id
int64
text
string
metadata
dict
line_start_n_end_idx
dict
quality_signals
dict
eai_taxonomy
dict
pid
string
6,879,383,775,663,011,000
Can video games really create new knowledge? Role-playing games like SchoolLife already help resolve bullyingGiantotter Lab “In Knowledge Games Karen Schrier argues that games can tackle some of the thorniest problems, from global warming to lack of food and clean water” MUCH has been made of how video games aren’t just for fun. They can also be educational, hone reflexes and mental agility, and even treat PTSD and depression. But Karen Schrier has bigger ideas in mind. In Knowledge Games, she writes: “I focus on how we can use games to create knowledge about our universe or develop original insights into human interactions.” LUFFY!!!!!! (12) Schrier is an assistant professor at Marist College in Poughkeepsie, New York, where she directs a programme about games and emerging media – so she should be well placed to make a case. And her book is as dogged as a doctoral thesis in chasing down its key questions: can games be used to create new knowledge? If so, how? Schrier focuses on the potential of games to tackle intractable problems by mapping them onto something that can be played, thereby reconceptualising them in a way that makes them easier to solve. So far, we’ve seen just a handful that fit the bill. Take EteRNA and Foldit, where players solve puzzles to devise designs for synthetic RNA molecules or shapes for proteins, respectively. EteRNAhas 37,000 players who have synthesised hundreds of new RNA designs by solving the puzzles. Using EteRNABot software, human players are better able to devise RNA molecules than any current algorithm. Then there’s EyeWire, in which players help to map neurons in the human brain. In Monster Proof, they check software for bugs. And SchoolLife lets students try their hand at different roles to identify ways to handle bullying. Schrier thinks games can also tackle some of the thorniest problems, from global warming to providing clean water and food. Take the SUDAN Game, which simulates the steps needed to resolve conflict there. Each of the game’s thousands of players checks out a few of the 185,760 interventions possible to see if any lead to a peaceful outcome. That way, the makers hope to find the best algorithm – at least on the basis of the game’s assumptions. “Human players are better able to devise new RNA molecules than any current algorithm“ The problems underlying the games come in many flavours. Ill-structured ones, for example, benefit from people trying many different solutions, as in Foldit or the SUDAN Game. Then there are dilemmas that may not have a single solution, or complex problems with multiple sub-problems. Perhaps the worst are “wicked problems”: ill-structured, complex dilemmas for which no single formulation is sufficient, people do not even agree on the problem, and there are no right or wrong answers – just better or worse ones, depending on skew. Indeed, most social and political problems are “wicked”: health issues that combine social and biological causes, such as heart disease; how to help children struggling at school; high rates of recidivism among prisoners. Can games help? Why not? Compared with other collective problem-solving activities, they unite people with different experiences in a uniquely structured and motivating way. Schrier makes no bones about the fact that knowledge games are much less fun than the ones they mimic – Tetris,Candy Crush, The Sims. That’s mostly because they tend to be made by small research groups with small budgets. It doesn’t have to stay that way, though. For now, there are plenty of people who like being part of a volunteer online community to make up for a lack of polish. In the end, Schrier does a great job of clearing a space where we can chat about games’ potential for giving us new perspectives on old problems. It’s exciting territory, but it remains underexplored. Ask me if a game was the right tool to crack a specific problem, and I’d have to change the subject.   Thanks to Johns Hopkins University Press for this article So what do you think? Dose being a gamer make you better at learning? Should gaming be made a part of our school studies? Leave your thoughts and comments below and lets have a discussion. Leave a Reply
{ "url": "http://www.smartandfitclub.com/2016/05/31/can-video-games-really-create-new-knowledge/", "source_domain": "www.smartandfitclub.com", "snapshot_id": "crawl=CC-MAIN-2016-50", "warc_metadata": { "Content-Length": "105931", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:G2MQAUEQTGIK5V7JEIDTUQZL5HLR7KSI", "WARC-Concurrent-To": "<urn:uuid:09f90843-62be-466c-b8e4-ef1320ca0dd4>", "WARC-Date": "2016-12-09T03:48:31Z", "WARC-IP-Address": "88.208.252.140", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:Y7V6ZKHCXJLDKJMSCPZKNZAKPYB7AG7X", "WARC-Record-ID": "<urn:uuid:dbb42926-2e7f-4556-a39d-ac63d6a58753>", "WARC-Target-URI": "http://www.smartandfitclub.com/2016/05/31/can-video-games-really-create-new-knowledge/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:97be0770-636c-4776-9dac-8c08b23f1264>" }, "warc_info": "robots: classic\r\nhostname: ip-10-31-129-80.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-50\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for November 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 45, 46, 125, 126, 274, 275, 434, 435, 638, 639, 656, 657, 981, 982, 1574, 1575, 1802, 1803, 2249, 2250, 2337, 2338, 2873, 2874, 3270, 3271, 3656, 3657, 3959, 3960, 3962, 3963, 4021, 4022, 4211, 4212 ], "line_end_idx": [ 45, 46, 125, 126, 274, 275, 434, 435, 638, 639, 656, 657, 981, 982, 1574, 1575, 1802, 1803, 2249, 2250, 2337, 2338, 2873, 2874, 3270, 3271, 3656, 3657, 3959, 3960, 3962, 3963, 4021, 4022, 4211, 4212, 4225 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4225, "ccnet_original_nlines": 36, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.41787439584732056, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.013285020366311073, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.14009661972522736, "rps_doc_frac_unique_words": 0.5170454382896423, "rps_doc_mean_word_length": 4.839488506317139, "rps_doc_num_sentences": 41, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.450106143951416, "rps_doc_word_count": 704, "rps_doc_frac_chars_dupe_10grams": 0.029938360676169395, "rps_doc_frac_chars_dupe_5grams": 0.06163780018687248, "rps_doc_frac_chars_dupe_6grams": 0.04637511074542999, "rps_doc_frac_chars_dupe_7grams": 0.029938360676169395, "rps_doc_frac_chars_dupe_8grams": 0.029938360676169395, "rps_doc_frac_chars_dupe_9grams": 0.029938360676169395, "rps_doc_frac_chars_top_2gram": 0.007337830029428005, "rps_doc_frac_chars_top_3gram": 0.010566480457782745, "rps_doc_frac_chars_top_4gram": 0.008805399760603905, "rps_doc_books_importance": -386.5858459472656, "rps_doc_books_importance_length_correction": -386.5858459472656, "rps_doc_openwebtext_importance": -251.26942443847656, "rps_doc_openwebtext_importance_length_correction": -251.26942443847656, "rps_doc_wikipedia_importance": -211.7935791015625, "rps_doc_wikipedia_importance_length_correction": -211.7935791015625 }, "fasttext": { "dclm": 0.0858004093170166, "english": 0.9497172832489014, "fineweb_edu_approx": 2.3560380935668945, "eai_general_math": 0.07864552736282349, "eai_open_web_math": 0.16544145345687866, "eai_web_code": 0.008766289800405502 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.0194", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "371.3922", "labels": { "level_1": "Social sciences", "level_2": "Education", "level_3": "Teachers, Teaching, and School management and organization" } } }, "bloom_cognitive_process": { "primary": { "code": "5", "label": "Evaluate" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "1", "label": "News/Editorial" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "10", "label": "Knowledge Article" }, "secondary": { "code": "16", "label": "Personal Blog" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
1,978,273,088,206,821,000
 Lógica proposicional - Wikillerato Patrocinado por PHPDocX Síguenos en Twitter Buscar en WikilleratO     Lógica proposicional De Wikillerato Una de las razones que motivó la aparición de la lógica matemática, fue evitar la ambigüedad del lenguaje natural y transformar el pensamiento en un cálculo, según el modo de operar de las matemáticas. Simplificar o simbolizar las oraciones o juicios para poder operar con ellas, así surge el Tabla de contenidos Lenguaje formal Consiste en abreviar o simbolizar las oraciones o juicios, que en la lógica matemática se llaman proposiciones. Estas proposiciones se reducen en el lenguaje formal a una sola letra, que llamamos variable, y la simbolizamos con las letras minúsculas del alfabeto que van de la “p” hasta el final del abecedario. Si digo por ejemplo:”Antonio ama a Piedad”, esta proposición queda simbolizada en el lenguaje formal mediante la variable “p” o “q”, o “r”, o “s”. Además de estas variables, la lógica proposicional utiliza otros símbolos, llamados constantes, cuyo significado siempre es el mismo ya que modifican o unen a las variables. Estos símbolos constantes, se llaman funtores, juntores, conectivas u operadores lógicos. Cuando el funtor afecta a una sola variable, se llama monádico, como por ejemplo el negador ( \bar{ } ) que se lee en el lenguaje natural “no”, y se sitúa encima de la letra variable, \bar{ p} , “no p”. Cuando afectan a más de una variable, son poliádicos. Los funtores más importantes son: [\land ] Conjuntor , “ y “ en el lenguaje natural. [\lor ] Disyuntor , “ o “. [\to ] Condicional, “ si…, entonces”. [\leftrightarrow ] Bicondiconal, “ si y sólo si…, entonces”. [ \underline{\lor }] Disyunción exclusiva, “o…o”, una proposición excluye a la otra. El negador además de ser un funtor monádico, es decir que afecta a una variable, puede ser poliádico, cuando afecta a más de una variable o a una expresión entera. Hay que tener siempre en cuenta, que las variables simbolizan oraciones enteras y no sólo palabras o nombres: Ejemplos de simbolización de oraciones, del lenguaje natural al lenguaje formal: 1. La conjunción: [ p \land q ] “Juan juega y Pedro estudia”. 2. La disyunción: [ p \lor q ] “Llueve o nieva”. 3. El condicional: [ p \to q ] “Si estudias entonces aprendes”. 4. El bicondicional: [ p \leftrightarrow q ] “Si y sólo si tienes dieciocho años puedes votar”. 5. La disyunción exclusiva: [ p \underline{\lor} q ] “O te quedas o te vas”. 6. La negación: [ \bar{p} ] “Manolo no juega limpio”. A veces el negador puede afectar a más de una variable o a la conjunción, o disyunción de ambas: [\overline{p \lor q} ] “Es falso que estudies o trabajes”. Valores de verdad En la gramática estamos acostumbrados a ver que la oraciones pueden ser verdaderas o falsas, según se ajusten o no a la realidad que expresan, por ejemplo si llueve y digo que “hace sol”, esa oración es falsa. En cambio la lógica considera que las proposiciones pueden ser verdaderas o falsas con independencia de que en la realidad lo sean; por eso habla de valores de verdad. Una proposición [ p ] puede ser indistintamente verdadera o falsa; cuando es verdadera, le damos valor 1, cuando es falsa, le adjudicamos el valor 0. Según esto la variable p, puede tener los siguientes valores: p 1100 1010 Cuando p siempre tiene valor 1, hablamos de tautología de p. Cuando siempre es falsa, contradicción de p. Si p es primero verdadera y luego falsa, afirmación de p. Cuando es primero falsa y luego verdadera, negación de p. Si consideramos los valores de dos variables conjuntamente, las posibilidades aumentan según el gráfico siguiente: p\, q 1  1  1 1 1 1 0 1 0 0 1 1 0 0 0 0 1 0 1  0   1 1 1 0 1 1 0 1 0 0 1 0 0 1 0 0 0  1  1 1 0 1 1 0 1 1 0 1 0 0 1 0 0 0 0  0  1 0 1 1 1 0 1 0 1 0 1 1 0 0 0 0 Las dos primeras columnas indican los cuatro valores posibles que pueden tener dos proposiciones simples, si se consideran sus valores a la vez: las dos verdaderas, la primera verdadera y la segunda falsa, la primera falsa y la segunda verdadera y las dos falsas. Las restantes dieciséis columnas representan los valores de verdad o falsedad, de cada una de las dieciséis proposiciones de orden dos. Entre estas proposiciones, hay algunas que tienen especial interés en lógica, según los valores que adoptan las variables cuando están afectadas por funtores: Proposición conjuntiva p\landq 111 100 001 000 La conjunción es verdadera sólo cuando ambas variables lo son y es falsa en los demás casos. Se lee p y q. Proposición disyuntiva inclusiva p\lorq 111 110 010 000 La disyunción es verdadera en todos los casos menos cuando p vale 1 y q vale 0. Se lee p ó q. Proposición disyuntiva exclusiva p\underline{\lor}q 101 110 011 000 La disyunción exclusiva es verdadera cuando una variable es verdadera y la otra falsa, y es falsa en los demás casos. Se lee p excluye a q. Proposición condicional p\toq 111 100 011 010 El condicional es verdadero en todos los caso menos cuando p vale 1 y q vale 0. Se lee p condiciona a q. Proposición bicondicional p\leftrightarrowq 111 100 001 010 El bicondicional es verdadero cuando ambos son verdaderos o cuando ambos son falsos, y es falso en los demás casos. Se lee p bicondiciona a q. Proposición negativa p\bar p 10 01 La negación - que se lee no p -, cambia el valor de la variable que se niega: sólo es verdadera si p es falsa y es falsa si p es verdadera. Proposiciones atómicas y moleculares. Las tablas de verdad ó tablas veritativas En Química se aprende que los cuerpos están formados de átomos que se asocian formando moléculas; cuando una proposición consta de una sola variable la llamamos proposición atómica, y, cuando consta de muchas variables, proposición molecular. Para hallar el valor de verdad de una proposición molecular, hay que descubrir el funtor capital, aquel que liga más, es decir que une o liga toda la expresión. Un mecanismo sencillo para conocer el valor del funtor capital en una proposición molecular es el llamado método de las tablas de verdad. Sirve de ayuda para localizar al funtor capital, la utilización de paréntesis y corchetes: [ (p \to q) \land p ] \to q En esta expresión se ve con claridad que el funtor capital es el condicional, que une todo el corchete con q. El modus operandi es ir encontrando el valor de verdad primero de los funtores que ligan menos, hasta llegar en último lugar al funtor capital. [ (p \to q) \land p] \to q 1 1 1 1 1 1 1 1 0 0 0 1 1 0 0 1 1 0 0 1 1 0 1 0 0 0 1 0 En esta expresión, se comienza hallando el valor del condicional en el primer paréntesis puesto que une a la p con la q; después la conjunción que une el resultado del condicional con la p dentro del corchete; y por último el condicional que une el resultado recién hallado de la conjunción con la última variable q. Cuando en la tabla aparece en todos los lugares de funtor capital el valor 1, la expresión es una tautología o identidad. Si en todos los lugares el valor es 0, es una contradicción. Finalmente cuando en el funtor capital encontramos valores de 1 y de 0, la proposición es indeterminada. Dos proposiciones son equivalentes si tienen la misma tabla veritativa: (p \to q)         (\bar p \lor q) 1 1 1 0 1 1 1 0 0 0 0 0 0 1 1 1 1 1 0 1 1 1 1 0 Según se observa en este ejemplo, el resultado del condicional en el primer paréntesis, es el mismo que el resultado de la disyunción en el segundo paréntesis. Estas proposiciones son por tanto, equivalentes; esto quiere decir que pueden ser sustituidas una por la otra. Dada cualquier expresión, se puede sustituir por otra equivalente, esta afirmación se conoce con el nombre de principio o regla de sustitución. Leyes lógicas Todas aquellas proposiciones tautológicas son leyes de la lógica proposicional. Por ejemplo: p \lor \bar p 1 1 0 0 1 1 Es una ley lógica que ya conoció Aristóteles (384 – 322) con el nombre de tercero excluido o tertio excluso. Las leyes lógicas son muy numerosas, pero hay algunas muy importantes que se refieren a la conjunción, disyunción y negador (La T significa tautología y la C contradicción): Idempotencia ( p \lor p ) \leftrightarrow p Asociativa [ ( p \lor q ) \lor r ] \leftrightarrow p \lor q \lor r [ ( p \land q ) \land r ] \leftrightarrow p \land q \land r Conmutativa ( p \lor q ) \leftrightarrow (q \lor p) ( p \land q ) \leftrightarrow (q \land p) Identidad ( p \lor T ) \leftrightarrow T ( p \land T ) \leftrightarrow p ( p \lor C ) \leftrightarrow p ( p \land C) \leftrightarrow C Absorción p \lor ( q \land p ) \leftrightarrow p \, p \land ( q \lor p ) \leftrightarrow p \, Distributiva p \lor ( q \land r ) \leftrightarrow ( p\lor q) \land ( p\lor q) p \land ( q \lor r ) \leftrightarrow ( p\land q) \lor ( p\land q) Negación ( p \lor \bar p) \leftrightarrow T ( p \land \bar p) \leftrightarrow C Morgan Doble negación       ASIGNATURAS MatemáticasFísicaQuímicaBiologíaDibujoHistoriaLengua y LiteraturaHistoria del ArteFilosofía Creative Commons License Los contenidos de Wikillerato están disponibles bajo una licencia de Creative Commons. Pueden utilizarse y redistribuirse libremente siempre que se reconozca su procedencia.
{ "url": "http://www.wikillerato.org/index.php?title=L%C3%B3gica_proposicional&oldid=4273", "source_domain": "www.wikillerato.org", "snapshot_id": "crawl=CC-MAIN-2020-29", "warc_metadata": { "Content-Length": "50822", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:GGN7IKNPBTYJZM72DWN6P6XYIK7TXO2Z", "WARC-Concurrent-To": "<urn:uuid:de5283ef-877e-43bc-8810-8787aaee4bb2>", "WARC-Date": "2020-07-12T19:59:21Z", "WARC-IP-Address": "176.28.102.2", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:TUISPSP7V44D5WXNLQRVXHWNGXTMZ2DA", "WARC-Record-ID": "<urn:uuid:0860604c-53fa-4a9b-818c-84074afef370>", "WARC-Target-URI": "http://www.wikillerato.org/index.php?title=L%C3%B3gica_proposicional&oldid=4273", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:7c32973d-fce1-4031-a41b-9504da5abc74>" }, "warc_info": "isPartOf: CC-MAIN-2020-29\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-82.ec2.internal\r\nsoftware: Apache Nutch 1.17 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 61, 62, 82, 83, 105, 109, 110, 131, 132, 147, 148, 441, 442, 443, 463, 464, 480, 481, 793, 794, 941, 942, 1206, 1207, 1498, 1499, 1552, 1553, 1582, 1583, 1623, 1624, 1687, 1688, 1775, 1776, 1777, 1941, 1942, 2052, 2053, 2134, 2135, 2199, 2200, 2251, 2252, 2317, 2318, 2414, 2415, 2493, 2494, 2548, 2549, 2646, 2647, 2708, 2709, 2727, 2728, 3106, 3107, 3319, 3320, 3322, 3327, 3332, 3333, 3334, 3556, 3557, 3558, 3673, 3674, 3675, 3681, 3719, 3758, 3796, 3834, 3835, 3836, 4100, 4101, 4237, 4238, 4397, 4398, 4421, 4422, 4430, 4434, 4438, 4442, 4446, 4447, 4540, 4541, 4555, 4556, 4557, 4590, 4591, 4598, 4602, 4606, 4610, 4614, 4615, 4695, 4696, 4710, 4711, 4712, 4745, 4746, 4765, 4769, 4773, 4777, 4781, 4782, 4900, 4901, 4923, 4924, 4948, 4949, 4955, 4959, 4963, 4967, 4971, 4972, 5052, 5053, 5078, 5079, 5080, 5106, 5107, 5125, 5129, 5133, 5137, 5141, 5142, 5258, 5259, 5286, 5287, 5308, 5309, 5317, 5320, 5323, 5324, 5464, 5465, 5466, 5546, 5547, 5790, 5791, 5952, 5953, 6091, 6092, 6093, 6184, 6185, 6218, 6219, 6329, 6330, 6474, 6475, 6502, 6516, 6530, 6544, 6558, 6559, 6876, 6877, 7165, 7166, 7238, 7239, 7273, 7285, 7297, 7309, 7321, 7322, 7323, 7594, 7595, 7739, 7740, 7741, 7755, 7756, 7849, 7850, 7864, 7870, 7876, 7877, 7986, 7987, 8161, 8162, 8163, 8176, 8177, 8213, 8214, 8225, 8226, 8297, 8298, 8373, 8374, 8386, 8387, 8436, 8437, 8488, 8489, 8499, 8500, 8536, 8537, 8574, 8575, 8611, 8612, 8648, 8649, 8659, 8660, 8702, 8703, 8745, 8746, 8759, 8760, 8826, 8827, 8894, 8895, 8904, 8905, 8942, 8943, 8981, 8982, 8989, 8990, 9005, 9006, 9010, 9012, 9024, 9116, 9141, 9228 ], "line_end_idx": [ 61, 62, 82, 83, 105, 109, 110, 131, 132, 147, 148, 441, 442, 443, 463, 464, 480, 481, 793, 794, 941, 942, 1206, 1207, 1498, 1499, 1552, 1553, 1582, 1583, 1623, 1624, 1687, 1688, 1775, 1776, 1777, 1941, 1942, 2052, 2053, 2134, 2135, 2199, 2200, 2251, 2252, 2317, 2318, 2414, 2415, 2493, 2494, 2548, 2549, 2646, 2647, 2708, 2709, 2727, 2728, 3106, 3107, 3319, 3320, 3322, 3327, 3332, 3333, 3334, 3556, 3557, 3558, 3673, 3674, 3675, 3681, 3719, 3758, 3796, 3834, 3835, 3836, 4100, 4101, 4237, 4238, 4397, 4398, 4421, 4422, 4430, 4434, 4438, 4442, 4446, 4447, 4540, 4541, 4555, 4556, 4557, 4590, 4591, 4598, 4602, 4606, 4610, 4614, 4615, 4695, 4696, 4710, 4711, 4712, 4745, 4746, 4765, 4769, 4773, 4777, 4781, 4782, 4900, 4901, 4923, 4924, 4948, 4949, 4955, 4959, 4963, 4967, 4971, 4972, 5052, 5053, 5078, 5079, 5080, 5106, 5107, 5125, 5129, 5133, 5137, 5141, 5142, 5258, 5259, 5286, 5287, 5308, 5309, 5317, 5320, 5323, 5324, 5464, 5465, 5466, 5546, 5547, 5790, 5791, 5952, 5953, 6091, 6092, 6093, 6184, 6185, 6218, 6219, 6329, 6330, 6474, 6475, 6502, 6516, 6530, 6544, 6558, 6559, 6876, 6877, 7165, 7166, 7238, 7239, 7273, 7285, 7297, 7309, 7321, 7322, 7323, 7594, 7595, 7739, 7740, 7741, 7755, 7756, 7849, 7850, 7864, 7870, 7876, 7877, 7986, 7987, 8161, 8162, 8163, 8176, 8177, 8213, 8214, 8225, 8226, 8297, 8298, 8373, 8374, 8386, 8387, 8436, 8437, 8488, 8489, 8499, 8500, 8536, 8537, 8574, 8575, 8611, 8612, 8648, 8649, 8659, 8660, 8702, 8703, 8745, 8746, 8759, 8760, 8826, 8827, 8894, 8895, 8904, 8905, 8942, 8943, 8981, 8982, 8989, 8990, 9005, 9006, 9010, 9012, 9024, 9116, 9141, 9228, 9314 ] }
{ "red_pajama_v2": { "ccnet_original_length": 9314, "ccnet_original_nlines": 269, "rps_doc_curly_bracket": 0.0015031100483611226, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.1323155164718628, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.0066157798282802105, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.2798982262611389, "rps_doc_frac_unique_words": 0.27911391854286194, "rps_doc_mean_word_length": 4.550632953643799, "rps_doc_num_sentences": 64, "rps_doc_symbol_to_word_ratio": 0.0015267200069501996, "rps_doc_unigram_entropy": 5.100957870483398, "rps_doc_word_count": 1580, "rps_doc_frac_chars_dupe_10grams": 0.020027820020914078, "rps_doc_frac_chars_dupe_5grams": 0.08052851259708405, "rps_doc_frac_chars_dupe_6grams": 0.06481224298477173, "rps_doc_frac_chars_dupe_7grams": 0.0445062592625618, "rps_doc_frac_chars_dupe_8grams": 0.02475661039352417, "rps_doc_frac_chars_dupe_9grams": 0.022809460759162903, "rps_doc_frac_chars_top_2gram": 0.010848400183022022, "rps_doc_frac_chars_top_3gram": 0.008344920352101326, "rps_doc_frac_chars_top_4gram": 0.00611960981041193, "rps_doc_books_importance": -697.7138671875, "rps_doc_books_importance_length_correction": -697.7138671875, "rps_doc_openwebtext_importance": -417.0889587402344, "rps_doc_openwebtext_importance_length_correction": -417.0889587402344, "rps_doc_wikipedia_importance": -299.2660827636719, "rps_doc_wikipedia_importance_length_correction": -299.2660827636719 }, "fasttext": { "dclm": 0.656700611114502, "english": 0.0011600099969655275, "fineweb_edu_approx": 1.5574390888214111, "eai_general_math": 0.028033550828695297, "eai_open_web_math": 0.9211881160736084, "eai_web_code": 0.8140143752098083 } }
{ "free_decimal_correspondence": { "primary": { "code": "511.3", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Arithmetic" } }, "secondary": { "code": "510", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "10", "label": "Knowledge Article" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
806,505,873,434,801,300
Skip to content HTTPS clone URL Subversion checkout URL You can clone with or . Download ZIP branch: master @brendano 667 lines (544 sloc) 19.301 kB # util.R: # Utilities to make R a happier place # Brendan O'Connor, brenocon.com/code ######################################## ## Tell R the terminal width. Needs to be re-run every time you resize the ## terminal, so source() this file if ( (numcol <-Sys.getenv("COLUMNS")) != "") { numcol = as.integer(numcol) options(width= numcol - 1) } else if (Sys.info()['sysname'] == 'Darwin') { # I think this is a mac-only stty output format. # TODO need to prevent this from executing when under GUI output = tryCatch(system("stty -a", intern=T), error=I) if (length(output) > 0) { numcol = as.integer(sub(".* ([0-9]+) column.*", "\\1", output[1])) if (is.finite(numcol) && numcol > 0) { options(width= numcol - 1 ) } } rm(output) } rm(numcol) ######################################## ## Put everything into an environment, to not pollute global namespace util = new.env() ######################################## ## Better I/O routines util$read.tsv <- function(..., header=F, sep='\t', quote='', comment='', na.strings='', stringsAsFactors=FALSE) { # read.table() wrapper with default settings for no-nonsense, pure TSV # Typical use case is output from another program. # (R's defaults are more geared for human-readable datafiles, which is less # feasible for large-scale data anyway.) # These options are substantially faster than read.table() defaults. # (see e.g. LINK) # stringsAsFactors is the devil. args = list(...) args$header = header if (!is.null(args$col.names)) { # read.delim() is not smart about this. Yikes. args$header = FALSE } args$sep = sep args$quote = quote args$comment = comment args$stringsAsFactors = stringsAsFactors args$na.strings = na.strings do.call(read.delim, args) } util$write.tsv <- function(..., header=NA, col.names=F, row.names=F, sep='\t', na='', quote=F) { # 'header' to 'col.names' naming consistency with read.table() if (is.finite(header)) col.names = header write.table(..., col.names=col.names, row.names=row.names, sep=sep, na=na, quote=quote) } ######################################## ## Misc small routines util$as.c <- as.character util$unwhich <- function(indices, len=length(indices)) { # reverse of which(): from indices to boolean mask. ret = rep(F,len) ret[indices] = T ret } util$nna <- function(...) !is.na(...) # i type this a lot, i think its worth 3 characters + shift key util$kna <- function(x) x[nna(x)] # kill NA's (from vector) .. BUT is this same as na.omit() ? # hm: is this subsumed by reshape::rescaler? util$unitnorm <- function(x, na.rm=FALSE, ...) (x - mean(x,na.rm=na.rm,...)) / sd(x,na.rm=na.rm) util$renorm <- function(x, mean=0, sd=1, ...) (unitnorm(x,...) * sd) + mean util$rbern <- function(n, p=0.5) rbinom(n, size=1, prob=p) util$boot_binom <- function(n, p) rbinom(1,n,p)/n util$shuffle <- function(...) UseMethod("shuffle") util$shuffle.default <- function(x) x[order(runif(length(x)))] util$shuffle.data.frame <- function(x) x[order(runif(nrow(x))),] util$sample_df <- function(d, size=10, ...) { samp = sample(1:nrow(d), size=size, ...) d[samp,] } util$present_levels <- function(x) intersect(levels(x), x) util$trim_levels <- function(...) UseMethod("trim_levels") util$trim_levels.factor <- function(x) factor(x, levels=present_levels(x)) util$trim_levels.data.frame <- function(x) { for (n in names(x)) if (is.factor(x[,n])) x[,n] = trim_levels(x[,n]) x } util$prio_check = function(...) { # priority-order, 3-value-logic backoff # the first argument that is not NA or NULL, return it. vars = list(...) for (i in 1:length(vars)) { if (!is.null(vars[[i]]) && !is.na(vars[[i]])) return(vars[[i]]) } FALSE } util$grid_points <- function(min,max) { # 1,2,5,10,20,50 ... kinda-exponential scaling, nice for grid search x = min ret = NULL while(x <= max) { ret = c(ret, x, x*2, x*5) x = x * 10 } ret[ret <= max] } # grep() returns indices of matches. Variants: util$bgrep <- function(pat,x, ...) { # "boolean" grep: return a logical vector ready for vector ops # like & | and others unwhich(grep(pat,x,...), length(x)) } util$ngrep <- function(pat,x, ...) # "normal" grep: return values, not indices x[grep(pat,x,...)] ######################################## ## Other data manipulation routines util$merge.list <- function(x,y,only.new.y=FALSE,append=FALSE,...) { # http://tolstoy.newcastle.edu.au/R/devel/04/11/1469.html out=x ystructure = names(c(y,recursive=TRUE)) xstructure = names(c(x,recursive=TRUE)) yunique = ystructure[! ystructure %in% xstructure] ystructure = sapply(ystructure,FUN=function(element) strsplit(element,"\\.")) xstructure = sapply(xstructure,FUN=function(element) strsplit(element,"\\.")) yunique = sapply(yunique,FUN=function(element) strsplit(element,"\\.")) if (only.new.y) lapply(yunique, FUN=function(index) out[[index]]<<-y[[index]]) else { if (!append) { lapply(ystructure, FUN=function(index) out[[index]]<<-y[[index]]) } else lapply(ystructure, FUN=function(index) out[[index]]<<-c(out[[index]],y[[index]])) } return(out) } util$tapply2 <- function(x, ...) { # like tapply but preserves factors if (is.factor(x)) { r = factor(tapply(as.character(x), ...), levels=levels(x)) } else { r = tapply(x, ...) } r } util$inject <- function(collection, start, fn) { # like lisp reduce. (named after ruby) acc = start for (x in collection) acc = fn(acc, x) acc } util$xprod <- function(xs,ys) { # Set cross-product ret = list() i=0 for (x in xs) for (y in ys) { i = i+1 ret[[i]] = list(x=x,y=y) } ret } util$multi_xprod <- function(args) { # Set cross-product pair_xprod <- function(xs,ys) { ret = list() i=0 for (x in xs) for (y in ys) { i = i+1 ret[[i]] = c(x,y) } ret } ret = list(NA) for (i in 1:length(args)) { ret = pair_xprod(ret, args[[i]]) } lapply(ret, function(x) x[2:length(x)]) } ######################################## ## Printing, viewing ## see also: str() util$printf <- function(...) cat(sprintf(...)) util$listprint <- function(x) { s = paste(sapply(names(x), function(n) sprintf("%s=%s", n,x[[n]])), collapse=' ') printf("%s\n", s) } util$msg <- function(...) cat(..., "\n", file=stderr()) util$h = utils::head util$ppy <- function(x, column.major=FALSE, ...) { # pretty-print as yaml. intended for rows with big textual cells. # a la mysql's \G operator library(yaml) cat(as.yaml(x, column.major=column.major), ...) cat("\n", ...) } util$table_html = function(...) { # Intended for inside dosink() columns = list(...) ncol = length(columns) nrow = length(columns[[1]]) # assume columns are in parallel printf("\n<table cellpadding=3 border=1 cellspacing=0 bordercolor=gray>") for (i in 1:nrow) { printf("\n<tr>") for (j in 1:ncol) printf("\n <td>%s", columns[[j]][i]) } printf("\n</table>\n") } ######################################## ## Workspace management # improved list of objects # http://stackoverflow.com/questions/1358003/tricks-to-manage-the-available-memory-in-an-r-session util$list_objects = function (pos = 1, pattern) { napply = function(names, fn) sapply(names, function(x) fn(get(x, pos = pos))) names = ls(pos = pos, pattern = pattern) N = length(names) obj_class = napply(names, function(x) as.character(class(x))[1]) obj_mode = napply(names, mode) obj_type = ifelse(is.na(obj_class), obj_mode, obj_class) obj_prettysize = napply(names, function(x) { capture.output(print(object.size(x), units = "auto")) }) obj_size = napply(names, object.size) obj_prettysize[obj_size < 1e6] = "" obj_length = napply(names, function(x) length(x)) obj_dim = t(napply(names, function(x) as.numeric(dim(x))[1:2])) is_flat = is.na(obj_dim)[, 1] is_vector = napply(names, function(x) is.vector(x) & class(x) != 'list') info_width = max(20, options('width')$width - 60) small_str = function(x) { out = capture.output( str(x, max.level=0, give.attr=F, give.head=F, width=info_width, strict.width='cut') ) out = str_c(out,collapse=' ') out = cutoff(str_replace(out,"\n"," ")) if (str_detect(out, "^List of")) out = str_c("[Names] $ ", str_c(names(x),collapse=' ')) cutoff(out) } cutoff = function(s) { if (str_length(s) >= info_width) { str_c(str_sub(s,1,info_width-2),'..') } else { s } } pad = function(s) sprintf(" %s", s) out <- data.frame( Type = obj_type, Size = obj_prettysize, Dim = ifelse(is_vector | is_flat, obj_length, sprintf("(%s, %s)", obj_dim[,1], obj_dim[,2])), Value = napply(names, function(x) if (class(x) %in% c('data.frame','list') && !is.null(names(x))) cutoff(str_c("[Names] $ ",str_c(names(x), collapse=' '))) else small_str(x) ), stringsAsFactors=F) row.names(out) = names out$Dim = sprintf(" %s", out$Dim) out$Value = sprintf(str_c(" %-", info_width, "s"), out$Value) out = rbind(subset(out, Type!='function'), subset(out, Type=='function')) out } util$lsos = function() { d = list_objects() d$name = row.names(d) d = subset(d, name != 'util') row.names(d)=d$name d$name=NULL d } ######################################## ## For performance optimization and long-running jobs util$timeit <- function(expr, name=NULL) { # print how long the expression takes, and return its value too. # So you can interpose timeit({ blabla }) around any chunk of code "blabla". start = Sys.time() ret = eval(expr) finish = Sys.time() if (!is.null(name)) cat(name,": ") print(finish-start) invisible(ret) } util$dotprogress <- function(callback, interval=10) { # intended to wrap the anonymous callback for sapply() or somesuch. # ALTERNATIVE: plyr *ply(.progress='text') count = 0 return(function(...) { if ((count <<- count+1) %% interval == 0) cat(".") callback(...) }) } ######################################## ## External programs for interactivity util$excel <- function(d) { f = paste("/tmp/tmp.", round(runif(1)*1000),".csv", sep='') # con = file(f, "w", encoding="MACROMAN") con = file(f, "w") write.csv(d, con, row.names=FALSE) close(con) # system(paste("open -a 'Microsoft Excel' ",f, sep='')) system(paste("open -a '/Applications/Microsoft Office 2008/Microsoft Excel.app' ",f, sep='')) } util$mate <- function(...) { system(paste("mate", ...)) } util$vim <- function(...) { system(paste("vim",...)) } util$ll <- function(...) { system(paste("ls","-l",...)) } util$newwin <- function(x) { # Takes object printout into new file... dosink(OPEN=T) kinda subsumes this f = paste("/tmp/tmp.", round(runif(1)*100),".txt", sep='') capture.output(print(x),file=f) # system("FILE_TO_VIEW=/tmp/tmp.txt /Applications/Utilities/Terminal.app/Contents/MacOS/Terminal /users/brendano/sw/bin/lame_viewer.sh") # system("DISPLAY=:0 /usr/X11R6/bin/xterm -geometry 80x60 -e less /tmp/tmp.txt &") system(paste("mate ",f," &", sep='')) } ######################################## ## Graphics output wrappers ## For easy one-liners, like: ## dopdf("tmp.pdf",width=5,height=5,cmd=plot(x,y)) util$dopdf <- function(filename,..., cmd) { pdf(filename, ...) eval(cmd) dev.off() if (exists('OPEN') && OPEN) system(sprintf("open %s", filename)) } util$dopng <- function(filename,..., cmd) { png(filename, ...) eval(cmd) dev.off() if ((exists('OPEN') && OPEN)) system(sprintf("open %s", filename)) } util$dosink <- function(filename,cmd, open=NULL) { # like capture.output() but follows open/OPEN conventions here sink(filename) eval(cmd) sink(NULL) if (prio_check(open, exists('OPEN') && OPEN)) system(sprintf("open %s", filename)) } util$dosvg <- function(filename, ..., cmd, open=NULL) { library("RSvgDevice") devSVG(filename, ...) eval(cmd) dev.off() if (prio_check(open, exists('OPEN') && OPEN)) system(sprintf("open %s", filename)) } ######################################## ## Plotting routines util$linelight <- function(x,y, lty='dashed', col='lightgray', ...) { # highlight a point with lines running to the axes. left = par('usr')[1] bot = par('usr')[3] segments(left,y, x,y, lty=lty, col=col, ...) segments(x,bot, x,y, lty=lty, col=col, ...) } util$hintonplot <- function(mat, max_value=max(abs(mat)), mid_value=0, ...) { # Plots a matrix as colored, size-varying boxes # I dunno who started calling this a "Hinton plot", but anyways # Example: # hintonplot(matrix(rnorm(100),10)) # Example, for counts: # table(cyl=mtcars$cyl, mpg=cut(mtcars$mpg,3)) # mpg # cyl (10.4,18.2] (18.2,26.1] (26.1,33.9] # 4 0 6 5 # 6 2 5 0 # 8 12 2 0 # hintonplot(table(cyl=mtcars$cyl, mpg=cut(mtcars$mpg,3))) plot.new() plot.window(xlim=c(0.5,ncol(mat)+0.5), ylim=c(0.5,nrow(mat)+0.5)) x_mid = 1:ncol(mat) y_mid = 1:nrow(mat) area = abs(mat) / max_value side = sqrt(area) for (x in 1:ncol(mat)) { for (y in nrow(mat):1) { # ym = (nrow(mat):1)[y] ym = y d = side[ym,x] / 2 rect(x-d, y-d, x+d, y+d, col=if (mat[ym,x]>0) 'darkblue' else 'darkred') } } axis(1, 1:ncol(mat), labels=colnames(mat)) # axis(2, nrow(mat):1, labels=row.names(mat)) axis(2, 1:nrow(mat), labels=row.names(mat)) title(xlab=names(dimnames(mat))[2], ylab=names(dimnames(mat))[1], ...) } util$binary_eval <- function(pred,labels, cutoff='naive', repar=TRUE, ...) { # Various binary classification evaluation plots and metrics library(ROCR) # plot(performance(prediction(pred,y),'acc')) rocr_pred = prediction(pred,labels) acc = performance(rocr_pred,'acc') f1 = performance(rocr_pred,'f') auc = performance(rocr_pred,'auc')@y.values[[1]] roc = performance(rocr_pred,'rec','spec') bac = if (rocr_pred@n.pos[[1]] != rocr_pred@n.neg[[1]]) sapply(1:length(roc@x.values[[1]]), function(i) mean(c(roc@x.values[[1]][i], roc@y.values[[1]][i]))) else rep(-1,length(pred)) # sensspec = performance(rocr_pred,'rec','spec') pr_curve = performance(rocr_pred,'prec','rec') rp_curve = performance(rocr_pred,'rec','prec') printf("AUC = %.3f\n", auc) if (cutoff=='naive') { if (all(pred>=0) & all(pred<=1)) { printf("Predictions seem to be probabilities, so ") cutoff = 0.5 } else if (any(pred<0) & any(pred>0)) { printf("Predictions seem to be real-valued scores, so ") cutoff = 0 } else { warning("cant tell what naive cutoff should be") cutoff = NULL } printf("using naive cutoff %s:\n", cutoff) } else if (class(cutoff)=='character') { printf("Using %s-best cutoff ", cutoff) if (cutoff=='bac') { perf = NULL perf_y = bac } else { perf = performance(rocr_pred, cutoff, ...) perf_y = perf@y.values[[1]] } cutoff_ind = which.max(perf_y) cutoff = if (cutoff=='prbe') perf@x.values[[1]][1] else rocr_pred@cutoffs[[1]][cutoff_ind] printf("%f\n", cutoff) } else { printf("For cutoff %s:\n", cutoff) } cutoff_ind = last(which(rocr_pred@cutoffs[[1]] >= cutoff)) if (repar) par(mfrow=c(2,2)) pp = function(perf) { if (length(cutoff_ind)>0 && is.finite(cutoff_ind)) { x=perf@x.values[[1]][cutoff_ind] y=perf@y.values[[1]][cutoff_ind] points(x,y, col='blue') linelight(x,y, col='lightblue') } } plot(acc); pp(acc) plot(f1); pp(f1) plot(roc); pp(roc) abline(a=1,b=-1,lty='dashed',col='gray') legend('bottomleft',legend=sprintf("AUC = %.3f",auc)) plot(rp_curve); pp(rp_curve) pp = function(ind,...) points(rp_curve@x.values[[1]][ind], rp_curve@y.values[[1]][ind], ...) best_f1 = which.max(f1@y.values[[1]]) pp(best_f1, pch=2,col='green') f05 = performance(rocr_pred,'f',beta=0.5) best_f05 = which.max(f05@y.values[[1]]) pp(best_f05,pch=2,col='green') f2 = performance(rocr_pred,'f',beta=2) best_f2 = which.max(f2@y.values[[1]]) pp(best_f2,pch=2,col='green') prbe = performance(rocr_pred,'prbe')@y.values[[1]] linelight(prbe,prbe,col='lightgray') # printf("Acc = %.3f\n", mean((pred >= cutoff) == (labels > 0))) printf("Acc %.3f, ", acc@y.values[[1]][cutoff_ind]) printf(" F %.3f, Prec %.3f, Rec %.3f, Spec %.3f", f1@y.values[[1]][cutoff_ind], pr_curve@y.values[[1]][cutoff_ind], pr_curve@x.values[[1]][cutoff_ind], roc@x.values[[1]][cutoff_ind]) # printf(" Prec = %.3f\n", pr_curve@y.values[[1]][cutoff_ind]) # printf(" Rec = %.3f\n", pr_curve@x.values[[1]][cutoff_ind]) # printf(" Spec = %.3f\n", roc@x.values[[1]][cutoff_ind]) if (bac[1] != -1) printf(", BalAcc %.3f", mean(bac)) printf("\n") invisible(rocr_pred) } ######################################## # These are kinda obscure, should delete? util$fair_gt <- function(x,y) { # Breaks ties arbitrarily. # of TRUE's should be halfway between > and >=. ret = rep(NA, length(x)) ret[x > y] = TRUE ret[x < y] = FALSE # which filler order? should randomly chooise either c(T,F) vs c(F,T) as the # seed (or a random permutation of 50/50 distribution on the whole length), # but not clear how to stably but arbitrarily choose one... hash the bitmap # of the concatenation of x and y perhaps. don't know how to do in highlevel R. filler_length = length(which(x==y)) filler = rep(c(TRUE,FALSE), ceiling(filler_length/2) )[1:filler_length] ret[which(x == y)] = filler ret } util$fair_lt <- function(x,y) ! fair_gt(x,y) util$rand_gt <- function(x,y) { # Breaks ties randomly. ret = rep(NA, length(x)) ret[x > y] = TRUE ret[x < y] = FALSE filler_length = length(which(x==y)) filler = as.logical(rbern(filler_length)) ret[which(x == y)] = filler ret } util$rand_lt <- function(x,y) ! rand_gt(x,y) ######################################## # Deprecated ## now in plyr 0.19 as summarise() http://github.com/hadley/plyr/blob/master/NEWS # util$reframe = function(.data, ...) { # e = eval(substitute(list(...)), .data, parent.frame()) # data.frame(e) # } # util$table.range <- function(x, min=NULL, max=NULL) { # ## DEPRECATED: use factor() on both sides, instead, to specify the allowable range # # Like table(), but only for integers, and forces a contiguous range of bins # # so counts of 0 can appear. Useful if you want to compare tables between # # different datasets. # if (is.null(min)) min = min(x) # if (is.null(max)) max = max(x) # x2 = rep(0, max-min+1) # t = table(x) # t_inds = as.integer(names(t)) # t_mask = t_inds >= min & t_inds <= max # t_inds = t_inds[t_mask] # mask = t_inds - min + 1 # x2[mask] = x2[mask] + t[t_mask] # names(x2) = min:max # x2 # } ######################################## ######################################## ## Has to be last in file while("util" %in% search()) detach("util") attach(util) Jump to Line Something went wrong with that request. Please try again.
{ "url": "https://github.com/brendano/dlanalysis/blob/master/util.R", "source_domain": "github.com", "snapshot_id": "crawl=CC-MAIN-2015-27", "warc_metadata": { "Content-Length": "232216", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:I6OORJL34UU3ZICQ7YMF3GH4RUH2ATLV", "WARC-Concurrent-To": "<urn:uuid:6f474c87-32c2-442d-954b-dc171d0fcfc3>", "WARC-Date": "2015-07-02T12:37:42Z", "WARC-IP-Address": "192.30.252.131", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:J4DEFFTJX247IXIDI2N2JWDFW2QMISOO", "WARC-Record-ID": "<urn:uuid:158e1ee6-2932-4fa6-88f3-f44f5fa92874>", "WARC-Target-URI": "https://github.com/brendano/dlanalysis/blob/master/util.R", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:c27b3125-1152-455d-a9dc-8bd4ae577287>" }, "warc_info": "robots: classic\r\nhostname: ip-10-179-60-89.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-27\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for June 2015\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 16, 17, 33, 34, 58, 59, 78, 81, 83, 96, 111, 121, 152, 162, 200, 238, 279, 354, 389, 436, 464, 491, 539, 588, 646, 702, 728, 795, 834, 862, 864, 866, 877, 879, 890, 931, 1002, 1019, 1060, 1083, 1197, 1268, 1319, 1395, 1436, 1505, 1523, 1556, 1573, 1594, 1626, 1673, 1693, 1695, 1710, 1729, 1752, 1793, 1822, 1848, 1850, 1947, 2010, 2052, 2140, 2142, 2183, 2206, 2232, 2289, 2341, 2358, 2375, 2379, 2381, 2483, 2578, 2623, 2720, 2796, 2855, 2905, 2956, 3019, 3084, 3130, 3171, 3180, 3182, 3241, 3300, 3375, 3420, 3440, 3462, 3489, 3491, 3493, 3527, 3567, 3623, 3640, 3668, 3714, 3732, 3734, 3740, 3742, 3782, 3851, 3859, 3870, 3888, 3914, 3925, 3927, 3943, 3945, 3992, 4029, 4092, 4114, 4150, 4152, 4187, 4231, 4250, 4291, 4327, 4396, 4454, 4460, 4500, 4540, 4591, 4669, 4747, 4819, 4835, 4898, 4905, 4920, 4986, 4988, 5075, 5077, 5089, 5091, 5126, 5162, 5182, 5241, 5250, 5269, 5271, 5273, 5275, 5324, 5363, 5375, 5397, 5414, 5418, 5420, 5452, 5472, 5485, 5489, 5519, 5527, 5552, 5554, 5558, 5560, 5597, 5617, 5649, 5662, 5666, 5696, 5704, 5722, 5724, 5728, 5730, 5745, 5773, 5806, 5808, 5848, 5850, 5891, 5912, 5931, 5978, 6010, 6092, 6110, 6112, 6168, 6189, 6240, 6306, 6333, 6347, 6395, 6410, 6412, 6446, 6477, 6497, 6520, 6548, 6581, 6655, 6675, 6692, 6710, 6747, 6749, 6772, 6774, 6815, 6839, 6866, 6965, 7015, 7070, 7093, 7134, 7152, 7217, 7248, 7305, 7350, 7407, 7445, 7481, 7531, 7569, 7595, 7625, 7698, 7748, 7774, 7796, 7880, 7882, 7912, 7952, 7985, 8041, 8053, 8055, 8078, 8113, 8151, 8160, 8162, 8164, 8166, 8202, 8221, 8238, 8261, 8307, 8355, 8389, 8453, 8511, 8529, 8532, 8552, 8575, 8609, 8671, 8745, 8749, 8751, 8776, 8795, 8817, 8847, 8867, 8879, 8881, 8883, 8924, 8978, 9021, 9086, 9163, 9182, 9199, 9219, 9254, 9274, 9289, 9291, 9345, 9413, 9456, 9466, 9489, 9531, 9540, 9554, 9557, 9559, 9600, 9639, 9667, 9727, 9769, 9788, 9823, 9834, 9890, 9984, 9986, 10015, 10042, 10044, 10072, 10097, 10099, 10126, 10155, 10157, 10186, 10262, 10321, 10353, 10490, 10573, 10611, 10613, 10654, 10682, 10712, 10763, 10807, 10826, 10836, 10846, 10874, 10911, 10913, 10957, 10976, 10986, 10996, 11026, 11063, 11065, 11116, 11179, 11194, 11204, 11215, 11261, 11298, 11300, 11356, 11378, 11400, 11410, 11420, 11466, 11503, 11505, 11546, 11567, 11637, 11689, 11710, 11730, 11775, 11819, 11821, 11899, 11947, 12011, 12022, 12058, 12081, 12128, 12134, 12176, 12186, 12196, 12207, 12266, 12277, 12343, 12363, 12383, 12411, 12429, 12454, 12479, 12503, 12510, 12529, 12602, 12604, 12606, 12649, 12695, 12739, 12810, 12812, 12889, 12950, 12964, 13010, 13046, 13081, 13113, 13162, 13204, 13260, 13308, 13361, 13366, 13387, 13436, 13483, 13530, 13558, 13581, 13616, 13668, 13681, 13721, 13778, 13789, 13798, 13847, 13861, 13863, 13906, 13947, 13987, 14008, 14020, 14033, 14042, 14085, 14113, 14115, 14146, 14237, 14260, 14269, 14304, 14306, 14365, 14394, 14416, 14469, 14502, 14535, 14559, 14591, 14593, 14595, 14614, 14631, 14650, 14691, 14745, 14774, 14867, 14905, 14936, 14978, 15018, 15049, 15088, 15126, 15156, 15207, 15244, 15309, 15361, 15411, 15441, 15477, 15513, 15544, 15607, 15669, 15727, 15745, 15780, 15793, 15814, 15816, 15857, 15899, 15931, 16006, 16031, 16049, 16068, 16145, 16221, 16297, 16377, 16413, 16485, 16513, 16517, 16519, 16564, 16596, 16620, 16645, 16663, 16682, 16718, 16760, 16788, 16792, 16794, 16839, 16880, 16893, 16975, 17015, 17072, 17088, 17092, 17148, 17233, 17312, 17388, 17412, 17445, 17478, 17503, 17518, 17550, 17591, 17617, 17643, 17677, 17699, 17704, 17708, 17749, 17790, 17816, 17844, 17859, 17872, 17885 ], "line_end_idx": [ 16, 17, 33, 34, 58, 59, 78, 81, 83, 96, 111, 121, 152, 162, 200, 238, 279, 354, 389, 436, 464, 491, 539, 588, 646, 702, 728, 795, 834, 862, 864, 866, 877, 879, 890, 931, 1002, 1019, 1060, 1083, 1197, 1268, 1319, 1395, 1436, 1505, 1523, 1556, 1573, 1594, 1626, 1673, 1693, 1695, 1710, 1729, 1752, 1793, 1822, 1848, 1850, 1947, 2010, 2052, 2140, 2142, 2183, 2206, 2232, 2289, 2341, 2358, 2375, 2379, 2381, 2483, 2578, 2623, 2720, 2796, 2855, 2905, 2956, 3019, 3084, 3130, 3171, 3180, 3182, 3241, 3300, 3375, 3420, 3440, 3462, 3489, 3491, 3493, 3527, 3567, 3623, 3640, 3668, 3714, 3732, 3734, 3740, 3742, 3782, 3851, 3859, 3870, 3888, 3914, 3925, 3927, 3943, 3945, 3992, 4029, 4092, 4114, 4150, 4152, 4187, 4231, 4250, 4291, 4327, 4396, 4454, 4460, 4500, 4540, 4591, 4669, 4747, 4819, 4835, 4898, 4905, 4920, 4986, 4988, 5075, 5077, 5089, 5091, 5126, 5162, 5182, 5241, 5250, 5269, 5271, 5273, 5275, 5324, 5363, 5375, 5397, 5414, 5418, 5420, 5452, 5472, 5485, 5489, 5519, 5527, 5552, 5554, 5558, 5560, 5597, 5617, 5649, 5662, 5666, 5696, 5704, 5722, 5724, 5728, 5730, 5745, 5773, 5806, 5808, 5848, 5850, 5891, 5912, 5931, 5978, 6010, 6092, 6110, 6112, 6168, 6189, 6240, 6306, 6333, 6347, 6395, 6410, 6412, 6446, 6477, 6497, 6520, 6548, 6581, 6655, 6675, 6692, 6710, 6747, 6749, 6772, 6774, 6815, 6839, 6866, 6965, 7015, 7070, 7093, 7134, 7152, 7217, 7248, 7305, 7350, 7407, 7445, 7481, 7531, 7569, 7595, 7625, 7698, 7748, 7774, 7796, 7880, 7882, 7912, 7952, 7985, 8041, 8053, 8055, 8078, 8113, 8151, 8160, 8162, 8164, 8166, 8202, 8221, 8238, 8261, 8307, 8355, 8389, 8453, 8511, 8529, 8532, 8552, 8575, 8609, 8671, 8745, 8749, 8751, 8776, 8795, 8817, 8847, 8867, 8879, 8881, 8883, 8924, 8978, 9021, 9086, 9163, 9182, 9199, 9219, 9254, 9274, 9289, 9291, 9345, 9413, 9456, 9466, 9489, 9531, 9540, 9554, 9557, 9559, 9600, 9639, 9667, 9727, 9769, 9788, 9823, 9834, 9890, 9984, 9986, 10015, 10042, 10044, 10072, 10097, 10099, 10126, 10155, 10157, 10186, 10262, 10321, 10353, 10490, 10573, 10611, 10613, 10654, 10682, 10712, 10763, 10807, 10826, 10836, 10846, 10874, 10911, 10913, 10957, 10976, 10986, 10996, 11026, 11063, 11065, 11116, 11179, 11194, 11204, 11215, 11261, 11298, 11300, 11356, 11378, 11400, 11410, 11420, 11466, 11503, 11505, 11546, 11567, 11637, 11689, 11710, 11730, 11775, 11819, 11821, 11899, 11947, 12011, 12022, 12058, 12081, 12128, 12134, 12176, 12186, 12196, 12207, 12266, 12277, 12343, 12363, 12383, 12411, 12429, 12454, 12479, 12503, 12510, 12529, 12602, 12604, 12606, 12649, 12695, 12739, 12810, 12812, 12889, 12950, 12964, 13010, 13046, 13081, 13113, 13162, 13204, 13260, 13308, 13361, 13366, 13387, 13436, 13483, 13530, 13558, 13581, 13616, 13668, 13681, 13721, 13778, 13789, 13798, 13847, 13861, 13863, 13906, 13947, 13987, 14008, 14020, 14033, 14042, 14085, 14113, 14115, 14146, 14237, 14260, 14269, 14304, 14306, 14365, 14394, 14416, 14469, 14502, 14535, 14559, 14591, 14593, 14595, 14614, 14631, 14650, 14691, 14745, 14774, 14867, 14905, 14936, 14978, 15018, 15049, 15088, 15126, 15156, 15207, 15244, 15309, 15361, 15411, 15441, 15477, 15513, 15544, 15607, 15669, 15727, 15745, 15780, 15793, 15814, 15816, 15857, 15899, 15931, 16006, 16031, 16049, 16068, 16145, 16221, 16297, 16377, 16413, 16485, 16513, 16517, 16519, 16564, 16596, 16620, 16645, 16663, 16682, 16718, 16760, 16788, 16792, 16794, 16839, 16880, 16893, 16975, 17015, 17072, 17088, 17092, 17148, 17233, 17312, 17388, 17412, 17445, 17478, 17503, 17518, 17550, 17591, 17617, 17643, 17677, 17699, 17704, 17708, 17749, 17790, 17816, 17844, 17859, 17872, 17885, 17942 ] }
{ "red_pajama_v2": { "ccnet_original_length": 17942, "ccnet_original_nlines": 558, "rps_doc_curly_bracket": 0.007914390414953232, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.14123223721981049, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.01914691925048828, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.5199999809265137, "rps_doc_frac_unique_words": 0.6073232293128967, "rps_doc_mean_word_length": 7.2108588218688965, "rps_doc_num_sentences": 292, "rps_doc_symbol_to_word_ratio": 0.15127961337566376, "rps_doc_unigram_entropy": 6.476965427398682, "rps_doc_word_count": 1584, "rps_doc_frac_chars_dupe_10grams": 0.005603219848126173, "rps_doc_frac_chars_dupe_5grams": 0.03081771917641163, "rps_doc_frac_chars_dupe_6grams": 0.03081771917641163, "rps_doc_frac_chars_dupe_7grams": 0.03081771917641163, "rps_doc_frac_chars_dupe_8grams": 0.021187180653214455, "rps_doc_frac_chars_dupe_9grams": 0.011556649580597878, "rps_doc_frac_chars_top_2gram": 0.008755030110478401, "rps_doc_frac_chars_top_3gram": 0.002101209945976734, "rps_doc_frac_chars_top_4gram": 0.011206439696252346, "rps_doc_books_importance": -2094.9560546875, "rps_doc_books_importance_length_correction": -2094.9560546875, "rps_doc_openwebtext_importance": -1076.11279296875, "rps_doc_openwebtext_importance_length_correction": -1076.11279296875, "rps_doc_wikipedia_importance": -704.2142944335938, "rps_doc_wikipedia_importance_length_correction": -704.2142944335938 }, "fasttext": { "dclm": 0.9942623972892761, "english": 0.36464768648147583, "fineweb_edu_approx": 3.175210952758789, "eai_general_math": 0.9970823526382446, "eai_open_web_math": 0.3437883257865906, "eai_web_code": 0.999042272567749 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.133", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "519.5", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Probabilities; or, Mathematical statistics" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "1", "label": "Leftover HTML" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "4", "label": "Advanced Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "5", "label": "Exceptionally Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,621,865,982,294,955,000
Mach v0.2 has been released! For all the details check out the announcement GPU error handling Asynchronous nature GPUs have largely asynchronous APIs: you build up a command buffer which encodes a number of commands instructing the GPU to do something, and then you ask the GPU to execute that buffer of commands. As a result, errors must be handled asynchronously as well. try isn’t going to work here. Error scopes WebGPU has a concept of error scopes, you can push an error scope onto the stack and pop an error scope. Commands that produce errors while the error scope was on the stack will result in that error scope’s callback being invoked. Let’s look at a concrete example: Catching a shader compilation error // Push a validation error scope, so that if compiling the shader fails we'll // be able to handle that error. core.device().pushErrorScope(.validation); // Compile our fragment shader. var fs_module = core.device().createShaderModuleWGSL("my fragment shader", fragment_shader_code); // Pop our error scope. If compilation fails then we'll get a callback. var error_occurred: bool = false; _ = core.device().popErrorScope(&error_occurred, struct { inline fn callback(ctx: *bool, typ: gpu.ErrorType, message: [*:0]const u8) void { if (typ != .no_error) { std.debug.print("🔴🔴🔴🔴:\n{s}\n", .{message}); ctx.* = true; } } }.callback); if (error_occurred) { // Our fragment shader failed to compile, so fallback to a different fragment shader. fs_module = core.device().createShaderModuleWGSL( "black_screen_frag.wgsl", @embedFile("black_screen_frag.wgsl"), ); } defer fs_module.release(); Debugging Naming objects At many points, when creating an object there is a label parameter or field you can specify to name an object. This is very useful in debugging, as WebGPU error messages will include the error when pointing at e.g. pipeline validation errors. RenderDoc & other tools You may wish to use RenderDoc and AMD Radeon GPU Profiler or NVIDIA Visual Profiler.
{ "url": "https://machengine.org/engine/gpu/errors/", "source_domain": "machengine.org", "snapshot_id": "CC-MAIN-2023-40", "warc_metadata": { "Content-Length": "11711", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:YISGRRONNBB7ARKRPFO73QQPLVOHPKU3", "WARC-Concurrent-To": "<urn:uuid:38d1baeb-2089-46aa-932c-7b238a686454>", "WARC-Date": "2023-10-02T08:04:17Z", "WARC-IP-Address": "104.21.5.122", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:VBD5HVANXELVBDVYVCNTELM6SGUN2BMT", "WARC-Record-ID": "<urn:uuid:352a4b75-59fc-4140-a0f2-b9fb888b8ddb>", "WARC-Target-URI": "https://machengine.org/engine/gpu/errors/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:4c014a2a-53e9-4279-b671-60a859341a56>" }, "warc_info": "isPartOf: CC-MAIN-2023-40\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September/October 2023\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-67\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 76, 77, 96, 97, 117, 118, 408, 409, 422, 423, 688, 689, 725, 726, 804, 837, 880, 881, 913, 1011, 1012, 1084, 1118, 1176, 1262, 1294, 1351, 1377, 1387, 1393, 1406, 1428, 1518, 1572, 1606, 1652, 1659, 1661, 1688, 1689, 1699, 1700, 1715, 1716, 1959, 1960, 1984, 1985 ], "line_end_idx": [ 76, 77, 96, 97, 117, 118, 408, 409, 422, 423, 688, 689, 725, 726, 804, 837, 880, 881, 913, 1011, 1012, 1084, 1118, 1176, 1262, 1294, 1351, 1377, 1387, 1393, 1406, 1428, 1518, 1572, 1606, 1652, 1659, 1661, 1688, 1689, 1699, 1700, 1715, 1716, 1959, 1960, 1984, 1985, 2069 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2069, "ccnet_original_nlines": 48, "rps_doc_curly_bracket": 0.005799899809062481, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.29197078943252563, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.014598540030419827, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.26520681381225586, "rps_doc_frac_unique_words": 0.5802919864654541, "rps_doc_mean_word_length": 5.5766425132751465, "rps_doc_num_sentences": 36, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.796056747436523, "rps_doc_word_count": 274, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.032722510397434235, "rps_doc_frac_chars_top_3gram": 0.01047119963914156, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -199.7794647216797, "rps_doc_books_importance_length_correction": -199.7794647216797, "rps_doc_openwebtext_importance": -98.03782653808594, "rps_doc_openwebtext_importance_length_correction": -98.03782653808594, "rps_doc_wikipedia_importance": -90.3438720703125, "rps_doc_wikipedia_importance_length_correction": -90.3438720703125 }, "fasttext": { "dclm": 0.13276106119155884, "english": 0.6644479036331177, "fineweb_edu_approx": 2.548443555831909, "eai_general_math": 0.8863553404808044, "eai_open_web_math": 0.09297841787338257, "eai_web_code": 0.9839650392532349 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.0285", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.457", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-3,663,370,303,781,481,500
non persistent flash drives non persistent flash drives non persistent flash drives for deleted photo recovery non persistent flash drives for quick format,full format,accidentally formatted from Windows 10,Windows 7,Windows 8 PC.   Use "Undelete" recover deleted files for non persistent flash drives . Use "Unformat" mode for non persistent flash drives after quick format,full format,accidentally formatted,reformatting,High-level formatting,Low-level formatting. Use "Recover partition" for non persistent flash drives to recover deleted files partitions changed or damaged or deleted. Use "Full Scan" for non persistent flash drives from partitions show as "raw" or which can not be found with "undelete" or "Unformat" or "Recover partition" ,recover files from raw partition,recover files of partitons which are not NTFS,nor exfat,nor fat32. support deep and full scan lost data from sd card partition , hard drive, usb. "non persistent flash drives",This guide to VDI storage looks at the fundamentals of VDI storage and how to specify storage for likely workloads and persistent versus non-persistent desktops.  · I upgraded 2 ESXi hosts from 4.1 to 5.5. Now they are both showing the following waring: System Logs on Host are stored on non-persistent storage. Both A flash solid state drive (SSD) is a non-volatile storage device that stores persistent data in flash memory.  · Storage touches everything from the data center to your iPhone. A key trend: Solid state drive adoption. Key players: EMC, NetApp, Seagate, Sandisk and … Designed for applications that are sensitive to down time and require high performance to enable frequent access to large data sets, NVDIMMs combine the speed of DRAM This definition explains the meaning of non-volatile memory (NVM) and outlines the advantages and disadvantages of different types of NVM technology. This article is written like a manual or guidebook. Please help rewrite this article from a descriptive, neutral point of view, and remove advice or instruction. We enrolled patients with persistent, moderate-to-severe asthma and a blood eosinophil count of at least 300 cells per microliter or a sputum eosinophil level of at This topic provides guidance on how to choose drives for Storage Spaces Direct to meet your performance and capacity requirements. Storage Spaces Direct features a Problems with USB drives There are many possible problems with USB drives. Here are some problems and solutions: Troubleshooting for USB drives Aidfile Format Recovery Software Keyfeature Support Windows 10,Windows XP,2003,2008,2012,7,8,8.1,Vista. MS Office document (Word, Excel, PowerPoint, Outlook) types (doc, docx, ppt, pptx, xls, xlsx, pst, etc.),photos (JPG, PNG, ICON, TIF, BMP, RAF, CR2, etc.), videos and audios (MPG, MP4, MP3, MTS, M2TS, 3GP, AVI, MOV, RM, RMVB, etc.), compressed files (rar, zip, etc.), PE files (exe, dll, lib, etc.) and so on. non persistent flash drives 1. Select the "Recover Partition " or "unformat" or "undelete" or "full scan". 2. Select the drive, then click the "NEXT" button. 3. Set the format recovery properties . 4. Select the want to recover files . 5. Recover successful ,
{ "url": "http://formatdriverecovery.com/pages4/non-persistent-flash-drives.html", "source_domain": "formatdriverecovery.com", "snapshot_id": "crawl=CC-MAIN-2018-05", "warc_metadata": { "Content-Length": "9311", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:E34FBJGYXMAOJS4C4W72PPHDE5EBKS4Y", "WARC-Concurrent-To": "<urn:uuid:86676aa5-5616-4b77-83d9-e0f433a786da>", "WARC-Date": "2018-01-18T17:48:51Z", "WARC-IP-Address": "208.113.187.58", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:6EJKOJEM536AVL3F5RKPCINECVBRFGVU", "WARC-Record-ID": "<urn:uuid:ff6c60eb-ed9f-4b91-85d3-4b411f6b582e>", "WARC-Target-URI": "http://formatdriverecovery.com/pages4/non-persistent-flash-drives.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:e3c9f44c-4463-4b48-b486-f9a0556e3dab>" }, "warc_info": "robots: classic\r\nhostname: ip-10-181-213-23.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-05\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for January 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 28, 29, 57, 58, 113, 114, 234, 235, 237, 238, 309, 310, 473, 474, 597, 598, 935, 936, 1128, 1283, 1393, 1550, 1717, 1867, 2029, 2194, 2358, 2502, 2503, 2547, 2548, 2608, 2609, 2919, 2920, 2948, 2949, 3028, 3029, 3080, 3081, 3121, 3122, 3160, 3161 ], "line_end_idx": [ 28, 29, 57, 58, 113, 114, 234, 235, 237, 238, 309, 310, 473, 474, 597, 598, 935, 936, 1128, 1283, 1393, 1550, 1717, 1867, 2029, 2194, 2358, 2502, 2503, 2547, 2548, 2608, 2609, 2919, 2920, 2948, 2949, 3028, 3029, 3080, 3081, 3121, 3122, 3160, 3161, 3184 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3184, "ccnet_original_nlines": 45, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2348484843969345, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05454545095562935, "rps_doc_frac_lines_end_with_ellipsis": 0.021739130839705467, "rps_doc_frac_no_alph_words": 0.2651515305042267, "rps_doc_frac_unique_words": 0.5408805012702942, "rps_doc_mean_word_length": 5.2809224128723145, "rps_doc_num_sentences": 37, "rps_doc_symbol_to_word_ratio": 0.0015151499537751079, "rps_doc_unigram_entropy": 5.142591953277588, "rps_doc_word_count": 477, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.08336641639471054, "rps_doc_frac_chars_dupe_6grams": 0.028582770377397537, "rps_doc_frac_chars_dupe_7grams": 0.028582770377397537, "rps_doc_frac_chars_dupe_8grams": 0.028582770377397537, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.051607780158519745, "rps_doc_frac_chars_top_3gram": 0.07145693153142929, "rps_doc_frac_chars_top_4gram": 0.08574830740690231, "rps_doc_books_importance": -272.5251159667969, "rps_doc_books_importance_length_correction": -272.5251159667969, "rps_doc_openwebtext_importance": -135.04763793945312, "rps_doc_openwebtext_importance_length_correction": -135.04763793945312, "rps_doc_wikipedia_importance": -126.88453674316406, "rps_doc_wikipedia_importance_length_correction": -126.88453674316406 }, "fasttext": { "dclm": 0.060590509325265884, "english": 0.830687940120697, "fineweb_edu_approx": 1.7168278694152832, "eai_general_math": 0.027886809781193733, "eai_open_web_math": 0.07992637157440186, "eai_web_code": 0.0537070594727993 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.6", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.72", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "6", "label": "Promotional/Advertisement" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "17", "label": "Product Page" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
7,446,203,498,328,818,000
blob: 3dde96557c038bb5584f55abe4cc478a5fd6030d [file] [log] [blame] /* { dg-do run } */ /* { dg-require-effective-target avx } */ /* { dg-options "-O2 -mavx" } */ #include "avx-check.h" #ifndef MASK #define MASK 214 #endif #define mask_v(pos) (((MASK & (0x1 << (pos))) >> (pos)) << 31) void static avx_test (void) { int i; int m[4] = {mask_v(0), mask_v(1), mask_v(2), mask_v(3)}; float s[4] = {1,2,3,4}; union128 src; union128i_d mask; float e[4] = {0.0}; float d[4] = {0.0}; src.x = _mm_loadu_ps (s); mask.x = _mm_loadu_si128 ((__m128i *)m); _mm_maskstore_ps (d, mask.x, src.x); for (i = 0 ; i < 4; i++) e[i] = m[i] ? s[i] : 0; if (checkVf (d, e, 4)) abort (); }
{ "url": "https://gnu.googlesource.com/gcc/+/cd2fd5facb5e1882d3f338ed456ae9536f7c0593/gcc/testsuite/gcc.target/i386/avx-vmaskmovps-2.c", "source_domain": "gnu.googlesource.com", "snapshot_id": "CC-MAIN-2024-33", "warc_metadata": { "Content-Length": "15857", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:VKGMTHBKT7YZCG5TMNW72QXXXHKRH5PV", "WARC-Concurrent-To": "<urn:uuid:186a4726-6247-4542-9303-1bfb67124cf1>", "WARC-Date": "2024-08-06T04:53:12Z", "WARC-IP-Address": "142.250.31.82", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:D5GWL5TQADBNCLTCP377A23ZTJLQQ6PX", "WARC-Record-ID": "<urn:uuid:738d3316-e5d8-4cae-aa40-568e7e213702>", "WARC-Target-URI": "https://gnu.googlesource.com/gcc/+/cd2fd5facb5e1882d3f338ed456ae9536f7c0593/gcc/testsuite/gcc.target/i386/avx-vmaskmovps-2.c", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:74cd1329-e37b-4a1f-b758-3b695a1935d2>" }, "warc_info": "isPartOf: CC-MAIN-2024-33\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for August 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-36\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 68, 88, 130, 163, 186, 199, 216, 223, 286, 298, 314, 316, 323, 380, 404, 418, 436, 456, 476, 502, 543, 580, 605, 629, 652, 662 ], "line_end_idx": [ 68, 88, 130, 163, 186, 199, 216, 223, 286, 298, 314, 316, 323, 380, 404, 418, 436, 456, 476, 502, 543, 580, 605, 629, 652, 662, 663 ] }
{ "red_pajama_v2": { "ccnet_original_length": 663, "ccnet_original_nlines": 26, "rps_doc_curly_bracket": 0.024132730439305305, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.11637931317090988, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.017241379246115685, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.6336206793785095, "rps_doc_frac_unique_words": 0.7721518874168396, "rps_doc_mean_word_length": 4.7848100662231445, "rps_doc_num_sentences": 9, "rps_doc_symbol_to_word_ratio": 0.021551720798015594, "rps_doc_unigram_entropy": 4.011863708496094, "rps_doc_word_count": 79, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0, "rps_doc_frac_chars_top_3gram": 0, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -146.26327514648438, "rps_doc_books_importance_length_correction": -154.085205078125, "rps_doc_openwebtext_importance": -99.28263092041016, "rps_doc_openwebtext_importance_length_correction": -107.10456848144531, "rps_doc_wikipedia_importance": -58.53841781616211, "rps_doc_wikipedia_importance_length_correction": -66.3603515625 }, "fasttext": { "dclm": 0.9697386026382446, "english": 0.20712228119373322, "fineweb_edu_approx": 3.23419451713562, "eai_general_math": 0.5103181004524231, "eai_open_web_math": 0.2274700403213501, "eai_web_code": 0.036044660955667496 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-4,261,306,567,258,390,000
Sublime Forum Folder groups - multiple paths for folders #1 here’s a reasonably complex project blah@notebook:~/desktops/d2/project$ tree -a . ├── project.sublime-project ├── v1 │ ├── a │ │ └── v1_a │ ├── b │ │ └── v2_b │ └── c ├── v2 │ ├── a │ ├── b │ │ └── v2_b │ └── c │ └── test_c └── .workspace └── w1 - project.sublime-workspace and this is the workspace i want something like this Screenshot%20from%202020-08-10%2002-08-05 and this Screenshot%20from%202020-08-10%2002-18-45 currently i think there’s no direct way of achieving this behaviour (am i missing something?). i’m using symlinks for creating the groups (or filters if the targets are files). ├── .symlinks │ ├── all_a │ │ ├── v1a -> ../../v1/a │ │ └── v2a -> ../../v2/a │ └── all_a_files │ └── v1_a -> ../../v1/a/v1_a Screenshot%20from%202020-08-10%2002-29-15 can we get extra options like target_folder or target_files like we have for include/exclude patterns. also, maybe the behaviour of path can be changed to include multiple folders, thus creating a sort of group. Screenshot%20from%202020-08-10%2002-45-09 Screenshot%20from%202020-08-10%2002-35-53 0 Likes
{ "url": "https://forum.sublimetext.com/t/folder-groups-multiple-paths-for-folders/53163", "source_domain": "forum.sublimetext.com", "snapshot_id": "crawl=CC-MAIN-2020-40", "warc_metadata": { "Content-Length": "11915", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:Q52ZFG524G3SY6WHOTJSOY6CY6UGWR2F", "WARC-Concurrent-To": "<urn:uuid:053c8cf6-2dff-4eb1-9ba8-9395d15a3cb0>", "WARC-Date": "2020-09-30T10:35:00Z", "WARC-IP-Address": "104.236.208.78", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:QRBTHO2QSJL2QDOHGQVPQ5MGVIDZYHCX", "WARC-Record-ID": "<urn:uuid:273fcf56-bd47-4939-9165-1a5c7192cbc5>", "WARC-Target-URI": "https://forum.sublimetext.com/t/folder-groups-multiple-paths-for-folders/53163", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:412a1d55-ca46-4750-bf22-6a2923f0864f>" }, "warc_info": "isPartOf: CC-MAIN-2020-40\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-235.ec2.internal\r\nsoftware: Apache Nutch 1.17 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 14, 15, 58, 59, 62, 63, 99, 100, 145, 147, 175, 182, 192, 209, 219, 236, 246, 253, 263, 273, 290, 300, 319, 334, 373, 374, 400, 401, 428, 470, 479, 521, 522, 699, 700, 714, 728, 758, 788, 808, 844, 845, 887, 888, 991, 992, 1101, 1185, 1186 ], "line_end_idx": [ 14, 15, 58, 59, 62, 63, 99, 100, 145, 147, 175, 182, 192, 209, 219, 236, 246, 253, 263, 273, 290, 300, 319, 334, 373, 374, 400, 401, 428, 470, 479, 521, 522, 699, 700, 714, 728, 758, 788, 808, 844, 845, 887, 888, 991, 992, 1101, 1185, 1186, 1193 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1193, "ccnet_original_nlines": 49, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2283737063407898, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.5051903128623962, "rps_doc_frac_unique_words": 0.5454545617103577, "rps_doc_mean_word_length": 5.181818008422852, "rps_doc_num_sentences": 12, "rps_doc_symbol_to_word_ratio": 0.0034602100495249033, "rps_doc_unigram_entropy": 4.079496383666992, "rps_doc_word_count": 165, "rps_doc_frac_chars_dupe_10grams": 0.042105261236429214, "rps_doc_frac_chars_dupe_5grams": 0.042105261236429214, "rps_doc_frac_chars_dupe_6grams": 0.042105261236429214, "rps_doc_frac_chars_dupe_7grams": 0.042105261236429214, "rps_doc_frac_chars_dupe_8grams": 0.042105261236429214, "rps_doc_frac_chars_dupe_9grams": 0.042105261236429214, "rps_doc_frac_chars_top_2gram": 0.042105261236429214, "rps_doc_frac_chars_top_3gram": 0.023391809314489365, "rps_doc_frac_chars_top_4gram": 0.014035089872777462, "rps_doc_books_importance": -124.0727767944336, "rps_doc_books_importance_length_correction": -124.0727767944336, "rps_doc_openwebtext_importance": -56.989933013916016, "rps_doc_openwebtext_importance_length_correction": -56.97515106201172, "rps_doc_wikipedia_importance": -42.659828186035156, "rps_doc_wikipedia_importance_length_correction": -42.659828186035156 }, "fasttext": { "dclm": 0.5692539811134338, "english": 0.5871366858482361, "fineweb_edu_approx": 1.726770043373108, "eai_general_math": 0.8293817043304443, "eai_open_web_math": 0.01871245913207531, "eai_web_code": 0.9281107783317566 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.435", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,684,646,263,872,029,000
Legacy Documentation: Version 2018.1 (Go to current version) Memory Profiler Physics Profiler Other Versions Audio Profiler In the Profiler window there is a pane called Audio. The pane monitors significant performance meters about the audio system, such as total load and voice counts. When you highlight the pane, the lower part of the window changes into a detailed view about various parts of the audio system not covered by the graphs. • Playing Sources is the total playing sources in the scene at a specific frame. Monitor this to see if audio is overloaded. • Paused Sources is the total paused sources in the scene at a specific frame. • Audio Voice is the actually number of audio (FMOD channels) voices used. PlayOneShot is using voices not shown in Playing Sources. • Audio Memory is the total RAM used by the audio engine. CPU usage can be seen in the bottom. Monitor this to see if Audio alone is taking up too much CPU. Click the Channels, Groups or Channels and groups buttons for detailed per-frame logging of sound events. Here these events can be obtained and scrubbed, just like the renderer and memory graphs. The rows in the frame log reveal information such as which audio sources played which clips, the volume at which they were played, the distance to the listener, and relative playback time. Clicking on one of these rows highlights the associated audio source and clip in the Project browser and Hierarchy window. Channel view. When clicking a row the AudioClip Asset is highlighted first, then the AudioSource in the Hierarchy that played it. Channels and groups view. Here the AudioSource that played the sound in the selected row is highlighted. Did you find this page useful? Please give it a rating: Memory Profiler Physics Profiler
{ "url": "https://docs.unity3d.com/2018.1/Documentation/Manual/ProfilerAudio.html", "source_domain": "docs.unity3d.com", "snapshot_id": "crawl=CC-MAIN-2021-10", "warc_metadata": { "Content-Length": "12994", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:GZVTC4VBHOE4CLCLPIDBNPCKPZQNBPZ2", "WARC-Concurrent-To": "<urn:uuid:8a734284-5a82-42ec-ad6e-9173f9f52286>", "WARC-Date": "2021-02-28T19:02:17Z", "WARC-IP-Address": "104.199.36.179", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:JVFBCCBCK5C2RDWXMDZAXLKI5PW6EWR6", "WARC-Record-ID": "<urn:uuid:0257be92-9a7d-4aa7-9848-0781b29ec2bc>", "WARC-Target-URI": "https://docs.unity3d.com/2018.1/Documentation/Manual/ProfilerAudio.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ce9fbf38-8a55-41aa-ab1a-87a3e440fc5c>" }, "warc_info": "isPartOf: CC-MAIN-2021-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February/March 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-119.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 61, 77, 94, 109, 110, 125, 126, 443, 444, 571, 652, 787, 847, 848, 947, 948, 1144, 1145, 1457, 1458, 1588, 1589, 1694, 1695, 1751, 1752, 1768 ], "line_end_idx": [ 61, 77, 94, 109, 110, 125, 126, 443, 444, 571, 652, 787, 847, 848, 947, 948, 1144, 1145, 1457, 1458, 1588, 1589, 1694, 1695, 1751, 1752, 1768, 1784 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1784, "ccnet_original_nlines": 27, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3875739574432373, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.011834319680929184, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.12426035851240158, "rps_doc_frac_unique_words": 0.47999998927116394, "rps_doc_mean_word_length": 4.769999980926514, "rps_doc_num_sentences": 22, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.540956020355225, "rps_doc_word_count": 300, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.07826694846153259, "rps_doc_frac_chars_dupe_6grams": 0.07826694846153259, "rps_doc_frac_chars_dupe_7grams": 0.046121589839458466, "rps_doc_frac_chars_dupe_8grams": 0.046121589839458466, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.02795247919857502, "rps_doc_frac_chars_top_3gram": 0.020964359864592552, "rps_doc_frac_chars_top_4gram": 0.04053109884262085, "rps_doc_books_importance": -126.09078979492188, "rps_doc_books_importance_length_correction": -119.90618896484375, "rps_doc_openwebtext_importance": -68.93647003173828, "rps_doc_openwebtext_importance_length_correction": -68.93647003173828, "rps_doc_wikipedia_importance": -54.91920852661133, "rps_doc_wikipedia_importance_length_correction": -53.66230392456055 }, "fasttext": { "dclm": 0.2536693811416626, "english": 0.9319733381271362, "fineweb_edu_approx": 3.1491146087646484, "eai_general_math": 0.7531453371047974, "eai_open_web_math": 0.16116678714752197, "eai_web_code": 0.5468398332595825 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.0285", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "781.2", "labels": { "level_1": "Arts", "level_2": "Music", "level_3": "Music theory" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
4,842,382,059,320,235,000
Tuesday, November 17, 2009 MacOSX - yet another average Linux distribution Already for some time I have known that I am physically incompatible with Microsoft's products, including Windows operating system. For years I blamed Microsoft for it, but it was only a while ago when I started to realize that there must be something wrong with me. After all, there are many people who use Microsoft's software day by day and are happy with it, it's just me who is able to crash vanilla WinXP in 5 minutes after the first boot. One way or another, I can't use Windows. I have been a devoted Linux user for 10 years, but this only means I know it's shortcomings all too well. I can say I've had enough of it for a while, especially after the last upgrade, when my fonts started to disappear pixel by pixel. And since my good old IBM T42 needed a replacement anyway, I decided to by a MacBook Pro. I have numerous colleagues who have switched to Mac more or less recently, and all of them share a common characteristic -- they are all happy about their computer. So I thought I might get happy as well. I was wrong. Of course I had done my homework. I knew that some older versions of MacOSX shipped with a non-standard Estonian keymap, e.g missing the circumflex symbol (^) badly needed for TeX typesetting. I had some hope that this would have been fixed in Snow Leopard, but I was of course too optimistic. Luckily, I have a good friend and colleague, a long time Mac-happee Sven Laur, who pointed me towards a keymap modification tool called Ukelele. That did the trick. So far so good. Another peculiarity of MacOSX I was somewhat prepared for was the absence of a decent package management system. Of course, it is very convenient to install programs by just dragging them to the Applications directory, and later uninstall by dragging them onto the trash bin. But what happens if the package does not really contain an executable program? For example, when looking for a solution for my above-mentioned problem, I found an Estonian keymap prepackaged for MacOSX on the Estonian Mac user forum. After downloading and installing, it of course turned out that it was packaged for some older version of the OS and that the old keymaps do not work any more. Oh well, let's try something else and uninstall this one first ... but uninstalling something that was not dragged onto the Applications directory turned out to be impossible! I asked for help from our local Mac store and the canonical way of resolving this issue was just deleting one file from the file system. But what happens if there are more files spread around everywhere, configuration files, dependencies ..? Steve only knows. Then all of a sudden, the lot-advertised 3- and 4-finger trackpad gestures stopped working. I did some forum digging and it turned out that this was a known bug that can be resolved by logging out and back in again. Indeed it was. Is this the standard way of work of an operating system that is born ready? I don't know. You tell me. But my latest-and-the-worst experience on MacOSX is connected to the fonts. I knew that it was very hard to change the fonts that Mac designers have chosen for you. I asked about this issue from our local Mac store before buying my laptop. The guy behind the desk did some googling (!) and calmed me down saying that there exists something called TinkerTool, a program that reveals some hidden configuration options, including font configuration. Since my eyes get tired quite fast when I need to read small fonts, I downloaded the tool and tried turning every single font listed there to 14pt. The only visible difference was increase in the window title text, everything else remained the same! Yes, some applications allow increasing some fonts independently of the system settings. So I was able to play with the display font of Safari and text output field of Skype, but not with the Safari UI font nor Skype's text input field! The worst of all is Thunderbird with the UI font so ridiculously small that it hurts. Browsing the forums reminded me of the good old times under Linux some 5 years ago, when one manually had to change the contents of userChrome.css file. I searched for it -- no such file exists in Thunderbird distribution for MacOSX as of the end of 2009. I created it in the correct directory, but it did not have any effect. And by the way -- I did not buy a Mac to start fiddling with the configuration files by hand! Oh well. There are many other things to tell about (how Cyberduck FTP client hanged so badly that it even blocked shutdown, or how you have to go through 32 (thirty-two) easy steps in order to get MSN working under iChat), but I guess it is a good time to end this post here. What can I say in conclusion? MacOSX really does not work out-of-the-box, and as such, it is as good as your average Linux distribution. It's only that exactly half of the Linux distributions are above the average. Wednesday, November 11, 2009 Sülearvutid ja hinded Mul on hea meel tõdeda, et nähtus, mis mulle juba üsna tükk aega ilmne on tundunud, aga millest Eestis eriti popp rääkida ei ole, on lõpuks ometi ametliku uuringu läbi konnitust leidnud: (süle)arvutite kasutamine ei paranda õpilaste hindeid. Seejuures langevad õppetulemised kõige enam just võõrkeelte osas. Ei, ma ei arva, et arvuti kui selline põhimõtteliselt paha oleks, meie haridussüsteemis usutakse lihtsalt tema automaagilisse imetegemisvõimesse -- anname läpaka lapsele kätte ning siis ei peagi rohkem midagi tegema. Peab ikka küll. Loeme tähelepanelikult, mida ütles Eesti Vabariigi president Toomas-Hendrik Ilves "Tagasi kooli" päeva raames tundi pidades: Tänu sellele, et meil oli õpetaja, kes nii noorelt õpetas meile programmeerimist, hakkasin ma 1993. või 1994. aastal mõtlema, et kui meie saime nii noorelt programmeerimisega hakkama, siis miks ei võiks me Eesti lastele arvutit õpetada ja nii tekkis Tiigrihüppe seeme. PROGRAMMEERIMIST. Mitte rate'i. Mitte youtube'i. Mitte kontoripakette. Programmeerimist. 9. klassis. Targad onud ja tädid õppekavade arendajad, mõelge selelle! How to make money Getting rich in three easy steps: 1. Become Google 2. Start selling text ad space 3. Sell the space to anyone who pays What if you sell ad space to parties with conflicting interests? It's not really a problem as long as they pay :) (For the people who do not understand Russian -- the lower ad advertises an anti-spam product.)  
{ "url": "http://janwillemson.blogspot.com/2009/11/", "source_domain": "janwillemson.blogspot.com", "snapshot_id": "crawl=CC-MAIN-2018-17", "warc_metadata": { "Content-Length": "43435", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:YZH3NS2FQGSZEKHXB5A2IGPBLKEYC23K", "WARC-Concurrent-To": "<urn:uuid:15ea535c-dce8-4e1e-afe7-4acecd0d93e5>", "WARC-Date": "2018-04-22T20:19:26Z", "WARC-IP-Address": "216.58.218.225", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:7RKMVKBDO3Q3Y5QKTOIJX5CAAQAPN7NC", "WARC-Record-ID": "<urn:uuid:268d961f-dfdc-4182-b037-b6e402109b54>", "WARC-Target-URI": "http://janwillemson.blogspot.com/2009/11/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:5c6d905c-a600-4481-a201-15731f2f2d22>" }, "warc_info": "robots: classic\r\nhostname: ip-10-113-239-22.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-17\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for April 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 27, 28, 76, 77, 523, 524, 802, 803, 1098, 1099, 1112, 1113, 1588, 1589, 1944, 1945, 2695, 2696, 3030, 3031, 3478, 3479, 3729, 3730, 4474, 4475, 4888, 4889, 4967, 4968, 4997, 4998, 5020, 5021, 5329, 5330, 5331, 5548, 5549, 5565, 5566, 5691, 5692, 5961, 5962, 6122, 6123, 6141, 6142, 6176, 6195, 6228, 6267, 6381, 6382, 6478, 6479 ], "line_end_idx": [ 27, 28, 76, 77, 523, 524, 802, 803, 1098, 1099, 1112, 1113, 1588, 1589, 1944, 1945, 2695, 2696, 3030, 3031, 3478, 3479, 3729, 3730, 4474, 4475, 4888, 4889, 4967, 4968, 4997, 4998, 5020, 5021, 5329, 5330, 5331, 5548, 5549, 5565, 5566, 5691, 5692, 5961, 5962, 6122, 6123, 6141, 6142, 6176, 6195, 6228, 6267, 6381, 6382, 6478, 6479, 6480 ] }
{ "red_pajama_v2": { "ccnet_original_length": 6480, "ccnet_original_nlines": 57, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3987730145454407, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03220859169960022, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.14647239446640015, "rps_doc_frac_unique_words": 0.48636364936828613, "rps_doc_mean_word_length": 4.710000038146973, "rps_doc_num_sentences": 73, "rps_doc_symbol_to_word_ratio": 0.0007668699836358428, "rps_doc_unigram_entropy": 5.755885124206543, "rps_doc_word_count": 1100, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.0077205197885632515, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.004825320094823837, "rps_doc_frac_chars_top_3gram": 0.009264620020985603, "rps_doc_frac_chars_top_4gram": 0.006176409777253866, "rps_doc_books_importance": -548.5023803710938, "rps_doc_books_importance_length_correction": -548.5023803710938, "rps_doc_openwebtext_importance": -246.27383422851562, "rps_doc_openwebtext_importance_length_correction": -246.27383422851562, "rps_doc_wikipedia_importance": -103.34245300292969, "rps_doc_wikipedia_importance_length_correction": -103.34245300292969 }, "fasttext": { "dclm": 0.05424100160598755, "english": 0.8948479890823364, "fineweb_edu_approx": 1.4312978982925415, "eai_general_math": 0.5357738137245178, "eai_open_web_math": 0.3720436692237854, "eai_web_code": 0.2788541316986084 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "004.019", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "5", "label": "Evaluate" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "9", "label": "Personal/Misc" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "16", "label": "Personal Blog" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
1,219,858,889,180,103,400
How can a general user trace the origin of TCP/IP data generated by persistent e-mail anomaly? Tags: .NET application security computer information Forensic analysis malware Malware detection TCP/IP Webmail Thank you very much for taking time to consider this question. What do you recommend for a general user who needs to trace the origin and route of TCP/IP data associated with an e-mail message? My SOHO computer is infected by some form of malware. The ISP's tech support could not resolve it; the relevant "abuse@" site has not responded to a query. For professional reasons, it is important that make a diligent effort to track where any rerouted messages with confidential information may have ended up. I've done what I can with Traceroute and IP Lookup, and sites that provide guidance on tracing e-mails. I'm out of ideas. Background:  The balance of this message provides additional detail that may assist your assessment. I use a stand-alone system that runs both Mac and Windows; the webmail service was provided by an major ISP accessed via a standard router. Indicators:  There three known indicators: (1)  In creating a new e-mail message, the drop-down box in the "From" line generates a second bogus address just below my correct e-mail address; (2) For messages forwarded from my address, the anomaly transmits a duplicate copy of the message to an unknown mail-server. (This was revealed when a message I forwarded with an incorrect address sent back a "Delivery Failed" notification) (3) the ISP tech support staff accessed my system and attributed the anomaly to "spyware."  When they could not remove the anomaly, they referred me to their "abuse@" site.T hat entity provided an automated response 10 days ago, and nothing since. Status:  To date, I have used the IP address generated by the return notice to identify public IP addresses. Test messages sent to the bogus e-mail address (which drops down from the From line) returned header information that identified the "original recipient" as an unknown UserID and mail server. Whois searches from several sites reported that the UserID and Host Name are "not found" or are non-existent. Before giving up, I'd like to know if there are other open source tools or tracing methods that a user with no training in computer forensics should try and can use reliably. Best, PS: Please forgive my use of a pseudonym. But as a sole practitioner, this experience has left me gun shy about e-mail and submissions to websites. For the time being, I've switched to a more secure web-mail service and take other precautions that seem to make sense.   Software/Hardware used: Use both Mac and Windows with Parallels. Answer Wiki Thanks. We'll let you know when a new response is added. TCP reset attack, also known as forged TCP resets, spoofed TCP reset packets or TCP reset attacks. These terms refer to a method of tampering with internet communications. Sometimes, the tampering is malicious, other times, it is beneficial. The Internet is, in essence, a system for individual computers to exchange electronic messages, or packets of IP data Discuss This Question: 3  Replies   There was an error processing your information. Please try again later. Thanks. We'll let you know when a new response is added. Send me notifications when members answer or reply to this question. REGISTER or login: Forgot Password? By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy • Genderhayes TCP starts a re-transmission timer when each outbound segment is handed down to IP. If no acknowledgment has been received for the data in a given segment before the timer expires, then the segment is retransmitted, up to the TcpMaxDataRetransmissions times 6,525 pointsBadges: report • Troubleshoot2014 Very helpful. Thanks. Does anyone know of a tool or process for resolving a reset attack e.g. a link to a methodology 15 pointsBadges: report • Genderhayes A stealth scan is a kind of scan that is designed to go undetected by auditing tools stealth scanning technique is “inverse mapping”, where you try to find out all hosts on a network by generating “host unreachable” ICMP-messages for those IPs that do not exist. Since these messages may be generated by any TCP/IP packet one may send meaningless packets 6,525 pointsBadges: report Forgot Password No problem! Submit your e-mail address below. We'll send you an e-mail containing your password. Your password has been sent to: To follow this tag... There was an error processing your information. Please try again later. REGISTER or login: Forgot Password? By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy Thanks! We'll email you when relevant content is added and updated. Following
{ "url": "http://itknowledgeexchange.techtarget.com/itanswers/tracing-the-origin-route-of-tcpip-data-to-resolve-suspected-spoofing-of-an-e-mail-address/", "source_domain": "itknowledgeexchange.techtarget.com", "snapshot_id": "crawl=CC-MAIN-2014-23", "warc_metadata": { "Content-Length": "83557", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:PRBS7RAPODUEWYZTME2JDJC4HUXH6AIU", "WARC-Concurrent-To": "<urn:uuid:42205253-93af-48ff-aba3-8599220f9283>", "WARC-Date": "2014-07-26T16:42:52Z", "WARC-IP-Address": "206.19.49.161", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:CWFJMMBQHQOWXTC6SDVJZVG6FHHVHDSO", "WARC-Record-ID": "<urn:uuid:bb0d2601-4c3d-4a5a-bf9b-5029e2b6bf03>", "WARC-Target-URI": "http://itknowledgeexchange.techtarget.com/itanswers/tracing-the-origin-route-of-tcpip-data-to-resolve-suspected-spoofing-of-an-e-mail-address/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:0e9dc856-9005-4ece-af27-171c694b8e8a>" }, "warc_info": "robots: classic\r\nhostname: ip-10-33-131-23.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-23\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for July 2014\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 95, 96, 102, 128, 149, 167, 175, 193, 200, 208, 836, 837, 1078, 1079, 1758, 1759, 2345, 2351, 2352, 2620, 2622, 2623, 2624, 2648, 2689, 2690, 2702, 2703, 2760, 2761, 3121, 3122, 3156, 3157, 3159, 3231, 3288, 3357, 3358, 3377, 3378, 3395, 3614, 3630, 3892, 3916, 3927, 3948, 4070, 4091, 4102, 4118, 4477, 4501, 4512, 4513, 4529, 4530, 4627, 4628, 4660, 4661, 4683, 4684, 4756, 4757, 4776, 4777, 4794, 5013, 5014, 5082, 5083 ], "line_end_idx": [ 95, 96, 102, 128, 149, 167, 175, 193, 200, 208, 836, 837, 1078, 1079, 1758, 1759, 2345, 2351, 2352, 2620, 2622, 2623, 2624, 2648, 2689, 2690, 2702, 2703, 2760, 2761, 3121, 3122, 3156, 3157, 3159, 3231, 3288, 3357, 3358, 3377, 3378, 3395, 3614, 3630, 3892, 3916, 3927, 3948, 4070, 4091, 4102, 4118, 4477, 4501, 4512, 4513, 4529, 4530, 4627, 4628, 4660, 4661, 4683, 4684, 4756, 4757, 4776, 4777, 4794, 5013, 5014, 5082, 5083, 5092 ] }
{ "red_pajama_v2": { "ccnet_original_length": 5092, "ccnet_original_nlines": 73, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.37140020728111267, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03674279898405075, "rps_doc_frac_lines_end_with_ellipsis": 0.01351351011544466, "rps_doc_frac_no_alph_words": 0.16385303437709808, "rps_doc_frac_unique_words": 0.4579780697822571, "rps_doc_mean_word_length": 4.924482345581055, "rps_doc_num_sentences": 54, "rps_doc_symbol_to_word_ratio": 0.0009930500527843833, "rps_doc_unigram_entropy": 5.459006309509277, "rps_doc_word_count": 821, "rps_doc_frac_chars_dupe_10grams": 0.1538461446762085, "rps_doc_frac_chars_dupe_5grams": 0.1538461446762085, "rps_doc_frac_chars_dupe_6grams": 0.1538461446762085, "rps_doc_frac_chars_dupe_7grams": 0.1538461446762085, "rps_doc_frac_chars_dupe_8grams": 0.1538461446762085, "rps_doc_frac_chars_dupe_9grams": 0.1538461446762085, "rps_doc_frac_chars_top_2gram": 0.0029680898878723383, "rps_doc_frac_chars_top_3gram": 0.01484046969562769, "rps_doc_frac_chars_top_4gram": 0.008409599773585796, "rps_doc_books_importance": -510.4756164550781, "rps_doc_books_importance_length_correction": -510.4756164550781, "rps_doc_openwebtext_importance": -314.4040832519531, "rps_doc_openwebtext_importance_length_correction": -314.4040832519531, "rps_doc_wikipedia_importance": -260.5210266113281, "rps_doc_wikipedia_importance_length_correction": -260.5210266113281 }, "fasttext": { "dclm": 0.06543278694152832, "english": 0.931645393371582, "fineweb_edu_approx": 1.6113953590393066, "eai_general_math": 0.04822837933897972, "eai_open_web_math": 0.1609574556350708, "eai_web_code": 0.021105889230966568 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.82", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.67", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
5,513,942,509,143,154,000
loading Step 7: Conclusion I hope you have found this instructable useful, as it should provide you with the code you need to get I2C working nicely. I spent a long time trying to fathom the Adafruit I2C Library out, before realising that these simple commands are all that I need. The basic read and write commands are functions in my provided code, so that should see you through.  <p>Now here is a question from a newb who wants to get into I2C on the Pi.</p><p>The provided page (http://www.robot-electronics.co.uk/htm/srf08tech.html) says that this comes with default address 0xE0 and it is modifiable to 0xFE with increments of 0x02. But the pi only supports up to 0x78. How does that work?</p> <p>(Step 6 sensor)</p> <p>Oh man, Thank you so much for this instructable! Your tutorial was short and to the point, while remaining sufficient for my applications.<br><br>Thank you so much!</p> <p>I am just learning i2c, thanks a lot for your info, but for the price of the i2c rangefinders I think I will stick with HC-SR04 Ultrasound Wave Detector Range Ultrasonic Sensor Distance Module for just over $1 each and use i2c for the i2c sensors.</p> <p>thanks, very usefull. just wonder if i'm able to communicate with a pcf8574 or mcp23017 i/o expander now.</p> <p>How did you get your nano that cool green color?</p> <p>Where do I find the SDA and SCL lines on my Pi</p> <p>you can find them on pin 3 and 5, 3 is the SDA and the SCL is the 5th pin</p> <p>For the 512mb of ram USE </p><p>i2cdetect -y 1</p><p>instead of the other.</p> <p>Thank you! I've been trouble shooting for almost an hour and was about to give up when i saw your post. I thought I had killed my BMP180 while soldering it or that it was broke for some other reason. =)</p> Awesome! <p>Same goes for the Pi 2, which is also a B+.</p> <p>A good ible - another great example would be connecting MCP23008 or MCP23017 chips and controlling them either via python-smbus (by sending bytes to registers) or via wiringpi2 (high level driver providing setup routines and an abstraction layer).</p> <p>Please forgive a complete noob commenting here but, as I read more and more <br>on I2C, the noobier I'm getting. </p><p>What's got me confused is how to connect, for example, several SRF08 Range Sensors. <br>Presumably they all have the same address (0x70) so confusion reigns, right? I <br>suspect you can only connect devices that have different addresses which, if <br>I'm right, severely limits the usefulness of I2C. </p><p>Am I right and is there a cost-effective way around this limitation?</p><p>P.S. I'm relatively new to all this hardware stuff. I'm retired now but was a mainframe programmer who has since discovered Python and loves it.</p> <p>You can configure the address that the SRF08 uses, there a 16 possibles, <br> meaning you could use up to 16 SRF08's on one bus. Scroll down on this <br> page to see how http://www.robot-electronics.co.uk/htm/srf08tech.shtml</p> <p>There is a very simplai I2C level shifter that will save your port. </p><p>see for example http://playground.arduino.cc/Main/I2CBi-directionalLevelShifter, you will probably have the pull up resistors on the boards anyway so you probaly just need the two FETs. </p> <p>If I use another sensor for example IMU breakout-LSM9DSO, What is the change in the python file?</p> <p>Great bit of info got my almost totally unrelated project working as you had all the important stuff</p> <p>very easy explanation... I easily get confused with Rpi tutorials on web but this one is an exception....</p><p> thank you sir... @</p><p><a href="http://www.instructables.com/member/AntMan232/" rel="nofollow">AntMan232</a></p> <p>as a lurker who is considering a pi for all sorts of nefarious purposes, I find this very helpful!</p> What purpose does the write(0x51) provide? Is it just activating the module on the i2c bus so values can be read from it? <p>0x51 is the write register to command data returned in centimeter vales. 0x50 commands values in inches and 0x52 commands values in microseconds (flight time.</p><p>See <a href="http://spaces.atmel.com/gf/download/frsrelease/228/1344/SRF08%20Ultra%20sonic%20range%20finder.pdf" rel="nofollow">http://spaces.atmel.com/gf/download/frsrelease/228/1344/SRF08%20Ultra%20sonic%20range%20finder.pdf</a></p> <p>TNX for the great instruction but 1 question </p><p>i didn't understand if the 5V i2c device has damaged your device or not , </p> When you do: <br> <br> bear2 = bus.read_byte_data(address, 3) <br> bear = (bear1 &lt;&lt; 8) + bear2 <br> bear = bear/10.0 <br> return bear.... <br>why do you divide by 10? I am assuming you have a signed 15 bit number and you are getting rid of the last 0? Why not use &gt;&gt; 1? <br/> I could only run i2cdetect with the command &quot;sudo i2cdetect -y 0&quot; <br>Otherwise it would not run.. Hey, AntMan. Should you be so inclined, a similar article on how to get i2s (much different than i2c functionally) working on Raspberry Pi would be enormously appreciated. I'd like to attach a Wolfson audio codec but getting up to the configuration point where I could basically do that and begin talking to it is daunting to say the least. Thank You! To make this 'bile better, you might explain in step 1 what I2C is for. Ah, whoops, thanks!<br> Would the external GPS cable for a generic Android tablet or an old XM radio possibly work? I have a couple of those that I might be able to part with if they could be made to work. As a supplement, I have a similar write-up that I buried perhaps a little too deep on the eLinux wiki: <br> <br>http://elinux.org/RPi_Tutorial_EGHS:Communicating_With_Other_Micro-controllers <br> <br>Includes: the official (probably overkill) way of interfacing 3.3V and 5V I2C applications, software for a few languages, and kernel considerations. <br> <br>Range sensor sounds fun, I'll give that a try! Thanks for a very straight forward step by step explanation! all we need now is gps and radar. and viola we are ai nav.. kewl. let me know when you get GPS up and running.. <br> <br> If you give me a GPS module, I will gladly oblige. :D If only I had the money... Thanks for sharing this,it means i could use my temperature sensors Thanks guys, it's nice to be able to help! It geniunely took me about a week to realise that the Adafruit code was overkill, and that it only took one line to read over i2c... Nice and clean examples! You have a new follower. Thanks for sharing this. This will surely come in handy. About This Instructable 598,098views 365favorites License: More by AntMan232:PICAXE Raspberry Pi ADCRaspberry Pi I2C (Python)Arduino stepper motor and servos shield - AW GCSE Board Add instructable to:
{ "url": "http://www.instructables.com/id/Raspberry-Pi-I2C-Python/step7/Conclusion/", "source_domain": "www.instructables.com", "snapshot_id": "crawl=CC-MAIN-2016-22", "warc_metadata": { "Content-Length": "62761", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:PF3WTSO5E6VPUTMVTF5AOMWLUHGDZQB6", "WARC-Concurrent-To": "<urn:uuid:37a24314-720d-47dd-b146-196aca656a1c>", "WARC-Date": "2016-05-28T09:56:47Z", "WARC-IP-Address": "23.235.39.129", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:W4QLQUA5XWPSFTYQG3CBMWY7QGYWGTRS", "WARC-Record-ID": "<urn:uuid:82d26e2c-8253-426e-998a-36cd3c16d4f0>", "WARC-Target-URI": "http://www.instructables.com/id/Raspberry-Pi-I2C-Python/step7/Conclusion/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:4409f2c3-886a-443b-8b4c-9bc289ef6285>" }, "warc_info": "robots: classic\r\nhostname: ip-10-185-217-139.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-22\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for May 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 8, 9, 28, 29, 386, 703, 726, 898, 1153, 1266, 1322, 1376, 1457, 1539, 1749, 1758, 1809, 2064, 2720, 2952, 3221, 3325, 3433, 3664, 3770, 3892, 4295, 4429, 4711, 4717, 4826, 5167, 5178, 5250, 5274, 5456, 5861, 5922, 6044, 6125, 6193, 6369, 6419, 6476, 6477, 6501, 6502, 6515, 6516, 6529, 6530, 6539, 6540, 6662 ], "line_end_idx": [ 8, 9, 28, 29, 386, 703, 726, 898, 1153, 1266, 1322, 1376, 1457, 1539, 1749, 1758, 1809, 2064, 2720, 2952, 3221, 3325, 3433, 3664, 3770, 3892, 4295, 4429, 4711, 4717, 4826, 5167, 5178, 5250, 5274, 5456, 5861, 5922, 6044, 6125, 6193, 6369, 6419, 6476, 6477, 6501, 6502, 6515, 6516, 6529, 6530, 6539, 6540, 6662, 6682 ] }
{ "red_pajama_v2": { "ccnet_original_length": 6682, "ccnet_original_nlines": 54, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.38069218397140503, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.04432300850749016, "rps_doc_frac_lines_end_with_ellipsis": 0.0363636389374733, "rps_doc_frac_no_alph_words": 0.25804492831230164, "rps_doc_frac_unique_words": 0.4813084006309509, "rps_doc_mean_word_length": 4.746728897094727, "rps_doc_num_sentences": 93, "rps_doc_symbol_to_word_ratio": 0.003642990021035075, "rps_doc_unigram_entropy": 5.656948566436768, "rps_doc_word_count": 1070, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.003937779925763607, "rps_doc_frac_chars_top_3gram": 0.0035439999774098396, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -792.2621459960938, "rps_doc_books_importance_length_correction": -792.2621459960938, "rps_doc_openwebtext_importance": -483.34344482421875, "rps_doc_openwebtext_importance_length_correction": -483.34344482421875, "rps_doc_wikipedia_importance": -333.929931640625, "rps_doc_wikipedia_importance_length_correction": -333.929931640625 }, "fasttext": { "dclm": 0.09965019673109055, "english": 0.9072011113166809, "fineweb_edu_approx": 1.5294055938720703, "eai_general_math": 0.6920327544212341, "eai_open_web_math": 0.30699342489242554, "eai_web_code": 0.1200639009475708 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "621.392", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Engineering", "level_3": "Mechanical engineering and Machinery" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "5", "label": "Comment Section" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
3,762,365,932,920,422,400
NetBSD-Bugs archive [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index] kern/42348: lookup protocol use in do_sys_rename() is wrong >Number: 42348 >Category: kern >Synopsis: lookup protocol use in do_sys_rename() is wrong >Confidential: no >Severity: non-critical >Priority: medium >Responsible: kern-bug-people >State: open >Class: sw-bug >Submitter-Id: net >Arrival-Date: Thu Nov 19 18:05:00 +0000 2009 >Originator: Antti Kantee >Release: >Organization: oh no! more fail systems. >Environment: >Description: do_sys_rename() induces the final VOP_LOOKUP() for a file server twice. This causes confusion in file system drivers, since they cannot e.g. allocate a memory slot without it being overridden by the next lookup (alternative is some weird heuristics where the driver attempts to detect the pattern). What rename should arguably do is VOP_ABORTOP() right after the first one. However, this is difficult since then the "real" lookup gets done without SAVESTART. Also, performing the first lookup without SAVESTART is difficult, since then HASBUF may not get set correctly, i.e. the pathname buffer is lost. >How-To-Repeat: >Fix: Home | Main Index | Thread Index | Old Index
{ "url": "http://mail-index.netbsd.org/netbsd-bugs/2009/11/19/msg014467.html", "source_domain": "mail-index.netbsd.org", "snapshot_id": "crawl=CC-MAIN-2016-40", "warc_metadata": { "Content-Length": "4964", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:XMRT2CV6T3ACYST27XAETRYQQMWI2ODP", "WARC-Concurrent-To": "<urn:uuid:e8bba5ab-d510-4ec5-8914-8bccf57a6b8e>", "WARC-Date": "2016-10-01T00:35:17Z", "WARC-IP-Address": "199.233.217.205", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:7XDBPPF5LR5TMOH34WREW4BVHYOOFBYA", "WARC-Record-ID": "<urn:uuid:b6397afc-b4ff-4881-a6d2-7c7e03adb62e>", "WARC-Target-URI": "http://mail-index.netbsd.org/netbsd-bugs/2009/11/19/msg014467.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:030eaecf-7039-408e-b2a3-9d58529c340b>" }, "warc_info": "robots: classic\r\nhostname: ip-10-143-35-109.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-40\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for September 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 20, 21, 107, 108, 168, 169, 170, 171, 194, 216, 281, 301, 331, 355, 388, 410, 434, 455, 503, 533, 551, 566, 593, 607, 621, 686, 751, 814, 881, 921, 922, 992, 1059, 1118, 1180, 1229, 1245, 1246, 1252, 1253, 1254, 1255 ], "line_end_idx": [ 20, 21, 107, 108, 168, 169, 170, 171, 194, 216, 281, 301, 331, 355, 388, 410, 434, 455, 503, 533, 551, 566, 593, 607, 621, 686, 751, 814, 881, 921, 922, 992, 1059, 1118, 1180, 1229, 1245, 1246, 1252, 1253, 1254, 1255, 1299 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1299, "ccnet_original_nlines": 42, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.23616236448287964, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.0184501800686121, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.34317344427108765, "rps_doc_frac_unique_words": 0.7650602459907532, "rps_doc_mean_word_length": 5.668674468994141, "rps_doc_num_sentences": 12, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.676555156707764, "rps_doc_word_count": 166, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.07863973826169968, "rps_doc_frac_chars_dupe_6grams": 0.07863973826169968, "rps_doc_frac_chars_dupe_7grams": 0.07863973826169968, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.02975557930767536, "rps_doc_frac_chars_top_3gram": 0.03613176941871643, "rps_doc_frac_chars_top_4gram": 0.04038257151842117, "rps_doc_books_importance": -122.9143295288086, "rps_doc_books_importance_length_correction": -122.9143295288086, "rps_doc_openwebtext_importance": -63.84610366821289, "rps_doc_openwebtext_importance_length_correction": -63.84610366821289, "rps_doc_wikipedia_importance": -48.94601058959961, "rps_doc_wikipedia_importance_length_correction": -48.946006774902344 }, "fasttext": { "dclm": 0.02109902910888195, "english": 0.8157275915145874, "fineweb_edu_approx": 2.306065320968628, "eai_general_math": 0.1836620569229126, "eai_open_web_math": 0.6666758060455322, "eai_web_code": 0.12531709671020508 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.62", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "4", "label": "Analyze" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
4,613,854,284,617,615,000
Royal Panda roulette Author Topic: understand what is the worst spin sequence that can ruin your system.  (Read 2925 times) 0 Members and 1 Guest are viewing this topic. weird Gentlemen, with respect, This my last Topic, [therefore will retire my self from any forum.] Please read below quotes by two respected gentlemen of gambling. Hang them on your wall, and read a million time. ==================================== It is not the house edge that can not be surpassed. Progressive betting is meant for that only. It is indeed variance that empties both flat bettors as well as progressive bettors and virtual limits that you can get of variance momentarily is unbeatable with any progressive betting. Quote by Albalaha. ===================================== "In short, instead of counting your profit, try to identify and understand what is the worst spin sequence that can ruin your system. This is much more useful information." quote by KAV ============================= We always read, people posting of how they trying to beat roulette with whatever method and strategy that they devised,  BUT seldom, [or never?], read about why and how a strategy fail and the remedy. Thus let me start the ball roll, and u may add in your opinion. Why that system fail? =========================== Martingale [marthy] Simply because of long sleep that depleted the bankroll or table limit. But many kind of progression, simply a stretch marthy. But if we wait for very long sleep, and then hope the 'horrible-variance',  wont repeat,  we MAY win, but as soon as we LOSE once,  we depleted our BR and need to suffer,  chicken feed win, to set-off the huge losses,  and if we suffer TWICE losses, in a day, that the end. ================================= Labourche [Labby] 33%plus one more win. Any less than that will suffer huge progressing losses. Thus if we wait for a virtual losses, then only we bet, hoping that horrible variance wont repeat soon, we may win. But then again, if TWICE losses in row, then that the end for the BR. =========================== Parlay for X time. then again we lose when the X wont happen, and we keep waiting and betting parlaying till the BR depleted. ========================================== Oscar pluscoup. Then again, after the horrible variance, the horrible may hit again, till the BR dried. ================================================= Flatbet. Then again, wait after a 'horrible', the flat just fall flat at the face.. =============================== then someone say, "wait for a horrible",  "No!" the other says wait for "DOUBLE horrible", then the other says "That will  a life-time wait...!" ========= Well Gentlemen, What say U? Thanks.   december So, you're quitting roulette. or just forum posting? Good luck anyway!   Reyth Re: understand what is the worst spin sequence that can ruin your system. « Reply #2 on: September 26, 2016, 08:46:52 PM » Asuming your desired target will pay off the debt, is the worst sequence defined as: The sequence with the longest successive misses before your desired target hits Or can there be a worse session that is hiding in the statistical output? Since only losses/misses can hurt us, I don't see how there can be anything worse than as defined above? Obviously if our desired target does NOT pay off the debt, then we run into successive SERIES of losses that exceed the profit generated by our desired target before profit can be restored. The underlined is the reason I almost gave up on roulette.  The ability to deal with the bolded is the reason I haven't. :D UPDATE:  I just answered my own question!  The worst sequence most certainly does NOT have to be the one with the total most successive misses because losses can cluster together tightly within a smaller number of total losses. I am pretty sure that the worst sequences will always be close in total loss spins though... « Last Edit: September 28, 2016, 01:10:07 AM by Reyth »   dobbelsteen Re: understand what is the worst spin sequence that can ruin your system. « Reply #3 on: September 30, 2016, 08:55:11 PM » Never heard about the SSB method? Noboddy has accepted the challemge to beat SSB. SSB Can be beaten by an event of a sequence of 20 ECs    
{ "url": "https://www.roulettelife.com/index.php/topic,523.0.html", "source_domain": "www.roulettelife.com", "snapshot_id": "crawl=CC-MAIN-2019-30", "warc_metadata": { "Content-Length": "31543", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:B6MUE3YB7JZVXKWVDDH2I5Q4TOMJFKPU", "WARC-Concurrent-To": "<urn:uuid:cc8c8209-a696-44a7-8dd1-fd4024ec6818>", "WARC-Date": "2019-07-22T01:14:55Z", "WARC-IP-Address": "37.60.232.182", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:JJEFNH2FARVBCXPD2JL5L5DCPLCGTIX4", "WARC-Record-ID": "<urn:uuid:60e7e167-866a-49d8-ac46-dd1c6e41f871>", "WARC-Target-URI": "https://www.roulettelife.com/index.php/topic,523.0.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:d0f427ac-61c6-4886-9807-72583bdb2023>" }, "warc_info": "isPartOf: CC-MAIN-2019-30\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-111-193-217.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 21, 22, 125, 126, 172, 173, 179, 180, 191, 205, 206, 226, 274, 275, 340, 389, 390, 427, 711, 730, 768, 769, 942, 955, 985, 986, 1017, 1053, 1106, 1132, 1187, 1188, 1252, 1253, 1275, 1303, 1304, 1324, 1325, 1354, 1397, 1398, 1453, 1454, 1490, 1529, 1543, 1585, 1625, 1672, 1714, 1728, 1729, 1763, 1781, 1782, 1804, 1860, 1861, 1899, 1917, 1965, 1977, 1993, 2047, 2075, 2076, 2095, 2202, 2245, 2246, 2262, 2303, 2350, 2400, 2409, 2446, 2484, 2516, 2517, 2558, 2608, 2662, 2663, 2673, 2689, 2701, 2702, 2710, 2712, 2713, 2722, 2723, 2776, 2777, 2795, 2797, 2798, 2804, 2805, 2879, 2928, 3013, 3014, 3094, 3095, 3169, 3170, 3275, 3276, 3466, 3467, 3591, 3592, 3820, 3821, 3914, 3970, 3972, 3973, 3985, 3986, 4060, 4109, 4143, 4144, 4192, 4193, 4247, 4248, 4250, 4251 ], "line_end_idx": [ 21, 22, 125, 126, 172, 173, 179, 180, 191, 205, 206, 226, 274, 275, 340, 389, 390, 427, 711, 730, 768, 769, 942, 955, 985, 986, 1017, 1053, 1106, 1132, 1187, 1188, 1252, 1253, 1275, 1303, 1304, 1324, 1325, 1354, 1397, 1398, 1453, 1454, 1490, 1529, 1543, 1585, 1625, 1672, 1714, 1728, 1729, 1763, 1781, 1782, 1804, 1860, 1861, 1899, 1917, 1965, 1977, 1993, 2047, 2075, 2076, 2095, 2202, 2245, 2246, 2262, 2303, 2350, 2400, 2409, 2446, 2484, 2516, 2517, 2558, 2608, 2662, 2663, 2673, 2689, 2701, 2702, 2710, 2712, 2713, 2722, 2723, 2776, 2777, 2795, 2797, 2798, 2804, 2805, 2879, 2928, 3013, 3014, 3094, 3095, 3169, 3170, 3275, 3276, 3466, 3467, 3591, 3592, 3820, 3821, 3914, 3970, 3972, 3973, 3985, 3986, 4060, 4109, 4143, 4144, 4192, 4193, 4247, 4248, 4250, 4251, 4252 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4252, "ccnet_original_nlines": 132, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.38598576188087463, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.035629451274871826, "rps_doc_frac_lines_end_with_ellipsis": 0.007518799975514412, "rps_doc_frac_no_alph_words": 0.20308789610862732, "rps_doc_frac_unique_words": 0.44525545835494995, "rps_doc_mean_word_length": 4.417518138885498, "rps_doc_num_sentences": 48, "rps_doc_symbol_to_word_ratio": 0.004750589840114117, "rps_doc_unigram_entropy": 5.267826080322266, "rps_doc_word_count": 685, "rps_doc_frac_chars_dupe_10grams": 0.08063449710607529, "rps_doc_frac_chars_dupe_5grams": 0.08063449710607529, "rps_doc_frac_chars_dupe_6grams": 0.08063449710607529, "rps_doc_frac_chars_dupe_7grams": 0.08063449710607529, "rps_doc_frac_chars_dupe_8grams": 0.08063449710607529, "rps_doc_frac_chars_dupe_9grams": 0.08063449710607529, "rps_doc_frac_chars_top_2gram": 0.011566420085728168, "rps_doc_frac_chars_top_3gram": 0.016523459926247597, "rps_doc_frac_chars_top_4gram": 0.025115659460425377, "rps_doc_books_importance": -300.9496765136719, "rps_doc_books_importance_length_correction": -300.9496765136719, "rps_doc_openwebtext_importance": -246.78370666503906, "rps_doc_openwebtext_importance_length_correction": -246.78370666503906, "rps_doc_wikipedia_importance": -151.98948669433594, "rps_doc_wikipedia_importance_length_correction": -151.98948669433594 }, "fasttext": { "dclm": 0.050680991262197495, "english": 0.9127020835876465, "fineweb_edu_approx": 1.509660243988037, "eai_general_math": 0.2875860929489136, "eai_open_web_math": 0.4715496301651001, "eai_web_code": 0.0183216892182827 } }
{ "free_decimal_correspondence": { "primary": { "code": "519.5", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Probabilities; or, Mathematical statistics" } }, "secondary": { "code": "794.24", "labels": { "level_1": "Arts", "level_2": "Amusements and Recreation", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "4", "label": "Analyze" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "5", "label": "Comment Section" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
2,021,384,245,209,038,800
InvalidOperationException – Das Objekt wird bereits an anderer Stelle verwendet Heute hatte ich einen Fehler in meinem Programm beim Zugriff auf ein Bitmap von einem Hintergrund-Thread aus: InvalidOperationException – Das Objekt wird bereits an anderer Stelle verwendet. Auf Englisch: InvalidOperationException – object is currently in use elsewhere. Die Ursache ist ein Zugriff von mehreren Threads aus auf dasselbe Bitmap-Objekt. Auf Stack Overflow schreibt Hans Passant die Lösung: There’s a lock inside GDI+ that prevents two threads from accessing a bitmap at the same time. This is not a blocking kind of lock, it is a „programmer did something wrong, I’ll throw an exception“ kind of lock. Your threads are bombing because you are cloning the image (== accessing a bitmap) in all threads. Your UI thread is bombing because it is trying to draw the bitmap (== accessing a bitmap) at the same time a thread is cloning it. You’ll need to restrict access to the bitmap to only one thread. Clone the images in the UI thread before you start the BGWs, each BGW needs its own copy of the image. Update the PB’s Image property in the RunWorkerCompleted event. You’ll lose some concurrency this way but that’s unavoidable. Ich muss also sicherstellen, dass auf ein Bild-Objekt nur von einem Thread aus zugegriffen wird.
{ "url": "https://entwicklergate.de/t/invalidoperationexception-das-objekt-wird-bereits-an-anderer-stelle-verwendet/57", "source_domain": "entwicklergate.de", "snapshot_id": "crawl=CC-MAIN-2019-39", "warc_metadata": { "Content-Length": "12924", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:6UNMOC5H3YO74J2R7RMJ5MRVVUQFBRYU", "WARC-Concurrent-To": "<urn:uuid:eccde0d6-39e0-4040-9e21-72a83e6c6535>", "WARC-Date": "2019-09-17T03:15:23Z", "WARC-IP-Address": "18.184.22.200", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:HJ7RKBKBPBF4UZRCA5N54D6775KEIHAR", "WARC-Record-ID": "<urn:uuid:aaab7320-e62c-4650-9a81-fe8252cf9cd8>", "WARC-Target-URI": "https://entwicklergate.de/t/invalidoperationexception-das-objekt-wird-bereits-an-anderer-stelle-verwendet/57", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:67f10559-07b1-44aa-b24f-f7813e4e5929>" }, "warc_info": "isPartOf: CC-MAIN-2019-39\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-61.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 80, 81, 191, 192, 273, 274, 288, 289, 355, 356, 437, 438, 491, 492, 934, 935, 1229, 1230 ], "line_end_idx": [ 80, 81, 191, 192, 273, 274, 288, 289, 355, 356, 437, 438, 491, 492, 934, 935, 1229, 1230, 1326 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1326, "ccnet_original_nlines": 18, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.31128403544425964, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.023346299305558205, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.14785991609096527, "rps_doc_frac_unique_words": 0.5727699398994446, "rps_doc_mean_word_length": 5.037558555603027, "rps_doc_num_sentences": 12, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.571780204772949, "rps_doc_word_count": 213, "rps_doc_frac_chars_dupe_10grams": 0.13047529757022858, "rps_doc_frac_chars_dupe_5grams": 0.1845293641090393, "rps_doc_frac_chars_dupe_6grams": 0.1845293641090393, "rps_doc_frac_chars_dupe_7grams": 0.1845293641090393, "rps_doc_frac_chars_dupe_8grams": 0.13047529757022858, "rps_doc_frac_chars_dupe_9grams": 0.13047529757022858, "rps_doc_frac_chars_top_2gram": 0.07269337773323059, "rps_doc_frac_chars_top_3gram": 0.04473438858985901, "rps_doc_frac_chars_top_4gram": 0.06523764878511429, "rps_doc_books_importance": -99.69944763183594, "rps_doc_books_importance_length_correction": -99.69944763183594, "rps_doc_openwebtext_importance": -46.317623138427734, "rps_doc_openwebtext_importance_length_correction": -46.317623138427734, "rps_doc_wikipedia_importance": -32.16975021362305, "rps_doc_wikipedia_importance_length_correction": -32.16917419433594 }, "fasttext": { "dclm": 0.10331559181213379, "english": 0.2488892674446106, "fineweb_edu_approx": 2.367173194885254, "eai_general_math": 0.11422938108444214, "eai_open_web_math": 0.34181755781173706, "eai_web_code": 0.9406154155731201 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.67", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "16", "label": "Personal Blog" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-1,385,523,637,926,541,000
Skip to content local-ch/lhs Repository files navigation LHS LHS ia a Rails-Gem, providing an ActiveRecord like interface to access HTTP-JSON-Services from Rails Applications. Special features provided by this gem are: Multiple endpoint configuration per resource, active-record-like query-chains, scopes, error handling, relations, request cycle cache, batch processing, including linked resources (hypermedia), data maps (data accessing), nested-resource handling, ActiveModel like backend validation conversion, formbuilder-compatible, three types of pagination support, service configuration per resource, kaminari-support and much more. LHS uses LHC for advanced http requests. Quickstart gem 'lhs' # config/initializers/lhc.rb LHC.configure do |config| config.placeholder(:service, 'https://my.service.dev') end # app/models/record.rb class Record < LHS::Record endpoint '{+service}/records' endpoint '{+service}/records/{id}' end # app/controllers/application_controller.rb record = Record.find_by(email: 'somebody@mail.com') record.review # "Lunch was great Table of contents Installation/Startup checklist • Install LHS gem, preferably via Gemfile • Configure LHC via an config/initializers/lhc.rb (See: https://github.com/local-ch/lhc#configuration) • Add LHC::Caching to LHC.config.interceptors to facilitate LHS' Request Cycle Cache • Store all LHS::Records in app/models for autoload/preload reasons • Request data from services via LHS from within your rails controllers Record Endpoints Endpoint, the entry point to a service, a process, a queue or a topic in a service-oriented architecture Start a record with configuring one or multiple endpoints. # app/models/record.rb class Record < LHS::Record endpoint '{+service}/records' endpoint '{+service}/records/{id}' endpoint '{+service}/accociation/{accociation_id}/records' endpoint '{+service}/accociation/{accociation_id}/records/{id}' end You can also add request options to be used with configured endpoints: # app/models/record.rb class Record < LHS::Record endpoint '{+service}/records', auth: { bearer: -> { access_token } } endpoint '{+service}/records/{id}', auth: { bearer: -> { access_token } } end -> Check LHC for more information about request options Configure endpoint hosts It's common practice to use different hosts accross different environments in a service-oriented architecture. Use LHC placeholders to configure different hosts per environment: # config/initializers/lhc.rb LHC.configure do |config| config.placeholder(:search, ENV['SEARCH']) end # app/models/record.rb class Record < LHS::Record endpoint '{+search}/api/search.json' end DON'T! Please DO NOT mix host placeholders with and endpoint's resource path, as otherwise LHS will not work properly. # config/initializers/lhc.rb LHC.configure do |config| config.placeholder(:search, 'http://tel.search.ch/api/search.json') end # app/models/record.rb class Record < LHS::Record endpoint '{+search}' end Endpoint Priorities LHS uses endpoint configurations to determine what endpoint to use when data is requested, in a similar way, routes are identified in Rails to map requests to controllers. If they are ambiguous, LHS will always use the first one found: # app/models/record.rb class Record < LHS::Record endpoint '{+service}/records' endpoint '{+service}/bananas' end # app/controllers/some_controller.rb Record.fetch GET https://service.example.com/records Be aware that, if you configure ambiguous endpoints across multiple classes, the order of things is not deterministic. Ambiguous endpoints across multiple classes need to be avoided. Provider Providers in LHS allow you to group shared endpoint options under a common provider. # app/models/provider/base_record.rb module Provider class BaseRecord < LHS::Record provider params: { api_key: 123 } end end Now every record, part of that particular provider can inherit the provider's BaseRecord. # app/models/provider/account.rb module Provider class Account < BaseRecord endpoint '{+host}/records' endpoint '{+host}/records/{id}' end end # app/controllers/some_controller.rb Provider::Account.find(1) GET https://provider/records/1?api_key=123 And requests made via those provider records apply the common provider options. Record inheritance You can inherit from previously defined records and also inherit endpoints that way: # app/models/base.rb class Base < LHS::Record endpoint '{+service}/records/{id}' end # app/models/record.rb class Record < Base end # app/controllers/some_controller.rb Record.find(1) GET https://service.example.com/records/1 Find multiple records fetch In case you want to just fetch the records endpoint, without applying any further queries or want to handle pagination, you can simply call fetch: # app/controllers/some_controller.rb records = Record.fetch GET https://service.example.com/records where You can query a service for records by using where: # app/controllers/some_controller.rb Record.where(color: 'blue') GET https://service.example.com/records?color=blue If the provided parameter – color: 'blue' in this case – is not part of the endpoint path, it will be added as query parameter. # app/controllers/some_controller.rb Record.where(accociation_id: '12345') GET https://service.example.com/accociation/12345/records If the provided parameter – accociation_id in this case – is part of the endpoint path, it will be injected into the path. You can also provide hrefs to fetch multiple records: # app/controllers/some_controller.rb Record.where('https://service.example.com/accociation/12345/records') GET https://service.example.com/accociation/12345/records Reuse/Dry where statements: Use scopes In order to reuse/dry where statements organize them in scopes: # app/models/record.rb class Record < LHS::Record endpoint '{+service}/records' endpoint '{+service}/records/{id}' scope :blue, -> { where(color: 'blue') } scope :available, ->(state) { where(available: state) } end # app/controllers/some_controller.rb records = Record.blue.available(true) GET https://service.example.com/records?color=blue&available=true all You can fetch all remote records by using all. Pagination will be performed automatically (See: Record pagination) # app/controllers/some_controller.rb records = Record.all GET https://service.example.com/records?limit=100 GET https://service.example.com/records?limit=100&offset=100 GET https://service.example.com/records?limit=100&offset=200 # app/controllers/some_controller.rb records.size # 300 all with unpaginated endpoints In case your record endpoints are not implementing any pagination, configure it to be paginated: false. Pagination will not be performed automatically in those cases: # app/models/record.rb class Record < LHS::Record configuration paginated: false end # app/controllers/some_controller.rb records = Record.all GET https://service.example.com/records Retrieve the amount of a collection of items: count vs. length The different behavior of count and length is based on ActiveRecord's behavior. count The total number of items available remotly via the provided endpoint/api, communicated via pagination meta data. length The number of items already loaded from the endpoint/api and kept in memory right now. In case of a paginated endpoint this can differ to what count returns, as it depends on how many pages have been loaded already. Find single records find find finds a unique record by unique identifier (usually id or href). If no record is found an error is raised. Record.find(123) GET https://service.example.com/records/123 Record.find('https://anotherservice.example.com/records/123') GET https://anotherservice.example.com/records/123 find can also be used to find a single unique record with parameters: Record.find(another_identifier: 456) GET https://service.example.com/records?another_identifier=456 You can also fetch multiple records by id in parallel: Record.find(1, 2, 3) # In parallel: GET https://service.example.com/records/1 GET https://service.example.com/records/2 GET https://service.example.com/records/3 find_by find_by finds the first record matching the specified conditions. If no record is found, nil is returned. find_by! raises LHC::NotFound if nothing was found. Record.find_by(color: 'blue') GET https://service.example.com/records?color=blue first first is an alias for finding the first record without parameters. If no record is found, nil is returned. first! raises LHC::NotFound if nothing was found. Record.first GET https://service.example.com/records?limit=1 first can also be used with options: Record.first(params: { color: :blue }) GET https://service.example.com/records?color=blue&limit=1 last last is an alias for finding the last record without parameters. If no record is found, nil is returned. last! raises LHC::NotFound if nothing was found. Record.last last can also be used with options: Record.last(params: { color: :blue }) Work with retrieved data After fetching single or multiple records you can navigate the received data with ease: records = Record.where(color: 'blue') records.length # 4 records.count # 400 record = records.first record.type # 'Business' record[:type] # 'Business' record['type'] # 'Business' Automatic detection/conversion of collections How to configure endpoints for automatic collection detection? LHS detects automatically if the responded data is a single business object or a set of business objects (collection). Conventionally, when the respons contains an items key { items: [] } it's treated as a collection, but also if the respons contains a plain raw array: [{ href: '' }] it's also treated as a collection. If you need to configure the attribute of the response providing the collection, configure items_key as explained here: Determine collections from the response body Map complex data for easy access To influence how data is accessed, simply create methods inside your Record to access complex data structures: # app/models/record.rb class Record < LHS::Record endpoint '{+service}/records' def name dig(:addresses, :first, :business, :identities, :first, :name) end end Access and identify nested records Nested records, in nested data, are automatically casted to the correct Record class, when they provide an href and that href matches any defined endpoint of any defined Record: # app/models/place.rb class Place < LHS::Record endpoint '{+service}/places' endpoint '{+service}/places/{id}' def name dig(:addresses, :first, :business, :identities, :first, :name) end end # app/models/favorite.rb class Favorite < LHS::Record endpoint '{+service}/favorites' endpoint '{+service}/favorites/{id}' end # app/controllers/some_controller.rb favorite = Favorite.includes(:place).find(123) favorite.place.name # local.ch AG GET https://service.example.com/favorites/123 {... place: { href: 'https://service.example.com/places/456' }} GET https://service.example.com/places/456 If automatic detection of nested records does not work, make sure your Records are stored in app/models! See: Insallation/Startup checklist Relations / Associations Typically nested data is automatically casted when accessed (See: Access and identify nested records), but sometimes API's don't provide dedicated endpoints to retrieve these records. In those cases, those records are only available through other records and don't have an href on their own and can't be casted automatically, when accessed. To be able to implement Record-specific logic for those nested records, you can define relations/associations. has_many # app/models/location.rb class Location < LHS::Record endpoint '{+service}/locations/{id}' has_many :listings end # app/models/listing.rb class Listing < LHS::Record def supported? type == 'SUPPORTED' end end # app/controllers/some_controller.rb Location.find(1).listings.first.supported? # true GET https://service.example.com/locations/1 {... listings: [{ type: 'SUPPORTED' }] } class_name: Specify the class name of the relation. Use it only if that name can't be inferred from the relation name. So has_many :photos will by default be linked to the Photo class, but if the real class name is e.g. CustomPhoto or namespaced Custom::Photo, you'll have to specify it with this option. # app/models/custom/location.rb module Custom class Location < LHS::Record endpoint '{+service}/locations' endpoint '{+service}/locations/{id}' has_many :photos, class_name: 'Custom::Photo' end end # app/models/custom/photo.rb module Custom class Photo < LHS::Record end end has_one # app/models/transaction.rb class Transaction < LHS::Record endpoint '{+service}/transaction/{id}' has_one :user end # app/models/user.rb class User < LHS::Record def email self[:email_address] end end # app/controllers/some_controller.rb Transaction.find(1).user.email_address # steve@local.ch GET https://service.example.com/transaction/1 {... user: { email_address: 'steve@local.ch' } } class_name: Specify the class name of the relation. Use it only if that name can't be inferred from the relation name. So has_many :photos will by default be linked to the Photo class, but if the real class name is e.g. CustomPhoto or namespaced Custom::Photo, you'll have to specify it with this option. # app/models/custom/location.rb module Custom class Location < LHS::Record endpoint '{+service}/locations' endpoint '{+service}/locations/{id}' has_one :photo, class_name: 'Custom::Photo' end end # app/models/custom/photo.rb module Custom class Photo < LHS::Record end end Unwrap nested items from the response body If the actual item data is mixed with metadata in the response body, LHS allows you to configure a record in a way to automatically unwrap items from within nested response data. item_key is used to unwrap the actual object from within the response body. # app/models/location.rb class Location < LHS::Record configuration item_key: [:response, :location] end # app/controllers/some_controller.rb location = Location.find(123) location.id # 123 GET https://service.example.com/locations/123 {... response: { location: { id: 123 } } } Determine collections from the response body items_key key used to determine the collection of items of the current page (e.g. docs, items, etc.), defaults to 'items': # app/models/search.rb class Search < LHS::Record configuration items_key: :docs end # app/controllers/some_controller.rb search_result = Search.where(q: 'Starbucks') search_result.first.address # Bahnhofstrasse 5, 8000 Zürich GET https://service.example.com/search?q=Starbucks {... docs: [... {... address: 'Bahnhofstrasse 5, 8000 Zürich' }] } Load additional data based on retrieved data In order to load linked data from already retrieved data, you can use load! (or reload!). # app/controllers/some_controller.rb record = Record.find(1) record.associated_thing.load! GET https://things/4 { name: "Steve" } # app/controllers/some_controller.rb record.associated_thing.name # Steve record.associated_thing.load! # Does NOT create another request, as it is already loaded record.associated_thing.reload! # Does request the data again from remote GET https://things/4 { name: "Steve" } Chain complex queries Method chaining, also known as named parameter idiom, is a common syntax for invoking multiple method calls in object-oriented programming languages. Each method returns an object, allowing the calls to be chained together without requiring variables to store the intermediate results In order to simplify and enhance preparing complex queries for performing single or multiple requests, LHS implements query chains to find single or multiple records. LHS query chains do lazy evaluation to only perform as many requests as needed, when the data to be retrieved is actually needed. Any method, accessing the content of the data to be retrieved, is resolving the chain in place – like .each, .first, .some_attribute_name. Nevertheless, if you just want to resolve the chain in place, and nothing else, fetch should be the method of your choice: # app/controllers/some_controller.rb Record.where(color: 'blue').fetch Chain where queries # app/controllers/some_controller.rb records = Record.where(color: 'blue') [...] records.where(available: true).each do |record| [...] end GET https://service.example.com/records?color=blue&available=true In case you wan't to check/debug the current values for where in the chain, you can use where_values_hash: records.where_values_hash # {color: 'blue', available: true} Expand plain collections of links: expanded Some endpoints could respond only with a plain list of links and without any expanded data, like search results. Use expanded to have LHS expand that data, by performing necessary requests in parallel: # app/controllers/some_controller.rb Search.where(what: 'Cafe').expanded GET https://service.example.com/search?what=Cafe {... "items" : [ {"href": "https://service.example.com/records/1"}, {"href": "https://service.example.com/records/2"}, {"href": "https://service.example.com/records/3"} ] } In parallel: > GET https://service.example.com/records/1 < {... name: 'Cafe Einstein'} > GET https://service.example.com/records/2 < {... name: 'Starbucks'} > GET https://service.example.com/records/3 < {... name: 'Plaza Cafe'} { ... "items" : [ { "href": "https://service.example.com/records/1", "name": 'Cafe Einstein', ... }, { "href": "https://service.example.com/records/2", "name": 'Starbucks', ... }, { "href": "https://service.example.com/records/3", "name": 'Plaza Cafe', ... } ] } You can also apply request options to expanded. Those options will be used to perform the additional requests to expand the data: # app/controllers/some_controller.rb Search.where(what: 'Cafe').expanded(auth: { bearer: access_token }) Error handling with chains One benefit of chains is lazy evaluation. But that also means they only get resolved when data is accessed. This makes it hard to catch errors with normal rescue blocks: # app/controllers/some_controller.rb def show @records = Record.where(color: blue) # returns a chain, nothing is resolved, no http requests are performed rescue => e # never ending up here, because the http requests are actually performed in the view, when the query chain is resolved end # app/views/some/view.haml = @records.each do |record| # .each resolves the query chain, leads to http requests beeing performed, which might raises an exception = record.name To simplify error handling with chains, you can also chain error handlers to be resolved, as part of the chain. If you need to render some different view in Rails based on an LHS error raised during rendering the view, please proceed as following: # app/controllers/some_controller.rb def show @records = Record .rescue(LHC::Error, ->(error){ rescue_from(error) }) .where(color: 'blue') render 'show' render_error if @error end private def rescue_from(error) @error = error nil end def render_error self.response_body = nil # required to not raise AbstractController::DoubleRenderError render 'error' end > GET https://service.example.com/records?color=blue < 406 In case no matching error handler is found the error gets re-raised. -> Read more about LHC error types/classes If you want to inject values for the failing records, that might not have been found, you can inject values for them with error handlers: # app/controllers/some_controller.rb data = Record .rescue(LHC::Unauthorized, ->(response) { Record.new(name: 'unknown') }) .find(1, 2, 3) data[1].name # 'unknown' In parallel: > GET https://service.example.com/records/1 < 200 > GET https://service.example.com/records/2 < 400 > GET https://service.example.com/records/3 < 200 -> Read more about LHC error types/classes If an error handler returns nil an empty LHS::Record is returned, not nil! In case you want to ignore errors and continue working with nil in those cases, please use ignore: # app/controllers/some_controller.rb record = Record.ignore(LHC::NotFound).find_by(color: 'blue') record # nil Resolve chains: fetch In case you need to resolve a query chain in place, use fetch: # app/controllers/some_controller.rb records = Record.where(color: 'blue').fetch Add request options to a query chain: options You can apply options to the request chain. Those options will be forwarded to the request performed by the chain/query: # app/controllers/some_controller.rb options = { auth: { bearer: '123456' } } # authenticated with OAuth token # app/controllers/some_controller.rb AuthenticatedRecord = Record.options(options) # app/controllers/some_controller.rb blue_records = AuthenticatedRecord.where(color: 'blue') GET https://service.example.com/records?color=blue { headers: { 'Authentication': 'Bearer 123456' } } # app/controllers/some_controller.rb AuthenticatedRecord.create(color: 'red') POST https://service.example.com/records { body: '{ color: "red" }' }, headers: { 'Authentication': 'Bearer 123456' } } # app/controllers/some_controller.rb record = AuthenticatedRecord.find(123) GET https://service.example.com/records/123 { headers: { 'Authentication': 'Bearer 123456' } } # app/controllers/some_controller.rb authenticated_record = record.options(options) # starting a new chain based on the found record # app/controllers/some_controller.rb authenticated_record.valid? POST https://service.example.com/records/validate { body: '{...}', headers: { 'Authentication': 'Bearer 123456' } } # app/controllers/some_controller.rb authenticated_record.save POST https://service.example.com/records { body: '{...}', headers: { 'Authentication': 'Bearer 123456' } } # app/controllers/some_controller.rb authenticated_record.destroy DELETE https://service.example.com/records/123 { headers: { 'Authentication': 'Bearer 123456' } } # app/controllers/some_controller.rb authenticated_record.update(name: 'Steve') POST https://service.example.com/records/123 { body: '{...}', headers: { 'Authentication': 'Bearer 123456' } } Control pagination within a query chain page sets the page that you want to request. per sets the amount of items requested per page. limit is an alias for per. But without providing arguments, it resolves the query and provides the current response limit per page # app/controllers/some_controller.rb Record.page(3).per(20).where(color: 'blue') GET https://service.example.com/records?offset=40&limit=20&color=blue # app/controllers/some_controller.rb Record.page(3).per(20).where(color: 'blue') GET https://service.example.com/records?offset=40&limit=20&color=blue The applied pagination strategy depends on what's configured for the particular record: See Record pagination Record pagination You can configure pagination on a per record base. LHS differentiates between the pagination strategy (how items/pages are navigated and calculated) and pagination keys (how stuff is named and accessed). Pagination strategy Pagination strategy: offset (default) The offset pagination strategy is LHS's default pagination strategy, so nothing needs to be (re-)configured. The offset pagination strategy starts with 0 and offsets by the amount of items, thay you've already recived – typically limit. # app/models/record.rb class Search < LHS::Record endpoint '{+service}/search' end # app/controllers/some_controller.rb Record.all GET https://service.example.com/records?limit=100 { items: [{...}, ...], total: 300, limit: 100, offset: 0 } In parallel: GET https://service.example.com/records?limit=100&offset=100 GET https://service.example.com/records?limit=100&offset=200 Pagination strategy: page In comparison to the offset strategy, the page strategy just increases by 1 (page) and sends the next batch of items for the next page. # app/models/record.rb class Search < LHS::Record configuration pagination_strategy: 'page', pagination_key: 'page' endpoint '{+service}/search' end # app/controllers/some_controller.rb Record.all GET https://service.example.com/records?limit=100 { items: [{...}, ...], total: 300, limit: 100, page: 1 } In parallel: GET https://service.example.com/records?limit=100&page=2 GET https://service.example.com/records?limit=100&page=3 Pagination strategy: start In comparison to the offset strategy, the start strategy indicates with which item the current page starts. Typically it starts with 1 and if you get 100 items per page, the next start is 101. # app/models/record.rb class Search < LHS::Record configuration pagination_strategy: 'start', pagination_key: 'startAt' endpoint '{+service}/search' end # app/controllers/some_controller.rb Record.all GET https://service.example.com/records?limit=100 { items: [{...}, ...], total: 300, limit: 100, page: 1 } In parallel: GET https://service.example.com/records?limit=100&startAt=101 GET https://service.example.com/records?limit=100&startAt=201 Pagination strategy: link The link strategy continuously follows in-response embedded links to following pages until the last page is reached (indicated by no more next link). WARNING Loading all pages from a resource paginated with links only can result in very poor performance, as pages can only be loaded sequentially! # app/models/record.rb class Search < LHS::Record configuration pagination_strategy: 'link' endpoint '{+service}/search' end # app/controllers/some_controller.rb Record.all GET https://service.example.com/records?limit=100 { items: [{...}, ...], limit: 100, next: { href: 'https://service.example.com/records?from_record_id=p62qM5p0NK_qryO52Ze-eg&limit=100' } } Sequentially: GET https://service.example.com/records?from_record_id=p62qM5p0NK_qryO52Ze-eg&limit=100 GET https://service.example.com/records?from_record_id=xcaoXBmuMyFFEcFDSgNgDQ&limit=100 Pagination keys limit_key limit_key sets the key used to indicate how many items you want to retrieve per page e.g. size, limit, etc. In case the limit_key parameter differs for how it needs to be requested from how it's provided in the response, use body and parameter subkeys. # app/models/record.rb class Record < LHS::Record configuration limit_key: { body: [:pagination, :max], parameter: :max } endpoint '{+service}/records' end # app/controllers/some_controller.rb records = Record.where(color: 'blue') records.limit # 20 GET https://service.example.com/records?color=blue&max=100 { ... items: [...], pagination: { max: 20 } } pagination_key pagination_key defines which key to use to paginate a page (e.g. offset, page, startAt etc.). In case the limit_key parameter differs for how it needs to be requested from how it's provided in the response, use body and parameter subkeys. # app/models/record.rb class Record < LHS::Record configuration pagination_key: { body: [:pagination, :page], parameter: :page }, pagination_strategy: :page endpoint '{+service}/records' end # app/controllers/some_controller.rb records = Record.where(color: 'blue').all records.length # 300 GET https://service.example.com/records?color=blue&limit=100 {... pagination: { page: 1 } } In parallel: GET https://service.example.com/records?color=blue&limit=100&page=2 {... pagination: { page: 2 } } GET https://service.example.com/records?color=blue&limit=100&page=3 {... pagination: { page: 3 } } total_key total_key defines which key to user for pagination to describe the total amount of remote items (e.g. total, totalResults, etc.). # app/models/record.rb class Record < LHS::Record configuration total_key: [:pagination, :total] endpoint '{+service}/records' end # app/controllers/some_controller.rb records = Record.where(color: 'blue').fetch records.length # 100 records.count # 300 GET https://service.example.com/records?color=blue&limit=100 {... pagination: { total: 300 } } Pagination links next? next? Tells you if there is a next link or not. # app/controllers/some_controller.rb @records = Record.where(color: 'blue').fetch GET https://service.example.com/records?color=blue&limit=100 {... items: [...], next: 'https://service.example.com/records?color=blue&limit=100&offset=100' } # app/views/some_view.haml - if @records.next? = render partial: 'next_arrow' previous? previous? Tells you if there is a previous link or not. # app/controllers/some_controller.rb @records = Record.where(color: 'blue').fetch GET https://service.example.com/records?color=blue&limit=100 {... items: [...], previous: 'https://service.example.com/records?color=blue&limit=100&offset=100' } # app/views/some_view.haml - if @records.previous? = render partial: 'previous_arrow' Kaminari support (limited) LHS implements an interface that makes it partially working with Kaminari. The kaminari’s page parameter is in params[:page]. For example, you can use kaminari to render paginations based on LHS Records. Typically, your code will look like this: # controller @items = Record.page(params[:page]).per(100) # view = paginate @items Build, create and update records Create new records create create will return the object in memory if persisting fails, providing validation errors in .errors (See record validation). create! instead will raise an exception. create always builds the data of the local object first, before it tries to sync with an endpoint. So even if persisting fails, the local object is build. # app/controllers/some_controller.rb record = Record.create( text: 'Hello world' ) POST https://service.example.com/records { body: "{ 'text' : 'Hello world' }" } -> See record validation for how to handle validation errors when creating records. Unwrap nested data when creation response nests created record data item_created_key key used to merge record data thats nested in the creation response body: # app/models/location.rb class Location < LHS::Record configuration item_created_key: [:response, :location] end # app/controllers/some_controller.rb location.create(lat: '47.3920152', long: '8.5127981') location.address # Förrlibuckstrasse 62, 8005 Zürich POST https://service.example.com/locations { body: "{ 'lat': '47.3920152', long: '8.5127981' }" } {... { response: { location: {... address: 'Förrlibuckstrasse 62, 8005 Zürich' } } } } Create records through associations: Nested sub resources # app/models/restaurant.rb class Restaurant < LHS::Record endpoint '{+service}/restaurants/{id}' end # app/models/feedback.rb class Feedback < LHS::Record endpoint '{+service}/restaurants/{restaurant_id}/feedbacks' end # app/controllers/some_controller.rb restaurant = Restaurant.find(1) GET https://service.example.com/restaurants/1 {... reviews: { href: 'https://service.example.com/restaurants/1/reviews' }} # app/controllers/some_controller.rb restaurant.reviews.create( text: 'Simply awesome!' ) POST https://service.example.com/restaurants/1/reviews { body: "{ 'text': 'Simply awesome!' }" } Start building new records With new or build you can start building new records from scratch, which can be persisted with save: # app/controllers/some_controller.rb record = Record.new # or Record.build record.name = 'Starbucks' record.save POST https://service.example.com/records { body: "{ 'name' : 'Starbucks' }" } Change/Update existing records save save persist the whole object in its current state. save will return false if persisting fails. save! instead will raise an exception. # app/controllers/some_controller.rb record = Record.find('1z-5r1fkaj') GET https://service.example.com/records/1z-5r1fkaj { name: 'Starbucks', recommended: null } # app/controllers/some_controller.rb record.recommended = true record.save POST https://service.example.com/records/1z-5r1fkaj { body: "{ 'name': 'Starbucks', 'recommended': true }" } -> See record validation for how to handle validation errors when updating records. update Directly via Record # app/controllers/some_controller.rb Record.update(id: '1z-5r1fkaj', name: 'Steve') GET https://service.example.com/records/1z-5r1fkaj { name: 'Steve' } per Instance update persists the whole object after new parameters are applied through arguments. update will return false if persisting fails. update! instead will raise an exception. update always updates the data of the local object first, before it tries to sync with an endpoint. So even if persisting fails, the local object is updated. # app/controllers/some_controller.rb record = Record.find('1z-5r1fkaj') GET https://service.example.com/records/1z-5r1fkaj { name: 'Starbucks', recommended: null } # app/controllers/some_controller.rb record.update(recommended: true) POST https://service.example.com/records/1z-5r1fkaj { body: "{ 'name': 'Starbucks', 'recommended': true }" } -> See record validation for how to handle validation errors when updating records. You can use update and the end of query-chains: # app/controllers/some_controller.rb record.options(method: :put).update(recommended: true) You can also pass explicit request options to update, by passing two explicit hashes: # app/controllers/some_controller.rb record.update({ recommended: true }, { method: 'put' }) partial_update partial_update updates just the provided parameters. partial_update will return false if persisting fails. partial_update! instead will raise an exception. partial_update always updates the data of the local object first, before it tries to sync with an endpoint. So even if persisting fails, the local object is updated. # app/controllers/some_controller.rb record = Record.find('1z-5r1fkaj') GET https://service.example.com/records/1z-5r1fkaj { name: 'Starbucks', recommended: null } # app/controllers/some_controller.rb record.partial_update(recommended: true) POST https://service.example.com/records/1z-5r1fkaj { body: "{ 'recommended': true }" } -> See record validation for how to handle validation errors when updating records. You can use partial_update at the end of query-chains: # app/controllers/some_controller.rb record.options(method: :put).partial_update(recommended: true) You can also pass explicit request options to partial_update, by passing two explicit hashes: # app/controllers/some_controller.rb record.partial_update({ recommended: true }, { method: 'put' }) Endpoint url parameter injection during record creation/change LHS injects parameters provided to create, update, partial_update, save etc. into an endpoint's URL when matching: # app/models/feedback.rb class Feedback << LHS::Record endpoint '{+service}/records/{record_id}/feedbacks' end # app/controllers/some_controller.rb Feedback.create(record_id: 51232, text: 'Great Restaurant!') POST https://service.example.com/records/51232/feedbacks { body: "{ 'text' : 'Great Restaurant!' }" } Record validation In order to validate records before persisting them, you can use the valid? (validate alias) method. It's not recommended to validate records anywhere, including application side validation via ActiveModel::Validations, except, if you validate them via the same endpoint/service, that also creates them. The specific endpoint has to support validations without persistence. An endpoint has to be enabled (opt-in) in your record configurations: # app/models/user.rb class User < LHS::Record endpoint '{+service}/users', validates: { params: { persist: false } } end # app/controllers/some_controller.rb user = User.build(email: 'i\'m not an email address') unless user.valid? @errors = user.errors render 'new' and return end POST https://service.example.com/users?persist=false { body: '{ "email" : "i'm not an email address"}' } { "field_errors": [{ "path": ["email"], "code": "WRONG_FORMAT", "message": "The property value's format is incorrect." }], "message": "Email must have the correct format." } The functionalities of LHS::Errors pretty much follow those of ActiveModel::Validation: # app/views/some_view.haml @errors.any? # true @errors.include?(:email) # true @errors[:email] # ['WRONG_FORMAT'] @errors.messages # {:email=>["Translated error message that this value has the wrong format"]} @errors.codes # {:email=>["WRONG_FORMAT"]} @errors.message # Email must have the correct format." Configure record validations The parameters passed to the validates endpoint option are used to perform record validations: # app/models/user.rb class User < LHS::Record endpoint '{+service}/users', validates: { params: { persist: false } } # will add ?persist=false to the request endpoint '{+service}/users', validates: { params: { publish: false } } # will add ?publish=false to the request endpoint '{+service}/users', validates: { params: { validates: true } } # will add ?validates=true to the request endpoint '{+service}/users', validates: { path: 'validate' } # will perform a validation via ...users/validate end HTTP Status Codes for validation errors The HTTP status code received from the endpoint when performing validations on a record, is available through the errors object: # app/controllers/some_controller.rb record.save record.errors.status_code # 400 Reset validation errors Clear the error messages like: # app/controllers/some_controller.rb record.errors.clear Add validation errors In case you want to add application side validation errors, even though it's not recommended, do it as following: user.errors.add(:name, 'WRONG_FORMAT') Validation errors for nested data If you work with complex data structures, you sometimes need to have validation errors delegated/scoped to nested data. This features makes LHS::Records compatible with how Rails or Simpleform renders/builds forms and especially error messages: # app/controllers/some_controller.rb unless @customer.save @errors = @customer.errors end POST https://service.example.com/customers { body: "{ 'address' : { 'street': 'invalid', housenumber: '' } }" } { "field_errors": [{ "path": ["address", "street"], "code": "REQUIRED_PROPERTY_VALUE_INCORRECT", "message": "The property value is incorrect." },{ "path": ["address", "housenumber"], "code": "REQUIRED_PROPERTY_VALUE", "message": "The property value is required." }], "message": "Some data is invalid." } # app/views/some_view.haml = form_for @customer, as: :customer do |customer_form| = fields_for 'customer[:address]', @customer.address, do |address_form| = fields_for 'customer[:address][:street]', @customer.address.street, do |street_form| = street_form.input :name = street_form.input :house_number This would render nested forms and would also render nested form errors for nested data structures. You can also access those nested errors like: @customer.address.errors @customer.address.street.errors Translation of validation errors If a translation exists for one of the following translation keys, LHS will provide a translated error (also in the following order) rather than the plain error message/code, when building forms or accessing @errors.messages: lhs.errors.records.<record_name>.attributes.<attribute_name>.<error_code> e.g. lhs.errors.records.customer.attributes.name.unsupported_property_value lhs.errors.records.<record_name>.<error_code> e.g. lhs.errors.records.customer.unsupported_property_value lhs.errors.messages.<error_code> e.g. lhs.errors.messages.unsupported_property_value lhs.errors.attributes.<attribute_name>.<error_code> e.g. lhs.errors.attributes.name.unsupported_property_value lhs.errors.fallback_message lhs.errors.records.<record_name>.attributes.<collection>.<attribute_name>.<error_code> e.g. lhs.errors.records.appointment_proposal.attributes.appointments.date_time.date_property_not_in_future Validation error types: errors vs. warnings Persistance failed: errors If an endpoint returns errors in the response body, that is enough to interpret it as: persistance failed. The response status code in this scenario is neglected. Persistance succeeded: warnings In some cases, you need non blocking meta information about potential problems with the created record, so called warnings. If the API endpoint implements warnings, returned when validating, they are provided just as errors (same interface and methods) through the warnings attribute: # app/controllres/some_controller.rb @presence = Presence.options(params: { synchronize: false }).create( place: { href: 'http://storage/places/1' } ) POST https://service.example.com/presences { body: '{ "place": { "href": "http://storage/places/1" } }' } { field_warnings: [{ code: 'WILL_BE_RESIZED', path: ['place', 'photos', 0], message: 'This photo is too small and will be resized.' } } presence.warnings.any? # true presence.place.photos[0].warnings.messages.first # 'This photo is too small and will be resized.' Using ActiveModel::Validations none the less If you are using ActiveModel::Validations, even though it's not recommended, and you add errors to the LHS::Record instance, then those errors will be overwritten by the errors from ActiveModel::Validations when using save or valid?. So in essence, mixing ActiveModel::Validations and LHS built-in validations (via endpoints), is not compatible, yet. Open issue Use form_helper to create and update records Rails form_for view-helper can be used in combination with instances of LHS::Records to autogenerate forms: <%= form_for(@instance, url: '/create') do |f| %> <%= f.text_field :name %> <%= f.text_area :text %> <%= f.submit "Create" %> <% end %> Destroy records destroy deletes a record. # app/controllers/some_controller.rb record = Record.find('1z-5r1fkaj') GET https://service.example.com/records/1z-5r1fkaj # app/controllers/some_controller.rb record.destroy DELETE https://service.example.com/records/1z-5r1fkaj You can also destroy records directly without fetching them first: # app/controllers/some_controller.rb destroyed_record = Record.destroy('1z-5r1fkaj') DELETE https://service.example.com/records/1z-5r1fkaj or with parameters: # app/controllers/some_controller.rb destroyed_records = Record.destroy(name: 'Steve') DELETE https://service.example.com/records?name='Steve' Record getters and setters Sometimes it is necessary to implement custom getters and setters and convert data to a processable (endpoint) format behind the scenes. Record setters You can define setter methods in LHS::Records that will be used by initializers (new) and setter methods, that convert data provided, before storing it in the record and persisting it with a remote endpoint: # app/models/user.rb class Feedback < LHS::Record def ratings=(values) super( values.map { |k, v| { name: k, value: v } } ) end end # app/controllers/some_controller.rb record = Record.new(ratings: { quality: 3 }) record.ratings # [{ :name=>:quality, :value=>3 }] Setting attributes with other names: # app/models/booking.rb class Booking < LHS::Record def appointments_attributes=(values) self.appointments = values.map { |appointment| appointment[:id] } end end or # app/models/booking.rb class Booking < LHS::Record def appointments_attributes=(values) self[:appointments] = values.map { |appointment| appointment[:id] } end end # app/controllers/some_controller.rb booking.update(params) Record getters If you implement accompanying getter methods, the whole data conversion would be internal only: # app/models/user.rb class Feedback < LHS::Record def ratings=(values) super( values.map { |k, v| { name: k, value: v } } ) end def ratings super.map { |r| [r[:name], r[:value]] }] end end # app/controllers/some_controller.rb record = Record.new(ratings: { quality: 3 }) record.ratings # {:quality=>3} Include linked resources (hyperlinks and hypermedia) In a service-oriented architecture using hyperlinks/hypermedia, records/resources can contain hyperlinks to other records/resources. When fetching records with LHS, you can specify in advance all the linked resources that you want to include in the results. With includes LHS ensures that all matching and explicitly linked resources are loaded and merged (even if the linked resources are paginated). Including linked resources/records is heavily influenced by https://guides.rubyonrails.org/active_record_querying.html and you should read it to understand this feature in all it's glory. Generate links from parameters Sometimes you need to generate full hrefs/urls for records but you just have parameters that describe that record, like the ID. For those usecases you can use href_for(params): # app/controllers/some_controller.rb Presence.create(place: { href: Place.href_for(123) }) POST '/presences' { place: { href: "http://datastore/places/123" } } Ensure the whole linked collection is included with includes In case endpoints are paginated and you are certain that you'll need all objects of a set and not only the first page/batch, use includes. LHS will ensure that all linked resources are around by loading all pages (parallelized/performance optimized). # app/controllers/some_controller.rb customer = Customer.includes(contracts: :products).find(1) > GET https://service.example.com/customers/1 < {... contracts: { href: 'https://service.example.com/customers/1/contracts' } } > GET https://service.example.com/customers/1/contracts?limit=100 < {... items: [...], limit: 10, offset: 0, total: 32 } In parallel: > GET https://service.example.com/customers/1/contracts?limit=10&offset=10 < {... products: [{ href: 'https://service.example.com/product/LBC' }] } > GET https://service.example.com/customers/1/contracts?limit=10&offset=20 < {... products: [{ href: 'https://service.example.com/product/LBB' }] } In parallel: > GET https://service.example.com/product/LBC < {... name: 'Local Business Card' } > GET https://service.example.com/product/LBB < {... name: 'Local Business Basic' } # app/controllers/some_controller.rb customer.contracts.length # 32 customer.contracts.first.products.first.name # Local Business Card Include only the first linked page of a linked collection: includes_first_page includes_first_page includes the first page/response when loading the linked resource. If the endpoint is paginated, only the first page will be included. # app/controllers/some_controller.rb customer = Customer.includes_first_page(contracts: :products).find(1) > GET https://service.example.com/customers/1 < {... contracts: { href: 'https://service.example.com/customers/1/contracts' } } > GET https://service.example.com/customers/1/contracts?limit=100 < {... items: [...], limit: 10, offset: 0, total: 32 } In parallel: > GET https://service.example.com/product/LBC < {... name: 'Local Business Card' } > GET https://service.example.com/product/LBB < {... name: 'Local Business Basic' } # app/controllers/some_controller.rb customer.contracts.length # 10 customer.contracts.first.products.first.name # Local Business Card Include various levels of linked data The method syntax of includes allows you to include hyperlinks stored in deep nested data structures: Some examples: Record.includes(:localch_account, :entry) # Includes localch_account -> entry # { localch_account: { href: '...', entry: { href: '...' } } } Record.includes([:localch_account, :entry]) # Includes localch_account and entry # { localch_account: { href: '...' }, entry: { href: '...' } } Record.includes(campaign: [:entry, :user]) # Includes campaign and entry and user from campaign # { campaign: { href: '...' , entry: { href: '...' }, user: { href: '...' } } } Identify and cast known records when including records When including linked resources with includes, already defined records and their endpoints and configurations are used to make the requests to fetch the additional data. That also means that options for endpoints of linked resources are applied when requesting those in addition. This applies for example a records endpoint configuration even though it's fetched/included through another record: # app/models/favorite.rb class Favorite < LHS::Record endpoint '{+service}/users/{user_id}/favorites', auth: { basic: { username: 'steve', password: 'can' } } endpoint '{+service}/users/{user_id}/favorites/:id', auth: { basic: { username: 'steve', password: 'can' } } end # app/models/place.rb class Place < LHS::Record endpoint '{+service}/v2/places', auth: { basic: { username: 'steve', password: 'can' } } endpoint '{+service}/v2/places/{id}', auth: { basic: { username: 'steve', password: 'can' } } end # app/controllers/some_controller.rb Favorite.includes(:place).where(user_id: current_user.id) > GET https://service.example.com/users/123/favorites { headers: { 'Authentication': 'Basic c3RldmU6Y2Fu' } } < {... items: [... { place: { href: 'https://service.example.com/place/456' } } ] } In parallel: > GET https://service.example.com/place/456 { headers: { 'Authentication': 'Basic c3RldmU6Y2Fu' } } > GET https://service.example.com/place/789 { headers: { 'Authentication': 'Basic c3RldmU6Y2Fu' } } > GET https://service.example.com/place/1112 { headers: { 'Authentication': 'Basic c3RldmU6Y2Fu' } } > GET https://service.example.com/place/5423 { headers: { 'Authentication': 'Basic c3RldmU6Y2Fu' } } Apply options for requests performed to fetch included records Use references to apply request options to requests performed to fetch included records: # app/controllers/some_controller.rb Favorite.includes(:place).references(place: { auth: { bearer: '123' }}).where(user_id: 1) GET https://service.example.com/users/1/favorites {... items: [... { place: { href: 'https://service.example.com/places/2' } }] } In parallel: GET https://service.example.com/places/2 { headers: { 'Authentication': 'Bearer 123' } } GET https://service.example.com/places/3 { headers: { 'Authentication': 'Bearer 123' } } GET https://service.example.com/places/4 { headers: { 'Authentication': 'Bearer 123' } } Here is another example, if you want to ignore errors, that occur while you fetch included resources: # app/controllers/some_controller.rb feedback = Feedback .includes(campaign: :entry) .references(campaign: { ignore: LHC::NotFound }) .find(12345) compact: Remove included resources that didn't return any records In case you include nested data and ignored errors while including, it can happen that you get back a collection that contains data based on response errors: # app/controllers/some_controller.rb user = User .includes(:places) .references(places: { ignore: LHC::NotFound }) .find(123) GET http://service/users/123 { "places": { "href": "http://service/users/123/places" } } GET http://service/users/123/places { "items": [ { "href": "http://service/places/1" }, { "href": "http://service/places/2" } ] } GET http://service/places/1 200 { "name": "Casa Ferlin" } GET http://service/places/2 404 { "status": 404, "error": "not found" } user.places[1] # { "status": 404, "error": "not found" } In order to exclude items from a collection which where not based on successful responses, use .compact or .compact!: # app/controllers/some_controller.rb user = User .includes(:places) .references(places: { ignore: LHC::NotFound }) .find(123) places = user.places.compact places # { "items": [ { "href": "http://service/places/1", "name": "Casa Ferlin" } ] } Record batch processing Be careful using methods for batch processing. They could result in a lot of HTTP requests! all all fetches all records from the service by doing multiple requests, best-effort parallelization, and resolving endpoint pagination if necessary: records = Record.all > GET https://service.example.com/records?limit=100 < {... items: [...] total: 900, limit: 100, offset: 0 } In parallel: > GET https://service.example.com/records?limit=100&offset=100 > GET https://service.example.com/records?limit=100&offset=200 > GET https://service.example.com/records?limit=100&offset=300 > GET https://service.example.com/records?limit=100&offset=400 > GET https://service.example.com/records?limit=100&offset=500 > GET https://service.example.com/records?limit=100&offset=600 > GET https://service.example.com/records?limit=100&offset=700 > GET https://service.example.com/records?limit=100&offset=800 all is chainable and has the same interface like where: Record.where(color: 'blue').all Record.all.where(color: 'blue') Record.all(color: 'blue') All three are doing the same thing: fetching all records with the color 'blue' from the endpoint while resolving pagingation if endpoint is paginated. Using all, when endpoint does not implement response pagination meta data In case an API does not provide pagination information in the repsponse data (limit, offset and total), LHS keeps on loading pages when requesting all until the first empty page responds. find_each find_each is a more fine grained way to process single records that are fetched in batches. Record.find_each(start: 50, batch_size: 20, params: { has_reviews: true }, headers: { 'Authorization': 'Bearer 123' }) do |record| # Iterates over each record. Starts with record no. 50 and fetches 20 records each batch. record break if record.some_attribute == some_value end find_in_batches find_in_batches is used by find_each and processes batches. Record.find_in_batches(start: 50, batch_size: 20, params: { has_reviews: true }, headers: { 'Authorization': 'Bearer 123' }) do |records| # Iterates over multiple records (batch size is 20). Starts with record no. 50 and fetches 20 records each batch. records break if records.first.name == some_value end Convert/Cast specific record types: becomes Based on ActiveRecord's implementation, LHS implements becomes, too. It's a way to convert records of a certain type A to another certain type B. NOTE: RPC-style actions, that are discouraged in REST anyway, are utilizable with this functionality, too. See the following example: # app/models/location.rb class Location < LHS::Record endpoint '{+service}/locations' endpoint '{+service}/locations/{id}' end # app/models/synchronization.rb class Synchronization < LHS::Record endpoint '{+service}/locations/{id}/sync' end # app/controllers/some_controller.rb location = Location.find(1) GET https://service.example.com/location/1 # app/controllers/some_controller.rb synchronization = location.becomes(Synchronization) synchronization.save! POST https://service.example.com/location/1/sync { body: '{ ... }' } Assign attributes Allows you to set the attributes by passing in a hash of attributes. entry = LocalEntry.new entry.assign_attributes(company_name: 'localsearch') entry.company_name # => 'localsearch' Request Cycle Cache By default, LHS does not perform the same http request multiple times during one request/response cycle. # app/models/user.rb class User < LHS::Record endpoint '{+service}/users/{id}' end # app/models/location.rb class Location < LHS::Record endpoint '{+service}/locations/{id}' end # app/controllers/some_controller.rb def index @user = User.find(1) @locations = Location.includes(:owner).find(2) end GET https://service.example.com/users/1 GET https://service.example.com/location/2 {... owner: { href: 'https://service.example.com/users/1' } } From cache: GET https://service.example.com/users/1 It uses the LHC Caching Interceptor as caching mechanism base and sets a unique request id for every request cycle with Railties to ensure data is just cached within one request cycle and not shared with other requests. Only GET requests are considered for caching by using LHC Caching Interceptor's cache_methods option internally and considers request headers when caching requests, so requests with different headers are not served from cache. The LHS Request Cycle Cache is opt-out, so it's enabled by default and will require you to enable the LHC Caching Interceptor in your project. Change store for LHS' request cycle cache By default the LHS Request Cycle Cache will use ActiveSupport::Cache::MemoryStore as its cache store. Feel free to configure a cache that is better suited for your needs by: # config/initializers/lhs.rb LHS.configure do |config| config.request_cycle_cache = ActiveSupport::Cache::MemoryStore.new end Disable request cycle cache If you want to disable the LHS Request Cycle Cache, simply disable it within configuration: # config/initializers/lhs.rb LHS.configure do |config| config.request_cycle_cache_enabled = false end Automatic Authentication (OAuth) LHS provides a way to have records automatically fetch and use OAuth authentication when performing requests within Rails. In order to enable automatic oauth authentication, perform the following steps: 1. Make sure LHS is configured to perform auto_oauth. Provide a block that, when executed in the controller context, returns a valid access_token/bearer_token. # config/initializers/lhs.rb LHS.configure do |config| config.auto_oauth = -> { access_token } end 1. Opt-in records requiring oauth authentication: # app/models/record.rb class Record < LHS::Record oauth # ... end 1. Include the LHS::OAuth context into your application controller: # app/controllers/application_controller.rb class ApplicationController < ActionController::Base include LHS::OAuth # ... end 1. Make sure you have the LHC::Auth interceptor enabled: # config/initializers/lhc.rb LHC.configure do |config| config.interceptors = [LHC::Auth] end Now you can perform requests based on the record that will be auto authenticated from now on: # app/controllers/some_controller.rb Record.find(1) https://records/1 Authentication: 'Bearer token-12345' Configure multiple auth providers (even per endpoint) In case you need to configure multiple auth provider access_tokens within your application, make sure you provide a proc returning a hash when configuring auto_oauth, naming every single provider and the responsive method to retrieve the access_tokens in the controller context: # config/initializers/lhs.rb LHS.configure do |config| config.auto_oauth = proc do { provider1: access_token_provider_1, provider2: access_token_provider_2 } end end Then make sure you either define which provider to use on a record level: # model/record.rb class Record < LHS::Record oauth(:provider1) #... end or on an endpoint level: # model/record.rb class Record < LHS::Record endpoint 'https://service/records', oauth: :provider1 #... end Configure providers If you're using LHS service providers, you can also configure auto auth on a provider level: # app/models/providers/localsearch.rb module Providers class Localsearch < LHS::Record provider(
{ "url": "https://github.com/local-ch/lhs", "source_domain": "github.com", "snapshot_id": "CC-MAIN-2024-10", "warc_metadata": { "Content-Length": "1052748", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:FKWVLQQINXSAH5JFF6RY6MGHTY2HEZPG", "WARC-Concurrent-To": "<urn:uuid:a1934bc8-b2b6-4591-906f-20c75d14f94b>", "WARC-Date": "2024-02-21T04:58:30Z", "WARC-IP-Address": "140.82.112.4", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:HWAFLXMJNF7VJQURM4IWIMDPNYLWNFA5", "WARC-Record-ID": "<urn:uuid:88e41916-de06-43ef-9548-f6f186c4ce8d>", "WARC-Target-URI": "https://github.com/local-ch/lhs", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ca66a83a-60c0-4ab0-b42b-29187b5c8cfe>" }, "warc_info": "isPartOf: CC-MAIN-2024-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February/March 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-169\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 16, 17, 30, 31, 59, 60, 64, 65, 646, 647, 688, 689, 700, 701, 711, 740, 741, 767, 824, 828, 851, 852, 879, 880, 912, 949, 950, 954, 998, 999, 1051, 1084, 1085, 1103, 1104, 1135, 1136, 1180, 1285, 1372, 1442, 1516, 1517, 1524, 1525, 1535, 1536, 1641, 1642, 1701, 1702, 1725, 1726, 1753, 1754, 1786, 1823, 1884, 1950, 1951, 1955, 1956, 2027, 2028, 2051, 2052, 2079, 2080, 2151, 2227, 2228, 2232, 2233, 2289, 2290, 2315, 2316, 2427, 2428, 2495, 2496, 2525, 2526, 2552, 2597, 2601, 2624, 2625, 2652, 2653, 2692, 2693, 2697, 2698, 2705, 2706, 2818, 2819, 2848, 2849, 2875, 2945, 2949, 2972, 2973, 3000, 3001, 3024, 3027, 3031, 3032, 3052, 3053, 3225, 3226, 3290, 3291, 3314, 3315, 3342, 3343, 3375, 3407, 3408, 3412, 3449, 3450, 3463, 3503, 3504, 3687, 3688, 3697, 3698, 3783, 3784, 3821, 3822, 3838, 3871, 3909, 3915, 3919, 3920, 4010, 4011, 4044, 4045, 4061, 4090, 4121, 4157, 4163, 4167, 4204, 4205, 4231, 4274, 4275, 4355, 4356, 4375, 4376, 4461, 4462, 4483, 4484, 4509, 4546, 4550, 4573, 4574, 4594, 4598, 4635, 4636, 4651, 4693, 4694, 4716, 4717, 4723, 4724, 4871, 4872, 4909, 4910, 4933, 4975, 4976, 4982, 4983, 5035, 5036, 5073, 5074, 5102, 5155, 5156, 5284, 5285, 5322, 5323, 5361, 5419, 5420, 5543, 5544, 5598, 5599, 5636, 5637, 5707, 5765, 5766, 5805, 5806, 5870, 5871, 5894, 5895, 5922, 5923, 5955, 5992, 5993, 6036, 6094, 6095, 6099, 6136, 6137, 6175, 6241, 6242, 6246, 6247, 6362, 6363, 6400, 6401, 6422, 6474, 6537, 6600, 6637, 6638, 6657, 6658, 6689, 6690, 6857, 6858, 6881, 6882, 6909, 6942, 6946, 6983, 6984, 7005, 7047, 7048, 7111, 7112, 7192, 7193, 7313, 7314, 7537, 7538, 7558, 7559, 7564, 7565, 7677, 7678, 7695, 7739, 7801, 7852, 7853, 7923, 7924, 7961, 8024, 8025, 8080, 8081, 8102, 8117, 8161, 8205, 8249, 8250, 8258, 8259, 8365, 8366, 8418, 8419, 8449, 8500, 8501, 8507, 8508, 8615, 8616, 8666, 8667, 8680, 8728, 8729, 8766, 8767, 8806, 8865, 8866, 8871, 8872, 8977, 8978, 9027, 9028, 9040, 9041, 9077, 9078, 9116, 9117, 9142, 9143, 9231, 9232, 9270, 9289, 9309, 9332, 9357, 9384, 9412, 9413, 9459, 9460, 9523, 9524, 9643, 9644, 9845, 9846, 10011, 10012, 10045, 10046, 10157, 10158, 10181, 10182, 10209, 10210, 10242, 10243, 10254, 10321, 10327, 10331, 10332, 10367, 10368, 10546, 10547, 10569, 10570, 10596, 10627, 10663, 10664, 10675, 10742, 10748, 10752, 10777, 10778, 10807, 10841, 10880, 10884, 10921, 10922, 10969, 11003, 11049, 11050, 11114, 11115, 11158, 11159, 11299, 11300, 11325, 11326, 11667, 11668, 11779, 11780, 11789, 11814, 11815, 11844, 11845, 11884, 11885, 11906, 11907, 11911, 11935, 11936, 11964, 11965, 11982, 12006, 12012, 12016, 12053, 12054, 12104, 12148, 12189, 12190, 12495, 12496, 12528, 12529, 12543, 12574, 12610, 12651, 12656, 12706, 12712, 12716, 12745, 12746, 12760, 12788, 12794, 12798, 12806, 12834, 12835, 12867, 12868, 12909, 12910, 12926, 12930, 12951, 12952, 12977, 12978, 12990, 13015, 13021, 13025, 13062, 13063, 13119, 13165, 13214, 13215, 13520, 13521, 13553, 13554, 13568, 13599, 13635, 13676, 13681, 13729, 13735, 13739, 13768, 13769, 13783, 13811, 13817, 13821, 13822, 13865, 13866, 14045, 14046, 14122, 14123, 14148, 14149, 14178, 14227, 14231, 14268, 14269, 14299, 14317, 14363, 14406, 14407, 14452, 14453, 14576, 14577, 14600, 14601, 14628, 14661, 14665, 14702, 14703, 14748, 14808, 14859, 14927, 14928, 14973, 14974, 15064, 15065, 15102, 15103, 15127, 15157, 15178, 15196, 15233, 15270, 15271, 15360, 15434, 15455, 15473, 15474, 15496, 15497, 15782, 15783, 15950, 15951, 16081, 16082, 16344, 16345, 16382, 16383, 16417, 16418, 16438, 16439, 16476, 16477, 16515, 16521, 16569, 16577, 16581, 16649, 16650, 16757, 16758, 16784, 16785, 16820, 16821, 16865, 16866, 16979, 16980, 17069, 17070, 17107, 17108, 17144, 17193, 17198, 17212, 17267, 17322, 17376, 17380, 17382, 17383, 17396, 17442, 17474, 17520, 17548, 17594, 17623, 17624, 17626, 17632, 17646, 17652, 17707, 17738, 17748, 17755, 17761, 17816, 17843, 17853, 17860, 17866, 17921, 17949, 17959, 17965, 17969, 17971, 17972, 18102, 18103, 18140, 18141, 18209, 18210, 18237, 18238, 18408, 18409, 18446, 18447, 18456, 18566, 18578, 18699, 18703, 18730, 18731, 18866, 18882, 18883, 18995, 18996, 19132, 19133, 19170, 19171, 19180, 19200, 19257, 19283, 19299, 19324, 19328, 19329, 19337, 19338, 19361, 19378, 19384, 19388, 19389, 19406, 19495, 19512, 19516, 19569, 19575, 19576, 19645, 19646, 19689, 19690, 19828, 19829, 19866, 19867, 19881, 19956, 19973, 19974, 19999, 20012, 20058, 20066, 20112, 20120, 20166, 20174, 20175, 20218, 20219, 20294, 20295, 20394, 20395, 20432, 20433, 20494, 20495, 20508, 20509, 20531, 20532, 20595, 20596, 20633, 20634, 20678, 20679, 20725, 20726, 20847, 20848, 20885, 20886, 20960, 20997, 20998, 21044, 21081, 21082, 21138, 21240, 21277, 21278, 21319, 21439, 21476, 21477, 21516, 21611, 21648, 21649, 21745, 21782, 21783, 21811, 21927, 21964, 21965, 21991, 22098, 22135, 22136, 22165, 22263, 22300, 22301, 22344, 22455, 22456, 22496, 22497, 22542, 22543, 22592, 22593, 22724, 22725, 22762, 22763, 22807, 22877, 22914, 22915, 22959, 23029, 23030, 23140, 23141, 23159, 23160, 23364, 23365, 23385, 23386, 23424, 23425, 23534, 23535, 23663, 23664, 23687, 23688, 23715, 23746, 23750, 23787, 23788, 23799, 23849, 23851, 23874, 23888, 23902, 23914, 23916, 23929, 23992, 24055, 24081, 24082, 24218, 24219, 24242, 24243, 24270, 24338, 24339, 24370, 24374, 24411, 24412, 24423, 24473, 24475, 24498, 24512, 24526, 24536, 24538, 24551, 24610, 24669, 24696, 24697, 24890, 24891, 24914, 24915, 24942, 25014, 25015, 25046, 25050, 25087, 25088, 25099, 25149, 25151, 25174, 25188, 25202, 25212, 25214, 25227, 25291, 25355, 25381, 25382, 25532, 25533, 25541, 25542, 25681, 25682, 25705, 25706, 25733, 25777, 25778, 25809, 25813, 25850, 25851, 25862, 25912, 25914, 25937, 25951, 25961, 26057, 26061, 26063, 26077, 26167, 26257, 26258, 26274, 26275, 26285, 26286, 26539, 26540, 26563, 26564, 26591, 26665, 26666, 26698, 26702, 26739, 26740, 26778, 26797, 26856, 26862, 26878, 26904, 26906, 26921, 26922, 27161, 27162, 27185, 27186, 27213, 27322, 27323, 27355, 27359, 27396, 27397, 27439, 27460, 27521, 27552, 27565, 27635, 27668, 27738, 27771, 27781, 27782, 27912, 27913, 27936, 27937, 27964, 28013, 28014, 28046, 28050, 28087, 28088, 28132, 28153, 28173, 28234, 28268, 28269, 28286, 28287, 28293, 28294, 28342, 28343, 28380, 28381, 28426, 28487, 28584, 28611, 28612, 28632, 28665, 28675, 28676, 28732, 28733, 28770, 28771, 28816, 28877, 28978, 29005, 29006, 29030, 29067, 29068, 29095, 29096, 29171, 29172, 29343, 29344, 29357, 29402, 29409, 29427, 29428, 29461, 29462, 29481, 29482, 29489, 29490, 29615, 29616, 29657, 29658, 29813, 29814, 29851, 29852, 29876, 29898, 29900, 29980, 29981, 30065, 30066, 30134, 30135, 30226, 30227, 30252, 30253, 30282, 30283, 30340, 30341, 30345, 30382, 30383, 30437, 30490, 30588, 30676, 30734, 30761, 30762, 30793, 30834, 30838, 30863, 30864, 30893, 30955, 30959, 30996, 30997, 31029, 31075, 31152, 31189, 31190, 31217, 31243, 31245, 31342, 31343, 31370, 31371, 31472, 31473, 31510, 31511, 31549, 31575, 31587, 31665, 31666, 31697, 31698, 31703, 31704, 31756, 31757, 31840, 31841, 31878, 31879, 31914, 31965, 32006, 32043, 32044, 32070, 32082, 32191, 32192, 32276, 32277, 32284, 32304, 32341, 32342, 32389, 32440, 32458, 32471, 32472, 32557, 32558, 32645, 32646, 32804, 32805, 32842, 32843, 32878, 32929, 32970, 33007, 33008, 33041, 33150, 33151, 33235, 33236, 33284, 33285, 33322, 33323, 33378, 33379, 33465, 33466, 33503, 33504, 33560, 33575, 33576, 33629, 33630, 33733, 33734, 33900, 33901, 33938, 33939, 33974, 34025, 34066, 34103, 34104, 34145, 34233, 34234, 34318, 34319, 34374, 34375, 34412, 34413, 34476, 34477, 34571, 34572, 34609, 34610, 34674, 34675, 34738, 34739, 34854, 34855, 34880, 34881, 34911, 34965, 34969, 35006, 35007, 35068, 35170, 35171, 35189, 35190, 35291, 35292, 35495, 35496, 35636, 35637, 35658, 35659, 35684, 35685, 35758, 35759, 35763, 35800, 35801, 35855, 35856, 35875, 35899, 35925, 35929, 36034, 36037, 36058, 36081, 36109, 36168, 36174, 36225, 36227, 36228, 36316, 36317, 36344, 36345, 36365, 36397, 36432, 36527, 36570, 36625, 36654, 36655, 36750, 36751, 36772, 36773, 36798, 36799, 36914, 37029, 37145, 37269, 37270, 37274, 37314, 37315, 37444, 37445, 37482, 37483, 37495, 37527, 37551, 37552, 37583, 37584, 37621, 37622, 37642, 37664, 37665, 37779, 37780, 37819, 37853, 37854, 37974, 37975, 38100, 38101, 38138, 38139, 38161, 38190, 38194, 38306, 38309, 38330, 38365, 38414, 38464, 38470, 38510, 38549, 38598, 38604, 38641, 38643, 38670, 38671, 38726, 38727, 38801, 38802, 38893, 38894, 38926, 38966, 38967, 39067, 39068, 39114, 39115, 39140, 39172, 39205, 39206, 39432, 39433, 39507, 39583, 39584, 39630, 39690, 39691, 39724, 39776, 39777, 39829, 39888, 39889, 39917, 39918, 40005, 40112, 40156, 40183, 40184, 40347, 40348, 40380, 40381, 40505, 40506, 40667, 40668, 40705, 40706, 40775, 40820, 40822, 40928, 40930, 40953, 40984, 41020, 41082, 41088, 41092, 41122, 41220, 41265, 41266, 41500, 41501, 41618, 41619, 41630, 41631, 41676, 41677, 41785, 41786, 41836, 41864, 41891, 41918, 41928, 41929, 41945, 41946, 41972, 41973, 42010, 42011, 42046, 42097, 42134, 42135, 42150, 42204, 42205, 42272, 42273, 42310, 42311, 42359, 42413, 42414, 42434, 42435, 42472, 42473, 42523, 42579, 42580, 42607, 42608, 42745, 42746, 42761, 42762, 42970, 42971, 42992, 42993, 43022, 43023, 43046, 43057, 43107, 43113, 43119, 43123, 43160, 43161, 43206, 43256, 43257, 43294, 43295, 43319, 43320, 43348, 43349, 43388, 43458, 43464, 43468, 43469, 43472, 43473, 43497, 43498, 43526, 43527, 43566, 43638, 43644, 43648, 43685, 43686, 43709, 43710, 43725, 43726, 43822, 43823, 43844, 43845, 43874, 43875, 43898, 43909, 43959, 43965, 43971, 43972, 43986, 44031, 44037, 44041, 44078, 44079, 44124, 44155, 44156, 44209, 44210, 44343, 44344, 44469, 44470, 44614, 44615, 44803, 44804, 44835, 44836, 44964, 44965, 45014, 45015, 45052, 45053, 45107, 45176, 45177, 45238, 45239, 45378, 45379, 45491, 45492, 45529, 45530, 45589, 45635, 45717, 45783, 45838, 45852, 45929, 46004, 46081, 46156, 46169, 46217, 46256, 46304, 46344, 46381, 46382, 46413, 46480, 46481, 46560, 46561, 46716, 46717, 46754, 46755, 46825, 46871, 46953, 47019, 47074, 47087, 47135, 47174, 47222, 47262, 47299, 47300, 47331, 47398, 47399, 47437, 47438, 47540, 47541, 47556, 47557, 47599, 47635, 47698, 47699, 47743, 47780, 47843, 47844, 47887, 47940, 48020, 48021, 48076, 48077, 48247, 48248, 48358, 48359, 48475, 48476, 48501, 48502, 48531, 48532, 48639, 48750, 48751, 48755, 48777, 48778, 48804, 48805, 48896, 48992, 48993, 48997, 49034, 49035, 49093, 49203, 49287, 49300, 49402, 49504, 49607, 49710, 49711, 49774, 49775, 49864, 49865, 49902, 49903, 49993, 50043, 50123, 50136, 50227, 50318, 50409, 50410, 50512, 50513, 50550, 50551, 50571, 50601, 50652, 50667, 50668, 50734, 50735, 50893, 50894, 50931, 50932, 50944, 50965, 51014, 51027, 51056, 51116, 51117, 51153, 51166, 51207, 51247, 51251, 51252, 51280, 51310, 51311, 51339, 51383, 51440, 51441, 51559, 51560, 51597, 51598, 51610, 51631, 51680, 51693, 51722, 51723, 51810, 51811, 51835, 51836, 51928, 51929, 51933, 51934, 52080, 52081, 52102, 52154, 52161, 52176, 52190, 52204, 52216, 52218, 52231, 52296, 52361, 52426, 52491, 52556, 52621, 52686, 52751, 52752, 52808, 52809, 52841, 52873, 52899, 52900, 53051, 53052, 53126, 53127, 53315, 53316, 53326, 53327, 53419, 53420, 53551, 53643, 53652, 53699, 53703, 53704, 53720, 53721, 53781, 53782, 53920, 54036, 54046, 54090, 54094, 54095, 54139, 54140, 54209, 54210, 54287, 54288, 54422, 54423, 54448, 54449, 54478, 54512, 54551, 54555, 54587, 54588, 54624, 54668, 54672, 54709, 54710, 54738, 54781, 54818, 54819, 54871, 54893, 54962, 54963, 54981, 54982, 55051, 55052, 55075, 55128, 55166, 55167, 55187, 55188, 55293, 55294, 55315, 55316, 55341, 55376, 55380, 55405, 55406, 55435, 55474, 55478, 55515, 55516, 55526, 55549, 55598, 55602, 55642, 55685, 55747, 55759, 55801, 55802, 56022, 56023, 56250, 56251, 56394, 56395, 56437, 56438, 56612, 56613, 56642, 56643, 56669, 56738, 56742, 56743, 56771, 56772, 56864, 56865, 56894, 56895, 56921, 56966, 56970, 56971, 57004, 57005, 57128, 57129, 57209, 57210, 57372, 57401, 57402, 57428, 57470, 57474, 57526, 57549, 57550, 57577, 57585, 57593, 57597, 57667, 57711, 57712, 57765, 57786, 57787, 57795, 57799, 57858, 57887, 57888, 57914, 57950, 57954, 57955, 58049, 58050, 58087, 58088, 58103, 58121, 58158, 58159, 58213, 58214, 58493, 58494, 58523, 58549, 58579, 58585, 58627, 58668, 58674, 58680, 58684, 58685, 58759, 58760, 58778, 58805, 58825, 58832, 58836, 58837, 58862, 58863, 58881, 58908, 58964, 58971, 58975, 58976, 58996, 58997, 59090, 59091, 59129, 59146, 59180, 59185 ], "line_end_idx": [ 16, 17, 30, 31, 59, 60, 64, 65, 646, 647, 688, 689, 700, 701, 711, 740, 741, 767, 824, 828, 851, 852, 879, 880, 912, 949, 950, 954, 998, 999, 1051, 1084, 1085, 1103, 1104, 1135, 1136, 1180, 1285, 1372, 1442, 1516, 1517, 1524, 1525, 1535, 1536, 1641, 1642, 1701, 1702, 1725, 1726, 1753, 1754, 1786, 1823, 1884, 1950, 1951, 1955, 1956, 2027, 2028, 2051, 2052, 2079, 2080, 2151, 2227, 2228, 2232, 2233, 2289, 2290, 2315, 2316, 2427, 2428, 2495, 2496, 2525, 2526, 2552, 2597, 2601, 2624, 2625, 2652, 2653, 2692, 2693, 2697, 2698, 2705, 2706, 2818, 2819, 2848, 2849, 2875, 2945, 2949, 2972, 2973, 3000, 3001, 3024, 3027, 3031, 3032, 3052, 3053, 3225, 3226, 3290, 3291, 3314, 3315, 3342, 3343, 3375, 3407, 3408, 3412, 3449, 3450, 3463, 3503, 3504, 3687, 3688, 3697, 3698, 3783, 3784, 3821, 3822, 3838, 3871, 3909, 3915, 3919, 3920, 4010, 4011, 4044, 4045, 4061, 4090, 4121, 4157, 4163, 4167, 4204, 4205, 4231, 4274, 4275, 4355, 4356, 4375, 4376, 4461, 4462, 4483, 4484, 4509, 4546, 4550, 4573, 4574, 4594, 4598, 4635, 4636, 4651, 4693, 4694, 4716, 4717, 4723, 4724, 4871, 4872, 4909, 4910, 4933, 4975, 4976, 4982, 4983, 5035, 5036, 5073, 5074, 5102, 5155, 5156, 5284, 5285, 5322, 5323, 5361, 5419, 5420, 5543, 5544, 5598, 5599, 5636, 5637, 5707, 5765, 5766, 5805, 5806, 5870, 5871, 5894, 5895, 5922, 5923, 5955, 5992, 5993, 6036, 6094, 6095, 6099, 6136, 6137, 6175, 6241, 6242, 6246, 6247, 6362, 6363, 6400, 6401, 6422, 6474, 6537, 6600, 6637, 6638, 6657, 6658, 6689, 6690, 6857, 6858, 6881, 6882, 6909, 6942, 6946, 6983, 6984, 7005, 7047, 7048, 7111, 7112, 7192, 7193, 7313, 7314, 7537, 7538, 7558, 7559, 7564, 7565, 7677, 7678, 7695, 7739, 7801, 7852, 7853, 7923, 7924, 7961, 8024, 8025, 8080, 8081, 8102, 8117, 8161, 8205, 8249, 8250, 8258, 8259, 8365, 8366, 8418, 8419, 8449, 8500, 8501, 8507, 8508, 8615, 8616, 8666, 8667, 8680, 8728, 8729, 8766, 8767, 8806, 8865, 8866, 8871, 8872, 8977, 8978, 9027, 9028, 9040, 9041, 9077, 9078, 9116, 9117, 9142, 9143, 9231, 9232, 9270, 9289, 9309, 9332, 9357, 9384, 9412, 9413, 9459, 9460, 9523, 9524, 9643, 9644, 9845, 9846, 10011, 10012, 10045, 10046, 10157, 10158, 10181, 10182, 10209, 10210, 10242, 10243, 10254, 10321, 10327, 10331, 10332, 10367, 10368, 10546, 10547, 10569, 10570, 10596, 10627, 10663, 10664, 10675, 10742, 10748, 10752, 10777, 10778, 10807, 10841, 10880, 10884, 10921, 10922, 10969, 11003, 11049, 11050, 11114, 11115, 11158, 11159, 11299, 11300, 11325, 11326, 11667, 11668, 11779, 11780, 11789, 11814, 11815, 11844, 11845, 11884, 11885, 11906, 11907, 11911, 11935, 11936, 11964, 11965, 11982, 12006, 12012, 12016, 12053, 12054, 12104, 12148, 12189, 12190, 12495, 12496, 12528, 12529, 12543, 12574, 12610, 12651, 12656, 12706, 12712, 12716, 12745, 12746, 12760, 12788, 12794, 12798, 12806, 12834, 12835, 12867, 12868, 12909, 12910, 12926, 12930, 12951, 12952, 12977, 12978, 12990, 13015, 13021, 13025, 13062, 13063, 13119, 13165, 13214, 13215, 13520, 13521, 13553, 13554, 13568, 13599, 13635, 13676, 13681, 13729, 13735, 13739, 13768, 13769, 13783, 13811, 13817, 13821, 13822, 13865, 13866, 14045, 14046, 14122, 14123, 14148, 14149, 14178, 14227, 14231, 14268, 14269, 14299, 14317, 14363, 14406, 14407, 14452, 14453, 14576, 14577, 14600, 14601, 14628, 14661, 14665, 14702, 14703, 14748, 14808, 14859, 14927, 14928, 14973, 14974, 15064, 15065, 15102, 15103, 15127, 15157, 15178, 15196, 15233, 15270, 15271, 15360, 15434, 15455, 15473, 15474, 15496, 15497, 15782, 15783, 15950, 15951, 16081, 16082, 16344, 16345, 16382, 16383, 16417, 16418, 16438, 16439, 16476, 16477, 16515, 16521, 16569, 16577, 16581, 16649, 16650, 16757, 16758, 16784, 16785, 16820, 16821, 16865, 16866, 16979, 16980, 17069, 17070, 17107, 17108, 17144, 17193, 17198, 17212, 17267, 17322, 17376, 17380, 17382, 17383, 17396, 17442, 17474, 17520, 17548, 17594, 17623, 17624, 17626, 17632, 17646, 17652, 17707, 17738, 17748, 17755, 17761, 17816, 17843, 17853, 17860, 17866, 17921, 17949, 17959, 17965, 17969, 17971, 17972, 18102, 18103, 18140, 18141, 18209, 18210, 18237, 18238, 18408, 18409, 18446, 18447, 18456, 18566, 18578, 18699, 18703, 18730, 18731, 18866, 18882, 18883, 18995, 18996, 19132, 19133, 19170, 19171, 19180, 19200, 19257, 19283, 19299, 19324, 19328, 19329, 19337, 19338, 19361, 19378, 19384, 19388, 19389, 19406, 19495, 19512, 19516, 19569, 19575, 19576, 19645, 19646, 19689, 19690, 19828, 19829, 19866, 19867, 19881, 19956, 19973, 19974, 19999, 20012, 20058, 20066, 20112, 20120, 20166, 20174, 20175, 20218, 20219, 20294, 20295, 20394, 20395, 20432, 20433, 20494, 20495, 20508, 20509, 20531, 20532, 20595, 20596, 20633, 20634, 20678, 20679, 20725, 20726, 20847, 20848, 20885, 20886, 20960, 20997, 20998, 21044, 21081, 21082, 21138, 21240, 21277, 21278, 21319, 21439, 21476, 21477, 21516, 21611, 21648, 21649, 21745, 21782, 21783, 21811, 21927, 21964, 21965, 21991, 22098, 22135, 22136, 22165, 22263, 22300, 22301, 22344, 22455, 22456, 22496, 22497, 22542, 22543, 22592, 22593, 22724, 22725, 22762, 22763, 22807, 22877, 22914, 22915, 22959, 23029, 23030, 23140, 23141, 23159, 23160, 23364, 23365, 23385, 23386, 23424, 23425, 23534, 23535, 23663, 23664, 23687, 23688, 23715, 23746, 23750, 23787, 23788, 23799, 23849, 23851, 23874, 23888, 23902, 23914, 23916, 23929, 23992, 24055, 24081, 24082, 24218, 24219, 24242, 24243, 24270, 24338, 24339, 24370, 24374, 24411, 24412, 24423, 24473, 24475, 24498, 24512, 24526, 24536, 24538, 24551, 24610, 24669, 24696, 24697, 24890, 24891, 24914, 24915, 24942, 25014, 25015, 25046, 25050, 25087, 25088, 25099, 25149, 25151, 25174, 25188, 25202, 25212, 25214, 25227, 25291, 25355, 25381, 25382, 25532, 25533, 25541, 25542, 25681, 25682, 25705, 25706, 25733, 25777, 25778, 25809, 25813, 25850, 25851, 25862, 25912, 25914, 25937, 25951, 25961, 26057, 26061, 26063, 26077, 26167, 26257, 26258, 26274, 26275, 26285, 26286, 26539, 26540, 26563, 26564, 26591, 26665, 26666, 26698, 26702, 26739, 26740, 26778, 26797, 26856, 26862, 26878, 26904, 26906, 26921, 26922, 27161, 27162, 27185, 27186, 27213, 27322, 27323, 27355, 27359, 27396, 27397, 27439, 27460, 27521, 27552, 27565, 27635, 27668, 27738, 27771, 27781, 27782, 27912, 27913, 27936, 27937, 27964, 28013, 28014, 28046, 28050, 28087, 28088, 28132, 28153, 28173, 28234, 28268, 28269, 28286, 28287, 28293, 28294, 28342, 28343, 28380, 28381, 28426, 28487, 28584, 28611, 28612, 28632, 28665, 28675, 28676, 28732, 28733, 28770, 28771, 28816, 28877, 28978, 29005, 29006, 29030, 29067, 29068, 29095, 29096, 29171, 29172, 29343, 29344, 29357, 29402, 29409, 29427, 29428, 29461, 29462, 29481, 29482, 29489, 29490, 29615, 29616, 29657, 29658, 29813, 29814, 29851, 29852, 29876, 29898, 29900, 29980, 29981, 30065, 30066, 30134, 30135, 30226, 30227, 30252, 30253, 30282, 30283, 30340, 30341, 30345, 30382, 30383, 30437, 30490, 30588, 30676, 30734, 30761, 30762, 30793, 30834, 30838, 30863, 30864, 30893, 30955, 30959, 30996, 30997, 31029, 31075, 31152, 31189, 31190, 31217, 31243, 31245, 31342, 31343, 31370, 31371, 31472, 31473, 31510, 31511, 31549, 31575, 31587, 31665, 31666, 31697, 31698, 31703, 31704, 31756, 31757, 31840, 31841, 31878, 31879, 31914, 31965, 32006, 32043, 32044, 32070, 32082, 32191, 32192, 32276, 32277, 32284, 32304, 32341, 32342, 32389, 32440, 32458, 32471, 32472, 32557, 32558, 32645, 32646, 32804, 32805, 32842, 32843, 32878, 32929, 32970, 33007, 33008, 33041, 33150, 33151, 33235, 33236, 33284, 33285, 33322, 33323, 33378, 33379, 33465, 33466, 33503, 33504, 33560, 33575, 33576, 33629, 33630, 33733, 33734, 33900, 33901, 33938, 33939, 33974, 34025, 34066, 34103, 34104, 34145, 34233, 34234, 34318, 34319, 34374, 34375, 34412, 34413, 34476, 34477, 34571, 34572, 34609, 34610, 34674, 34675, 34738, 34739, 34854, 34855, 34880, 34881, 34911, 34965, 34969, 35006, 35007, 35068, 35170, 35171, 35189, 35190, 35291, 35292, 35495, 35496, 35636, 35637, 35658, 35659, 35684, 35685, 35758, 35759, 35763, 35800, 35801, 35855, 35856, 35875, 35899, 35925, 35929, 36034, 36037, 36058, 36081, 36109, 36168, 36174, 36225, 36227, 36228, 36316, 36317, 36344, 36345, 36365, 36397, 36432, 36527, 36570, 36625, 36654, 36655, 36750, 36751, 36772, 36773, 36798, 36799, 36914, 37029, 37145, 37269, 37270, 37274, 37314, 37315, 37444, 37445, 37482, 37483, 37495, 37527, 37551, 37552, 37583, 37584, 37621, 37622, 37642, 37664, 37665, 37779, 37780, 37819, 37853, 37854, 37974, 37975, 38100, 38101, 38138, 38139, 38161, 38190, 38194, 38306, 38309, 38330, 38365, 38414, 38464, 38470, 38510, 38549, 38598, 38604, 38641, 38643, 38670, 38671, 38726, 38727, 38801, 38802, 38893, 38894, 38926, 38966, 38967, 39067, 39068, 39114, 39115, 39140, 39172, 39205, 39206, 39432, 39433, 39507, 39583, 39584, 39630, 39690, 39691, 39724, 39776, 39777, 39829, 39888, 39889, 39917, 39918, 40005, 40112, 40156, 40183, 40184, 40347, 40348, 40380, 40381, 40505, 40506, 40667, 40668, 40705, 40706, 40775, 40820, 40822, 40928, 40930, 40953, 40984, 41020, 41082, 41088, 41092, 41122, 41220, 41265, 41266, 41500, 41501, 41618, 41619, 41630, 41631, 41676, 41677, 41785, 41786, 41836, 41864, 41891, 41918, 41928, 41929, 41945, 41946, 41972, 41973, 42010, 42011, 42046, 42097, 42134, 42135, 42150, 42204, 42205, 42272, 42273, 42310, 42311, 42359, 42413, 42414, 42434, 42435, 42472, 42473, 42523, 42579, 42580, 42607, 42608, 42745, 42746, 42761, 42762, 42970, 42971, 42992, 42993, 43022, 43023, 43046, 43057, 43107, 43113, 43119, 43123, 43160, 43161, 43206, 43256, 43257, 43294, 43295, 43319, 43320, 43348, 43349, 43388, 43458, 43464, 43468, 43469, 43472, 43473, 43497, 43498, 43526, 43527, 43566, 43638, 43644, 43648, 43685, 43686, 43709, 43710, 43725, 43726, 43822, 43823, 43844, 43845, 43874, 43875, 43898, 43909, 43959, 43965, 43971, 43972, 43986, 44031, 44037, 44041, 44078, 44079, 44124, 44155, 44156, 44209, 44210, 44343, 44344, 44469, 44470, 44614, 44615, 44803, 44804, 44835, 44836, 44964, 44965, 45014, 45015, 45052, 45053, 45107, 45176, 45177, 45238, 45239, 45378, 45379, 45491, 45492, 45529, 45530, 45589, 45635, 45717, 45783, 45838, 45852, 45929, 46004, 46081, 46156, 46169, 46217, 46256, 46304, 46344, 46381, 46382, 46413, 46480, 46481, 46560, 46561, 46716, 46717, 46754, 46755, 46825, 46871, 46953, 47019, 47074, 47087, 47135, 47174, 47222, 47262, 47299, 47300, 47331, 47398, 47399, 47437, 47438, 47540, 47541, 47556, 47557, 47599, 47635, 47698, 47699, 47743, 47780, 47843, 47844, 47887, 47940, 48020, 48021, 48076, 48077, 48247, 48248, 48358, 48359, 48475, 48476, 48501, 48502, 48531, 48532, 48639, 48750, 48751, 48755, 48777, 48778, 48804, 48805, 48896, 48992, 48993, 48997, 49034, 49035, 49093, 49203, 49287, 49300, 49402, 49504, 49607, 49710, 49711, 49774, 49775, 49864, 49865, 49902, 49903, 49993, 50043, 50123, 50136, 50227, 50318, 50409, 50410, 50512, 50513, 50550, 50551, 50571, 50601, 50652, 50667, 50668, 50734, 50735, 50893, 50894, 50931, 50932, 50944, 50965, 51014, 51027, 51056, 51116, 51117, 51153, 51166, 51207, 51247, 51251, 51252, 51280, 51310, 51311, 51339, 51383, 51440, 51441, 51559, 51560, 51597, 51598, 51610, 51631, 51680, 51693, 51722, 51723, 51810, 51811, 51835, 51836, 51928, 51929, 51933, 51934, 52080, 52081, 52102, 52154, 52161, 52176, 52190, 52204, 52216, 52218, 52231, 52296, 52361, 52426, 52491, 52556, 52621, 52686, 52751, 52752, 52808, 52809, 52841, 52873, 52899, 52900, 53051, 53052, 53126, 53127, 53315, 53316, 53326, 53327, 53419, 53420, 53551, 53643, 53652, 53699, 53703, 53704, 53720, 53721, 53781, 53782, 53920, 54036, 54046, 54090, 54094, 54095, 54139, 54140, 54209, 54210, 54287, 54288, 54422, 54423, 54448, 54449, 54478, 54512, 54551, 54555, 54587, 54588, 54624, 54668, 54672, 54709, 54710, 54738, 54781, 54818, 54819, 54871, 54893, 54962, 54963, 54981, 54982, 55051, 55052, 55075, 55128, 55166, 55167, 55187, 55188, 55293, 55294, 55315, 55316, 55341, 55376, 55380, 55405, 55406, 55435, 55474, 55478, 55515, 55516, 55526, 55549, 55598, 55602, 55642, 55685, 55747, 55759, 55801, 55802, 56022, 56023, 56250, 56251, 56394, 56395, 56437, 56438, 56612, 56613, 56642, 56643, 56669, 56738, 56742, 56743, 56771, 56772, 56864, 56865, 56894, 56895, 56921, 56966, 56970, 56971, 57004, 57005, 57128, 57129, 57209, 57210, 57372, 57401, 57402, 57428, 57470, 57474, 57526, 57549, 57550, 57577, 57585, 57593, 57597, 57667, 57711, 57712, 57765, 57786, 57787, 57795, 57799, 57858, 57887, 57888, 57914, 57950, 57954, 57955, 58049, 58050, 58087, 58088, 58103, 58121, 58158, 58159, 58213, 58214, 58493, 58494, 58523, 58549, 58579, 58585, 58627, 58668, 58674, 58680, 58684, 58685, 58759, 58760, 58778, 58805, 58825, 58832, 58836, 58837, 58862, 58863, 58881, 58908, 58964, 58971, 58975, 58976, 58996, 58997, 59090, 59091, 59129, 59146, 59180, 59185, 59198 ] }
{ "red_pajama_v2": { "ccnet_original_length": 59198, "ccnet_original_nlines": 1850, "rps_doc_curly_bracket": 0.01052400004118681, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.17663773894309998, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.022194920107722282, "rps_doc_frac_lines_end_with_ellipsis": 0.005942729767411947, "rps_doc_frac_no_alph_words": 0.39451655745506287, "rps_doc_frac_unique_words": 0.21954461932182312, "rps_doc_mean_word_length": 7.363304138183594, "rps_doc_num_sentences": 1125, "rps_doc_symbol_to_word_ratio": 0.022962909191846848, "rps_doc_unigram_entropy": 6.191162586212158, "rps_doc_word_count": 6017, "rps_doc_frac_chars_dupe_10grams": 0.11468231678009033, "rps_doc_frac_chars_dupe_5grams": 0.2518451511859894, "rps_doc_frac_chars_dupe_6grams": 0.19591468572616577, "rps_doc_frac_chars_dupe_7grams": 0.15242071449756622, "rps_doc_frac_chars_dupe_8grams": 0.13585373759269714, "rps_doc_frac_chars_dupe_9grams": 0.11815822124481201, "rps_doc_frac_chars_top_2gram": 0.004062749911099672, "rps_doc_frac_chars_top_3gram": 0.006771239917725325, "rps_doc_frac_chars_top_4gram": 0.010856560431420803, "rps_doc_books_importance": -5915.509765625, "rps_doc_books_importance_length_correction": -5915.509765625, "rps_doc_openwebtext_importance": -2699.79052734375, "rps_doc_openwebtext_importance_length_correction": -2699.79052734375, "rps_doc_wikipedia_importance": -1536.8636474609375, "rps_doc_wikipedia_importance_length_correction": -1536.8636474609375 }, "fasttext": { "dclm": 0.8976060152053833, "english": 0.6877962946891785, "fineweb_edu_approx": 2.0126965045928955, "eai_general_math": 0.7636130452156067, "eai_open_web_math": 0.10209094732999802, "eai_web_code": 0.9852688312530518 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.452", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
4,699,101,003,577,950,000
Hermes - a semantic XML+MathML+Unicode e-publishing/self-archiving tool for LaTeX authored scientific articles Download latest version: 0.9.12, released on 28 Nov. 2006 Last update on by Romeo Anghelache Users, developers and/or philosophers are invited to ask/send comments on the Hermes blog or to send their comments directly to the author. Examples Some results of Hermes assisted conversions are hosted here; the source distribution also contains an article in LaTeX source, as well as a content-oriented source sample. What is Hermes? Hermes is a grammar based translator from (AMS)LaTeX to Unicode(utf-8) encoded XML+MathML+metadata. It is free software (software libre). Translating pure (AMS)TeX documents is not yet supported by Hermes, but this facility will be available sooner or later, depending on user interest. What for? Hermes is here to help individuals at self-archiving, libraries at long term-archiving, and publishers at having a reference document for their various specific services. How does it work? Hermes follows the steps below, in the specified order: 1. semantically seeds a copy of your TeX source 2. lets the TeX program do its job (texing) on this semantically enriched source 3. parses the resulting semantic dvi 4. generates the XML reference document, a semantic XML reflection of your TeX source. It works on Linux, Windows and OS X. What is the Hermes reference document? It is a Unicode XML document with a generic structure, containg free text  and various XML vocabularies. It contains the semantics Hermes managed to recover from the LaTeX source. Its validating XML-Schema will get published after this generic structure gets less fluid. Currently, the generic structure consists of: 1. sections 2. presentation hints (currently font names and sizes), 3. free text ((accented)TeX glyphs mapped to their Unicode equivalent), 4. metadata (title, author, date etc.) 5. bibliography, 6. internal and external references (no need for special LaTeX packages to get these activated in the XML), 7. tables, images These items are in a one-to-one relationship with the corresponding structures in the source/semantic dvi. This list is extensible: LaTeX environments automatically produce an XML structure. The XML vocabularies reflect the vocabularies used in the LaTeX source, e.g. mathematical regions in the LaTeX source correspond to MathML regions in the reference document. MathML is the only validable XML vocabulary implemented and supported currently by Hermes (SVG, and other vocabularies, like MARC, or other open standards, may follow,  if users are interested). Of MathML, only MathML-presentation is generated if Hermes is used to translate legacy LaTeX files (here, by legacy LaTeX files I mean sources which were not edited with semantic vocabularies in mind) without manual intervention on the source. MathML-content can only be generated if a newly authored LaTeX source uses the semantic LaTeX macros available in the Hermes distribution. Installation requirements A standard latex system, gcc, bison, flex, make and libxml/xslt should be on your system, in order to compile the program and have the proper example output (Windows developers can check out the Cygwin distribution, windows users will have a binary distribution (hermes.exe and seed.exe) issued (almost) synchronously with the source distribution.). Developers and Unix users can unpack the source distro and run make. After a successful 'make' you get: General use Follow the steps below: 'Validate' your source: 1. - write an (AMS)LaTeX text containing mathematical expressions; LaTeX it and fix all your editing errors ;). 2. - latex document.tex, if you didn't get a dvi return to step 1 Use Hermes to get the reference document (library) and renderable (publish) XML files: 1. - run ./seed document.tex, if you didn't get document.s.tex go to found-a-bug 2. - latex document.s.tex, if you didn't get a document.s.dvi go to found-a-bug 3. - run ./hermes document.s.dvi >document.lib.xml, if you didn't get a document.lib.xml go to found-a-bug 4. - run xsltproc pub.xslt document.lib.xml > document.pub.xml, if you didn't get a document.pub.xml go to found-a-bug 5. - now you can archive or send document.lib.xml to your library, and post your document.pub.xml on your website, along with the MathML-stylesheets for others to read/reuse. found-a-bug: either let the author know, fix it or ask around. Architecture of Hermes Developer's tips To do Credits Hermes is covered by GNU GPL, and developed by Romeo Anghelache. It was created in the EU funded MoWGLI research project (ended in Feb. 2005), as a task for LivingReviews, from Max Planck Institute for Gravitational Physics, Golm, Germany. Its further development was partially supported by : Alternative tools, developed by other fellows Valid XHTML 1.0!
{ "url": "http://hermes.roua.org/", "source_domain": "hermes.roua.org", "snapshot_id": "crawl=CC-MAIN-2015-18", "warc_metadata": { "Content-Length": "14542", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:JKCPUQAYTBT57ODKW2VJ7UK3A73FZHTU", "WARC-Concurrent-To": "<urn:uuid:883670b7-9e4d-4abf-a3d8-2cd5bd7aa072>", "WARC-Date": "2015-04-26T08:09:33Z", "WARC-IP-Address": "198.252.66.122", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:OU5YWCGDKHUPN6HC4GAD7DZZ7NEOJZNM", "WARC-Record-ID": "<urn:uuid:13082874-1d25-4bde-9d31-d0919ccbecde>", "WARC-Target-URI": "http://hermes.roua.org/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:b25b2d15-a16c-4924-858f-2550aad521e7>" }, "warc_info": "robots: classic\r\nhostname: ip-10-235-10-82.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-18\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for April 2015\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 111, 112, 170, 205, 345, 346, 355, 356, 528, 529, 545, 546, 684, 833, 834, 844, 845, 1016, 1017, 1035, 1036, 1092, 1142, 1225, 1264, 1353, 1390, 1391, 1430, 1431, 1536, 1611, 1702, 1748, 1762, 1820, 1894, 1935, 1954, 2064, 2084, 2275, 2449, 2644, 2888, 3027, 3028, 3054, 3055, 3405, 3474, 3509, 3510, 3522, 3523, 3547, 3571, 3685, 3753, 3840, 3923, 4005, 4114, 4235, 4412, 4425, 4475, 4476, 4499, 4500, 4517, 4518, 4524, 4525, 4533, 4534, 4774, 4827, 4828, 4874, 4875 ], "line_end_idx": [ 111, 112, 170, 205, 345, 346, 355, 356, 528, 529, 545, 546, 684, 833, 834, 844, 845, 1016, 1017, 1035, 1036, 1092, 1142, 1225, 1264, 1353, 1390, 1391, 1430, 1431, 1536, 1611, 1702, 1748, 1762, 1820, 1894, 1935, 1954, 2064, 2084, 2275, 2449, 2644, 2888, 3027, 3028, 3054, 3055, 3405, 3474, 3509, 3510, 3522, 3523, 3547, 3571, 3685, 3753, 3840, 3923, 4005, 4114, 4235, 4412, 4425, 4475, 4476, 4499, 4500, 4517, 4518, 4524, 4525, 4533, 4534, 4774, 4827, 4828, 4874, 4875, 4891 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4891, "ccnet_original_nlines": 81, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.30896684527397156, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.024366470053792, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.24561403691768646, "rps_doc_frac_unique_words": 0.47664836049079895, "rps_doc_mean_word_length": 5.295329570770264, "rps_doc_num_sentences": 84, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.343237400054932, "rps_doc_word_count": 728, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.0236057098954916, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.010376130230724812, "rps_doc_frac_chars_top_3gram": 0.012970170006155968, "rps_doc_frac_chars_top_4gram": 0.016861220821738243, "rps_doc_books_importance": -492.1805419921875, "rps_doc_books_importance_length_correction": -492.1805419921875, "rps_doc_openwebtext_importance": -259.8172607421875, "rps_doc_openwebtext_importance_length_correction": -259.8172607421875, "rps_doc_wikipedia_importance": -210.84764099121094, "rps_doc_wikipedia_importance_length_correction": -210.84764099121094 }, "fasttext": { "dclm": 0.23478108644485474, "english": 0.8426478505134583, "fineweb_edu_approx": 2.1169586181640625, "eai_general_math": 0.8790637850761414, "eai_open_web_math": 0.5135012269020081, "eai_web_code": 0.34581059217453003 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.467", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "025.0285", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "Library science", "level_3": "Library administration" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "17", "label": "Product Page" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-946,195,181,610,517,200
Win32LOB intunewin file upload process explained for automation • last updated: Sun, 29 Jan 2023 12:50:32 A few days ago a question reached me about creating Win32Lob applications including the intunewin file upload using the REST API. The create Win32Lob Graph API has no object available to store a file in, and the documentation doesn’t explain how to upload files while creating Win32Lob applications automated. That decided me to look into the file upload process and write this blog. Check the question and responses below 👇 Create Win32LOB App portal process The reason why there is no file placeholder available in the Graph API is because of the application creation process has multiple phases. The file upload process is a separate process for example. There is no direct connection to the application creation process. During the process, there is a breakout to an Azure Storage blob container. Create Win32LOB App in Intune In the screenshot below, I created a test Win32 app in the portal. I filled in the required fields where the screenshot shows the last page just before deployment. create-mobileApp-portal After hitting the create button the process starts. At the backend, when looking into the browser’s development, you will see the Win32 app is created without a file upload. create-mobileApp Request intunewin file version When the application deployment is finished, there is a response with the application ID. Based on the ID, the backend searches for the application you have just created. From that point, The first step is requesting a version number. The response is a version ID. In the case of a new application, the version ID is 1. content-version With the version, a file placeholder is created with file metadata. Meta data like the file’s name and size. In the placeholder creation background, a place is created on Azure storage. create-file-in-version file-metadata When the placeholder is created, a response is returned with an ID that represents the placeholder on the Azure storage location. Creating the Azure storage location can take a while. While waiting the browser requests the ID till the moment the storage location URL is returned. storage-id After a small minute, the storage location is present. Upload and commit intunewin file to Azure Storage Blob storage-location In the next step, the process takes the file and reads all file bytes in memory, and uses the blob placeholder information to stage the data. This is where the actual upload process starts. read-file-bytes When the file is read, the last step is to commit the staged file to the blob storage. In the commit phase, you see the request URL has the application ID (ID in Intune), the file version (which is 1 at the initial application creation), and the response ID (ID on the Azure Blob Storage). commit-phase In the next few requests, the browser waits till the commit status has been completed successfully by sending a GET request. get-commit-status commit-success Create Win32LOB App in automation Ok, now we know what phases we have, and multiple tasks are executed to create Win32LOB applications in Intune. In the next part of this blog, let’s take a look at how these steps look in the automation world. To keep the post readable and as short as possible, I only show the happy flow Create Win32LOB App in Intune automated The first step is creating the Win32LOB App in Intune. In this step, only the application is created with no file attached. To create a Win32LOB file in Intune automated with the REST API, I used the code below. The body is a JSON-formatted body with the application details. $win32LobBody = @" { "@odata.type": "#microsoft.graph.win32LobApp", "applicableArchitectures": "x64", "allowAvailableUninstall": false, "categories": [], "description": "Install-WinGetApplication.exe", "developer": "", "displayName": "Install-WinGetApplication.exe", "displayVersion": "", "fileName": "Install-WinGetApplication.intunewin", "installCommandLine": "test.exe", "installExperience": { "deviceRestartBehavior": "allow", "runAsAccount": "system" }, "informationUrl": "", "isFeatured": false, "roleScopeTagIds": [], "notes": "", "minimumSupportedWindowsRelease": "21H1", "msiInformation": null, "owner": "", "privacyInformationUrl": "", "publisher": "test", "returnCodes": [ { "returnCode": 0, "type": "success" }, { "returnCode": 1707, "type": "success" }, { "returnCode": 3010, "type": "softReboot" }, { "returnCode": 1641, "type": "hardReboot" }, { "returnCode": 1618, "type": "retry" } ], "rules": [ { "@odata.type": "#microsoft.graph.win32LobAppFileSystemRule", "ruleType": "detection", "operator": "notConfigured", "check32BitOn64System": false, "operationType": "exists", "comparisonValue": null, "fileOrFolderName": "test.exe", "path": "c:\\" } ], "runAs32Bit": false, "setupFilePath": "Install-WinGetApplication.exe", "uninstallCommandLine": "test.exe" } "@ $win32LobUrl = "https://graph.microsoft.com/beta/deviceAppManagement/mobileApps" $win32LobApp = Invoke-RestMethod -Uri $win32LobUrl -Body $win32LobBody -Headers $authHeader -Method Post -ContentType 'application/json' I stored the deployment output in the $win32LobApp variable. In the variable the Intune application ID is stored which is needed in the next phase. create-app-response Request intunewin file version The application is created and we have an Intune application ID. Now it is time to create a file placeholder on the Azure Storage. $Win32LobVersionUrl = "https://graph.microsoft.com/beta/deviceAppManagement/mobileApps/{0}/microsoft.graph.win32LobApp/contentVersions" -f $win32LobApp.id $win32LobAppVersionRequest = Invoke-RestMethod -Uri $Win32LobVersionUrl -Method "POST" -Body "{}" -Headers $authHeader $win32LobAppVersionRequest win32Lob-version-id It doesn’t matter how often you request a version, the version ID remains the same till the commit phase was successful. Create place holder for intunewin file version automated This is the part where it becomes more complex and the first time we pick up the intunewin file. To create a placeholder, we need file information like the name and the size. This is called the metadata. To get the file information I used the code below. I search the intunewin file and open it. An intunewin file has a detection.xml inside that holds the needed information. After reading the application information, we close the file to save memory. $filePath = (Get-childItem './Install-WinGetApplication.intunewin').FullName $IntuneWin32AppFile = [System.IO.Compression.ZipFile]::OpenRead($filePath) $DetectionXMLFile = $IntuneWin32AppFile.Entries | Where-Object { $_.Name -like "detection.xml" } $FileStream = $DetectionXMLFile.Open() $StreamReader = New-Object -TypeName "System.IO.StreamReader" -ArgumentList $FileStream -ErrorAction Stop $DetectionXMLContent = [xml]($StreamReader.ReadToEnd()) $FileStream.Close() $StreamReader.Close() $IntuneWin32AppFile.Dispose() intunewin-applicationinfo With the above-gathered information, I create a body with the needed information and send the request. $Win32LobFileBody = [ordered]@{ "@odata.type" = "#microsoft.graph.mobileAppContentFile" "name" = $DetectionXMLContent.ApplicationInfo.FileName "size" = [int64]$DetectionXMLContent.ApplicationInfo.UnencryptedContentSize "sizeEncrypted" = (Get-Item -Path $filePath).Length "manifest" = $null "isDependency" = $false } | ConvertTo-Json $Win32LobFileUrl = "https://graph.microsoft.com/beta/deviceAppManagement/mobileApps/{0}/microsoft.graph.win32LobApp/contentVersions/{1}/files" -f $win32LobApp.id, $win32LobAppVersionRequest.id $Win32LobPlaceHolder = Invoke-RestMethod -Uri $Win32LobFileUrl -Method "POST" -Body $Win32LobFileBody -Headers $authHeader placeholder-request The screenshot above shows the first response. As you can see the request is pending under the uploadState. Also, the isCommited object is False which means there is no file uploaded under the id yet. The last thing is the azureStorageUri which is still empty. The code below checks, based on the placeholder ID, if the request is handled. $storageCheckUrl = "https://graph.microsoft.com/beta/deviceAppManagement/mobileApps/{0}/microsoft.graph.win32LobApp/contentVersions/{1}/files/{2}" -f $win32LobApp.id, $win32LobAppVersionRequest.id, $Win32LobPlaceHolder.id $storageCheck = Invoke-RestMethod -Uri $storageCheckUrl -Method "GET" -Headers $authHeader $storageCheck storage-uri-success Now we have a placeholder to store the intunewin file at and start the real upload. Attention: The storage URL location is temporary and has an expiration time, make sure the upload is done within the expiration time Upload file to Win32 LOB App automated Uploading files through the HTTP protocol needs some attention. I’m not going into deep but explaining the basics. To upload files through HTTP we need to slice the packages in pieces, this is called chunking. Chunked encoding is cutting data into smaller “blocks.” Chunks are sent independently of one another, usually through a single persistent connection. The type is specified in the Transfer-Encoding header (in the first block). The receiver never sees the entire file (as it might not have been completely available in the first place — some examples being a server reading and sending a large file to a client, or generating a table of results from a database). For more information about chunking check: https://bunny.net/academy/http/what-is-chunked-encoding/ The whole upload process has the following steps in basics: • Extract intunewin file to an unencrypted file; • Chunk extracted file; • Upload the chunks; • Commit the upload; • Update the file version in the Intune application; Extract Intunewin file Before we can create chunks the file needs to be extracted in an unencrypted file. To extract the file the code below is needed. $Base64Key = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.EncryptionKey $Base64IV = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.InitializationVector $ExtractedIntuneWinFile = $FilePath + ".extracted" $ZipFile = [System.IO.Compression.ZipFile]::OpenRead($FilePath) #$IntuneWinFileName = Split-Path -Path $FilePath -Leaf $IntuneWinFileName = $DetectionXMLContent.ApplicationInfo.FileName $ZipFile.Entries | Where-Object { $_.Name -like $IntuneWinFileName } | ForEach-Object { [System.IO.Compression.ZipFileExtensions]::ExtractToFile($_, $ExtractedIntuneWinFile, $true) } $ZipFile.Dispose() $Key = [System.Convert]::FromBase64String($Base64Key) $IV = [System.Convert]::FromBase64String($Base64IV) $TargetFilePath = $FilePath + ".decoded" $TargetFilePathName = Split-Path -Path $TargetFilePath -Leaf [System.IO.FileStream]$FileStreamTarget = [System.IO.File]::Open($TargetFilePath, [System.IO.FileMode]::Create, [System.IO.FileAccess]::ReadWrite, [System.IO.FileShare]::None) $AES = [System.Security.Cryptography.Aes]::Create() [System.Security.Cryptography.ICryptoTransform]$Decryptor = $AES.CreateDecryptor($Key, $IV) [System.IO.FileStream]$FileStreamSource = [System.IO.File]::Open($ExtractedIntuneWinFile, [System.IO.FileMode]::Open, [System.IO.FileAccess]::Read, [System.IO.FileShare]::None) $FileStreamSourceSeek = $FileStreamSource.Seek(48l, [System.IO.SeekOrigin]::Begin) [System.Security.Cryptography.CryptoStream]$CryptoStream = New-Object -TypeName System.Security.Cryptography.CryptoStream -ArgumentList @($FileStreamTarget, $Decryptor, [System.Security.Cryptography.CryptoStreamMode]::Write) -ErrorAction Stop $buffer = New-Object byte[](2097152) while ($BytesRead = $FileStreamSource.Read($buffer, 0, 2097152)) { $CryptoStream.Write($buffer, 0, $BytesRead) $CryptoStream.Flush() } Calculate and create chunks With the basics in mind, I use the code block below to create chunks and send every chunk to the Azure Storage Blob. In the first part, I create 6MB chunks and calculate, based on the expanded file size, how many chunks there are. $ChunkSizeInBytes = 1024l * 1024l * 6l; $SASRenewalTimer = [System.Diagnostics.Stopwatch]::StartNew() $FileSize = (Get-Item -Path $ExtractedIntuneWinFile).Length $ChunkCount = [System.Math]::Ceiling($FileSize / $ChunkSizeInBytes) $BinaryReader = New-Object -TypeName System.IO.BinaryReader([System.IO.File]::Open($FilePath, [System.IO.FileMode]::Open, [System.IO.FileAccess]::Read, [System.IO.FileShare]::ReadWrite)) In my case, the intunewin file is that small I only have one chunk. Upload chunks In the loop below, I create chunks and load the bytes into it. Thereafter, I send every chunk and corresponding bytes to the storage location. $ChunkIDs = @() for ($Chunk = 0; $Chunk -lt $ChunkCount; $Chunk++) { $ChunkID = [System.Convert]::ToBase64String([System.Text.Encoding]::ASCII.GetBytes($Chunk.ToString("0000"))) $ChunkIDs += $ChunkID $Start = $Chunk * $ChunkSizeInBytes $Length = [System.Math]::Min($ChunkSizeInBytes, $FileSize - $Start) $Bytes = $BinaryReader.ReadBytes($Length) $CurrentChunk = $Chunk + 1 $Uri = "{0}&comp=block&blockid={1}" -f $storageCheck.azureStorageUri, $ChunkID $ISOEncoding = [System.Text.Encoding]::GetEncoding("iso-8859-1") $EncodedBytes = $ISOEncoding.GetString($Bytes) $Headers = @{ "x-ms-blob-type" = "BlockBlob" } $UploadResponse = Invoke-WebRequest $Uri -Method "Put" -Headers $Headers -Body $EncodedBytes -UseBasicParsing -ErrorAction Stop } In the last step, I finalize the chunk list and send an XML list to the storage location. $finalChunkUri = "{0}&comp=blocklist" -f $storageCheck.azureStorageUri $XML = '<?xml version="1.0" encoding="utf-8"?><BlockList>' foreach ($Chunk in $ChunkID) { $XML += "<Latest>$($Chunk)</Latest>" } $XML += '</BlockList>' Invoke-RestMethod -Uri $finalChunkUri -Method "Put" -Body $XML -ErrorAction Stop $BinaryReader.Close() $BinaryReader.Dispose() Commit upload The last step is to commit the chunks into the file at the storage location. To commit we head back to the XML content. In the XML content, we grab the encryption info. The encryption info is used to decrypt the file in the Intune environment. After creating, the encryption body is sent to the commit URL. This is the Azure Storage URL including the placeholder ID. The API request does not give a response. $Win32FileEncryptionInfo = @{ "fileEncryptionInfo" = [ordered]@{ "encryptionKey" = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.EncryptionKey "macKey" = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.macKey "initializationVector" = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.initializationVector "mac" = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.mac "profileIdentifier" = "ProfileVersion1" "fileDigest" = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.fileDigest "fileDigestAlgorithm" = $DetectionXMLContent.ApplicationInfo.EncryptionInfo.fileDigestAlgorithm } } | ConvertTo-Json $CommitResourceUri = "{0}/commit" -f $storageCheckUrl, $Win32LobPlaceHolder.id Invoke-RestMethod -uri $CommitResourceUri -Method "POST" -Body $Win32FileEncryptionInfo -Headers $authHeader After committing the file, I check the upload state. $CommitStatus = Invoke-RestMethod -uri $storageCheckUrl -Method GET -Headers $authHeader $CommitStatus Update file version At last, the code below tells the application which version is committed. $Win32AppCommitBody = [ordered]@{ "@odata.type" = "#microsoft.graph.win32LobApp" "committedContentVersion" = $win32LobAppVersionRequest.id } | ConvertTo-Json $Win32AppUrl = "{0}/{1}" -f $win32LobUrl, $win32LobApp.id Invoke-RestMethod -uri $Win32AppUrl -Method "PATCH" -Body $Win32AppCommitBody -Headers $authHeader commit-state Summary In this blog post, I explained in basics how to update (intunewin) files with the Graph API. The whole process is quite complex and I showed the happy flow with small code blocks. There are no checks and the code is not very efficient. Luckily there is a good PowerShell module that has all the logic and intelligence to upload intunewin files with the Graph API. I would recommend taking a look at Nicolaj Andersen’s PowerShell module IntuneWin32App. See the GitHub project at: https://github.com/MSEndpointMgr/IntuneWin32App or in the PowerShell gallery at: https://www.powershellgallery.com/packages/IntuneWin32App/1.3.6 Thank you for reading my blog win32lob intunewin file upload process explained for automation. I hope you got a bit inspired. Enjoy your day and happy automating 👋 comments powered by Disqus Related Posts Add Microsoft Store (WinGet) app with icon into Intune automated In the week of November 28, 2022, Microsoft released the new Microsoft Store which is implemented in Intune using the Windows Packager Manager. This is because the Microsoft Store for Business will be deprecated in the first quarter of 2023. Read more Monitor Intune using Azure Functions, PowerShell, Graph API and MS Teams Intune and the rest of Microsoft Endpoint Manager are growing. To keep your environment nice, clean and secure it is a good idea to monitor your MEM environment. Read more Deploy Intune settings catalog automated from scratch with Graph API I show in this blog how to create a device configuration profile based on the settings catalog in Intune. A while ago Icreated a profile with power settings and deployed the profile to all devices including a filter. Read more
{ "url": "https://www.rozemuller.com/win32lob-intunewin-file-upload-process-explained-for-automation/", "source_domain": "www.rozemuller.com", "snapshot_id": "CC-MAIN-2023-06", "warc_metadata": { "Content-Length": "567044", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:ODJDO4KPL2ZHW45N6PWZOVXRAJC6S2IV", "WARC-Concurrent-To": "<urn:uuid:0026582e-8bbc-4ad5-b3b4-6c3dd21a7095>", "WARC-Date": "2023-01-29T16:26:23Z", "WARC-IP-Address": "20.75.109.112", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:TVHKEB2NIXRNLERMQ5ISYD7ALIVFDCJE", "WARC-Record-ID": "<urn:uuid:0a015825-b17c-4865-b803-990b02d5b554>", "WARC-Target-URI": "https://www.rozemuller.com/win32lob-intunewin-file-upload-process-explained-for-automation/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:259883b1-3b62-47fd-9a41-d48bcdd3a58e>" }, "warc_info": "isPartOf: CC-MAIN-2023-06\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for January/February 2023\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-142\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 64, 65, 109, 110, 420, 494, 495, 536, 537, 572, 573, 712, 914, 915, 945, 946, 1110, 1111, 1135, 1136, 1310, 1311, 1328, 1329, 1360, 1361, 1532, 1626, 1681, 1682, 1698, 1699, 1767, 1885, 1886, 1923, 1924, 2204, 2205, 2271, 2272, 2327, 2328, 2345, 2346, 2536, 2537, 2553, 2554, 2844, 2845, 2858, 2859, 3002, 3003, 3018, 3019, 3053, 3054, 3264, 3343, 3344, 3384, 3385, 3661, 3662, 3681, 3683, 3738, 3780, 3822, 3848, 3904, 3929, 3985, 4015, 4074, 4116, 4147, 4193, 4230, 4241, 4271, 4300, 4331, 4352, 4402, 4434, 4455, 4492, 4521, 4546, 4560, 4593, 4627, 4642, 4656, 4692, 4726, 4741, 4755, 4791, 4828, 4843, 4857, 4893, 4930, 4945, 4959, 4995, 5027, 5041, 5052, 5071, 5085, 5162, 5203, 5248, 5295, 5338, 5379, 5427, 5458, 5472, 5483, 5512, 5570, 5613, 5615, 5618, 5699, 5836, 5837, 5985, 5986, 6006, 6007, 6038, 6039, 6170, 6171, 6326, 6445, 6472, 6473, 6493, 6494, 6615, 6616, 6673, 6674, 6929, 6930, 7128, 7129, 7206, 7282, 7379, 7418, 7524, 7580, 7600, 7622, 7652, 7653, 7679, 7680, 7783, 7784, 7816, 7878, 7946, 8035, 8091, 8119, 8148, 8167, 8360, 8483, 8484, 8765, 8766, 8845, 8846, 9068, 9160, 9174, 9175, 9195, 9196, 9280, 9281, 9414, 9415, 9454, 9455, 9665, 9891, 10126, 10127, 10227, 10228, 10288, 10289, 10340, 10366, 10389, 10412, 10467, 10468, 10491, 10492, 10621, 10622, 10701, 10786, 10837, 10901, 10956, 11023, 11111, 11208, 11210, 11229, 11283, 11335, 11376, 11437, 11613, 11665, 11757, 11934, 12017, 12260, 12297, 12364, 12412, 12438, 12440, 12441, 12469, 12470, 12701, 12702, 12742, 12804, 12864, 12932, 13119, 13120, 13188, 13189, 13203, 13204, 13347, 13348, 13364, 13417, 13530, 13556, 13596, 13668, 13714, 13745, 13746, 13829, 13898, 13949, 13967, 14006, 14012, 14144, 14146, 14147, 14237, 14238, 14309, 14368, 14399, 14440, 14442, 14465, 14466, 14547, 14569, 14593, 14594, 14608, 14609, 14853, 14854, 15019, 15020, 15050, 15089, 15188, 15280, 15386, 15475, 15526, 15622, 15727, 15733, 15752, 15753, 15832, 15941, 15942, 15995, 15996, 16086, 16100, 16101, 16121, 16122, 16196, 16197, 16231, 16294, 16356, 16375, 16433, 16532, 16533, 16546, 16547, 16555, 16556, 17180, 17181, 17276, 17345, 17346, 17373, 17374, 17388, 17389, 17454, 17455, 17697, 17698, 17708, 17709, 17782, 17783, 17945, 17946, 17956, 17957, 18026, 18027, 18244, 18245 ], "line_end_idx": [ 64, 65, 109, 110, 420, 494, 495, 536, 537, 572, 573, 712, 914, 915, 945, 946, 1110, 1111, 1135, 1136, 1310, 1311, 1328, 1329, 1360, 1361, 1532, 1626, 1681, 1682, 1698, 1699, 1767, 1885, 1886, 1923, 1924, 2204, 2205, 2271, 2272, 2327, 2328, 2345, 2346, 2536, 2537, 2553, 2554, 2844, 2845, 2858, 2859, 3002, 3003, 3018, 3019, 3053, 3054, 3264, 3343, 3344, 3384, 3385, 3661, 3662, 3681, 3683, 3738, 3780, 3822, 3848, 3904, 3929, 3985, 4015, 4074, 4116, 4147, 4193, 4230, 4241, 4271, 4300, 4331, 4352, 4402, 4434, 4455, 4492, 4521, 4546, 4560, 4593, 4627, 4642, 4656, 4692, 4726, 4741, 4755, 4791, 4828, 4843, 4857, 4893, 4930, 4945, 4959, 4995, 5027, 5041, 5052, 5071, 5085, 5162, 5203, 5248, 5295, 5338, 5379, 5427, 5458, 5472, 5483, 5512, 5570, 5613, 5615, 5618, 5699, 5836, 5837, 5985, 5986, 6006, 6007, 6038, 6039, 6170, 6171, 6326, 6445, 6472, 6473, 6493, 6494, 6615, 6616, 6673, 6674, 6929, 6930, 7128, 7129, 7206, 7282, 7379, 7418, 7524, 7580, 7600, 7622, 7652, 7653, 7679, 7680, 7783, 7784, 7816, 7878, 7946, 8035, 8091, 8119, 8148, 8167, 8360, 8483, 8484, 8765, 8766, 8845, 8846, 9068, 9160, 9174, 9175, 9195, 9196, 9280, 9281, 9414, 9415, 9454, 9455, 9665, 9891, 10126, 10127, 10227, 10228, 10288, 10289, 10340, 10366, 10389, 10412, 10467, 10468, 10491, 10492, 10621, 10622, 10701, 10786, 10837, 10901, 10956, 11023, 11111, 11208, 11210, 11229, 11283, 11335, 11376, 11437, 11613, 11665, 11757, 11934, 12017, 12260, 12297, 12364, 12412, 12438, 12440, 12441, 12469, 12470, 12701, 12702, 12742, 12804, 12864, 12932, 13119, 13120, 13188, 13189, 13203, 13204, 13347, 13348, 13364, 13417, 13530, 13556, 13596, 13668, 13714, 13745, 13746, 13829, 13898, 13949, 13967, 14006, 14012, 14144, 14146, 14147, 14237, 14238, 14309, 14368, 14399, 14440, 14442, 14465, 14466, 14547, 14569, 14593, 14594, 14608, 14609, 14853, 14854, 15019, 15020, 15050, 15089, 15188, 15280, 15386, 15475, 15526, 15622, 15727, 15733, 15752, 15753, 15832, 15941, 15942, 15995, 15996, 16086, 16100, 16101, 16121, 16122, 16196, 16197, 16231, 16294, 16356, 16375, 16433, 16532, 16533, 16546, 16547, 16555, 16556, 17180, 17181, 17276, 17345, 17346, 17373, 17374, 17388, 17389, 17454, 17455, 17697, 17698, 17708, 17709, 17782, 17783, 17945, 17946, 17956, 17957, 18026, 18027, 18244, 18245, 18254 ] }
{ "red_pajama_v2": { "ccnet_original_length": 18254, "ccnet_original_nlines": 353, "rps_doc_curly_bracket": 0.003506080014631152, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.1931850165128708, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.028442690148949623, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.3596170246601105, "rps_doc_frac_unique_words": 0.3431621789932251, "rps_doc_mean_word_length": 6.910015106201172, "rps_doc_num_sentences": 273, "rps_doc_symbol_to_word_ratio": 0.0014080499531701207, "rps_doc_unigram_entropy": 5.632516860961914, "rps_doc_word_count": 1967, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.036859918385744095, "rps_doc_frac_chars_dupe_6grams": 0.024867570027709007, "rps_doc_frac_chars_dupe_7grams": 0.020600350573658943, "rps_doc_frac_chars_dupe_8grams": 0.008240140043199062, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.00956445001065731, "rps_doc_frac_chars_top_3gram": 0.0058858199045062065, "rps_doc_frac_chars_top_4gram": 0.004193639848381281, "rps_doc_books_importance": -1281.0345458984375, "rps_doc_books_importance_length_correction": -1281.0345458984375, "rps_doc_openwebtext_importance": -727.6671142578125, "rps_doc_openwebtext_importance_length_correction": -727.6671142578125, "rps_doc_wikipedia_importance": -805.1839599609375, "rps_doc_wikipedia_importance_length_correction": -805.1839599609375 }, "fasttext": { "dclm": 0.5088319778442383, "english": 0.755003035068512, "fineweb_edu_approx": 2.5220394134521484, "eai_general_math": 0.42706239223480225, "eai_open_web_math": 0.12840771675109863, "eai_web_code": 0.7167531251907349 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.445", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.028", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-5,313,969,304,292,499,000
Ad Our DNA is written in Swift Jump WWDC and Women When I attended my first WWDC in 2011 there was one gender-related observation I made which deeply troubled me: For the first time ever I had to queue in front of the male toilets. Up until this point I had been holding the belief that queues can only form in front of the female toilets. As with any belief your brain is filtering the world to find reasons and explanations. So my own working theory had been that this toilet queue conundrum must be  due to a male anatomical advantage, being able to “shoot from the hip”. Of course – given the same number of people – ladies would take longer, having to sit down, be more carefully washing their hands, powdering their noses and doing a bit of idle conversation. Men on the other hand would go pee like a SWAT team. In, Shoot the Fly, Out, done in 60 seconds. Washing our hands? Not necessary, we are engineers, we hit our targets. Not me, of course. I had never been aggressively domesticated by women to sit down for number 1. So I typically wash my hands because I don’t have the urge to prove to myself that my aim is flawless. Even though I like to believe it is. On this background I’m sure you understand my puzzlement. The second reason for it was that I never really worked in a male-dominated environment. Before I became an independent software engineer, I worked for some tech companies, but for the most part on my own, being the only Windows desktop support guy or being the only Telco Billing specialist on staff. Formative Years I have to admit that I was more of a lone wolf than a party animal. Not going out drinking also contributed to me staying out of male groups. The groups that you spend most of your time in while you are young must be contributing to your view of the world. My work places rarely shared Internet pictures of female car parking disasters. Male peers couldn’t infect me with misogyny, since I didn’t have anyone I could remotely consider to be my peer. If there was any – however brief – phase of female antipathy then only around the age of 20 when I was still a virgin, because I couldn’t “get any”. My hypotheses at that point in my life revolved around finding reasons why no woman seemed to be able to like or love me. That was also the time when those kind of “systems” started to pop up for “players” and how to “lay” any women. The core message being: you need to be arrogant and funny. If you treat women on a condescending manner then they would let you “bed” them. Doesn’t work yet? Well then you where not condescending enough! Admittedly I tried out a few tricks there and “scored some”. But I am not proud of that. Desperate, peer-less male engineers are the core audience for anybody promising a system for them to solve their loneliness problem. There is a whole industry catering to these suckers. Rise of the Internet Men at Work While I was going to school to get my engineer’s degree we had a fair share of female would-be-developers attending, and I met a good number of women in most of the employments I had. So I never got a feeling that something must be wrong. I think my first actual contact with gender-related violence was somebody showing me an image he had gotten by email. Yes, at that time there were not websites for that kind of thing, let alone Twitter. It was a picture of a jumble of cars being parked totally chaotically. The subtitle read “Feminist Convention Parking”. It was not funny for me back then, but I found it curious that other men would find that laughter-inducing. Why are clichés funny? That was about the only kind of women disparagement I got in contact with. I was probably lucky enough in that matter, lonesome but untarnished. I grew up with the belief that women are equal to men in every aspect, accept that some might have dubious parallel parking skills. If anything then I was admiring women because I had heard that the male Y-chromosome was a mutation of the female X. While this mutation brought with it some advantages (like being able to pee standing up), apparently it also causes some problems. Bearers of the Y lack the full spectrum of emotion and communication. They live shorter. They cannot create life. I felt a little bit handicapped being a man, but learned to live with it. No point in being jealous of women, or being angry at them for having advantages over men. As the Internet grew larger and more prevalent communication and “social networking” exploded. When this happens information hierarchies – with a single entity disseminating information to all below it – tumble. Instead you have the information flow more akin to a network where some nodes are better connected then others, but in the end all nodes of the network get the information. This also means that nowadays the light is shone on every tiny infraction. Anything good or bad is blogged about, dissected and opined ad nauseam. Misogynist are outed in a heart beat. This social network – which many call Web 2.0 – has become enough of a power to influence elections and to destroy companies that misstep. Programmer-ettes When I visited San Francisco in 2011 I learned that it seems to be hard for companies to hire iOS developers. Especially on iOS you were able to build an app, have Apple sell it for you and then call yourself “indie”. And the ones that didn’t want to be self-employed where gobbled up by companies like Apple. No available developers were to be found. There are companies like Etsy who had the same problem with too few developers. The theory goes that if you want more developers on the market you need to “activate” the female population. If you had the same number of female developers as you had male then you would have double the number of candidates to hire. Etsy managed to grow the number of female engineers by 500% (video) by establishing a summer scholarship program. They invited young women to San Francisco, paid for living expenses and contracted a company to do programming courses on location in the Etsy offices. The lion share of attendees of this program opted to stay at Etsy, with a much larger than usual portion of women. I have yet to see any other strategy that even comes close to their rate of success. One often cited reason for the lack of female developers is that they probably didn’t get enough encouragement as teenagers. I often hear people argument that if women wanted to they would be totally equal with men. There are no barriers to them being that any more. Those people fail to see that they themselves are part of the problem. A lack of barriers does not equate to forward momentum. Men who think that there is no problem anyway won’t act. Why bother if your world is ok? WWDC Statistics For the third time in a row I am scouring Tweets for information on who got a WWDC ticket and who activated it. The people I find I put on my WWDC 2013 Attendees Twitter list. At the time of this writing I have collected 324 list members, of which 5 are women. That is 1.5%. In my experience less then 10% of Apple developers use Twitter, but nevertheless I see no reason why there would be a gender difference in tweeting. I think my number should be in the general vicinity of the actual number. Somebody asked an Apple employee at WWDC 2012 and got the, albeit inofficial, information of 3.5% female attendance. The WWDC Girls Twitter account follows 216 women who stated that they attend WWDC. That would be about 4% of 5500 tickets. Only Apple knows the real number but these data points suggest that the number of female WWDC attendees must be in the low single digit range. 3.5% sounds quite plausible to me. Apple’s credo is “to treat everybody the same”, regardless of his/her parameters. But personally I fear that WWDC has turned into an unwilling act of gender inequality. There has been much discussion about if and how Apple should change WWDC to be “more fair”. I believe that this overlooks a larger issue related to gender discrimination. I would venture a bet that most of the people able to afford travel, accommodation and entry to WWDC can do so because a company is footing the bill. There is some commercial interest in these people learning about the latest and greatest Apple technologies. Put differently I am sending somebody to a conference that costs me around $4000 per person if I believe that this person is able to add at least as much value over the coming year to my business. But since last year getting tickets has turned into a crap shoot. My fear is that companies are securing a ticket for their lead developers and development managers first to be certain that they can attend, because them getting the infos would be way more valuable than if they sent lower level engineers. A dev lead can spend more quality time with Apple engineers and talk to the app store review team on behalf of the company’s interests. Because of this we probably will get even fewer female attendees. Of the few female engineers even fewer would be holding a sufficiently high up position to be sent to WWDC. Women and Tablet WWDC Scholarship for Women Apple is literally giving away 150 tickets out of the 5500 to students. They have been doing that for many years now since it is in Apple’s best interest to get on a good footing with people while they are at school. In exchange for such a ticket students need to create and present an app that tells Apple something about themselves. One could argue that this program is unfair to the rest of us hard working software developers. I need to scrape together about a month’s worth of earnings to be able to afford to travel to WWDC. And I think that I have done more for Apple ‘s business in my 4 full time years, than most of these students will do in their lifetime. Even calling it a “Student Scholarship” is a misnomer. A true scholarship does not only pay for a ticket for an event but also takes other burdens off the student’s shoulders. What Etsy did is a true scholarship. What Apple does is just giving away free event tickets based in part on merit. This is why I propose for Apple to adapt their “Scholarship” program to a be a true scholarship program. They would pay for living expenses and training for a larger group based on merit. And not just leading up to WWDC but throughout the year. Of course nowadays you have to do such a problem gender-neutrally, but Etsy’s experience has shown that you tend to get equal numbers of both sexes in such scholarship programs. Apple then would be able to get first pick of the engineers coming out of the program and also they could give the student tickets to participants of their new scholarship program. The development public would see this as much “fairer” because you would have to learn programming for several months instead of being awarded a lucky break based on a simple quick app you whip up. F’in BSc The main hinderance that US-based companies have related to hiring developers is that they require their on candidates to have a Bachelor of Computer Science (BSc). If you don’t have an academic degree most companies wouldn’t even talk to you, regardless of your other qualifications. I couldn’t work for Apple even if I wanted to, because I don’t possess a BSc nor any other academic degree. Instead I have an engineers diploma which i got from the Austrian government after a 2-year school and 3 years of working. My “engineer’s degree” is civil and not academic. So I could bring much to Apple, but they wouldn’t ever consider me because of my lack of BSc. Also I would probably not even get a US work visa since for these you also need a BSc. The US work visa situation is a horror story in its own right. This reliance on academic degrees is especially pronounced in the US of A. Programming was an academic endeavor 30 years ago, but in times of the Internet everybody can learn to program, and program well. If I need a certain algorithm I can look it up on Wikipedia or maybe find it explained on Stack Overflow or better yet find it already implemented in Open Source software. To participate in Apple’s above mentioned “Student Scholarship” you need to be enrolled as a student for a BSc degree. Reliance on academic diplomas or a specific age range or school attendance is a form of discrimination of it’s own. I have no numbers, but it is my feeling that this BSc-addiction also blinds companies to many amazing female prospects who didn’t have the necessary funding to go to college. Some people see this a left-over from a patriarchal age where male managers where judging people’s worthiness based on their academic degrees. Conclusion There are too few women attending WWDC, period. This is a symptom of a large problem that needs to be addressed im my humble opinion by removing the outmoded reliance on academic achievements and by sponsoring young people who are interested in learning to program. A true scholarship program needs to go over several months, unburden students from living expenses and include real work and learning. Companies like Etsy have shown that such a program will get an even number of males and females with the final result of ending up with an overall greater number of developers, of which females form a much higher than usual percentage. Apple should be a shining example and “sherlock” the scholarship idea. In the least they should stop calling a scholarship which is none. Making apps has ceased to be a science a couple of years ago, it became vocational. Companies who still think that they need academics for programmers are only hurting themselves. Categories: Apple 18 Comments » 1. > Some people see this a left-over from a patriarchal age where male managers where judging people’s worthiness based on their academic degrees. Actually, it’s just about precisely the opposite. It’s to *avoid* having to make judgements. The problem with the US employment system is that if you’re any sizeable corporation (I think this kicks in at 20 employees or so most places) that privately administers any type of competitive intelligence or aptitude test that in practice does not provide results precisely in line with the ethnic and gender makeup of your applicant pool, WAZOO you are buried under discrimination lawsuits. And it makes absolutely no difference whether your test is demonstrably directly related to job performance or not. Politically incorrect results are incontrovertible proof of your evil intent. The easiest way to attempt to provide yourself a high quality workforce given the inability to actually pick the best is via credentialism. If you make a blanket B.Sc.(Comp.) or whatever requirement, then you only need to hire the correct ethnic/gender mix of those who apply *meeting that requirement* to stay out of the courts. Much easier! And if that means that anyone without the means/inclination to attain the picked credential is therefore out of luck no matter how clever they are or how much they deserve an opportunity … well, if *you* were a big employer, what would *you* do differently? 2. When apple computers were # 1 in education, graphic arts, and printing WWDCs seemed to be 40% women. This was years before Apple/Next merger. 3. The AUC (Apple University Consortium) in Australia offered true Scholarship to students in the form of a WWDC ticket and funds towards airfares and accommodation in San Francisco. Of course Apple took the decision last year to stop funding this program (after 25 years) so that says a lot about their interest (and lack thereof) in the Higher-Education market and students in general… 4. Silly me, I thought WWDC was open to anyone buying a ticket… Assuming you do so before it sells out. So who are you blaming it on that there are too few money and academic achievements and sponsorships and scholarships and WHAT? If they want to go, have them buy a ticket. 5. I am a female programming student that applied for a WWDC scholarship ticket. I do not yet know if I got one or not. I have a bachelor’s degree in Journalism and I am currently attending a community college in Madison, WI. Apple does open up the scholarship program to students from our college. We have had two students win scholarships for the last few years to WWDC. Apple also has a scholarship program in the true sense of the word called Cocoa Camp where they fly you to Apple headquarters and you work with engineers for a week. I did not complete the application for that because I ran out of time. My two cents about why there are so few women in programming is that we tend to get down on ourselves when we do not understand something. We are afraid to ask questions for fear of looking stupid and we tend to believe no one else has ever felt the way we do and we must be failures. I know at my school most students take the programming classes multiple times because they are so difficult. If you are taking the class for the first time and you are next to someone who already has heard the information before, you tend to feel dumb and decide that since this is “easy” for everyone else that you are not cut out to be a programmer. I know my teacher spends a great deal of time with female students assuring them that they can do this and that they are not stupid. If more teachers did that then I think there would be more female programmers.
{ "url": "https://www.cocoanetics.com/2013/05/wwdc-and-women/", "source_domain": "www.cocoanetics.com", "snapshot_id": "CC-MAIN-2024-38", "warc_metadata": { "Content-Length": "65631", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:SLERETFBAVK6BMJMAODE2F7ZO5OFGGKT", "WARC-Concurrent-To": "<urn:uuid:e3e8b080-9f0d-4385-92f2-f204867c4909>", "WARC-Date": "2024-09-18T21:21:10Z", "WARC-IP-Address": "23.88.72.186", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:QPZ3BDATV62GTBZPDU2XJQ24V5NQTNYT", "WARC-Record-ID": "<urn:uuid:af4734bd-20d1-433a-aee1-fede64a64614>", "WARC-Target-URI": "https://www.cocoanetics.com/2013/05/wwdc-and-women/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:40406327-a0a8-4644-b7c0-ee49990519ec>" }, "warc_info": "isPartOf: CC-MAIN-2024-38\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-15\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 3, 4, 32, 37, 38, 53, 54, 343, 344, 939, 940, 1177, 1178, 1538, 1539, 1555, 1556, 1813, 1814, 2278, 2279, 2595, 2596, 2871, 2872, 2893, 2894, 2906, 2907, 3349, 3350, 3601, 3602, 3879, 3880, 4316, 4317, 4408, 4409, 4794, 4795, 5119, 5120, 5137, 5138, 5490, 5491, 5805, 5806, 6187, 6188, 6273, 6274, 6612, 6613, 6758, 6759, 6775, 6776, 7274, 7275, 7515, 7516, 7694, 7695, 8035, 8036, 8492, 8493, 8559, 8560, 8936, 8937, 9111, 9112, 9129, 9130, 9157, 9158, 9493, 9494, 9826, 9827, 10119, 10120, 10543, 10544, 10923, 10924, 10933, 10934, 11500, 11501, 11745, 11746, 12123, 12124, 12243, 12244, 12535, 12536, 12679, 12680, 12691, 12692, 12958, 12959, 13330, 13331, 13649, 13650, 13651, 13669, 13670, 13684, 13685, 13835, 13836, 13933, 13934, 14526, 14527, 15132, 15133, 15280, 15281, 15671, 15672, 15950, 15951, 16563, 16564, 16853, 16854, 17210, 17211 ], "line_end_idx": [ 3, 4, 32, 37, 38, 53, 54, 343, 344, 939, 940, 1177, 1178, 1538, 1539, 1555, 1556, 1813, 1814, 2278, 2279, 2595, 2596, 2871, 2872, 2893, 2894, 2906, 2907, 3349, 3350, 3601, 3602, 3879, 3880, 4316, 4317, 4408, 4409, 4794, 4795, 5119, 5120, 5137, 5138, 5490, 5491, 5805, 5806, 6187, 6188, 6273, 6274, 6612, 6613, 6758, 6759, 6775, 6776, 7274, 7275, 7515, 7516, 7694, 7695, 8035, 8036, 8492, 8493, 8559, 8560, 8936, 8937, 9111, 9112, 9129, 9130, 9157, 9158, 9493, 9494, 9826, 9827, 10119, 10120, 10543, 10544, 10923, 10924, 10933, 10934, 11500, 11501, 11745, 11746, 12123, 12124, 12243, 12244, 12535, 12536, 12679, 12680, 12691, 12692, 12958, 12959, 13330, 13331, 13649, 13650, 13651, 13669, 13670, 13684, 13685, 13835, 13836, 13933, 13934, 14526, 14527, 15132, 15133, 15280, 15281, 15671, 15672, 15950, 15951, 16563, 16564, 16853, 16854, 17210, 17211, 17426 ] }
{ "red_pajama_v2": { "ccnet_original_length": 17426, "ccnet_original_nlines": 136, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.476462185382843, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.0325249582529068, "rps_doc_frac_lines_end_with_ellipsis": 0.007299270015209913, "rps_doc_frac_no_alph_words": 0.11640513688325882, "rps_doc_frac_unique_words": 0.31778424978256226, "rps_doc_mean_word_length": 4.515710830688477, "rps_doc_num_sentences": 178, "rps_doc_symbol_to_word_ratio": 0.0011412299936637282, "rps_doc_unigram_entropy": 5.894687175750732, "rps_doc_word_count": 3087, "rps_doc_frac_chars_dupe_10grams": 0.017073169350624084, "rps_doc_frac_chars_dupe_5grams": 0.017073169350624084, "rps_doc_frac_chars_dupe_6grams": 0.017073169350624084, "rps_doc_frac_chars_dupe_7grams": 0.017073169350624084, "rps_doc_frac_chars_dupe_8grams": 0.017073169350624084, "rps_doc_frac_chars_dupe_9grams": 0.017073169350624084, "rps_doc_frac_chars_top_2gram": 0.006814919877797365, "rps_doc_frac_chars_top_3gram": 0.004591099917888641, "rps_doc_frac_chars_top_4gram": 0.00215207994915545, "rps_doc_books_importance": -1611.878662109375, "rps_doc_books_importance_length_correction": -1611.878662109375, "rps_doc_openwebtext_importance": -796.3650512695312, "rps_doc_openwebtext_importance_length_correction": -796.3650512695312, "rps_doc_wikipedia_importance": -667.74560546875, "rps_doc_wikipedia_importance_length_correction": -667.74560546875 }, "fasttext": { "dclm": 0.1276932954788208, "english": 0.9735477566719055, "fineweb_edu_approx": 1.7626593112945557, "eai_general_math": 0.3030046224594116, "eai_open_web_math": 0.17987048625946045, "eai_web_code": 0.09241033345460892 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.019", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "305.42", "labels": { "level_1": "Social sciences", "level_2": "", "level_3": "Social sciences — Periodicals" } } }, "bloom_cognitive_process": { "primary": { "code": "5", "label": "Evaluate" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "9", "label": "Personal/Misc" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "16", "label": "Personal Blog" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
-9,060,383,721,349,595,000
3D Immersive and Interactive Learning by Yiyu Cai By Yiyu Cai 3D know-how isn't really new; examine on 3D began again in early Nineteen Sixties. yet not like in earlier instances, 3D expertise has now swiftly entered our lifestyle from cinema to workplace to domestic. utilizing 3D for schooling is a brand new but tough activity. This e-book will current a number of cutting edge efforts utilizing 3D for immersive and interactive studying overlaying a large spectrum of schooling together with proficient software, common (technical) circulation, and unique wishes schooling. The publication also will percentage event on curriculum-based 3D studying in lecture room atmosphere and co-curriculum-based 3D scholar study initiatives. The ebook is prepared as follows. bankruptcy 1 introduces the basics of 3D academic expertise and their functions in immersive and interactive studying. bankruptcy 2 discusses using digital truth in educating and studying of Molecular Biology. bankruptcy three offers the daVinci Lab @ River Valley highschool. bankruptcy four describes the 3D schooling improvement technique. bankruptcy five experiences the adaption 3D approach for studying profits in reduce secondary general (technical) movement. bankruptcy 6 investigates the results of digital truth know-how on spatial visualization talents. bankruptcy 7 showcases a sabbatical application for college kids to take advantage of 3D for technology, know-how, Engineering and arithmetic (STEM) studying. bankruptcy eight stocks using 3D digital red dolphin to aid targeted schooling. The foreword of this booklet is written through Dr Cheah Horn Mun, Director, schooling know-how department, Ministry of schooling, Singapore. Show description Read or Download 3D Immersive and Interactive Learning PDF Similar human-computer interaction books Next-generation business intelligence software with Silverlight 3 Enterprise intelligence (BI) software program is the code and instruments that let you view assorted elements of a company utilizing a unmarried visible platform, making comprehending mountains of information more straightforward. purposes that come with stories, analytics, facts, and ancient and predictive modeling are all examples of BI functions. New Perspectives on Affect and Learning Technologies Of the entire modifications among people and pcs, emotion could be the main easy: people have them and use them; machines don't, other than with human support. essentially the most promising arenas for human/computer intervention has been within the type of academic applied sciences that reply to the intersection of impact and cognition that happens in the course of studying. Writing for Interaction. Crafting the Information Experience for Web and Software Apps Writing for interplay makes a speciality of the artwork of constructing the data adventure because it seems to be inside software program and internet purposes, in particular within the type of person interface textual content. It additionally presents ideas for making sure a constant, optimistic details event throughout quite a few supply mechanisms, equivalent to on-line support and social media. Software Designers in Action: A Human-Centric Look at Design Work Software program Designers in motion: A Human-Centric examine layout paintings examines how builders truly practice software program layout of their daily paintings. The e-book deals a finished examine early software program layout, exploring the paintings designers from a number of varied viewpoints. Divided into 4 sections, it discusses a number of theoretical examinations of the character of software program layout and specific layout difficulties, severely assesses the procedures and practices that designers keep on with, offers in-depth debts of key assisting components of layout, and explores the position of human interplay in software program layout. Additional info for 3D Immersive and Interactive Learning Sample text A line can either intersect with or be parallel to a plane; two planes always intersect. The angle formed by two intersecting elements can be interactive displayed using the input pen. The virtual-reality elements program allows users to dynamically illustrate the distance or angle concepts. For example, a line segment can be rotated in 3D space, during which, its associated distance or angle will be dynamically updated. 3, the shortest distance between two lines can be dynamically displayed. 3 Dynamic demonstration of shortest distance between two lines 52 H. Also, for measurement purposes using the RUMM2030 program, an ordered marking response scheme has been created for each item. 4 Item 7 from the 20-item version of the purdue spatial visualization test—rotations. 5 Scoring rubric for posttest of purdue spatial visualization test—rotations Question/Score A B C D E 1 2 3 4 5 6 7 8 9 10 1 4 3 1 1 1 2 2 2 3 3 1 4 3 4 0 0 3 3 0 4 2 0 2 0 3 3 0 4 1 0 3 2 4 3 4 4 1 0 4 2 0 1 0 2 2 1 4 1 2 A (score 0), C (score 1) B (score 2), D (score 3), E (score 4) depending on which alternative is more correct. This helps in the removal of excess water from the amoeba. Soon, the vacuole reappears and again slowly increases in size, and the process is repeated. Which of the following graphs show a correct relationship between the frequency at which the vacuole is emptied and the concentration of salt in the surrounding water? A Frequency of contraction/min–1 Salt concentration / % 2 Use of Virtual-Reality in Teaching and Learning Molecular Biology B 37 Frequency of contraction/min–1 Salt concentration / % C Frequency of contraction/min–1 Salt concentration / % D Frequency of contraction/min–1 Salt concentration / % Explanation A B C D water moves down a concentration gradient water moves down a potential gradient water moves against a concentration gradient water moves against a potential gradient S. Download PDF sample Rated 4.28 of 5 – based on 20 votes
{ "url": "http://seo-referencement-google.com/books/3-d-immersive-and-interactive-learning", "source_domain": "seo-referencement-google.com", "snapshot_id": "crawl=CC-MAIN-2018-30", "warc_metadata": { "Content-Length": "34005", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:FXYS37R4D5UVFDFJEUSEVTB4ZZVC22P6", "WARC-Concurrent-To": "<urn:uuid:7167caa7-e0f5-4bf3-950a-554a729fea80>", "WARC-Date": "2018-07-19T09:44:56Z", "WARC-IP-Address": "212.227.247.85", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:DOYTOWAYEDIV3H2DUXSTNMLFFTDQNEF3", "WARC-Record-ID": "<urn:uuid:6d790a33-62f7-4b35-9817-659765e0f3fc>", "WARC-Target-URI": "http://seo-referencement-google.com/books/3-d-immersive-and-interactive-learning", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:0c1e6b3d-797f-4ac4-a02c-4e4b82070c59>" }, "warc_info": "robots: classic\r\nhostname: ip-10-33-201-248.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-30\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for July 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 50, 51, 63, 64, 736, 737, 1717, 1718, 1735, 1736, 1795, 1796, 1837, 1838, 1904, 1905, 2257, 2258, 2311, 2312, 2691, 2692, 2779, 2780, 3182, 3183, 3249, 3250, 3916, 3917, 3975, 3976, 3988, 3989, 4556, 4557, 5103, 5104, 5908, 5909, 5929, 5930 ], "line_end_idx": [ 50, 51, 63, 64, 736, 737, 1717, 1718, 1735, 1736, 1795, 1796, 1837, 1838, 1904, 1905, 2257, 2258, 2311, 2312, 2691, 2692, 2779, 2780, 3182, 3183, 3249, 3250, 3916, 3917, 3975, 3976, 3988, 3989, 4556, 4557, 5103, 5104, 5908, 5909, 5929, 5930, 5965 ] }
{ "red_pajama_v2": { "ccnet_original_length": 5965, "ccnet_original_nlines": 42, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2876838147640228, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.041360288858413696, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.20588235557079315, "rps_doc_frac_unique_words": 0.46739131212234497, "rps_doc_mean_word_length": 5.3086957931518555, "rps_doc_num_sentences": 40, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.460411548614502, "rps_doc_word_count": 920, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.09090909361839294, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.021498769521713257, "rps_doc_frac_chars_top_3gram": 0.023546269163489342, "rps_doc_frac_chars_top_4gram": 0.02538903057575226, "rps_doc_books_importance": -581.1527099609375, "rps_doc_books_importance_length_correction": -581.1527099609375, "rps_doc_openwebtext_importance": -308.0808410644531, "rps_doc_openwebtext_importance_length_correction": -308.0808410644531, "rps_doc_wikipedia_importance": -241.41030883789062, "rps_doc_wikipedia_importance_length_correction": -241.41030883789062 }, "fasttext": { "dclm": 0.027657270431518555, "english": 0.9045504927635193, "fineweb_edu_approx": 2.2382302284240723, "eai_general_math": 0.27029556035995483, "eai_open_web_math": 0.12337172031402588, "eai_web_code": 0.050886571407318115 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.019", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "371.392", "labels": { "level_1": "Social sciences", "level_2": "Education", "level_3": "Teachers, Teaching, and School management and organization" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "2", "label": "Academic/Research" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "10", "label": "Knowledge Article" }, "secondary": { "code": "17", "label": "Product Page" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-5,749,887,451,634,836,000
.NODE Importing and Exporting in a Script Like almost everything else in FileMaker, you can completely control the import and export process from a script. You use the Import Records and Export Records script, which you can find in the Records section of the script steps list. You also find script steps for Save Records as Excel and Save Records as PDF, with similar options. 17.5.1. The Import Records Script Step This script step has three options. First, you get to specify the data source to import from. Your choices match those in the File Import Records menu: File, Folder, Digital Camera (Mac OS X only), XML Data, and ODBC Data. Whichever option you choose, FileMaker asks you for more information (which ODBC data source to use, for instance). When specifying a file, you get the standard path list dialog box. In other words, you can specify several paths if you want; FileMaker imports the first one it finds. (If you don't specify a source, your users have to do it as they run the script, in a potentially confusing series of dialog boxes. Since you're presumably providing a script to make things easier for people, it's best to store source files in a safe place and have the script escort your users to them.) Once you've specified the source, you can turn on "Specify import order" to record the import field mapping, and other import options. Finally, you can turn on "Perform without dialog" if you want FileMaker to import the data directly, with no input from your users. If you leave this option off, FileMaker displays the Import Field Mapping dialog box when the script runs, so folks can make changes to any field mapping you specified. 17.5.2. The Export Records Script Step The Export Records script step offers similar options. You can specify the output file and export order, and you can choose "Perform without dialog" if you don't want your users to see the export dialog box. When you specify the output file, you may be surprised to see an Output File Path List. In other words, FileMaker lets you specify more than one file. This choice doesn't mean FileMaker exports more than one file, though. Instead, it exports to the first file path that is valid. If the first path in the list includes a folder name that doesn't exist, for example, FileMaker skips it and tries the next one. Part I: Introduction to FileMaker Pro Your First Database Organizing and Editing Records Building a New Database Part II: Layout Basics Layout Basics Creating Layouts Advanced Layouts and Reports Part III: Multiple Tables and Relationships Multiple Tables and Relationships Advanced Relationship Techniques Part IV: Calculations Introduction to Calculations Calculations and Data Types Advanced Calculations Extending Calculations Part V: Scripting Scripting Basics Script Steps Advanced Scripting Part VI: Security and Integration Security Exporting and Importing Sharing Your Database Developer Utilities Part VII: Appendixes Appendix A. Getting Help FileMaker Pro 8. The Missing Manual FileMaker Pro 8: The Missing Manual ISBN: 0596005792 EAN: 2147483647 Year: 2004 Pages: 176 Similar book on Amazon Flylib.com © 2008-2017. If you may any questions please contact us: flylib@qtcs.net
{ "url": "https://flylib.com/books/en/2.128.1/importing_and_exporting_in_a_script.html", "source_domain": "flylib.com", "snapshot_id": "crawl=CC-MAIN-2018-22", "warc_metadata": { "Content-Length": "34375", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:UFP4FT3PNPAL2QZINWIKXVLFY4TCQHUN", "WARC-Concurrent-To": "<urn:uuid:d3fe46a8-7b54-4330-ad8b-e4d19462005e>", "WARC-Date": "2018-05-23T22:43:37Z", "WARC-IP-Address": "94.130.122.250", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:YTQOZMD6NL5XRAPFXHEPES65KW4MDARZ", "WARC-Record-ID": "<urn:uuid:c5267b1a-e41f-46cb-a013-c0da15b99e41>", "WARC-Target-URI": "https://flylib.com/books/en/2.128.1/importing_and_exporting_in_a_script.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:903e34ea-fe88-4afe-930f-6834b7717bcc>" }, "warc_info": "robots: classic\r\nhostname: ip-10-148-11-10.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-22\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for May 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 6, 7, 43, 44, 380, 381, 420, 421, 1233, 1234, 1670, 1671, 1710, 1711, 1919, 1920, 2329, 2330, 2368, 2369, 2389, 2390, 2421, 2422, 2446, 2447, 2470, 2471, 2485, 2486, 2503, 2504, 2533, 2534, 2578, 2579, 2613, 2614, 2647, 2648, 2670, 2671, 2700, 2701, 2729, 2730, 2752, 2753, 2776, 2777, 2795, 2796, 2813, 2814, 2827, 2828, 2847, 2848, 2882, 2883, 2892, 2893, 2917, 2918, 2940, 2941, 2961, 2962, 2983, 2984, 3009, 3010, 3011, 3012, 3013, 3014, 3050, 3086, 3103, 3119, 3130, 3141, 3164, 3165, 3189 ], "line_end_idx": [ 6, 7, 43, 44, 380, 381, 420, 421, 1233, 1234, 1670, 1671, 1710, 1711, 1919, 1920, 2329, 2330, 2368, 2369, 2389, 2390, 2421, 2422, 2446, 2447, 2470, 2471, 2485, 2486, 2503, 2504, 2533, 2534, 2578, 2579, 2613, 2614, 2647, 2648, 2670, 2671, 2700, 2701, 2729, 2730, 2752, 2753, 2776, 2777, 2795, 2796, 2813, 2814, 2827, 2828, 2847, 2848, 2882, 2883, 2892, 2893, 2917, 2918, 2940, 2941, 2961, 2962, 2983, 2984, 3009, 3010, 3011, 3012, 3013, 3014, 3050, 3086, 3103, 3119, 3130, 3141, 3164, 3165, 3189, 3248 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3248, "ccnet_original_nlines": 85, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 1, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3349056541919708, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.026729559525847435, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.17138364911079407, "rps_doc_frac_unique_words": 0.42125236988067627, "rps_doc_mean_word_length": 4.903225898742676, "rps_doc_num_sentences": 33, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.910171985626221, "rps_doc_word_count": 527, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.061919499188661575, "rps_doc_frac_chars_dupe_6grams": 0.02244582027196884, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.016253869980573654, "rps_doc_frac_chars_top_3gram": 0.022058820351958275, "rps_doc_frac_chars_top_4gram": 0.01393189001828432, "rps_doc_books_importance": -296.48480224609375, "rps_doc_books_importance_length_correction": -296.48480224609375, "rps_doc_openwebtext_importance": -143.49771118164062, "rps_doc_openwebtext_importance_length_correction": -143.49771118164062, "rps_doc_wikipedia_importance": -68.2420883178711, "rps_doc_wikipedia_importance_length_correction": -68.2420883178711 }, "fasttext": { "dclm": 0.020319700241088867, "english": 0.7903912663459778, "fineweb_edu_approx": 2.09580659866333, "eai_general_math": 0.7749980688095093, "eai_open_web_math": 0.43571019172668457, "eai_web_code": 0.07506746053695679 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.74", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
6,368,259,945,934,947,000
Your IP Address is: 18.234.97.53 What is an SSL Certificate and Why It Is Important? Secure Sockets Layer (SSL) is an encryption protocol, a security technology, used for establishing the secure connection between a server and you — that is between a website and your browser. SSL aims to keep your sensitive data (i.e., login credentials, credit card details, SSN, and other personal data), which you send across the Internet, encrypted to make it accessible only for the intended recipient. How to recognize SSL-secured websites? Websites use SSL technology to let their customers feel confident while providing their personal data, for example, while purchasing online. To let you easily see whether the website you are visiting is a trusted one or not, browsers give you visual cues such as an icon of a lock next to the address bar or the whole bar green. The lock icon means that a website is SSL-secured, while a green address bar implies that a website uses Extended Validation SSL. Another distinctive feature of SSL is that the websites that use it begin not with http but with https. How does it work? All browsers are capable of interacting with SSL-secured web servers, but to make this interaction happen, the browser and the server need an SSL certificate (a small data file used to link a cryptographic key with details of an organization or site) for establishing a secure connection. Therefore, when a browser tries to access an SSL-secured website, an ‘SSL Handshake’ process takes place, which is instant and invisible for users. Setting up the SSL connection requires three keys; they are the public, private, and session ones. It works this way: any data encrypted with the private key can be decrypted by the public key solely, and vice versa. However, as such an encryption process is quite power-consuming, it is used only during the SSL Handshake, after which a symmetric session key is created. Thus, when the secure connection is established, the transmitted data is encrypted with this session key. SSL or TLS? New versions of SSL have been released to ensure more secure data transmission, and TLS (Transport Layer Security) is just the updated version of SSL. Previous changes were reflected in the name by adding the number of versions, for example, SSLv2.0 or SSLv3.0. However, instead of naming the next version SSLv4.0, it was called TLSv1.0. As SSL is more commonly used, it is referred to while talking about securing transmitted data, even if the TLS version is actually used.
{ "url": "https://whatismyip.li/what-is-ssl-certificate", "source_domain": "whatismyip.li", "snapshot_id": "crawl=CC-MAIN-2020-45", "warc_metadata": { "Content-Length": "10310", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:IW4PF5UEVOBTMQMU7QIFYEJCAJAVU66B", "WARC-Concurrent-To": "<urn:uuid:70d5621d-3b03-40fd-95c4-8d50aba3452c>", "WARC-Date": "2020-10-28T14:10:59Z", "WARC-IP-Address": "172.64.173.2", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:TDQUOXFB6GROEIUSFVBPPKR3MO62ULRV", "WARC-Record-ID": "<urn:uuid:5905effc-abd5-4933-b374-337bcf1c85fb>", "WARC-Target-URI": "https://whatismyip.li/what-is-ssl-certificate", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ea82c3ff-22a5-4438-b2a2-fcc317a358de>" }, "warc_info": "isPartOf: CC-MAIN-2020-45\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for October 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-30.ec2.internal\r\nsoftware: Apache Nutch 1.17 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 20, 33, 34, 86, 87, 495, 496, 535, 536, 865, 866, 1100, 1101, 1119, 1120, 1557, 1558, 2036, 2037, 2049, 2050, 2388, 2389 ], "line_end_idx": [ 20, 33, 34, 86, 87, 495, 496, 535, 536, 865, 866, 1100, 1101, 1119, 1120, 1557, 1558, 2036, 2037, 2049, 2050, 2388, 2389, 2525 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2525, "ccnet_original_nlines": 23, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4000000059604645, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.045098040252923965, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.16862745583057404, "rps_doc_frac_unique_words": 0.4880952537059784, "rps_doc_mean_word_length": 4.80476188659668, "rps_doc_num_sentences": 29, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.888208866119385, "rps_doc_word_count": 420, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.005946480203419924, "rps_doc_frac_chars_top_3gram": 0.015857279300689697, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -209.5915985107422, "rps_doc_books_importance_length_correction": -209.5915985107422, "rps_doc_openwebtext_importance": -141.09815979003906, "rps_doc_openwebtext_importance_length_correction": -141.09815979003906, "rps_doc_wikipedia_importance": -120.02523803710938, "rps_doc_wikipedia_importance_length_correction": -120.02523803710938 }, "fasttext": { "dclm": 0.8436949849128723, "english": 0.937448263168335, "fineweb_edu_approx": 2.992077112197876, "eai_general_math": 0.3638097047805786, "eai_open_web_math": 0.05527561902999878, "eai_web_code": 0.9089047908782959 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.82", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.678", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "10", "label": "Knowledge Article" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-7,996,204,553,524,422,000
How to Make a Presentation on an iPad by Alex Zang Stephen Colbert made a joke presentation on his iPad at the Grammys. Stephen Colbert made a joke presentation on his iPad at the Grammys. Larry Busacca/Getty Images Entertainment/Getty Images One of the benefits of using your iPad to make presentations is its mobility. You can take it anywhere with you without much trouble, then hook it up to a projector or monitor to make a presentation. While the iPad doesn't come with presentation building software, you can download one of many applications from the app store that are designed to help you create and make a variety of different types of presentations. 1. Get Keynote from the Apple iTunes Store. Keynote allows you to choose various themes for your presentation, then organize the presentation itself by dragging and dropping various photos and bits of text to where you want them. As of the date of publication, Keynote costs $9.99. 2. Download Corkulous from the Apple iTunes Store. Rather than the traditional slideshow presentation, Corkulous allows you to use a virtual corkboard. You can tack up photos and virtual note cards, then proceed to talk your way through the corkboard, allowing all of the people watching your presentation to see how everything connects to the big picture. Corkulous costs $4.99 as of the date of publication. 3. Use Power Presenter, available from the Apple iTunes Store. While this software doesn't allow you to create a presentation, it does allow you to upload a PDF file, then present from that PDF file. During the presentation, you can highlight various bits of text, write onscreen, and draw if need be. As of the date of publication, Power Presenter costs $1.99. Tip • Practice your presentation before you have to make it. Warning • Don't rely completely on the iPad. People still expect you to be interesting during the presentation. About the Author Alex Zang has been freelance writing since 2004, specializing in sports and technology. His work has appeared in "The Calgary Herald" and "Western Canadian Condos & Resorts," as well as online. Zang studied film production and screenwriting at Mount Royal College. Photo Credits • Larry Busacca/Getty Images Entertainment/Getty Images bibliography-icon icon for annotation tool Cite this Article
{ "url": "https://smallbusiness.chron.com/make-presentation-ipad-29725.html", "source_domain": "smallbusiness.chron.com", "snapshot_id": "crawl=CC-MAIN-2019-26", "warc_metadata": { "Content-Length": "40833", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:2FVYAN4BDSROJ2A2VOUPY2EANSZC5O2J", "WARC-Concurrent-To": "<urn:uuid:531c95c2-046f-4279-99c9-f239cc335ebb>", "WARC-Date": "2019-06-18T23:25:36Z", "WARC-IP-Address": "23.60.107.34", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:WZLT6BV2ZFMOSAPNFFDS4ARFYUSOZDVR", "WARC-Record-ID": "<urn:uuid:59073874-12c9-43dc-a141-99e38c5b04d6>", "WARC-Target-URI": "https://smallbusiness.chron.com/make-presentation-ipad-29725.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:696c9fce-4906-4782-964b-e8dc5db8869a>" }, "warc_info": "isPartOf: CC-MAIN-2019-26\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-144-182-216.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 38, 39, 52, 121, 122, 191, 192, 246, 247, 666, 667, 670, 671, 950, 951, 954, 955, 1362, 1363, 1366, 1367, 1726, 1727, 1731, 1732, 1791, 1792, 1800, 1801, 1907, 1908, 1925, 1926, 2191, 2192, 2206, 2207, 2265 ], "line_end_idx": [ 38, 39, 52, 121, 122, 191, 192, 246, 247, 666, 667, 670, 671, 950, 951, 954, 955, 1362, 1363, 1366, 1367, 1726, 1727, 1731, 1732, 1791, 1792, 1800, 1801, 1907, 1908, 1925, 1926, 2191, 2192, 2206, 2207, 2265, 2325 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2325, "ccnet_original_nlines": 38, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3968609869480133, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.004484300035983324, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.16143497824668884, "rps_doc_frac_unique_words": 0.49734044075012207, "rps_doc_mean_word_length": 4.960106372833252, "rps_doc_num_sentences": 29, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.823700904846191, "rps_doc_word_count": 376, "rps_doc_frac_chars_dupe_10grams": 0.06005362048745155, "rps_doc_frac_chars_dupe_5grams": 0.18605898320674896, "rps_doc_frac_chars_dupe_6grams": 0.09865952283143997, "rps_doc_frac_chars_dupe_7grams": 0.06005362048745155, "rps_doc_frac_chars_dupe_8grams": 0.06005362048745155, "rps_doc_frac_chars_dupe_9grams": 0.06005362048745155, "rps_doc_frac_chars_top_2gram": 0.013404830358922482, "rps_doc_frac_chars_top_3gram": 0.01930294930934906, "rps_doc_frac_chars_top_4gram": 0.02895442023873329, "rps_doc_books_importance": -216.18429565429688, "rps_doc_books_importance_length_correction": -216.18429565429688, "rps_doc_openwebtext_importance": -105.6925048828125, "rps_doc_openwebtext_importance_length_correction": -105.6925048828125, "rps_doc_wikipedia_importance": -64.62832641601562, "rps_doc_wikipedia_importance_length_correction": -64.62832641601562 }, "fasttext": { "dclm": 0.026882829144597054, "english": 0.9386389851570129, "fineweb_edu_approx": 1.6095489263534546, "eai_general_math": 0.008907790295779705, "eai_open_web_math": 0.11712806671857834, "eai_web_code": 0.0005923500284552574 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.164", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "658.40285", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Business", "level_3": "Management" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-8,982,903,762,332,769,000
eLicense problem for second computer I’ve installed the cubase on my PC, and run smoothly with the eLicenser, with serail number inputted. Now I install it on my laptop, but after I plug in the eLicenser, the laptop did not recognize that it is an eLicenser with a serial number, and keep on asking me to re-input a serial number; even worth, when I re-input the serial number provided in the box, the program said that the number is already used and reject me. The 25hr count down continued. I checked the Steinberg website, which says that eLicense, with a serial number inputted, should authorize any computer with it attached, which is clearly not my case. On the other side, the website also says that I cannot re-input a serial number after the first serial number is inputted. So I’m stuck here. What should I do? Hi, If you are using UBS-eLicenser, you should just plug it in, and it should work (after installation of eLCCC, of course). No Activation needed. Make sure, it’s connected to USB2, and make sure, you have the very latest eLCC version, please. If you are using Soft-eLicenser, you cannot switch from one computer to another one, and back. You need to Reactivate.
{ "url": "https://forums.steinberg.net/t/elicense-problem-for-second-computer/671902", "source_domain": "forums.steinberg.net", "snapshot_id": "crawl=CC-MAIN-2021-17", "warc_metadata": { "Content-Length": "16658", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:I5J2JUQCPTVT6YY6XD4E6RODVVRUN4XF", "WARC-Concurrent-To": "<urn:uuid:b285153a-708e-44c1-8d45-3ffabc24773d>", "WARC-Date": "2021-04-21T02:22:33Z", "WARC-IP-Address": "184.104.202.107", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:CHM6HOXPS6LLE4GZKXH4G2GS774JXVXN", "WARC-Record-ID": "<urn:uuid:eea9783f-b5e0-4f14-b50a-6524a8dd734c>", "WARC-Target-URI": "https://forums.steinberg.net/t/elicense-problem-for-second-computer/671902", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ecc9944c-e25f-4b11-abe3-7cfd7efa091b>" }, "warc_info": "isPartOf: CC-MAIN-2021-17\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for April 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-35.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 37, 38, 494, 495, 786, 787, 824, 825, 829, 830, 973, 974, 1071, 1072 ], "line_end_idx": [ 37, 38, 494, 495, 786, 787, 824, 825, 829, 830, 973, 974, 1071, 1072, 1190 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1190, "ccnet_original_nlines": 14, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4615384638309479, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.042307689785957336, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.16923077404499054, "rps_doc_frac_unique_words": 0.5384615659713745, "rps_doc_mean_word_length": 4.490384578704834, "rps_doc_num_sentences": 12, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.418299674987793, "rps_doc_word_count": 208, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.07708778977394104, "rps_doc_frac_chars_top_3gram": 0.05567451938986778, "rps_doc_frac_chars_top_4gram": 0.036402568221092224, "rps_doc_books_importance": -133.77810668945312, "rps_doc_books_importance_length_correction": -133.77810668945312, "rps_doc_openwebtext_importance": -63.30164337158203, "rps_doc_openwebtext_importance_length_correction": -63.276493072509766, "rps_doc_wikipedia_importance": -60.41262435913086, "rps_doc_wikipedia_importance_length_correction": -60.41262435913086 }, "fasttext": { "dclm": 0.018783150240778923, "english": 0.9394433498382568, "fineweb_edu_approx": 1.2453224658966064, "eai_general_math": 0.8208354115486145, "eai_open_web_math": 0.23557955026626587, "eai_web_code": 0.009744410403072834 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-536,714,346,184,977,340
Forums The forums ran from 2008-2020 and are now closed and viewable here as an archive. Home Forums CSS Need help changing the paragraph font size. Re: Need help changing the paragraph font size. #120721 jurotek Participant @ricksmith, > I’m trying to change the font size (and line height) on this site. do you mean your paragraph font size and line height? Edit: @TheDoc, got the answer, btw, your paragraph font-size is not set so is inherited from your body font-size of 12px
{ "url": "https://css-tricks.com/forums/reply/re-need-help-changing-the-paragraph-font-size-2/", "source_domain": "css-tricks.com", "snapshot_id": "crawl=CC-MAIN-2022-21", "warc_metadata": { "Content-Length": "69598", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:552X2HM6CGGDAYKLEVKVVHZH7LP7MUVU", "WARC-Concurrent-To": "<urn:uuid:c0565477-b313-42cf-9c8f-94fe589e49e3>", "WARC-Date": "2022-05-23T10:41:10Z", "WARC-IP-Address": "104.18.37.246", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:W627WLNY4IUD5PH44UEQMYAIGIXU7OVP", "WARC-Record-ID": "<urn:uuid:fc0337fd-1f5a-46c8-95e6-74d7e7027a5e>", "WARC-Target-URI": "https://css-tricks.com/forums/reply/re-need-help-changing-the-paragraph-font-size-2/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:472799c8-ee9f-4741-a997-2bb404b77c62>" }, "warc_info": "isPartOf: CC-MAIN-2022-21\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-73\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 7, 8, 90, 91, 199, 200, 208, 216, 228, 229, 241, 242, 311, 312, 366, 367 ], "line_end_idx": [ 7, 8, 90, 91, 199, 200, 208, 216, 228, 229, 241, 242, 311, 312, 366, 367, 487 ] }
{ "red_pajama_v2": { "ccnet_original_length": 487, "ccnet_original_nlines": 16, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3177570104598999, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.018691590055823326, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.22429907321929932, "rps_doc_frac_unique_words": 0.6585366129875183, "rps_doc_mean_word_length": 4.609755992889404, "rps_doc_num_sentences": 6, "rps_doc_symbol_to_word_ratio": 0.00934579037129879, "rps_doc_unigram_entropy": 3.8224518299102783, "rps_doc_word_count": 82, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.30158731341362, "rps_doc_frac_chars_dupe_6grams": 0.190476194024086, "rps_doc_frac_chars_dupe_7grams": 0.190476194024086, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.08465608209371567, "rps_doc_frac_chars_top_3gram": 0.1349206268787384, "rps_doc_frac_chars_top_4gram": 0.10052909702062607, "rps_doc_books_importance": -48.74057388305664, "rps_doc_books_importance_length_correction": -56.0594482421875, "rps_doc_openwebtext_importance": -29.463083267211914, "rps_doc_openwebtext_importance_length_correction": -36.781959533691406, "rps_doc_wikipedia_importance": -24.326425552368164, "rps_doc_wikipedia_importance_length_correction": -31.645299911499023 }, "fasttext": { "dclm": 0.10226594656705856, "english": 0.8833242058753967, "fineweb_edu_approx": 1.2698137760162354, "eai_general_math": 0.7216231226921082, "eai_open_web_math": 0.86695396900177, "eai_web_code": 0.00019829999655485153 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
-3,369,300,794,779,677,700
Immersitech Logo Developer Home imm_heading Struct Reference A structure to describe the direction a participant is facing in three-dimensional space. More... #include <immersitech.h> Public Attributes int azimuth_heading   int elevation_heading   Detailed Description A structure to describe the direction a participant is facing in three-dimensional space. The azimuth angle is with respect to the x and z plane. The elevation angle is with respect to the y and z plane. Parameters azimuth_headingThe azimuth angle the participant is facing. Allowable azimuth headings are from -180 to 180. elevation_headingThe elevation angle the participant is facing. Allowable elevation headings are from -90 to 90. Member Data Documentation ◆ azimuth_heading int imm_heading::azimuth_heading ◆ elevation_heading int imm_heading::elevation_heading The documentation for this struct was generated from the following file:
{ "url": "https://sdkdocs.immersitech.io/structimm__heading.html", "source_domain": "sdkdocs.immersitech.io", "snapshot_id": "crawl=CC-MAIN-2022-40", "warc_metadata": { "Content-Length": "8815", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:EFFJBOG45W2EJKRYCGALKS7SPP63PBB2", "WARC-Concurrent-To": "<urn:uuid:49890d9e-9c10-406f-8ff1-50e32b8ccbca>", "WARC-Date": "2022-10-07T11:49:49Z", "WARC-IP-Address": "185.199.108.153", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:LREQ4IGYLFLDGFSBWPBN5E6I3SIZA3EV", "WARC-Record-ID": "<urn:uuid:8b634535-c6ec-45bd-9eff-6551e5509143>", "WARC-Target-URI": "https://sdkdocs.immersitech.io/structimm__heading.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:86bc16d7-b28b-4b51-a6c7-3e499a7bb374>" }, "warc_info": "isPartOf: CC-MAIN-2022-40\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September/October 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-215\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 32, 61, 62, 160, 161, 186, 187, 205, 206, 226, 228, 250, 252, 253, 274, 275, 365, 366, 480, 481, 492, 601, 714, 715, 741, 742, 760, 761, 794, 795, 815, 816, 851, 852 ], "line_end_idx": [ 32, 61, 62, 160, 161, 186, 187, 205, 206, 226, 228, 250, 252, 253, 274, 275, 365, 366, 480, 481, 492, 601, 714, 715, 741, 742, 760, 761, 794, 795, 815, 816, 851, 852, 924 ] }
{ "red_pajama_v2": { "ccnet_original_length": 924, "ccnet_original_nlines": 34, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2945205569267273, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.013698630034923553, "rps_doc_frac_lines_end_with_ellipsis": 0.02857143059372902, "rps_doc_frac_no_alph_words": 0.1780821830034256, "rps_doc_frac_unique_words": 0.4958677589893341, "rps_doc_mean_word_length": 6.206611633300781, "rps_doc_num_sentences": 11, "rps_doc_symbol_to_word_ratio": 0.013698630034923553, "rps_doc_unigram_entropy": 3.8763480186462402, "rps_doc_word_count": 121, "rps_doc_frac_chars_dupe_10grams": 0.1997336894273758, "rps_doc_frac_chars_dupe_5grams": 0.3568575084209442, "rps_doc_frac_chars_dupe_6grams": 0.3568575084209442, "rps_doc_frac_chars_dupe_7grams": 0.1997336894273758, "rps_doc_frac_chars_dupe_8grams": 0.1997336894273758, "rps_doc_frac_chars_dupe_9grams": 0.1997336894273758, "rps_doc_frac_chars_top_2gram": 0.0692410096526146, "rps_doc_frac_chars_top_3gram": 0.10119839757680893, "rps_doc_frac_chars_top_4gram": 0.053262319415807724, "rps_doc_books_importance": -60.291683197021484, "rps_doc_books_importance_length_correction": -60.291683197021484, "rps_doc_openwebtext_importance": -35.724124908447266, "rps_doc_openwebtext_importance_length_correction": -24.35770606994629, "rps_doc_wikipedia_importance": -26.484434127807617, "rps_doc_wikipedia_importance_length_correction": -26.484434127807617 }, "fasttext": { "dclm": 0.40453338623046875, "english": 0.8349452018737793, "fineweb_edu_approx": 1.9122517108917236, "eai_general_math": 0.6908204555511475, "eai_open_web_math": 0.32509732246398926, "eai_web_code": 0.010024430230259895 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-1,902,263,539,228,567,000
Take the 2-minute tour × Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required. I have a declarative table defined like this: class Transaction(Base): __tablename__ = "transactions" id = Column(Integer, primary_key=True) account_id = Column(Integer) transfer_account_id = Column(Integer) amount = Column(Numeric(12, 2)) ... The query should be: SELECT id, (CASE WHEN transfer_account_id=1 THEN -amount ELSE amount) AS amount FROM transactions WHERE account_id = 1 OR transfer_account_id = 1 My code is: query = Transaction.query.filter_by(account_id=1, transfer_account_id=1) query = query.add_column(case(...).label("amount")) But it doesn't replace the amount column. Been trying to do this with for hours and I don't want to use raw SQL. share|improve this question 2 Answers 2 up vote 1 down vote accepted Any query you do will not replace original amount column. But you can load another column using following query: q = session.query(Transaction, case([(Transaction.transfer_account_id==1, -1*Transaction.amount)], else_=Transaction.amount).label('special_amount') ) q = q.filter(or_(Transaction.account_id==1, Transaction.transfer_account_id==1)) This will not return only Transaction objects, but rather tuple(Transaction, Decimal) But if you want this property be part of your object, then: Since your case when ... function is completely independent from the condition in WHERE, I would suggest that you change your code in following way: 1) add a property to you object, which does the case when ... check as following: @property def special_amount(self): return -self.amount if self.transfer_account_id == 1 else self.amount You can completely wrap this special handling of the amount providing a setter property as well: @special_amount.setter def special_amount(self, value): if self.transfer_account_id is None: raise Exception('Cannot decide on special handling, because transfer_account_id is not set') self.amount = -value if self.transfer_account_id == 1 else value 2) fix your query to only have a filter clause with or_ clause (it looks like your query does not work at all): q = session.query(Transaction).filter( or_(Transaction.account_id==1, Transaction.transfer_account_id==1) ) # then get your results with the proper amount sign: for t in q.all(): print q.id, q.special_amount share|improve this answer      What about sorting? Can I throw in an order_by()? –  Paul Onutor Mar 16 '10 at 15:57      with the query - sure; with the @property - not really when executing query on the database, but you can easily sort Transaction objects once you retrieved them and stored in the list. –  van Mar 16 '10 at 16:27 The construct you are looking for is called column_property. You could use a secondary mapper to actually replace the amount column. Are you sure you are not making things too difficult for yourself by not just storing the negative values in the database directly or giving the "corrected" column a different name? from sqlalchemy.orm import mapper, column_property wrongmapper = sqlalchemy.orm.mapper(Transaction, Transaction.__table, non_primary = True, properties = {'amount': column_property(case([(Transaction.transfer_account_id==1, -1*Transaction.amount)], else_=Transaction.amount)}) Session.query(wrongmapper).filter(...) share|improve this answer      Nice but not quite right. I can't use an external param. –  Paul Onutor Mar 15 '10 at 17:19 Your Answer   discard By posting your answer, you agree to the privacy policy and terms of service. Not the answer you're looking for? Browse other questions tagged or ask your own question.
{ "url": "http://stackoverflow.com/questions/2444679/sqlalchemy-custom-query-column", "source_domain": "stackoverflow.com", "snapshot_id": "crawl=CC-MAIN-2014-35", "warc_metadata": { "Content-Length": "74350", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:MD66SGPZB6YYQCTTBERP7OLBGRIU2ZJA", "WARC-Concurrent-To": "<urn:uuid:c58aed39-7836-404a-8cf6-18aeb3028360>", "WARC-Date": "2014-08-28T15:21:34Z", "WARC-IP-Address": "198.252.206.16", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:25PIJSNNFDHQ4VETK3M4JMOW4ZWG6EKA", "WARC-Record-ID": "<urn:uuid:80383eb0-8458-40f1-a2ae-d9b313a824a8>", "WARC-Target-URI": "http://stackoverflow.com/questions/2444679/sqlalchemy-custom-query-column", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:2e14e8cc-e8de-4fc1-a1f1-0e29bf04ce73>" }, "warc_info": "robots: classic\r\nhostname: ip-10-180-136-8.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-35\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for August 2014\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 25, 157, 158, 204, 205, 230, 265, 308, 341, 383, 419, 427, 428, 449, 450, 530, 548, 596, 597, 609, 610, 683, 735, 736, 778, 779, 850, 851, 879, 880, 892, 893, 922, 923, 1036, 1037, 1068, 1204, 1224, 1305, 1306, 1392, 1393, 1394, 1454, 1603, 1604, 1686, 1687, 1697, 1723, 1797, 1798, 1895, 1896, 1919, 1952, 1993, 2094, 2163, 2164, 2276, 2277, 2316, 2352, 2396, 2398, 2399, 2452, 2470, 2503, 2529, 2534, 2619, 2624, 2836, 2837, 3152, 3153, 3204, 3274, 3298, 3326, 3419, 3455, 3456, 3495, 3521, 3526, 3618, 3619, 3631, 3632, 3634, 3642, 3643, 3721, 3722 ], "line_end_idx": [ 25, 157, 158, 204, 205, 230, 265, 308, 341, 383, 419, 427, 428, 449, 450, 530, 548, 596, 597, 609, 610, 683, 735, 736, 778, 779, 850, 851, 879, 880, 892, 893, 922, 923, 1036, 1037, 1068, 1204, 1224, 1305, 1306, 1392, 1393, 1394, 1454, 1603, 1604, 1686, 1687, 1697, 1723, 1797, 1798, 1895, 1896, 1919, 1952, 1993, 2094, 2163, 2164, 2276, 2277, 2316, 2352, 2396, 2398, 2399, 2452, 2470, 2503, 2529, 2534, 2619, 2624, 2836, 2837, 3152, 3153, 3204, 3274, 3298, 3326, 3419, 3455, 3456, 3495, 3521, 3526, 3618, 3619, 3631, 3632, 3634, 3642, 3643, 3721, 3722, 3812 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3812, "ccnet_original_nlines": 98, "rps_doc_curly_bracket": 0.0005246599903330207, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2816166877746582, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.020860500633716583, "rps_doc_frac_lines_end_with_ellipsis": 0.010101010091602802, "rps_doc_frac_no_alph_words": 0.3207301199436188, "rps_doc_frac_unique_words": 0.5189075469970703, "rps_doc_mean_word_length": 5.934874057769775, "rps_doc_num_sentences": 55, "rps_doc_symbol_to_word_ratio": 0.007822689600288868, "rps_doc_unigram_entropy": 5.177985668182373, "rps_doc_word_count": 476, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.008495580404996872, "rps_doc_frac_chars_top_3gram": 0.011327429674565792, "rps_doc_frac_chars_top_4gram": 0.015575219877064228, "rps_doc_books_importance": -359.56732177734375, "rps_doc_books_importance_length_correction": -359.56732177734375, "rps_doc_openwebtext_importance": -205.77903747558594, "rps_doc_openwebtext_importance_length_correction": -205.77903747558594, "rps_doc_wikipedia_importance": -93.20111846923828, "rps_doc_wikipedia_importance_length_correction": -93.20111846923828 }, "fasttext": { "dclm": 0.2746768593788147, "english": 0.7996691465377808, "fineweb_edu_approx": 1.6755326986312866, "eai_general_math": 0.018421290442347527, "eai_open_web_math": 0.13399362564086914, "eai_web_code": 0.003856780007481575 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.133", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "5", "label": "Social/Forum" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "1", "label": "Leftover HTML" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
3,861,507,674,272,292,000
AnsweredAssumed Answered Passing user input into Geoprocessing service as dataset Question asked by Zachary.King on Feb 13, 2020 Latest reply on Feb 14, 2020 by Davepike101@hotmail.com I have a script tool that runs in ArcGIS Desktop and a slightly modified copy that runs in ArcGIS Pro. The tool takes input from a user via arcpy.GetParameterAsText. This input corresponds with the name of a layer in map. The text string is then passed into a series of geoprocessing steps.   The tool is published to Portal however, when I try and run it in a web app I get an error which reads File "e:\program files\arcgis\server\framework\runtime\arcgis\Resources\arcpy\arcpy\geoprocessing\_base.py", line 368, in describe self._gp.Describe(*gp_fixargs(args, True))) OSError: "Layer Name" does not exist. Is there something I am needing to do to convert the text string value to JSON so that the geoprocessing steps in the script will recognize the appropriate layer?  Outcomes
{ "url": "https://community.esri.com/thread/248204-passing-user-input-into-geoprocessing-service-as-dataset", "source_domain": "community.esri.com", "snapshot_id": "crawl=CC-MAIN-2020-10", "warc_metadata": { "Content-Length": "112919", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:EXXB6CCQC3DRI6T73ANXTPTZUHKLCGHU", "WARC-Concurrent-To": "<urn:uuid:f8ae0831-ca70-476a-a5c0-f8063ae5b3f0>", "WARC-Date": "2020-02-20T13:36:10Z", "WARC-IP-Address": "104.121.106.107", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:Q7BSX7PHWYKEXRL4YPM5U3ZVFOMI724A", "WARC-Record-ID": "<urn:uuid:15e1fa64-627f-4818-9854-4ac413be9d4a>", "WARC-Target-URI": "https://community.esri.com/thread/248204-passing-user-input-into-geoprocessing-service-as-dataset", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:a57f3e9e-8589-49c7-8b03-b7553389118f>" }, "warc_info": "isPartOf: CC-MAIN-2020-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-136.ec2.internal\r\nsoftware: Apache Nutch 1.16 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 25, 26, 83, 84, 131, 187, 188, 479, 480, 482, 483, 963, 964 ], "line_end_idx": [ 25, 26, 83, 84, 131, 187, 188, 479, 480, 482, 483, 963, 964, 972 ] }
{ "red_pajama_v2": { "ccnet_original_length": 972, "ccnet_original_nlines": 13, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3103448152542114, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.024630539119243622, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.20689654350280762, "rps_doc_frac_unique_words": 0.6575342416763306, "rps_doc_mean_word_length": 5.294520378112793, "rps_doc_num_sentences": 13, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.368562698364258, "rps_doc_word_count": 146, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.012936609797179699, "rps_doc_frac_chars_top_3gram": 0.025873219594359398, "rps_doc_frac_chars_top_4gram": 0.04139715060591698, "rps_doc_books_importance": -91.20156860351562, "rps_doc_books_importance_length_correction": -91.20156860351562, "rps_doc_openwebtext_importance": -41.8214225769043, "rps_doc_openwebtext_importance_length_correction": -28.068931579589844, "rps_doc_wikipedia_importance": -39.27619171142578, "rps_doc_wikipedia_importance_length_correction": -39.27619171142578 }, "fasttext": { "dclm": 0.04794245958328247, "english": 0.8189513683319092, "fineweb_edu_approx": 2.0918056964874268, "eai_general_math": 0.7811940312385559, "eai_open_web_math": 0.14749997854232788, "eai_web_code": 0.05731863155961037 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "910.285", "labels": { "level_1": "History and Geography", "level_2": "Geography and Voyages and travels", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
349,306,741,740,713,500
How do I send an email to multiple recipients in Linux? How can you send a mail to several people in Linux? How to Use Mailx to Send to Multiple Addresses 1. Begin the mail command using the following syntax: mailx [-s “subject”]. … 2. Enter the email address of your first recipient after the brackets. … 3. Enter the email address or addresses of any other recipients you wish to receive the message separated by a space. How do you send an email to multiple recipients in shell script? Use option -t for sendmail. in your case – echo -e $mail | /usr/sbin/sendmail -t and add yout Recepient list to message itself like To: someone@somewhere.com someother@nowhere.com right after the line From:….. -t option means – Read message for recipients. How do I read mail in Linux? prompt, enter the number of the mail you want to read and press ENTER . Press ENTER to scroll through the message line by line and press q and ENTER to return to the message list. To exit mail , type q at the ? prompt and then press ENTER . What is mail command in Unix? The mail command allows you to read or send mail. If users is left blank, it allows you to read mail. If users has a value, then it allows you send mail to those users. How do I add multiple recipients in Sendmail? 2 Answers. To put multiple addresses on the To: or Cc: or Bcc: line, separate them by a comma (plus optional spaces). There are mail readers that allow typing a semicolon to separate addresses and show addresses separated by semicolons, but this is not standard syntax. How do I send an email to multiple people in Python? If you want to use smtplib to send email to multiple recipients, use email. Message. add_header(‘To’, eachRecipientAsString) to add them, and then when you invoke the sendmail method, use email. Message. How do I send an email with Mailutils? Sending a simple mail Enter the CC address and press enter or press enter without anything to skip. From the next line type in your message. Pressing enter would create a new line in the message. Once you are done entering the message, press . How can I tell if an email is running on Linux? Desktop Linux users can find out if Sendmail is working without resorting to the command line by running by using the System Monitor utility. Click the “Dash” button, type “system monitor” (without quotes) in the search box then click on the “System Monitor” icon. What is mail server in Linux? A mail server (sometimes called MTA – Mail Transport Agent) is an application that is used to transfer mails from one user to another. … Postfix was designed to be easier to configure as well as more reliable and secure than sendmail, and it has become the default mail server on many Linux distributions (e.g. openSUSE). How install mailx package in Linux? How to Install mail command in RHEL/CentOS 7/8 1. Step 1: Prerequisites. 2. Step 2: Update Your System. 3. Step 3: Install mail command in Linux. 4. Step 4: Check mail command version. 5. Step 5: Send a Test email using mail command in Linux. What is the difference between mail and mailx in Unix? Mailx is more advanced than “mail”. Mailx supports attachments by using the “-a” parameter. Users then list a file path after the “-a” parameter. Mailx also supports POP3, SMTP, IMAP, and MIME. Like this post? Please share to your friends: OS Today
{ "url": "https://frameboxxindore.com/apple/how-do-i-send-an-email-to-multiple-recipients-in-linux.html", "source_domain": "frameboxxindore.com", "snapshot_id": "crawl=CC-MAIN-2022-40", "warc_metadata": { "Content-Length": "124757", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:MJAKUF35MAM7S4PHRH5ORTL33F4JY5A3", "WARC-Concurrent-To": "<urn:uuid:11410238-1277-41e9-ae43-4165093979a6>", "WARC-Date": "2022-09-24T22:43:33Z", "WARC-IP-Address": "185.202.239.182", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:YCCWXJWBK2OU34CFSTAQO4GYEKWWZMDH", "WARC-Record-ID": "<urn:uuid:f81b5353-9717-4a7e-bae1-e762ec5ddfe1>", "WARC-Target-URI": "https://frameboxxindore.com/apple/how-do-i-send-an-email-to-multiple-recipients-in-linux.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:fa35d37f-0553-43d9-b435-04bb56aad14d>" }, "warc_info": "isPartOf: CC-MAIN-2022-40\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September/October 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-188\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 56, 57, 109, 110, 157, 158, 238, 313, 433, 434, 499, 500, 757, 758, 787, 788, 1029, 1030, 1060, 1061, 1230, 1231, 1277, 1278, 1548, 1549, 1602, 1603, 1807, 1808, 1847, 1848, 1870, 1871, 2093, 2094, 2142, 2143, 2408, 2409, 2439, 2440, 2762, 2763, 2799, 2800, 2847, 2848, 2876, 2909, 2953, 2994, 3054, 3055, 3110, 3111, 3305, 3306, 3352 ], "line_end_idx": [ 56, 57, 109, 110, 157, 158, 238, 313, 433, 434, 499, 500, 757, 758, 787, 788, 1029, 1030, 1060, 1061, 1230, 1231, 1277, 1278, 1548, 1549, 1602, 1603, 1807, 1808, 1847, 1848, 1870, 1871, 2093, 2094, 2142, 2143, 2408, 2409, 2439, 2440, 2762, 2763, 2799, 2800, 2847, 2848, 2876, 2909, 2953, 2994, 3054, 3055, 3110, 3111, 3305, 3306, 3352, 3360 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3360, "ccnet_original_nlines": 59, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3475862145423889, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.02620689943432808, "rps_doc_frac_lines_end_with_ellipsis": 0.03333333134651184, "rps_doc_frac_no_alph_words": 0.20000000298023224, "rps_doc_frac_unique_words": 0.38513514399528503, "rps_doc_mean_word_length": 4.393580913543701, "rps_doc_num_sentences": 63, "rps_doc_symbol_to_word_ratio": 0.005517240148037672, "rps_doc_unigram_entropy": 4.864738464355469, "rps_doc_word_count": 592, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.044598229229450226, "rps_doc_frac_chars_dupe_6grams": 0.044598229229450226, "rps_doc_frac_chars_dupe_7grams": 0.03806227818131447, "rps_doc_frac_chars_dupe_8grams": 0.02076124958693981, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.0188389103859663, "rps_doc_frac_chars_top_3gram": 0.011534029617905617, "rps_doc_frac_chars_top_4gram": 0.011534029617905617, "rps_doc_books_importance": -331.1968078613281, "rps_doc_books_importance_length_correction": -331.1968078613281, "rps_doc_openwebtext_importance": -182.89718627929688, "rps_doc_openwebtext_importance_length_correction": -182.89718627929688, "rps_doc_wikipedia_importance": -129.8492431640625, "rps_doc_wikipedia_importance_length_correction": -129.8492431640625 }, "fasttext": { "dclm": 0.8027825951576233, "english": 0.8469406366348267, "fineweb_edu_approx": 1.9172135591506958, "eai_general_math": 0.07392395287752151, "eai_open_web_math": 0.09371960163116455, "eai_web_code": 0.043819610029459 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.442", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.67", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-437,532,987,867,396,350
PDA View Full Version : Help with mysql chris.botma 09-21-2011, 09:52 AM I have the following coding, it generates a 6 digit number, now what I would like to know is, how am I gonna select a single number out of that 6 digits? Say if i want to select the second digit out of the 6? The reason for doing so, I want to add a check digit in MySQL. -- Delete the old version of the procedure so we start fresh DROP PROCEDURE IF EXISTS mwc_account_batch_generator; -- -------------------------------------------------------------------------------- -- Routine DDL -- Routine: mwc_account_batch_generator -- Project: mwc account management -- Author: Christiaan Botma -- Date: 2011-09-20 -- -- [Short Description of the routine goes here] -- -- [Define all input parameters here] -- -- [Define what is returned here] -- -- -------------------------------------------------------------------------------- -- change the delimeter to cause MySQL to see the following block -- of statements as a single command DELIMITER $$ -- Create the procedure, give it a name and define the input parameters CREATE PROCEDURE `mwc_account_batch_generator` ( IN in_total_accounts BIGINT , IN in_initial_balance float(10,2) -- CONSTRAINT loc_un UNIQUE(location) ) BEGIN DECLARE i INT DEFAULT 1; drop table if exists tmp_account_generator; create temporary table tmp_account_generator ( acc_number BIGINT not null, balance float(10,2) not null, UNIQUE KEY (acc_number) ); -- Stored procedure code goes here -- insert new accounts into temp table with the balance specified by initial balance. -- random account number generation rules: -- Number must contain 6 digits -- Number must not exist in the table, has to be unique WHILE i <= in_total_accounts DO insert into tmp_account_generator(acc_number, balance) values (100000 + (RAND() * 899999), in_initial_balance); SET i = i + 1; END WHILE; -- select all new generated accounts select * from tmp_account_generator; END$$ call mwc_account_batch_generator(10, 10.02); Old Pedant 09-21-2011, 09:24 PM ??? That code seems very very badly BROKEN to me! Sure, it guarantees that WHEN YOU RUN IT it will get unique account numbers. But because it drops and recreates the temp table each time, there is *NO GUARANTEE AT ALL* that it won't generate the *SAME* random 6-digit account number when it is run again! So today you assign account number 817832 to Mr. Jones. No problem. Tomorrow (or next week or next month or next year...or 13 seconds from now!) you end up assigning account number 817832 to Ms. Anderson! THIS IS REALLY REALLY BAD! I think you need to toss this out and rethink the entire process! Old Pedant 09-21-2011, 09:25 PM Oh...and why do you ask for 10 different account numbers, each time you call the SP? What happens if you need new account numbers for, say, 17 new customers? Or 3 new customers? This whole thing just screams for rewrite. Old Pedant 09-21-2011, 09:27 PM On top of that, a "check digit" is usually *NOT* simply a copy of one of the digits in the account number. Instead, a "check digit" is usually calculated mathematically to ensure that it really *is* a check digit. http://en.wikipedia.org/wiki/Check_digit chris.botma 09-22-2011, 08:52 AM Thanks for being honest, I'm totally new to tis scene. How would you then write a procedure to generate the 6 digit numbers and then add the check digit for it to be UNIQUE? I would realy appreciate the help guys. Thanks! Old Pedant 09-22-2011, 06:21 PM Well, to ensure uniqueness, you would need to keep track of all ALREADY-ISSUED account numbers. I would assume you have some table some place where you indeed associate a new user with his/her account number? USERS table or maybe ACCOUNTS table? In that table, the account number needs to be either the PRIMARY KEY or at least declared as a UNIQUE INDEX. Doing that will ensure that any attempt to assign a duplicate account number will produce an error. At this point, then, it's not important *how* you generate the account number. You could do it in PHP code, for example, instead of in a SQL procedure. You just have to make sure that you test it for uniqueness against that table (above). And since manipulating numbers--including finding a check digit value--is going to be easier in PHP (or ASP or JSP) code than in SQL, I'd do it all there, instead. So the pseudo-code would be something like this: (1) in PHP/ASP/JSP, generate a random account number, with check digit (2) query your db: SELECT COUNT(*) FROM accountsTable WHERE accountNumber = [newly generated random number] (3) If the COUNT(*) from step (2) comes back as OTHER than zero, go back to step 1. Keep it simple like that.
{ "url": "http://www.codingforums.com/archive/index.php/t-238676.html", "source_domain": "www.codingforums.com", "snapshot_id": "crawl=CC-MAIN-2017-09", "warc_metadata": { "Content-Length": "9256", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:T7QG3NEVKREM753CWW355QAQ7SJ5WMUI", "WARC-Concurrent-To": "<urn:uuid:3f944fb1-91b7-4df9-a5bd-5a39ff2ccc66>", "WARC-Date": "2017-02-19T15:01:51Z", "WARC-IP-Address": "199.245.54.187", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:SRIIMFTAPGBMLXCUO2HF4CEQZD2AF6WT", "WARC-Record-ID": "<urn:uuid:4eddc894-a95f-485c-8b2a-5cd0e1bcf4f5>", "WARC-Target-URI": "http://www.codingforums.com/archive/index.php/t-238676.html", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:dd08221a-d6b5-457a-8465-df55cab66f24>" }, "warc_info": "robots: classic\r\nhostname: ip-10-171-10-108.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2017-09\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for February 2017\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 1, 5, 6, 42, 43, 44, 45, 57, 78, 350, 351, 352, 413, 414, 468, 469, 470, 471, 472, 473, 557, 558, 573, 574, 614, 615, 650, 651, 679, 680, 700, 701, 704, 705, 753, 754, 757, 758, 796, 797, 800, 801, 835, 836, 839, 840, 924, 925, 926, 927, 928, 929, 995, 996, 1033, 1034, 1047, 1048, 1049, 1050, 1051, 1052, 1124, 1125, 1174, 1175, 1205, 1206, 1240, 1241, 1242, 1243, 1281, 1282, 1284, 1285, 1291, 1292, 1293, 1294, 1319, 1320, 1321, 1322, 1366, 1367, 1368, 1369, 1370, 1371, 1416, 1417, 1419, 1420, 1448, 1449, 1479, 1480, 1504, 1505, 1508, 1509, 1510, 1511, 1546, 1547, 1548, 1549, 1550, 1551, 1637, 1638, 1681, 1682, 1714, 1715, 1771, 1772, 1773, 1774, 1775, 1776, 1808, 1809, 1921, 1922, 1923, 1924, 1939, 1940, 1951, 1952, 1953, 1954, 1955, 1956, 1993, 1994, 1995, 1996, 1997, 1998, 2035, 2036, 2042, 2043, 2044, 2045, 2046, 2047, 2048, 2049, 2050, 2051, 2052, 2053, 2098, 2099, 2110, 2131, 2181, 2182, 2259, 2260, 2438, 2439, 2644, 2645, 2672, 2673, 2739, 2740, 2751, 2772, 2950, 2951, 2994, 2995, 3006, 3027, 3241, 3242, 3283, 3284, 3296, 3317, 3539, 3540, 3551, 3572, 3668, 3669, 3819, 3820, 4029, 4030, 4269, 4270, 4434, 4435, 4484, 4485, 4486, 4557, 4665, 4749, 4750 ], "line_end_idx": [ 1, 5, 6, 42, 43, 44, 45, 57, 78, 350, 351, 352, 413, 414, 468, 469, 470, 471, 472, 473, 557, 558, 573, 574, 614, 615, 650, 651, 679, 680, 700, 701, 704, 705, 753, 754, 757, 758, 796, 797, 800, 801, 835, 836, 839, 840, 924, 925, 926, 927, 928, 929, 995, 996, 1033, 1034, 1047, 1048, 1049, 1050, 1051, 1052, 1124, 1125, 1174, 1175, 1205, 1206, 1240, 1241, 1242, 1243, 1281, 1282, 1284, 1285, 1291, 1292, 1293, 1294, 1319, 1320, 1321, 1322, 1366, 1367, 1368, 1369, 1370, 1371, 1416, 1417, 1419, 1420, 1448, 1449, 1479, 1480, 1504, 1505, 1508, 1509, 1510, 1511, 1546, 1547, 1548, 1549, 1550, 1551, 1637, 1638, 1681, 1682, 1714, 1715, 1771, 1772, 1773, 1774, 1775, 1776, 1808, 1809, 1921, 1922, 1923, 1924, 1939, 1940, 1951, 1952, 1953, 1954, 1955, 1956, 1993, 1994, 1995, 1996, 1997, 1998, 2035, 2036, 2042, 2043, 2044, 2045, 2046, 2047, 2048, 2049, 2050, 2051, 2052, 2053, 2098, 2099, 2110, 2131, 2181, 2182, 2259, 2260, 2438, 2439, 2644, 2645, 2672, 2673, 2739, 2740, 2751, 2772, 2950, 2951, 2994, 2995, 3006, 3027, 3241, 3242, 3283, 3284, 3296, 3317, 3539, 3540, 3551, 3572, 3668, 3669, 3819, 3820, 4029, 4030, 4269, 4270, 4434, 4435, 4484, 4485, 4486, 4557, 4665, 4749, 4750, 4775 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4775, "ccnet_original_nlines": 207, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3192346394062042, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.08459214866161346, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.29003021121025085, "rps_doc_frac_unique_words": 0.4337517321109772, "rps_doc_mean_word_length": 4.776847839355469, "rps_doc_num_sentences": 44, "rps_doc_symbol_to_word_ratio": 0.0020141000859439373, "rps_doc_unigram_entropy": 5.2779412269592285, "rps_doc_word_count": 717, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.011678829789161682, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.037956200540065765, "rps_doc_frac_chars_top_3gram": 0.016058389097452164, "rps_doc_frac_chars_top_4gram": 0.012262769974768162, "rps_doc_books_importance": -346.0757751464844, "rps_doc_books_importance_length_correction": -346.0757751464844, "rps_doc_openwebtext_importance": -231.05032348632812, "rps_doc_openwebtext_importance_length_correction": -231.05032348632812, "rps_doc_wikipedia_importance": -171.2880401611328, "rps_doc_wikipedia_importance_length_correction": -171.2880401611328 }, "fasttext": { "dclm": 0.23133563995361328, "english": 0.7731737494468689, "fineweb_edu_approx": 1.5448294878005981, "eai_general_math": 0.7991311550140381, "eai_open_web_math": 0.2788997292518616, "eai_web_code": 0.8852604031562805 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.44", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "2", "label": "Partially Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
3,065,307,265,460,860,000
Definition of:flowchart flowchart A graphical representation of the sequence of operations in an information system or program. Information system flowcharts show how data flows from source documents through the computer to final distribution to users. Program flowcharts show the sequence of instructions in a single program or subroutine. Different symbols are used to draw each type of flowchart.
{ "url": "http://www.pcmag.com/encyclopedia/term/43329/flowchart", "source_domain": "www.pcmag.com", "snapshot_id": "crawl=CC-MAIN-2013-48", "warc_metadata": { "Content-Length": "158687", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:3ZV2DNV7WWGFMZFA7J57RUMODY32WIG2", "WARC-Concurrent-To": "<urn:uuid:14a93df9-79cd-4db4-9295-f5c2dc98a3d3>", "WARC-Date": "2013-12-05T16:59:18Z", "WARC-IP-Address": "184.51.126.9", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:CHXY6E7FFMYTROXZQOUQDOSTA2PQ455Y", "WARC-Record-ID": "<urn:uuid:9e2ce25e-f2bc-4ea7-865e-c0a423b5796e>", "WARC-Target-URI": "http://www.pcmag.com/encyclopedia/term/43329/flowchart", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:845227e4-e0dd-441e-8879-dff9a3e41d72>" }, "warc_info": "robots: classic\r\nhostname: ip-10-33-133-15.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2013-48\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for Winter 2013\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 24, 34, 35 ], "line_end_idx": [ 24, 34, 35, 400 ] }
{ "red_pajama_v2": { "ccnet_original_length": 400, "ccnet_original_nlines": 3, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.359375, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.015625, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.078125, "rps_doc_frac_unique_words": 0.6896551847457886, "rps_doc_mean_word_length": 5.810344696044922, "rps_doc_num_sentences": 4, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 3.57924747467041, "rps_doc_word_count": 58, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.06528189778327942, "rps_doc_frac_chars_top_3gram": 0.0771513432264328, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -22.85758399963379, "rps_doc_books_importance_length_correction": -22.85758399963379, "rps_doc_openwebtext_importance": -7.12301778793335, "rps_doc_openwebtext_importance_length_correction": -7.123018264770508, "rps_doc_wikipedia_importance": -7.127481460571289, "rps_doc_wikipedia_importance_length_correction": -7.127481937408447 }, "fasttext": { "dclm": 0.03000563010573387, "english": 0.8590730428695679, "fineweb_edu_approx": 3.3369061946868896, "eai_general_math": 0.9971655607223511, "eai_open_web_math": 0.40742772817611694, "eai_web_code": 0.8882368803024292 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.01", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "1", "label": "Remember" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "1", "label": "Factual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
858,256,850,252,286,800
PageRenderTime 55ms CodeModel.GetById 4ms app.highlight 46ms RepoModel.GetById 1ms app.codeStats 0ms /src/ois/src/win32/extras/WiiMote/OISWiiMote.cpp https://bitbucket.org/cabalistic/ogredeps/ C++ | 373 lines | 263 code | 54 blank | 56 comment | 80 complexity | 7511304a3ff9260994e650ffdf8aa3a2 MD5 | raw file 1#include "OISConfig.h" 2#ifdef OIS_WIN32_WIIMOTE_SUPPORT 3/* 4The zlib/libpng License 5 6Copyright (c) 2005-2007 Phillip Castaneda (pjcast -- www.wreckedgames.com) 7 8This software is provided 'as-is', without any express or implied warranty. In no event will 9the authors be held liable for any damages arising from the use of this software. 10 11Permission is granted to anyone to use this software for any purpose, including commercial 12applications, and to alter it and redistribute it freely, subject to the following 13restrictions: 14 15 1. The origin of this software must not be misrepresented; you must not claim that 16 you wrote the original software. If you use this software in a product, 17 an acknowledgment in the product documentation would be appreciated but is 18 not required. 19 20 2. Altered source versions must be plainly marked as such, and must not be 21 misrepresented as being the original software. 22 23 3. This notice may not be removed or altered from any source distribution. 24*/ 25#include "OISWiiMote.h" 26#include "OISWiiMoteFactoryCreator.h" 27#include "OISException.h" 28#include "OISWiiMoteForceFeedback.h" 29#define _USE_MATH_DEFINES 30#include <math.h> 31#include <limits.h> 32 33using namespace OIS; 34 35//-----------------------------------------------------------------------------------// 36WiiMote::WiiMote(InputManager* creator, int id, bool buffered, WiiMoteFactoryCreator* local_creator) : 37 JoyStick("cWiiMote", buffered, id, creator), 38 mWiiCreator(local_creator), 39 mtInitialized(false), 40 mRingBuffer(OIS_WII_EVENT_BUFFER), 41 mtLastButtonStates(0), 42 mtLastPOVState(0), 43 mtLastX(0.0f), 44 mtLastY(1.0f), 45 mtLastZ(0.0f), 46 mtLastNunChuckX(0.0f), 47 mtLastNunChuckY(1.0f), 48 mtLastNunChuckZ(0.0f), 49 mLastNunChuckXAxis(0), 50 mLastNunChuckYAxis(0), 51 _mWiiMoteMotionDelay(5), 52 mRumble(0) 53{ 54 mRumble = new WiiMoteForceFeedback(mWiiMote); 55} 56 57//-----------------------------------------------------------------------------------// 58WiiMote::~WiiMote() 59{ 60 delete mRumble; 61 62 if( mWiiMote.IsConnected() ) 63 { 64 mWiiMote.StopDataStream(); 65 mWiiMote.Disconnect(); 66 } 67 mWiiCreator->_returnWiiMote(mDevID); 68} 69 70//-----------------------------------------------------------------------------------// 71void WiiMote::_initialize() 72{ 73 if( mWiiMote.ConnectToDevice(mDevID) == false ) 74 OIS_EXCEPT(E_InputDisconnected, "Error connecting to WiiMote!"); 75 76 if( mWiiMote.StartDataStream() == false ) 77 OIS_EXCEPT(E_InputDisconnected, "Error starting WiiMote data stream!"); 78 79 //Fill in joystick information 80 mState.mVectors.clear(); 81 mState.mButtons.clear(); 82 mState.mAxes.clear(); 83 84 if( mWiiMote.IsNunChuckAttached() ) 85 { //Setup for WiiMote + nunChuck 86 mState.mVectors.resize(2); 87 mState.mButtons.resize(9); 88 mState.mAxes.resize(2); 89 mState.mAxes[0].absOnly = true; 90 mState.mAxes[1].absOnly = true; 91 } 92 else 93 { //Setup for WiiMote 94 mState.mVectors.resize(1); 95 mState.mButtons.resize(7); 96 } 97 98 mPOVs = 1; 99 mState.clear(); 100 mtInitialized = true; 101} 102 103//-----------------------------------------------------------------------------------// 104void WiiMote::_threadUpdate() 105{ 106 //Leave early if nothing is setup yet 107 if( mtInitialized == false ) 108 return; 109 110 //Oops, no room left in ring buffer.. have to wait for client app to call Capture() 111 if( mRingBuffer.GetWriteAvailable() == 0 ) 112 return; 113 114 WiiMoteEvent newEvent; 115 newEvent.clear(); 116 117 //Update read 118 mWiiMote.HeartBeat(); 119 120 //Get & check current button states 121 const cWiiMote::tButtonStatus &bState = mWiiMote.GetLastButtonStatus(); 122 _doButtonCheck(bState.m1, 0, newEvent.pushedButtons, newEvent.releasedButtons); //1 123 _doButtonCheck(bState.m2, 1, newEvent.pushedButtons, newEvent.releasedButtons); //2 124 _doButtonCheck(bState.mA, 2, newEvent.pushedButtons, newEvent.releasedButtons); //A 125 _doButtonCheck(bState.mB, 3, newEvent.pushedButtons, newEvent.releasedButtons); //B 126 _doButtonCheck(bState.mPlus, 4, newEvent.pushedButtons, newEvent.releasedButtons);//+ 127 _doButtonCheck(bState.mMinus, 5, newEvent.pushedButtons, newEvent.releasedButtons);//- 128 _doButtonCheck(bState.mHome, 6, newEvent.pushedButtons, newEvent.releasedButtons);//Home 129 130 //Check POV 131 newEvent.povChanged = _doPOVCheck(bState, newEvent.povDirection); 132 133 //Do motion check on main orientation - accounting for sensitivity factor 134 mWiiMote.GetCalibratedAcceleration(newEvent.x, newEvent.y, newEvent.z); 135 //Normalize new vector (old vector is already normalized) 136 float len = sqrt((newEvent.x*newEvent.x) + (newEvent.y*newEvent.y) + (newEvent.z*newEvent.z)); 137 newEvent.x /= len; 138 newEvent.y /= len; 139 newEvent.z /= len; 140 141 //Get new angle 142 float angle = acos((newEvent.x * mtLastX) + (newEvent.y * mtLastY) + (newEvent.z * mtLastZ)); 143 if( angle > (mVector3Sensitivity * (M_PI / 180.0)) ) 144 { //Store for next check 145 mtLastX = newEvent.x; 146 mtLastY = newEvent.y; 147 mtLastZ = newEvent.z; 148 149 if( _mWiiMoteMotionDelay <= 0 ) 150 newEvent.movement = true; //Set flag as moved 151 else 152 --_mWiiMoteMotionDelay; 153 } 154 155 //Act on NunChuck Data 156 if( mWiiMote.IsNunChuckAttached() ) 157 { 158 const cWiiMote::tChuckReport &bState = mWiiMote.GetLastChuckReport(); 159 _doButtonCheck(bState.mButtonC, 7, newEvent.pushedButtons, newEvent.releasedButtons); //C 160 _doButtonCheck(bState.mButtonZ, 8, newEvent.pushedButtons, newEvent.releasedButtons); //Z 161 162 mWiiMote.GetCalibratedChuckAcceleration(newEvent.nunChuckx, newEvent.nunChucky, newEvent.nunChuckz); 163 //Normalize new vector (old vector is already normalized) 164 float len = sqrt((newEvent.nunChuckx*newEvent.nunChuckx) + 165 (newEvent.nunChucky*newEvent.nunChucky) + 166 (newEvent.nunChuckz*newEvent.nunChuckz)); 167 168 newEvent.nunChuckx /= len; 169 newEvent.nunChucky /= len; 170 newEvent.nunChuckz /= len; 171 172 float angle = acos((newEvent.nunChuckx * mtLastNunChuckX) + 173 (newEvent.nunChucky * mtLastNunChuckY) + 174 (newEvent.nunChuckz * mtLastNunChuckZ)); 175 176 if( angle > (mVector3Sensitivity * (M_PI / 180.0)) ) 177 { //Store for next check 178 mtLastNunChuckX = newEvent.nunChuckx; 179 mtLastNunChuckY = newEvent.nunChucky; 180 mtLastNunChuckZ = newEvent.nunChuckz; 181 182 if( _mWiiMoteMotionDelay <= 0 ) 183 newEvent.movementChuck = true; 184 } 185 186 //Ok, Now check both NunChuck Joystick axes for movement 187 float tempX = 0.0f, tempY = 0.0f; 188 mWiiMote.GetCalibratedChuckStick(tempX, tempY); 189 190 //Convert to int and clip 191 newEvent.nunChuckXAxis = (int)(tempX * JoyStick::MAX_AXIS); 192 if( newEvent.nunChuckXAxis > JoyStick::MAX_AXIS ) 193 newEvent.nunChuckXAxis = JoyStick::MAX_AXIS; 194 else if( newEvent.nunChuckXAxis < JoyStick::MIN_AXIS ) 195 newEvent.nunChuckXAxis = JoyStick::MIN_AXIS; 196 197 newEvent.nunChuckYAxis = (int)(tempY * JoyStick::MAX_AXIS); 198 if( newEvent.nunChuckYAxis > JoyStick::MAX_AXIS ) 199 newEvent.nunChuckYAxis = JoyStick::MAX_AXIS; 200 else if( newEvent.nunChuckYAxis < JoyStick::MIN_AXIS ) 201 newEvent.nunChuckYAxis = JoyStick::MIN_AXIS; 202 203 //Apply a little dead-zone dampner 204 int xDiff = newEvent.nunChuckXAxis - mLastNunChuckXAxis; 205 if( xDiff > 1500 || xDiff < -1500 ) 206 { 207 mLastNunChuckXAxis = newEvent.nunChuckXAxis; 208 newEvent.nunChuckXAxisMoved = true; 209 } 210 211 int yDiff = newEvent.nunChuckYAxis - mLastNunChuckYAxis; 212 if( yDiff > 1500 || yDiff < -1500 ) 213 { 214 mLastNunChuckYAxis = newEvent.nunChuckYAxis; 215 newEvent.nunChuckYAxisMoved = true; 216 } 217 } 218 219 //Ok, put entry in ringbuffer if something changed 220 if(newEvent.pushedButtons || newEvent.releasedButtons || newEvent.povChanged || newEvent.movement || 221 newEvent.movementChuck || newEvent.nunChuckXAxisMoved || newEvent.nunChuckYAxisMoved) 222 { 223 mRingBuffer.Write(&newEvent, 1); 224 } 225 226 //mWiiMote.PrintStatus(); 227} 228 229//-----------------------------------------------------------------------------------// 230void WiiMote::_doButtonCheck(bool new_state, int ois_button, unsigned int &pushed, unsigned int &released) 231{ 232 const bool old_state = ((mtLastButtonStates & ( 1L << ois_button )) == 0) ? false : true; 233 234 //Check to see if new state and old state are the same, and hence, need no change 235 if( new_state == old_state ) 236 return; 237 238 //Ok, so it changed... but how? 239 if( new_state ) 240 { //Ok, new state is pushed, old state was not pushed.. so send button press 241 mtLastButtonStates |= 1 << ois_button; //turn the bit flag on 242 pushed |= 1 << ois_button; 243 } 244 else 245 { //Ok, so new state is not pushed, and old state was pushed.. So, send release 246 mtLastButtonStates &= ~(1 << ois_button); //turn the bit flag off 247 released |= 1 << ois_button; 248 } 249} 250 251//-----------------------------------------------------------------------------------// 252bool WiiMote::_doPOVCheck(const cWiiMote::tButtonStatus &bState, unsigned int &newPosition) 253{ 254 newPosition = Pov::Centered; 255 256 if( bState.mUp ) 257 newPosition |= Pov::North; 258 else if( bState.mDown ) 259 newPosition |= Pov::South; 260 261 if( bState.mLeft ) 262 newPosition |= Pov::West; 263 else if( bState.mRight ) 264 newPosition |= Pov::East; 265 266 //Was there a change? 267 if( mtLastPOVState != newPosition ) 268 { 269 mtLastPOVState = newPosition; 270 return true; 271 } 272 273 return false; 274} 275 276//-----------------------------------------------------------------------------------// 277void WiiMote::setBuffered(bool buffered) 278{ 279 mBuffered = buffered; 280} 281 282//-----------------------------------------------------------------------------------// 283void WiiMote::capture() 284{ 285 //Anything to read? 286 int entries = mRingBuffer.GetReadAvailable(); 287 if( entries <= 0 ) 288 return; 289 290 WiiMoteEvent events[OIS_WII_EVENT_BUFFER]; 291 if( entries > OIS_WII_EVENT_BUFFER ) 292 entries = OIS_WII_EVENT_BUFFER; 293 294 mRingBuffer.Read(events, entries); 295 296 //Loop through each event 297 for( int i = 0; i < entries; ++i ) 298 { 299 //Any movement changes in the main accellerometers? 300 if( events[i].movement ) 301 { 302 mState.mVectors[0].x = events[i].x; 303 mState.mVectors[0].y = events[i].y; 304 mState.mVectors[0].z = events[i].z; 305 if( mBuffered && mListener ) 306 if( !mListener->vector3Moved( JoyStickEvent( this, mState ), 0 ) ) return; 307 } 308 309 //Check NunChuck movements 310 if( events[i].movementChuck ) 311 { 312 mState.mVectors[1].x = events[i].nunChuckx; 313 mState.mVectors[1].y = events[i].nunChucky; 314 mState.mVectors[1].z = events[i].nunChuckz; 315 if( mBuffered && mListener ) 316 if( !mListener->vector3Moved( JoyStickEvent( this, mState ), 1 ) ) return; 317 } 318 319 if( events[i].nunChuckXAxisMoved ) 320 { 321 mState.mAxes[0].abs = events[i].nunChuckXAxis; 322 323 if( mBuffered && mListener ) 324 if( !mListener->axisMoved( JoyStickEvent( this, mState ), 0 ) ) return; 325 } 326 327 if( events[i].nunChuckYAxisMoved ) 328 { 329 mState.mAxes[1].abs = events[i].nunChuckYAxis; 330 331 if( mBuffered && mListener ) 332 if( !mListener->axisMoved( JoyStickEvent( this, mState ), 1 ) ) return; 333 } 334 335 //Has the hat swtich changed? 336 if( events[i].povChanged ) 337 { 338 mState.mPOV[0].direction = events[i].povDirection; 339 if( mBuffered && mListener ) 340 if( !mListener->povMoved( JoyStickEvent( this, mState ), 0 ) ) return; 341 } 342 343 //Check for any pushed/released events for each button bit 344 int buttons = (int)mState.mButtons.size(); 345 for( int b = 0; b < buttons; ++b ) 346 { 347 unsigned bit_flag = 1 << b; 348 if( (events[i].pushedButtons & bit_flag) != 0 ) 349 { //send event 350 mState.mButtons[b] = true; 351 if( mBuffered && mListener ) 352 if( !mListener->buttonPressed( JoyStickEvent( this, mState ), b ) ) return; 353 } 354 355 if( (events[i].releasedButtons & bit_flag) != 0 ) 356 { //send event 357 mState.mButtons[b] = false; 358 if( mBuffered && mListener ) 359 if( !mListener->buttonReleased( JoyStickEvent( this, mState ), b ) ) return; 360 } 361 } 362 } 363} 364 365//-----------------------------------------------------------------------------------// 366Interface* WiiMote::queryInterface(Interface::IType type) 367{ 368 if( type == Interface::ForceFeedback && mtInitialized ) 369 return mRumble; 370 371 return 0; 372} 373#endif
{ "url": "https://searchcode.com/file/304088/src/ois/src/win32/extras/WiiMote/OISWiiMote.cpp/", "source_domain": "searchcode.com", "snapshot_id": "crawl=CC-MAIN-2021-43", "warc_metadata": { "Content-Length": "74635", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:SKHUWKAMKKENIJ7NFIFFNLOKYKMT64SG", "WARC-Concurrent-To": "<urn:uuid:e1cf2ea5-fc45-494d-87f1-ce9734b1fba9>", "WARC-Date": "2021-10-20T01:35:24Z", "WARC-IP-Address": "78.47.90.135", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:CUEREYBXCZWE6FBUIC3TOQFOJ667TUIY", "WARC-Record-ID": "<urn:uuid:e47ac6f8-a116-472f-a06f-103f89c6e8b4>", "WARC-Target-URI": "https://searchcode.com/file/304088/src/ois/src/win32/extras/WiiMote/OISWiiMote.cpp/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:1623201d-89a6-4eaf-86d2-902ae7579040>" }, "warc_info": "isPartOf: CC-MAIN-2021-43\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for October 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-13\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 101, 102, 151, 152, 195, 312, 338, 374, 380, 407, 411, 489, 493, 589, 674, 678, 772, 858, 875, 879, 969, 1046, 1126, 1145, 1149, 1231, 1283, 1287, 1369, 1375, 1402, 1443, 1472, 1512, 1541, 1562, 1585, 1589, 1613, 1617, 1708, 1814, 1863, 1895, 1921, 1960, 1987, 2010, 2029, 2048, 2067, 2094, 2121, 2148, 2175, 2202, 2231, 2246, 2251, 2301, 2306, 2310, 2401, 2424, 2429, 2449, 2453, 2486, 2492, 2524, 2552, 2558, 2599, 2604, 2608, 2699, 2730, 2735, 2787, 2857, 2861, 2907, 2984, 2988, 3023, 3052, 3081, 3107, 3111, 3151, 3188, 3220, 3252, 3281, 3318, 3355, 3361, 3370, 3396, 3428, 3460, 3466, 3470, 3485, 3505, 3531, 3536, 3540, 3631, 3664, 3669, 3711, 3744, 3757, 3761, 3849, 3896, 3909, 3913, 3940, 3962, 3966, 3984, 4010, 4014, 4054, 4130, 4218, 4306, 4394, 4482, 4572, 4663, 4756, 4760, 4776, 4846, 4850, 4928, 5004, 5066, 5165, 5188, 5211, 5234, 5239, 5259, 5357, 5414, 5443, 5470, 5497, 5524, 5528, 5565, 5617, 5627, 5657, 5663, 5667, 5694, 5734, 5740, 5815, 5910, 6005, 6009, 6115, 6178, 6243, 6304, 6356, 6360, 6392, 6424, 6456, 6460, 6526, 6588, 6641, 6645, 6703, 6733, 6777, 6821, 6865, 6869, 6907, 6945, 6952, 6956, 7018, 7057, 7110, 7116, 7147, 7212, 7267, 7318, 7378, 7429, 7433, 7498, 7553, 7604, 7664, 7715, 7719, 7759, 7821, 7862, 7869, 7920, 7962, 7969, 7973, 8035, 8076, 8083, 8134, 8176, 8183, 8189, 8193, 8248, 8353, 8446, 8452, 8490, 8496, 8500, 8530, 8535, 8539, 8630, 8740, 8745, 8839, 8844, 8930, 8963, 8976, 8980, 9016, 9036, 9117, 9184, 9216, 9222, 9231, 9315, 9386, 9420, 9426, 9431, 9435, 9526, 9621, 9626, 9659, 9663, 9684, 9716, 9744, 9776, 9780, 9803, 9834, 9863, 9894, 9898, 9924, 9964, 9970, 10005, 10023, 10029, 10033, 10051, 10056, 10060, 10151, 10195, 10200, 10226, 10231, 10235, 10326, 10353, 10358, 10382, 10432, 10455, 10468, 10472, 10519, 10560, 10597, 10602, 10641, 10645, 10675, 10714, 10720, 10777, 10807, 10814, 10856, 10898, 10940, 10975, 11057, 11064, 11068, 11100, 11135, 11142, 11192, 11242, 11292, 11327, 11409, 11416, 11420, 11460, 11467, 11520, 11524, 11559, 11638, 11645, 11649, 11689, 11696, 11749, 11753, 11788, 11867, 11874, 11878, 11913, 11945, 11952, 12009, 12044, 12122, 12129, 12133, 12197, 12245, 12285, 12292, 12326, 12380, 12401, 12435, 12471, 12555, 12563, 12567, 12623, 12644, 12679, 12715, 12800, 12808, 12815, 12821, 12826, 12830, 12921, 12982, 12987, 13047, 13068, 13072, 13086, 13091 ], "line_end_idx": [ 101, 102, 151, 152, 195, 312, 338, 374, 380, 407, 411, 489, 493, 589, 674, 678, 772, 858, 875, 879, 969, 1046, 1126, 1145, 1149, 1231, 1283, 1287, 1369, 1375, 1402, 1443, 1472, 1512, 1541, 1562, 1585, 1589, 1613, 1617, 1708, 1814, 1863, 1895, 1921, 1960, 1987, 2010, 2029, 2048, 2067, 2094, 2121, 2148, 2175, 2202, 2231, 2246, 2251, 2301, 2306, 2310, 2401, 2424, 2429, 2449, 2453, 2486, 2492, 2524, 2552, 2558, 2599, 2604, 2608, 2699, 2730, 2735, 2787, 2857, 2861, 2907, 2984, 2988, 3023, 3052, 3081, 3107, 3111, 3151, 3188, 3220, 3252, 3281, 3318, 3355, 3361, 3370, 3396, 3428, 3460, 3466, 3470, 3485, 3505, 3531, 3536, 3540, 3631, 3664, 3669, 3711, 3744, 3757, 3761, 3849, 3896, 3909, 3913, 3940, 3962, 3966, 3984, 4010, 4014, 4054, 4130, 4218, 4306, 4394, 4482, 4572, 4663, 4756, 4760, 4776, 4846, 4850, 4928, 5004, 5066, 5165, 5188, 5211, 5234, 5239, 5259, 5357, 5414, 5443, 5470, 5497, 5524, 5528, 5565, 5617, 5627, 5657, 5663, 5667, 5694, 5734, 5740, 5815, 5910, 6005, 6009, 6115, 6178, 6243, 6304, 6356, 6360, 6392, 6424, 6456, 6460, 6526, 6588, 6641, 6645, 6703, 6733, 6777, 6821, 6865, 6869, 6907, 6945, 6952, 6956, 7018, 7057, 7110, 7116, 7147, 7212, 7267, 7318, 7378, 7429, 7433, 7498, 7553, 7604, 7664, 7715, 7719, 7759, 7821, 7862, 7869, 7920, 7962, 7969, 7973, 8035, 8076, 8083, 8134, 8176, 8183, 8189, 8193, 8248, 8353, 8446, 8452, 8490, 8496, 8500, 8530, 8535, 8539, 8630, 8740, 8745, 8839, 8844, 8930, 8963, 8976, 8980, 9016, 9036, 9117, 9184, 9216, 9222, 9231, 9315, 9386, 9420, 9426, 9431, 9435, 9526, 9621, 9626, 9659, 9663, 9684, 9716, 9744, 9776, 9780, 9803, 9834, 9863, 9894, 9898, 9924, 9964, 9970, 10005, 10023, 10029, 10033, 10051, 10056, 10060, 10151, 10195, 10200, 10226, 10231, 10235, 10326, 10353, 10358, 10382, 10432, 10455, 10468, 10472, 10519, 10560, 10597, 10602, 10641, 10645, 10675, 10714, 10720, 10777, 10807, 10814, 10856, 10898, 10940, 10975, 11057, 11064, 11068, 11100, 11135, 11142, 11192, 11242, 11292, 11327, 11409, 11416, 11420, 11460, 11467, 11520, 11524, 11559, 11638, 11645, 11649, 11689, 11696, 11749, 11753, 11788, 11867, 11874, 11878, 11913, 11945, 11952, 12009, 12044, 12122, 12129, 12133, 12197, 12245, 12285, 12292, 12326, 12380, 12401, 12435, 12471, 12555, 12563, 12567, 12623, 12644, 12679, 12715, 12800, 12808, 12815, 12821, 12826, 12830, 12921, 12982, 12987, 13047, 13068, 13072, 13086, 13091, 13100 ] }
{ "red_pajama_v2": { "ccnet_original_length": 13100, "ccnet_original_nlines": 378, "rps_doc_curly_bracket": 0.0045801498927176, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.10652413964271545, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.010689269751310349, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.5576851963996887, "rps_doc_frac_unique_words": 0.614130437374115, "rps_doc_mean_word_length": 6.959627151489258, "rps_doc_num_sentences": 229, "rps_doc_symbol_to_word_ratio": 0.00405455008149147, "rps_doc_unigram_entropy": 6.2666778564453125, "rps_doc_word_count": 1288, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.06001785025000572, "rps_doc_frac_chars_dupe_6grams": 0.01963409036397934, "rps_doc_frac_chars_dupe_7grams": 0.01963409036397934, "rps_doc_frac_chars_dupe_8grams": 0.010263280011713505, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.03926818072795868, "rps_doc_frac_chars_top_3gram": 0.015618029981851578, "rps_doc_frac_chars_top_4gram": 0.00803213007748127, "rps_doc_books_importance": -1161.4451904296875, "rps_doc_books_importance_length_correction": -1161.4451904296875, "rps_doc_openwebtext_importance": -755.3348999023438, "rps_doc_openwebtext_importance_length_correction": -755.3348999023438, "rps_doc_wikipedia_importance": -448.6196594238281, "rps_doc_wikipedia_importance_length_correction": -448.6196594238281 }, "fasttext": { "dclm": 0.35080593824386597, "english": 0.45243459939956665, "fineweb_edu_approx": 1.8045485019683838, "eai_general_math": 0.7183176875114441, "eai_open_web_math": 0.08294326066970825, "eai_web_code": 0.6439844369888306 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "794.8", "labels": { "level_1": "Arts", "level_2": "Amusements and Recreation", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "1", "label": "Leftover HTML" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-407,270,022,210,736,830
るりまサーチ 最速Rubyリファレンスマニュアル検索! 21件ヒット [1-21件を表示] (0.019秒) 別のキーワード 1. _builtin readline 2. readline readline 3. io readline 4. argf.class readline 5. csv readline ライブラリ キーワード 検索結果 Kernel.#readline(rs = $/) -> String (18145.0) ARGFから一行読み込んで、それを返します。 行の区切りは引数 rs で指定した文字列になります。 ...に発生します。 @raise EOFError readline でファイル末端(EOF)を検出すると発生します。 ---main.rb--- ARGV << 'b.txt' << 'c.txt' p readline #=> "hello\n" p readline(nil) #=> "it\ncommon\n" p readline("") #=> "ARGF\n\n" p readline('、') #=> "スクリプトに指... ...した引数 (Object::ARGV を参照) をファイル名と\nみなして、" p readline #=> "それらのファイルを連結した 1 つの仮想ファイルを表すオブジェクトです。 \n" p readline # end of file reached (EOFError) --- b.txt --- hello it common --- c.txt -... ...-- ARGF スクリプトに指定した引数 (Object::ARGV を参照) をファイル名と みなして、それらのファイルを連結した 1 つの仮想ファイルを表すオブジェクトです。 @see $/,ARGF,Kernel.#readlines,Kernel.#gets... Kernel.#readlines(rs = $/) -> [String] | nil (6102.0) ARGFを Kernel.#gets(rs) でEOFまで読み込んで、その各行を要素としてもつ配列を返します。 行の区切りは引数 rs で指定した文字列になります。 ...ARGFを Kernel.#gets(rs) でEOFまで読み込んで、その各行を要素としてもつ配列を返します。 行の区切りは引数 rs で指定した文字列になります。 rs に nil を指定すると行区切りなしとみなします。 空文字列 "" を指定すると連続... ...ARGV << 'b.txt' << 'b.txt' p readlines #=> ["hello\n", "it\n", "\n", "common\n", "hello\n", "it\n", "\n", "common\n"] ARGV << 'b.txt' << 'b.txt' p readlines(nil) #=> ["hello\nit\n\ncommon\n", "hello\nit\n\ncommon\n"] ARGV << 'b.txt' << 'b.txt' p readlines("") #=> ["hello\nit\n\n", "c... ...ommon\n", "hello\nit\n\n", "common\n"] ARGV << 'b.txt' << 'b.txt' p readlines('it') #=> ["hello\nit", "\n\ncommon\n", "hello\nit", "\n\ncommon\n"] p readlines #=> nil --- b.txt --- hello it common @see $/,ARGF,Kernel.#gets... Kernel.#gets(rs = $/) -> String | nil (14.0) ARGFから一行読み込んで、それを返します。 行の区切りは引数 rs で指定した文字列になります。 ...、" p gets #=> "それらのファイルを連結した 1 つの仮想ファイルを表すオブジェクトです。 \n" p gets #=> nil p readline # end of file reached (EOFError) --- b.txt --- hello it common --- c.txt --- ARGF スクリプトに指定した引数 (Object:... ...:ARGV を参照) をファイル名と みなして、それらのファイルを連結した 1 つの仮想ファイルを表すオブジェクトです。 @see $/,ARGF,Kernel.#readlines,Kernel.#readline...
{ "url": "http://rurema.clear-code.com/module:Kernel/type:module-function/query:readline/", "source_domain": "rurema.clear-code.com", "snapshot_id": "crawl=CC-MAIN-2018-17", "warc_metadata": { "Content-Length": "20579", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:PDOSXMXGKO3IMB5XKQBIC24H3K2AARVB", "WARC-Concurrent-To": "<urn:uuid:30193efa-84fe-43df-bc0e-92444a44b28a>", "WARC-Date": "2018-04-22T12:32:11Z", "WARC-IP-Address": "133.130.99.16", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:IOWTA7LDP7YPOVC7BG4IGEKXOKS4B4QZ", "WARC-Record-ID": "<urn:uuid:ba2bfdba-7bfc-4992-9d75-4e01226d31c6>", "WARC-Target-URI": "http://rurema.clear-code.com/module:Kernel/type:module-function/query:readline/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:99ee44c2-7983-4d20-9b1c-c76d936114d2>" }, "warc_info": "robots: classic\r\nhostname: ip-10-152-23-81.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-17\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for April 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 7, 8, 29, 56, 57, 65, 66, 89, 112, 129, 154, 172, 173, 179, 180, 186, 187, 192, 193, 239, 240, 290, 291, 302, 352, 353, 367, 394, 419, 454, 484, 516, 559, 616, 660, 674, 680, 683, 690, 705, 711, 716, 717, 757, 799, 800, 847, 848, 902, 903, 986, 987, 1046, 1073, 1074, 1103, 1123, 1153, 1244, 1245, 1272, 1344, 1345, 1372, 1416, 1458, 1459, 1486, 1567, 1587, 1601, 1607, 1610, 1611, 1618, 1619, 1648, 1649, 1694, 1695, 1745, 1746, 1752, 1805, 1820, 1864, 1878, 1884, 1887, 1894, 1908, 1913, 1914, 1939, 1961, 2003, 2004 ], "line_end_idx": [ 7, 8, 29, 56, 57, 65, 66, 89, 112, 129, 154, 172, 173, 179, 180, 186, 187, 192, 193, 239, 240, 290, 291, 302, 352, 353, 367, 394, 419, 454, 484, 516, 559, 616, 660, 674, 680, 683, 690, 705, 711, 716, 717, 757, 799, 800, 847, 848, 902, 903, 986, 987, 1046, 1073, 1074, 1103, 1123, 1153, 1244, 1245, 1272, 1344, 1345, 1372, 1416, 1458, 1459, 1486, 1567, 1587, 1601, 1607, 1610, 1611, 1618, 1619, 1648, 1649, 1694, 1695, 1745, 1746, 1752, 1805, 1820, 1864, 1878, 1884, 1887, 1894, 1908, 1913, 1914, 1939, 1961, 2003, 2004, 2054 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2054, "ccnet_original_nlines": 97, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.15808171033859253, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03730018064379692, "rps_doc_frac_lines_end_with_ellipsis": 0.08163265138864517, "rps_doc_frac_no_alph_words": 0.6110124588012695, "rps_doc_frac_unique_words": 0.4512820541858673, "rps_doc_mean_word_length": 7.138461589813232, "rps_doc_num_sentences": 47, "rps_doc_symbol_to_word_ratio": 0.07104796171188354, "rps_doc_unigram_entropy": 4.1471171379089355, "rps_doc_word_count": 195, "rps_doc_frac_chars_dupe_10grams": 0.10201148688793182, "rps_doc_frac_chars_dupe_5grams": 0.4073275923728943, "rps_doc_frac_chars_dupe_6grams": 0.2916666567325592, "rps_doc_frac_chars_dupe_7grams": 0.10201148688793182, "rps_doc_frac_chars_dupe_8grams": 0.10201148688793182, "rps_doc_frac_chars_dupe_9grams": 0.10201148688793182, "rps_doc_frac_chars_top_2gram": 0.028735630214214325, "rps_doc_frac_chars_top_3gram": 0.07183907926082611, "rps_doc_frac_chars_top_4gram": 0.03735632076859474, "rps_doc_books_importance": -232.68310546875, "rps_doc_books_importance_length_correction": -232.68310546875, "rps_doc_openwebtext_importance": -128.86770629882812, "rps_doc_openwebtext_importance_length_correction": -128.86770629882812, "rps_doc_wikipedia_importance": -28.89289665222168, "rps_doc_wikipedia_importance_length_correction": -28.89289665222168 }, "fasttext": { "dclm": 0.9977279901504517, "english": 0.026651160791516304, "fineweb_edu_approx": 2.9681880474090576, "eai_general_math": 0.18088579177856445, "eai_open_web_math": 0.1480068564414978, "eai_web_code": 0.9281912446022034 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1332", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.133", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-2,704,099,821,607,427,000
Java Уроки Java для начинающих 24 урока 50 заданий Справочник Компилятор #17 - Анонимные классы и вложенные классы #17 - Анонимные классы и вложенные классы Java В этом уроке мы изучим анонимные классы, а также рассмотрим что такое вложенные классы. Зачем они нужны и как ими пользоваться в языке Java Видео урок: Вложенные классы записываются внутри других классов. Это может быть полезно, если вложенный класс является частью главного класса. К примеру, есть класс Автомобиль и мы создаем вложенный класс Двигатель. Таким образом все находиться в одном месте и в этом удобно ориентироваться. class Auto { String model; class Engine { private boolean working = false; public void work () { working = true; System.out.print("Двигатель запущен!"); } } Engine en = new Engine(); } public class Main { public static void main(String[] args) { Auto bmw = new Auto(); bmw.en.work(); } } Как видите, объекты вложенных классов создаются в самом классе. При создании объекта главного класса мы также можем получить доступ ко всем его объектам и к их методам. Анонимные классы - это классы, которые не имеют имени и их создание оправдано если вам необходимо запись лишь пару методов или же свойств в класс. Анонимные классы можно записывать прямиком в функциях или же других классах. Пример анонимного класса: Auto car = new Auto() { void flyingMoto () { System.out.print ("Летающий мотоцикл"); } }; Исходный код Весь код будет доступен после подписки на проект! Онлайн редактор кода Загрузка... Задание к уроку Необходимо оформить подписку на проект, чтобы получить доступ ко всем домашним заданиям! Большое задание по курсу Вам необходимо оформить подписку на сайте, чтобы получить большое задание. Такие задания есть к каждому курсу. В них входит задание, методика решения, а также "Готовое решение". PS: подобные задания доступны при подписке от 1 месяца! Java Также стоит посмотреть
{ "url": "https://itproger.com/course/java/17", "source_domain": "itproger.com", "snapshot_id": "crawl=CC-MAIN-2019-18", "warc_metadata": { "Content-Length": "33466", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:IT3NJOO7IV4F62RV7MTB7PT5GB456VUL", "WARC-Concurrent-To": "<urn:uuid:cdaab688-1a47-4d14-b6f1-9c09d6c90b46>", "WARC-Date": "2019-04-22T00:26:57Z", "WARC-IP-Address": "185.68.16.143", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:YYSOV3NTKAFMJVZXVTWOTT23DZ574KPZ", "WARC-Record-ID": "<urn:uuid:bf492b3d-6a5d-42f7-a533-9e29192bdd29>", "WARC-Target-URI": "https://itproger.com/course/java/17", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:f8dc3563-8c9d-46cd-b6a0-6e0d416c1f09>" }, "warc_info": "isPartOf: CC-MAIN-2019-18\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for April 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-63-222-147.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 5, 6, 32, 33, 75, 76, 118, 119, 161, 162, 163, 168, 169, 309, 310, 322, 323, 603, 616, 634, 635, 654, 695, 696, 726, 754, 806, 816, 822, 823, 853, 855, 856, 876, 877, 922, 953, 976, 982, 984, 1153, 1154, 1404, 1428, 1451, 1497, 1501, 1504, 1505, 1518, 1519, 1569, 1570, 1591, 1592, 1604, 1605, 1621, 1622, 1711, 1712, 1737, 1738, 1916, 1972, 1973, 1974, 1979, 1980 ], "line_end_idx": [ 5, 6, 32, 33, 75, 76, 118, 119, 161, 162, 163, 168, 169, 309, 310, 322, 323, 603, 616, 634, 635, 654, 695, 696, 726, 754, 806, 816, 822, 823, 853, 855, 856, 876, 877, 922, 953, 976, 982, 984, 1153, 1154, 1404, 1428, 1451, 1497, 1501, 1504, 1505, 1518, 1519, 1569, 1570, 1591, 1592, 1604, 1605, 1621, 1622, 1711, 1712, 1737, 1738, 1916, 1972, 1973, 1974, 1979, 1980, 2002 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2002, "ccnet_original_nlines": 69, "rps_doc_curly_bracket": 0.006993010174483061, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.014164309948682785, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.011331439949572086, "rps_doc_frac_lines_end_with_ellipsis": 0.014285709708929062, "rps_doc_frac_no_alph_words": 0.8498583436012268, "rps_doc_frac_unique_words": 0.6407407522201538, "rps_doc_mean_word_length": 5.544444561004639, "rps_doc_num_sentences": 24, "rps_doc_symbol_to_word_ratio": 0.008498580195009708, "rps_doc_unigram_entropy": 4.943144798278809, "rps_doc_word_count": 270, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.04408818110823631, "rps_doc_frac_chars_dupe_6grams": 0.04408818110823631, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.05010019987821579, "rps_doc_frac_chars_top_3gram": 0.022712089121341705, "rps_doc_frac_chars_top_4gram": 0.024048099294304848, "rps_doc_books_importance": -160.8008270263672, "rps_doc_books_importance_length_correction": -160.8008270263672, "rps_doc_openwebtext_importance": -81.11125946044922, "rps_doc_openwebtext_importance_length_correction": -81.11125946044922, "rps_doc_wikipedia_importance": -42.3719367980957, "rps_doc_wikipedia_importance_length_correction": -42.3719367980957 }, "fasttext": { "dclm": 0.8694761991500854, "english": 0, "fineweb_edu_approx": 2.4364354610443115, "eai_general_math": -0.000005840000085299835, "eai_open_web_math": 0.17580044269561768, "eai_web_code": 0.6124312281608582 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1332", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.133", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "2", "label": "Click Here References" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
1,041,143,771,814,224,800
cancel Showing results for  Search instead for  Did you mean:  Guidance about Integration on Website superiorapk Newcomer Newcomer Hi. Yasir here. I have been running a blog and i am looking how to integrate my blog with zoom. Any volunteer to assist in this regard. 2 REPLIES 2 YaBoiB Community Champion | Zoom Employee Community Champion | Zoom Employee Hello @superiorapk    Zoom already has a blog here blog.zoom.us what is it that you are wanting to integrate your blog to?     Please check out our marketplace.zoom.us to find where many other users are integrating their apps to Zoom using either SDK or OAuth apps.    Please let me know if there is anything more that I can do to assist you.    Brandon  Brandon (he/him/his) Zoom Community Champion Have you heard of Zoom AI Companion? difeent3 Newcomer Newcomer I can provide guidance on integration for a website. Integration typically refers to the process of combining different software systems or components to work together seamlessly. Here are some general steps and considerations for integrating various elements on a website: 1. Identify the Integration Requirement: Determine what specific functionality or feature you want to integrate into your website. It could be integrating payment gateways, social media sharing, customer support chat, third-party APIs, or any other service. 2. Research Available Solutions: Explore the available tools, plugins, or libraries that can help you achieve the desired integration. Look for reliable and well-documented options that align with your requirements. Consider factors like compatibility, support, security, and cost. 3. Understand API Documentation: If you're integrating with an external service via an API (Application Programming Interface), thoroughly review the API documentation provided by the service provider. It will outline the methods, endpoints, and data formats required to interact with the service. 4. Obtain Necessary Credentials: Some integrations may require API keys, access tokens, or authentication credentials. Follow the provider's instructions to obtain these credentials securely. 5. Implement Integration Code: Depending on the integration method, you may need to write code or configure settings to enable the integration. This could involve adding JavaScript, CSS, or HTML snippets, modifying backend code, or utilizing plugins/modules. 6. Test the Integration: After implementing the integration, thoroughly test it to ensure it works as expected. Test different scenarios, edge cases, and potential errors to identify and fix any issues. 7. Monitor and Maintain: Continuously monitor the integrated components to ensure they remain functional and secure. Stay updated with any changes or updates from the service providers and adapt your integration accordingly. 8. Security Considerations: Pay attention to security practices while integrating external services. Use secure connections (HTTPS), validate user inputs, and implement appropriate security measures to protect user data. 9. Performance Optimization: Integration may impact your website's performance. Optimize the integration code and minimize unnecessary requests to improve loading times and user experience. 10. Documentation: Document the integration process and any specific requirements for future reference or troubleshooting purposes. This documentation will be helpful if you need to update or modify the integration in the future. Remember, specific integration processes can vary depending on the services or tools you're integrating. It's essential to follow the documentation and guidelines provided by the service providers to ensure a successful integration.
{ "url": "https://community.zoom.com:443/t5/Zoom-Rooms-and-Workspaces/Guidance-about-Integration-on-Website/td-p/73186", "source_domain": "community.zoom.com:443", "snapshot_id": "CC-MAIN-2024-26", "warc_metadata": { "Content-Length": "231541", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:VH5N4QU2HLC34LODKTXQ4YV2MF5MMKRT", "WARC-Concurrent-To": "<urn:uuid:d0ca2710-7ed4-4407-8860-a81230b63f7d>", "WARC-Date": "2024-06-15T08:35:27Z", "WARC-IP-Address": "18.160.18.120", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:NUGI3MQ46RAJ2FHEMVWBO7RBN2XIM64B", "WARC-Record-ID": "<urn:uuid:c518659e-fc63-44e0-b64c-30022af4c93f>", "WARC-Target-URI": "https://community.zoom.com:443/t5/Zoom-Rooms-and-Workspaces/Guidance-about-Integration-on-Website/td-p/73186", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:92131b7e-936f-45b7-a0bc-5ca9e178dcc5>" }, "warc_info": "isPartOf: CC-MAIN-2024-26\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-115\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 7, 28, 48, 63, 64, 102, 103, 115, 124, 133, 134, 138, 139, 151, 152, 232, 233, 273, 274, 286, 287, 294, 329, 364, 365, 384, 385, 387, 388, 492, 493, 495, 496, 636, 637, 639, 640, 715, 716, 718, 719, 728, 729, 730, 751, 775, 812, 813, 822, 831, 840, 841, 1115, 1116, 1376, 1377, 1661, 1662, 1962, 1963, 2157, 2158, 2419, 2420, 2625, 2626, 2853, 2854, 3077, 3078, 3270, 3271, 3503, 3504 ], "line_end_idx": [ 7, 28, 48, 63, 64, 102, 103, 115, 124, 133, 134, 138, 139, 151, 152, 232, 233, 273, 274, 286, 287, 294, 329, 364, 365, 384, 385, 387, 388, 492, 493, 495, 496, 636, 637, 639, 640, 715, 716, 718, 719, 728, 729, 730, 751, 775, 812, 813, 822, 831, 840, 841, 1115, 1116, 1376, 1377, 1661, 1662, 1962, 1963, 2157, 2158, 2419, 2420, 2625, 2626, 2853, 2854, 3077, 3078, 3270, 3271, 3503, 3504, 3736 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3736, "ccnet_original_nlines": 74, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3348837196826935, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.0201550405472517, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.17519380152225494, "rps_doc_frac_unique_words": 0.5452830195426941, "rps_doc_mean_word_length": 5.722641468048096, "rps_doc_num_sentences": 47, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.2539286613464355, "rps_doc_word_count": 530, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.036927130073308945, "rps_doc_frac_chars_top_3gram": 0.01384767983108759, "rps_doc_frac_chars_top_4gram": 0.019122980535030365, "rps_doc_books_importance": -270.8104248046875, "rps_doc_books_importance_length_correction": -270.8104248046875, "rps_doc_openwebtext_importance": -191.8121795654297, "rps_doc_openwebtext_importance_length_correction": -191.8121795654297, "rps_doc_wikipedia_importance": -129.20103454589844, "rps_doc_wikipedia_importance_length_correction": -129.20103454589844 }, "fasttext": { "dclm": 0.8398123383522034, "english": 0.8522347211837769, "fineweb_edu_approx": 1.5294342041015625, "eai_general_math": 0.011853580363094807, "eai_open_web_math": 0.1320338249206543, "eai_web_code": 0.12337368726730347 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.678", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
2,200,900,621,009,459,500
math help What is 9/11 - 3/7? What is 9/11 - 3/7? Here's how to subtract 3/7 from 9/11: 9 11 3 7 Step 1 We can't subtract two fractions with different denominators. So you need to get a common denominator. To do this, you'll multiply the denominators times each other... but the numerators have to change, too. They get multiplied by the other term's denominator. So we multiply 9 by 7, and get 63. Then we multiply 3 by 11, and get 33. Next we give both terms new denominators -- 11 × 7 = 77. So now our fractions look like this: 63 77 33 77 Step 2 Since our denominators match, we can subtract the numerators. 63 − 33 = 30 So the answer is: 30 77 Step 3 Last of all, we need to simplify the fraction, if possible. Can it be reduced to a simpler fraction? To find out, we try dividing it by 2... Nope! So now we try the next greatest prime number, 3... Nope! So now we try the next greatest prime number, 5... Nope! So now we try the next greatest prime number, 7... Nope! So now we try the next greatest prime number, 11... Nope! So now we try the next greatest prime number, 13... Nope! So now we try the next greatest prime number, 17... Nope! So now we try the next greatest prime number, 19... Nope! So now we try the next greatest prime number, 23... Nope! So now we try the next greatest prime number, 29... Nope! So now we try the next greatest prime number, 31... No good. 31 is larger than 30. So we're done reducing. There you have it! The final answer is: 9 11 3 7 = 30 77
{ "url": "https://mathhelper.us/9over11/minus/3over7", "source_domain": "mathhelper.us", "snapshot_id": "crawl=CC-MAIN-2021-49", "warc_metadata": { "Content-Length": "15909", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:PC2JBFKCNSWSEBPOJ7LJX4FDLQEAQJ34", "WARC-Concurrent-To": "<urn:uuid:cc16d1f1-0431-40d9-90a2-dd0485a42805>", "WARC-Date": "2021-12-07T16:04:18Z", "WARC-IP-Address": "162.243.195.140", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:GX6BWFB7N7ITXDGLPIEEVN52TGYXIMNR", "WARC-Record-ID": "<urn:uuid:4ccdb6d1-187a-4b53-bc78-c60a414f820e>", "WARC-Target-URI": "https://mathhelper.us/9over11/minus/3over7", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:25a95824-f6fd-48ee-bf02-26585d71763f>" }, "warc_info": "isPartOf: CC-MAIN-2021-49\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November/December 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-12\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 10, 11, 31, 32, 52, 53, 91, 92, 94, 97, 99, 101, 102, 109, 110, 370, 371, 406, 407, 445, 446, 503, 504, 541, 542, 545, 548, 551, 554, 555, 562, 563, 625, 626, 639, 640, 658, 659, 662, 665, 666, 673, 674, 775, 776, 816, 817, 874, 875, 932, 933, 990, 991, 1049, 1050, 1108, 1109, 1167, 1168, 1226, 1227, 1285, 1286, 1344, 1345, 1403, 1404, 1459, 1460, 1500, 1502, 1505, 1507, 1509, 1511, 1514 ], "line_end_idx": [ 10, 11, 31, 32, 52, 53, 91, 92, 94, 97, 99, 101, 102, 109, 110, 370, 371, 406, 407, 445, 446, 503, 504, 541, 542, 545, 548, 551, 554, 555, 562, 563, 625, 626, 639, 640, 658, 659, 662, 665, 666, 673, 674, 775, 776, 816, 817, 874, 875, 932, 933, 990, 991, 1049, 1050, 1108, 1109, 1167, 1168, 1226, 1227, 1285, 1286, 1344, 1345, 1403, 1404, 1459, 1460, 1500, 1502, 1505, 1507, 1509, 1511, 1514, 1516 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1516, "ccnet_original_nlines": 76, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.34656083583831787, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0, "rps_doc_frac_lines_end_with_ellipsis": 0.1428571343421936, "rps_doc_frac_no_alph_words": 0.3571428656578064, "rps_doc_frac_unique_words": 0.35862070322036743, "rps_doc_mean_word_length": 3.7517242431640625, "rps_doc_num_sentences": 39, "rps_doc_symbol_to_word_ratio": 0.0317460298538208, "rps_doc_unigram_entropy": 4.156647205352783, "rps_doc_word_count": 290, "rps_doc_frac_chars_dupe_10grams": 0.36764705181121826, "rps_doc_frac_chars_dupe_5grams": 0.36764705181121826, "rps_doc_frac_chars_dupe_6grams": 0.36764705181121826, "rps_doc_frac_chars_dupe_7grams": 0.36764705181121826, "rps_doc_frac_chars_dupe_8grams": 0.36764705181121826, "rps_doc_frac_chars_dupe_9grams": 0.36764705181121826, "rps_doc_frac_chars_top_2gram": 0.05055147036910057, "rps_doc_frac_chars_top_3gram": 0.08272059261798859, "rps_doc_frac_chars_top_4gram": 0.10110294073820114, "rps_doc_books_importance": -200.83375549316406, "rps_doc_books_importance_length_correction": -190.70753479003906, "rps_doc_openwebtext_importance": -98.93949127197266, "rps_doc_openwebtext_importance_length_correction": -98.93949127197266, "rps_doc_wikipedia_importance": -94.79664611816406, "rps_doc_wikipedia_importance_length_correction": -82.2093276977539 }, "fasttext": { "dclm": 0.9850140810012817, "english": 0.852317214012146, "fineweb_edu_approx": 2.3780832290649414, "eai_general_math": 0.9984467625617981, "eai_open_web_math": 0.9360501170158386, "eai_web_code": 0.5434871912002563 } }
{ "free_decimal_correspondence": { "primary": { "code": "513.24", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Geometry" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "-1", "label": "Abstain" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-1,562,601,041,623,595,800
Компилятор masm Содержание Дневники чайника. Чтива 0, виток0 Знакомство с MASM32 и Win32-программированием Мне приходит довольно много писем с просьбами рассказать о MASM’е больше. И я решил слегка переделать эту главу. Кроме того, я уже написал справочные статьи для тех, кто не застал времена MS-DOS. Если интересно, загляните в следующий виток Как получаются программы? До сих пор мы писали все примеры в Hiew’e, но этот способ крайне извращенный. Я использовал его только для того, чтобы вы увидели настоящий Асм. Вначале очень трудно отличить высокоуровневые наслоения от самого языка Ассемблер, и некоторое время я сам путал команды процессора и директивы. Но теперь, когда вы видели язык во всей его наготе, можно слегка приодеть его. Нормальные программы пишут в обычном текстовом виде, а не как мы раньше (каждую строку сразу транслировали в машинную команду). Такой текстовый вид называется исходным, а файлы — исходниками, или сырцами (от английского source). Текст исходника можно писать где угодно, хоть в Ворде (при установленном фильтре простого текста). На вкус, на цвет. Я пишу в RadAsm’e. Это целая среда для разработки приложений, очень удобно. Однако на первых порах рекомендую писать просто в редакторе Far’а, можно подключить к нему специальный плагин Colorer. Этот плаг подсвечивает синтаксис многих языков программирования. Но всё это не обязательно. Тут каждый сам себе берлогу выстилает. Когда исходный текст набран и сохранён, его можно компилировать. За процесс получения готовой программы отвечает компилятор, и состоит этот процесс из двух основных этапов. 1. Исходный текст преобразуется в промежуточный файл. Это делает транслятор (в случае с MASM’ом он называется ml.exe). 2. Затем создаётся готовый исполняемый модуль в определённом формате. То есть программа. Это делает линковщик (в случае с MASM’ом он называется link.exe). Значит, для того чтобы делать программы, нужно иметь текстовый редактор и компилятор, который состоит из двух основных частей — транслятор и линковщик. Всё остальное не обязательно, однако реальные программы Win32 используют внешние функции, стандартные константы и переменные, ресурсы и много другое. Всё это требует дополнительных файлов, которые мы и видим в. MASM32 SDK Это очень распространённый пакет, собранный Стивеном Хатчисоном (Hutch). Важно понять, что MASM32 вовсе не компилятор, а сборник для программирования под Win32, в который входит 32-битный компилятор MASM. Сегодня (С наступающим, 2012-м, годом!) я использую пакет MASM32 версии 10. Описывать всё, что входит в пакет MASM32 SDK, — не вижу смысла. Лучше сосредоточиться на самом компиляторе. Матрос, мы сегодня выходим из гравитационного пояса Солнечной системы. Перед гиперскачком нужно проверить и настроить всё оборудование. Из чего состоит компилятор MASM? Основных файлов всего два: ml.exe — транслятор. Он преобразует исходный текст в obj-файл (объектного формата COFF или OMF), link.exe — линковщик. Создаёт готовый исполняемый exe или dll модуль (в формате для DOS, Windows. ). Эти файлы включены в основной состав MS Visual Studio (и в .NET). При желании можно скачать в открытом доступе самые новые версии вместе с Visual Studio Express (или в обновлениях) на сайте MS. Правда, я не вижу в этом особого смысла (в следующем витке описана причина). Установка и настройка MASM32 Ну, для начала хорошо бы его иметь. Можно скачать с wasm.ru или с сайта автора. 1. Перед установкой отключите чрезмерно бдительные антивирусы (Каспер в первую очередь). 2. Устанавливать пакет советую на тот диск, где будут ваши исходники. Теперь полезно прописать в системе путь к файлам компилятора. В Win7 это можно сделать так: В меню «пуск» правый клик на «Компьютер» > Свойства > Дополнительные параметры системы > закладка «Дополнительно» > Переменные среды. Здесь в списке системных переменных нужно изменить значение переменной «PATH». Дописать в конце строки: (не пропустите точку с запятой и вместо «D» укажите букву диска на котором установлен MASM32). Поскольку редактор исходных файлов Quick Editor я не использую (уж больно он убогий), на этом можно считать подготовку MASM32 к работе завершенной. Было бы неплохо знать, как вообще проходит процесс написания программы. Здесь я могу рассуждать только теоретически, так как сам не написал еще ни одной серьёзной программы. :))) Однако кое-что об этом знаю и с радостью поделюсь своими представлениями. Реальный процесс разработки программы Знающие люди говорят, что это творческий процесс. Из чего можно сделать вывод, что дело это крайне личное. Но общие правила здесь тоже имеются. 1. Постановка задачи 2. Создание алгоритма (в той или иной степени) 3. Кодирование на конкретном языке 4. Попытка компиляции. Если счетчик ошибок не ноль, прыг на шаг 3 или даже 2 5. Удивление, что оно хоть как-то заработало 6. Если счетчик найденных ошибок не ноль, то прыг на шаг 1 7. Я пока так оставлю, а потом ещё доделаю 8. Если обстоятельства (обычно лень) не позволяют продолжить — проект умирает. Или на шаг 1 Примерно так я делал небольшую программку для личного пользования. Научить вас ставить задачи я даже пытаться не буду, сам не умею. Создавать алгоритмы вас научит Кнут, это его стихия, а я могу только восхищаться. Дональд Эрвин Кнут — Великий Автор, его трёхтомник можно взять на сайте int3.net (после регистрации). Мне кажется, человек, который не читал Кнута, программистом себя называть не имеет права (сам я, кстати, тоже не читал :). А если серьёзно, то абсолютное большинство существующих учебников и литературы о программировании не может выжить и семи лет, потому что такие книги ориентированы на изучение возможностей того или иного языка (как мои статьи). Кнут же на протяжении полувека(!) учит создавать реальные программы, а не оболочки для простого ввода/вывода. Думаю, вы поняли, что его книгу хорошо бы купить. Цена, правда, хорошая, но трёхтомник того стоит. Итак, вернёмся к бренной жизни. Кодирование на конкретном языке — вот о чем мы тут толкуем. Правда не надо забывать, что программа ещё должна работать под конкретной системой. Win32 Многие считают, что мир форточек устроен по законам Майкрософт, но это лишь очень поверхностный взгляд. Как бы ни старались специалисты этой конторы, они тоже вынуждены подчиняться правилам Intel. Так что главное отличие DOS-среды от Windows — это то, что последняя опирается на защищённый режим процессора (Protected Mode — PM). Кардинальное отличие PM от Real Mode — новый (довольно хитрый) механизм работы с памятью, и он сильно изменил жизнь программистов. Win32 использует страничную адресацию памяти, которая является надстройкой над сегментной адресацией защищённого режима. Несмотря на то, что работа с памятью в PM устроена сложно и запутанно, внешне всё выглядит элементарно. По крайней мере в Windows адресацию сделали довольно удобной. В данном случае советую всем начать именно с внешнего осмотра. Ну если, конечно, вы самые смелые, самые умные и уже готовы разбирать всё по винтикам изнутри, тогда берите учебник по i80386 процессору и читайте про селекторы, таблицы дискрипторов, разбирайтесь, как в PM при страничной адресации формируется физический адрес из линейного. Лучше, конечно, начать с рассылки Broken Sword’a. Но что-то мне подсказывает, что вам пока рано браться даже за популярное изложение особенностей PM :). Сам я уже год как пытаюсь подступиться к этой теме, просветление уже где-то рядом. :) Внешний осмотр Win32. Что же мы имеем после загрузки форточек: • Каждая программа загружается в собственное изолированное виртуальное адресное пространство (Виртуальное Пространство Процесса). • Адреса в таком ВПП могут быть от 00000000 до FFFFFFFF (4Gb), будем называть их виртуальными. • При загрузке и далее при выполнении в эту виртуальность проецируется всё необходимое для работы программы (код и данные операционной системы, динамические части самой программы, файлы и т.п.). • Программа, кроме собственных вычислений, практически ничего самостоятельно сделать не может. Ей приходится просить ОС вывести что-либо или предоставить в её ВПП. Для этого она вызывает нужные API-функции. • Файлы с машинным кодом и данными у Win32-программ устроены в соответствии с PE-форматом, который довольно сильно связан с особенностями защищённого режима процессора. Исполняемые файлы PE-формата делятся на секции. Должна быть минимум одна секция (секция кода), но файл может иметь и другие секции для разных целей (данные, ресурсы, служебные секции и т.д.). А ещё нужно знать, что в защищённом режиме существуют 4 уровня привилегий. Нулевой самый сильный, 3-й самый слабый. Эти уровни называют кольцами (ring0,1,2,3). Win32 использует только ring0 для ядра и драйверов и ring3 для прикладных программ. Таких поверхностных данных вполне достаточно, чтобы мы могли дальше разумно изучать программирование на Ассемблере, и приступить к программированию WinAPI. По крайней мере сам я о защищённом режиме и о том, как его используют форточки знаю немногим больше :(. Так что будем учиться вместе. Первый пример Windows-программы Давайте рассмотрим, как может выглядеть маленькая программа для Win32, написанная под MASM. Языка Ассемблер здесь нет! Этот текст будет преобразован в запускаемый файл формата PE (Portable Executable — портируемый exe-формат). То есть стандартную программу для форточек. Попробуйте набрать в файл «prax05.asm» все эти строки, большая часть которых, кстати сказать, — директивы MASM’a. . Хотя это как раз можно и не набирать, ещё успеете натыкаться :), возьмите мой файл. Компилировать программу новичку проще всего так (читатели меня всё-таки убедили =): 1. Открыть редактор исходных файлов «Quick Editor» (икона «MASM32 Editor» на рабочем столе). 2. Открыть или набрать в нём пример. 3. После всех изменений обязательно нужно сохранить пример и обязательно на тот диск где установлен MASM32. 4. Для самой компиляции нужно выполнить пункт меню Project > Build All. 5. Должно появиться консольное окошко с отчётом компилятора (если консоли нет, значит, по какой-то причине компиляции не было). Запустить пример можно из того же Quick Editor’a кнопкой «Run File» или пунктом меню Project > Run Program. Если вы планируете работать с компилятором на разных дисках, то самый грубый, но быстрый и универсальный, способ решить проблему компиляции – тупо скопировать папку MASM32 в корень всех дисков, где будет проходить компиляция программ. Хочу предостеречь юные умы от выражений типа «иконка открывает MASM». В корне неправильные слова влекут неправильные выводы и действия. Ещё раз обращаю ваше внимание: MASM – это компилятор, он состоит из двух частей (ml.exe и link.exe). Обе части не имеют другого способа общения с пользователем кроме как через командную строку. А иконка на рабочем столе открывает программу-посредник под названием «Quick Editor», которая для компиляции всего лишь запускает файл build.bat. И тут мы переходим к следующему уровню пользования компилятором. Другой способ компиляции программ — использовать файл build.bat без посредника (описание в следующем витке). В командной строке ОСи (В Far’e внизу или в «Пуск > Все программы > Стандартные > Командная строка») набираем следующее: ! Разумеется, текущей папкой должна быть папка с исходником. ! Имя файла в командной строке пишите без расширения. ! Расширение у файла должно быть asm. ! файл должен быть на диске с пакетом MASM32 в корне. После нажатия Enter вызовется бат-файл. Его задача превратить текстовый файл (исходник) в готовую программу (бинарник). Для этого он выполняет ml.exe с параметрами Если в исходнике нет явных ошибок, появится файл prax05.obj. И далее выполнится link.exe, который и создаст готовую Win-программу. На выходе мы имеем два файла. Один — объектный, он нам не пригодится, это для нас промежуточный файл. Второй — exe, сами знаете, что с ним делать. Ошибки будут — это я гарантирую. Опечатки обычно быстро находятся, так как компилятор сообщает тип ошибки и строку, которая её вызывает. Однако это далеко не всегда означает, что ошибка именно в этой строке. Тут нужно головой думать. Подозреваю, что она у вас работает хорошо, раз мы с вами добрались до Windows. Но если у вас недостаточно знаний пользователя и из-за этого не собирается даже пример prax05.asm, — не расстраивайтесь. Прочитайте главу следующего витка. Должно помочь и уж, по крайней мере, поднимет ваш «уровень юзера». Да, да, у вас всё получится. Поздравляю, матрос! Мы в гиперпространстве. Полноценная программа для Windows. Её уже не исследуешь в CodeView. Для отладки форточных программ мы запаслись OllyDbg. Хорошо бы настроить и его (цвета, шрифты, размер и пути в ini-файле). Это у вас займёт некоторое время, ко всему надо привыкнуть. Я всё-таки надеюсь, вас не испугает такая небольшая программка весом в 2Mb, ведь вы наверняка настраивали и более навороченные приложения. Кроме того, недавно хорошие ребята, потрудившись наславу, сделали русский help, который можно взять тут. Спасибо: deNULL, HyPeR, name, Wenden. И ещё есть вводная статья Bit-hack’a http://cracklab.ru/art/ollydbg.php, за что ему тоже огромное спасибо. Exe-файл формата PE содержит кучу всякой ерунды, которая, впрочем, необходима для запуска Win32-программы. Сложного там ничего нет, позже вы скорее всего познакомитесь с устройством PE-формата, а сейчас нужно понять лишь одно. На начало исполняемого кода программы в памяти указывает Entry Point (EP — точки входа). В разных программах она может указывать на разные адреса. Но в простых примерах, собранных build.bat’ом, адрес первой команды будет 401000h. Значение EntryPoint в таком случае будет = 1000h, плюс Image base 400000h = 401000h. Про PE-формат мы, наверное, ещё поговорим, и даже очень плотно, ну а сейчас. Откройте prax05.exe в OllyDbg. Для этого достаточно загрузить Olly и открыть программу как обычный документ в форточках. После работы Win-загрузчика Олли покажет вам первую инструкцию в окне кода (ориентируясь именно на EP). Исследовать этот пример вам пока не надо, через регистры здесь слишком трудно разобраться. • В верхней левой части — вся программа, которая выводит на экран сообщение типа Message Box. Вы видите, нет ни одной строчки из исходного файла prax05.asm, потому что это уже Ассемблер! • Вверху справа — регистры процессора (заметьте, EBX стоит четвёртым, рядом с регистрами-указателями, и флаги выглядят по-другому). Как я уже сказал, регистры селекторов (сегментные регистры ES-GS) нас не волнуют, даже не обращайте на них внимание. • Внизу слева — байты памяти (Olly сразу же показывает секцию данных программы). • Внизу справа отображается содержимое стека (о нём следующая глава). Нужно заметить, несмотря на то, что Ollydbg выглядит как обычная программа, это всё-таки отладчик и у него есть свои ограничения. Рекомендую, например, закрывать его каждый раз, как вам понадобится загрузить новую программу. Мы узнаем, как работает этот пример, но прежде остановимся на исходнике. Весь код из исходника, кроме двух строк, будет во всех программах Win32 под MASM’ом, поэтому вы должны знать, что он означает. Но не воспринимайте это слишком серьёзно. Там будет много длинно-умных слов. За такими словами очень часто прячется дребедень. Хочу, чтобы вы поняли одну простую вещь. Совсем скоро вы будете знать команды Асма, и если вы поймёте основы программирования, а затем познаете интерес математики :), то каждый из вас сможет написать собственный компилятор для программ Ассемблера, возможно, не хуже MASM’a или FASM’a. Вы сможете сами придумывать всякие директивы, псевдокоманды, макросы, плагины и новые удобные фишки. Но команды процессора — совсем другое дело. Кроме того, что они в процессоре и изменить их нельзя (уточнение), большинство из команд имеет под собой математическое основание, заложенное в структуру цифровых технологий. Поэтому приоритет нужно отдавать в пользу команд процессора. А директивы MASM’a и все страшные слова за ними воспринимайте поверхностно. Я бы вообще не объяснял их (как Калашников в первых уроках), если б не знал, как сильно отвлекает внимание новичка непонятная строка в исходнике. Теперь можно приступать к разбору этих самых директив. Писать каждый раз такой код заново не надо. Это каркас программы для форточек. Мало того, к этому каркасу будут добавляться такие же постоянно повторяющиеся вещи. Создали один раз файл-заготовку — и далее можно вписывать туда только полезный код. Я уже не раз говорил, что после точки с запятой идёт комментарий. Значит, MASM такую информацию не воспринимает. Можно писать всё что хочется. Это директива, указывающая компилятору, что в программе будут использоваться команды процессора i80x386. В exe эта информация записывается в самом начале после заголовка PE. Если интересно, найдите в exe-файле буквы PE. Потом идут два нулевых байта, так как заголовок PE — это dword (4 байта). В следующем слове (двух байтах) как раз и будет информация о командах процессора, которые используются программой. Всё, от 386-го до сегодняшних 32-битных Intel-совместимых процессоров, обозначается кодом 014Сh. Для нас такая информация бесполезна, а вот директива «.386» обязывает нас не использовать новые команды, иначе программа не соберётся, пока мы не исправим эту директиву на «.486» или «.586» :). Директива «.model» задаёт модель памяти flat для нашей программы. Модель flat лучше переводить: сплошная модель, а не плоская, как многие пишут. Stdcall — это «уговор» о том, кто будет чистить параметры (функция, которую вызвали, или сам вызывающий). Мы всегда будем использовать вариант «функция чистит свои параметры». Он и называется stdcall. Однако такое объяснение далеко не полное, и я вернусь к параметру stdcall при объяснении вызова функций. К этому моменту вы уже будете знать, что такое стек. От директивы .model явным образом зависит скомпилированный код в объектном файле и также зависит формат получившегося исполняемого файла. Это просто. Всё уже объяснено в комментарии. В этой строке включается чувствительность к ПРОПИСНЫМ или строчным символам. То есть «МЕТКА» и «метка», «Имя» и «имя» будут уже не одно и то же! На exe это никак не отражается. Include — директива для подключения файлов (их расширение не обязательно должно быть inc). В подключаемых файлах может быть всё то же самое, что и в основном файле. То есть исходный код программы, данные, макросы (тоже код), комментарии и т.д. Причём вы можете вставлять инклуды, например, в середине кода, а продолжать программу уже в том файле. В этих трёх inc-файлах в текстовом виде содержатся описания констант, структур и прототипов функций Windows. Далее я всё объясню, и вы поймёте, что это очень просто — как словарь или каталог товаров. Вы можете перенести нужные описания в наш файл, и подключать inc’и не придётся, только это неудобно. Includelib — директива для подключения файлов импорта. Я сам только что в первый раз задумался: а что в lib-файлах? Думаю, что вам сегодня объяснять это не нужно. Просто там информация о системных библиотеках, на основе которой будет сформирован вызов API-функций в нашей программе. В exe-файл в данном случае из inc’ов не попадёт ни строчки кода, но компилятору они нужны для преобразования двух полезных строк (invoke) в машинный код. А из lib-файлов будут взяты две строки кода и данные, которые в exe запишутся в директорию импорта (всё тот же PE-формат). Вот это очень интересная строка. Тоже директива. Чтобы разделить код и разного рода данные, в exe-файлах существуют секции. У каждой секции свои атрибуты и они тоже напрямую связаны с защищённым режимом. Это позволяет стабилизировать работу программ и упорядочить процесс написания. Считается, что машинный код менять не нужно, значит, для него подойдёт атрибут read only (только чтение). А данные (как теперь считается) выполнять не нужно, значит, можно в секции данных выключить атрибут исполняемого кода. Слава Богу, что всё это только теоретически (пока). Любая секция может содержать и код, и данные, и соответствующие атрибуты. Так что сейчас можно воспринимать секции только как полезную для программистов вещь. Итак, секция данных объявляется директивой «.data», и это выставляет в ней нужные для данных атрибуты. Так же, как мы вписывали строки текста в конце файла (после кода программы), эта секция по умолчанию будет размещаться в exe-файле после кода. Здесь от MASM’a только db. Перед ним идут названия переменных. После db идёт содержание переменной, то есть текстовые или цифровые данные. Если данные текстовые, то они помещаются в кавычках или апострофах. А если данные просто байты, то так и пишут через запятую. Добавьте в этой секции вот такую строку: Теперь соберите файл ещё раз (старые obj и exe будут стёрты build.bat’om). Несмотря на то, что переменная LaLa в коде не использовалась, в готовой программе будут эти байты: Найдите их, загрузив пример в отладчик OllyDbg. Я уже говорил, что обычно мы будем заканчивать строку текста нулевым байтом. Теперь вы видите, как это пишется в синтаксисе MASM’а. В файле будет одно и то же: байты символов и 00. А Str1, Str2 — это имена переменных, они могут быть любые, лишь бы не нарушали правил, описанных в help-файлах MASM’a. Осталось объяснить, что такое db — одна из ряда однотипных директив инициализации данных и их резервирования. Длинные слова, мало что значат. DB — сокращение от Data in Bytes (данные в байтах). Есть ещё DW (Data in Words), и DD (Data in Dwords), и ещё несколько аналогичных, побольше. Суть только в том, что запятая в DB разделяет байт, а в DD запятая разделяет 4 байта. Пример. В исходнике так: В исходнике так: вызовет ошибку при сборке файла — размер в последней запятой не тот. Вот и все основные премудрости представления целочисленных данных без знака (то есть положительных целых чисел) в MASM’e. Хотя нет, забыл сказать, что можно ещё объявлять резерв. Данные, которые на момент старта программы ещё не появились. Для чего это делается? Допустим, в программе много промежуточных данных. Вписывая их в секцию неинициализированных данных (.data?), мы экономим в размере файла. Пока программа не стартовала, никаких данных в этой секции нет, а вот во время загрузки OS выделяет память сразу под все данные. На первых порах можно спокойно писать все данные в секцию .data. Файл от этого больше не станет, а наоборот, будет только меньше. В PE-формате есть много всяких тонкостей, одна из них — это выравнивание секций. В большинстве программ в конце каждой секции есть нули, посмотрите в Hiew’e, и вы увидите, сколько места пропадает. Если я ничего не путаю, то секция должна быть кратна 512 байтам (200h). Значит, если у вас нет данных на эту сумму, то лучше не заводить новую секцию «.data?» а писать всё в «.data». Здесь закончилась секция данных. . и началась секция кода. Это единственная секция, без которой программу не собрать. Но я ещё раз повторяю: «.code» вовсе не означает, что данных сюда класть нельзя. Правда, если данные изменяются и они в секции кода — это вызовет проблему (не те атрибуты секции). Хотя руками можно всё :). Вот мы и добрались до нашей первой метки. Метки в exe-файл не идут. Первая метка начинает код программы. Можно написать хоть «tuki_puki:», лишь бы в конце кода было «end tuki_puki». Что и сообщит MASM’у, где кончилась программа, а самое главное — где она началась. Далее мы всё время будем использовать метки. Они начинают строки, к которым нам нужно прыгать. При сборке программы компилятор подставляет адреса команд в памяти вместо обращений к меткам. Это гораздо удобнее, чем писать: Такая команда будет ошибочна, так как, я уже сказал, EP будет указывать на разные адреса в разных программах. Пока что адрес в памяти для первой инструкции будет 401000, а если код программы усложнится, то адрес может стать другим. Если вы запишете: то больше об адресах беспокоиться не надо. В exe окажется правильная маш.команда, а на Асме она будет выглядеть «JMP 00401000» или куда укажет метка. В этих двух строчках и скрывается сама программа. Первая строка вызывает API-функцию MessageBox и передаёт ей необходимые параметры. Вторая строка выполняет действие, похожее на int 20 в DOS. Это завершающий код с параметром NULL. На самом деле в коде будет не NULL, а нулевой байт (00h). Это значит, что и здесь можно писать: Подробный разбор содержания этих двух строк будет уже в следующей Чтиве. Она была написана год назад, я тогда в первый раз увидел в WinXP код программы на Асме, поэтому дотошно описывал всё новое (но с таким количеством ошибок! :/). Найдя оператор END в этом случае, компилятор MASM’a сочтёт, что метка «start» будет точкой входа в программу. Потому что больше заканчивать в этом файле нечего. Именно со строки END первая метка начнётся трансляция полезного кода в файл :). В любой программе под форточки используется стек, и в следующей главе я расскажу о нём. Вернуться на главную — Фирма Интел после всем известной ошибки Пентимума разработала специальную утилиту для «конечных» пользователей, благодаря которой можно изменять код микропрограммного блока управления в процессорах «выше» Пентиума. То есть у нас с вами теоретически есть возможность менять свойства инструкций процессора. Некоторую информацию вы можете получить в популярной статье iXbt, а также здесь. Язык Ассемблера. Компилятор FASM. Язык ассемблера — машинно-ориентированный язык низкого уровня с командами, обычно соответствующими командам машины, предназначен для системного программирования. Примеры его использования: драйвер, ядро операционной систем, а также написание критических участков кода (где важна максимальная скорость выполнения). На этом языке пишут вирусы и эксплойты (специальные программы, созданные для эксплуатации уязвимостей в ПО). Преимущества знания ассемблера: · Глубокое понимание работы компьютера и операционной системы. · Максимальная гибкость при работе с аппаратными ресурсами. · Оптимизация программ по скорости выполнения. · Оптимизация программ по размеру кода. · Дизассемблирование и отладка. 1 — Глубокое понимание работы компьютера и операционной системы Илон Маск рекомендует:  Что такое код printer_create_brush Даже если пишется программа на языке высокого уровня, знание ассемблера поможет понять, как будет выполняться программа, как хранятся переменные, как вызываются функции. А это позволит избежать многих ошибок. Большинство специалистов знают программирование только на уровне языка, т.е. знают что надо написать, чтобы получить какой-то результат, а как он был получен не имеют представления. Человек, владеющий ассемблером, будет лучше программировать и на других языках. 2 — Максимальная гибкость при работе с аппаратными ресурсами Используя ассемблер, можно делать с компьютером все что угодно. А языки высокого уровня ограничены компилятором и используемыми библиотеками. Такие современные языки, как Java и C# вообще не позволяют работать с аппаратными ресурсами и операционной системой напрямую. 3 — Оптимизация программ по скорости выполнения. Современные компиляторы достаточно хорошо оптимизируют код, поэтому писать на ассемблере все подряд не имеет смысла. Однако, если пишется программа для шифрования или архивации больших файлов, то применение ассемблера позволит в несколько раз увеличить скорость выполнения программы. Причем достаточно реализовать на ассемблере небольшой критически важный участок программы, который производит вычисления или сложные преобразования, а интерфейс может быть написан на языке высокого уровня. 4 — Оптимизация программ по размеру кода Программа на ассемблере, как правило, значительно меньше аналогичной программы на другом языке программирования. Для современных персональных компьютеров и серверов с терабайтными дисками и гигабайтами памяти это вряд ли играет большую роль. Но для микроконтроллеров, где всего несколько килобайт памяти, маленький размер программы очень важен. Чем меньше программа, тем меньше памяти требуется, и тем проще и дешевле будет используемая микросхема. 5 — Дизассемблирование и отладка Дизассемблирование — процесс и/или способ получения исходного текста программы на ассемблере из программы в машинных кодах. Целью дизассемблирования обычно является изменение чужих программ (чаще всего это взлом защиты). Если вы попытаетесь просмотреть в текстовом редакторе файлы с расширением .ехе , то увидите непонятную смесь символов. Это инструкции для процессора. Компьютер читает и исполняет их. Но иногда человек тоже хочет понять, что записано в этих файлах. Тогда он выполняет дизассемблирование. Дизассемблирование превращает исполняемый файл в текст программы на ассемблере. Если вы знаете ассемблер, у вас появляется часть прочесть текст программы и внести в него изменения. Ассемблер очень может помочь и при отладке. Иногда случаются ошибки и в компиляторах. Вроде бы корректно написанный код выполняется вовсе не так, как предполагалось. Чтобы обнаружить такую ошибку надо посмотреть во что скомпилировался код, а разобраться в этом без ассемблера невозможно. Учиться программировать начнем с процессора Intel 8086. Будем писать программы под DOS. Практическая ценность от программирования под DOS в наше время не очень большая, если вы, конечно, не собираетесь тесно работать с этой операционной системой. Но она позволит быстро освоить основы ассемблера, а потом мы уже перейдем к программированию под 32-битные системы. Для программирования на ассемблере прежде всего необходим компилятор. Наиболее известные компиляторы это TASM, MASM и FASM. Мы будем использовать FASM. Это довольно новый, удобный, быстро развивающийся компилятор ассемблера, написанный на себе самом. Его преимущества — это поддержка сложных макросов и мультиплатформенность. Есть версии под DOS, Windows и Linux. С его помощью можно сгенерировать файл любого формата, не обязательно исполняемый файл, так что FASM — это превосходный инструмент для экспериментов и исследований. Последнюю версию FASM’a можно скачать с официального сайта http://www.flatassembler.net/. Для установки содержимое архива надо распаковать в какую-нибудь папку. Например, папка C:\FASM. Для отладки написанных программ будем использовать старый добрый Turbo Debugger из пакета TASM. Архив также надо распаковать в какую-нибудь папку. Например, папка C:\TD. Особенности разработки программ в MASM Для успешной работы с ассемблером MASM корпорации Microsoft в современных операционных средах (WindowsNT\2000\XP) необходимо иметь версию 6.13 этого пакета или выше. В него входят следующие основные программы: — ml.exe— ассемблер и компоновщик (Masm and Link); — cv.exe— отладчик (CodeView); — lib.exe, implib.exe, nmake.exe, cref.exe, h2inc.exe, exehdr.exe, cvpack.exe, helpmake.exe, rm.exe, undeL.exe, exp.exe— вспомогательные утилиты. В пакете MASM изначально предпринимались попытки совместить удобство средств программирования, свойственных языкам высокого уровня, с традицион­ными средствами машинно-ориентированных языков. Например, буква «М» в на­звании пакета означает слово «macro», то есть возможность создания макроопре­делений (или макросов), представляющих собой именованные группы команд. Их можно вставлять в программу в любом месте, указав только имя группы. Когда-то такая возможность действительно была отличительным свойством этого пакета, но сейчас этим никого не удивишь — макросредства есть во всех ассемблерах для платформы Intel (например, TASM), но, тем не менее, название осталось. С помощью пакета MASM разработка программ выполняется традиционным для ассемблерного программирования способом — запуском отдельных программ трансляции, компоновки и отладки. Для этого используются программы masm.exe, mL.exe, link.exe и cv.exe. Во избежание путаницы необходимо отметить, что транс­ляция исходного файла может производиться двумя программами: masm.exe и mL.exe. В чем разница? До выхода MASM версии 5.1 включительно программа masm.exe была самостоятельным транслятором ассемблера. Начиная с MASM вер­сии 6.0 трансляция ассемблерного файла обычно выполняется программой mL.exe, которая кроме трансляции файла вызывает компоновщик link.exe. Это изменение сделано с целью унификации вызовов компиляторов командной строки для всех поддерживаемых этой фирмой языков программирования. К примеру, компиля­цию программы на языке С из командной строки выполняет программа cl.exe. Ее задачи — компиляция исходной программы на языках C/C++ и, при отсутствии синтаксических ошибок, компоновка и формирование исполняемого модуля. Ана­логичные задачи решает и программаmL.exe. Хотя в пакете MASM 6.13 допустимо использование программы masm.exe, нужно иметь в виду, что запуск link.exe в этом случае также должен выполняться отдельно. Наличие программы masm.exe в пакете MASM6.13 можно объяснить соображениями совместимости с предыдущими версиями пакета, поэтому особого смысла в ее использовании нет. Далее приведены форматы командных строк для запуска программ ml.exe, Masm.exe и link.exe, а описание их ключей можно найти в приложении В(http:// www.piter.com/download). Командная строка mL.exe имеет вид ml [ключи] исх_файл_1 [[ключи] исх_файл_2] . [/link ключи_linк] Ключи командной строки для ml.exe чувствительны к регистру. Командная строка masm.exe имеет вид masm [ключи] исх_файл [, [объектный_файл] [, [файл_листинга] Компоновщик компонует (объединяет) объектные файлы и библиотеки в ис­полняемый файл или динамически компонуемую библиотеку (DLL). Командная строка link.exe имеет вид link[ключи] объект_файлы [,[исполн_файл] [,[файл_карты] [,[файлы_библиотек] [.,def-файл]]][;] Так же как и в случае пакета TASM, для эффективной работы с MASM нужно провести некоторую дополнительную работу. Исполняемые файлы пакета MASM 6.13 находятся в двух каталогах: ..\BIN и ..\BINR. Для удобства работы их лучше объединить в одном каталоге, к примеру, в каталоге ..\WORK. После этого остается поместить туда исходный файл. Пример командной строки для получе­ния пригодного к отладке исполняемого модуля может быть следующим: ML.EXE /Zi /Fl Prg_6_l.asm Если нет синтаксических ошибок, то можно запускать отладчик: CV.EXE PRG_6_1.EXE Итоги Структура программы на ассемблере отражает особенности архитектуры про­цессора. Для процессоров Intel типичная программа состоит из трех сегментов: кода, стека и данных. Но это не обязательное условие; например, если програм­ма не использует стек и для ее работы не требуется определения данных, то она может состоять всего лишь на одного сегмента кода. — Программа на ассемблере работает на уровне аппаратных средств, входящих в программную модель процессора, которая описана в главе 2. — При разработке алгоритма работы программы и его реализации на ассемблере программист сам должен беспокоиться о размещении данных в памяти, об эф­фективном использовании ограниченного количества регистров, об организа­ции связи с операционной системой и другими программами. Специфика разработки программы на ассемблере состоит в том, что програм­мист должен уделять внимание не только и не столько особенностям модели­рования предметной области, сколько тому, как при этом наиболее эффективно и корректно использовать ресурсы процессора. — В результате работы транслятора создаются файл объектного модуля и файл листинга программы, содержащий разнообразную информацию о программе: объектный код, сообщения о синтаксических ошибках, таблицу СИМВОЛОВ и т. д. Имея небольшой опыт, из файла листинга можно извлечь массу полезной ин­формации. — После получения корректного объектного модуля программу необходимо скомпоновать. Для этого применяется утилита-компоновщик, одним из ОСНОВНЫХ назначений которой является разрешение внешних ссылок. Если целевая про­грамма состоит из нескольких отдельно оттранслированных модулей и в них есть взаимные ссылки на переменные или модули, то компоновщик разрешает их, формируя тем самым правильные перемещаемые адреса. — Результатом работы компоновщика является исполняемый (загрузочный) мо­дуль, имеющий расширение .ехе. Его уже можно запускать в надежде, что он правильно вы полнит задуманные программистом действия. Но чаше всего при первых запусках программы этого не случается, что говорит о наличии в про­грамме логических ошибок, поиск которых без специальных средств может быть долгим. Для поиска и устранения логических ошибок предназначен специаль­ный вид программного обеспечения — отладчики. С их помощью в большин­стве случаев довольно быстро удается снять большинство программных про­блем подобного рода. Контрольные вопросы 1. Жизненный цикл программы – этапы; 2. каждой тетраде можно поставить в соответствие одну… 3. для пре­образования кода символа шестнадцатеричной цифры в соответствующее двоич­ное число есть два пути: … 4. Алгоритм преобразования должен различать прописные и строчные буквенные символы шестнадцатеричных цифр и корректи­ровать значение ASCII-кода на величину… 5. после записи значения шестнадцатеричной циф­ры следует символ «h» — зачем? 6. общая схема процесса разработки программы на ассемблере — рис.; 7. На этапе трансляции решается несколько задач: …; 8. Итог рабо­ты ассемблера — два файла:…; 9. При использовании пакета TASM получение объектного модуля исходного файла производится программой (ассемблером)…; 10. Перед работой с программой tasm.exe желательно провести некоторые подготовительные операции. После установки пакета TASM в каталоге \TASM\BIN…; 11. Для устранения ошибок нужно…; 12. файл листинг – для чего? 13. исходный файл наассемблере в общем случае может содержать конструкции следующих типов:…; 14. После устранения ошибок и получения объектного модуля можно приступать к следующему этапу — созданию исполняемого (загрузочного) модуля, или, как еще называют этот процесс, к… — зачем? 15. Результатом работы компоновщика является создание загрузочного файла с расширением …; 16. Отладка программы – назначение? 17. Отладчики бывают двух типов:…; 18. Отладчик позволяет решить две главные задачи:…; 19. Как произвести запуск отладчика? 20. Управление работой отладчика ведется с помощью системы меню. Имеются два тина таких меню:…; 21. Запустить программу в отладчике можно в одном из четырех режимов:; 22. Режим безусловного выполнения программы целесообразно применять…, и как; 23. Режим выполнения программы до текущего положения курсора целесообразно применять…, и как; 24. В режиме выполнения программы с установкой точек прерывания целесообразно применять…, и как; 25. Режим выполнения программы по шагам применяется для детального целесообразно применять…, и как; 26. Окно CPUотражает состояние процессора и состоит из пяти подчиненных окон…; 27. Особенности разработки программ в MASM — в него входят следующие основные программы:…. Темы и вопросы для самостоятельного обучения Вопросы для самостоятельного изучения Не нашли то, что искали? Воспользуйтесь поиском: Лучшие изречения: Сдача сессии и защита диплома — страшная бессонница, которая потом кажется страшным сном. 8774 — | 7145 — или читать все. 188.64.174.135 © studopedia.ru Не является автором материалов, которые размещены. Но предоставляет возможность бесплатного использования. Есть нарушение авторского права? Напишите нам | Обратная связь. Отключите adBlock! и обновите страницу (F5) очень нужно Assembler Глава #13 — Программирование в MASM Программирование в MASM Компиляторы языка Assembler несколько отличаются друг от друга т.к не существует единого стандарта. Обычно для Intel совместимых процессоров используется синтаксис команд, указанный в документации от Intel и AMD (называемый Intel), сами же команды и их использование описаны в документации с официальных сайтов производителей процессоров. Но, кроме команд, в исходном коде программы также встречаются специальные символы и директивы, указывающие компилятору как нужно компилировать программу. Обычно, именно эти элементы программы отличаются для разных компиляторов. Для программирования на Assembler’е под Windows чаще всего используется компилятор MASM, поэтому желательно знать особенности программирования на нем. Многие другие компиляторы пытаются быть совместимыми с MASM, поэтому данный материал частично пригоден и для их использования. Об использовании чисел можно посмотреть в главе #2, о работе с памятью в главе #4 и компилирование программы показано в главе #8. Повторно этот и другие, уже изложенные материалы рассмотрены не будут. Дополнительную информацию можно найти в пакете masm32 — \masm32\help\masm32.hlp а также в пакете с компилятором MASM (если он в виде отдельного продукта) — \bin\qh.exe (переменная среды HELPFILES должна указывать на папку с файлами справки — \help в каталоге установленного MASM’а). Краткое описание MASM есть также в MSDN: .NET Development -> Visual Studio .NET -> Product Documentation -> Visual C++ -> Reference -> Microsoft Macro Assembler Reference. Данная глава посвящена, в основном, макросредствам компилятора MASM, его элементам хранения данных и улучшения читаемости исходного кода. ——————————- Зачем нужны разнообразные макросредства? Компилятор нужен для автоматизации вычислений, необходимых при создании программы. Пример: jmp AnyLabel — безусловный переход на метку AnyLabel • Если знаковое смещение от метки AnyLabel до конца этой команды поместится в байт, то создается следующий код: db 0EBh,AnyLabel-($+1) • Если разница больше байта, то: db 0E9h dd AnyLabel-($+4) Как видно из примера, код команды и операнд зависят от текущего адреса (обозначен символом «$») и от адреса метки AnyLabel. Поэтому программу удобнее писать не в hex редакторе, а используя компилятор, который будет производить все нужные вычисления при модификации программы. В отличие от компиляторов языков высокого уровня, Assembler не «думает» за программиста, а только производит «механические» вычисления, тем самым не искажая оригинальные мысли автора программы. Чем больше компилятор будет считать, тем проще будет написание программы, не ухудшая откомпилированный вариант. Также, получится более понятный и организованный исходный код, который будет легче воспринимать и модифицировать в дальнейшем. Но, самое главное — нужно устанавливать зависимость одних участков программы от других, где это возможно (как в примере с командой jmp). Это избавит вас от рутинной переработки исходника при модификации, и от возможных ошибок, возникающих при этом. ——————————- Оформление исходного кода Исходник может содержать пояснения для программистов каким образом работает та или иная часть программы. Желательно, чтобы вначале исходного файла, перед процедурами и другими оконченными логическими блоками были комментарии, вкратце описывающие принцип работы и способ использования. Следующий тип комментария удобен для пояснения небольших участков кода. Текст, находящийся за символом «;» и до конца строки игнорируется компилятором. пример: xchg eax,eax ;поменяет местами значения регистров eax и eax Также бывают блочные комментарии, исключающие целый блок текста: comment @ Текст пояснения @ после директивы comment указывается символ, который будет означать последнюю строку блочного комментария. Если строка слишком длинная, ее можно разделить на несколько, используя символ «\» Пример: xchg eax,\ ;начало строки eax ;продолжение — конец Большие программы удобно разделять на несколько файлов, после чего можно использовать директиву «include имя файла», для их объединения. Файл, указанный этой директиве компилируется также, как будто его содержимое находится вместо директивы include. ——————————- Выражения Вместо непосредственно указанных чисел, в программе можно использовать выражения, автоматически вычисляемые при компиляции. В выражениях можно использовать следующие операторы: +, -, *, /, mod (остаток от деления), div, and, or, xor, not, shr, shl, скобки для указания порядка вычислений и т.д. Пример: mov eax,2*(3+4) ;откомпилируется как mov eax,14 mov ecx,3 shl 2 ;mov ecx,12 Также, можно использовать переменные в выражениях. Переменными желательно обозначать числа, многократно используемые в программе. Пример: WindowSize=100+5 ;создадим переменную WindowSize, имеющую значение 105 mov eax,WindowSize+2 ;mov eax,107 mov ecx,WindowSize+4 ;mov ecx,109 Такие переменные не являются ячейками памяти программы, а существуют только для компиляции. Значение переменной может быть изменено. Переменные обычно объявляются в одном месте программы для удобной настройки ее работы, а в больших программах выносятся в отдельный файл. При помощи директив equ и textequ можно указать строку в качестве значения переменной. Объявленная при помощи директивы equ переменная может быть как текстовой так и числовой, в зависимости от того сможет ли компилятор интерпретировать ее значение как число или нет при инициализации. Тип такой переменной в последующим не может быть изменен. Для указания строк, их заключают в угловые скобки. Длинна строки не может превышать 255 символов. Для указания самих скобок и других специальных символов в качестве текста, перед ними ставится знак «!» Пример: ProgName equ «Any Program» WindowTitle db «This program name is: «, ProgName ——————————- Структуры Структуры нужны для того чтобы задать формат хранения группы данных, используемых в программе. Используются обычно для упрощения модификации формата хранения данных а также для согласованности форматов данных между разными модулями и частями программы. Пример: AnyStruct struct AnyDword dd ? Any3Words dw 10,20,30 TString5 db 3 dup (‘z’) AnyStruct ends Данная форма записи объявляет формат группы данных (структуру) под названием AnyStruct (название является типом группы данных). Она не создает данных непосредственно, но позволяет задать их значения по умолчанию, если при инициализации они опущены. После объявления структуры, например, можно использовать следующие выражения: sizeof(AnyStruct)- размер структуры в байтах (=13) AnyStruct.Any3Words- (=4) Структуры позволяют также задать выравнивание (указывается как число после слова struct) для выравнивания элементов структуры. Также, структура может содержать выражение org Число, указывающее смещение структуры. После описания, можно объявлять данные указанного типа, например: StructTest AnyStruct <> Создаст следующие данные: StructTest.AnyDword dd ? StructTest.Any3Words dw 10,20,30 StructTest.TString5 db 3 dup (‘z’) Т.к все параметры структуры не инициализированы (не указаны в угловых скобках), то область памяти StructTest имеет значения всех элементов структуры AnyStruct по умолчанию Пример инициализации структуры: TStruct2 AnyStruct ,»ttt»> Получим следующие данные: TStruct2.AnyDword dd 2 TStruct2.Any3Words dw 5,20,8 TStruct2.TString5 db «ttt» В данном примере опущено только второе слово из Any3Words, и принимает значение по умолчанию, остальные данные инициализируются значениями, указанными в угловых скобках. После инициализации, к данным можно обращаться следующим образом: mov [TStruct2.AnyDword],10 inc [TStruct2.Any3Words] Если адрес структуры, например, находится в регистре eax, то: assume eax: ptr AnyStruct mov ecx,[eax].AnyDword mov bx,[eax].Any3Words assume eax:nothing либо mov eсx,[eax].AnyStruct.AnyDword Кроме структур, можно создать еще и следующие типы данных: union (объединение) и record (запись). Чаще всего они встречаются внутри структур. union Представляет одну и туже область памяти как разные типы данных. Используется обычно в случаях, когда исключено одновременное хранение перечисленных данных а также для ссылки на одну и туже область данных как на разные типы, в зависимости от имени используемого элемента. Размер объединения равен максимальному размеру перечисленного элемента. Указываются объединения почти также, как и структуры: AnyUnion union FullDword dd ? LowestWord dw ? LowestByte db ? AnyUnion ends TUnion AnyUnion После этого TUnion.FullDword = 12345678h, TUnion.LowestWord=5678h, а TUnion.LowestByte=78h record Используется для описания группы бит. Позволяют удобно использовать выражения с битами, и создавать битовую маску. Пример — запись, описывающая число Real4 (с.м предыдущую главу): FpuReal4 record Sign:1, Exponent:8=127, Significand:23 mov eax,FpuReal4 ;mov eax,-1.5 record поддерживает следующие выражения: mask — получить маску записи/поля width — узнать размер в битах записи/поля. В выражениях, название элемента записи равно смещению (в битах) от начала записи. Пример: FpuReal4 record Sign:1, Exponent:8=127, Significand:23 mov ecx,FpuReal4 > ;2.0 ;получим значение поля Exponent в регистр eax mov eax,ecx shr eax,Exponent and eax,mask Exponent shr Exponent ;eax=128 ——————————- Макросы Макросы используются для автоматизации создания часто повторяющихся участков программы. Обычно эти участки схожи по смыслу между собой, но несколько отличаются в реализации, либо слишком малы для выноса в процедуру. Макрос представляет из себя описание алгоритма для генерации исходного кода, интерпретируемого при компиляции. Существует два типа макросов: макро-функции и макро-процедуры. Макро-процедуры при вызове просто заменяются на последовательность команд, вызываются аналогично обычной команде, и может быть вызваны только в начале строки. Макро-функции отличаются тем, что могут возвращать некое значение, и могут вызываться в выражениях. Параметры вызова указываются в круглых скобках. Для указания макро-функции внутри макроса используется директива «EXITM » Макросы могут иметь локальные переменные. Объявляются они перечислением через запятую после слова «local». Они существуют только в самом макросе, и поэтому не создают конфликт с уже объявленными в других местах переменными с таким же именем. Внутри макросов можно использовать специальные макро- комментарии, указываемые после символов «;;». Они не попадают в листинг. Пример макро-процедуры: ZeroEax macro ;объявим макро-функцию xor eax,eax endm ;конец макроса После объявления макрос можно использовать также, как и команду процессора. Пример: ZeroEax ;откомпилируется как xor eax,eax Макрос может иметь параметры Пример макро-функции: XorAndRet macro reg xor reg,reg EXITM ENDM . neg XorAndRet(eax) ;Откомпилируется в xor eax,eax и neg eax Пример #2: ZeroReg macro param1:= xor param1,param1 ENDM . RVar equ edx ZeroReg ecx ;откомпилируется как xor ecx,ecx ZeroReg RVar ;раскроется как xor RVar,RVar после откомпилируется как xor edx,edx ZeroReg ;параметр неуказан, используется дефолтное значение (получим xor eax,eax) Как видно из примера, компилятор просто производит поиск текста «param1» в теле макроса, заменяет его на указанное в качестве параметра значение, и после компилирует. Этот процесс часто называется «раскрытием макроса». Это важно понимать для написания макросов. Для того, чтобы передать в качестве параметра именно значение переменной нужно поставить перед ней знак %, а для того, чтобы раскрыть макросы во всей строке, нужно поставить этот же знак в начале строки. Пример: ProgName equ %WindowTitle db «This program name is: &ProgName&» Для того чтобы отделить имя переменной от текста, используется символ «&» Пример: moveXx macro dest,src mov e&dest&x,e&src&x ENDM moveXx a,b ;откомпилируется в mov eax,ebx Параметров может быть несколько, можно задавать значения по умолчанию (как в примере ZeroReg), можно также указывать следующие модификаторы: -req — обязательный параметр. Если при вызове он не указан то компилятор выдаст ошибку. -vararg — последний параметр может быть vararg. Это означает, что все, что указанно при вызове макроса в качестве параметров присваивается этому параметру как единая текстовая строка. Пример: DisplayNote macro etxt:vararg % echo Note: @FileCur(@CatStr(%@Line)) etxt ENDM . DisplayNote any,test,params ;comment Переменной etxt присвоится текст «any,test,params» как единый параметр т.к она vararg. Если убрать слово vararg и двоеточие, то переменной etxt присвоится только текст «any», и при компиляции появится предупреждение о том, что указаны лишние параметры при вызове (каковыми компилятор посчитает слова «test» и «params»). Параметры vararg обычно используются при создании макросов с переменным количеством параметров. Для создания более функциональных макросов, существуют директивы, позволяющие организовывать циклы, ветвления и т.д. Также, большинство из них можно использовать и вне макросов. Организовать цикл можно при помощи следующих директив: FOR, FORC, REPEAT, WHILE, и GOTO FOR parametr[:req | :=значение по умолчанию], Данная директива повторяет цикл столько раз, сколько параметров содержится в указанной текстовой строке. Первый операнд для FOR указывает имя переменной, которой присваивается текущий параметр для каждой итерации. Можно задать также значение по умолчанию, или модификатор req. Пример: ZeroRegs macro reglist:vararg FOR curparam:= , xor curparam,curparam ENDM ENDM . ZeroRegs ebx,,ecx ;откомпилируется в xor ebx,ebx / xor eax,eax и xor ecx,ecx Пример#2. Следующая запись в исходном коде обнулит значения регистров, указанных в угловых скобках: FOR curreg, xor curreg,curreg ENDM Для преждевременного прерывания цикла или макроса используется директива EXITM Остальные директивы работают схожим образом: Директива FORC parametr, организовывает цикл, повторяющийся для каждого символа заданной строки, REPEAT выражение — заданное количество раз, WHILE выражение — пока истинно (не нулевое) значение выражения. Конец блока обозначается директивой ENDM. GOTO макрометка — осуществляет безусловный переход на указанную макрометку, которая задается следующим образом :LabelName. Часто в макросах встречаются директивы условного ассемблирования. Эти директивы проверяют заданное условие, и на основе этого решают компилировать указанный блок или нет. Конец блока обозначается директивой ENDIF IF не нулевой (истина) IFE нулевой (ложен) IFB tесли выражение пустое IFNB если выражение не пустое IFDEF если переменная определена IFNDEF если переменная не определена IFDIF текстовые строки разные IFDIFI текстовые строки разные (без учета регистра) IFIDN текстовые строки идентичны IFIDNI текстовые строки идентичны (без учета регистра) Пример: IFDEF AnyVar .. ;откомпилируется если определена переменная AnyVar ELSEIFDEF AnySecondVar .. ;откомпилируется если определена переменная AnySecondVar ELSE .. ;откомпилируется если переменные AnyVar и AnySecondVar не были определены. ENDIF IFB и IFNB часто используются для проверки: указан ли параметр макроса при вызове или нет. Ключ компилятора «/Dимя=значение» позволяет определить переменную и задать ей значение. Поэтому, используя директивы условного ассемблирования можно написать исходный код, зависящий от параметров компиляции. Для каждой из этих директив условного ассемблирования существует аналогичная версия директивы ELSE. Директивы сравнения строк имеют два параметра, а остальные — один. Существует директива .ERR [текст] для отображения ошибки, и ее версии с окончаниями, как у директивы IF для отображения ошибки при определенном условии. Для операции сравнения используются следующие операторы: EQ (равно), NE (не равно), GT (больше чем), LT (меньше чем), GE (больше или равно), LE (меньше или равно), которые возвращают 0 если ложно, или -1 если истинно. Они часто используются в директивах условного ассемблирования. Пример — макрос, печатающий числовой параметр — слово или другой тип: IsWord macro number:req IF number GT 0FFh and number LE 0FFFFh echo number is word ELSE echo number is not word ENDIF ENDM Компилятор masm Yasm – свободный ассемблер, являющийся попыткой полностью переписать ассемблер NASM. Лицензируется под лицензией BSD и в настоящее время развивается Питером Джонсоном и Майклом Ерманом. Yasm… Скачать WinAsm Studio WinAsm Studio — бесплатная среда разработки программного обеспечения для Microsoft Windows и DOS, изначально предназначенная для написания программ на языке ассемблера. Создана программистом Антонисом Киприану…. Скачать SASM (SimpleASM) — бесплатная простая кроссплатформенная Open Source среда разработки программного обеспечения на языках ассемблера NASM, MASM, GAS, FASM с подсветкой синтаксиса и отладчиком. SASM… Скачать RadASM RadASM — бесплатная среда разработки программного обеспечения для операционных систем Microsoft Windows и не только, изначально предназначенная для написания программ на языке ассемблера. Создана программистом Ketil Olsen… Скачать NASM (Netwide Assembler) — свободный ассемблер для архитектуры Intel x86. Используется для написания 16-, 32- и 64-разрядных программ. NASM был создан Саймоном Тэтхемом совместно с… Скачать Fresh > 1 Fresh IDE — свободная интегрированная среда разработки на визуальном языке ассемблера для операционных систем Microsoft Windows со встроенным FASM. Fresh IDE поддерживает сборку программ для тех же… Скачать Visual Assembler Visual Assembler – бесплатная компьютерная программа, которая написана для тех, кто программирует на ассемблере. Borland Tasm – транслятор сделанный для MS-DOS. Т. к. начинающему программисту на… Скачать Beye (от англ. Binary EYE, старое название Biew) – мультиплатформенный редактор файлов с поддержкой бинарного, шестнадцатеричного и дизассемблерных режимов. Для дизассемблирования используется Intel-синтаксис. Цветные AVR/Java/x86-i386-AMD64/ARM-XScale/PPC64… Скачать Программирование на языке Assembler в FASM В начале было слово… Если точнее то было просто предложение от Kinder-а написать статью посвящённую макросам в FASM. Я согласился попробовать, но рассматривать макросы отдельно от синтаксиса как-то не очень правильно, а синтаксис без примеров разобрать сложно и в результате получилось сочинение о том как писать программы в FASM. В этом сочинении будут рассмотрены основные моменты отличающие FASM от sдругих компиляторов, правила по которым пишутся макросы и форматы выходных файлов создаваемые FASM-ом. Так же в рамках данного сочинения мы создадим несколько контролов в виде макросов . Данный раздел является вольным пересказом соответствующего раздела руководства, поставляемого с компилятором. Данная статья посвящена использованию макросов в компиляторе FASM. Для начала вопрос: «Что такое макрос?» (поскольку я не могу услышать Ваш ответ прямо сейчас, когда пишу эту статью, отправляйте свои ответы мне по электронной почте, если Ваше мнение отличается от моего мнения). Макрос — это инструкция препроцессору компилятора развернуть, встретившееся в коде программы, имя макроса (возможно с параметрами) в последовательность строк кода ассемблера с использованием переданных параметров (если таковые заданы). Далее предлагаю Вам ознакомиться с основными директивами, используемыми внутри определений макросов. Внутри определений макросов можно использовать инструкции if и else при этом каждая инструкция if должна закрываться инструкцией end if. Пример из руководства, поставляемого вместе с компилятором: Этот макрос является расширением инструкции процессора mov. В данном случае если оба операнда макроса являются сегментными регистрами используется связка «push — pop», в любом другом случае используется стандартная инструкция «mov op1,op2». Оператор in позволяет проверить соответствие операнда нескольким значениям в угловых скобках. Можно ещё более расширить эту инструкцию для пересылки трёх значений второго в первый, а третьего во второй: В данном случае нас интересует инструкция eq, которая позволяет проверить эквивалентен ли операнд какому либо значению, в нашем случае мы проверяем его отсутствие, и если он отсутствует, то подставляется ветвь if иначе подставляется ветвь else. Директива purge позволяет отменить последнее определение макроса. Кроме уже изложенного в определение макроса можно передавать заранее неизвестное количество операндов (пар операндов и т.д.), для этого необходимо заключить операнды, количество которых заранее неизвестно, в квадратные скобки. Например для вызова процедур написан макрос STDCALL: Операндами этого макроса служат один обязательный (proc) и несколько необязательных параметров (arg). Директива reverse сообщает препроцессору, что следующие строки необходимо повторить столько раз, сколько параметров arg передано макросу начиная с последнего параметра. Директива common сообщает препроцессору, что следующие строки необходимо повторить только один раз. Директива forward сообщает препроцессору, что следующие строки необходимо повторить столько раз, сколько параметров arg передано макросу начиная с первого параметра. Действие директив common, forward и reverse заканчивается другой директивой common, forward или re-verse соответственно или закрывающейся фигурной скобкой. Если ни одна из этих директив не встречается в определении макроса, то макрос развернётся для всех параметров начиная с первого. Неизвестное количество параметров можно передать и другому макросу: В этом примере при выполнении ветви if в макрос stdcall кроме параметра [proc] передаются все полученные параметры arg. Внутри макроопределения может использоваться оператор #, который может использоваться для составления операторов ассемблера, например условного перехода: При выполнении макроса jif ax,ae,10h,exit макрос будет развёрнут в следующую конструкцию: Так же этот оператор можно использовать и для составления имён переменных или макросов внутри макроопределений: Теперь при вызове данного макроса в секции данных Мы будем иметь два массива из 10 байт каждый, с именами Chif.mas и Rab.mas. Аналогично можно создать и переменные и макросы внутри определения макроса. Однако определить макрос внутри макроса обычным путём: препроцессор не позволит использовать данную конструкцию, выход в использовании директивы fix она эквивалентна директиве equ, но препроцессор обрабатывает fix позже чем equ, что и позволяет использовать подобную конструкцию: Синтаксис компилятора ФАСМ несколько отличается от синтаксиса других компиляторов, но отличия незначительны и в основном касаются макроязыка. Средства макроязыка мы рассмотрим ниже, здесь же я хотел бы отметить только то, что передача адреса переменной производится указанием имени переменной без каких либо скобок или префиксов, а её содержимого написанием имени переменной в квадратных скобках. mov eax,var; записываем в регистр еах адрес переменной var mov eax,[var]; записываем в регистр еах значение переменной var Структура каркасного приложения на ФАСМ-е В этой части мы рассмотрим, основы синтаксиса данного компилятора и рассмотрим каркасные приложения для основных форматов исполняемых файлов. Итак, что необходимо для работающего приложения? Во-первых мы должны указать компилятору какого формата должен быть создаваемый файл. Это делается директивой format после, которой следует указание форматов: • PE формат исполняемых файлов Windows. Далее должно следовать уточнение GUI (графический интерфейс), console (консольное приложение) и native (если Вы знаете, что это такое сообщите мне). Если выбран графический интерфейс, то следует также указать версию графического интерфейса 4.0, а так же зарезервированное слово DLL, если собирается динамическая библиотека. • MZ формат исполняемых файлов MS DOS. • COFF или MS COFF (для линковки продуктами Microsoft)для создания объектного файла, который в дальнейшем будет линковаться к другому проекту или к ресурсам. • ELF формат для создания исполняемых файлов UNIX подобных систем (Linux). Как Вы наверно поняли, я не знаком с файлами ELF типа и в данной статье мы не будем его рассматривать. Если директива format не указана, компилятор соберёт файл в формате com. После указания формата выходного файла мы должны указать компилятору точку начала программы. Это делается с помощью директивы entry после которой указывается метка, с которой начинается код программы. Например entry start. Так же, в случае необходимости, мы должны указать на начало секций данных, кода, импорта, экспорта или ресурсов. Для этого существует директива section, после которой в кавычках следует название секции, далее без скобок тип секции (данные или код) и атрибуты (запись, чтение исполняемый код). Более подробно когда какие атрибуты указывать Вы прочитаете ниже т.к. для разных форматов выходных файлов эти атрибуты отличаются. Форматы PE исполняемых файлов Windows. Консольные приложения Консольное приложение может использовать все функции API предоставляемые Windows, но работать с такой программой пользователь может только через командную строку. Вот простой пример консольного приложения: В данном примере создаётся три секции: данных, кода и секция импортируемых функций. Секцию импорта я создаю при помощи макроса _library, в стандартной поставке такого макроса нет, но если написать без подчёркивания перед library то всё скомпилируется правильно. Причина проста, я пользуюсь FASM-ом с версии 1.35, а тогда такого макроса еще не было (а сам я ещё не смог бы его написать) и для совместимости с ранее написанными программами я включил два варианта этого макроса. В ранней версии, необходимо было записывать все используемые в приложении функции вручную, теперь же работу по подключению только используемых функций берёт на себя компилятор, хотя за такое удобство приходится платить некоторым увеличением времени компиляции. Более подробно о принципе работы этого и других макросов будет написано в соответствующем разделе ниже. Название секции импорта «.idata», хотя название можно изменить и это не повлияет на работоспособность программы, т.к. мы указали назначение этой секции import data, далее следует указание атрибутов, в данном случае readable, что означает для чтения и этого достаточно, если Вы не собираетесь менять содержимое этой секции. Следующей рассмотрим секцию данных. У нас секция данных имеет название «.data», далее следует указание назначения секции data, что означает секцию данных, атрибуты указаны readable writeable, т.е. эта область памяти будет доступна для чтения и записи. Если указать только первый атрибут (readable) при выполнении программы произойдёт ошибка «Программа выполнила недопустимую операцию». Последней рассмотрим секцию кода, она имеет название «.code» назначение секции code, т.е. исполняемая часть программы, атрибуты readable executable, что означает, что из секции кода мы можем читать данные (под данными может подразумеваться и коды инструкций и определённые в этой секции данные) и можем выполнять содержимое этой секции. Кроме рассмотренных секций, консольное приложение может иметь секции экспортируемых функций и секцию ресурсов. Это пожалуй всё, что необходимо знать для начала о консольных приложениях. Да ещё я считаю лишний раз напомнить, что хоть консольное приложение и напоминает внешне программы DOS-а, использование прерываний в нём не допускается т.к. это всё же приложение Windows, естественно выполняться такое приложение может только в Windows. Графическое приложение Графические приложения Windows это оконные приложения, такие как Word, Excel, Notepad и т.д. В отличии от консольных приложений, GUI приложения должны содержать как минимум одну процедуру обработки сообщений, приходящих к окну. Вот простой пример оконного приложения: Так же, как и в примере с консольным приложением, в первой строке указана директива format PE, но вместо console, как в предыдущем примере, дано указание GUI 4.0 компилятору собирать приложение с графическим интерфейсом версии 4.0. Приложение из нашего примера ничего полезного не делает, оно просто создаёт окно, которое реагирует только на нажатие двух системных кнопок в верхнем правом углу окна «Свернуть» и «Закрыть». Приложение содержит секции данных, кода, импорта и ресурсов. После указания точки входа в программу entry start подключаются файлы содержащие макросы и определения констант и структур Windows. Затем следует секция данных, определение которой дано в предыдущем разделе, и секция кода. В секции кода мы получаем хендл нашего модуля (GetModuleHandle), загружаем иконку (LoadIcon), определённую в секции ресурсов, загружаем стандартный курсор Windows (LoadCursor) и заполняем структуру wc для дальнейшей регистрации класса нашего окна (RegisterClass). После регистрации класса окна мы создаём окно зарегистрированного класса (CreateWindowEx). В структуре wc имеется член .lpfnWndProc, в который мы записываем адрес начала процедуры обработки событий окна WindowProc. Далее следует цикл обработки сообщений, посылаемых окну системой Windows. Процедура обработки сообщений получает от Windows четыре параметра: proc WindowProc, hwnd, wmsg, wparam, lparam hwnd — хендл нашего окна wmsg — код сообщения, которое Windows послало нашему окну wparam и lparam — уточняющие параметры посланного сообщения. proc это не директива компилятора, а макрос содержащий, часть пролога процедуры. Он определён следующим образом: Таким образом следующая строка proc Win,param будет развёрнута в следующую конструкцию: Более подробно это означает, что мы определяем метку Win, которая означает начало процедуры. В следующей строке записана директива virtual at ebp+8, которая должна заканчиваться директивой end virtual. Внутри этого определения помещаются переменные, которые будут размещаться с адреса указанного после at, в нашем примере это ebp+8. Это означает, что в нашем примере запись «mov param,eax» будет заменена на «mov [ebp+8],eax«. Если бы в определении процедуры было две или более переменных, то адрес каждой последующей переменной увеличивался бы на размер предыдущей переменной. Таким образом: определит три переменные с адресами У некоторых читателей может возникнуть вопрос: «А зачем все эти пляски?». Ответ прост: регистр ebp указывает на вершину стека и все переменные, передаваемые в процедуру, находятся выше (в смысле в памяти с адресами больше чем вершина стека т.к. вершина стека сдвигается вниз когда в стек помещаются данные и вверх, когда данные из стека изымаются) текущей вершины стека. Первой, в определении переменных внутри virtual — end virtual записана директива local, которая указывает компилятору, что следующие за ней через запятую метки, локальны в данном макросе. Последней, внутри описания виртуальных переменных, следует определение макропеременной ..ret = $ — (ebp+8), которая фактически содержит количество переданных процедуре байт параметров. Она используется при написании эпилога процедуры для очистки стека при возврате управления инструкции, следующей за вызовом данной процедуры. После определения виртуальных переменных, передаваемых процедуре в качестве параметров, определяются локальные макропеременные, которые используются во второй части пролога процедуры. Я уже несколько раз использовал термин — макропеременная. Макропеременная отличается от переменных, используемых в программе, тем, что она существует только во время компиляции и используется как константа, которая может иметь разные значения в разных частях программы. После определения макропеременных начинается блок определения виртуальных переменных, однако переменных в этом макросе нет. После макроса proc необходимо ставить макрос enter, который содержит заключительную часть пролога, а между ними могут располагаться локальные переменные. Для того, что бы имена переменных были локальными перед ними ставится точка. Например .param. Макрос enter определён следующим образом: Таким образом dynamic_size — это размер памяти отведённой под локальные переменные. Последняя инструкция, в прологе процедуры, enter dynamic_size,0. Это единственная строка, которая попадёт в исполняемый код программы. Завершаться процедура должна макросом return, который определён следующим образом: Полагаю здесь не должно быть сложностей с пониманием макроса. Процедура должна правильно обрабатывать поступившие сообщения. Те сообщения, которые мы хотим обработать сами, выделяются в первых строках процедуры и управление передаётся на те участки кода, которые должны производить необходимые действия, а те сообщения, которые нам нет необходимости обрабатывать, мы доверяем обработать системе Windows (Def-WindowProc). Хочу обратить Ваше внимание на то, что в данной программе используются глобальные метки (wmdestroy, wmcreate, defwndproc), что не очень удобно в программах содержащих несколько процедур (большинство оконных процедур обрабатывают одни и те же сообщения), поэтому рекомендуется внутри процедур использовать локальные метки (.wmdestroy, .wmcreate, .defwndproc). Теперь пришло время посмотреть на секцию импорта. Она отличается от рассмотренной в предыдущем разделе здесь мы используем макрос library, который определён следующим образом: Для того, чтобы было более понятно вспомним, как в нашем примере используется этот макрос: Таким образом, макрос library создаёт заголовок таблицы импорта, вначале записывая смещение названия библиотеки DLL, а затем смещение, с которого начинаются имена импортируемых функций. Далее следуют макросы import, определённые следующим образом: Он создаёт тело таблицы импорта для каждой из импортируемых библиотек. Вначале создавая таблицу смещений имён импортируемых функций, а затем записывая имена импортируемых функций. Более подробно о структуре PE-файла Вы должны прочитать в соответствующей литературе (например в туториалах, которые написал Iczelion). После таблицы импорта создаётся таблица ресурсов: В нашем примере мы используем только одну иконку. Динамические библиотеки (DLL) Последним в данном разделе рассмотрим простую динамическую библиотеку. Динамическая библиотека — это приложение GUI, который может содержать как исполняемый код, так и ресурсы. Это приложение не предназначено для самостоятельного запуска, оно используется другими приложениями для хранения часто используемых процедур, шрифтов и многого другого. Мы рассмотрим создание динамической библиотеки на примере процедуры, возвращающей строку, содержащую текущую дату. Мы создадим два модуля один файл динамической библиотеки (dll2.dll) и файл использующий созданную нами библиотеку (usedll.exe). Вот файл динамической библиотеки: Первые строки format PE GUI 4.0 DLL и entry DllEntryPoint указывают компилятору создать РЕ-файл динамической библиотеки с точкой входа на метке DllEntryPoint. Как Вы могли заметить динамическая библиотека практически ни чем не отличается от обычной программы Windows, кроме того, что входная процедура вызывается системой в четырёх случаях: • Когда динамическая библиотека загружается в адресное пространство процесса (параметр fdwReason = DLL_PROCESS_ATTACH = 1); • Когда динамическая библиотека выгружается из адресного пространства процесса (параметр fdwReason = DLL_PROCESS_ DETACH = 0); • Когда создается новый поток в рамках динамической библиотеки (параметр fdwReason = DLL_ THREAD_ATTACН = 2); • Когда разрушается (прекращается) поток в рамках динамической библиотеки (параметр fdwReason = DLL_ THREAD_DETACH = 3). В обработке стартовой процедуры мы определяем значение параметра fdwReason и если динамическая библиотека была загружена или выгружена выдаём соответствующее сообщение. В конце файла мы создаём секцию экспорта нашей библиотеки: В таблице мы задаём имя файла динамической библиотеки и имена экспортируемых процедур. Макрос export определён следующим образом: Сперва, объявляются локальные метки и подсчитывается количество экспортируемых процедур: Затем заносится смещение RVA имени библиотеки: Следующая строка заносит общее количество экспортируемых функций, количество функций экспортируемых по имени (при использовании этого макроса все функции экспортируются по имени), смещение начала массива смещений функций, смещение начала массива смещений имен экспортируемых функций и смещение массива смещений ординалов функций. Далее объявляется метка начала массива смещений экспортируемых функций и создаётся массив их смещения: Следом объявляется метка начала массива смещений имён экспортируемых функций и создаётся сам массив: Затем объявляется метка начала массива смещений ординалов функций и создаётся массив ординалов экспортируемых функций: Ну и в конце макроса записывается имя динамической библиотеки и создаётся массив имен экспортируемых функций: Для более подробного ознакомления со структурой секции экспорта необходимо читать специальную литературу по структуре РЕ — файлов. Теперь давайте посмотрим, на программу вызывающую нашу динамическую библиотеку: Обычное графическое приложение не имеющее своего окна и ресурсов размером 2 кБ. Импортирует только три функции две предоставляемые системой Windows и одна написанной нами динамической библиотекой. Как видите подключение созданной нами динамической библиотеки, ничем не отличается от подключения стандартных библиотек Windows. В этом и заключается вся прелесть использования ФАСМ-а, он не берёт на себя слишком много, что в купе с гибким макроязыком позволяет сделать очень многое максимально просто. Формат исполняемых файлов MS COFF (obj — файлы) Использование obj-файлов в ФАСМ, лично мне, не кажется жизненно необходимым, однако использование этого формата возможно понадобится при создании проектов на С/С++. Именно на таком примере мы и рассмотрим формат файлов MS COFF. Для примера напишем программу, выводящую МессаджБокс с текущей датой. Модуль на ассемблере будет составлять строку символов, а модуль на С++ будет выводить эту строку в МессаджБокс. Вот модуль на ассемблере: Обратите внимание на строку 2, где закомментировано определение точки входа в программу (_WinMainCRTStartup)если эту строку раскомментировать, то точка входа в программу будет именно в модуле на ассемблере. Результат работы функции записывается в переменную _outs и адрес (указатель на строку) возвращаем в регистре еах. В этом модуле используются макросы копирования строки в строку (StringCopyHTML ebx,day). Этот макрос не входит в поставку компилятора и содержится в файлах strings.mac и strings.asm он просто копирует строку (не включая нулевой символ), указатель на которую передаётся вторым параметром, в строку, указатель которой передаётся вторым параметром, после его выполнения в регистре еах количество скопированных символов. Эта процедура выдаёт строку типа: «День: 28 Месяц: 10 Год:2003». Для использования объектного модуля созданного на ассемблере необходимо в проект на С++ добавить созданный нами объектный файл (Project->Add to project->Files. . . в появившемся окне необходимо выбрать тип файлов obj и указать используемый файл). Теперь рассмотрим текст программы на MS Visual C++ 5.0: Здесь ничего сложного: подключаем файл «windows.h», затем объявляем внешнюю процедуру, возвращающую указатель на строку символов с нулём в конце, объявляем переменную dat, как указатель на строку символов, и наконец функция WinMain в которой вызываем нашу функцию (Wind) на ассемблере и выводим результат в мессаджбокс. Внимательный читатель скажет: «Стоп, но в модуле на ассемблере функцию мы объявили как ?Wind@@YAPADXZ, а в модуле на С++ вызываем Wind». Всё правильно. Просто MS Visual C++ 5.0, к объявленным внешним (находящимся в скомпилированных модулях) процедурам добавляет дополнительные символы, для контроля соответствия типов передаваемых результатов из процедуры и переменных в процедуру. Вот краткая структура имени функций формируемых MS Visual C++: Префикс Объявленное имя переменной Разделитель Тип вызова процедуры Тип результата Тип параметров Постфикс ? Wind @@Y A PAD X Z Причём постфикс изменяется в зависимости от наличия передаваемых в функцию параметров. Если параметры передаются, то постфикс «@Z», а если параметры не передаются то просто «Z». Типы вызова процедуры следующие: __cdecl A __fastcall I __stdcall G Типы результата и передаваемых переменных имеют одинаковые обозначения: Тип результата Размер Обозначение char 1 D unsigned char 1 E short 2 F unsigned short 2 G enum 2 ?AW4__unnamed@@ long 4 J unsigned long 4 K int 4 H unsigned int 4 I float 4 M double 8 N long double 10 O bool 1 _N Причём если передаётся (получается) не параметр, а его адрес (например char *) то перед обозначением переменной добавляется PA. Если параметры, получаемые из процедуры или передаваемые в процедуру, отсутствуют, вместо них ставится X. Читатель может сказать: «Это как же нужно мозг морщить, чтобы всё запомнить и не перепутать ничего при составлении имени процедуры?». Такая работа имеет основное свойство: она не особо интеллектуальна, но муторна и действия при её решении вполне укладываются в рамках алгоритма. Отсюда вывод: компьютер на то и создан, что бы выполнять подобные задачи так пусть сам, и добавляет все эти префиксы, постфиксы и т.п. Напишем макрос, который будет объявлять процедуру составляя её имя из имени которое мы ему передаём и добавляя к нему все необходимые префиксы. Использовать переменные длиннее 4 байт мы не будем, но думаю Вы сами сможете модернизировать макросы под свои нужды если понадобится. Для начала мы должны определить символьные константы, соответствующие типам вызова процедуры и типам получаемых и возвращаемых параметров: Далее следует определение макроса: В первой строке мы очищаем временную символьную константу, далее следует указание препроцессору обработать строку «dr fix dr#type» для всех значений параметров type начиная с первого. Эта строчка, просто создаёт константу содержащую все символы соответствующие всем получаемым процедурой параметрам. Например если в процедуру передаётся два параметра типа int, то dr будет эквивалентно HH. Далее следует указание препроцессору следующие строки обработать только один раз (common) в этих строках мы делаем видимой из других модулей программы метку (название) нашей процедуры и собственно следует содержимое макроса proc, рассмотренного ранее. Полагаю, этот макрос не должен вызвать затруднений. Сложности в понимании может вызвать только строка «?#name#@@Y#calltype#returns#dr#@Z», объясню её более подробно. Сперва стоит знак вопроса (посмотрите табличку со структурой имени процедуры), после которого, значок номера (#), он говорит препроцессору, что далее следует символьная константа, которую следует склеить в одну метку с предыдущим текстом. Если константы с указанным именем не существует, то она включается, как есть. Рассмотрим последовательность действий препроцессора. Метка состоит из вопросительного знака, затем (без разделителей) добавляется, передаваемая макросу переменная name, после неё добавляется текст @@Y,после текста добавляется передаваемая макросу переменная calltype, затем переменная returns, потом составленная нами константа dr, и наконец постфикс @Z (или просто Z, если в процедуру не передаются параметры). Всё. Макрос создан. Однако это ещё не всё. С таким определением процедуры не всегда можно использовать стандартные макросы enter и return т.к. тип вызова __cdecl предполагает, что стек после завершения работы процедуры будет очищаться вызывающей процедурой т.е. модулем написанным на С++, а стандартный макрос return сам очищает стек. Вот макрос, содержащий эпилог процедуры для типа вызова __cdecl: Но не только эпилог нужно изменить, но и пролог тоже: Полагаю эти два коротеньких макроса не вызовут затруднений. Ну и пример использования данных макросов: Функция IntToString преобразует 32-х битное без знаковое число (второй параметр) в строку (адрес строки передаётся первым параметром). Модуль на С++ будет выглядеть следующим образом: Думаю больше пояснений не нужно. Формат исполняемых файлов MS DOS Формат исполняемых файлов MZ Программирование под ДОС в ФАСМ в принципе почти ничем не отличается от программирования под ДОС в любом другом компиляторе. Вот простейший пример программы: Как видите ничего сложного. Формат исполняемых файлов СОМ Если директива format не указана создаются файлы формата *.сом. Вот пример: Компилятор masm В данной главе мы поговорим о двух конкурирующих продуктах MASM и TASM, их плюсах и минусах, общих чертах и различиях. Когда в конце 80-х я впервые «пересел» на «айбиэмки», первый вопрос, который я задал знающим людям, был об ассемблере. До этого я программировал на разных компьютерах, в основном имеющих весьма ограниченные ресурсы. Естественно, что основным языком на таких компьютерах был ассемблер 27 . Мне дали MASM, кажется, это была вторая версия. Удивительно, но тогда на ассемблере я начал писать что-то типа баз данных. Проект мой не был закончен, но к ассемблеру я прикипел основательно. Потом мне попался Турбо Ассемблер версии 1.0. Он работал гораздо быстрее MASM. В дальнейшем мне приходилось использовать то один, то другой ассемблер. Как Вы, наверное, уже поняли, первая любовь оказалась сильнее, но теперь нам придется серьезно поговорить о том, что же все-таки предпочтительнее использовать при программировании в операционной системе Windows. 27 Одно время в образовании был широко распространен персональный компьютер «Ямаха», ОЗУ которого составляла всего 64 Кб (потом 128). Писать для такого компьютера, скажем, на языке Паскаль было, естественно, непозволительной роскошью. Начнем со справочной информации о параметрах командной строки ML.EXE и TASM32.EXE. В начале рассмотрим транслятор ML.EXE. Параметр Комментарий /? Вывод помощи. /AT Создать файл в формате .СОМ. Для программирования в Windows этот ключ, естественно, бесполезен. /Bl Использовать альтернативный компоновщик. Предполагается автоматический запуск компоновщика. /c Компиляция без компоновки. /Ср Сохранение регистров пользовательских идентификаторов. Может использоваться для дополнительного контроля. /Cu Приведение всех пользовательских идентификаторов к верхнему регистру. /Сх Сохранение регистров пользовательских идентификаторов, объявленных PUBLIC и EXTERNAL. /coff Создание объектных файлов в стандарте coff. Применение обязательно. Задание текстового макроса. Очень удобен для отладки с использованием условной компиляции. /ЕР Листинг: текст программы с включаемыми файлами. /F Размер стека в байтах. Размер стека по умолчанию равен 1 Мб. /Fe Имя исполняемого файла. Имеет смысл без параметра /с. /Fl Создать файл листинга. /Fm Создать map-файл. Имеет смысл без опции /с. /Fo Задать имя объектного файла. /Fpi Включение кода эмулятора сопроцессора. Начиная с 486-ого микропроцессора, данный параметр потерял актуальность. /Fr Включить ограниченную информацию браузера. /FR Включить полную информацию браузера. /G Использовать соглашение вызова Паскаль, Си, stdcall. /H Установить максимальную длину внешних имен. /I Добавить путь для inc-файлов. Допускается до 10 опций /I. /link Опции командной строки компоновщика. Имеет смысл без опции /с. /nologo Не показывать заголовочный текст компилятора. /Sa Листинг максимального формата. /Sc Включить в листинг синхронизацию. /Sf Листинг первого прохода. /Sl Длина строки листинга. /Sn Не включать в листинг таблицу символов. /Sp Высота страницы листинга. /Ss Текст подзаголовка листинга. /St Текст заголовка листинга. /Sx Включить в листинг фрагменты условной компиляции. /Ta Для компилирования файлов, расширение которых не .asm. /W Устанавливает перечень событий компиляции, трактуемые как предупреждения. /WX Трактовать предупреждения как ошибки. /w Тоже что /W0 /WX. /X Игнорировать путь, установленный переменной окружения INCLUDE. /Zd Отладочная информация состоит только из номеров строк. /Zf Объявить все имена PUBLIC. /Zi Включить полную отладочную информацию. /Zm Включить совместимость с MASM 5.01. /Zp Установить выравнивание структур. /Zs Выполнять только проверку синтаксиса. Параметр Комментарий /? или /h Вывод помощи. /a Сегменты в объектном файле располагаются в алфавитном порядке. /s Сегменты в объектном файле расположены в порядке их описания. Задание текстового макроса. Очень удобен для отладки с использованием условной компиляции. /e Включение кода эмуляции сопроцессора. /r Разрешение инструкций сопроцессора. /i Добавить путь для inc-файлов. Синтаксис такой же, как у команды РАТН. /j Определяет директиву, которая будет транслироваться перед трансляцией. /kh Задается максимальное количество идентификаторов. По умолчанию 16384. /l Создавать файл листинга. /la Показать в листинге код, вставляемый транслятором для организации интерфейса с языками высокого уровня. /ml Различать прописные и строчные буквы в идентификаторах. /mx Различать прописные и строчные буквы в идентификаторах PUBLIC и EXTERNAL. /mu Считать все символы в идентификаторах как прописные. /mv Установить максимальную длину идентификатора. /m Установка количества проходов транслятора. По умолчанию это число равно 1. /n Не выдавать в файле листинга таблицы идентификаторов. /os, /o, /op, /oi Тип объектного кода: стандартный, оверлейный, Phar Lap, IBM. /p Проверять наличие кода с побочными эффектами при работе в защищенном режиме. /q Удаление из объектного кода лишней информации. /t Подавление вывода всех сообщений при условном ассемблировании. /w0, /w1, /w2 Уровень полноты сообщений: сообщения не генерируются, сообщения генерируются. /w- /w+ Генереция (+) или ее отсутствие (-) сообщений класса xxx. /x Включить в листинг блоки условного ассемблирования. /z Выводить не только сообщения об ошибках, но строку с ошибкой. /zi Включить в объектный код информацию для отладки. /zd Поместить в объектный код номера строк. /zn Не помещать в объектный код отладочной информации. В этой таблице объяснение опции помещено под строкой, содержащей эту опцию. /ALIGN:number Определяет выравнивание секций в линейной модели. По умолчанию 4096. /BASE:Определяет базовый адрес (адрес загрузки). По умолчанию для ЕХЕ-программы адрес 0х400000, для DLL — 0х10000000. /COMMENT:[«]comment[«] Определяет комментарий, помещаемый в заголовок ЕХЕ- и DLL-файлов. /DEBUG Создает отладочную информацию для ЕХЕ- и DLL-файлов. Отладочная информация помещается в pdb-файл. /DEBUGTYPE: CV — отладочная информация в формате Microsoft, COFF — отладочная информация в формате COFF (Common Object File Format), BOTH — создаются оба вида отладочной информации. /DEF:filename Определяет DEF-файл. /DEFAULTLIB:library Добавляет одну библиотеку к списку используемых библиотек. /DLL Создать DLL-файл. /DRIVER[:] Используется для создания NT-драйвера (Kernel Mode Driver). /ENTRY:symbol Определяет стартовый адрес для ЕХЕ- и DLL-файлов. /EXETYPE:DYNAMIC Данная опция используется при создании VxD-драйвера. /EXPORT:entryname[=internalname][,@ordinal[,NONAME]][,DATA] Данная опция позволяет экспортировать функцию из вашей программы так, чтобы она была доступна для других программ. При этом создается import-библиотека. /FIXED[:NO] Данная опция фиксирует базовый адрес, определенный в опции /BASE. /FORCE[:] Позволяет создавать исполняемый файл, даже если не найдено внешнее имя или имеется несколько разных определений. /GPSIZE:number Определяет размер общих переменных для MIPS и Alpha платформ. /HEAP:reserve[,commit] Определяет размер кучи (HEAP) в байтах. По умолчанию этот размер равен одному мегабайту. /IMPLIB:filename Определяет имя import-библиотеки, если она создается. /INCLUDE:symbol Добавляет имя к таблице имен. /INCREMENTAL: Если установлена опция /INCREMENTAL:YES, то в ЕХЕ добавляется дополнительная информация, позволяющая быстрее перекомпилировать этот файл. По умолчанию это информация не добавляется. /LARGEADDRESSAWARE[:NO] Указывает, что приложение оперирует адресами, большими 2 Гб. /LIBPATH:dir Определяет библиотеку, которая в первую очередь разыскивается компоновщиком. /MACHINE: Определяет платформу. В большинстве случаев это делать не приходится. /MAP[:filename] Дает команду создания МАР-файла. /MAPINFO: Указывает компоновщику включить соответствующую информацию в МАР-файл. /MERGE:from=to Объединить секцию «from» с секцией «to» и присвоить имя «to». /NODEFAULTLIB[:library] Игнорирует все или конкретную библиотеку. /NOENTRY Необходимо для создания DLL-файла. /NOLOGO Не выводить начальное сообщение компоновщика. /OPT: Определяет способ оптимизации, которую выполняет компоновщик. /ORDER:@filename Оптимизация программы путем вставки определенных инициализированных данных (COMDAT). /OUT:filename Определяет выходной файл. /PDB: Определить имя файла, содержащего информацию для отладки. /PROFILE Используется для работы с профайлером (анализатором работы программы). /RELEASE Помещает контрольную сумму в выходной файл. /SECTION:name,[E][R][W][S][D][K][L][P][X] Данная опция позволяет изменить атрибут секции. /STACK:reserve[,commit] Определяет размер выделяемого стека. Commit — определяет размер памяти, интерпретируемый операционной системой. /STUB:filename Определяет STUB-файл, запускающийся в системе MS DOS. /SUBSYSTEM:[,#[.##]] Определяет, как запускать ЕХЕ-файл. CONSOLE — консольное приложение, WINDOWS — обычные WINDOWS-приложения, NATIVE — приложение для Windows NT, POSIX — создает приложение в POSIX-подсистеме WINDOWS NT. /SWAPRUN: Сообщает операционной системе скопировать выходной файл в swap-файл (WINDOWS NT). /VERBOSE[:LIB] Заставляет выводить информацию о процессе компоновки. /VERSION:#[.#] Помещает информацию о версии в ЕХЕ-заголовок. /VXD Создать VXD-драйвер. /WARN[:warninglevel] Определяет количество возможных предупреждений, выдаваемых компоновщиком. /WS:AGGRESSIVE Несколько уменьшает скорость выполнения приложения (Windows NT). Операционная система удаляет данное приложение из памяти в случае его простоя. В пакетах Borland С, начиная с 1997 года, сосуществовали две программы для компоновки объектных файлов: tlink32.exe и ilink32.exe. Опции этих программ практически совпадали, ilink32.exe — инкрементальный, или пошаговый, компоновщик. Он хранит информацию о предыдущих компоновках, что позволяет значительно ускорить весь процесс повторных трансляций. В последнее время программа tlink32.exe вообще исчезла из поставки. В дальнейшем мы не будем делать различий между этими двумя программами. Опции, помеченные (+), появились в новых версиях ilink32.exe, а опции со знаком (-), наоборот, исчезли. В новых версиях для выделения опции используется «/» вместо тире. -m Создать МАР-файл с информацией о сегментах и два листинга с PUBLIC-именами (в алфавитном и адресном порядке). -s Детальная информация о сегментах в МАР-файле. -M Поместить в МАР-файл сокращенные имена идентификаторов. -c Различать прописные и заглавные буквы в PUBLIC и EXTERNAL именах. -Enn Задает максимальное количество ошибок, приводящее к остановке компоновки. -P- Запретить паковать сегменты. Имеет смысл для 16-битных приложений (-P — разрешить). -b:хххх Задает базовый адрес. По умолчанию базовый адрес равен 400000Н. (+) -B:хххх Аналогично опции -b, но не создает таблицу настройки. Ключи —b и -B могут несколько ускорить работу программы. -wxxx Возможные предупреждения. Например, -w-stk игнорировать отсутствие стекового сегмента. -Txx -Tpx PE image(x: е=ЕХЕ, d=DLL) Тип выходного файла. Tpe — создать ЕХЕ-файл. Tpd — создать DLL-файл. Tpp — создать пакетный файл. (+) -ax -ap -aa -ар — создать консольное приложение, -аа — создать обычное Windows-приложение (GUI), -ad — создать 32-битный драйвер для Windows.(+) -r Заставляет компоновщик выдавать информацию о процессе компоновки. -Vd.d Помещает в ЕХЕ-заголовок ожидаемую версию Windows. -Ud.d Поместить в заголовок ЕХЕ-файла номер версии программы. (+) -o Импорт по номеру функции. (-) -Ao:nnnn Определяет величину выравнивания (кратно 2, минимально 16). -Af:nnnn Файл выравнивания. -Sc:xxxx Определить размер стека. -S:xxxx Определить размер резервного стека. Минимально 4К. -Hc:хххх Определить размер специальной «кучи». -H:хххх Определить размер резервной «кучи». -n Нет библиотеки «по умолчанию». (-) -v Поместить в исполняемый файл полную отладочную информацию. Можно использовать -v+ и -v- для селективного помещения отладочной информации в отдельные файлы. -j Определить путь поиска OBJ-файлов. -L Определить путь к LIB-библиотеке. -x Не создавать МАР-файл. -Rr Позволяет заменять или добавлять ресурсы. (+) -d Установить задержку загрузки библиотеки DLL. Она будет загружаться лишь при вызове входной процедуры. (+) -Dxxxx Поместить в PE-заголовок специальный дескриптор. -GC Поместить в заголовок РЕ строку (или строки). Например -GC»Hellow!». (+) -GD Генерировать Delphi-совместимый файл ресурсов. (+) -GF Установить флаг для загрузочного модуля: SWAPNET — указание для операционной системы поместить загрузочный модуль в swap-файл и загружать его оттуда, если он расположен на сетевом устройстве. SWAPCD — аналогично предыдущему флагу, но для съемных устройств. UNIPROCESSOR — приложение не должно запускаться в мультипроцессорной системе. LARGEADDRESSAWARE — приложение использует адреса больше 4 Gb. AGGRESSIVE — операционная система удаляет приложение из памяти в случае его простоя.(+) -Gk Заставляет компоновщик оставлять в случае ошибки те файлы, которые обычно в этом случае уничтожались.(+) -Gl Генерировать LIB-файл.(+) -Gpr Создавать пакет «времени исполнения».(+) -Gpd Создать пакет «времени создания».(+) -Gn Запретить пошаговую компиляцию.(+) -GS:string=[ECIRWSDKP] Добавляет флаги к уже существующим флагам секций.(+) -Gz Помещает в РЕ-заголовок контрольную сумму загрузочного модуля. На первый взгляд трудно выявить предпочтение между MASM32 и TASM32. Но все же: 1. MASM32 несколько более богат возможностями. Я имею в виду опции командной строки. 2. TASM32 перестал поддерживаться как отдельный продукт. В связи с этим MASM обошел конкурента по количеству содержащихся в пакете примеров, документации, библиотек и т.д. 3. TASM32 осуществляет более сложный алгоритм вызова API-функций, а это приводит к тому, что исполняемые модули в TASM32 получаются несколько большими, чем в MASM32. Завершая главу, приведу несколько простых примеров. Включение в исполняемый файл отладочной информации. Если в исполняемый файл была включена отладочная информация, то фирменный отладчик позволяет работать одновременно и с текстом программы, и с дизассемблированным кодом. Это особенно удобно для языков высокого уровня, а для программ на ассемблере это весьма мощный инструмент отладки. Пусть текст программы содержится в файле PROG.ASM. Для того чтобы включить отладочную информацию в исполняемый модуль, используем при трансляции следующие ключи: ML /c /coff /Zd /Zi prog.asm LINK /subsystem:windows /debug prog.obj При этом кроме файла PROG.EXE на диске появится файл PROG.PDB, содержащий отладочные данные. Теперь для отладки следует запустить фирменный 32-битный отладчик фирмы Microsoft — Code View. TASM32 /ml /zi prog.asm TLINK32 -aa -v prog.obj В результате в модуль PROG.EXE будет включена отладочная информация. Для отладки такого модуля следует использовать 32-битный Turbo Debugger — TD32.EXE. На Рис. 1.5.1 представлено окно отладчика с отлаживаемой программой. Можно видеть, что на экране имеется и текст программы, и ее дизассемблированный код. Более подробно об отладчиках мы будем говорить в последней части книги. Получение консольных и GUI приложений. О консольных приложениях речь еще впереди, здесь же я буду краток. Консольные приложения — это приложения, работающие с текстовым экраном, при этом они являются полнокровными 32- битными программами. О структуре консольных программ речь пойдет ниже, сейчас же заметим, что для получения консольного приложения с помощью TLINK32.EXE вместо ключа -aa следует использовать -ар. Что касается компоновщика из пакета MASM32, то здесь следует использовать ключ /subsystem:console вместо /subsystem:windows. Рис. 1.5.1. Окно TD32.EXE с отлаживаемой программой. Компилятор masm На сегодняшний день существует огромное количество языков программирования высокого уровня. На их фоне программирование на низкоуровневом языке — ассемблере — может на первый взгляд показаться чем-то устаревшим и нерациональным. Однако это только кажется. Следует признать, что ассемблер фактически является языком процессора, а значит, без него не обойтись, пока существуют процессоры. Основными достоинствами программирования на ассемблере являются максимальное быстродействие и минимальный размер получаемых программ. Недостатки зачастую обусловлены лишь склонностью современного рынка к предпочтению количества качеству. Современные компьютеры способны легко справиться с нагромождением команд высокоуровневых функций, а если нелегко — будьте добры обновите аппаратную часть вашей машины! Таков закон коммерческого программирования. Если же речь идет о программировании для души, то компактная и шустрая программа, написанная на ассемблере, оставит намного более приятное впечатление, нежели высокоуровневая громадина, обремененная кучей лишних операций. Бытует мнение, что программировать на ассемблере могут только избранные. Это неправда. Конечно, талантливых программистов-ассемблерщиков можно пересчитать по пальцам, но ведь так обстоит дело практически в любой сфере человеческой деятельности. Не так уж много найдется водителей-асов, но научиться управлять автомобилем сумеет каждый — было бы желание. Ознакомившись с данным циклом статей, вы не станете крутым хакером. Однако вы получите общие сведения и научитесь простым способам программирования на ассемблере для Windows, используя ее встроенные функции и макроинструкции компилятора. Естественно, для того, чтобы освоить программирование для Windows, вам необходимо иметь навыки и опыт работы в Windows. Сначала вам будет многое непонятно, но не расстраивайтесь из- за этого и читайте дальше: со временем все встанет на свои места. Итак, для того, чтобы начать программировать, нам как минимум понадобится компилятор. Компилятор — это программа, которая переводит исходный текст, написанный программистом, в исполняемый процессором машинный код. Основная масса учебников по ассемблеру делает упор на использование пакета MASM32 (Microsoft Macro Assembler). Но я в виде разнообразия и по ряду других причин буду знакомить вас с молодым стремительно набирающим популярность компилятором FASM (Flat Assembler). Этот компилятор достаточно прост в установке и использовании, отличается компактностью и быстротой работы, имеет богатый и емкий макросинтаксис, позволяющий автоматизировать множество рутинных задач. Его последнюю версию вы можете скачать по адресу: сайт выбрав flat assembler for Windows. Чтобы установить FASM, создайте папку, например, «D:\FASM» и в нее распакуйте содержимое скачанного zip-архива. Запустите FASMW.EXE и закройте, ничего не изменяя. Кстати, если вы пользуетесь стандартным проводником, и у вас не отображается расширение файла (например, .EXE), рекомендую выполнить Сервис -> Свойства папки -> Вид и снять птичку с пункта Скрывать расширения для зарегистрированных типов файлов. После первого запуска компилятора в нашей папке должен появиться файл конфигурации — FASMW.INI. Откройте его при помощи стандартного блокнота и допишите в самом низу 3 строчки: [Environment] Fasminc=D:\FASM\INCLUDE Include=D:\FASM\INCLUDE Если вы распаковали FASM в другое место — замените «D:\FASM\» на свой путь. Сохраните и закройте FASMW.INI. Забегая вперед, вкратце объясню, как мы будем пользоваться компилятором: 1. Пишем текст программы, или открываем ранее написанный текст, сохраненный в файле .asm, или вставляем текст программы из буфера обмена комбинацией. 2. Жмем F9, чтобы скомпилировать и запустить программу, или Ctrl+F9, чтобы только скомпилировать. Если текст программы еще не сохранен — компилятор попросит сохранить его перед компиляцией. 3. Если программа запустилась, тестируем ее на правильность работы, если нет — ищем ошибки, на самые грубые из которых компилятор нам укажет или тонко намекнет. Ну, а теперь мы можем приступить к долгожданной практике. Запускаем наш FASMW.EXE и набираем в нем код нашей первой программы: .data Caption db ‘Моя первая программа.’,0 Text db ‘Всем привет!’,0 .code start: invoke MessageBox,0,Text,Caption,MB_OK invoke ExitProcess,0 Жмем Run -> Run, или F9 на клавиатуре. В окне сохранения указываем имя файла и папку для сохранения. Желательно привыкнуть сохранять каждую программу в отдельную папку, чтобы не путаться в будущем, когда при каждой программе может оказаться куча файлов: картинки, иконки, музыка и прочее. Если компилятор выдал ошибку, внимательно перепроверьте указанную им строку — может, запятую пропустили или пробел. Также необходимо знать, что компилятор чувствителен к регистру, поэтому .data и .Data воспринимаются как две разные инструкции. Если же вы все правильно сделали, то результатом будет простейший MessageBox (рис. 1). Теперь давайте разбираться, что же мы написали в тексте программы. В первой строке директивой include мы включили в нашу программу большой текст из нескольких файлов. Помните, при установке мы прописывали в фасмовский ини-файл 3 строчки? Теперь %fasminc% в тексте программы означает D:\FASM\INCLUDE или тот путь, который указали вы. Директива include как бы вставляет в указанное место текст из другого файла. Откройте файл WIN32AX.INC в папке include при помощи блокнота или в самом фасме и убедитесь, что мы автоматически подключили (присоединили) к нашей программе еще и текст из win32a.inc, macro/if.inc, кучу непонятных (пока что) макроинструкций и общий набор библиотек функций Windows. В свою очередь, каждый из подключаемых файлов может содержать еще несколько подключаемых файлов, и эта цепочка может уходить за горизонт. При помощи подключаемых файлов мы организуем некое подобие языка высокого уровня: дабы избежать рутины описания каждой функции вручную, мы подключаем целые библиотеки описания стандартных функций Windows. Неужели все это необходимо такой маленькой программе? Нет, это — что-то вроде «джентльменского набора на все случаи жизни». Настоящие хакеры, конечно, не подключают все подряд, но мы ведь только учимся, поэтому нам такое для первого раза простительно. Далее у нас обозначена секция данных — .data. В этой секции мы объявляем две переменные — Caption и Text. Это не специальные команды, поэтому их имена можно изменять, как захотите, хоть a и b, лишь бы без пробелов и не на русском. Ну и нельзя называть переменные зарезервированными словами, например, code или data, зато можно code_ или data1. Команда db означает «определить байт» (define byte). Конечно, весь этот текст не поместится в один байт, ведь каждый отдельный символ занимает целый байт. Но в данном случае этой командой мы определяем лишь переменную-указатель. Она будет содержать адрес, в котором хранится первый символ строки. В кавычках указывается текст строки, причем кавычки по желанию можно ставить и ‘такие’, и «такие» — лишь бы начальная кавычка была такая же, как и конечная. Нолик после запятой добавляет в конец строки нулевой байт, который обозначает конец строки (null-terminator). Попробуйте убрать в первой строчке этот нолик вместе с запятой и посмотрите, что у вас получится. Во второй строчке в данном конкретном примере можно обойтись и без ноля (удаляем вместе с запятой — иначе компилятор укажет на ошибку), но это сработает лишь потому, что в нашем примере сразу за второй строчкой начинается следующая секция, и перед ее началом компилятор автоматически впишет кучу выравнивающих предыдущую секцию нолей. В общих случаях ноли в конце текстовых строк обязательны! Следующая секция — секция исполняемого кода программы — .code. В начале секции стоит метка start:. Она означает, что именно с этого места начнет исполняться наша программа. Первая команда — это макроинструкция invoke. Она вызывает встроенную в Windows API-функцию MessageBox. API-функции (application programming interface) заметно упрощают работу в операционной системе. Мы как бы просим операционную систему выполнить какое-то стандартное действие, а она выполняет и по окончании возвращает нам результат проделанной работы. После имени функции через запятую следуют ее параметры. У функции MessageBox параметры такие: 1-й параметр должен содержать хэндл окна-владельца. Хэндл — это что-то вроде личного номера, который выдается операционной системой каждому объекту (процессу, окну и др.). 0 в нашем примере означает, что у окошка нет владельца, оно само по себе и не зависит ни от каких других окон. 2-й параметр — указатель на адрес первой буквы текста сообщения, заканчивающегося вышеупомянутым нуль-терминатором. Чтобы наглядно понять, что это всего лишь адрес, сместим этот адрес на 2 байта прямо в вызове функции: invoke MessageBox,0,Text+2,Caption,MB_OK и убедимся, что теперь текст будет выводиться без первых двух букв. 3-й — указатель адреса первой буквы заголовка сообщения. 4-й — стиль сообщения. Со списком этих стилей вы можете ознакомиться, например, в INCLUDE\EQUATES\ USER32.INC. Для этого вам лучше будет воспользоваться поиском в Блокноте, чтобы быстро найти MB_OK и остальные. Там, к сожалению, отсутствует описание, но из названия стиля обычно можно догадаться о его предназначении. Кстати, все эти стили можно заменить числом, означающим тот, иной, стиль или их совокупность, например: MB_OK + MB_ICONEXCLAMATION. В USER32.INC указаны шестнадцатеричные значения. Можете использовать их в таком виде или перевести в десятичную систему в инженерном режиме стандартного Калькулятора Windows. Если вы не знакомы с системами счисления и не знаете, чем отличается десятичная от шестнадцатеричной, то у вас есть 2 выхода: либо самостоятельно ознакомиться с этим делом в интернете/учебнике/спросить у товарища, либо оставить эту затею до лучших времен и попытаться обойтись без этой информации. Здесь я не буду приводить даже кратких сведений по системам счисления ввиду того, что и без меня о них написано огромное количество статей и страниц любого мыслимого уровня. Вернемся к нашим баранам. Некоторые стили не могут использоваться одновременно — например, MB_OKCANCEL и MB_YESNO. Причина в том, что сумма их числовых значений (1+4=5) будет соответствовать значению другого стиля — MB_RETRYCANCEL. Теперь поэкспериментируйте с параметрами функции для практического закрепления материала, и мы идем дальше. Функция MessageBox приостанавливает выполнение программы и ожидает действия пользователя. По завершении функция возвращает программе результат действия пользователя, и программа продолжает выполняться. Вызов функции ExitProcess завершает процесс нашей программы. Эта функция имеет лишь один параметр — код завершения. Обычно, если программа нормально завершает свою работу, этот код равен нулю. Чтобы лучше понять последнюю строку нашего кода — .end start, — внимательно изучите эквивалентный код: format PE GUI 4.0 section ‘.data’ data readable writeable Caption db ‘Наша первая программа.’,0 Text db ‘Ассемблер на FASM — это просто!’,0 section ‘.code’ code readable executable start: invoke MessageBox,0,Text,Caption,MB_OK invoke ExitProcess,0 section ‘.idata’ import data readable writeable library KERNEL32, ‘KERNEL32.DLL’,\ USER32, ‘USER32.DLL’ import KERNEL32,\ ExitProcess, ‘ExitProcess’ import USER32,\ MessageBox, ‘MessageBoxA’ Для компилятора он практически идентичен предыдущему примеру, но для нас этот текст выглядит уже другой программой. Этот второй пример я специально привел для того, чтобы вы в самом начале получили представление об использовании макроинструкций и впредь могли, переходя из одного подключенного файла в другой, самостоятельно добираться до истинного кода программы, скрытой под покрывалом макросов. Попробуем разобраться в отличиях. Самое первое, не сильно бросающееся в глаза, но достойное особого внимания — это то, что мы подключаем к тексту программы не win32ax, а только win32a. Мы отказались от большого набора и ограничиваемся малым. Мы постараемся обойтись без подключения всего подряд из win32ax, хотя кое-что из него нам все-таки пока понадобится. Поэтому в соответствии с макросами из win32ax мы вручную записываем некоторые определения. Например, макрос из файла win32ax: macro .data во время компиляции автоматически заменяет .data на section ‘.data’ data readable writeable. Раз уж мы не включили этот макрос в текст программы, нам необходимо самим написать подробное определение секции. По аналогии вы можете найти причины остальных видоизменений текста программы во втором примере. Макросы помогают избежать рутины при написании больших программ. Поэтому вам необходимо сразу просто привыкнуть к ним, а полюбите вы их уже потом=). Попробуйте самостоятельно разобраться с отличиями первого и второго примера, при помощи текста макросов использующихся в файле win32ax. Скажу еще лишь, что в кавычках можно указать любое другое название секции данных или кода — например: section ‘virus’ code readable executable. Это просто название секции, и оно не является командой или оператором. Если вы все уяснили, то вы уже можете написать собственный вирус. Поверьте, это очень легко. Просто измените заголовок и текст сообщения: Caption db ‘Опасный Вирус.’,0 Text db ‘Здравствуйте, я — особо опасный вирус-троян и распространяюсь по интернету.’,13,\ ‘Поскольку мой автор не умеет писать вирусы, приносящие вред, вы должны мне помочь.’,13,\ ‘Сделайте, пожалуйста, следующее:’,13,\ ‘1.Сотрите у себя на диске каталоги C:\Windows и C:\Program files’,13,\ ‘2.Отправьте этот файл всем своим знакомым’,13,\ ‘Заранее благодарен.’,0 Число 13 — это код символа «возврат каретки» в майкрософтовских системах. Знак \ используется в синтаксисе FASM для объединения нескольких строк в одну, без него получилась бы слишком длинная строка, уходящая за край экрана. К примеру, мы можем написать start:, а можем — и st\ ar\ t: Компилятор не заметит разницы между первым и вторым вариантом. Ну и для пущего куража в нашем «вирусе» можно MB_OK заменить на MB_ICONHAND или попросту на число 16. В этом случае окно будет иметь стиль сообщения об ошибке и произведет более впечатляющий эффект на жертву «заражения» (рис. 2). Вот и все на сегодня. Желаю вам успехов и до новых встреч! Все приводимые примеры были протестированы на правильность работы под Windows XP и, скорее всего, будут работать под другими версиями Windows, однако я не даю никаких гарантий их правильной работы на вашем компьютере. Исходные тексты программ вы можете найти на форуме: сайт Компилятор masm Поддержка основных компиляторов MASM, FASM, TASM из коробки Отладка Поддержка запуска как сторонних отладчиков WinDbg, OllyDbg, TD, x64dbg, так и наличие интуитивно понятной встроенной отладки для некоторых типов проектов (beta) Подсветка и автодополнение синтаксиса Все ключевые слова вашего ассемблер кода имеют красивую цветную подсветку, а известные среде конструкции включены в автодополнение и имеют всплывающую подсказку с описанием. Собственный тип проектов Каждый программный проект хранится как обособленная единица, имеет конфигурацию, исходные коды и ссылки. Можно безболезненно перенести проект на другой компьютер или поделиться им. Инструменты рефакторинга На данный момент в среду разработки включены два инструмента: «Переименовать» который позволяет оперативно сменить имя переменной или функции во всех местах и «Извлечение процедуры» который позволяет извлечь выделяемый код с учетом аргументов в отдельную процедуру или файл Метрики Наряду с простейшими метриками, базирующимися на определении количественных характеристик, связанных с размером программы и используемых для прогнозирования трудозатрат и сроков разработки промежуточных этапов в IDE реализован расчёт метрик сложности потоков управления программ Сниппеты В среде присутствует панель сниппетов, которая позволяет делать часто используемые конструкции в виде заметок с возможностью их перетаскивания на код любой из программ Обработка ошибок Все сообщения от компиляторов и ошибки фиксируются. Вы получаете их списком, с возможностью перехода к сомнительной строке по клику Сравнение возможностей компиляторов MASM и FASM [закрыт] Подскажите, пожалуйста, что можно сделать на MASM и нельзя (или очень трудно) на FASM и наоборот. Закрыт по причине того, что необходимо переформулировать вопрос так, чтобы можно было дать объективно верный ответ участниками insolor, user194374, Abyx, Grundy, tutankhamun 7 янв ’16 в 16:40 . Вопрос порождает бесконечные прения и дискуссии, основанные не на знаниях, а на мнениях. Для получения ответа перефразируйте ваш вопрос так, чтобы на него можно было дать однозначно правильный ответ, либо удалите вопрос вовсе. Если вопрос можно переформулировать согласно правилам, изложенным в справке, отредактируйте его. 2 ответа 2 FASM предоставляет более развитую систему макросов, что облегчает восприятие кода и ускоряет процесс разработки. Хорошая статья по сабжу: http://www.insidepro.com/kk/108/108r.shtml Скажем так, MASM — это компилятор от крупной и вполне себе так серьезной фирмы Microsoft, а FASM — это компилятор, созданный энтузиастом, причем, насколько я знаю, только одним( и причем на Assembler`е ) =) Думаю, это о многом говорит вам. Но не подумайте, что я против энтузиазма, я наоборот за него — у энтузиастов порой получается все сделать даже лучше и качественнее, потому что они, как правило, одержимы не прибылью, как крупные компании, а скорее желанием получать удовольствие от своего дела. Но именно тут суть в том, что FASM был создан ОДНИМ человеком, что, в общем-то сложно, а MASM — подразделением Microsoft. Илон Маск рекомендует:  Инициализация Foxnoid Понравилась статья? Поделиться с друзьями: Кодинг, CSS и SQL
{ "url": "https://studiowb.ru/kompiljator-masm/", "source_domain": "studiowb.ru", "snapshot_id": "crawl=CC-MAIN-2021-10", "warc_metadata": { "Content-Length": "284299", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:DGOTMWPLU4XLAGXOO4OF6GF3ZE6W6C36", "WARC-Concurrent-To": "<urn:uuid:96afd4e4-c234-4fca-92ec-77a9c14c54ed>", "WARC-Date": "2021-02-26T12:54:26Z", "WARC-IP-Address": "87.236.16.120", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:ZWCZ7JEHAKU7GWK55K364L2EBID3SIYU", "WARC-Record-ID": "<urn:uuid:4c9fff62-bda4-45f8-bc35-7f41d40c5c6b>", "WARC-Target-URI": "https://studiowb.ru/kompiljator-masm/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ed696e1c-3fc0-4c24-90b8-918ca3a60f63>" }, "warc_info": "isPartOf: CC-MAIN-2021-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February/March 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-165.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 16, 17, 18, 29, 30, 64, 65, 111, 112, 225, 226, 353, 354, 380, 381, 671, 672, 751, 752, 981, 982, 1425, 1426, 1491, 1492, 1600, 1601, 1722, 1879, 1880, 2032, 2033, 2244, 2245, 2256, 2257, 2330, 2331, 2463, 2464, 2540, 2541, 2649, 2650, 2786, 2787, 2820, 2821, 2848, 2849, 2946, 2947, 3048, 3049, 3115, 3116, 3244, 3245, 3322, 3323, 3352, 3353, 3433, 3434, 3523, 3524, 3594, 3595, 3657, 3658, 3688, 3689, 3823, 3824, 3928, 3929, 4024, 4025, 4173, 4174, 4427, 4428, 4466, 4467, 4574, 4575, 4612, 4613, 4636, 4685, 4722, 4801, 4848, 4909, 4954, 5048, 5049, 5116, 5117, 5182, 5183, 5265, 5266, 5491, 5492, 5928, 5929, 5961, 5962, 6106, 6107, 6113, 6114, 6444, 6445, 6576, 6577, 6698, 6699, 6865, 6866, 7254, 7255, 7358, 7359, 7445, 7446, 7468, 7469, 7510, 7511, 7643, 7740, 7937, 8146, 8317, 8318, 8510, 8511, 8671, 8672, 8756, 8757, 8913, 8914, 9018, 9019, 9049, 9050, 9082, 9083, 9175, 9176, 9355, 9356, 9470, 9471, 9557, 9558, 9642, 9643, 9736, 9737, 9774, 9775, 9883, 9884, 9956, 9957, 9958, 10086, 10087, 10195, 10196, 10431, 10432, 10502, 10503, 10569, 10570, 10910, 10911, 10976, 10977, 11086, 11087, 11208, 11209, 11270, 11271, 11325, 11326, 11364, 11365, 11419, 11420, 11584, 11585, 11716, 11717, 11864, 11865, 12002, 12003, 12431, 12432, 12476, 12477, 12598, 12599, 12973, 12974, 13012, 13013, 13120, 13121, 13663, 13664, 13741, 13742, 14058, 14059, 14248, 14499, 14582, 14654, 14655, 14880, 14881, 14954, 14955, 15209, 15210, 16098, 16099, 16154, 16155, 16402, 16403, 16546, 16547, 16652, 16653, 17248, 17249, 17394, 17395, 17754, 17755, 17893, 17894, 18084, 18085, 18117, 18118, 18465, 18466, 18666, 18667, 18768, 18769, 19052, 19053, 19330, 19331, 19380, 19381, 19456, 19457, 20052, 20053, 20156, 20157, 20300, 20301, 20566, 20567, 20608, 20609, 20684, 20685, 20784, 20785, 20833, 20834, 20966, 20967, 21016, 21017, 21136, 21137, 21279, 21280, 21517, 21518, 21535, 21536, 21553, 21554, 21623, 21624, 21887, 21888, 22155, 22156, 22666, 22667, 22700, 22701, 22727, 22728, 22993, 22994, 23259, 23260, 23482, 23483, 23733, 23734, 23884, 23885, 23935, 23936, 24019, 24020, 24021, 24119, 24120, 24216, 24217, 24450, 24451, 24629, 24646, 24692, 24693, 24781, 24782, 24803, 24804, 25111, 25112, 25193, 25194, 25228, 25229, 25652, 25653, 25685, 25686, 25749, 25750, 25810, 25811, 25858, 25859, 25899, 25900, 25932, 25933, 25997, 25998, 26057, 26058, 26529, 26530, 26591, 26592, 26860, 26861, 26910, 26911, 27401, 27402, 27443, 27444, 27893, 27894, 27927, 27928, 28617, 28618, 28906, 28907, 29270, 29271, 29635, 29636, 29801, 29802, 29988, 29989, 30152, 30159, 30160, 30199, 30200, 30410, 30411, 30462, 30463, 30494, 30495, 30641, 30642, 31313, 31314, 32717, 32718, 32889, 32890, 32924, 32925, 32989, 32990, 33050, 33051, 33087, 33088, 33149, 33150, 33316, 33317, 33411, 33412, 33848, 33849, 33876, 33877, 33957, 33958, 33964, 33965, 34319, 34320, 34454, 34455, 34995, 34996, 35296, 35297, 35712, 35713, 36313, 36314, 36334, 36335, 36372, 36373, 36428, 36429, 36540, 36541, 36698, 36699, 36777, 36778, 36845, 36846, 36898, 36899, 36941, 36942, 37059, 37060, 37208, 37209, 37243, 37244, 37273, 37274, 37367, 37368, 37557, 37558, 37648, 37649, 37685, 37686, 37721, 37722, 37774, 37775, 37776, 37813, 37814, 37910, 37911, 37982, 37983, 38060, 38061, 38155, 38156, 38253, 38254, 38354, 38355, 38434, 38435, 38526, 38527, 38572, 38573, 38611, 38612, 38661, 38662, 38802, 38803, 39005, 39006, 39025, 39050, 39051, 39063, 39064, 39074, 39075, 39111, 39112, 39136, 39475, 39703, 39981, 39982, 40183, 40466, 40638, 40639, 40777, 40789, 40790, 40831, 40914, 40975, 41089, 41116, 41151, 41163, 41185, 41186, 41462, 41463, 41896, 42145, 42157, 42158, 42184, 42469, 42470, 42630, 42690, 42755, 42771, 42783, 42889, 42890, 42973, 42981, 43007, 43032, 43033, 43283, 43295, 43296, 43306, 43601, 43609, 43657, 43685, 43823, 43894, 43928, 43962, 44233, 44778, 44786, 44813, 44863, 44875, 44876, 44886, 45139, 45147, 45164, 45178, 45200, 45224, 45239, 45240, 45489, 45490, 45568, 45619, 45645, 45646, 45859, 45925, 45949, 45975, 46000, 46033, 46068, 46240, 46241, 46273, 46300, 46326, 46349, 46378, 46405, 46575, 46576, 46642, 46669, 46694, 46756, 46782, 46805, 46828, 46847, 46852, 46885, 46886, 47028, 47029, 47035, 47432, 47447, 47462, 47478, 47494, 47508, 47509, 47525, 47616, 47617, 47624, 47739, 47804, 47859, 47890, 47891, 48091, 48099, 48154, 48178, 48224, 48236, 48253, 48297, 48309, 48310, 48318, 48645, 48708, 48867, 49089, 49331, 49458, 49459, 49483, 49520, 49532, 49552, 49553, 49629, 49637, 49678, 49679, 49708, 49730, 49750, 49762, 49768, 49773, 49775, 49835, 49836, 49847, 49870, 49888, 49893, 49895, 49908, 49953, 50034, 50116, 50117, 50379, 50583, 50591, 50604, 50655, 50737, 50738, 50760, 50781, 50786, 50828, 50829, 50970, 51058, 51242, 51250, 51280, 51324, 51329, 51331, 51368, 51369, 51785, 51786, 51964, 51965, 52020, 52053, 52099, 52376, 52384, 52385, 52415, 52432, 52454, 52459, 52464, 52466, 52543, 52544, 52644, 52656, 52674, 52679, 52680, 52804, 53051, 53052, 53175, 53176, 53389, 53390, 53413, 53433, 53460, 53490, 53523, 53560, 53590, 53642, 53675, 53730, 53731, 53739, 53752, 53806, 53829, 53889, 53894, 53972, 53978, 53979, 54278, 54279, 54446, 54447, 54600, 54601, 54658, 54882, 54883, 54953, 54977, 55016, 55036, 55041, 55065, 55071, 55076, 55077, 55093, 55094, 55294, 55295, 55309, 55310, 55530, 55531, 55737, 55738, 55745, 55746, 55977, 55978, 56168, 56169, 56179, 56180, 56387, 56388, 56405, 56406, 56610, 56611, 56879, 56880, 56923, 56924, 57255, 57256, 57257, 57516, 57517, 57548, 57584, 57613, 57627, 57628, 57907, 57908, 58144, 58145, 58246, 58247, 58444, 58445, 58780, 58781, 58890, 58891, 59136, 59137, 59203, 59204, 59484, 59485, 60375, 60376, 60496, 60497, 60651, 60652, 60742, 60743, 60855, 60856, 60906, 60907, 60983, 60984, 61115, 61116, 61341, 61342, 61484, 61485, 61740, 61741, 61864, 61865, 61907, 61908, 61943, 61976, 62012, 62050, 62051, 62100, 62101, 62259, 62260, 62626, 62667, 62827, 62904, 62905, 63081, 63082, 63305, 63306, 63730, 63731, 63770, 63792, 63955, 63956, 63999, 64000, 64841, 64842, 65165, 65166, 65552, 65553, 65890, 65891, 66002, 66003, 66331, 66332, 66448, 66449, 66624, 66625, 66857, 66858, 67886, 67887, 67955, 67956, 68000, 68001, 68026, 68084, 68145, 68146, 68259, 68260, 68348, 68349, 68942, 68943, 68979, 68980, 69351, 69352, 69540, 69541, 69868, 69869, 70323, 70324, 70738, 70739, 71041, 71042, 71104, 71105, 71464, 71465, 71824, 71825, 72001, 72002, 72093, 72094, 72280, 72281, 72343, 72344, 72415, 72416, 72661, 72662, 72712, 72713, 72763, 72764, 72865, 72866, 73141, 73142, 73385, 73386, 73420, 73421, 73580, 73581, 73763, 73764, 73890, 74019, 74131, 74254, 74255, 74256, 74425, 74426, 74485, 74486, 74573, 74574, 74617, 74618, 74707, 74708, 74755, 74756, 75086, 75087, 75190, 75191, 75292, 75293, 75412, 75413, 75523, 75524, 75655, 75656, 75736, 75737, 76237, 76238, 76514, 76515, 76697, 76698, 76724, 76725, 77831, 77832, 78597, 78598, 78705, 78726, 78727, 78905, 78906, 78939, 78940, 78950, 78963, 78975, 78976, 79048, 79049, 79083, 79092, 79110, 79120, 79139, 79162, 79171, 79189, 79197, 79214, 79224, 79235, 79252, 79262, 79263, 79497, 79498, 80056, 80057, 80191, 80192, 80331, 80332, 80367, 80368, 81010, 81011, 81907, 81908, 82308, 82309, 82363, 82364, 82424, 82425, 82468, 82469, 82604, 82605, 82654, 82655, 82688, 82689, 82722, 82751, 82876, 82877, 82910, 82911, 82939, 82940, 83046, 83047, 83063, 83064, 84027, 84028, 84263, 84264, 84386, 84387, 84408, 84425, 84525, 84621, 84651, 84761, 84835, 84925, 84999, 85090, 85142, 85206, 85264, 85291, 85339, 85372, 85489, 85536, 85577, 85633, 85680, 85741, 85810, 85864, 85899, 85937, 85966, 85993, 86037, 86067, 86100, 86130, 86184, 86243, 86320, 86362, 86383, 86449, 86508, 86539, 86582, 86622, 86660, 86702, 86723, 86747, 86813, 86878, 86969, 87010, 87049, 87122, 87196, 87270, 87298, 87406, 87466, 87544, 87601, 87651, 87729, 87786, 87865, 87945, 87995, 88061, 88153, 88219, 88274, 88339, 88392, 88436, 88491, 88492, 88568, 88569, 88583, 88652, 88653, 88771, 88772, 88795, 88861, 88862, 88869, 88967, 88968, 88980, 89150, 89151, 89165, 89186, 89187, 89207, 89266, 89267, 89290, 89291, 89302, 89362, 89363, 89377, 89427, 89428, 89445, 89498, 89499, 89559, 89712, 89713, 89725, 89791, 89792, 89802, 89915, 89916, 89931, 89993, 89994, 90017, 90106, 90107, 90124, 90178, 90179, 90195, 90225, 90226, 90240, 90422, 90423, 90447, 90508, 90509, 90522, 90599, 90600, 90610, 90680, 90681, 90697, 90730, 90731, 90741, 90812, 90813, 90828, 90890, 90891, 90915, 90957, 90958, 90959, 90968, 91003, 91004, 91012, 91058, 91059, 91065, 91127, 91128, 91145, 91230, 91231, 91245, 91271, 91272, 91278, 91336, 91337, 91346, 91417, 91418, 91427, 91471, 91472, 91514, 91562, 91563, 91587, 91699, 91700, 91715, 91769, 91770, 91791, 91992, 91993, 92003, 92085, 92086, 92101, 92155, 92156, 92171, 92217, 92218, 92223, 92244, 92245, 92266, 92340, 92341, 92356, 92500, 92501, 93161, 93162, 93275, 93324, 93383, 93452, 93531, 93619, 93695, 93814, 93907, 94045, 94190, 94259, 94316, 94382, 94415, 94484, 94512, 94546, 94605, 94652, 94696, 94734, 94893, 94931, 94968, 94994, 95044, 95153, 95209, 95286, 95341, 95830, 95939, 95969, 96015, 96057, 96096, 96172, 96239, 96240, 96319, 96320, 96407, 96581, 96749, 96750, 96802, 96803, 97301, 97302, 97331, 97371, 97372, 97560, 97561, 97585, 97609, 97610, 97989, 97990, 98529, 98530, 98583, 98584, 98600, 98601, 99122, 99123, 100501, 100502, 101854, 101868, 101892, 101916, 101917, 102098, 102248, 102438, 102599, 102726, 102727, 102733, 102770, 102795, 102796, 102802, 102809, 102848, 102869, 102870, 104778, 104779, 106799, 106800, 107083, 107411, 107468, 108565, 108566, 109422, 109423, 109463, 109464, 109502, 109546, 109547, 109588, 109595, 109634, 109655, 109656, 109704, 109739, 109760, 109761, 109779, 109806, 109807, 109823, 109849, 109850, 110733, 110745, 110746, 111686, 111716, 111717, 111808, 111898, 111938, 112010, 112059, 112083, 112084, 112362, 112366, 112369, 112370, 112433, 112663, 112664, 112723, 112998, 112999, 113015, 113016, 113076, 113077, 113085, 113086, 113247, 113248, 113286, 113287, 113461, 113462, 113487, 113488, 113669, 113670, 113695, 113696, 113970, 113971, 113979, 113980, 114259, 114260, 114269, 114270, 114438, 114439, 114456, 114457, 114589, 114590, 114647, 114648, 114746, 114747, 114941, 114942, 115266, 115267, 115278, 115279, 115460, 115461, 116085, 116086, 116132, 116175 ], "line_end_idx": [ 16, 17, 18, 29, 30, 64, 65, 111, 112, 225, 226, 353, 354, 380, 381, 671, 672, 751, 752, 981, 982, 1425, 1426, 1491, 1492, 1600, 1601, 1722, 1879, 1880, 2032, 2033, 2244, 2245, 2256, 2257, 2330, 2331, 2463, 2464, 2540, 2541, 2649, 2650, 2786, 2787, 2820, 2821, 2848, 2849, 2946, 2947, 3048, 3049, 3115, 3116, 3244, 3245, 3322, 3323, 3352, 3353, 3433, 3434, 3523, 3524, 3594, 3595, 3657, 3658, 3688, 3689, 3823, 3824, 3928, 3929, 4024, 4025, 4173, 4174, 4427, 4428, 4466, 4467, 4574, 4575, 4612, 4613, 4636, 4685, 4722, 4801, 4848, 4909, 4954, 5048, 5049, 5116, 5117, 5182, 5183, 5265, 5266, 5491, 5492, 5928, 5929, 5961, 5962, 6106, 6107, 6113, 6114, 6444, 6445, 6576, 6577, 6698, 6699, 6865, 6866, 7254, 7255, 7358, 7359, 7445, 7446, 7468, 7469, 7510, 7511, 7643, 7740, 7937, 8146, 8317, 8318, 8510, 8511, 8671, 8672, 8756, 8757, 8913, 8914, 9018, 9019, 9049, 9050, 9082, 9083, 9175, 9176, 9355, 9356, 9470, 9471, 9557, 9558, 9642, 9643, 9736, 9737, 9774, 9775, 9883, 9884, 9956, 9957, 9958, 10086, 10087, 10195, 10196, 10431, 10432, 10502, 10503, 10569, 10570, 10910, 10911, 10976, 10977, 11086, 11087, 11208, 11209, 11270, 11271, 11325, 11326, 11364, 11365, 11419, 11420, 11584, 11585, 11716, 11717, 11864, 11865, 12002, 12003, 12431, 12432, 12476, 12477, 12598, 12599, 12973, 12974, 13012, 13013, 13120, 13121, 13663, 13664, 13741, 13742, 14058, 14059, 14248, 14499, 14582, 14654, 14655, 14880, 14881, 14954, 14955, 15209, 15210, 16098, 16099, 16154, 16155, 16402, 16403, 16546, 16547, 16652, 16653, 17248, 17249, 17394, 17395, 17754, 17755, 17893, 17894, 18084, 18085, 18117, 18118, 18465, 18466, 18666, 18667, 18768, 18769, 19052, 19053, 19330, 19331, 19380, 19381, 19456, 19457, 20052, 20053, 20156, 20157, 20300, 20301, 20566, 20567, 20608, 20609, 20684, 20685, 20784, 20785, 20833, 20834, 20966, 20967, 21016, 21017, 21136, 21137, 21279, 21280, 21517, 21518, 21535, 21536, 21553, 21554, 21623, 21624, 21887, 21888, 22155, 22156, 22666, 22667, 22700, 22701, 22727, 22728, 22993, 22994, 23259, 23260, 23482, 23483, 23733, 23734, 23884, 23885, 23935, 23936, 24019, 24020, 24021, 24119, 24120, 24216, 24217, 24450, 24451, 24629, 24646, 24692, 24693, 24781, 24782, 24803, 24804, 25111, 25112, 25193, 25194, 25228, 25229, 25652, 25653, 25685, 25686, 25749, 25750, 25810, 25811, 25858, 25859, 25899, 25900, 25932, 25933, 25997, 25998, 26057, 26058, 26529, 26530, 26591, 26592, 26860, 26861, 26910, 26911, 27401, 27402, 27443, 27444, 27893, 27894, 27927, 27928, 28617, 28618, 28906, 28907, 29270, 29271, 29635, 29636, 29801, 29802, 29988, 29989, 30152, 30159, 30160, 30199, 30200, 30410, 30411, 30462, 30463, 30494, 30495, 30641, 30642, 31313, 31314, 32717, 32718, 32889, 32890, 32924, 32925, 32989, 32990, 33050, 33051, 33087, 33088, 33149, 33150, 33316, 33317, 33411, 33412, 33848, 33849, 33876, 33877, 33957, 33958, 33964, 33965, 34319, 34320, 34454, 34455, 34995, 34996, 35296, 35297, 35712, 35713, 36313, 36314, 36334, 36335, 36372, 36373, 36428, 36429, 36540, 36541, 36698, 36699, 36777, 36778, 36845, 36846, 36898, 36899, 36941, 36942, 37059, 37060, 37208, 37209, 37243, 37244, 37273, 37274, 37367, 37368, 37557, 37558, 37648, 37649, 37685, 37686, 37721, 37722, 37774, 37775, 37776, 37813, 37814, 37910, 37911, 37982, 37983, 38060, 38061, 38155, 38156, 38253, 38254, 38354, 38355, 38434, 38435, 38526, 38527, 38572, 38573, 38611, 38612, 38661, 38662, 38802, 38803, 39005, 39006, 39025, 39050, 39051, 39063, 39064, 39074, 39075, 39111, 39112, 39136, 39475, 39703, 39981, 39982, 40183, 40466, 40638, 40639, 40777, 40789, 40790, 40831, 40914, 40975, 41089, 41116, 41151, 41163, 41185, 41186, 41462, 41463, 41896, 42145, 42157, 42158, 42184, 42469, 42470, 42630, 42690, 42755, 42771, 42783, 42889, 42890, 42973, 42981, 43007, 43032, 43033, 43283, 43295, 43296, 43306, 43601, 43609, 43657, 43685, 43823, 43894, 43928, 43962, 44233, 44778, 44786, 44813, 44863, 44875, 44876, 44886, 45139, 45147, 45164, 45178, 45200, 45224, 45239, 45240, 45489, 45490, 45568, 45619, 45645, 45646, 45859, 45925, 45949, 45975, 46000, 46033, 46068, 46240, 46241, 46273, 46300, 46326, 46349, 46378, 46405, 46575, 46576, 46642, 46669, 46694, 46756, 46782, 46805, 46828, 46847, 46852, 46885, 46886, 47028, 47029, 47035, 47432, 47447, 47462, 47478, 47494, 47508, 47509, 47525, 47616, 47617, 47624, 47739, 47804, 47859, 47890, 47891, 48091, 48099, 48154, 48178, 48224, 48236, 48253, 48297, 48309, 48310, 48318, 48645, 48708, 48867, 49089, 49331, 49458, 49459, 49483, 49520, 49532, 49552, 49553, 49629, 49637, 49678, 49679, 49708, 49730, 49750, 49762, 49768, 49773, 49775, 49835, 49836, 49847, 49870, 49888, 49893, 49895, 49908, 49953, 50034, 50116, 50117, 50379, 50583, 50591, 50604, 50655, 50737, 50738, 50760, 50781, 50786, 50828, 50829, 50970, 51058, 51242, 51250, 51280, 51324, 51329, 51331, 51368, 51369, 51785, 51786, 51964, 51965, 52020, 52053, 52099, 52376, 52384, 52385, 52415, 52432, 52454, 52459, 52464, 52466, 52543, 52544, 52644, 52656, 52674, 52679, 52680, 52804, 53051, 53052, 53175, 53176, 53389, 53390, 53413, 53433, 53460, 53490, 53523, 53560, 53590, 53642, 53675, 53730, 53731, 53739, 53752, 53806, 53829, 53889, 53894, 53972, 53978, 53979, 54278, 54279, 54446, 54447, 54600, 54601, 54658, 54882, 54883, 54953, 54977, 55016, 55036, 55041, 55065, 55071, 55076, 55077, 55093, 55094, 55294, 55295, 55309, 55310, 55530, 55531, 55737, 55738, 55745, 55746, 55977, 55978, 56168, 56169, 56179, 56180, 56387, 56388, 56405, 56406, 56610, 56611, 56879, 56880, 56923, 56924, 57255, 57256, 57257, 57516, 57517, 57548, 57584, 57613, 57627, 57628, 57907, 57908, 58144, 58145, 58246, 58247, 58444, 58445, 58780, 58781, 58890, 58891, 59136, 59137, 59203, 59204, 59484, 59485, 60375, 60376, 60496, 60497, 60651, 60652, 60742, 60743, 60855, 60856, 60906, 60907, 60983, 60984, 61115, 61116, 61341, 61342, 61484, 61485, 61740, 61741, 61864, 61865, 61907, 61908, 61943, 61976, 62012, 62050, 62051, 62100, 62101, 62259, 62260, 62626, 62667, 62827, 62904, 62905, 63081, 63082, 63305, 63306, 63730, 63731, 63770, 63792, 63955, 63956, 63999, 64000, 64841, 64842, 65165, 65166, 65552, 65553, 65890, 65891, 66002, 66003, 66331, 66332, 66448, 66449, 66624, 66625, 66857, 66858, 67886, 67887, 67955, 67956, 68000, 68001, 68026, 68084, 68145, 68146, 68259, 68260, 68348, 68349, 68942, 68943, 68979, 68980, 69351, 69352, 69540, 69541, 69868, 69869, 70323, 70324, 70738, 70739, 71041, 71042, 71104, 71105, 71464, 71465, 71824, 71825, 72001, 72002, 72093, 72094, 72280, 72281, 72343, 72344, 72415, 72416, 72661, 72662, 72712, 72713, 72763, 72764, 72865, 72866, 73141, 73142, 73385, 73386, 73420, 73421, 73580, 73581, 73763, 73764, 73890, 74019, 74131, 74254, 74255, 74256, 74425, 74426, 74485, 74486, 74573, 74574, 74617, 74618, 74707, 74708, 74755, 74756, 75086, 75087, 75190, 75191, 75292, 75293, 75412, 75413, 75523, 75524, 75655, 75656, 75736, 75737, 76237, 76238, 76514, 76515, 76697, 76698, 76724, 76725, 77831, 77832, 78597, 78598, 78705, 78726, 78727, 78905, 78906, 78939, 78940, 78950, 78963, 78975, 78976, 79048, 79049, 79083, 79092, 79110, 79120, 79139, 79162, 79171, 79189, 79197, 79214, 79224, 79235, 79252, 79262, 79263, 79497, 79498, 80056, 80057, 80191, 80192, 80331, 80332, 80367, 80368, 81010, 81011, 81907, 81908, 82308, 82309, 82363, 82364, 82424, 82425, 82468, 82469, 82604, 82605, 82654, 82655, 82688, 82689, 82722, 82751, 82876, 82877, 82910, 82911, 82939, 82940, 83046, 83047, 83063, 83064, 84027, 84028, 84263, 84264, 84386, 84387, 84408, 84425, 84525, 84621, 84651, 84761, 84835, 84925, 84999, 85090, 85142, 85206, 85264, 85291, 85339, 85372, 85489, 85536, 85577, 85633, 85680, 85741, 85810, 85864, 85899, 85937, 85966, 85993, 86037, 86067, 86100, 86130, 86184, 86243, 86320, 86362, 86383, 86449, 86508, 86539, 86582, 86622, 86660, 86702, 86723, 86747, 86813, 86878, 86969, 87010, 87049, 87122, 87196, 87270, 87298, 87406, 87466, 87544, 87601, 87651, 87729, 87786, 87865, 87945, 87995, 88061, 88153, 88219, 88274, 88339, 88392, 88436, 88491, 88492, 88568, 88569, 88583, 88652, 88653, 88771, 88772, 88795, 88861, 88862, 88869, 88967, 88968, 88980, 89150, 89151, 89165, 89186, 89187, 89207, 89266, 89267, 89290, 89291, 89302, 89362, 89363, 89377, 89427, 89428, 89445, 89498, 89499, 89559, 89712, 89713, 89725, 89791, 89792, 89802, 89915, 89916, 89931, 89993, 89994, 90017, 90106, 90107, 90124, 90178, 90179, 90195, 90225, 90226, 90240, 90422, 90423, 90447, 90508, 90509, 90522, 90599, 90600, 90610, 90680, 90681, 90697, 90730, 90731, 90741, 90812, 90813, 90828, 90890, 90891, 90915, 90957, 90958, 90959, 90968, 91003, 91004, 91012, 91058, 91059, 91065, 91127, 91128, 91145, 91230, 91231, 91245, 91271, 91272, 91278, 91336, 91337, 91346, 91417, 91418, 91427, 91471, 91472, 91514, 91562, 91563, 91587, 91699, 91700, 91715, 91769, 91770, 91791, 91992, 91993, 92003, 92085, 92086, 92101, 92155, 92156, 92171, 92217, 92218, 92223, 92244, 92245, 92266, 92340, 92341, 92356, 92500, 92501, 93161, 93162, 93275, 93324, 93383, 93452, 93531, 93619, 93695, 93814, 93907, 94045, 94190, 94259, 94316, 94382, 94415, 94484, 94512, 94546, 94605, 94652, 94696, 94734, 94893, 94931, 94968, 94994, 95044, 95153, 95209, 95286, 95341, 95830, 95939, 95969, 96015, 96057, 96096, 96172, 96239, 96240, 96319, 96320, 96407, 96581, 96749, 96750, 96802, 96803, 97301, 97302, 97331, 97371, 97372, 97560, 97561, 97585, 97609, 97610, 97989, 97990, 98529, 98530, 98583, 98584, 98600, 98601, 99122, 99123, 100501, 100502, 101854, 101868, 101892, 101916, 101917, 102098, 102248, 102438, 102599, 102726, 102727, 102733, 102770, 102795, 102796, 102802, 102809, 102848, 102869, 102870, 104778, 104779, 106799, 106800, 107083, 107411, 107468, 108565, 108566, 109422, 109423, 109463, 109464, 109502, 109546, 109547, 109588, 109595, 109634, 109655, 109656, 109704, 109739, 109760, 109761, 109779, 109806, 109807, 109823, 109849, 109850, 110733, 110745, 110746, 111686, 111716, 111717, 111808, 111898, 111938, 112010, 112059, 112083, 112084, 112362, 112366, 112369, 112370, 112433, 112663, 112664, 112723, 112998, 112999, 113015, 113016, 113076, 113077, 113085, 113086, 113247, 113248, 113286, 113287, 113461, 113462, 113487, 113488, 113669, 113670, 113695, 113696, 113970, 113971, 113979, 113980, 114259, 114260, 114269, 114270, 114438, 114439, 114456, 114457, 114589, 114590, 114647, 114648, 114746, 114747, 114941, 114942, 115266, 115267, 115278, 115279, 115460, 115461, 116085, 116086, 116132, 116175, 116192 ] }
{ "red_pajama_v2": { "ccnet_original_length": 116192, "ccnet_original_nlines": 1489, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 1, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.006413079798221588, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.036226559430360794, "rps_doc_frac_lines_end_with_ellipsis": 0.0020134199876338243, "rps_doc_frac_no_alph_words": 0.9024330377578735, "rps_doc_frac_unique_words": 0.3110688328742981, "rps_doc_mean_word_length": 6.128448963165283, "rps_doc_num_sentences": 1391, "rps_doc_symbol_to_word_ratio": 0.002447739941999316, "rps_doc_unigram_entropy": 7.397643089294434, "rps_doc_word_count": 15765, "rps_doc_frac_chars_dupe_10grams": 0.0056305998004972935, "rps_doc_frac_chars_dupe_5grams": 0.026900580152869225, "rps_doc_frac_chars_dupe_6grams": 0.016043059527873993, "rps_doc_frac_chars_dupe_7grams": 0.013248460367321968, "rps_doc_frac_chars_dupe_8grams": 0.006769139785319567, "rps_doc_frac_chars_dupe_9grams": 0.0056305998004972935, "rps_doc_frac_chars_top_2gram": 0.0031051100231707096, "rps_doc_frac_chars_top_3gram": 0.0013662499841302633, "rps_doc_frac_chars_top_4gram": 0.0011178399436175823, "rps_doc_books_importance": -11572.9677734375, "rps_doc_books_importance_length_correction": -11572.9677734375, "rps_doc_openwebtext_importance": -5399.638671875, "rps_doc_openwebtext_importance_length_correction": -5399.638671875, "rps_doc_wikipedia_importance": -4624.04443359375, "rps_doc_wikipedia_importance_length_correction": -4624.04443359375 }, "fasttext": { "dclm": 0.6814191937446594, "english": 0, "fineweb_edu_approx": 2.435610771179199, "eai_general_math": -0.000007269999969139462, "eai_open_web_math": 0.21267825365066528, "eai_web_code": 0.4874780774116516 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.162", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-4,266,172,511,691,393,000
Internet-Draft Layer 0 Types - Revision 2 October 2021 Beller, et al. Expires 28 April 2022 [Page] Workgroup: CCAMP Internet-Draft: draft-ietf-ccamp-layer0-types-ext-00 Updates: RFC9093 (if approved) Published: Intended Status: Standards Track Expires: Authors: D. Beller, Ed. Nokia S. Belotti, Ed. Nokia H. Zheng Huawei I. Busi Huawei E. Le Rouzic Orange A YANG Data Model for Layer 0 Types - Revision 2 Abstract This document defines a collection of common data types and groupings in the YANG data modeling language, which are used in several YANG modules for wavelength Division multiplexing (WDM) transport networks. The YANG module ietf-layer0-types-ext updates ietf-layer0-types defined in [RFC9093], which has been reduced in scope prior to publication to only cover spectrum management related aspects required for the YANG module ietf-wson-topology defined in [RFC9094]. To be completed Status of This Memo This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." This Internet-Draft will expire on 28 April 2022. Table of Contents 1. Introduction YANG [RFC7950] is a data modeling language used to model configuration data, state data, Remote Procedure Calls, and notifications for network management protocols such as NETCONF [RFC6241]. The YANG language supports a small set of built-in data types and provides mechanisms to derive other types from the built-in types. This document introduces a collection of common data types derived from the built-in YANG data types. The derived types and groupings are designed to be the common types applicable for modeling Traffic Engineering (TE) features as well as non-TE features (e.g., physical network configuration aspect) for Layer 0 optical networks in model(s) defined outside of this document. 1.1. Requirements Language The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119 [RFC2119]. 2. Extensions for the Layer 0 Types Module This document defines YANG module extensions for common Layer 0 types. named ietf-layer0-types-ext. This module can be used for both WSON and Flexi-grid DWDM networks but in particular is adding common types used in the context of optical impairment aware topology model in WSON and SSONs. The ietf-layer0-types-ext module contains the following YANG identities, types and groupings that can be reused in other YANG modules: transceiver-capabilities: a YANG grouping to define the transceiver capabilities (also called "modes") needed to determine optical signal compatibility. standard-mode: a YANG grouping for ITU-T G.698.2 standard mode that guarantees interoperability. organizational-mode: a YANG grouping to define transponder operational mode supported by organizations or vendors. common-explicit-mode: a YANG grouping to define the list of attributes related to optical impairments limits in case of transceiver explicit mode. This grouping should be the same used in [I-D.ietf-ccamp-dwdm-if-param-yang]. common-organizational-explicit-mode: a YANG grouping to define the common capabilities attributes limit range in case of operational mode and explicit mode. Also this grouping should be used in [I-D.ietf-ccamp-dwdm-if-param-yang]. cd-pmd-penalty: a YANG grouping to define the triplet used as entries in the list optional penalty associated with a given accumulated CD and PMD. This list of triplet cd, pmd, penalty can be used to sample the function penalty = f(CD, PMD). [Editor's note: There is still stuff from the xml template that needs to be removed] 3. Layer0 Types Revision 2 YANG CODE The YANG code is developed on GitHub and can also be found in the following CCAMP repository: https://github.com/ietf-ccamp-wg/ietf-ccamp-layer0-types-ext [Editor's note: YANG code below always has to be updated before submitting a new revision!] <CODE BEGINS> file "ietf-layer0-types-ext@2021-10-18.yang" module ietf-layer0-types-ext { namespace "urn:ietf:params:xml:ns:yang:ietf-layer0-types-ext"; prefix "l0-types-ext"; organization "IETF CCAMP Working Group"; contact "WG Web: <http://tools.ietf.org/wg/ccamp/> WG List: <mailto:ccamp@ietf.org> Editor: Dieter Beller <mailto:Dieter.Beller@nokia.com> Editor: Sergio Belotti <mailto:Sergio.Belotti@nokia.com> Editor: Italo Busi <mailto:Italo.Busi@huawei.com> Editor: Haomian Zheng <mailto:zhenghaomian@huawei.com>"; // Additional contacts TBA (contributors) description "Description to be added!!! Copyright (c) 2021 IETF Trust and the persons identified as authors of the code. All rights reserved. Redistribution and use in source and binary forms, with or without modification, is permitted pursuant to, and subject to the license terms contained in, the Simplified BSD License set forth in Section 4.c of the IETF Trust's Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info). This version of this YANG module is part of RFC XXXX; see the RFC itself for full legal notices."; revision "2021-10-18" { description "Initial Version"; reference "RFC XXXX: A YANG Data Model for Layer 0 Types - Revision 2"; } /* * Identities */ identity modulation { description "base identity for modulation type"; } identity QPSK { base modulation; description "QPSK (Quadrature Phase Shift Keying) modulation"; } identity DP-QPSK { base modulation; description "DP-QPSK (Dual Polarization Quadrature Phase Shift Keying) modulation"; } identity QAM8 { base modulation; description "8QAM (8-State Quadrature Amplitude Modulation) modulation"; } identity QAM16 { base modulation; description "QAM16 (Quadrature Amplitude Modulation)"; } identity DP-QAM8 { base modulation; description "DP-QAM8 (Dual Polarization Quadrature Amplitude Modulation)"; } identity DC-DP-QAM8 { base modulation; description "DC DP-QAM8 (Dual Carrier Dual Polarization Quadrature Amplitude Modulation)"; } identity DP-QAM16 { base modulation; description "DP-QAM16 (Dual Polarization Quadrature Amplitude Modulation)"; } identity DC-DP-QAM16 { base modulation; description "DC DP-QAM16 (Dual Carrier Dual Polarization Quadrature Amplitude Modulation)"; } identity fec-type { description "Base identity from which specific FEC (Forward Error Correction) type identities are derived."; } identity g-fec { base fec-type; description "G-FEC (Generic-FEC)"; } identity e-fec { base fec-type; description "E-FEC (Enhanced-FEC)"; } identity no-fec { base fec-type; description "No FEC"; } identity reed-solomon { base fec-type; description "Reed-Solomon error correction"; } identity hamming-code { base fec-type; description "Hamming Code error correction"; } identity golay { base fec-type; description "Golay error correction"; } identity line-coding { description "base line-coding class"; reference "ITU-T G.698.2-201811 section 7"; } identity line-coding-NRZ-2p5G { base line-coding; description "ITU-T G.698.2-201811 section 7 table 8-1"; } identity line-coding-NRZ-OTU1 { base line-coding; description "ITU-T G.698.2-201811 section 7 table 8-2"; } identity line-coding-NRZ-10G { base line-coding; description "ITU-T G.698.2-201811 section 7 table 8-3/8-5"; } identity line-coding-NRZ-OTU2 { base line-coding; description "ITU-T G.698.2-201811 section 7 table 8-4/8-6"; } identity wavelength-assignment { description "Wavelength selection base"; reference "RFC6163:Framework for GMPLS and Path Computation Element (PCE) Control of Wavelength Switched Optical Networks (WSONs)"; } identity unspecified-wavelength-assignment { base wavelength-assignment; description "No method specified"; } identity first-fit-wavelength-assignment { base wavelength-assignment; description "All the available wavelengths are numbered, and this WA (Wavelength Assignment) method chooses the available wavelength with the lowest index"; } identity random-wavelength-assignment { base wavelength-assignment; description "This WA method chooses an available wavelength randomly"; } identity least-loaded-wavelength-assignment { base wavelength-assignment; description "This WA method selects the wavelength that has the largest residual capacity on the most loaded link along the route (in multi-fiber networks)"; } identity term-type { description "Termination type"; reference "ITU-T G.709: Interfaces for the Optical Transport Network"; } identity term-phys { base term-type; description "Physical layer termination"; } identity term-otu { base term-type; description "OTU (Optical Transport Unit) termination"; } identity term-odu { base term-type; description "ODU (Optical Data Unit) termination"; } identity term-opu { base term-type; description "OPU (Optical Payload Unit) termination"; } identity otu-type { description "Base identity from which specific OTU identities are derived"; reference "ITU-T G.709: Interfaces for the Optical Transport Network"; } identity OTU1 { base otu-type; description "OTU1 (2.66 Gb/s)"; } identity OTU1e { base otu-type; description "OTU1e (11.04 Gb/s)"; } identity OTU1f { base otu-type; description "OTU1f (11.27 Gb/s)"; } identity OTU2 { base otu-type; description "OTU2 (10.70 Gb/s)"; } identity OTU2e { base otu-type; description "OTU2e (11.09 Gb/s)"; } identity OTU2f { base otu-type; description "OTU2f (11.31G)"; } identity OTU3 { base otu-type; description "OTU3 (43.01 Gb/s)"; } identity OTU3e1 { base otu-type; description "OTU3e1 (44.57 Gb/s)"; } identity OTU3e2 { base otu-type; description "OTU3e2 (44.58 Gb/s)"; } identity OTU4 { base otu-type; description "OTU4 (111.80 Gb/s)"; } identity OTUCn { base otu-type; description "OTUCn (n x 105.25 Gb/s)"; } identity type-power-mode { description "power equalization mode used within the OMS and its elements"; } identity power-spectral-density { base type-power-mode; description "all elements must use power spectral density (W/Hz)"; } identity carrier-power { base type-power-mode; description "all elements must use power (dBm)"; } /* * Typedefs */ typedef operational-mode { type string; description "Organization/vendor specific mode that guarantees interoperability."; reference "ITU-T G.698.2 (11/2018)"; } typedef standard-mode { type string; description "ITU-T G.698.2 standard mode that guarantees interoperability. It must be an string with the following format: B-DScW-ytz(v) where all these attributes are conformant to the ITU-T recomendation"; reference "ITU-T G.698.2 (11/2018)"; } typedef organization-identifier { type string; description "vendor/organization identifier that uses a private mode out of already defined in G.698.2 ITU-T application-code"; reference "RFC7581: Routing and Wavelength Assignment Information Encoding for Wavelength Switched Optical Networks"; } typedef frequency-thz { type decimal64 { fraction-digits 6; } units THz; description "The DWDM frequency in THz, e.g., 193.112500"; reference "RFC6205: Generalized Labels for Lambda-Switch-Capable (LSC) Label Switching Routers"; } typedef frequency-ghz { type decimal64 { fraction-digits 3; } units GHz; description "The DWDM frequency in GHz, e.g., 193112.500"; reference "RFC6205: Generalized Labels for Lambda-Switch-Capable (LSC) Label Switching Routers"; } typedef dbm-t { type int32; units ".01dbm"; description "Amplifiers and Transceivers Power in dBm."; } typedef snr { type decimal64 { fraction-digits 2; } units "dB@0.1nm"; description "(Optical) Signal to Noise Ratio measured over 0.1 nm resolution bandwidth"; } typedef fiber-type { type enumeration { enum G.652 { description "G.652 Standard Singlemode Fiber"; } enum G.654 { description "G.654 Cutoff Shifted Fiber"; } enum G.653 { description "G.653 Dispersion Shifted Fiber"; } enum G.655 { description "G.655 Non-Zero Dispersion Shifted Fiber"; } enum G.656 { description "G.656 Non-Zero Dispersion for Wideband Optical Transport"; } enum G.657 { description "G.657 Bend-Insensitive Fiber"; } } description "ITU-T based fiber-types"; } /* * Groupings */ /* supported inverse multiplexing capabilities such as max. OTSiG:OTSi cardinality It is a transponder attribute not transceiver */ /* leaf multiplexing-cap { type uint32; config false; description "supported inverse multiplexing capabilities such as max. OTSiG:OTSi cardinality"; } */ grouping transceiver-capabilities { description "This grouping is intended to be use for reporting the capabilities of a transceiver."; container supported-modes { description "Transceiver's supported modes."; list supported-mode { key "mode-id"; config false; description "list of supported transceiver's modes."; leaf mode-id { type string { length "1..255"; } description "ID for the supported transceiver's mode."; } choice mode { mandatory true; description "Indicates whether the transceiver's mode is a standard mode, an organizational mode or an explicit mode."; case G.698.2 { uses standard-mode; } case organizational-mode { container organizational-mode { description "The set of attributes for an organizational mode"; uses organizational-mode; uses common-organizational-explicit-mode; } // container organizational-mode } case explicit-mode { container explicit-mode { description "The set of attributes for an explicit mode"; container supported-modes { description "Container for all the standard and organizational modes supported by the transceiver's explicit mode."; leaf-list supported-application-codes { type leafref { path "../../../mode-id"; } must "../../../../" + "supported-mode[mode-id=current()]/" + "standard-mode" { description "The pointer is only for application codes supported by transceiver."; } description "List of pointers to the application codes supported by the transceiver's explicit mode."; } leaf-list supported-organizational-modes { type leafref { path "../../../mode-id"; } must "../../../../" + "supported-mode[mode-id=current()]/" + "organizational-mode" { description "The pointer is only for organizational modes supported by transceiver."; } description "List of pointers to the organizational modes supported by the transceiver's explicit mode."; } } // container supported-modes uses common-explicit-mode; uses common-organizational-explicit-mode; } // container explicit-mode } // end of case explicit-mode } // end of choice } // list supported-modes } // container supported-modes } // grouping transceiver-capabilities grouping standard-mode { description "ITU-T G.698.2 standard mode that guarantees interoperability. It must be an string with the following format: B-DScW-ytz(v) where all these attributes are conformant to the ITU-T recomendation"; leaf standard-mode { type standard-mode; config false; description "G.698.2 standard mode"; } } grouping organizational-mode { description "Transponder operational mode supported by organizations or vendor"; leaf operational-mode { type operational-mode; config false; description "configured organization- or vendor-specific application identifiers (AI) supported by the transponder"; } leaf organization-identifier { type organization-identifier; config false; description "organization identifier that uses organizational mode"; } } grouping cd-pmd-penalty { description "entries of table; triplet chromatic dispersion, polarization mode dispersion and associated penalty"; leaf chromatic-dispersion { type decimal64 { fraction-digits 2; range "0..max"; } units "ps/nm"; config false; mandatory true; description "chromatic dispersion"; } leaf polarization-mode-dispersion { type decimal64 { fraction-digits 2; range "0..max"; } units "ps"; config false; mandatory true; description "Polarization mode dispersion"; } leaf penalty { type decimal64 { fraction-digits 2; range "0..max"; } units "dB"; config false; mandatory true; description "Associated penalty on the receiver"; } } grouping pdl-penalty { description "entries of table; pair of values polarization dependent loss and associated penalty"; leaf max-polarization-dependent-loss { type decimal64 { fraction-digits 2; } units "dB"; config false; mandatory true; description "Maximum acceptable accumulate polarization dependent loss"; } leaf penalty { type uint8; units "dB"; config false; mandatory true; description "Associated penalty on the receiver"; } } /* * This grouping represent the list of attributes related to * optical impairment limits for explicit mode * (min OSNR, max PMD, max CD, max PDL, Q-factor limit, etc.) * In case of standard and operational mode the attributes are * implicit */ grouping common-explicit-mode { description "Attributes capabilities related to explicit mode of an optical transceiver"; leaf line-coding-bitrate { type identityref { base line-coding; } config false; description "Bit rate/line coding of optical tributary signal"; reference "ITU-T G.698.2 section 7.1.2"; } leaf max-polarization-mode-dispersion { type decimal64 { fraction-digits 2; range "0..max"; } units "ps"; config false; description "Maximum acceptable accumulated polarization mode dispersion on the receiver"; } leaf max-chromatic-dispersion { type decimal64 { fraction-digits 2; range "0..max"; } units "ps/nm"; config false; description "Maximum acceptable accumulated chromatic dispersion on the receiver"; } list chromatic-and-polarization-dispersion-penalty { config false; description "Optional penalty associated with a given accumulated CD and PMD. This list of triplet cd, pmd, penalty can be used to sample the function penalty = f(CD, PMD)."; uses cd-pmd-penalty ; } leaf max-diff-group-delay { type int32; config false; description "Maximum Differential group delay of this mode for this lane"; } list max-polarization-dependent-loss-penalty { config false; description "Optional penalty associated with the maximum acceptable accumulated polarization dependent loss. This list of pair pdl and penalty can be used to sample the function pdl = f(penalty)."; uses pdl-penalty ; } leaf available-modulation-type { type identityref { base modulation; } config false; description "Modulation type the specific transceiver in the list can support"; } leaf min-OSNR { type snr; config false; description "min OSNR measured over 0.1 nm resolution bandwidth: if received OSNR at minimum Rx-power is lower than MIN-OSNR, an increased level of bit-errors post-FEC needs to be expected."; // change resolution BW from 12.5 GHz to 0.1 nm } leaf min-Q-factor { type int32; units "dB"; config false; description "min Qfactor at FEC threshold"; } leaf available-baud-rate { type uint32; units Bd; config false; description "Baud-rate the specific transceiver in the list can support. Baud-rate is the unit for symbol rate or modulation rate in symbols per second or pulses per second. It is the number of distinct symbol changes (signal events) made to the transmission medium per second in a digitally modulated signal or a line code"; } leaf roll-off { type decimal64 { fraction-digits 4; range "0..1"; } config false; description "the roll-off factor (beta with values from 0 to 1) identifies how the real signal shape exceed the baud rate. If=0 it is exactly matching the baud rate.If=1 the signal exceeds the 50% of the baud rate at each side."; } leaf min-carrier-spacing { type frequency-ghz; config false; description "This attribute specifies the minimum nominal difference between the carrier frequencies of two homogeneous OTSis (which have the same optical characteristics but the central frequencies) such that if they are placed next to each other the interference due to spectrum overlap between them can be considered negligible. In case of heterogeneous OTSi it is up to path computation engine to determine the minimum distance between the carrier frequency of the two adjacent OTSi."; } leaf available-fec-type { type identityref { base fec-type; } config false; description "Available FEC"; } leaf fec-code-rate { type decimal64 { fraction-digits 8; range "0..max"; } config false; description "FEC-code-rate"; } leaf fec-threshold { type decimal64 { fraction-digits 8; range "0..max"; } config false; description "Threshold on the BER, for which FEC is able to correct errors"; } } // grouping common-explicit-mode grouping common-organizational-explicit-mode { description "Common capability attributes limit range in case of operational mode and explicit mode. These attributes are supported separately in case of application codes"; /* transmitter tuning range (f_tx-min, f_tx-max) */ leaf min-central-frequency { type frequency-thz; config false; description "This parameter indicates the minimum frequency for the transmitter tuning range."; } leaf max-central-frequency { type frequency-thz; config false; description "This parameter indicates the maximum frequency for the transmitter tuning range."; } /* transmitter-tunability-grid */ leaf central-frequency-step { type frequency-ghz; config false; description "This parameter indicates the transmitter tunability grid as the distance between two adjacent carrier frequencies of the transmitter tuning range."; } /* supported transmitter power range [p_tx-min, p_tx_max] */ leaf tx-channel-power-min { type dbm-t; config false; description "The minimum output power of this interface"; } leaf tx-channel-power-max { type dbm-t; config false; description "The maximum output power of this interface"; } /* supported receiver power range [p_rx-min, p_rx_max] */ leaf rx-channel-power-min { type dbm-t; config false; description "The minimum input power of this interface"; } leaf rx-channel-power-max { type dbm-t; config false; description "The maximum input power of this interface"; } leaf rx-total-power-max { type dbm-t; config false; description "Maximum rx optical power for all the channels"; } } // grouping common-organizational-explicit-mode /* This grouping represent the list of configured parameters */ /* values independent of operational mode */ grouping common-transceiver-configured-param { description "Capability of an optical transceiver"; leaf otsi-carrier-frequency { type frequency-thz; description "OTSi carrier frequency, equivalent to the actual configured transmitter frequency"; } leaf tx-channel-power { type dbm-t; description "The current channel transmit power"; } leaf rx-channel-power { type dbm-t; config false; description "The current channel received power "; } leaf rx-total-power { type dbm-t; config false; description "Current total received power"; } } // grouping for configured attributes out of mode grouping l0-tunnel-attributes { description "Parameters for Layer0 (WSON or Flexi-Grid) Tunnels."; leaf fec-type { type identityref { base fec-type; } description "FEC type."; } leaf termination-type { type identityref { base term-type; } description "Termination type."; } leaf bit-stuffing { type boolean; description "Bit stuffing enabled/disabled."; } } grouping l0-path-constraints { description "Global named path constraints configuration grouping for Layer0 (WSON or Flexi-Grid) paths."; leaf wavelength-assignment { type identityref { base wavelength-assignment; } description "Wavelength Allocation Method"; } } grouping frequency-range { description "The parameters that define a frequency range."; leaf lower-frequency { type frequency-thz; mandatory true; description "The lower frequency boundary of the frequency range."; } leaf upper-frequency { type frequency-thz; must '. > ../lower-frequency' { error-message "The upper frequency must be greater than the lower frequency."; } mandatory true; description "The upper frequency boundary of the frequency range."; } } } <CODE ENDS> Figure 1 4. Acknowledgements To be added if any. 5. Contributors Gabriele Galimberti Cisco Email: ggalimbe@cisco.com Enrico Griseri Nokia Email: Enrico.Griseri@nokia.com Aihua Guo Futurewei Email: aihuaguo@futurewei.com 6. IANA Considerations This memo includes no request to IANA. All drafts are required to have an IANA considerations section (see Guidelines for Writing an IANA Considerations Section in RFCs [RFC5226] for a guide). If the draft does not require IANA to do anything, the section contains an explicit statement that this is the case (as above). If there are no requirements for IANA, the section will be removed during conversion into an RFC by the RFC Editor. 7. Security Considerations All drafts are required to have a security considerations section. See RFC 3552 [RFC3552] for a guide. 8. References 8.1. Normative References [I-D.ietf-ccamp-optical-impairment-topology-yang] Lee, Y., Rouzic, E. L., Lopez, V., Galimberti, G., and D. Beller, "A YANG Data Model for Optical Impairment-aware Topology", Work in Progress, Internet-Draft, draft-ietf-ccamp-optical-impairment-topology-yang-07, , <https://datatracker.ietf.org/doc/html/draft-ietf-ccamp-optical-impairment-topology-yang-07>. [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, , <https://www.rfc-editor.org/info/rfc2119>. [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., and A. Bierman, Ed., "Network Configuration Protocol (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, , <https://www.rfc-editor.org/info/rfc6241>. [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", RFC 7950, DOI 10.17487/RFC7950, , <https://www.rfc-editor.org/info/rfc7950>. [RFC8795] Liu, X., Bryskin, I., Beeram, V., Saad, T., Shah, H., and O. Gonzalez de Dios, "YANG Data Model for Traffic Engineering (TE) Topologies", RFC 8795, DOI 10.17487/RFC8795, , <https://www.rfc-editor.org/info/rfc8795>. [RFC9093] Zheng, H., Lee, Y., Guo, A., Lopez, V., and D. King, "A YANG Data Model for Layer 0 Types", RFC 9093, DOI 10.17487/RFC9093, , <https://www.rfc-editor.org/info/rfc9093>. [RFC9094] Zheng, H., Lee, Y., Guo, A., Lopez, V., and D. King, "A YANG Data Model for Wavelength Switched Optical Networks (WSONs)", RFC 9094, DOI 10.17487/RFC9094, , <https://www.rfc-editor.org/info/rfc9094>. 8.2. Informative References [I-D.ietf-ccamp-dwdm-if-param-yang] Galimberti, G., Kunze, R., Burk, A., Hiremagalur, D., and G. Grammel, "A YANG model to manage the optical interface parameters for an external transponder in a WDM network", Work in Progress, Internet-Draft, draft-ietf-ccamp-dwdm-if-param-yang-06, , <https://datatracker.ietf.org/doc/html/draft-ietf-ccamp-dwdm-if-param-yang-06>. [RFC2629] Rose, M., "Writing I-Ds and RFCs using XML", RFC 2629, DOI 10.17487/RFC2629, , <https://www.rfc-editor.org/info/rfc2629>. [RFC3552] Rescorla, E. and B. Korver, "Guidelines for Writing RFC Text on Security Considerations", BCP 72, RFC 3552, DOI 10.17487/RFC3552, , <https://www.rfc-editor.org/info/rfc3552>. [RFC5226] Narten, T. and H. Alvestrand, "Guidelines for Writing an IANA Considerations Section in RFCs", RFC 5226, DOI 10.17487/RFC5226, , <https://www.rfc-editor.org/info/rfc5226>. Authors' Addresses Dieter Beller (editor) Nokia Sergio Belotti (editor) Nokia Haomian Zheng Huawei Italo Busi Huawei Esther Le Rouzic Orange
{ "url": "https://ftp.nordu.net/pub/ietf/internet-drafts/draft-ietf-ccamp-layer0-types-ext-01.html", "source_domain": "ftp.nordu.net", "snapshot_id": "crawl=CC-MAIN-2021-49", "warc_metadata": { "Content-Length": "80360", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:EAUNMK3U4Q7UFAFLVCGIYSSWBSE57OCL", "WARC-Concurrent-To": "<urn:uuid:1a20033b-b770-4c93-9c30-5aa9a26e119e>", "WARC-Date": "2021-12-05T13:36:15Z", "WARC-IP-Address": "109.105.110.53", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:XHNKS2GZHKDH7FHMKIETP7KE27UQUIRX", "WARC-Record-ID": "<urn:uuid:ebf82548-0866-4108-bd00-f07279845bc0>", "WARC-Target-URI": "https://ftp.nordu.net/pub/ietf/internet-drafts/draft-ietf-ccamp-layer0-types-ext-01.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:e7490c44-0547-4265-bea1-17de9c70bae9>" }, "warc_info": "isPartOf: CC-MAIN-2021-49\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November/December 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-6\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 55, 99, 110, 116, 132, 169, 178, 200, 211, 228, 244, 253, 262, 277, 283, 299, 305, 314, 321, 329, 336, 349, 356, 357, 406, 407, 416, 417, 884, 885, 901, 902, 922, 923, 1018, 1019, 1273, 1274, 1534, 1535, 1585, 1586, 1604, 1605, 1621, 1622, 1946, 1947, 2323, 2324, 2351, 2352, 2556, 2557, 2600, 2601, 3026, 3027, 3053, 3054, 3181, 3182, 3197, 3198, 3280, 3281, 3302, 3303, 3397, 3398, 3420, 3421, 3624, 3625, 3662, 3663, 3857, 3858, 3874, 3875, 4101, 4102, 4187, 4188, 4225, 4226, 4320, 4321, 4382, 4383, 4475, 4476, 4535, 4566, 4631, 4656, 4657, 4672, 4704, 4714, 4761, 4799, 4800, 4827, 4867, 4868, 4896, 4937, 4938, 4962, 5000, 5001, 5028, 5070, 5071, 5118, 5119, 5133, 5165, 5166, 5228, 5279, 5280, 5341, 5401, 5464, 5526, 5575, 5620, 5621, 5684, 5730, 5731, 5757, 5773, 5798, 5812, 5880, 5884, 5885, 5888, 5902, 5906, 5907, 5931, 5984, 5988, 5989, 6007, 6028, 6044, 6101, 6105, 6106, 6127, 6148, 6164, 6209, 6249, 6253, 6254, 6272, 6293, 6309, 6376, 6380, 6381, 6400, 6421, 6437, 6486, 6490, 6491, 6512, 6533, 6549, 6618, 6622, 6623, 6647, 6668, 6684, 6745, 6776, 6780, 6781, 6803, 6824, 6840, 6896, 6917, 6921, 6922, 6947, 6968, 6984, 7046, 7077, 7081, 7082, 7104, 7120, 7165, 7229, 7233, 7234, 7253, 7272, 7288, 7317, 7321, 7340, 7359, 7375, 7405, 7409, 7429, 7448, 7464, 7480, 7484, 7485, 7511, 7530, 7546, 7585, 7589, 7590, 7616, 7635, 7651, 7690, 7694, 7695, 7714, 7733, 7777, 7781, 7782, 7807, 7823, 7855, 7869, 7909, 7913, 7914, 7948, 7970, 7986, 8036, 8040, 8041, 8075, 8097, 8113, 8163, 8167, 8168, 8201, 8223, 8239, 8293, 8297, 8298, 8332, 8354, 8370, 8424, 8428, 8429, 8464, 8480, 8515, 8529, 8593, 8663, 8667, 8668, 8715, 8747, 8763, 8792, 8796, 8797, 8842, 8874, 8890, 8941, 8999, 9055, 9059, 9060, 9102, 9134, 9150, 9193, 9222, 9226, 9227, 9275, 9307, 9323, 9373, 9433, 9489, 9493, 9494, 9517, 9533, 9559, 9573, 9640, 9644, 9645, 9668, 9688, 9704, 9740, 9744, 9745, 9767, 9787, 9803, 9853, 9857, 9858, 9880, 9900, 9916, 9961, 9965, 9966, 9988, 10008, 10024, 10072, 10076, 10077, 10099, 10115, 10185, 10199, 10266, 10270, 10271, 10289, 10308, 10324, 10350, 10354, 10355, 10374, 10393, 10409, 10437, 10441, 10442, 10461, 10480, 10496, 10524, 10528, 10529, 10547, 10566, 10582, 10609, 10613, 10614, 10633, 10652, 10668, 10696, 10700, 10701, 10720, 10739, 10755, 10779, 10783, 10784, 10802, 10821, 10837, 10864, 10868, 10869, 10889, 10908, 10924, 10953, 10957, 10958, 10978, 10997, 11013, 11042, 11046, 11047, 11065, 11084, 11100, 11128, 11132, 11133, 11152, 11171, 11187, 11220, 11224, 11225, 11254, 11270, 11317, 11347, 11351, 11352, 11388, 11414, 11430, 11491, 11495, 11496, 11523, 11549, 11565, 11608, 11612, 11613, 11616, 11628, 11632, 11633, 11662, 11679, 11695, 11752, 11778, 11819, 11823, 11824, 11850, 11867, 11883, 11934, 11959, 12014, 12062, 12084, 12120, 12161, 12165, 12166, 12202, 12219, 12235, 12298, 12363, 12377, 12439, 12498, 12502, 12503, 12529, 12552, 12579, 12587, 12604, 12622, 12677, 12693, 12734, 12796, 12800, 12826, 12849, 12876, 12884, 12901, 12919, 12974, 12990, 13031, 13093, 13097, 13098, 13116, 13132, 13152, 13168, 13219, 13223, 13224, 13240, 13261, 13286, 13292, 13314, 13330, 13390, 13419, 13423, 13424, 13447, 13470, 13489, 13542, 13550, 13569, 13619, 13627, 13646, 13700, 13708, 13727, 13790, 13798, 13817, 13877, 13912, 13920, 13939, 13991, 13999, 14005, 14021, 14054, 14058, 14059, 14062, 14075, 14079, 14080, 14136, 14168, 14218, 14223, 14224, 14255, 14274, 14292, 14355, 14400, 14406, 14411, 14412, 14450, 14466, 14527, 14567, 14568, 14600, 14618, 14660, 14688, 14711, 14733, 14795, 14818, 14842, 14871, 14883, 14949, 14959, 14981, 15007, 15029, 15097, 15162, 15187, 15219, 15231, 15268, 15312, 15338, 15406, 15446, 15502, 15550, 15562, 15593, 15631, 15658, 15721, 15763, 15791, 15860, 15925, 15952, 16008, 16041, 16086, 16106, 16144, 16204, 16245, 16277, 16342, 16393, 16413, 16443, 16506, 16575, 16593, 16652, 16685, 16730, 16750, 16788, 16848, 16895, 16927, 16995, 17046, 17066, 17096, 17162, 17231, 17249, 17295, 17336, 17392, 17434, 17475, 17502, 17535, 17571, 17613, 17614, 17641, 17657, 17726, 17781, 17844, 17880, 17881, 17906, 17932, 17952, 17970, 18003, 18009, 18013, 18014, 18047, 18063, 18129, 18145, 18146, 18174, 18203, 18223, 18241, 18294, 18363, 18369, 18404, 18440, 18460, 18478, 18534, 18550, 18556, 18560, 18561, 18589, 18642, 18691, 18716, 18717, 18749, 18772, 18799, 18823, 18831, 18852, 18872, 18894, 18936, 18942, 18982, 19005, 19032, 19056, 19064, 19082, 19102, 19124, 19174, 19180, 19199, 19222, 19249, 19273, 19281, 19299, 19319, 19341, 19397, 19403, 19407, 19408, 19433, 19449, 19517, 19548, 19549, 19592, 19615, 19642, 19650, 19668, 19688, 19710, 19728, 19797, 19803, 19822, 19840, 19858, 19878, 19900, 19956, 19962, 19966, 19967, 19970, 20031, 20078, 20140, 20203, 20215, 20219, 20220, 20254, 20306, 20352, 20353, 20384, 20409, 20435, 20443, 20463, 20533, 20549, 20588, 20594, 20638, 20661, 20688, 20712, 20720, 20738, 20758, 20776, 20834, 20872, 20878, 20914, 20937, 20964, 20988, 20996, 21017, 21037, 21055, 21116, 21143, 21149, 21206, 21226, 21244, 21306, 21327, 21389, 21442, 21470, 21476, 21509, 21532, 21557, 21627, 21667, 21673, 21724, 21744, 21762, 21827, 21876, 21934, 21983, 22008, 22014, 22051, 22076, 22099, 22107, 22127, 22145, 22207, 22230, 22236, 22257, 22273, 22293, 22342, 22370, 22437, 22491, 22515, 22569, 22575, 22600, 22618, 22636, 22656, 22706, 22712, 22743, 22762, 22778, 22798, 22816, 22863, 22893, 22928, 22968, 23002, 23030, 23075, 23120, 23149, 23184, 23227, 23233, 23253, 23276, 23303, 23325, 23333, 23353, 23371, 23431, 23483, 23534, 23584, 23629, 23635, 23666, 23692, 23712, 23730, 23795, 23860, 23929, 23998, 24067, 24098, 24099, 24166, 24235, 24281, 24287, 24317, 24342, 24365, 24373, 24393, 24428, 24434, 24459, 24482, 24509, 24533, 24541, 24561, 24596, 24602, 24627, 24650, 24677, 24701, 24709, 24729, 24747, 24792, 24829, 24835, 24872, 24873, 24922, 24980, 25031, 25080, 25112, 25113, 25165, 25166, 25199, 25225, 25245, 25263, 25327, 25363, 25369, 25402, 25428, 25448, 25466, 25530, 25566, 25572, 25573, 25607, 25608, 25642, 25668, 25688, 25706, 25775, 25840, 25880, 25886, 25887, 25948, 25949, 25981, 25999, 26019, 26083, 26089, 26121, 26139, 26159, 26223, 26229, 26230, 26288, 26289, 26322, 26340, 26360, 26423, 26429, 26461, 26479, 26499, 26562, 26568, 26569, 26599, 26617, 26637, 26685, 26710, 26716, 26717, 26769, 26770, 26834, 26879, 26880, 26929, 26985, 26986, 27020, 27048, 27069, 27123, 27176, 27182, 27210, 27230, 27288, 27294, 27322, 27342, 27364, 27423, 27429, 27455, 27475, 27497, 27549, 27555, 27609, 27610, 27644, 27660, 27721, 27741, 27766, 27789, 27797, 27815, 27836, 27842, 27870, 27895, 27919, 27927, 27945, 27974, 27980, 28004, 28024, 28042, 28084, 28090, 28094, 28095, 28128, 28144, 28195, 28252, 28285, 28310, 28346, 28354, 28404, 28410, 28414, 28415, 28444, 28460, 28515, 28542, 28568, 28590, 28608, 28653, 28680, 28686, 28713, 28739, 28777, 28799, 28861, 28884, 28892, 28914, 28932, 28977, 29004, 29010, 29014, 29016, 29028, 29029, 29038, 29039, 29059, 29060, 29080, 29081, 29097, 29098, 29118, 29124, 29125, 29151, 29152, 29167, 29173, 29174, 29206, 29207, 29217, 29227, 29228, 29258, 29259, 29282, 29283, 29322, 29323, 29721, 29722, 29749, 29750, 29853, 29854, 29868, 29869, 29895, 29896, 29946, 30255, 30265, 30423, 30433, 30634, 30644, 30780, 30790, 31005, 31015, 31184, 31194, 31394, 31395, 31423, 31424, 31460, 31790, 31800, 31922, 31932, 32107, 32117, 32289, 32290, 32309, 32310, 32333, 32339, 32363, 32369, 32383, 32390, 32401, 32408, 32425 ], "line_end_idx": [ 55, 99, 110, 116, 132, 169, 178, 200, 211, 228, 244, 253, 262, 277, 283, 299, 305, 314, 321, 329, 336, 349, 356, 357, 406, 407, 416, 417, 884, 885, 901, 902, 922, 923, 1018, 1019, 1273, 1274, 1534, 1535, 1585, 1586, 1604, 1605, 1621, 1622, 1946, 1947, 2323, 2324, 2351, 2352, 2556, 2557, 2600, 2601, 3026, 3027, 3053, 3054, 3181, 3182, 3197, 3198, 3280, 3281, 3302, 3303, 3397, 3398, 3420, 3421, 3624, 3625, 3662, 3663, 3857, 3858, 3874, 3875, 4101, 4102, 4187, 4188, 4225, 4226, 4320, 4321, 4382, 4383, 4475, 4476, 4535, 4566, 4631, 4656, 4657, 4672, 4704, 4714, 4761, 4799, 4800, 4827, 4867, 4868, 4896, 4937, 4938, 4962, 5000, 5001, 5028, 5070, 5071, 5118, 5119, 5133, 5165, 5166, 5228, 5279, 5280, 5341, 5401, 5464, 5526, 5575, 5620, 5621, 5684, 5730, 5731, 5757, 5773, 5798, 5812, 5880, 5884, 5885, 5888, 5902, 5906, 5907, 5931, 5984, 5988, 5989, 6007, 6028, 6044, 6101, 6105, 6106, 6127, 6148, 6164, 6209, 6249, 6253, 6254, 6272, 6293, 6309, 6376, 6380, 6381, 6400, 6421, 6437, 6486, 6490, 6491, 6512, 6533, 6549, 6618, 6622, 6623, 6647, 6668, 6684, 6745, 6776, 6780, 6781, 6803, 6824, 6840, 6896, 6917, 6921, 6922, 6947, 6968, 6984, 7046, 7077, 7081, 7082, 7104, 7120, 7165, 7229, 7233, 7234, 7253, 7272, 7288, 7317, 7321, 7340, 7359, 7375, 7405, 7409, 7429, 7448, 7464, 7480, 7484, 7485, 7511, 7530, 7546, 7585, 7589, 7590, 7616, 7635, 7651, 7690, 7694, 7695, 7714, 7733, 7777, 7781, 7782, 7807, 7823, 7855, 7869, 7909, 7913, 7914, 7948, 7970, 7986, 8036, 8040, 8041, 8075, 8097, 8113, 8163, 8167, 8168, 8201, 8223, 8239, 8293, 8297, 8298, 8332, 8354, 8370, 8424, 8428, 8429, 8464, 8480, 8515, 8529, 8593, 8663, 8667, 8668, 8715, 8747, 8763, 8792, 8796, 8797, 8842, 8874, 8890, 8941, 8999, 9055, 9059, 9060, 9102, 9134, 9150, 9193, 9222, 9226, 9227, 9275, 9307, 9323, 9373, 9433, 9489, 9493, 9494, 9517, 9533, 9559, 9573, 9640, 9644, 9645, 9668, 9688, 9704, 9740, 9744, 9745, 9767, 9787, 9803, 9853, 9857, 9858, 9880, 9900, 9916, 9961, 9965, 9966, 9988, 10008, 10024, 10072, 10076, 10077, 10099, 10115, 10185, 10199, 10266, 10270, 10271, 10289, 10308, 10324, 10350, 10354, 10355, 10374, 10393, 10409, 10437, 10441, 10442, 10461, 10480, 10496, 10524, 10528, 10529, 10547, 10566, 10582, 10609, 10613, 10614, 10633, 10652, 10668, 10696, 10700, 10701, 10720, 10739, 10755, 10779, 10783, 10784, 10802, 10821, 10837, 10864, 10868, 10869, 10889, 10908, 10924, 10953, 10957, 10958, 10978, 10997, 11013, 11042, 11046, 11047, 11065, 11084, 11100, 11128, 11132, 11133, 11152, 11171, 11187, 11220, 11224, 11225, 11254, 11270, 11317, 11347, 11351, 11352, 11388, 11414, 11430, 11491, 11495, 11496, 11523, 11549, 11565, 11608, 11612, 11613, 11616, 11628, 11632, 11633, 11662, 11679, 11695, 11752, 11778, 11819, 11823, 11824, 11850, 11867, 11883, 11934, 11959, 12014, 12062, 12084, 12120, 12161, 12165, 12166, 12202, 12219, 12235, 12298, 12363, 12377, 12439, 12498, 12502, 12503, 12529, 12552, 12579, 12587, 12604, 12622, 12677, 12693, 12734, 12796, 12800, 12826, 12849, 12876, 12884, 12901, 12919, 12974, 12990, 13031, 13093, 13097, 13098, 13116, 13132, 13152, 13168, 13219, 13223, 13224, 13240, 13261, 13286, 13292, 13314, 13330, 13390, 13419, 13423, 13424, 13447, 13470, 13489, 13542, 13550, 13569, 13619, 13627, 13646, 13700, 13708, 13727, 13790, 13798, 13817, 13877, 13912, 13920, 13939, 13991, 13999, 14005, 14021, 14054, 14058, 14059, 14062, 14075, 14079, 14080, 14136, 14168, 14218, 14223, 14224, 14255, 14274, 14292, 14355, 14400, 14406, 14411, 14412, 14450, 14466, 14527, 14567, 14568, 14600, 14618, 14660, 14688, 14711, 14733, 14795, 14818, 14842, 14871, 14883, 14949, 14959, 14981, 15007, 15029, 15097, 15162, 15187, 15219, 15231, 15268, 15312, 15338, 15406, 15446, 15502, 15550, 15562, 15593, 15631, 15658, 15721, 15763, 15791, 15860, 15925, 15952, 16008, 16041, 16086, 16106, 16144, 16204, 16245, 16277, 16342, 16393, 16413, 16443, 16506, 16575, 16593, 16652, 16685, 16730, 16750, 16788, 16848, 16895, 16927, 16995, 17046, 17066, 17096, 17162, 17231, 17249, 17295, 17336, 17392, 17434, 17475, 17502, 17535, 17571, 17613, 17614, 17641, 17657, 17726, 17781, 17844, 17880, 17881, 17906, 17932, 17952, 17970, 18003, 18009, 18013, 18014, 18047, 18063, 18129, 18145, 18146, 18174, 18203, 18223, 18241, 18294, 18363, 18369, 18404, 18440, 18460, 18478, 18534, 18550, 18556, 18560, 18561, 18589, 18642, 18691, 18716, 18717, 18749, 18772, 18799, 18823, 18831, 18852, 18872, 18894, 18936, 18942, 18982, 19005, 19032, 19056, 19064, 19082, 19102, 19124, 19174, 19180, 19199, 19222, 19249, 19273, 19281, 19299, 19319, 19341, 19397, 19403, 19407, 19408, 19433, 19449, 19517, 19548, 19549, 19592, 19615, 19642, 19650, 19668, 19688, 19710, 19728, 19797, 19803, 19822, 19840, 19858, 19878, 19900, 19956, 19962, 19966, 19967, 19970, 20031, 20078, 20140, 20203, 20215, 20219, 20220, 20254, 20306, 20352, 20353, 20384, 20409, 20435, 20443, 20463, 20533, 20549, 20588, 20594, 20638, 20661, 20688, 20712, 20720, 20738, 20758, 20776, 20834, 20872, 20878, 20914, 20937, 20964, 20988, 20996, 21017, 21037, 21055, 21116, 21143, 21149, 21206, 21226, 21244, 21306, 21327, 21389, 21442, 21470, 21476, 21509, 21532, 21557, 21627, 21667, 21673, 21724, 21744, 21762, 21827, 21876, 21934, 21983, 22008, 22014, 22051, 22076, 22099, 22107, 22127, 22145, 22207, 22230, 22236, 22257, 22273, 22293, 22342, 22370, 22437, 22491, 22515, 22569, 22575, 22600, 22618, 22636, 22656, 22706, 22712, 22743, 22762, 22778, 22798, 22816, 22863, 22893, 22928, 22968, 23002, 23030, 23075, 23120, 23149, 23184, 23227, 23233, 23253, 23276, 23303, 23325, 23333, 23353, 23371, 23431, 23483, 23534, 23584, 23629, 23635, 23666, 23692, 23712, 23730, 23795, 23860, 23929, 23998, 24067, 24098, 24099, 24166, 24235, 24281, 24287, 24317, 24342, 24365, 24373, 24393, 24428, 24434, 24459, 24482, 24509, 24533, 24541, 24561, 24596, 24602, 24627, 24650, 24677, 24701, 24709, 24729, 24747, 24792, 24829, 24835, 24872, 24873, 24922, 24980, 25031, 25080, 25112, 25113, 25165, 25166, 25199, 25225, 25245, 25263, 25327, 25363, 25369, 25402, 25428, 25448, 25466, 25530, 25566, 25572, 25573, 25607, 25608, 25642, 25668, 25688, 25706, 25775, 25840, 25880, 25886, 25887, 25948, 25949, 25981, 25999, 26019, 26083, 26089, 26121, 26139, 26159, 26223, 26229, 26230, 26288, 26289, 26322, 26340, 26360, 26423, 26429, 26461, 26479, 26499, 26562, 26568, 26569, 26599, 26617, 26637, 26685, 26710, 26716, 26717, 26769, 26770, 26834, 26879, 26880, 26929, 26985, 26986, 27020, 27048, 27069, 27123, 27176, 27182, 27210, 27230, 27288, 27294, 27322, 27342, 27364, 27423, 27429, 27455, 27475, 27497, 27549, 27555, 27609, 27610, 27644, 27660, 27721, 27741, 27766, 27789, 27797, 27815, 27836, 27842, 27870, 27895, 27919, 27927, 27945, 27974, 27980, 28004, 28024, 28042, 28084, 28090, 28094, 28095, 28128, 28144, 28195, 28252, 28285, 28310, 28346, 28354, 28404, 28410, 28414, 28415, 28444, 28460, 28515, 28542, 28568, 28590, 28608, 28653, 28680, 28686, 28713, 28739, 28777, 28799, 28861, 28884, 28892, 28914, 28932, 28977, 29004, 29010, 29014, 29016, 29028, 29029, 29038, 29039, 29059, 29060, 29080, 29081, 29097, 29098, 29118, 29124, 29125, 29151, 29152, 29167, 29173, 29174, 29206, 29207, 29217, 29227, 29228, 29258, 29259, 29282, 29283, 29322, 29323, 29721, 29722, 29749, 29750, 29853, 29854, 29868, 29869, 29895, 29896, 29946, 30255, 30265, 30423, 30433, 30634, 30644, 30780, 30790, 31005, 31015, 31184, 31194, 31394, 31395, 31423, 31424, 31460, 31790, 31800, 31922, 31932, 32107, 32117, 32289, 32290, 32309, 32310, 32333, 32339, 32363, 32369, 32383, 32390, 32401, 32408, 32425, 32431 ] }
{ "red_pajama_v2": { "ccnet_original_length": 32431, "ccnet_original_nlines": 1123, "rps_doc_curly_bracket": 0.009373749606311321, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.13040606677532196, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05942555144429207, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.3748762011528015, "rps_doc_frac_unique_words": 0.2819571793079376, "rps_doc_mean_word_length": 6.469419002532959, "rps_doc_num_sentences": 299, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.959567070007324, "rps_doc_word_count": 3270, "rps_doc_frac_chars_dupe_10grams": 0.07336326688528061, "rps_doc_frac_chars_dupe_5grams": 0.254029780626297, "rps_doc_frac_chars_dupe_6grams": 0.2249586433172226, "rps_doc_frac_chars_dupe_7grams": 0.1670527160167694, "rps_doc_frac_chars_dupe_8grams": 0.13367998600006104, "rps_doc_frac_chars_dupe_9grams": 0.10134720057249069, "rps_doc_frac_chars_top_2gram": 0.0181990098208189, "rps_doc_frac_chars_top_3gram": 0.031198300421237946, "rps_doc_frac_chars_top_4gram": 0.009264949709177017, "rps_doc_books_importance": -2641.17333984375, "rps_doc_books_importance_length_correction": -2641.17333984375, "rps_doc_openwebtext_importance": -1304.2174072265625, "rps_doc_openwebtext_importance_length_correction": -1304.2174072265625, "rps_doc_wikipedia_importance": -1146.6102294921875, "rps_doc_wikipedia_importance_length_correction": -1146.6102294921875 }, "fasttext": { "dclm": 0.8391184210777283, "english": 0.6640595197677612, "fineweb_edu_approx": 2.4989185333251953, "eai_general_math": 0.7288370132446289, "eai_open_web_math": 0.3423808813095093, "eai_web_code": 0.9281771779060364 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.0285", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "621.392", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Engineering", "level_3": "Mechanical engineering and Machinery" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "2", "label": "Academic/Research" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "2", "label": "Text Extraction Errors" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "5", "label": "Exceptionally Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,374,209,704,383,051,000
Go4Expert Go4Expert (http://www.go4expert.com/) -   C++ (http://www.go4expert.com/articles/cpp-tutorials/) -   -   Generic C++ Properties (http://www.go4expert.com/articles/generic-cpp-properties-t3480/) Sanskruti 19Mar2007 18:59 Generic C++ Properties   Generics are parameterized types supported by the common language runtime. A parameterized type is a type that is defined with an unknown type parameter that is specified when the generic is used. C++ supports templates and both templates and generics support parameterized types to create typed collection classes. However, templates provide compile-time parameterization. You cannot reference an assembly containing a template definition and create new specializations of the template. Once compiled, a specialized template looks like any other class or method. In contrast, generics are emitted in MSIL as a parameterized type known by the runtime to be a parameterized type; source code that references an assembly containing a generic type can create specializations of the generic type. Class types, as long as they are managed types, may be generic. The type of object in the list would be the type parameter. If you needed a List class for many different types of objects, before generics you might have used a List that takes System::Object as the item type. But that would allow any object to be used in the list. Such a list would be called an untyped collection class. You could check the type at runtime and throw an exception. Or, you might have used a template, which would lose its generic quality once compiled into an assembly. Consumers of your assembly could not create their own specializations of the template. Generics allow you to create typed collection classes, say List<int> and List<double> ("List of double") which would generate a compile-time error if you tried to put a type that the collection was not designed to accept into the typed collection. Type Parameters A generic declaration contains one or more unknown types known as type parameters. Type parameters are given a name which stands for the type within the body of the generic declaration. The type parameter is used as a type within the body of the generic declaration. The generic declaration for List<T> contains the type parameter T. Type Arguments The type argument is the actual type used in place of the type parameter when the generic is specialized for a specific type or types. For example, int is the type argument in List<int>. Value types and handle types are the only types allowed in as a generic type argument. Constructed Type A type constructed from a generic type is referred to as a constructed type. A type not fully specified, such as List<T> is an open constructed type; a type fully specified, such as List<double>, is a closed constructed type or specialized type. Open constructed types may be used in the definition of other generic types or methods and may not be fully specified until the enclosing generic is itself specified. Reference Types and Value Types Handles types and value types may be used as type arguments. In the generic definition, in which either type may be used, the syntax is that of reference types. For example, the -> operator is used to access members of the type of the type parameter whether or not the type eventually used is a reference type or a value type. When a value type is used as the type argument, the runtime generates code that uses the value types directly without boxing the value types. Type Parameters Type parameters in a generic class are treated like other identifiers. However, because the type is not known, there are restrictions on their use. For example, you cannot use members and methods of the type parameter class unless the type parameter is known to support these members. That is, in order access a member through the type parameter, you must add the type that contains the member to the type parameter's constraint list. Code: CPP interface class I {     void f1();     void f2(); }; ref struct R : public I {     virtual void f1() {}     virtual void f2() {}     virtual void f3() {} }; generic <typename T> where T : I void f(T t) {     t->f1();     t->f2();     safe_cast<R^>(t)->f3(); }  int main() {     f(gcnew R()); } These restrictions apply to operators as well. An unconstrained generic type parameter may not use the == and != operators to compare two instances of the type parameter, in case the type does not support these operators. These checks are necessary for generics, but not for templates, because generics may be specialized at runtime with any class that satisfies the constraints, when it is too late to check for the use of invalid members. A default instance of the type parameter may be created by using the () operator. For example: T t = T(); where T is a type parameter in a generic class or method definition, initializes the variable to its default value. If T is a ref class it will be a null pointer; if T is a value class, the object is initialized to zero. This is called a default initializer. Generic Functions Generic functions may be necessary if the function's parameters are of an unknown type, or if the function itself must work with generic types. In many cases where System::Object may have been used in the past as a parameter for an unknown object type, a generic type parameter may be used instead, allowing for more type-safe code. Any attempt to pass in a type that the function was not designed for would be flagged as an error at compile time. Using System::Object as a function parameter, the inadvertent passing of an object that the function wasn't intended to deal with would not be detected, and you would have to cast the unknown object type to a specific type in the function body, and account for the possibility of an InvalidCastException. With a generic, code attempting to pass an object to the function would cause a type conflict so the function body is guaranteed to have the correct type. A generic function is a function that is declared with type parameters. When called, actual types are used instead of the type parameters. Code: CPP [attributes] [modifiers]  return-type identifier <type-parameter identifier(s)> [type-parameter-constraints clauses] ([formal-parameters])  {  function-body } The above syntax includes these terms, defined as follows: attributes (Optional) Additional declarative information. modifiers (Optional) A modifier for the function, such as static. virtual is not allowed since virtual methods may not be generic. return-type The type returned by the method. If the return type is void, no return value is required. identifier The function name. type-parameter identifier(s) Comma-separated identifiers list. formal-parameters (Optional) Parameter list. type-parameter-constraints-clauses This specifies restrictions on the types that may be used as type arguments, and takes the form specified in Constraints. function-body The body of the method, which may refer to the type parameter identifiers. Generic functions are functions declared with a generic type parameter. They may be methods in a class or struct, or standalone functions. A single generic declaration implicitly declares a family of functions that differ only in the substitution of a different actual type for the generic type parameter. When called, the generic type parameter is replaced by an actual type. The actual type may be explicitly specified in angled brackets using syntax similar to a template function call. If called without the type parameters, the compiler will attempt to deduce the actual type from the parameters supplied in the function call. If the intended type argument cannot be deduced from the parameters used, the compiler will report an error. An Example Code: CPP generic <typename ItemType> void G(int i) {}  ref struct A { generic <typename ItemType> void G(ItemType) {} generic <typename ItemType> static void H(int i) {} }; int main() {     A myObject;     // generic function call     myObject.G<int>(10);     // generic function call with type parameters deduced myObject.G(10);     // static generic function call     A::H<int>(10);     // global generic function call     G<int>(10); } Generic functions can be overloaded based on signature, the number of type parameters on a function.. Also, generic functions can be overloaded with non-generic functions of the same name, as long as the functions differ in some type parameters. For example, the following functions can be overloaded: Code: CPP ref struct MyClass {     void MyMethod(int i) {}     generic <class T>     void MyMethod(int i) {}       generic <class T, class V>     void MyMethod(int i) {} }; Generic Classes Collection classes in the past would use System::Object to store elements in a collection. Insertion of objects of a type that the collection was not designed for was not flagged at compile time, and often not even when the objects were inserted. Usually, an object would be cast to some other type when it was accessed in the collection. Only when the cast failed would the unexpected type be detected. Generics solves this problem at compile time by detecting any code that inserts a type that doesn't match (or implicitly convert to) the type parameter of the generic collection A generic class is declared using the following form: Code: CPP [attributes] generic <class-key type-parameter-identifier(s)> [constraint-clauses] [accessibility-modifiers] ref class identifier [modifiers] [: base-list] {     class-body } [declarators] [;] In the above syntax, the following terms are used: attributes (optional) Additional declarative information. class-key Either class or typename type-parameter-identifier(s) Comma-separated list of identifiers specifying the names of the type parameters. constraint-clauses A list (not comma-separated) of where clauses specifying the constraints for the type parameters. Takes the form: where type-parameter-identifier : constraint-list ... constraint-list class-or-interface[, ...] accessibility-modifiers Allowed accessibility modifiers include public and private. identifier The name of the generic class, any valid C++ identifier. modifiers (optional) Allowed modifiers include sealed and abstract. base-list A list that contains the one base class and any implemented interfaces, all separated by commas. class-body The body of the class, containing fields, member functions, etc. declarators Declarations of any variables of this type. For example: ^identifier[, ...] You can declare generic classes such as these (note that the keyword class may be used instead of typename). Code: CPP using namespace System; generic <typename ItemType> ref struct Stack { // ItemType may be used as a type here  void Add(ItemType item) {} }; generic <typename KeyType, typename ValueType> ref class HashTable {}; // The keyword class may be used instead of typename: generic <class ListItem>  ref class List {}; int main() { HashTable<int, Decimal>^ g1 = gcnew HashTable<int, Decimal>(); } Both value types (either built-in types such as int or double, or user-defined value types) and reference types may be used as a generic type argument. The syntax within the generic definition is the same regardless. Syntactically, the unknown type is treated as if it were a reference type. However, the runtime is able to determine that if the type actually used is a value type and substitute the appropriate generated code for direct access to members. Value types used as generic type arguments are not boxed and so do not suffer the performance penalty associated with boxing. The syntax used within the body of the generic should be T^ and '->' instead of '.'. C++ supports templates and both templates and generics support parameterized types to create typed collection classes. However, templates provide compile-time parameterization. You cannot reference an assembly containing a template definition and create new specializations of the template. Once compiled, a specialized template looks like any other class or method. In contrast, generics are emitted in MSIL as a parameterized type known by the runtime to be a parameterized type; source code that references an assembly containing a generic type can create specializations of the generic type. rashida.par 13Mar2008 15:40 Re: Generic C++ Properties   ok got it All times are GMT +5.5. The time now is 15:23.
{ "url": "http://www.go4expert.com/printthread.php?t=3480", "source_domain": "www.go4expert.com", "snapshot_id": "crawl=CC-MAIN-2016-26", "warc_metadata": { "Content-Length": "26181", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:GLI7V2LWXO2FFUB5J6MA5IGJLM2XNTHZ", "WARC-Concurrent-To": "<urn:uuid:4363a99f-30ea-417a-958e-df3e68a7ed03>", "WARC-Date": "2016-06-27T09:53:38Z", "WARC-IP-Address": "173.230.137.46", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:VAVUFNQ2BCE6Y2CGMTFCZ6BPFLJ5TYK7", "WARC-Record-ID": "<urn:uuid:cae444f9-e148-45fe-b4ae-d916bb689464>", "WARC-Target-URI": "http://www.go4expert.com/printthread.php?t=3480", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:a5ae47f5-e0c2-46df-9f4e-28906bb71c5f>" }, "warc_info": "robots: classic\r\nhostname: ip-10-164-35-72.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-26\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for June 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 10, 11, 49, 108, 205, 206, 232, 233, 256, 258, 455, 456, 747, 748, 1053, 1054, 1329, 1330, 1943, 1944, 1960, 1961, 1962, 1963, 2297, 2298, 2313, 2314, 2315, 2316, 2590, 2591, 2608, 2609, 2610, 2611, 3024, 3025, 3057, 3058, 3059, 3060, 3221, 3529, 3530, 3546, 3547, 3548, 3549, 3984, 3985, 3995, 3996, 4014, 4016, 4031, 4046, 4049, 4050, 4074, 4076, 4101, 4126, 4151, 4154, 4155, 4176, 4188, 4200, 4202, 4215, 4228, 4256, 4258, 4270, 4272, 4290, 4292, 4293, 4734, 4735, 4817, 4830, 4841, 5100, 5101, 5119, 5120, 5121, 5122, 6030, 6031, 6103, 6170, 6171, 6181, 6182, 6207, 6262, 6299, 6321, 6324, 6339, 6341, 6342, 6401, 6402, 6424, 6460, 6481, 6591, 6603, 6693, 6704, 6723, 6752, 6786, 6815, 6831, 6866, 6988, 7002, 7077, 7383, 7384, 7819, 7820, 7831, 7832, 7842, 7843, 7871, 7888, 7904, 7932, 7952, 7980, 8004, 8007, 8018, 8020, 8036, 8065, 8090, 8164, 8200, 8219, 8255, 8271, 8273, 8274, 8520, 8521, 8577, 8587, 8588, 8609, 8637, 8638, 8660, 8688, 8690, 8721, 8749, 8752, 8753, 8769, 8770, 8771, 8772, 9354, 9355, 9409, 9410, 9420, 9421, 9434, 9483, 9504, 9530, 9563, 9577, 9579, 9594, 9596, 9614, 9615, 9666, 9667, 9689, 9725, 9735, 9760, 9789, 9870, 9889, 10057, 10073, 10099, 10123, 10183, 10194, 10251, 10272, 10319, 10329, 10426, 10437, 10502, 10514, 10590, 10699, 10709, 10710, 10734, 10762, 10781, 10820, 10848, 10851, 10852, 10899, 10923, 10924, 10978, 11003, 11023, 11034, 11036, 11099, 11101, 11102, 11770, 11771, 12367, 12368, 12396, 12397, 12424, 12426, 12436, 12437, 12438 ], "line_end_idx": [ 10, 11, 49, 108, 205, 206, 232, 233, 256, 258, 455, 456, 747, 748, 1053, 1054, 1329, 1330, 1943, 1944, 1960, 1961, 1962, 1963, 2297, 2298, 2313, 2314, 2315, 2316, 2590, 2591, 2608, 2609, 2610, 2611, 3024, 3025, 3057, 3058, 3059, 3060, 3221, 3529, 3530, 3546, 3547, 3548, 3549, 3984, 3985, 3995, 3996, 4014, 4016, 4031, 4046, 4049, 4050, 4074, 4076, 4101, 4126, 4151, 4154, 4155, 4176, 4188, 4200, 4202, 4215, 4228, 4256, 4258, 4270, 4272, 4290, 4292, 4293, 4734, 4735, 4817, 4830, 4841, 5100, 5101, 5119, 5120, 5121, 5122, 6030, 6031, 6103, 6170, 6171, 6181, 6182, 6207, 6262, 6299, 6321, 6324, 6339, 6341, 6342, 6401, 6402, 6424, 6460, 6481, 6591, 6603, 6693, 6704, 6723, 6752, 6786, 6815, 6831, 6866, 6988, 7002, 7077, 7383, 7384, 7819, 7820, 7831, 7832, 7842, 7843, 7871, 7888, 7904, 7932, 7952, 7980, 8004, 8007, 8018, 8020, 8036, 8065, 8090, 8164, 8200, 8219, 8255, 8271, 8273, 8274, 8520, 8521, 8577, 8587, 8588, 8609, 8637, 8638, 8660, 8688, 8690, 8721, 8749, 8752, 8753, 8769, 8770, 8771, 8772, 9354, 9355, 9409, 9410, 9420, 9421, 9434, 9483, 9504, 9530, 9563, 9577, 9579, 9594, 9596, 9614, 9615, 9666, 9667, 9689, 9725, 9735, 9760, 9789, 9870, 9889, 10057, 10073, 10099, 10123, 10183, 10194, 10251, 10272, 10319, 10329, 10426, 10437, 10502, 10514, 10590, 10699, 10709, 10710, 10734, 10762, 10781, 10820, 10848, 10851, 10852, 10899, 10923, 10924, 10978, 11003, 11023, 11034, 11036, 11099, 11101, 11102, 11770, 11771, 12367, 12368, 12396, 12397, 12424, 12426, 12436, 12437, 12438, 12484 ] }
{ "red_pajama_v2": { "ccnet_original_length": 12484, "ccnet_original_nlines": 243, "rps_doc_curly_bracket": 0.0036847200244665146, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3490835130214691, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.023625250905752182, "rps_doc_frac_lines_end_with_ellipsis": 0.00409835996106267, "rps_doc_frac_no_alph_words": 0.19226068258285522, "rps_doc_frac_unique_words": 0.22746554017066956, "rps_doc_mean_word_length": 5.187168598175049, "rps_doc_num_sentences": 108, "rps_doc_symbol_to_word_ratio": 0.001221999991685152, "rps_doc_unigram_entropy": 5.099772930145264, "rps_doc_word_count": 1886, "rps_doc_frac_chars_dupe_10grams": 0.10180926322937012, "rps_doc_frac_chars_dupe_5grams": 0.17049984633922577, "rps_doc_frac_chars_dupe_6grams": 0.13973219692707062, "rps_doc_frac_chars_dupe_7grams": 0.12634161114692688, "rps_doc_frac_chars_dupe_8grams": 0.12634161114692688, "rps_doc_frac_chars_dupe_9grams": 0.11898191273212433, "rps_doc_frac_chars_top_2gram": 0.021465810015797615, "rps_doc_frac_chars_top_3gram": 0.01962587982416153, "rps_doc_frac_chars_top_4gram": 0.0061330897733569145, "rps_doc_books_importance": -994.5205688476562, "rps_doc_books_importance_length_correction": -994.5205688476562, "rps_doc_openwebtext_importance": -602.91259765625, "rps_doc_openwebtext_importance_length_correction": -602.91259765625, "rps_doc_wikipedia_importance": -541.2454833984375, "rps_doc_wikipedia_importance_length_correction": -541.2454833984375 }, "fasttext": { "dclm": 0.08123469352722168, "english": 0.7871280908584595, "fineweb_edu_approx": 3.1502668857574463, "eai_general_math": 0.8745213150978088, "eai_open_web_math": 0.22807282209396362, "eai_web_code": 0.9658714532852173 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1332", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-730,463,343,274,268,700
2018-09-19 04:59 CEST View Issue Details Jump to Notes ] IDProjectCategoryView StatusLast Update 0003902LittleComputerPeople[All Projects] Generalpublic2018-07-14 00:20 ReporterHexaae  Assigned ToJOTDProject InfoLittle Computer People (Activision) http://www.whdload.de/games/LittleComputerPeople.html   PrioritynormalSeverityminorReproducibilityalways StatusacknowledgedResolutionopen  Summary0003902: 040 or 060 WinUAE emu. Can't hear sounds when using CTRL+C (phone call), or DescriptionGameVersion: english,pal SlaveVersion: 1.2 (16.03.05) 040 or 060 WinUAE emu. Can't hear sounds when using CTRL+C (phone call), or CTRL+B (delivered book, no ring bell) etc... Tried to degrade emu it with "UAE-configuration cachesize 0 cycle_exact true" but didn't solve missing sounds issue. TagsNo tags attached. MachineUAE CPU68040 CPUSpeed75 ChipSetAGA GFXCardPicasso IV ChipMem2 MB FastMem256MB WorkbenchOS 3.9 KickROM40 - Kick 3.1 KickSoftOther WHDLoad18.4beta importedyes Attached Files -Relationships +Relationships -Notes note ~0006277 JOTD (developer) I don't know the game well. When can you trigger those ctrl+key things and do they have more than audio effect? Does it work on winuae setting like 68000? +Notes -Issue History Date Modified Username Field Change 2018-07-04 09:36 administrator New Issue 2018-07-04 09:36 administrator Status new => assigned 2018-07-04 09:36 administrator Assigned To => JOTD 2018-07-13 19:22 JOTD Status assigned => acknowledged 2018-07-13 23:12 JOTD Note Added: 0006277 +Issue History
{ "url": "http://mantis.whdload.de/view.php?id=3902", "source_domain": "mantis.whdload.de", "snapshot_id": "crawl=CC-MAIN-2018-39", "warc_metadata": { "Content-Length": "93080", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:CKG76NOXB25JPBSQGUBTAPACB6X2SXUV", "WARC-Concurrent-To": "<urn:uuid:324b347e-bf41-4716-b732-a07fa56812e9>", "WARC-Date": "2018-09-19T02:59:16Z", "WARC-IP-Address": "134.119.45.21", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:KXYGUNR4LV4NPDTII3EIGSYI6WTWII2O", "WARC-Record-ID": "<urn:uuid:cdc1a0e6-7096-42c9-84ed-f5f42f4f70b5>", "WARC-Target-URI": "http://mantis.whdload.de/view.php?id=3902", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:08370cc9-72a0-497b-8661-1ddca70a7f75>" }, "warc_info": "isPartOf: CC-MAIN-2018-39\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2018\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-47-244-60.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 0.11-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 22, 23, 58, 98, 170, 186, 249, 303, 305, 354, 388, 480, 516, 545, 546, 569, 667, 696, 745, 784, 806, 817, 826, 837, 848, 866, 878, 891, 907, 928, 942, 958, 970, 985, 986, 1001, 1016, 1017, 1024, 1025, 1039, 1040, 1057, 1058, 1170, 1171, 1214, 1221, 1222, 1237, 1273, 1314, 1368, 1419, 1473, 1515 ], "line_end_idx": [ 22, 23, 58, 98, 170, 186, 249, 303, 305, 354, 388, 480, 516, 545, 546, 569, 667, 696, 745, 784, 806, 817, 826, 837, 848, 866, 878, 891, 907, 928, 942, 958, 970, 985, 986, 1001, 1016, 1017, 1024, 1025, 1039, 1040, 1057, 1058, 1170, 1171, 1214, 1221, 1222, 1237, 1273, 1314, 1368, 1419, 1473, 1515, 1529 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1529, "ccnet_original_nlines": 56, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.11326860636472702, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.051779940724372864, "rps_doc_frac_lines_end_with_ellipsis": 0.017543859779834747, "rps_doc_frac_no_alph_words": 0.43689319491386414, "rps_doc_frac_unique_words": 0.7348066568374634, "rps_doc_mean_word_length": 6.834254264831543, "rps_doc_num_sentences": 18, "rps_doc_symbol_to_word_ratio": 0.0032362500205636024, "rps_doc_unigram_entropy": 4.76804256439209, "rps_doc_word_count": 181, "rps_doc_frac_chars_dupe_10grams": 0.09054163098335266, "rps_doc_frac_chars_dupe_5grams": 0.09054163098335266, "rps_doc_frac_chars_dupe_6grams": 0.09054163098335266, "rps_doc_frac_chars_dupe_7grams": 0.09054163098335266, "rps_doc_frac_chars_dupe_8grams": 0.09054163098335266, "rps_doc_frac_chars_dupe_9grams": 0.09054163098335266, "rps_doc_frac_chars_top_2gram": 0.029102670028805733, "rps_doc_frac_chars_top_3gram": 0.06063055992126465, "rps_doc_frac_chars_top_4gram": 0.022635409608483315, "rps_doc_books_importance": -132.63580322265625, "rps_doc_books_importance_length_correction": -121.6700210571289, "rps_doc_openwebtext_importance": -67.16250610351562, "rps_doc_openwebtext_importance_length_correction": -67.16250610351562, "rps_doc_wikipedia_importance": -34.8148078918457, "rps_doc_wikipedia_importance_length_correction": -21.762466430664062 }, "fasttext": { "dclm": 0.07464414834976196, "english": 0.6080690622329712, "fineweb_edu_approx": 2.5269973278045654, "eai_general_math": 0.003575559938326478, "eai_open_web_math": 0.05060511827468872, "eai_web_code": 0.028355959802865982 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "1", "label": "Factual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "2", "label": "Partially Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
-7,839,933,483,433,874,000
TechSpot Win98 Start Problem By Bencat Feb 26, 2007 1. I have a Dell Optoplex on my home network I am using for file backup and storage. Problem: I removed an older version of McAfee (Ver 7) to free up disk space. Now on Windows boot, I get a dos screen looking for a McAfee file. I can continue the boot but it often results in a Desk top frozen screen. I have tried everything McAfee and others suggested to elimiate the requst for the file at boot ...to no avail. (reg cleaner, system.ini etc). It seems like it would be an easy thing to eliminate if I could find it! Safe mode works all the time. Question: Any ideas where this boot request may be located and how do I eliminate it? Thank You in advance. :grinthumb   2. SNGX1275 SNGX1275 TS Forces Special Posts: 10,681   +392 I think you are on the right track looking in the system.ini, its one of those files I think, because I've had this problem before, unfortunately I think the last time I had it was around 2000 or 2001. Have you tried firing up msconfig and looking through the tabs there and seeing if there is anything you can find related to McAfee.   3. I think you'll probably find it in the autoexec.bat file, though it may be in config.sys. It wouldn't be in system.ini or win.ini as that is loaded with windows, not before windows (DOS). This is a common problem with AV programs like Norton or Mcafee.   1 person likes this. 4. Rick Rick TechSpot Staff Posts: 4,573   +65 I imagine it boots fine in Safe mode, have you tried? Download the VSCleanUpTool.exe from this page.. Run it under Safe Mode and it should solve your problem. That is, if your problem is actually McAfee and not some other coincidental issue....   5. Bencat Bencat TS Rookie Topic Starter I ran through the matrix I found on one of the windows help sites. It suggests turning off Config.sys, Autoexec.bat, System.ini, Win.ini and Start up group in varoius combinations using msconfig. None of the combinations eliminated the boot "missing file' error message. So.....I have to assume the source is not in one of these. The McAfee program was installed by Dell when I purcased the computer. I am now wondering if it isn't some hidden Dell startup folder! Caravel & Sngx1275 thanks for your suggestions.   6. Where does the "missing file" error appear? Before windows starts at the DOS prompt? Can you post up the contents of your autoexec.bat and config.sys files for a start. Anything loaded from DOS before win9x starts is usually located in autoexec.bat particularly. If you see it after the "Starting Windows 98" appears (after, and interrupting, the spash screen) then it could be located anywhere, even the registry. Have you tried running msconfig and checking to see if the missing file is being loaded as part of the startup list?   7. Bencat Bencat TS Rookie Topic Starter Fixed One Problem! Reference to the problem file was in the Reg. I did a "find" file in the reg area with key word McAfee. Even after running McAfee uninstall and and a program call Regclean, there were still references to McAfee. I deleted them and THIS problem was fixed (loads windows and desk top without stopping). I still have the unpredictable lockup problem after boot. I get one of three outcomes 1. clean boot (everything appears to work), 2. Everything loads, but hangs (Hour glass). 3. Same as 2, but no hour glass (mouse arrow moves but can't select anything. 2&3 Ctrl-Alt-Delete usually results in a black screen. Hard reboot is the only thing that works. Thanks for all your help so far...any additional ideas would be greatly appreciated. Bencat   Topic Status: Not open for further replies. Similar Topics Add New Comment You need to be a member to leave a comment. Join thousands of tech enthusiasts and participate. TechSpot Account You may also...
{ "url": "http://www.techspot.com/community/topics/win98-start-problem.70985/", "source_domain": "www.techspot.com", "snapshot_id": "crawl=CC-MAIN-2016-26", "warc_metadata": { "Content-Length": "50912", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:FA5OGOS25CGPXQPHSA2QLM4F4FN3DQOV", "WARC-Concurrent-To": "<urn:uuid:91039caa-7d36-4406-9cdc-c004e70e1bd4>", "WARC-Date": "2016-06-26T06:39:08Z", "WARC-IP-Address": "184.173.241.66", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:E3QOBKYGCEIF4KWAWQXN4SX6RPIHGRSA", "WARC-Record-ID": "<urn:uuid:0d47fd4d-92e8-4e33-95c6-082d891a001d>", "WARC-Target-URI": "http://www.techspot.com/community/topics/win98-start-problem.70985/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:8fd7adf0-a232-4648-94a3-ac39ab43ba47>" }, "warc_info": "robots: classic\r\nhostname: ip-10-164-35-72.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-26\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for June 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 9, 10, 30, 31, 41, 54, 141, 142, 610, 611, 701, 702, 739, 745, 759, 760, 812, 813, 1152, 1158, 1416, 1422, 1447, 1457, 1458, 1501, 1502, 1560, 1561, 1756, 1762, 1774, 1775, 1810, 1811, 2145, 2146, 2285, 2286, 2338, 2344, 2881, 2887, 2899, 2900, 2935, 2936, 2959, 2960, 3265, 3266, 3620, 3621, 3710, 3711, 3722, 3728, 3742, 3772, 3773, 3788, 3789, 3805, 3806, 3902 ], "line_end_idx": [ 9, 10, 30, 31, 41, 54, 141, 142, 610, 611, 701, 702, 739, 745, 759, 760, 812, 813, 1152, 1158, 1416, 1422, 1447, 1457, 1458, 1501, 1502, 1560, 1561, 1756, 1762, 1774, 1775, 1810, 1811, 2145, 2146, 2285, 2286, 2338, 2344, 2881, 2887, 2899, 2900, 2935, 2936, 2959, 2960, 3265, 3266, 3620, 3621, 3710, 3711, 3722, 3728, 3742, 3772, 3773, 3788, 3789, 3805, 3806, 3902, 3934 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3934, "ccnet_original_nlines": 65, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.371498167514801, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.04141290858387947, "rps_doc_frac_lines_end_with_ellipsis": 0.030303029343485832, "rps_doc_frac_no_alph_words": 0.192448228597641, "rps_doc_frac_unique_words": 0.4539969861507416, "rps_doc_mean_word_length": 4.466063499450684, "rps_doc_num_sentences": 75, "rps_doc_symbol_to_word_ratio": 0.006090130191296339, "rps_doc_unigram_entropy": 5.249139308929443, "rps_doc_word_count": 663, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.02161432057619095, "rps_doc_frac_chars_dupe_6grams": 0.02161432057619095, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.008105370216071606, "rps_doc_frac_chars_top_3gram": 0.012158050201833248, "rps_doc_frac_chars_top_4gram": 0.013508950360119343, "rps_doc_books_importance": -349.120849609375, "rps_doc_books_importance_length_correction": -349.120849609375, "rps_doc_openwebtext_importance": -215.87684631347656, "rps_doc_openwebtext_importance_length_correction": -215.87684631347656, "rps_doc_wikipedia_importance": -133.02540588378906, "rps_doc_wikipedia_importance_length_correction": -133.02540588378906 }, "fasttext": { "dclm": 0.024879520758986473, "english": 0.9373376965522766, "fineweb_edu_approx": 1.0615183115005493, "eai_general_math": 0.20029503107070923, "eai_open_web_math": 0.37352538108825684, "eai_web_code": 0.006897809915244579 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
8,625,003,613,952,161,000
首页 Preview Vue3+vite 配置路径别名 配置路径别名 在实际开发中,有的组件会嵌套的很深,如果需要引入外层其他目录的组件,需要编写很长一段相对路径。 vite.config.js里配置,为 /src配置别名@,为 import { defineConfig } from 'vite' import vue from '@vitejs/plugin-vue' import path from "path"; // https://vitejs.dev/config/ export default defineConfig({ plugins: [vue()], resolve: { alias: [{ find: "@", replacement: path.resolve(__dirname,'/src') //为 /src配置别名@ }, // 可以专门为组件文件路径设置别名 { find: "C", replacement: path.resolve(__dirname,'/src/components') } ] } }) 以引入组件为例: // 没有设置别名之前 import HelloWorld from '../components/helloWorld.vue' // 设置别名之后 import HelloWorld from '@/components/helloWorld.vue' import HelloWorld from 'C/helloWorld.vue' PS:如果这样在 ts 项目中以上配置完了之后,还要在tsconfig.jsoncompilerOptions进行配置 : "baseUrl": ".", "paths": { "@/*": ["src/*"] } 版权声明:本文内容由TeHub注册用户自发贡献,版权归原作者所有,TeHub社区不拥有其著作权,亦不承担相应法律责任。 如果您发现本社区中有涉嫌抄袭的内容,填写侵权投诉表单进行举报,一经查实,本社区将立刻删除涉嫌侵权内容。 点赞(0) 收藏(0) 励志猿 励志每天写一篇文章,有价值的文章,提升自我! 评论(0) 添加评论
{ "url": "https://tehub.com/a/bAwreRJeIZ", "source_domain": "tehub.com", "snapshot_id": "CC-MAIN-2024-38", "warc_metadata": { "Content-Length": "424010", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:5MHOPYGMZVAR6EL2UETCGAOA7OQMXXNB", "WARC-Concurrent-To": "<urn:uuid:4935b731-29c6-4406-9a73-bd903bb5c0be>", "WARC-Date": "2024-09-12T13:13:40Z", "WARC-IP-Address": "101.35.252.240", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:5JDRNO5434ZZNL65REP2H76TOA7CYW6Y", "WARC-Record-ID": "<urn:uuid:b8c23ddd-5b59-4813-bf7c-5f6d4a8b3ccd>", "WARC-Target-URI": "https://tehub.com/a/bAwreRJeIZ", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:4d33105f-a0c9-4cf4-a6b6-e3b35dfc5cc0>" }, "warc_info": "isPartOf: CC-MAIN-2024-38\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-98\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 3, 11, 12, 29, 30, 37, 38, 86, 87, 119, 120, 156, 193, 218, 219, 249, 279, 299, 312, 326, 343, 393, 413, 420, 443, 449, 466, 527, 533, 539, 543, 545, 548, 549, 558, 559, 571, 625, 626, 636, 689, 690, 732, 733, 795, 796, 812, 823, 842, 844, 845, 957, 958, 964, 970, 974, 997, 998, 1004, 1005 ], "line_end_idx": [ 3, 11, 12, 29, 30, 37, 38, 86, 87, 119, 120, 156, 193, 218, 219, 249, 279, 299, 312, 326, 343, 393, 413, 420, 443, 449, 466, 527, 533, 539, 543, 545, 548, 549, 558, 559, 571, 625, 626, 636, 689, 690, 732, 733, 795, 796, 812, 823, 842, 844, 845, 957, 958, 964, 970, 974, 997, 998, 1004, 1005, 1009 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1009, "ccnet_original_nlines": 60, "rps_doc_curly_bracket": 0.011892960406839848, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.028037380427122116, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.014018690213561058, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.6542056202888489, "rps_doc_frac_unique_words": 0.7246376872062683, "rps_doc_mean_word_length": 10.333333015441895, "rps_doc_num_sentences": 12, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 3.7340917587280273, "rps_doc_word_count": 69, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.06732118129730225, "rps_doc_frac_chars_top_3gram": 0.08415146917104721, "rps_doc_frac_chars_top_4gram": 0.1206171065568924, "rps_doc_books_importance": -105.27037811279297, "rps_doc_books_importance_length_correction": -105.27037811279297, "rps_doc_openwebtext_importance": -70.63617706298828, "rps_doc_openwebtext_importance_length_correction": -56.66802215576172, "rps_doc_wikipedia_importance": -44.91046142578125, "rps_doc_wikipedia_importance_length_correction": -44.91046142578125 }, "fasttext": { "dclm": 0.9896581768989563, "english": 0.03769484907388687, "fineweb_edu_approx": 1.801007866859436, "eai_general_math": 0.8630807995796204, "eai_open_web_math": 0.02040827088057995, "eai_web_code": 0.44689279794692993 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.133", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.452", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
5,898,516,680,210,844,000
The Oddities of WinPE I can’t stress enough how important it is when using new technology in a corporate environment. An example that I want to pass along involves the use of WinPE (Microsoft Windows PE operating system) with Altiris Deployment Server. I have learned the hard way that it is better to research until you die, before implementation of a new technology. When using Windows PE on Altiris Deployment Server, I would recommend using Altiris’ WinPE package and pay the 20$ to get their install of the OS. They have made some modifications to increase the speed of packet traffic when imaging. I would also recommend using the Windows PE 2005 utility CD which contains a VBS script to embed in your WinPE boot image to allow VBScripting to work properly when booting a computer into a WinPE environment that you plan to run a VBScript on. In addition to these options, I would strongly recommend that you add the Mass Storage driver information for any kind of SATA drives you are using in your laptop/desktop hardware. It makes it much easier to do scripted OS installs, let alone image using WinPE if you can see the hard drive you are about to copy files to. Just a few ideas to pass along that I hope you find of interest. Hopefully, it will help from keeping your hair from turning gray or falling out too soon in your life. %d bloggers like this:
{ "url": "https://blog.virtualnate.net/wordpress/2008/01/30/the-oddities-of-winpe/", "source_domain": "blog.virtualnate.net", "snapshot_id": "CC-MAIN-2024-18", "warc_metadata": { "Content-Length": "92426", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:HYJO4IELJWHX2KOD3RO25H3MSX3PCOZC", "WARC-Concurrent-To": "<urn:uuid:bd19661f-f9c5-425f-8712-fc54afc3037d>", "WARC-Date": "2024-04-13T09:38:43Z", "WARC-IP-Address": "172.67.193.128", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:LO6OIBPTWDWSXE5S4ZGD6DBJZIJ6FS23", "WARC-Record-ID": "<urn:uuid:5003d164-7bc1-497c-a70e-6dfdaf6df7d8>", "WARC-Target-URI": "https://blog.virtualnate.net/wordpress/2008/01/30/the-oddities-of-winpe/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:92745a36-1f39-44b9-b016-a7f4576d4f09>" }, "warc_info": "isPartOf: CC-MAIN-2024-18\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for April 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-97\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 22, 23, 1341, 1342 ], "line_end_idx": [ 22, 23, 1341, 1342, 1364 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1364, "ccnet_original_nlines": 4, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.47211897373199463, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05576207861304283, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.09293679893016815, "rps_doc_frac_unique_words": 0.6065573692321777, "rps_doc_mean_word_length": 4.5, "rps_doc_num_sentences": 11, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.678717613220215, "rps_doc_word_count": 244, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.024590160697698593, "rps_doc_frac_chars_top_3gram": 0.020036429166793823, "rps_doc_frac_chars_top_4gram": 0.04371584951877594, "rps_doc_books_importance": -134.82896423339844, "rps_doc_books_importance_length_correction": -134.82870483398438, "rps_doc_openwebtext_importance": -68.19110107421875, "rps_doc_openwebtext_importance_length_correction": -68.19110107421875, "rps_doc_wikipedia_importance": -58.27384948730469, "rps_doc_wikipedia_importance_length_correction": -58.05049133300781 }, "fasttext": { "dclm": 0.06043332815170288, "english": 0.9364024996757507, "fineweb_edu_approx": 2.3221936225891113, "eai_general_math": 0.48782259225845337, "eai_open_web_math": 0.16687345504760742, "eai_web_code": 0.40097957849502563 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "16", "label": "Personal Blog" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
4,215,363,000,782,816,000
Comments and answers for "How do I increase the connection pool size that has reached the maximum of 256?" https://community.datastax.com/questions/9641/how-to-increase-the-connection-pull-size-that-has.html The latest comments and answers for the question "How do I increase the connection pool size that has reached the maximum of 256?" Comment by Erick Ramirez on Erick Ramirez's comment https://community.datastax.com/comments/9694/view.html <div class="fr-view clearfix"><p>It looks like you didn&#39;t see my other reply where I&#39;ve linked the driver doc. The details are in that document. Cheers!</p></div> Thu, 17 Dec 2020 22:35:35 GMT Erick Ramirez Comment by michael.shatz_192704 on michael.shatz_192704's comment https://community.datastax.com/comments/9686/view.html <div class="fr-view clearfix"><p>Hi Erick,</p><p>I really appreciate your quick replies to all my questions, but none of them did really helped me<br />(note: I understand perfectly your answers).</p><p>I just want to know how to change the following attributes: max_connections_per_host and<br />max_requests_per_connection - that&#39;s all I want to know</p><p>thanks</p></div> Thu, 17 Dec 2020 12:08:41 GMT michael.shatz_192704 Comment by Erick Ramirez on Erick Ramirez's comment https://community.datastax.com/comments/9660/view.html <div class="fr-view clearfix"><p>I feel like you&#39;ve missed the point in my answer. Let me use an analogy.</p><p>Imagine you have 3 cashiers at a fast food restaurant taking orders and there are 10 customers queued up at each cashier (30 in total). But the cooks out the back can only serve 20 orders at a time so they can&#39;t keep up with the orders from 30 customers (leading to the &quot;busy queue&quot; problem).</p><p>Adding more cashiers out the front won&#39;t actually solve the problem because the size of the customer queues won&#39;t make a difference -- the problem is there&#39;s not enough capacity in the kitchen to process the orders.</p><p>In your case, your cluster can only service X transactions per second (tps) but your application is sending X + Y tps. You need to increase the size of your cluster to account for the extra Y tps. Cheers!</p></div> Thu, 17 Dec 2020 01:55:45 GMT Erick Ramirez Comment by Erick Ramirez on Erick Ramirez's comment https://community.datastax.com/comments/9659/view.html <div class="fr-view clearfix"><p>See <a rel="noopener noreferrer" href="https://docs.datastax.com/en/developer/java-driver/4.9/manual/core/pooling/" target="_blank">Connection pooling</a> in the driver docs.</p></div> Thu, 17 Dec 2020 01:48:32 GMT Erick Ramirez Comment by michael.shatz_192704 on michael.shatz_192704's answer https://community.datastax.com/comments/9639/view.html <div class="fr-view clearfix"><p>Hi</p><p>I set the following attributes in cassandra.yaml <br />max_connections_per_host=1000 and <br />max_requests_per_connection=1024 </p><p>Cassandra restarted</p><p>But the above did not help, The BusyPoolException has been thrown.</p><p>Please advise </p><p>Thanks</p></div> Wed, 16 Dec 2020 10:54:22 GMT michael.shatz_192704 Comment by michael.shatz_192704 on michael.shatz_192704's answer https://community.datastax.com/comments/9670/view.html <div class="fr-view clearfix"><p>Hi <a rel="user" href="/users/98/c88e6697-7966-4779-9221-58d72ce4c93e.html" nodeid="98">@Erick Ramirez</a></p><p>Thanks for your answer.</p><p>Even though, can you please guide how to increase the pool size?</p><p>Thanks</p></div> Mon, 14 Dec 2020 12:25:50 GMT michael.shatz_192704 Answer by Erick Ramirez https://community.datastax.com/answers/9652/view.html <div class="fr-view clearfix"><p>The <code>BusyPoolException</code> gets thrown when all the connections in the pool are used and there are no available slots left. This can happen when:</p><ul><li>an application is sending multiple long-running requests that eventually tie up all the connections in the pool until there are none left, or</li><li>the nodes are overloaded and requests are queueing up.</li></ul><p>The driver will attempt to connect to nodes in the query plan one by one but when they&#39;re all busy and there are no nodes left to contact in the list, the driver will return the <code>NoHostAvailableException</code>.</p><p>Trying to increase the connection pool size won&#39;t achieve the outcome you&#39;re after simply because the nodes are already overloaded and adding more requests to the queue will just make it worse.</p><p>You need to review your queries and make sure you are only doing single-partition requests. You also need to throttle the traffic to make sure you are not overloading the cluster. Cheers!</p></div> Sun, 13 Dec 2020 23:16:20 GMT Erick Ramirez
{ "url": "https://community.datastax.com/feed/9641/comments-and-answers.rss", "source_domain": "community.datastax.com", "snapshot_id": "crawl=CC-MAIN-2022-49", "warc_metadata": { "Content-Length": "7593", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:35VMY3ZZ644NTMYLZDWKPNOVBKRMJ6W3", "WARC-Concurrent-To": "<urn:uuid:a225d03c-c9d6-42f9-9172-ca972e680bb7>", "WARC-Date": "2022-12-01T10:58:50Z", "WARC-IP-Address": "54.87.228.252", "WARC-Identified-Payload-Type": "application/rss+xml", "WARC-Payload-Digest": "sha1:D73WENSG3JHP6JRMTXGJKIDUYEBU26X2", "WARC-Record-ID": "<urn:uuid:66ed80a2-a986-4bc8-a5e1-21456f774674>", "WARC-Target-URI": "https://community.datastax.com/feed/9641/comments-and-answers.rss", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:db5e5a92-12ba-446d-94e1-ecdaae58723d>" }, "warc_info": "isPartOf: CC-MAIN-2022-49\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November/December 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-149\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0 ], "line_end_idx": [ 4700 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4700, "ccnet_original_nlines": 0, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.28854435682296753, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.017226530238986015, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.34022393822669983, "rps_doc_frac_unique_words": 0.4724137783050537, "rps_doc_mean_word_length": 6.232758522033691, "rps_doc_num_sentences": 64, "rps_doc_symbol_to_word_ratio": 0.009474590420722961, "rps_doc_unigram_entropy": 5.137933254241943, "rps_doc_word_count": 580, "rps_doc_frac_chars_dupe_10grams": 0.03540802001953125, "rps_doc_frac_chars_dupe_5grams": 0.16127248108386993, "rps_doc_frac_chars_dupe_6grams": 0.1369294673204422, "rps_doc_frac_chars_dupe_7grams": 0.10594744235277176, "rps_doc_frac_chars_dupe_8grams": 0.10594744235277176, "rps_doc_frac_chars_dupe_9grams": 0.03540802001953125, "rps_doc_frac_chars_top_2gram": 0.026556020602583885, "rps_doc_frac_chars_top_3gram": 0.015491009689867496, "rps_doc_frac_chars_top_4gram": 0.013278010301291943, "rps_doc_books_importance": -550.0795288085938, "rps_doc_books_importance_length_correction": -550.0795288085938, "rps_doc_openwebtext_importance": -314.95013427734375, "rps_doc_openwebtext_importance_length_correction": -314.95013427734375, "rps_doc_wikipedia_importance": -273.4491882324219, "rps_doc_wikipedia_importance_length_correction": -273.4491882324219 }, "fasttext": { "dclm": 0.06375086307525635, "english": 0.8191869854927063, "fineweb_edu_approx": 1.0187264680862427, "eai_general_math": 0.04605298861861229, "eai_open_web_math": 0.14124661684036255, "eai_web_code": 0.1315973997116089 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.74", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "1", "label": "Leftover HTML" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-1,902,795,052,363,255,800
1 Reply Latest reply on Apr 29, 2020 1:22 AM by thatJeffSmith-Oracle Is there a process to file documentation bugs? kevinUCB In the distant past, I recall you could annotate on a page/document that there was an error --typo or whatever. In the ORDS 19.4 Installation, Configuration, and Development Guide, the Section 1.9 Header refers to Data Guard, when the description pretty clearly refers to Database Vault.
{ "url": "https://community.oracle.com/thread/4327874", "source_domain": "community.oracle.com", "snapshot_id": "crawl=CC-MAIN-2020-24", "warc_metadata": { "Content-Length": "83615", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:M6REX25ZDFLJ635HXU7MAQC4MRCVCRFK", "WARC-Concurrent-To": "<urn:uuid:acb168b8-7797-451f-b524-90db04518036>", "WARC-Date": "2020-05-24T23:10:09Z", "WARC-IP-Address": "104.68.240.79", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:UCP2PIOAC563IE2B72QO4IGGH5DYOWJH", "WARC-Record-ID": "<urn:uuid:e332d279-dc57-4b86-a6a4-fd06e30f5baa>", "WARC-Target-URI": "https://community.oracle.com/thread/4327874", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:abc50f85-7c1a-4e16-9075-3e0c8596f7fe>" }, "warc_info": "isPartOf: CC-MAIN-2020-24\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May/June 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-241.ec2.internal\r\nsoftware: Apache Nutch 1.16 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 73, 74, 125, 126, 139, 140, 258, 259 ], "line_end_idx": [ 73, 74, 125, 126, 139, 140, 258, 259, 440 ] }
{ "red_pajama_v2": { "ccnet_original_length": 440, "ccnet_original_nlines": 8, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.27586206793785095, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03448275849223137, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.27586206793785095, "rps_doc_frac_unique_words": 0.8358209133148193, "rps_doc_mean_word_length": 4.925373077392578, "rps_doc_num_sentences": 5, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 3.948591470718384, "rps_doc_word_count": 67, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.030303029343485832, "rps_doc_frac_chars_top_3gram": 0, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -46.541038513183594, "rps_doc_books_importance_length_correction": -46.60160827636719, "rps_doc_openwebtext_importance": -27.74039649963379, "rps_doc_openwebtext_importance_length_correction": -27.800966262817383, "rps_doc_wikipedia_importance": -26.558658599853516, "rps_doc_wikipedia_importance_length_correction": -26.61922836303711 }, "fasttext": { "dclm": 0.17931616306304932, "english": 0.8821271657943726, "fineweb_edu_approx": 2.202730894088745, "eai_general_math": 0.21416330337524414, "eai_open_web_math": 0.6434297561645508, "eai_web_code": 0.19649648666381836 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "025.0285", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "Library science", "level_3": "Library administration" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-610,308,281,484,350,800
James Steidl - Fotolia What MongoDB security issues are still unresolved? There are some MongoDB security issues that have yet to be resolved. Expert Matthew Pascucci discusses the risks and how to protect your enterprise from them. What are the MongoDB security risks have not yet been resolved? Is there anything companies can do to mitigate... the threats they pose before patches are available? Recently, there was a surge of attacks looking for misconfigured installations of MongoDB on the internet. The attackers were abusing the lack of authentication and remote accessibility to these MongoDB instances by deleting an original database and holding a copy of it for ransom. These and other MongoDB security misconfigurations and vulnerabilities aren't completely related to patch management, and are more in the realm of configuration management. There are a few ways to improve MongoDB security and protect your database from attackers. The major issue here lies with certain versions of MongoDB coming with loose default configurations. The responsibility in this case lies firmly with the administrators installing the database software and not managing it appropriately. I personally feel all software should be locked down by default, and should have certain features enabled only when needed, but if an application doesn't do this by default, and it's documented, then the responsibility falls to the administrators. Since older versions of MongoDB have loose default configurations, database administrators should validate a few things to start. The first step to improve MongoDB security is to determine if the server running your database needs to have any inbound connections. Many times, these databases are housed remotely and require access from remote administrators. The default port for a MongoDB is 27017 and, if it's not only bound to 127.0.0.1, and the firewalls aren't locked down, attackers can access the database remotely. Be sure to validate that only the proper ports are open, limit who can access the system and remove all access from the internet if it's not needed. Also, look into possibly using a VPN to connect to this instance if it has to be open over the internet to reduce visibility. Secondly, validate the users who authenticate and run the database. One of the previous issues was that the default configuration allowed unauthenticated users to access the database over the internet. It's highly recommended to have some type of role-based access control instituted to limit the exposure of parts of the database that shouldn't be accessed by particular users. Also, the user account running the database shouldn't have complete admin rights to the rest of the system. Limiting the rights directly to the application hardens it against other vulnerabilities that might arise within the application, such as SQL injection. The third step to take to improve MongoDB security is to validate that the data within the databases is encrypted both in transit and in storage. There is native encryption, called WiredTiger, that can be utilized in particular MongoDB versions that helps secure the data within the database. This wouldn't have helped with the theft problem that occurred in the ransomware attacks, but would have secured the stolen data from being used. If an organization needs to access the database remotely, it should be done over TLS to secure the communication in transit. Lastly, there are best practices like logging and auditing, vulnerability scanning, configuration and patch management that would have picked up on these issues. Without proper governance over MongoDB instances, or any system really, there can be a slow decline into an insecure posture that leads toward organizations being breached. Ask the expert: Want to ask Matt Pascucci a question about security? Submit your question now via email. (All questions are anonymous.) Next Steps Find out how a MongoDB database misconfiguration caused 30,000 insecure instances Read about a recent MongoDB security issue that lead to ransomware attacks Learn why Amazon Web Services is excited about serverless architecture This was last published in May 2017 Dig Deeper on Data security and privacy SearchNetworking SearchCIO SearchEnterpriseDesktop SearchCloudComputing ComputerWeekly.com Close
{ "url": "https://www.techtarget.com/searchsecurity/answer/What-MongoDB-security-issues-are-still-unresolved", "source_domain": "www.techtarget.com", "snapshot_id": "crawl=CC-MAIN-2022-27", "warc_metadata": { "Content-Length": "304487", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:NQO4JKPHXP6Z5TTYDRK3OZN4K6PDC5BB", "WARC-Concurrent-To": "<urn:uuid:b732da64-b9db-47bb-bf57-e146d17358e5>", "WARC-Date": "2022-07-01T10:11:19Z", "WARC-IP-Address": "104.18.42.39", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:HF2FXZSPSMJB6L7J4NAR3JWAKJKZZRFR", "WARC-Record-ID": "<urn:uuid:bcfe8be5-3ba9-48c8-b223-734c97f8adba>", "WARC-Target-URI": "https://www.techtarget.com/searchsecurity/answer/What-MongoDB-security-issues-are-still-unresolved", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:086141cb-0b42-4922-948f-d8ed772b8ae2>" }, "warc_info": "isPartOf: CC-MAIN-2022-27\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June/July 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-163\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 23, 24, 75, 76, 235, 236, 350, 351, 403, 404, 687, 688, 952, 953, 1190, 1191, 1569, 1570, 1963, 1964, 2239, 2240, 2619, 2620, 2881, 2882, 3446, 3447, 3782, 3783, 3799, 3919, 3920, 3931, 3932, 4014, 4015, 4090, 4091, 4162, 4163, 4199, 4200, 4240, 4241, 4258, 4268, 4292, 4313, 4332 ], "line_end_idx": [ 23, 24, 75, 76, 235, 236, 350, 351, 403, 404, 687, 688, 952, 953, 1190, 1191, 1569, 1570, 1963, 1964, 2239, 2240, 2619, 2620, 2881, 2882, 3446, 3447, 3782, 3783, 3799, 3919, 3920, 3931, 3932, 4014, 4015, 4090, 4091, 4162, 4163, 4199, 4200, 4240, 4241, 4258, 4268, 4292, 4313, 4332, 4337 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4337, "ccnet_original_nlines": 50, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.431011825799942, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.005256239790469408, "rps_doc_frac_lines_end_with_ellipsis": 0.019607840105891228, "rps_doc_frac_no_alph_words": 0.11169514060020447, "rps_doc_frac_unique_words": 0.4565868377685547, "rps_doc_mean_word_length": 5.339820384979248, "rps_doc_num_sentences": 38, "rps_doc_symbol_to_word_ratio": 0.001314059947617352, "rps_doc_unigram_entropy": 5.154630184173584, "rps_doc_word_count": 668, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.015699470415711403, "rps_doc_frac_chars_dupe_6grams": 0.015699470415711403, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.033641718327999115, "rps_doc_frac_chars_top_3gram": 0.01345669012516737, "rps_doc_frac_chars_top_4gram": 0.02018502913415432, "rps_doc_books_importance": -329.4928283691406, "rps_doc_books_importance_length_correction": -329.4928283691406, "rps_doc_openwebtext_importance": -196.1777801513672, "rps_doc_openwebtext_importance_length_correction": -196.1777801513672, "rps_doc_wikipedia_importance": -88.01685333251953, "rps_doc_wikipedia_importance_length_correction": -88.01685333251953 }, "fasttext": { "dclm": 0.4349353313446045, "english": 0.9406151175498962, "fineweb_edu_approx": 2.311525821685791, "eai_general_math": 0.21116793155670166, "eai_open_web_math": 0.12277764081954956, "eai_web_code": 0.5850338935852051 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.74", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.82", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "10", "label": "Knowledge Article" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
550,193,080,127,770,430
Logstash Outputedit Prerequisite: To use Logstash as an output, you must install and configure the Beats input plugin for Logstash. The Logstash output sends the events directly to Logstash by using the lumberjack protocol, which runs over TCP. Logstash allows for additional processing and routing of generated events. Here is an example of how to configure Packetbeat to use Logstash: output.logstash: hosts: ["localhost:5044"] Accessing Metadata Fieldsedit Every event sent to Logstash contains the following metadata fields that you can use in Logstash for indexing and filtering: { ... "@metadata": { "beat": "packetbeat", "type": "<event type>" } } Packetbeat uses the @metadata field to send metadata to Logstash. The contents of the @metadata field only exist in Logstash and are not part of any events sent from Logstash. See the Logstash documentation for more about the @metadata field. The default is packetbeat. To change this value, set the index option in the Packetbeat config file. The value of type varies depending on the event type. You can access this metadata from within the Logstash config file to set values dynamically based on the contents of the metadata. For example, the following Logstash configuration file for versions 2.x and 5.x sets Logstash to use the index and document type reported by Beats for indexing events into Elasticsearch: input { beats { port => 5044 } } output { elasticsearch { hosts => ["http://localhost:9200"] index => "%{[@metadata][beat]}-%{+YYYY.MM.dd}" document_type => "%{[@metadata][type]}" } } %{[@metadata][beat]} sets the first part of the index name to the value of the beat metadata field, and %{+YYYY.MM.dd} sets the second part of the name to a date based on the Logstash @timestamp field. For example: packetbeat-2017.03.29. %{[@metadata][type]} sets the document type based on the value of the type metadata field. Events indexed into Elasticsearch with the Logstash configuration shown here will be similar to events directly indexed by Beats into Elasticsearch. Compatibilityedit This output works with all compatible versions of Logstash. See "Supported Beats Versions" in the Elastic Support Matrix. Logstash Output Optionsedit You can specify the following options in the logstash section of the packetbeat.yml config file: enablededit The enabled config is a boolean setting to enable or disable the output. If set to false, the output is disabled. The default value is true. hostsedit The list of known Logstash servers to connect to. If load balancing is disabled, but mutliple hosts are configured, one host is selected randomly (there is no precedence). If one host becomes unreachable, another one is selected randomly. All entries in this list can contain a port number. If no port number is given, the value specified for port is used as the default port number. compression_leveledit The gzip compression level. Setting this value to 0 disables compression. The compression level must be in the range of 1 (best speed) to 9 (best compression). Increasing the compression level will reduce the network usage but will increase the cpu usage. The default value is 3. workeredit The number of workers per configured host publishing events to Logstash. This is best used with load balancing mode enabled. Example: If you have 2 hosts and 3 workers, in total 6 workers are started (3 for each host). loadbalanceedit If set to true and multiple Logstash hosts are configured, the output plugin load balances published events onto all Logstash hosts. If set to false, the output plugin sends all events to only one host (determined at random) and will switch to another host if the selected one becomes unresponsive. The default value is false. output.logstash: hosts: ["localhost:5044", "localhost:5045"] loadbalance: true index: packetbeat pipeliningedit Configures number of batches to be send asynchronously to logstash while waiting for ACK from logstash. Output only becomes blocking once number of pipelining batches have been written. Pipelining is disabled if a values of 0 is configured. The default value is 0. portedit Warning Deprecated in 5.0.0. The default port to use if the port number is not given in hosts. The default port number is 10200. proxy_urledit The URL of the SOCKS5 proxy to use when connecting to the Logstash servers. The value must be a URL with a scheme of socks5://. The protocol used to communicate to Logstash is not based on HTTP so a web-proxy cannot be used. If the SOCKS5 proxy server requires client authentication, then a username and password can be embedded in the URL as shown in the example. When using a proxy, hostnames are resolved on the proxy server instead of on the client. You can change this behavior by setting the proxy_use_local_resolver option. output.logstash: hosts: ["remote-host:5044"] proxy_url: socks5://user:password@socks5-proxy:2233 proxy_use_local_resolveredit The proxy_use_local_resolver option determines if Logstash hostnames are resolved locally when using a proxy. The default value is false which means that when a proxy is used the name resolution occurs on the proxy server. indexedit The index root name to write events to. The default is the Beat name. For example "packetbeat" generates "[packetbeat-]YYYY.MM.DD" indexes (for example, "packetbeat-2015.04.26"). ssledit Configuration options for SSL parameters like the root CA for Logstash connections. See SSL for more information. To use SSL, you must also configure the Beats input plugin for Logstash to use SSL/TLS. timeoutedit The number of seconds to wait for responses from the Logstash server before timing out. The default is 30 (seconds). max_retriesedit The number of times to retry publishing an event after a publishing failure. After the specified number of retries, the events are typically dropped. Some Beats, such as Filebeat, ignore the max_retries setting and retry until all events are published. Set max_retries to a value less than 0 to retry until all events are published. The default is 3. bulk_max_sizeedit The maximum number of events to bulk in a single Logstash request. The default is 2048. If the Beat sends single events, the events are collected into batches. If the Beat publishes a large batch of events (larger than the value specified by bulk_max_size), the batch is split. Specifying a larger batch size can improve performance by lowering the overhead of sending events. However big batch sizes can also increase processing times, which might result in API errors, killed connections, timed-out publishing requests, and, ultimately, lower throughput. Setting bulk_max_size to values less than or equal to 0 disables buffering in libbeat. When buffering is disabled, Beats that publish single events (such as Packetbeat) send each event directly to Elasticsearch. Beats that publish data in batches (such as Filebeat) send events in batches based on the spooler size.
{ "url": "https://www.elastic.co/guide/en/beats/packetbeat/current/logstash-output.html", "source_domain": "www.elastic.co", "snapshot_id": "crawl=CC-MAIN-2017-17", "warc_metadata": { "Content-Length": "51778", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:7MLK5L3BAT3AUK7XT7D5J2XHUPSV6M6T", "WARC-Concurrent-To": "<urn:uuid:3b43383c-8a83-4385-8f3f-ccaafe74e00a>", "WARC-Date": "2017-04-27T01:29:20Z", "WARC-IP-Address": "52.84.125.196", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:6ZTLAIA4POATOHT5BAWIV4FXPYVYQT4U", "WARC-Record-ID": "<urn:uuid:d0064ff1-d641-4f41-a54f-75806e20132f>", "WARC-Target-URI": "https://www.elastic.co/guide/en/beats/packetbeat/current/logstash-output.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:8eef39c5-0c28-46f7-a3d7-22e54a2438e0>" }, "warc_info": "robots: classic\r\nhostname: ip-10-145-167-34.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2017-17\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for April 2017\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 20, 21, 133, 134, 322, 323, 390, 391, 408, 436, 437, 467, 468, 593, 594, 596, 604, 624, 653, 683, 689, 691, 692, 935, 936, 1037, 1038, 1092, 1093, 1224, 1225, 1412, 1413, 1421, 1431, 1448, 1452, 1454, 1455, 1464, 1482, 1521, 1573, 1618, 1622, 1624, 1625, 1863, 1864, 1955, 1956, 2105, 2106, 2124, 2125, 2247, 2248, 2276, 2277, 2374, 2375, 2387, 2388, 2502, 2503, 2530, 2531, 2541, 2542, 2781, 2782, 2927, 2928, 2950, 2951, 3111, 3112, 3208, 3209, 3233, 3234, 3245, 3246, 3465, 3466, 3482, 3483, 3810, 3811, 3828, 3874, 3894, 3914, 3915, 3930, 3931, 4196, 4197, 4206, 4207, 4215, 4216, 4237, 4238, 4338, 4339, 4353, 4354, 4579, 4580, 4720, 4721, 4887, 4888, 4905, 4935, 4989, 4990, 5019, 5020, 5243, 5244, 5254, 5255, 5434, 5435, 5443, 5444, 5646, 5647, 5659, 5660, 5777, 5778, 5794, 5795, 6048, 6049, 6129, 6130, 6148, 6149, 6167, 6168, 6256, 6257, 6447, 6448, 6727, 6728 ], "line_end_idx": [ 20, 21, 133, 134, 322, 323, 390, 391, 408, 436, 437, 467, 468, 593, 594, 596, 604, 624, 653, 683, 689, 691, 692, 935, 936, 1037, 1038, 1092, 1093, 1224, 1225, 1412, 1413, 1421, 1431, 1448, 1452, 1454, 1455, 1464, 1482, 1521, 1573, 1618, 1622, 1624, 1625, 1863, 1864, 1955, 1956, 2105, 2106, 2124, 2125, 2247, 2248, 2276, 2277, 2374, 2375, 2387, 2388, 2502, 2503, 2530, 2531, 2541, 2542, 2781, 2782, 2927, 2928, 2950, 2951, 3111, 3112, 3208, 3209, 3233, 3234, 3245, 3246, 3465, 3466, 3482, 3483, 3810, 3811, 3828, 3874, 3894, 3914, 3915, 3930, 3931, 4196, 4197, 4206, 4207, 4215, 4216, 4237, 4238, 4338, 4339, 4353, 4354, 4579, 4580, 4720, 4721, 4887, 4888, 4905, 4935, 4989, 4990, 5019, 5020, 5243, 5244, 5254, 5255, 5434, 5435, 5443, 5444, 5646, 5647, 5659, 5660, 5777, 5778, 5794, 5795, 6048, 6049, 6129, 6130, 6148, 6149, 6167, 6168, 6256, 6257, 6447, 6448, 6727, 6728, 7043 ] }
{ "red_pajama_v2": { "ccnet_original_length": 7043, "ccnet_original_nlines": 150, "rps_doc_curly_bracket": 0.003407639916986227, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3353383541107178, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.01654135063290596, "rps_doc_frac_lines_end_with_ellipsis": 0.006622519809752703, "rps_doc_frac_no_alph_words": 0.1984962373971939, "rps_doc_frac_unique_words": 0.3229461908340454, "rps_doc_mean_word_length": 5.211520195007324, "rps_doc_num_sentences": 91, "rps_doc_symbol_to_word_ratio": 0.0007518799975514412, "rps_doc_unigram_entropy": 5.079451084136963, "rps_doc_word_count": 1059, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.04964667931199074, "rps_doc_frac_chars_dupe_6grams": 0.032976988703012466, "rps_doc_frac_chars_dupe_7grams": 0.014132999815046787, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.02355499006807804, "rps_doc_frac_chars_top_3gram": 0.010871529579162598, "rps_doc_frac_chars_top_4gram": 0.015401340089738369, "rps_doc_books_importance": -620.5350341796875, "rps_doc_books_importance_length_correction": -620.5350341796875, "rps_doc_openwebtext_importance": -429.32537841796875, "rps_doc_openwebtext_importance_length_correction": -429.32537841796875, "rps_doc_wikipedia_importance": -337.39813232421875, "rps_doc_wikipedia_importance_length_correction": -337.39813232421875 }, "fasttext": { "dclm": 0.2751009464263916, "english": 0.8097498416900635, "fineweb_edu_approx": 2.6267313957214355, "eai_general_math": 0.9504122138023376, "eai_open_web_math": 0.20235776901245117, "eai_web_code": 0.9842425584793091 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.467", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.74", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-3,382,574,591,668,694,500
CSA93 Amligic S912 remote.conf Can anyone give me a working remote.conf file please. Since upgrading from Libreelec (Kodi 17) to Coreelec (kodi 18 beta 3) I’ve lost my remote control functions. Also cant SSH into the box anymore “connection refused” Its a CSA93 Amlogic S913 Player and yes i did use the correct dtb.img when i did the upgrade. Did you take a look at this thread? CE doesn’t use remote.conf, so very doubtful :wink: If you updated from LE without a fresh install or used an LE Backup to fresh CE Install ? Try libreelec for password ssh. Happened to me wayback whenever. Thanks Will try do do a fresh install, yes i did use a LE backup so that might be the reason. Tried Keymapper also but doesnt even pick the signal from the remote up so i’m thinking it might be a IR receiver driver rather than the remote itself. @kostaman is referring to the fact that if you ‘update’ from LE instead of starting afresh with CE, as is advised, then your SSH password will be libreelec and not coreelec . Your remote will not work until you find or create the correct configuration files for it (which is not remote.conf). You need to do a little bit more reading, for example try @relkai’s suggestion: or here
{ "url": "https://discourse.coreelec.org/t/csa93-amligic-s912-remote-conf/1868", "source_domain": "discourse.coreelec.org", "snapshot_id": "crawl=CC-MAIN-2022-21", "warc_metadata": { "Content-Length": "33222", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:UGZPUDKKJCSLC3HUEGHXAMLYXCEN5B5L", "WARC-Concurrent-To": "<urn:uuid:ace63abe-1adf-49ed-ace3-c800519fb30c>", "WARC-Date": "2022-05-22T07:08:18Z", "WARC-IP-Address": "116.203.16.118", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:IFSV7UD6C2KGIEQUD7HLT7S5H6YQ4QEJ", "WARC-Record-ID": "<urn:uuid:ebf457f9-d0e1-4688-a26d-5a9d9512917d>", "WARC-Target-URI": "https://discourse.coreelec.org/t/csa93-amligic-s912-remote-conf/1868", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:374eb598-405b-4826-8f64-a77912a04647>" }, "warc_info": "isPartOf: CC-MAIN-2022-21\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-200\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 31, 32, 251, 252, 346, 347, 383, 384, 436, 437, 527, 592, 593, 687, 688, 840, 841, 1016, 1017, 1215, 1216 ], "line_end_idx": [ 31, 32, 251, 252, 346, 347, 383, 384, 436, 437, 527, 592, 593, 687, 688, 840, 841, 1016, 1017, 1215, 1216, 1223 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1223, "ccnet_original_nlines": 21, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4344569444656372, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05617978051304817, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.1573033630847931, "rps_doc_frac_unique_words": 0.611872136592865, "rps_doc_mean_word_length": 4.38812780380249, "rps_doc_num_sentences": 17, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.686977386474609, "rps_doc_word_count": 219, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.012486989609897137, "rps_doc_frac_chars_top_3gram": 0.01456816028803587, "rps_doc_frac_chars_top_4gram": 0.020811650902032852, "rps_doc_books_importance": -108.04224395751953, "rps_doc_books_importance_length_correction": -108.04224395751953, "rps_doc_openwebtext_importance": -78.9817123413086, "rps_doc_openwebtext_importance_length_correction": -78.9816665649414, "rps_doc_wikipedia_importance": -64.11620330810547, "rps_doc_wikipedia_importance_length_correction": -64.11620330810547 }, "fasttext": { "dclm": 0.2760075330734253, "english": 0.8972980976104736, "fineweb_edu_approx": 1.546986699104309, "eai_general_math": 0.7125605344772339, "eai_open_web_math": 0.5012155175209045, "eai_web_code": 0.1236569881439209 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
5,848,730,477,701,695,000
A weighted mean (or weighted average) is like an ordinary mean, but the observations don't contribute equally - more emphasis is placed on some data values than others; they are weighted by a bigger or smaller amount than 1/n. learn more… | top users | synonyms 13 votes 2answers 2k views Bias correction in weighted variance For unweighted variance $$\text{Var}(X):=\frac{1}{n}\sum_i(x_i - \mu)^2$$ there exists the bias corrected sample variance, when the mean was estimated from the same data: ... 10 votes 1answer 796 views Determining true mean from noisy observations I have a large set of data points of the form (mean, stdev). I wish to reduce this to a single (better) mean, and a (hopefully) smaller standard deviation. Clearly I could simply compute $\frac{\sum ... 9 votes 1answer 192 views Voting system that uses confidence for each voter Let's say, we have simple "yes/no" question that we want to know answer to. And there are N people "voting" for correct answer. Every voter has a history - list of 1's and 0's, showing whether they ... 8 votes 3answers 34k views How do I calculate a weighted standard deviation? In Excel? So, I have a data set of percentages like so: ... 8 votes 1answer 297 views Averages of averages (of averages, of averages…) Consider the following cell biology experiment. We are comparing $T$ different treatments of cultured cells. Each treatment $t$ is replicated in several (microtiter) wells, indexed by the variable ... 6 votes 2answers 5k views Computing standard error in weighted mean estimation Suppose that $w_1,w_2,\ldots,w_n$ and $x_1,x_2,...,x_n$ are each drawn i.i.d. from some distributions, with $w_i$ independent of $x_i$. The $w_i$ are strictly positive. You observe all the $w_i$, but ... 5 votes 0answers 64 views Weighting on tables I have a question about terminology. Suppose I have data categorized by three factors A, B, and C, with cell means $\bar{y}_{ijk}$ and cell frequencies $n_{ijk}$, where $i$, $j$, and $k$ index A, B, ... 4 votes 1answer 306 views Estimate the population variance from a set of means I have a set of measurements which is partitioned into M partitions. However, I only have the partition sizes $N_i$ and the means $\bar{x}_i$ from each partition. Because all measurements are assumed ... 4 votes 3answers 1k views Weighted standard deviation of average For two groups (a and b) with unequal numbers of observations (n=10 and n=30), I have given their means and sd. Calculating the weighted mean is pretty straight forward. But how can I derive the sd of ... 4 votes 1answer 4k views Weighted Variance, one more time Unbiased weighted variance was already addressed here and elsewhere but there still seems to be a surprising amount of confusion. There appears to be a consensus toward the formula presented in the ... 4 votes 1answer 521 views Using the eigenvalues from PCA in k-nearest-neighbours I'm quite new to this StackExchange, only been a lurker till now, but my StackOverflow fellows have said you'd be the best people to ask about this. Anyway, enough introduction. I'm using the ... 4 votes 1answer 4k views A simpler way to calculate Exponentially Weighted Moving Average? Proposed Method: Given a time series $x_i$, I want to compute a weighted moving average with an averaging window of $N$ points, where the weightings favour more recent values over older values. In ... 4 votes 1answer 109 views Standard error of a weighted mean when observations are not independent I have a situation where I have a bunch of noisy observations with known (and normal) sampling error and a non-trivial co-variance structure between the observations. In an uncorrelated setting, I'd ... 4 votes 1answer 670 views Negative weights in a moving average? A number of well known moving averages, such as Spencer's 15 point MA, and Henderson moving averages have negative weights in the averages. What does this mean in a conceptual sense? What information ... 3 votes 2answers 3k views Weighted geometric mean vs weighted mean I have a set of data, each element has a weight. I need to estimate the mean of this data. I found that there are two ways: A weighted geometric mean and a weighted mean. When should I use each of ... 3 votes 1answer 185 views How do I introduce features and their confidence values into classifiers I would appreciate some advice on how best to weight or give more importance to a percentage with a larger denominator. Eg A. 1 out of 2 = 50% B. 5 out of 10 = 50% C. 500 out of 1000 = 50% Some of ... 3 votes 1answer 120 views Calculating and comparing weighted means with changing number of daily values I have daily data where the number of values changes with each day. I would like to calculate the weighted mean of this data, where days with more values are weighted higher than days with less. ... 3 votes 1answer 277 views How does a Daniell kernel differ from a two sided average? As far as I can understand, the Daniell kernel, is simply $K(j/M)=\frac{1}{2M+1}1(|j|\leq M)$. Namely, this is a two sided average. Why do people call this an untruncated kernel and differentiate ... 3 votes 1answer 614 views Degrees of freedom for a weighted average And yet another for the long list of degrees-of-freedom questions! Given an i.i.d. sample $x_1,..., x_n$ from an arbitrary real-valued distribution with expectation $\mu$, the sample mean can be ... 3 votes 0answers 61 views Computation of the entropy of marginals? I have implemented this paper: Efficient graph-based semi-supervised learning of structured tagging models In the last sentence of the section 4.2, the authors have mentioned another possible way of ... 2 votes 1answer 106 views Comparing two lists to measure for similarity The problem I am trying to solve is finding the probability that two people are the same by cross-referencing the associates of the two people. For example, if person A is associated with the ... 2 votes 1answer 100 views Computing lowess mean value I am trying to reimplement the lowess algorithm in java. I read the matlab page explaining lowess with the following steps: Compute the regression weights for each data point in the span. A ... 2 votes 3answers 93 views How to calculate the weighted mean? For example assume I have three observations as given in matrix A $A = \left[ \begin{array}{ccc} 1 & 0 & 1 \\ 1 & 1 & 0 \\ 0 & 1 & 1 \\ \end{array} \right]$ each row vector ... 2 votes 1answer 450 views Standard deviations and confidence intervals (weighted) running average My question is related to this one. I am calculating averages, actually as many as I have samples because I calculate a running average, and for equal weighting I know how to calculate the $95\%$ CI, ... 2 votes 1answer 44 views Estimate the parameters of an ellipse in the presence of large outliers I have a number of points $x_1,\ldots,x_m\in\mathbb{R}^n$ with weights $w_1,\ldots,w_m$ between 0 and 1. There is an ellipse which contains a very high concentration of points with weights close to ... 2 votes 2answers 708 views Weighted mean of two 2D Gaussian random variables I have two 2D Gaussian random variables. I'd like to find the weighted average of the two (based on their covariance matrix around the mean, meaning that the mean of the final Gaussian should be ... 2 votes 0answers 25 views with two EWMA means of different window sizes, can we estimate any other means? slopes? jumps? EWMA is defined as follows(1, 2, 3, 4, 5): $$ \mu_{N} = \frac {1}{N} \Sigma_{i=1}^{N}x_i $$ $$ =\frac {1}{N} \Sigma_{i=1}^{N-1}x_i + \frac{1}{N}x_{N} $$ $$ =\frac {N-1}{N} \frac{1}{N-1} ... 2 votes 0answers 83 views Exponentially Weighing Moving Average (EWMA) for weekly data I'm aware that the typical EWMA approach is applied over larger time periods (say for Volatility, where lambda = 94% and all weights add up to 100% for stock returns data from last 5 years). ... 2 votes 0answers 213 views Weighted Standard Deviation vs. Weighted Regression Standard Error This is an R question. I have $n$ observations of the variable $y$, with each observation, $i$, weighted by $w(i)$. Each $w(i)$ weight falls between zero and 1, with the sum of the weights, ... 2 votes 0answers 63 views How to bootstrap confidence of a weighted measure? I have a large data set of 20M observations with 20+ measures for each observation (people). Additionally I have a set of weights that reflect the racial population where each person lives. For ... 2 votes 0answers 32 views Estimated Treatment Effect in the full sample is not between the estimates of the stratified samples? I am estimating the relationship between students' math scores and using a supplemental math software. I've adjusted for some demographic variables in the model. In my first model, I use the full ... 2 votes 0answers 34 views How to symmetrically adjust data by removing certain value Say I have a data set in the following format: {a:200, b: 100; c:400} The sum of a, b and c equals 700. Now, I have another value which is supposed to be the actual total say 500. How do I adjust ... 1 vote 2answers 155 views Always get confused by “probabilities and weighted probabilities” type of questions as cant differentiate between two Urn 1 contains 5 white balls and 7 black balls. Urn 2 contains 3 whites and 12 black. A fair coin is flipped; if it is Heads, a ball is drawn from Urn 1, and if it is Tails, a ball is drawn from Urn ... 1 vote 2answers 230 views Better method to estimate gender gap: difference between medians or median gap by occupation? I'm doing some analysis of Bureau of Labor Statistics data on wages earned by men and women, and I'm trying to determine which of the two methods I've used is the better estimate of the gender wage ... 1 vote 2answers 34 views Will the mean of a set of means always be the same as the mean obtained from the entire set of raw data? If I have calculated the mean for 4 data sets (which do have different sample sizes), can I then obtain an "overall mean" by calculating the "mean of the means"? If yes, will this "mean of the means" ... 1 vote 2answers 2k views How to compute weighted means and SDs? I want to calculate volume weighted average price and standard deviation for the following dataset: ... 1 vote 1answer 440 views How to relate raw scores on five-point Likert to three conceptual categories? My thesis is on employee productivity and I had a questionnaire which consists of a five-point Likert scale (5-strongly agree, 4-agree, 3-agree, 2-disagree, and 1-strongly disagree). On the other ... 1 vote 1answer 140 views Estimating an overall summary statistic (mean) for a value reported by ten published studies Background I am writing a systematic review and meta-analysis of the association of exposure to X with the outcome Y. I have identified ten studies that report on this subject. This will be a ... 1 vote 1answer 213 views Is there a more elegent solution for exponentially weighted-mean in R? [closed] OK so I have a working code to do what I want but I am new to R and feel like my solution is very clunky and there is likely a more efficient way to get the same result. I have a set of data that ... 1 vote 2answers 358 views How do I calculate the ranking of some galleries based on the rankings of the artists represented by them? The mean is not good in this case, because there are galleries that have an artist with a high rank and several other artists with way lower ranks. I'm thinking about doing a weighted mean, but I ... 1 vote 2answers 34 views How should I determine an average from a set of averages I have a set of lines. I measure their length each 5 times, and then take the mean of their lengths (as I measure them). I also take the standard deviation. I want to know the 'average' line length. ... 1 vote 1answer 28 views Estimating costs with extreme values I am trying to estimate health care costs and I was wondering what the standard practice is for extreme values? By extreme values I mean I have a large portion of my costs being zero and a small ... 1 vote 1answer 107 views How to compare subjects with different weights? I have a collection of products that could be rated as good or bad. Every product has a grade, that is the sum of "good" votes minus the sum of "bad" votes. These products are also split into two ... 1 vote 1answer 194 views Weighted average of measurements with unequal errors Suppose I have the numbers below. Consider them as results of some measurement. ... 1 vote 1answer 118 views Error on weighted mean I have some measured datapoints. Each of the points has attached an error, depending on how precise the measurement was done. Now I'm using the squared weighted mean with the inverse of the errors as ... 1 vote 0answers 37 views How did they do this analysis? (weighted proportions) I've read with interest the report by Ayanian et al "Racial and Ethnic Disparities among Enrollees in Medicare Advantage Plans" [1]. They have estimated adjusted proportions of individuals that ... 1 vote 0answers 32 views Mean of an interval censored random variable It is likely that I am incorrect terminology here, but I am trying to compute a "mean" of an interval censored random variable. Here is an example where: 1. a random sample from the standard normal ... 1 vote 0answers 60 views Aggregating Standard Errors for Predicted Probability Estimates I obtain predicted values from a logistic regression for a certain outcome (e.g., mortality) at the hospital level – the data is at the patient level – and need to compute the average across ... 1 vote 0answers 61 views Weighted variance of the weighted variance in frequency transition matrix? Assume I have a $m\times n$ Transition Matrix $A$ with $m$ different observations and $n$ represents a discrete state space. Each column counts the frequency that state $j\in [1...n]$ was visited from ... 1 vote 1answer 194 views Compare Log-Normal Distributions I am looking at distributions for the fuel consumption of vehicles in the US and I have two sets of data: Data Set 1 - This is a dataset for the fuel consumption of all vehicles made available for ...
{ "url": "http://stats.stackexchange.com/questions/tagged/weighted-mean?sort=votes&pagesize=15", "source_domain": "stats.stackexchange.com", "snapshot_id": "crawl=CC-MAIN-2015-22", "warc_metadata": { "Content-Length": "176479", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:QL3LSI4DQMR6BPWVRXEZREQEBYC5C6XC", "WARC-Concurrent-To": "<urn:uuid:2f1d53a6-d896-4313-9a4f-a1b0e4323f27>", "WARC-Date": "2015-05-22T20:39:03Z", "WARC-IP-Address": "104.16.12.13", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:XXUNAXSTKHOEB2NRG66BF2WXQSASR7OK", "WARC-Record-ID": "<urn:uuid:3f2487c6-83c8-479d-b8b0-3929e2d2462d>", "WARC-Target-URI": "http://stats.stackexchange.com/questions/tagged/weighted-mean?sort=votes&pagesize=15", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:0cacf7f5-e373-4940-81ac-5566f7297ab3>" }, "warc_info": "robots: classic\r\nhostname: ip-10-180-206-219.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-22\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for May 2015\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 227, 228, 263, 264, 267, 273, 282, 291, 292, 329, 330, 505, 508, 514, 522, 532, 533, 579, 580, 783, 785, 791, 799, 809, 810, 860, 861, 1063, 1065, 1071, 1080, 1090, 1091, 1151, 1152, 1202, 1204, 1210, 1218, 1228, 1229, 1278, 1279, 1480, 1482, 1488, 1497, 1506, 1507, 1560, 1561, 1765, 1767, 1773, 1782, 1791, 1792, 1812, 1813, 2016, 2018, 2024, 2032, 2042, 2043, 2096, 2097, 2301, 2303, 2309, 2318, 2327, 2328, 2367, 2368, 2573, 2575, 2581, 2589, 2598, 2599, 2632, 2633, 2835, 2837, 2843, 2851, 2861, 2862, 2917, 2918, 3114, 3116, 3122, 3130, 3139, 3140, 3206, 3207, 3408, 3410, 3416, 3424, 3434, 3435, 3507, 3508, 3711, 3713, 3719, 3727, 3737, 3738, 3776, 3777, 3981, 3983, 3989, 3998, 4007, 4008, 4049, 4050, 4251, 4253, 4259, 4267, 4277, 4278, 4351, 4352, 4553, 4555, 4561, 4569, 4579, 4580, 4658, 4659, 4858, 4860, 4866, 4874, 4884, 4885, 4944, 4945, 5145, 5147, 5153, 5161, 5171, 5172, 5214, 5215, 5414, 5416, 5422, 5431, 5440, 5441, 5482, 5483, 5686, 5688, 5694, 5702, 5712, 5713, 5759, 5760, 5956, 5958, 5964, 5972, 5982, 5983, 6011, 6012, 6206, 6208, 6214, 6223, 6232, 6233, 6269, 6270, 6447, 6449, 6455, 6463, 6473, 6474, 6546, 6547, 6751, 6753, 6759, 6767, 6776, 6777, 6849, 6850, 7052, 7054, 7060, 7069, 7079, 7080, 7130, 7131, 7330, 7332, 7338, 7347, 7356, 7357, 7452, 7453, 7643, 7645, 7651, 7660, 7669, 7670, 7731, 7732, 7927, 7929, 7935, 7944, 7954, 7955, 8022, 8023, 8217, 8219, 8225, 8234, 8243, 8244, 8295, 8296, 8494, 8496, 8502, 8511, 8520, 8521, 8623, 8624, 8824, 8826, 8832, 8841, 8850, 8851, 8910, 8911, 9111, 9113, 9118, 9127, 9137, 9138, 9256, 9257, 9460, 9462, 9467, 9476, 9486, 9487, 9581, 9582, 9784, 9786, 9791, 9800, 9809, 9810, 9915, 9916, 10120, 10122, 10127, 10136, 10145, 10146, 10185, 10186, 10290, 10292, 10297, 10305, 10315, 10316, 10394, 10395, 10595, 10597, 10602, 10610, 10620, 10621, 10714, 10715, 10911, 10913, 10918, 10926, 10936, 10937, 11017, 11018, 11218, 11220, 11225, 11234, 11244, 11245, 11352, 11353, 11553, 11555, 11560, 11569, 11578, 11579, 11636, 11637, 11840, 11842, 11847, 11855, 11864, 11865, 11902, 11903, 12102, 12104, 12109, 12117, 12127, 12128, 12176, 12177, 12377, 12379, 12384, 12392, 12402, 12403, 12456, 12457, 12541, 12543, 12548, 12556, 12566, 12567, 12590, 12591, 12795, 12797, 12802, 12811, 12820, 12821, 12875, 12876, 13074, 13076, 13081, 13090, 13099, 13100, 13145, 13146, 13348, 13350, 13355, 13364, 13373, 13374, 13438, 13439, 13634, 13636, 13641, 13650, 13659, 13660, 13735, 13736, 13941, 13943, 13948, 13956, 13966, 13967, 14000, 14001 ], "line_end_idx": [ 227, 228, 263, 264, 267, 273, 282, 291, 292, 329, 330, 505, 508, 514, 522, 532, 533, 579, 580, 783, 785, 791, 799, 809, 810, 860, 861, 1063, 1065, 1071, 1080, 1090, 1091, 1151, 1152, 1202, 1204, 1210, 1218, 1228, 1229, 1278, 1279, 1480, 1482, 1488, 1497, 1506, 1507, 1560, 1561, 1765, 1767, 1773, 1782, 1791, 1792, 1812, 1813, 2016, 2018, 2024, 2032, 2042, 2043, 2096, 2097, 2301, 2303, 2309, 2318, 2327, 2328, 2367, 2368, 2573, 2575, 2581, 2589, 2598, 2599, 2632, 2633, 2835, 2837, 2843, 2851, 2861, 2862, 2917, 2918, 3114, 3116, 3122, 3130, 3139, 3140, 3206, 3207, 3408, 3410, 3416, 3424, 3434, 3435, 3507, 3508, 3711, 3713, 3719, 3727, 3737, 3738, 3776, 3777, 3981, 3983, 3989, 3998, 4007, 4008, 4049, 4050, 4251, 4253, 4259, 4267, 4277, 4278, 4351, 4352, 4553, 4555, 4561, 4569, 4579, 4580, 4658, 4659, 4858, 4860, 4866, 4874, 4884, 4885, 4944, 4945, 5145, 5147, 5153, 5161, 5171, 5172, 5214, 5215, 5414, 5416, 5422, 5431, 5440, 5441, 5482, 5483, 5686, 5688, 5694, 5702, 5712, 5713, 5759, 5760, 5956, 5958, 5964, 5972, 5982, 5983, 6011, 6012, 6206, 6208, 6214, 6223, 6232, 6233, 6269, 6270, 6447, 6449, 6455, 6463, 6473, 6474, 6546, 6547, 6751, 6753, 6759, 6767, 6776, 6777, 6849, 6850, 7052, 7054, 7060, 7069, 7079, 7080, 7130, 7131, 7330, 7332, 7338, 7347, 7356, 7357, 7452, 7453, 7643, 7645, 7651, 7660, 7669, 7670, 7731, 7732, 7927, 7929, 7935, 7944, 7954, 7955, 8022, 8023, 8217, 8219, 8225, 8234, 8243, 8244, 8295, 8296, 8494, 8496, 8502, 8511, 8520, 8521, 8623, 8624, 8824, 8826, 8832, 8841, 8850, 8851, 8910, 8911, 9111, 9113, 9118, 9127, 9137, 9138, 9256, 9257, 9460, 9462, 9467, 9476, 9486, 9487, 9581, 9582, 9784, 9786, 9791, 9800, 9809, 9810, 9915, 9916, 10120, 10122, 10127, 10136, 10145, 10146, 10185, 10186, 10290, 10292, 10297, 10305, 10315, 10316, 10394, 10395, 10595, 10597, 10602, 10610, 10620, 10621, 10714, 10715, 10911, 10913, 10918, 10926, 10936, 10937, 11017, 11018, 11218, 11220, 11225, 11234, 11244, 11245, 11352, 11353, 11553, 11555, 11560, 11569, 11578, 11579, 11636, 11637, 11840, 11842, 11847, 11855, 11864, 11865, 11902, 11903, 12102, 12104, 12109, 12117, 12127, 12128, 12176, 12177, 12377, 12379, 12384, 12392, 12402, 12403, 12456, 12457, 12541, 12543, 12548, 12556, 12566, 12567, 12590, 12591, 12795, 12797, 12802, 12811, 12820, 12821, 12875, 12876, 13074, 13076, 13081, 13090, 13099, 13100, 13145, 13146, 13348, 13350, 13355, 13364, 13373, 13374, 13438, 13439, 13634, 13636, 13641, 13650, 13659, 13660, 13735, 13736, 13941, 13943, 13948, 13956, 13966, 13967, 14000, 14001, 14201 ] }
{ "red_pajama_v2": { "ccnet_original_length": 14201, "ccnet_original_nlines": 403, "rps_doc_curly_bracket": 0.00429547019302845, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3472222089767456, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.04629629850387573, "rps_doc_frac_lines_end_with_ellipsis": 0.12376237660646439, "rps_doc_frac_no_alph_words": 0.23247353732585907, "rps_doc_frac_unique_words": 0.31663158535957336, "rps_doc_mean_word_length": 4.591578960418701, "rps_doc_num_sentences": 151, "rps_doc_symbol_to_word_ratio": 0.018187830224633217, "rps_doc_unigram_entropy": 5.639505863189697, "rps_doc_word_count": 2375, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.04759284853935242, "rps_doc_frac_chars_dupe_6grams": 0.013388349674642086, "rps_doc_frac_chars_dupe_7grams": 0.010637319646775723, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.014213659800589085, "rps_doc_frac_chars_top_3gram": 0.009353510104119778, "rps_doc_frac_chars_top_4gram": 0.004126550164073706, "rps_doc_books_importance": -1482.4873046875, "rps_doc_books_importance_length_correction": -1482.4873046875, "rps_doc_openwebtext_importance": -803.54541015625, "rps_doc_openwebtext_importance_length_correction": -803.54541015625, "rps_doc_wikipedia_importance": -696.2809448242188, "rps_doc_wikipedia_importance_length_correction": -696.2809448242188 }, "fasttext": { "dclm": 0.5524505376815796, "english": 0.9354509711265564, "fineweb_edu_approx": 1.5423269271850586, "eai_general_math": 0.8795892000198364, "eai_open_web_math": 0.7384999394416809, "eai_web_code": 0.1731022596359253 } }
{ "free_decimal_correspondence": { "primary": { "code": "519.5", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Probabilities; or, Mathematical statistics" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "4", "label": "Analyze" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "4", "label": "Advanced Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,776,845,843,371,056,000
View Poll Results: Do you like the redesign of the App Catalog? Voters 52. You may not vote on this poll • Yes, the design is better than before. 25 48.08% • No, the design is worse than before. 11 21.15% • I didn't realize anything had changed. 4 7.69% • I don't care either way. 12 23.08% Results 1 to 14 of 14 1.    #1   I was wondering what everyone thinks of the redesign of the App Catalog now that webOS 1.3.5 has come to the Pre and Pixi. I for one think it is a downgrade. There may not be much that has changed, but when looking at the screen for an individual app, there is a lot that just doesn't seem right to me. The new thumbnail behavior. Only one larger thumbnail instead of three smaller ones. I don't necessarily mind that the thumbnail is easier to see what's going on without needing to enlarge, but it is horribly offset by the big empty space that is to the right of it, above the star rating. That is such an unsightly aesthetic that I can't believe it got a green-light. Also, why do the previews cycle through the images like in a slideshow. This forces users to sit at the main screen waiting for an image to change, when they could just tap the preview and view the images full screen. A user will also immediately scroll down to view the app description, so they might not even notice the cycling of the previews at all. And why should you have to tap the App name to get the date, version number and file size? Again, I feel as though people may not even realize you can do this. If you're going to hide info, at least hide *more* info. Like give us the original date the app became available AND the last date it was updated. That seems kind of useful to me. The app description text has also been increased. This to me makes it seem like an ugly web page with the text size blown up so old people, or those who can't see well could view it better. It looks amateurish. If I had access to improving the layout of the screen where you're looking at App info, I would make it so that the image preview could scroll through by swiping within the thumbnail. No enlarging necessary. Just swipe your finger over the thumbnail and the next one is displayed. Either that or add a <- and -> button (think web browser buttons but smaller) right below the image to move back and forth between images in the thumbnail size. Next, Move the star rating to the top of the section to the right of the preview and move the number of reviews to the right of the stars. Underneath keep the "reviews" and "share" buttons, but also add similarly sized buttons for "Web page" and "Support" and remove the links at the bottom of the description. This would make for a much more uniform and streamlined appearance. 2.    #2   Please note: I'm not asking for opinions about the new features that the App Catalog now brings, such as background downloading of apps, etc. I appreciate the new *features* that are available now. I just think the design is terrible. 3. WhoAmI's Avatar Posts 229 Posts Global Posts 257 Global Posts #3   I like the new features (background downloading!) but I'm not a fan of the new design. The old design seamed much more space-efficient if you ask me. --WhoAmI-- Sprint Palm Treo 700p with MR --> Palm Pre T-Money is now available for the webOS! Financial planning has never been easier. 4. #4   I like that the App Catalog is a lot faster and the background downloading is a nice feature. However, I agree with the OPs criticisms and suggestions regarding the thumbnails, star ratings and version numbers. 5. cashen's Avatar Posts 759 Posts Global Posts 773 Global Posts #5   I voted yes, but the one thing i dislike is the photo of the app. I liked how before the images were overlaying each other. 6. #6   In terms of features and speed (background downloading, extremely snappy performance) the new app catalog is worlds better than the previous one. But in terms of visual design, I agree with the OP. I do like the larger screenshot preview, but I also liked the stacked screenshot design from the original App Catalog. Some medium between the two would be better. And yes there is too much empty space next to the screenshot, above the ratings. The larger text is also not as visually appealing. Second, why hide version number and size? It only takes up one line. I understand that you can tap the top to reveal these details, but it's not even apparent that one could do this (I had to read it somewhere else). Seems unintuitive and worse, unnecessary. Finally, the new shade of blue actually makes it harder to read the white text of the App catalog. It needs to be toned down pronto, back to the shade of blue of the original App Catalog. I don't understand why they decided to do that. Oh yeah, search is still broken. You would think searching for "word ace" would bring up the Word Ace app, but nope. 7. #7   the image cycles through screen shots... if theres more then one to show.. 8. #8   Palm needs to come up with a color scheme. Like the app store is 3 shades of blue, the dialer is green, the unlock button is yellow, the other programs are in gray or silver, and all the palm stuff is orange....but the app store looks better. 9. #9   Design is fine....simple, easy and quick to read/find what I'm looking for. 10. #10   I enjoy the design being very simple and clean. On the flip side searching for apps is still not really that efficient. They could do a better job. Also what about adding a star or favorite button or something that allows you to come back to it if you don't want to download it now. I often run across an app I like but don't want to buy at that time. So I have to refind that app instead of maybe going into a favorites page or something. This would come in handy when we start creeping up in total apps. 11. #11   The overall visual design is okay. I've seen better and worse. The major thing that needs fixing is the search function. It just blatantly misses certain titles and seems to have a bias for paid titles versus free ones. It won't bring up most demo/free versions in the search results. If I want to find Crosswords (or Crossword Lite), I have to browse to Games/Puzzles/Word Games to find it. A search yields nothing. Searching for the game's creator (Stand Alone) also yields nothing. I don't know what search algorithm Palm is using, but it's going to be a real problem as the catalog grows if they don't fix it. --Inspector Gadget "Go Go Gadget Pre!!" Palm Pre on Sprint Palm V--> Palm IIIc--> Visor Prism--> Visor Phone--> Treo 270--> Treo 600--> Treo 650--> Treo 700wx--> HTC Touch Diamond--> Palm Pre & HTC EVO 4G. 12. #12   I still think the shade of blue is too light. Doesn't blend well with the white text. 13.    #13   I'm really surprised to see more people voting for liking the new design better. I cant imagine what's to like better about the things they've changed so I'm just going to chalk it up to a few anomalies like: people either not caring or not noticing and just saying they like it anyway. people thinking that I'm asking if they like the updated features and not the actual visual design of the catalog. Posters like ryleyinstl said the "design is fine"... I also think it's "fine" but that's not what I was asking. I was asking if the slight changes they made to the design of the catalog are better or worse, and I think they are worse. Doesn't seem like many people are posting to defend their opinion of why they apparently like it better but I'm stubbornly going to admit that I can't see how anyone could possibly like the catalog better now. 14.    #14   this forum is bumpin Tags for this Thread Posting Permissions
{ "url": "http://forums.webosnation.com/webos-discussion-lounge/221572-app-catalog-v1-0-0-redesign-webos-1-3-5-your-thoughts.html", "source_domain": "forums.webosnation.com", "snapshot_id": "crawl=CC-MAIN-2017-47", "warc_metadata": { "Content-Length": "91644", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:GWYYQ3HSHQPW6Z7ZZL7OD7MMW67ZYWFP", "WARC-Concurrent-To": "<urn:uuid:2b9c22bb-2a73-4e6f-9f9e-9463d607728f>", "WARC-Date": "2017-11-19T12:35:26Z", "WARC-IP-Address": "104.16.189.223", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:E2BO5U2F73BYJIMNZMQHCGYSQWURVPPF", "WARC-Record-ID": "<urn:uuid:6f8c9992-57c0-4bf0-a435-31c44242c623>", "WARC-Target-URI": "http://forums.webosnation.com/webos-discussion-lounge/221572-app-catalog-v1-0-0-redesign-webos-1-3-5-your-thoughts.html", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:927a4e4c-5839-44ae-981f-c73c9b27589f>" }, "warc_info": "robots: classic\r\nhostname: ip-10-236-168-78.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-47\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for November 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 64, 65, 72, 106, 149, 150, 164, 205, 206, 220, 263, 264, 276, 305, 306, 320, 342, 355, 482, 483, 667, 668, 1041, 1042, 1400, 1401, 1745, 1746, 1961, 1962, 2408, 2409, 2792, 2805, 3044, 3065, 3075, 3089, 3106, 3127, 3136, 3290, 3305, 3352, 3353, 3439, 3449, 3664, 3685, 3695, 3709, 3726, 3747, 3756, 3884, 3894, 4044, 4045, 4397, 4398, 4661, 4662, 4902, 4903, 5024, 5034, 5113, 5123, 5370, 5380, 5460, 5472, 5982, 5994, 6061, 6062, 6288, 6289, 6493, 6494, 6627, 6650, 6651, 6676, 6699, 6700, 6793, 6855, 6867, 6957, 6972, 7185, 7186, 7268, 7269, 7388, 7389, 7838, 7853, 7878, 7879, 7900, 7901 ], "line_end_idx": [ 64, 65, 72, 106, 149, 150, 164, 205, 206, 220, 263, 264, 276, 305, 306, 320, 342, 355, 482, 483, 667, 668, 1041, 1042, 1400, 1401, 1745, 1746, 1961, 1962, 2408, 2409, 2792, 2805, 3044, 3065, 3075, 3089, 3106, 3127, 3136, 3290, 3305, 3352, 3353, 3439, 3449, 3664, 3685, 3695, 3709, 3726, 3747, 3756, 3884, 3894, 4044, 4045, 4397, 4398, 4661, 4662, 4902, 4903, 5024, 5034, 5113, 5123, 5370, 5380, 5460, 5472, 5982, 5994, 6061, 6062, 6288, 6289, 6493, 6494, 6627, 6650, 6651, 6676, 6699, 6700, 6793, 6855, 6867, 6957, 6972, 7185, 7186, 7268, 7269, 7388, 7389, 7838, 7853, 7878, 7879, 7900, 7901, 7920 ] }
{ "red_pajama_v2": { "ccnet_original_length": 7920, "ccnet_original_nlines": 103, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4472303092479706, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03206996992230415, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.1848396509885788, "rps_doc_frac_unique_words": 0.3603411614894867, "rps_doc_mean_word_length": 4.189765453338623, "rps_doc_num_sentences": 113, "rps_doc_symbol_to_word_ratio": 0.010495630092918873, "rps_doc_unigram_entropy": 5.471507549285889, "rps_doc_word_count": 1407, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.013910089619457722, "rps_doc_frac_chars_dupe_6grams": 0.008821030147373676, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.012722649611532688, "rps_doc_frac_chars_top_3gram": 0.011026290245354176, "rps_doc_frac_chars_top_4gram": 0.007633590139448643, "rps_doc_books_importance": -492.7873229980469, "rps_doc_books_importance_length_correction": -492.7873229980469, "rps_doc_openwebtext_importance": -397.76409912109375, "rps_doc_openwebtext_importance_length_correction": -397.76409912109375, "rps_doc_wikipedia_importance": -444.0113220214844, "rps_doc_wikipedia_importance_length_correction": -444.0113220214844 }, "fasttext": { "dclm": 0.17867928743362427, "english": 0.963359534740448, "fineweb_edu_approx": 1.005782127380371, "eai_general_math": 0.11636900901794434, "eai_open_web_math": 0.21146619319915771, "eai_web_code": 0.08268082141876221 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.67", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.457", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "5", "label": "Evaluate" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "14", "label": "Reviews/Critiques" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "5", "label": "Comment Section" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-8,855,541,804,746,177,000
Using regex capture group back reference in nested search @emmanuel or @josh Is it possible to use a backreference in a nested search within the “find & replace” action? I am trying to perform a find and replace to update a CID (Inline image) reference within an image tag. Example showing the CID in the src attribute: <img width="599" height="155" id="_x0000_i1025" src="cid:[email protected]" style="width:6.2395in; height:1.6145in"> The below screenshot is where I’m getting the current email body and using a regex to find specific img tags. In the ‘replace by’ I would like to perform a search and use one of the capturing groups as a backreference for the record I want to return. Here’s the nested “Search for” where I’m trying to use the third capture group as a backreference, but this doesn’t appear to work. Is it possible? 1 Like You sort of can, but its a little clumsier than your example. The group reference $3 is out of the regex context. Instead you can put another This Activity's activity.body : find & replace/regex inside the search criteria.
{ "url": "https://forum.bubble.io/t/using-regex-capture-group-back-reference-in-nested-search/21285", "source_domain": "forum.bubble.io", "snapshot_id": "CC-MAIN-2023-50", "warc_metadata": { "Content-Length": "24088", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:3DCNLVHQSGU7R2GQOOU7W3UEU22CYWZA", "WARC-Concurrent-To": "<urn:uuid:20e61e76-eb9a-43c9-ad00-acc590ea1100>", "WARC-Date": "2023-12-08T05:23:34Z", "WARC-IP-Address": "104.16.137.79", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:CBTE6G5IUF64HFDJDSPM2TLTMSQPTLP3", "WARC-Record-ID": "<urn:uuid:a3656200-c4bf-46b3-821d-05ca4c7f0248>", "WARC-Target-URI": "https://forum.bubble.io/t/using-regex-capture-group-back-reference-in-nested-search/21285", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:e9c95feb-2675-4cb1-9a95-d106a8c33c70>" }, "warc_info": "isPartOf: CC-MAIN-2023-50\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November/December 2023\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-252\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 58, 59, 78, 79, 172, 173, 277, 278, 324, 325, 442, 443, 694, 695, 843, 844, 851, 852, 914, 915 ], "line_end_idx": [ 58, 59, 78, 79, 172, 173, 277, 278, 324, 325, 442, 443, 694, 695, 843, 844, 851, 852, 914, 915, 1075 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1075, "ccnet_original_nlines": 20, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3580246865749359, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.02880658023059368, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.23045267164707184, "rps_doc_frac_unique_words": 0.5738636255264282, "rps_doc_mean_word_length": 4.755681991577148, "rps_doc_num_sentences": 12, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.342709064483643, "rps_doc_word_count": 176, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.05017920956015587, "rps_doc_frac_chars_top_3gram": 0.028673840686678886, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -96.64137268066406, "rps_doc_books_importance_length_correction": -96.64137268066406, "rps_doc_openwebtext_importance": -62.282955169677734, "rps_doc_openwebtext_importance_length_correction": -51.26662063598633, "rps_doc_wikipedia_importance": -37.1960563659668, "rps_doc_wikipedia_importance_length_correction": -37.1960563659668 }, "fasttext": { "dclm": 0.030694719403982162, "english": 0.8272759914398193, "fineweb_edu_approx": 1.3933079242706299, "eai_general_math": 0.8375110626220703, "eai_open_web_math": 0.19406777620315552, "eai_web_code": 0.9820945858955383 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.7", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-5,328,747,197,358,137,000
OpenWrt的开机启动服务(init scripts) 参考 https://wiki.openwrt.org/doc/techref/initscripts 以一个简单的例子来说明 #!/bin/sh /etc/rc.common # Example script # Copyright (C) 2007 OpenWrt.org START=10 STOP=15 start() { echo start # commands to launch application } stop() { echo stop # commands to kill application } 第一行shebang #! 使用 /bin/sh /etc/rc.common 作为脚本解释器并在执行脚本前调用 main 和检查脚本 公用的 init script 方法有 start # 启动服务 stop # 停止服务 restart # 重启服务 reload # 重新载入配置文件, 如果失败则重启 enable # 启用开机自启动 disable # 禁用开机自启动 脚本中 start() 和 stop() 是必须的 启动顺序 START= 和 STOP= 决定脚本启动时的次序. 启动时init.d会根据文件名顺序, 自动执行在/etc/rc.d中找到的脚本. 初始化脚本可以作为/etc/init.d/下文件的软链放置在/etc/rc.d/. enable 和 disable 可以自动帮你创建对应的带序号的软链. 这个例子中START=10 会被链接到 /etc/rc.d/S10example, 启动时执行在START=9之后, 在START=11之前. 而STOP=15会被链接到 /etc/rc.d/K15example, 执行在STOP=14之后, 在STOP=16之前. 同一个启动数字的, 按字母顺序启动. 脚本中的 boot() 当存在boot()方法时, 系统启动时会调用boot()而不是start() boot() { echo boot # commands to run on boot } 你可以使用EXTRA_COMMANDS和EXTRA_HELP设置自定义的服务方法 EXTRA_COMMANDS="custom" EXTRA_HELP=" custom Help for the custom command" custom() { echo "custom command" # do your custom stuff } 多个自定义方法的添加 EXTRA_COMMANDS="custom1 custom2 custom3" EXTRA_HELP=<<EOF custom1 Help for the custom1 command custom2 Help for the custom2 command custom3 Help for the custom3 command EOF custom1 () { echo "custom1" # do the stuff for custom1 } custom2 () { echo "custom2" # do the stuff for custom2 } custom3 () { echo "custom3" # do the stuff for custom3 } 快速查询所有服务的自启动状态, 可以使用以下命令 [email protected]:~# for F in /etc/init.d/* ; do $F enabled && echo $F on || echo $F **disabled**; done /etc/init.d/boot on /etc/init.d/bootcount on /etc/init.d/cron on /etc/init.d/dnsmasq on /etc/init.d/done on /etc/init.d/dropbear on /etc/init.d/firewall on /etc/init.d/fstab on /etc/init.d/gpio_switch on /etc/init.d/led on /etc/init.d/log on /etc/init.d/network on /etc/init.d/odhcpd on /etc/init.d/rpcd on /etc/init.d/samba on /etc/init.d/shadowsocks-libev on /etc/init.d/sysctl on /etc/init.d/sysfixtime on /etc/init.d/sysntpd on /etc/init.d/system on /etc/init.d/transmission on /etc/init.d/uhttpd on /etc/init.d/umount **disabled** /etc/init.d/wifidog **disabled** 时间: 2024-02-20 23:58:58 OpenWrt的开机启动服务(init scripts)的相关文章 非root用户执行开机启动服务脚 本 一.需求 centos6下面添加开机服务,例如开机启动supervisor服务,然后supervisor会负责拉起配置的进程,从而实现各种服务的开机重启. 二.原理需求 在centos6下面主要通过在/etc/init.d/下面添加服务脚本和chkconfig命令来完成添加启动服务 添加服务的启停脚本如果需要开机启动服务,或者通过service命令控制服务,必须在/etc/init.d/下面有对应服务的启停脚本,如果我们的服务为supervisor,那么在/etc/init.d/下面对应的启停脚 开机启动服务:chkconfig命令详解 1.查看系统运行级别 # cat /etc/inittab # Default runlevel. The runlevels used are:#   0 - halt (Do NOT set initdefault to this)#   1 - Single user mode#   2 - Multiuser, without NFS (The same as 3, if you do not have networking)#   3 - Full multiuser mode#   如何自己添加开机启动服务 在centos6如何添加开机启动服务 在centos6中启动某项服务都是用一条service的命令跟服务名来启动关闭(重启),或者查看状态的.只要安装某项服务直接service命令就可以执行三种状态,今天就跟我一起来看看怎么用一个简单的小脚本来用service命令执行它并设置成开机启动! #我实现写好了一个名叫mydeamon的脚本 首先看看我的脚本里都写了些什么: case $1 in [Rr][eE][sS][Tt][aA][Rr][Tt])         re        re调用重启 linux chkconfig添加开机启动服务 --add:增加所指定的系统服务,让chkconfig指令得以管理它,并同时在系统启动的叙述文件内增加相关数据: --del:删除所指定的系统服务,不再由chkconfig指令管理,并同时在系统启动的叙述文件内删除相关数据: --level<等级代号>:指定读系统服务要在哪一个执行等级中开启或关毕. 等级代号列表: 等级0表示:表示关机 等级1表示:单用户模式 等级2表示:无网络连接的多用户命令行模式 等级3表示:有网络连接的多用户命令行模式 等级4表示:不可用 等级5表示:带图形界面的多用户 centOS7添加开机启动服务/执行脚本 centOS7添加开机启动服务/执行脚本 /etc/rc.d/rc.local  后追加shell脚本 1 开机启动服务 在centos7中添加开机自启服务非常方便,只需要两条命令(以Jenkins为例): #设置jenkins服务为自启动服务 systemctl enable jenkins.service #启动jenkins服务 systemctl start jenkins.service 2 开机执行脚本 在centos7中增加脚本有两种常用的方法: 修改/etc/rc.d/rc/lo Hortonworks HDP Sandbox定制(配置)开机启动服务(组件) 定制Hortonworks HDP开机启动服务可以这样做:本文原文出处: http://blog.csdn.net/bluishglc/article/details/42109253 严禁任何形式的转载,否则将委托CSDN官方维护权益! 找到文件:/usr/lib/hue/tools/start_scripts/start_deps.mf,Hortonworks HDP启动所有服务和组件的命令都在这个文件中,之所以把这些服务的启动命令写在了一个makefile中而不是一个shell文件,其实就 mysql不能开机启动服务 遇到一件非常郁闷的事情,mysql不能开机启动服务. 用到mysql数据库的时候,需要进入bin目录,手动启动mysqld.exe.非常,非常的不爽. 于是,写了一个小脚本. 设置自己的开机启动服务 在CentOS系统下,主要有两种方法设置自己安装的程序开机启动.1.把启动程序的命令添加到/etc/rc.d/rc.local文件中,比如下面的是设置开机启动httpd. 1 #!/bin/sh 2 # 3 # This script will be executed *after* all the other init scripts. 4 # You can put your own initialization stuff in here if you don't 5 # want to centos7之添加开机启动服务/脚本 一.添加开机启动脚本 #!/bin/bash # THIS FILE IS ADDED FOR COMPATIBILITY PURPOSES # # It is highly advisable to create own systemd services or udev rules # to run scripts during boot instead of using this file. # # In contrast to previous versions due to parall
{ "url": "https://www.biecuoliao.com/pa/MmYbmBM.html", "source_domain": "www.biecuoliao.com", "snapshot_id": "CC-MAIN-2024-10", "warc_metadata": { "Content-Length": "24098", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:DIHSAALOAZZCW2TZPYQBRNRHHYBR47LO", "WARC-Concurrent-To": "<urn:uuid:7c354f5f-f2d6-4ac2-ba71-aa4520999f9d>", "WARC-Date": "2024-02-24T02:58:14Z", "WARC-IP-Address": "123.253.226.77", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:UDTQ6O675IIKGGKTBKPKMYSA4Q62AYQD", "WARC-Record-ID": "<urn:uuid:d657158d-7b0e-491f-b2ee-190b51c11d88>", "WARC-Target-URI": "https://www.biecuoliao.com/pa/MmYbmBM.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:18752d28-e598-452c-aa6c-911c28020e13>" }, "warc_info": "isPartOf: CC-MAIN-2024-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February/March 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-78\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 29, 30, 82, 83, 95, 96, 121, 138, 171, 172, 181, 189, 190, 200, 219, 260, 279, 280, 289, 307, 346, 348, 349, 417, 418, 438, 439, 454, 469, 484, 512, 530, 549, 550, 576, 577, 582, 583, 729, 730, 883, 884, 896, 897, 936, 937, 946, 960, 990, 992, 993, 1034, 1035, 1059, 1116, 1117, 1128, 1154, 1181, 1183, 1184, 1195, 1196, 1237, 1254, 1295, 1336, 1377, 1381, 1382, 1395, 1414, 1445, 1447, 1460, 1479, 1510, 1512, 1525, 1544, 1575, 1577, 1578, 1603, 1604, 1689, 1708, 1728, 1753, 1773, 1796, 1816, 1840, 1864, 1885, 1912, 1931, 1950, 1973, 1995, 2015, 2036, 2069, 2091, 2117, 2140, 2162, 2190, 2212, 2244, 2277, 2301, 2302, 2336, 2337, 2356, 2357, 2608, 2609, 2630, 2631, 2881, 2882, 2895, 2896, 3147, 3148, 3172, 3173, 3423, 3424, 3445, 3446, 3697, 3698, 3738, 3739, 3990, 3991, 4005, 4006, 4094, 4095, 4107, 4108, 4358, 4359, 4379, 4380 ], "line_end_idx": [ 29, 30, 82, 83, 95, 96, 121, 138, 171, 172, 181, 189, 190, 200, 219, 260, 279, 280, 289, 307, 346, 348, 349, 417, 418, 438, 439, 454, 469, 484, 512, 530, 549, 550, 576, 577, 582, 583, 729, 730, 883, 884, 896, 897, 936, 937, 946, 960, 990, 992, 993, 1034, 1035, 1059, 1116, 1117, 1128, 1154, 1181, 1183, 1184, 1195, 1196, 1237, 1254, 1295, 1336, 1377, 1381, 1382, 1395, 1414, 1445, 1447, 1460, 1479, 1510, 1512, 1525, 1544, 1575, 1577, 1578, 1603, 1604, 1689, 1708, 1728, 1753, 1773, 1796, 1816, 1840, 1864, 1885, 1912, 1931, 1950, 1973, 1995, 2015, 2036, 2069, 2091, 2117, 2140, 2162, 2190, 2212, 2244, 2277, 2301, 2302, 2336, 2337, 2356, 2357, 2608, 2609, 2630, 2631, 2881, 2882, 2895, 2896, 3147, 3148, 3172, 3173, 3423, 3424, 3445, 3446, 3697, 3698, 3738, 3739, 3990, 3991, 4005, 4006, 4094, 4095, 4107, 4108, 4358, 4359, 4379, 4380, 4630 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4630, "ccnet_original_nlines": 149, "rps_doc_curly_bracket": 0.003023759927600622, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.15965582430362701, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03346079960465431, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.5133843421936035, "rps_doc_frac_unique_words": 0.6212871074676514, "rps_doc_mean_word_length": 8.690593719482422, "rps_doc_num_sentences": 81, "rps_doc_symbol_to_word_ratio": 0.03824092075228691, "rps_doc_unigram_entropy": 5.167178153991699, "rps_doc_word_count": 404, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.007974940352141857, "rps_doc_frac_chars_top_3gram": 0.01139277033507824, "rps_doc_frac_chars_top_4gram": 0.011107949540019035, "rps_doc_books_importance": -351.7353210449219, "rps_doc_books_importance_length_correction": -351.7353210449219, "rps_doc_openwebtext_importance": -211.4479217529297, "rps_doc_openwebtext_importance_length_correction": -211.4479217529297, "rps_doc_wikipedia_importance": 34.11212921142578, "rps_doc_wikipedia_importance_length_correction": 34.11212921142578 }, "fasttext": { "dclm": 0.3337423801422119, "english": 0.10312808305025101, "fineweb_edu_approx": 1.625962257385254, "eai_general_math": 0.5179615020751953, "eai_open_web_math": 0.04906601086258888, "eai_web_code": 0.4886314272880554 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.0285", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
7,358,174,227,805,055,000
Is there a way to control both Order By and Order query parameters from one input field Is there a way to control both Order By and Order query parameters from one input field - Top view layout of costume of traveler with notepad and knife placed near photo camera and lenses on surface near diary with map I want to give the user the ability to order posts by post date/alphabetically either on ASC or DESC order through a select input on an archive page. The easy way would be to show two inputs on the front end: one controlling the order_by parameter, and other controlling the order parameter. But it would be a lot better if it were just one select input field with four options: • Latest • Oldest • Alphabetical A-Z • Alphabetical Z-A I tried cheating, using & inside each option's value, but it gets automatically escaped on the URL. <form action=""> <select name="orderby" id=""> <option value="post_date&order=DESC">Latest</option> <option value="post_date&order=ASC">Oldest</option> <option value="post_title&order=ASC">Alphabetical A-Z</option> <option value="post_title&order=DESC">Alphabetical A-Z</option> </select> <button>Filter</button> </form> This code gives me a URL like this: http://example.com/?orderby=post_date%26order%3DASC I could do it easily with javascript, or with PHP, but I wanted to know if there was a better solution. Best Answer There are many ways you could proceed. Here is one. I would defined the four options like this: function fetch_order_from_form( $query ){ if( $query->is_page( ThePAGEID ) && $query->is_main_query() && (isset($_POST["orderby"]) && !empty($_POST["orderby"])) ) { if( $_POST["orderby"]) == 1){ $query->set( 'orderby', 'date' ); $query->set( 'order', 'ASC' ); } elseif( $_POST["orderby"]) ==2 ){ $query->set( 'orderby', 'date' ); $query->set( 'order', 'DESC' ); } elseif( $_POST["orderby"]) ==2 ){ $query->set( 'orderby', 'title' ); $query->set( 'order', 'ASC' ); } elseif( $_POST["orderby"]) ==2 ){ $query->set( 'orderby', 'title' ); $query->set( 'order', 'DESC' ); } } } add_action( 'pre_get_posts', 'fetch_order_from_form' ); Pictures about "Is there a way to control both Order By and Order query parameters from one input field" Is there a way to control both Order By and Order query parameters from one input field - Men In Black Clothes Wearing Masks Is there a way to control both Order By and Order query parameters from one input field - Back view of anonymous policeman in helmet and bulletproof vest maintaining law and order while standing on city street Is there a way to control both Order By and Order query parameters from one input field - Rural Field in Order Does order matter in query parameters? A properly written application will find a given query parameter in any order and will not be order sensitive. How do I pass two parameters in query string? Passing Multiple Parameters for QueryString To pass multiple parameters, we will use \u201c&\u201d symbol to separate the other field and value combinations. On button click (from code behind), redirect to another page with two QueryString parameters. How do I pass multiple query parameters in REST URL? Query parameters are passed after the URL string by appending a question mark followed by the parameter name , then equal to (\u201c=\u201d) sign and then the parameter value. Multiple parameters are separated by \u201c&\u201d symbol. How do I pass multiple values in API? Pass Multiple Parameters in URL in Web API • In the "Solution Explorer". • Expand the "Views" folder. • Select "Home" -> "Index. cshtml". Add the following code: @{ ViewBag. Title = "Index"; } <h3>Passing multiple parameter in URL</h3> @using (Html. BeginForm("index", "Home")) { <a href="/home/MultipleParameter/? • Wordpress: Is there a way to control both Order By and Order query parameters from one input field Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0. Images: Rachel Claire, cottonbro, Mathias Reding, Mark Stebnicki
{ "url": "https://www.all4wordpress.com/is-there-a-way-to-control-both-order-by-and-order-query-parameters-from-one-input-field", "source_domain": "www.all4wordpress.com", "snapshot_id": "CC-MAIN-2023-40", "warc_metadata": { "Content-Length": "33933", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:CQ342QWDZNCDGMZR3ZPOEGYGYC4GUKLO", "WARC-Concurrent-To": "<urn:uuid:7fe3701f-b8b2-4b39-89d9-a7c37eaec488>", "WARC-Date": "2023-09-30T19:02:09Z", "WARC-IP-Address": "143.110.226.245", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:6UOABBVT27QER34VAJAFWPD7XC3YA7K2", "WARC-Record-ID": "<urn:uuid:662bcdf6-6cdf-4853-9743-973f5e2728ad>", "WARC-Target-URI": "https://www.all4wordpress.com/is-there-a-way-to-control-both-order-by-and-order-query-parameters-from-one-input-field", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:4a0d55e3-fe66-4e17-8db0-ab5e71571550>" }, "warc_info": "isPartOf: CC-MAIN-2023-40\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September/October 2023\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-200\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 88, 89, 308, 309, 459, 460, 602, 603, 690, 691, 702, 713, 734, 755, 756, 856, 857, 874, 908, 969, 1029, 1100, 1172, 1186, 1214, 1222, 1223, 1311, 1312, 1416, 1417, 1418, 1430, 1431, 1483, 1484, 1528, 1529, 1571, 1698, 1736, 1782, 1825, 1835, 1877, 1923, 1967, 1977, 2019, 2066, 2109, 2119, 2161, 2208, 2252, 2262, 2268, 2270, 2326, 2327, 2328, 2329, 2434, 2435, 2560, 2770, 2881, 2882, 2883, 2884, 2923, 2924, 3035, 3036, 3082, 3083, 3335, 3336, 3389, 3390, 3625, 3626, 3664, 3665, 3708, 3740, 3771, 3986, 3987, 3988, 3989, 3990, 4093, 4094, 4095, 4096, 4097, 4231, 4232 ], "line_end_idx": [ 88, 89, 308, 309, 459, 460, 602, 603, 690, 691, 702, 713, 734, 755, 756, 856, 857, 874, 908, 969, 1029, 1100, 1172, 1186, 1214, 1222, 1223, 1311, 1312, 1416, 1417, 1418, 1430, 1431, 1483, 1484, 1528, 1529, 1571, 1698, 1736, 1782, 1825, 1835, 1877, 1923, 1967, 1977, 2019, 2066, 2109, 2119, 2161, 2208, 2252, 2262, 2268, 2270, 2326, 2327, 2328, 2329, 2434, 2435, 2560, 2770, 2881, 2882, 2883, 2884, 2923, 2924, 3035, 3036, 3082, 3083, 3335, 3336, 3389, 3390, 3625, 3626, 3664, 3665, 3708, 3740, 3771, 3986, 3987, 3988, 3989, 3990, 4093, 4094, 4095, 4096, 4097, 4231, 4232, 4300 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4300, "ccnet_original_nlines": 99, "rps_doc_curly_bracket": 0.003488369984552264, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2475138157606125, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05193369835615158, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.30718231201171875, "rps_doc_frac_unique_words": 0.41522490978240967, "rps_doc_mean_word_length": 5.2231831550598145, "rps_doc_num_sentences": 28, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.950775146484375, "rps_doc_word_count": 578, "rps_doc_frac_chars_dupe_10grams": 0.16462405025959015, "rps_doc_frac_chars_dupe_5grams": 0.23948326706886292, "rps_doc_frac_chars_dupe_6grams": 0.2156343162059784, "rps_doc_frac_chars_dupe_7grams": 0.2156343162059784, "rps_doc_frac_chars_dupe_8grams": 0.2156343162059784, "rps_doc_frac_chars_dupe_9grams": 0.16462405025959015, "rps_doc_frac_chars_top_2gram": 0.04968532919883728, "rps_doc_frac_chars_top_3gram": 0.01854919083416462, "rps_doc_frac_chars_top_4gram": 0.025505129247903824, "rps_doc_books_importance": -494.1138610839844, "rps_doc_books_importance_length_correction": -494.1138610839844, "rps_doc_openwebtext_importance": -304.1083679199219, "rps_doc_openwebtext_importance_length_correction": -304.1083679199219, "rps_doc_wikipedia_importance": -242.00599670410156, "rps_doc_wikipedia_importance_length_correction": -242.00599670410156 }, "fasttext": { "dclm": 0.3449305295944214, "english": 0.6955710053443909, "fineweb_edu_approx": 1.7417906522750854, "eai_general_math": 0.4099818468093872, "eai_open_web_math": 0.09858065843582153, "eai_web_code": 0.5154440999031067 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
218,924,173,970,184,740
Iscriviti al feed CLH-MonitorGlow-Horizontal This post is brought to you by Command Line Heroes, an original podcast from Red Hat. In the summer of my 14th year, I needed a new computer. Kids today need things all the time, but I really needed a new computer. Why? Because the PC clone I shared with my dad had a 286 processor and Linux® required at least a 386. I tried the Slackware boot disk one of my dad’s colleagues gave me anyway, but the screen would display “LI” and then freeze, two letters shy of the “LILO” it would print when the bootloader was successful. The kernel just didn’t know what to do with my antiquated processor. I spent a lot of time looking at a frozen screen with nothing but “LI_” on it. So I made a deal with my dad (I earn half, you pay half) and got a McJob. Three months later, I had saved $250–half the amount needed to buy a used 386dx40 from some random computer store in the classified section of the Rocky Mountain News. I gave up my summer for Linux. Ok, so I wasn’t going to be outside playing football or something, but it was still summer and I spent it filling sodas. Why did I care about Linux that much? Let’s turn the clock back a little. A year before that, I got a 2400bps modem for my birthday. Dialing into small BBS systems was a unique thrill. The local BBS community showed traces of life everywhere – software, message boards, welcome screens – but never any actual people. It was exciting and unfulfilling at the same time, and there was only so much I could explore without running up the phone bill. After a season or two I had pretty much exhausted the entertainment potential of the reachable BBS universe. A friend from high school had clued our social circle into this thing called Nyx at the University of Denver. Nyx was a Unix machine - with a modem bank and internet connection - that offered free accounts to all those willing to prove their identity with a notarized form. I had to find my birth certificate, which was no small feat, but it sounded different and interesting and I wanted in. Nyx was my Hogwarts. On this magical system, which at the time was a SparcServer 2, I first discovered the mysteries of Unix and the Internet. Magic power one: I can figure stuff out by myself The most fundamental magic of Unix lies in its modularity. Its extreme modularity. When you type “ls” to view the contents of a directory, it is actually running a small program called “ls”. You can go find that program and inspect it to see what other technology it relies on. You can find out who wrote it, or get an exhaustive list of its features. You can replace it with something else if you want to. I don’t know why you would, but you could. The same is true for every other thing that happens in a Unix system. As I explored Nyx, it became clear to me where the administrators had made simple and effective alterations to customize the system for its purpose. Each program in Unix can accept input and create output. You can pass one command’s output (STDOUT) into another command’s input (STDIN) simply by typing them both on the command line with a pipe symbol (‘|’) in between them. You can also write the STDOUT of a command to a file, or read a file as STDIN to a command, using more simple bits of single-character syntax. Unix makes it easy to tie programs together in these basic ways. You can deal with pipes and redirect commands to files in the DOS shell too, but I did not encounter it often enough to take much note. On Nyx, it was everywhere I looked. The shell, which starts when you log in and allows you to issue commands interactively, is itself a neat bit of engineering magic. Unix shells are real-time programming environments, commonly used for navigating through files and directories and running commands but capable of a whole lot more. If you find yourself doing the same task over and over again, you can usually automate it with a shell script. The system is littered with nicely commented shell scripts that teach you how, and every piece has a built-in manual. The DOS command line knows how to do a few dozen things that it was told to do by its programmers; the Unix shell is a real-time engine that changes all the time and runs your code as you need it. Shells first taught me what it means, at the most basic levels, to program something and operate it at the same time. Early DevOps firms were Linux shops, and I think the reason can be found deep inside the DNA of Linux, in the shell. To operate Unix is to develop on it. Unix implemented the basics of integration half a century ago, making it easy to tie software together on the fly with muscle memory. Everything we have built on top has conformed to basic expectations and capabilities as a result. Today’s leading-edge computing platforms are based on the fundamental flexibility of the Unix architecture. Unix is modular because it’s hard to solve big problems and it’s easy to solve small ones. And because sometimes you know you’re going to solve parts of your problem over and over again in different ways. Plus, it wasn’t created by a single person or company – modularity allowed for small parts of it to be written by different people in different places over long periods of time. Being modular is great. As a user, this matters because it makes everything easy to figure out. If you don’t know how to get a directory listing in exactly the way you want, you can assume that ‘ls’ is a discrete program with a man page. That means you can learn about it. If it ends up calling other programs, you can learn about them too. If you have a lot of time on your hands (and, as a teenager, I did) you can follow a virtually endless path, each discovery as intuitive and effortless as the last. Magic power two: It connects me with other people I remember the first time I learned I was not alone. One day, on Nyx, I typed “w” and hit return–I forget why–and saw a list of names and programs. It scrolled on forever, which might be the first time I learned to connect its STDOUT to something that would buffer it and wait for a keystroke after each full page of content. Each line in the list was another logged-in person, and each corresponding program was the thing they were currently working on. Other people were using this machine, same as me, editing files and running compilers. There I was, running “w”. And someone else was running “w” too! They were looking to see who was doing what, and saw me doing the same. What are the chances of that? Actually, it happened more often than you’d think. As it turns out, when people share space with one another they end up being curious about what everyone else is doing...and that’s exactly what was going on here. People were sharing space, and it was making them curious. When Unix was created, computers were unbelievably expensive. So expensive that nobody owned one for their personal use, and every last resource was shared. That meant that Unix needed to establish the basics of ownership and exclusivity: some things belong to individuals or groups while others are only made available for periods of time. By the time PCs were common, people could afford their own computers and no longer needed a multi-user operating system. There was a computer at every desk, and DOS was the blunt result: simpler, less capable, inelegant, and antisocial. Everything was in upper case, like the system was screaming at you. It was coarse and uninviting. But then, why have a nice living room when nobody ever comes over? Unix is, by its very nature, a social platform. People share technologies, processor time, memory, and storage in real time. They can communicate with one another in a variety of ways. It’s no surprise that the same community that thrived in the early Unix era spawned the free software movement that is still strong today. Sharing resources thoughtfully in pursuit of a shared goal, as it turns out, is still a good idea even when resources aren’t painfully scarce. Of course, with public spaces come private spaces. What kind of multi-user system would it be if nothing was off limits? Nyx was what you might call a massively shared system–more than 8000 users–and it had taken precautions. There were basic programs (like telnet) that normal users were not allowed to run. There were mysteriously locked doors all over the place, and I wanted to see what was behind them. I wanted to be an admin. At that time, I didn’t even know what root was, I just wanted to be in that “admin” group that owned all the areas I wanted to look into. I think it’s worth pointing out that I was very fortunate to have access to a Unix system at the age of 13. It was virtually unheard of for a college to make that kind of resource available to the general public. The brainchild of Professor Andrew Burt, who ran it on a shoestring budget, Nyx was barely tolerated by the campus authorities. But if Nyx was my Hogwarts, Professor Burt was its Dumbledore. I never met him, and never interacted with him directly, but I knew he was doing wholesome work and his name carried weight. So I respected the closed doors I encountered, even though they did make me curious. I wanted to have my own system. My guidance counselor asked for my 5-year life goal after high school, and my answer was “to get paid to operate a real Unix system with actual users, and to have root.” We never spoke again. I guess he didn’t have much advice to offer about getting root. He probably thought I had a decent shot at whatever I was talking about. When I first tried to install Linux on my hard-earned 386 with those SLS disks, it failed about halfway through. Naturally, one of the floppies was bad. With dozens of disks in the set, the chances were very good that one was going to fail. Floppies were terrible. I had no extras, so I opted for a very minimal distribution called MCC. It came in a handful of packages and required you to build everything you wanted to use. I didn’t think I wanted to use very much until I started building, quickly realizing that everything I needed had cascading dependencies. It was the best way to learn. I built the entire stack myself, exactly how my system needed it, exactly how I wanted. I built the leanest kernel I could for my meager hardware. You don’t see doors the same way when you’ve built all the walls yourself. Linux was my Unix, and it was totally worth smelling like fries all summer. Magic power three: It’s everywhere, and so am I For the first 13 years of my life, I lived in a world where computing existed but networking did not. A computer was a thing that edited documents, managed rudimentary budgets, printed multi-page sideways “happy birthday” banners, and–most importantly of all–ran my arbitrary BASIC programs. Having only the IBM BASIC manual and my dad’s code as a guide, my projects were very limited in scope. You can only learn so much from a few thousand lines of source material. There was a section in the PC manual on the topic of communications. And wow, did they big it up from a terminology perspective; it wasn’t just about sending bits across a phone line. They described a fabric of systems, each one gathering mass and potential–both computing and social–as it parlayed with the next. It showed the contrasting lone computer, desolate and limited. It was huge. Or it seemed that way to me at the time because I didn’t have a modem. And also maybe because I was a child with absolutely zero chance of getting one. It was clear to me, though, that my PC was really designed to be an island. You could build bridges to exciting lands, but only with great effort. Not all programs assumed you could connect to anything else. In fact, it required specialized programs just to connect to anything. Unix systems, or relatively recent ones starting a few decades back, more or less assumed connectivity of some kind. A very visible, if basic, sign of this assumption is the hostname: every Unix host knows what its own name is. Why would that be the case, unless it expected to encounter things from other peers? I learned that running a program on a remote host was almost as easy as running one locally, even if it took longer on the arcane networks of old. As I traversed the system I read manual pages on every program I could think of, and at the bottom of each one was a list of the author’s email addresses. There were signs of other people everywhere I looked. Not only people from Nyx, but from other systems. Often they were from systems in different countries. It was its own society, its own collection of small communities. There was a basic assumption that users knew how to reach people and get to remote things, and people did. The notion of an isolated Unix server is, well, kind of bizarre. I remember coming home from school and logging into Nyx–sometimes having to dial for minutes or even hours until a line freed up–so I could see if my friends were online and ready to play NyxMud or jump into IRC together. From everything I saw, Unix was built to connect people. The magic endures A Unix system resembles a dust cloud of tiny pieces of technology, each piece serving a distinct purpose, each piece replaceable, each piece deterministic. No piece attempts to solve a problem that’s unreasonably hard; together, they are too complicated to be held in any single brain at once. Unix is inherently social, and created social behaviors we all still benefit from. Unix is everywhere. A lot of you are using laptops powered by Unix today. The first laptop I purchased with my own money was a Powerbook G4, and I bought it because it was the best Unix laptop I could find. It remains the most popular Unix-based laptop today (although most people don’t know it so the point is somewhat lost). And if you don’t carry Unix in your bag, almost all of you carry Unix in your pockets (although, again, not that you’d know it). Linux is what most people think of today when they hear “Unix.” Linux has built an entire universe, colorful and vast, based on the fundamental “rules of physics” established by Unix half a century ago. We all use it thousands of times every day. Linux powers Android and its multitude of devices–some you have heard of and many millions you have not. Linux lives inside routers, small and slim, optimized to keep your video stream smooth, and it lives inside your home NAS (if you have one). It powers just about every datacenter and every cloud service. Every service, period. Everything. You can’t order a pizza, board an airplane, spend money, have money, read the news, or enjoy a major motion picture without it. But for me, Linux was even more than that. It was a gateway to a world full of possibilities, and it had a profound impact on the person I am today. Linux rewarded me for curiosity, lighting a fire that still burns inside me 25 years later and - I know it seems trite - gave me a sense of purpose when I needed it most. The community drew me in, connecting me with people who cared about the same things I care about. We marveled at the same magic and, together, we found our belonging. Want to hear more stories about the OS? Check out @ThomasDCameron's post on going from police officer to open source devotee. Subscribe to Command Line Heroes, an original podcast by Red Hat, and be sure to follow Ross on Twitter at @rossturk. Sull'autore UI_Icon-Red_Hat-Close-A-Black-RGB Ricerca per canale automation icon Automazione Novità sull'automazione IT di tecnologie, team e ambienti AI icon Intelligenza artificiale Aggiornamenti sulle piattaforme che consentono alle aziende di eseguire carichi di lavoro IA ovunque open hybrid cloud icon Hybrid cloud open source Scopri come affrontare il futuro in modo più agile grazie al cloud ibrido security icon Sicurezza Le ultime novità sulle nostre soluzioni per ridurre i rischi nelle tecnologie e negli ambienti edge icon Edge computing Aggiornamenti sulle piattaforme che semplificano l'operatività edge Infrastructure icon Infrastruttura Le ultime novità sulla piattaforma Linux aziendale leader a livello mondiale application development icon Applicazioni Approfondimenti sulle nostre soluzioni alle sfide applicative più difficili Original series icon Serie originali Raccontiamo le interessanti storie di leader e creatori di tecnologie pensate per le aziende
{ "url": "https://www.redhat.com/it/blog/linux-and-enduring-magic-unix", "source_domain": "www.redhat.com", "snapshot_id": "CC-MAIN-2024-26", "warc_metadata": { "Content-Length": "257929", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:HGW7PN5HQNUJ7NJTXHIQLN6BEN24YKAI", "WARC-Concurrent-To": "<urn:uuid:1af1a09b-f787-4f25-a4f2-026b8da12e09>", "WARC-Date": "2024-06-15T18:31:59Z", "WARC-IP-Address": "23.213.73.214", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:5UWRBXXZPMUDZNHOHAUO763IVBFO6CT3", "WARC-Record-ID": "<urn:uuid:854bc8fd-586b-47c4-b4a3-fb92b4559308>", "WARC-Target-URI": "https://www.redhat.com/it/blog/linux-and-enduring-magic-unix", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:725edf40-9e87-4f83-af89-df2c10b655c2>" }, "warc_info": "isPartOf: CC-MAIN-2024-26\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-185\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 18, 19, 132, 133, 189, 190, 573, 574, 722, 723, 1155, 1156, 1673, 1674, 2067, 2068, 2211, 2212, 2262, 2263, 2346, 2347, 2933, 2934, 3540, 3541, 4066, 4067, 4536, 4537, 4877, 4878, 5285, 5286, 5768, 5769, 5819, 5820, 5873, 5874, 6276, 6277, 6803, 6804, 7145, 7146, 7548, 7549, 8016, 8017, 8588, 8589, 9203, 9204, 9565, 9566, 10130, 10131, 10459, 10460, 10508, 10509, 10977, 10978, 11355, 11356, 11800, 11801, 12416, 12417, 12811, 12812, 13091, 13092, 13110, 13111, 13488, 13489, 13945, 13946, 14193, 14194, 14666, 14667, 15154, 15155, 15195, 15196, 15282, 15283, 15401, 15402, 15403, 15415, 15416, 15450, 15451, 15470, 15471, 15487, 15488, 15500, 15501, 15559, 15560, 15568, 15569, 15594, 15595, 15696, 15697, 15720, 15721, 15746, 15747, 15821, 15822, 15836, 15837, 15847, 15848, 15943, 15944, 15954, 15955, 15970, 15971, 16039, 16040, 16060, 16061, 16076, 16077, 16154, 16155, 16184, 16185, 16198, 16199, 16275, 16276, 16297, 16298, 16314, 16315 ], "line_end_idx": [ 18, 19, 132, 133, 189, 190, 573, 574, 722, 723, 1155, 1156, 1673, 1674, 2067, 2068, 2211, 2212, 2262, 2263, 2346, 2347, 2933, 2934, 3540, 3541, 4066, 4067, 4536, 4537, 4877, 4878, 5285, 5286, 5768, 5769, 5819, 5820, 5873, 5874, 6276, 6277, 6803, 6804, 7145, 7146, 7548, 7549, 8016, 8017, 8588, 8589, 9203, 9204, 9565, 9566, 10130, 10131, 10459, 10460, 10508, 10509, 10977, 10978, 11355, 11356, 11800, 11801, 12416, 12417, 12811, 12812, 13091, 13092, 13110, 13111, 13488, 13489, 13945, 13946, 14193, 14194, 14666, 14667, 15154, 15155, 15195, 15196, 15282, 15283, 15401, 15402, 15403, 15415, 15416, 15450, 15451, 15470, 15471, 15487, 15488, 15500, 15501, 15559, 15560, 15568, 15569, 15594, 15595, 15696, 15697, 15720, 15721, 15746, 15747, 15821, 15822, 15836, 15837, 15847, 15848, 15943, 15944, 15954, 15955, 15970, 15971, 16039, 16040, 16060, 16061, 16076, 16077, 16154, 16155, 16184, 16185, 16198, 16199, 16275, 16276, 16297, 16298, 16314, 16315, 16407 ] }
{ "red_pajama_v2": { "ccnet_original_length": 16407, "ccnet_original_nlines": 145, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4356639087200165, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03407755866646767, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.13160987198352814, "rps_doc_frac_unique_words": 0.347466379404068, "rps_doc_mean_word_length": 4.5022406578063965, "rps_doc_num_sentences": 169, "rps_doc_symbol_to_word_ratio": 0.00029376999009400606, "rps_doc_unigram_entropy": 5.978165626525879, "rps_doc_word_count": 2901, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.008268889971077442, "rps_doc_frac_chars_dupe_6grams": 0.005206339992582798, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.005359469912946224, "rps_doc_frac_chars_top_3gram": 0.003445369889959693, "rps_doc_frac_chars_top_4gram": 0.002909430069848895, "rps_doc_books_importance": -1650.3741455078125, "rps_doc_books_importance_length_correction": -1650.3741455078125, "rps_doc_openwebtext_importance": -903.0015258789062, "rps_doc_openwebtext_importance_length_correction": -903.0015258789062, "rps_doc_wikipedia_importance": -943.328857421875, "rps_doc_wikipedia_importance_length_correction": -943.328857421875 }, "fasttext": { "dclm": 0.21850234270095825, "english": 0.9738587737083435, "fineweb_edu_approx": 1.9345096349716187, "eai_general_math": 0.419460654258728, "eai_open_web_math": 0.2685367465019226, "eai_web_code": 0.2596336007118225 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "004.09", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "9", "label": "Personal/Misc" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "16", "label": "Personal Blog" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
-7,233,029,429,784,541,000
approve/reject through dropdownlist. Posted by Diyaayeshaa under ASP.NET on 10/4/2013 | Points: 10 | Views : 753 | Status : [Member] | Replies : 1 previously i try to approve /reject thrugh buttons and i try to code it but now i try to approve/reject through dropdownlist but i dont know how i code though dropdownlist.... this is code when i add buttons of approve and reject.. protected void GrdFileApprove_RowCommand(object sender, GridViewCommandEventArgs e) { if (e.CommandName == "_Approve") { //using (SqlConnection con = DataAccess.GetConnected()) using (SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["mydms"].ConnectionString)) { try { con.Open(); int rowindex = Convert.ToInt32(e.CommandArgument); GridViewRow row = (GridViewRow)((Control)e.CommandSource).NamingContainer; Button Prove_Button = (Button)row.FindControl("BtnApprove"); SqlCommand cmd = new SqlCommand("approveee", con); //cmd.CommandType = CommandType.StoredProcedure; cmd.CommandType = CommandType.StoredProcedure; //con.Execute("approve", new { UserID, DocID, ApproveID }); cmd.Parameters.Add(new SqlParameter("@UserID", UserID)); cmd.Parameters.Add(new SqlParameter("@DocID", DocID)); //cmd.Parameters.Add("ApproveID", (object)ApproveID ?? DBNull.Value); cmd.Parameters.Add(new SqlParameter("@ApproveID", ApproveID)); int result = cmd.ExecuteNonQuery(); if (result != 0) { GrdFileApprove.DataBind(); } } catch { apfi.Text = "Not Approve"; } finally { con.Close(); } } } else if (e.CommandName == "_Reject") { using (SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings["mydms"].ConnectionString)) { try { con.Open(); int rowindex = Convert.ToInt32(e.CommandArgument); GridViewRow row = (GridViewRow)((Control)e.CommandSource).NamingContainer; LinkButton Prove_Button = (LinkButton)row.FindControl("Button1"); SqlCommand cmd = new SqlCommand("sprejectapprove", con); cmd.CommandType = CommandType.StoredProcedure; cmd.Parameters.Add(new SqlParameter("@UserID",UserID)); cmd.Parameters.Add(new SqlParameter("@DocID", DocID)); cmd.Parameters.Add(new SqlParameter("@ApproveID", ApproveID)); int result = cmd.ExecuteNonQuery(); if (result != 0) { GrdFileApprove.DataBind(); } } catch { apfi.Text = "Rejct"; } finally { con.Close(); } } } } plzz can any one tell me how i done with dropdownlist? Responses Posted by: Diyaayeshaa on: 10/4/2013 [Member] Starter | Points: 25 Up 0 Down this is grdivew html <asp:GridView ID="GrdFileApprove" runat="server" BackColor="White" BorderColor="#336666" BorderStyle="Double" BorderWidth="3px" CellPadding="4" GridLines="Horizontal" AutoGenerateColumns="False" onrowcommand="GrdFileApprove_RowCommand" OnRowDataBound="OnRowDataBound" > <Columns> <asp:TemplateField HeaderText="S no"> <ItemTemplate> <%# Container.DataItemIndex+1 %> <asp:HiddenField runat="server" ID="HdnFileID" Value='<%# Eval("DocID") %>' /> </ItemTemplate> </asp:TemplateField> <asp:BoundField DataField="DocID" HeaderText="DocumentID" /> <asp:BoundField DataField="DocName" HeaderText="DocName" /> <asp:BoundField DataField="Uploadfile" HeaderText="File Name" /> <asp:BoundField DataField="DocType" HeaderText="Document" /> <asp:BoundField DataField="DepType" HeaderText="Department" /> <asp:BoundField HeaderText="ApproveID" DataField="ApproveID" ></asp:BoundField> <asp:TemplateField> <ItemTemplate> <asp:Label ID="lblCountry" runat="server" Text='<%# Eval("ApproveID") %>' Visible = "false" /> <asp:DropDownList ID="DropDownList4" runat="server" class="vpb_dropdown"> </asp:DropDownList> </ItemTemplate> </asp:TemplateField> </Columns> <RowStyle BackColor="White" ForeColor="#333333" /> <FooterStyle BackColor="White" ForeColor="#333333" /> <PagerStyle BackColor="#336666" ForeColor="White" HorizontalAlign="Center" /> <SelectedRowStyle BackColor="#339966" Font-Bold="True" ForeColor="White" /> <HeaderStyle BackColor="#336666" Font-Bold="True" ForeColor="White" /> </asp:GridView> Diyaayeshaa, if this helps please login to Mark As Answer. | Alert Moderator Login to post response
{ "url": "http://www.dotnetfunda.com/forums/show/16516/approvereject-through-dropdownlist", "source_domain": "www.dotnetfunda.com", "snapshot_id": "crawl=CC-MAIN-2016-44", "warc_metadata": { "Content-Length": "41399", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:ZKQFCC2GKQCV7XOGUREHNIQNI3AL6BCR", "WARC-Concurrent-To": "<urn:uuid:8152b9fc-2f78-40ef-8687-3c9d3f6e9587>", "WARC-Date": "2016-10-24T23:49:51Z", "WARC-IP-Address": "23.239.203.17", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:OD3PWPBE5CQ2BFG6WQWSBCFOHJBY2X3F", "WARC-Record-ID": "<urn:uuid:0e9aa638-8ffa-4786-ba61-416bec9ed4e7>", "WARC-Target-URI": "http://www.dotnetfunda.com/forums/show/16516/approvereject-through-dropdownlist", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:3f908b8b-a1d6-45ac-b040-2ed2e82831f3>" }, "warc_info": "robots: classic\r\nhostname: ip-10-171-6-4.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-44\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for October 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 37, 38, 148, 324, 325, 381, 382, 470, 472, 505, 507, 563, 675, 677, 681, 683, 695, 746, 821, 882, 933, 982, 1029, 1089, 1146, 1201, 1271, 1334, 1370, 1387, 1389, 1416, 1418, 1420, 1426, 1428, 1455, 1457, 1465, 1467, 1480, 1482, 1484, 1486, 1523, 1525, 1637, 1639, 1643, 1645, 1657, 1708, 1783, 1849, 1906, 1953, 2009, 2064, 2127, 2163, 2180, 2182, 2209, 2211, 2213, 2219, 2221, 2242, 2244, 2252, 2254, 2267, 2269, 2271, 2273, 2275, 2276, 2277, 2278, 2333, 2334, 2335, 2336, 2337, 2347, 2348, 2415, 2416, 2419, 2421, 2426, 2447, 2448, 2518, 2595, 2646, 2721, 2731, 2769, 2784, 2817, 2896, 2912, 2933, 2994, 3054, 3119, 3180, 3243, 3323, 3343, 3358, 3453, 3527, 3547, 3563, 3584, 3595, 3646, 3700, 3778, 3854, 3925, 3941, 3942, 3943, 4020, 4021 ], "line_end_idx": [ 37, 38, 148, 324, 325, 381, 382, 470, 472, 505, 507, 563, 675, 677, 681, 683, 695, 746, 821, 882, 933, 982, 1029, 1089, 1146, 1201, 1271, 1334, 1370, 1387, 1389, 1416, 1418, 1420, 1426, 1428, 1455, 1457, 1465, 1467, 1480, 1482, 1484, 1486, 1523, 1525, 1637, 1639, 1643, 1645, 1657, 1708, 1783, 1849, 1906, 1953, 2009, 2064, 2127, 2163, 2180, 2182, 2209, 2211, 2213, 2219, 2221, 2242, 2244, 2252, 2254, 2267, 2269, 2271, 2273, 2275, 2276, 2277, 2278, 2333, 2334, 2335, 2336, 2337, 2347, 2348, 2415, 2416, 2419, 2421, 2426, 2447, 2448, 2518, 2595, 2646, 2721, 2731, 2769, 2784, 2817, 2896, 2912, 2933, 2994, 3054, 3119, 3180, 3243, 3323, 3343, 3358, 3453, 3527, 3547, 3563, 3584, 3595, 3646, 3700, 3778, 3854, 3925, 3941, 3942, 3943, 4020, 4021, 4043 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4043, "ccnet_original_nlines": 128, "rps_doc_curly_bracket": 0.006925549823790789, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.08922363817691803, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.008111240342259407, "rps_doc_frac_lines_end_with_ellipsis": 0.007751939818263054, "rps_doc_frac_no_alph_words": 0.49594438076019287, "rps_doc_frac_unique_words": 0.5866666436195374, "rps_doc_mean_word_length": 10.123332977294922, "rps_doc_num_sentences": 60, "rps_doc_symbol_to_word_ratio": 0.011587490327656269, "rps_doc_unigram_entropy": 4.985971927642822, "rps_doc_word_count": 300, "rps_doc_frac_chars_dupe_10grams": 0.21534408628940582, "rps_doc_frac_chars_dupe_5grams": 0.21534408628940582, "rps_doc_frac_chars_dupe_6grams": 0.21534408628940582, "rps_doc_frac_chars_dupe_7grams": 0.21534408628940582, "rps_doc_frac_chars_dupe_8grams": 0.21534408628940582, "rps_doc_frac_chars_dupe_9grams": 0.21534408628940582, "rps_doc_frac_chars_top_2gram": 0.003951270133256912, "rps_doc_frac_chars_top_3gram": 0.005926900077611208, "rps_doc_frac_chars_top_4gram": 0.015805069357156754, "rps_doc_books_importance": -329.3427429199219, "rps_doc_books_importance_length_correction": -329.3427429199219, "rps_doc_openwebtext_importance": -151.68646240234375, "rps_doc_openwebtext_importance_length_correction": -151.68646240234375, "rps_doc_wikipedia_importance": -97.23184204101562, "rps_doc_wikipedia_importance_length_correction": -97.23184204101562 }, "fasttext": { "dclm": 0.3800047039985657, "english": 0.3825468122959137, "fineweb_edu_approx": 2.5833024978637695, "eai_general_math": 0.04548865929245949, "eai_open_web_math": 0.1050635576248169, "eai_web_code": 0.391271710395813 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.133", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "2", "label": "Partially Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-6,341,957,273,526,653,000
/* * CDDL HEADER START * * The contents of this file are subject to the terms of the * Common Development and Distribution License (the "License"). * You may not use this file except in compliance with the License. * * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE * or http://www.opensolaris.org/os/licensing. * See the License for the specific language governing permissions * and limitations under the License. * * When distributing Covered Code, include this CDDL HEADER in each * file and include the License file at usr/src/OPENSOLARIS.LICENSE. * If applicable, add the following below this CDDL HEADER, with the * fields enclosed by brackets "[]" replaced with your own identifying * information: Portions Copyright [yyyy] [name of copyright owner] * * CDDL HEADER END */ /* * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. * Copyright 2015 Nexenta Systems, Inc. All rights reserved. */ /* Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T */ /* All Rights Reserved */ /* * University Copyright- Copyright (c) 1982, 1986, 1988 * The Regents of the University of California * All Rights Reserved * * University Acknowledgment- Portions of this document are derived from * software developed by the University of California, Berkeley, and its * contributors. */ #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include static int spec_open(struct vnode **, int, struct cred *, caller_context_t *); static int spec_close(struct vnode *, int, int, offset_t, struct cred *, caller_context_t *); static int spec_read(struct vnode *, struct uio *, int, struct cred *, caller_context_t *); static int spec_write(struct vnode *, struct uio *, int, struct cred *, caller_context_t *); static int spec_ioctl(struct vnode *, int, intptr_t, int, struct cred *, int *, caller_context_t *); static int spec_getattr(struct vnode *, struct vattr *, int, struct cred *, caller_context_t *); static int spec_setattr(struct vnode *, struct vattr *, int, struct cred *, caller_context_t *); static int spec_access(struct vnode *, int, int, struct cred *, caller_context_t *); static int spec_create(struct vnode *, char *, vattr_t *, enum vcexcl, int, struct vnode **, struct cred *, int, caller_context_t *, vsecattr_t *); static int spec_fsync(struct vnode *, int, struct cred *, caller_context_t *); static void spec_inactive(struct vnode *, struct cred *, caller_context_t *); static int spec_fid(struct vnode *, struct fid *, caller_context_t *); static int spec_seek(struct vnode *, offset_t, offset_t *, caller_context_t *); static int spec_frlock(struct vnode *, int, struct flock64 *, int, offset_t, struct flk_callback *, struct cred *, caller_context_t *); static int spec_realvp(struct vnode *, struct vnode **, caller_context_t *); static int spec_getpage(struct vnode *, offset_t, size_t, uint_t *, page_t **, size_t, struct seg *, caddr_t, enum seg_rw, struct cred *, caller_context_t *); static int spec_putapage(struct vnode *, page_t *, u_offset_t *, size_t *, int, struct cred *); static struct buf *spec_startio(struct vnode *, page_t *, u_offset_t, size_t, int); static int spec_getapage(struct vnode *, u_offset_t, size_t, uint_t *, page_t **, size_t, struct seg *, caddr_t, enum seg_rw, struct cred *); static int spec_map(struct vnode *, offset_t, struct as *, caddr_t *, size_t, uchar_t, uchar_t, uint_t, struct cred *, caller_context_t *); static int spec_addmap(struct vnode *, offset_t, struct as *, caddr_t, size_t, uchar_t, uchar_t, uint_t, struct cred *, caller_context_t *); static int spec_delmap(struct vnode *, offset_t, struct as *, caddr_t, size_t, uint_t, uint_t, uint_t, struct cred *, caller_context_t *); static int spec_poll(struct vnode *, short, int, short *, struct pollhead **, caller_context_t *); static int spec_dump(struct vnode *, caddr_t, offset_t, offset_t, caller_context_t *); static int spec_pageio(struct vnode *, page_t *, u_offset_t, size_t, int, cred_t *, caller_context_t *); static int spec_getsecattr(struct vnode *, vsecattr_t *, int, struct cred *, caller_context_t *); static int spec_setsecattr(struct vnode *, vsecattr_t *, int, struct cred *, caller_context_t *); static int spec_pathconf(struct vnode *, int, ulong_t *, struct cred *, caller_context_t *); #define SN_HOLD(csp) { \ mutex_enter(&csp->s_lock); \ csp->s_count++; \ mutex_exit(&csp->s_lock); \ } #define SN_RELE(csp) { \ mutex_enter(&csp->s_lock); \ csp->s_count--; \ ASSERT((csp->s_count > 0) || (csp->s_vnode->v_stream == NULL)); \ mutex_exit(&csp->s_lock); \ } #define S_ISFENCED(sp) ((VTOS((sp)->s_commonvp))->s_flag & SFENCED) struct vnodeops *spec_vnodeops; /* * *PLEASE NOTE*: If you add new entry points to specfs, do * not forget to add support for fencing. A fenced snode * is indicated by the SFENCED flag in the common snode. * If a snode is fenced, determine if your entry point is * a configuration operation (Example: open), a detection * operation (Example: gettattr), an I/O operation (Example: ioctl()) * or an unconfiguration operation (Example: close). If it is * a configuration or detection operation, fail the operation * for a fenced snode with an ENXIO or EIO as appropriate. If * it is any other operation, let it through. */ const fs_operation_def_t spec_vnodeops_template[] = { VOPNAME_OPEN, { .vop_open = spec_open }, VOPNAME_CLOSE, { .vop_close = spec_close }, VOPNAME_READ, { .vop_read = spec_read }, VOPNAME_WRITE, { .vop_write = spec_write }, VOPNAME_IOCTL, { .vop_ioctl = spec_ioctl }, VOPNAME_GETATTR, { .vop_getattr = spec_getattr }, VOPNAME_SETATTR, { .vop_setattr = spec_setattr }, VOPNAME_ACCESS, { .vop_access = spec_access }, VOPNAME_CREATE, { .vop_create = spec_create }, VOPNAME_FSYNC, { .vop_fsync = spec_fsync }, VOPNAME_INACTIVE, { .vop_inactive = spec_inactive }, VOPNAME_FID, { .vop_fid = spec_fid }, VOPNAME_SEEK, { .vop_seek = spec_seek }, VOPNAME_PATHCONF, { .vop_pathconf = spec_pathconf }, VOPNAME_FRLOCK, { .vop_frlock = spec_frlock }, VOPNAME_REALVP, { .vop_realvp = spec_realvp }, VOPNAME_GETPAGE, { .vop_getpage = spec_getpage }, VOPNAME_PUTPAGE, { .vop_putpage = spec_putpage }, VOPNAME_MAP, { .vop_map = spec_map }, VOPNAME_ADDMAP, { .vop_addmap = spec_addmap }, VOPNAME_DELMAP, { .vop_delmap = spec_delmap }, VOPNAME_POLL, { .vop_poll = spec_poll }, VOPNAME_DUMP, { .vop_dump = spec_dump }, VOPNAME_PAGEIO, { .vop_pageio = spec_pageio }, VOPNAME_SETSECATTR, { .vop_setsecattr = spec_setsecattr }, VOPNAME_GETSECATTR, { .vop_getsecattr = spec_getsecattr }, NULL, NULL }; /* * Return address of spec_vnodeops */ struct vnodeops * spec_getvnodeops(void) { return (spec_vnodeops); } extern vnode_t *rconsvp; /* * Acquire the serial lock on the common snode. */ #define LOCK_CSP(csp) (void) spec_lockcsp(csp, 0, 1, 0) #define LOCKHOLD_CSP_SIG(csp) spec_lockcsp(csp, 1, 1, 1) #define SYNCHOLD_CSP_SIG(csp, intr) spec_lockcsp(csp, intr, 0, 1) typedef enum { LOOP, INTR, SUCCESS } slock_ret_t; /* * Synchronize with active SLOCKED snode, optionally checking for a signal and * optionally returning with SLOCKED set and SN_HOLD done. The 'intr' * argument determines if the thread is interruptible by a signal while * waiting, the function returns INTR if interrupted while there is another * thread closing this snonde and LOOP if interrupted otherwise. * When SUCCESS is returned the 'hold' argument determines if the open * count (SN_HOLD) has been incremented and the 'setlock' argument * determines if the function returns with SLOCKED set. */ static slock_ret_t spec_lockcsp(struct snode *csp, int intr, int setlock, int hold) { slock_ret_t ret = SUCCESS; mutex_enter(&csp->s_lock); while (csp->s_flag & SLOCKED) { csp->s_flag |= SWANT; if (intr) { if (!cv_wait_sig(&csp->s_cv, &csp->s_lock)) { if (csp->s_flag & SCLOSING) ret = INTR; else ret = LOOP; mutex_exit(&csp->s_lock); return (ret); /* interrupted */ } } else { cv_wait(&csp->s_cv, &csp->s_lock); } } if (setlock) csp->s_flag |= SLOCKED; if (hold) csp->s_count++; /* one more open reference : SN_HOLD */ mutex_exit(&csp->s_lock); return (ret); /* serialized/locked */ } /* * Unlock the serial lock on the common snode */ #define UNLOCK_CSP_LOCK_HELD(csp) \ ASSERT(mutex_owned(&csp->s_lock)); \ if (csp->s_flag & SWANT) \ cv_broadcast(&csp->s_cv); \ csp->s_flag &= ~(SWANT|SLOCKED); #define UNLOCK_CSP(csp) \ mutex_enter(&csp->s_lock); \ UNLOCK_CSP_LOCK_HELD(csp); \ mutex_exit(&csp->s_lock); /* * compute/return the size of the device */ #define SPEC_SIZE(csp) \ (((csp)->s_flag & SSIZEVALID) ? (csp)->s_size : spec_size(csp)) /* * Compute and return the size. If the size in the common snode is valid then * return it. If not valid then get the size from the driver and set size in * the common snode. If the device has not been attached then we don't ask for * an update from the driver- for non-streams SSIZEVALID stays unset until the * device is attached. A stat of a mknod outside /devices (non-devfs) may * report UNKNOWN_SIZE because the device may not be attached yet (SDIPSET not * established in mknod until open time). An stat in /devices will report the * size correctly. Specfs should always call SPEC_SIZE instead of referring * directly to s_size to initialize/retrieve the size of a device. * * XXX There is an inconsistency between block and raw - "unknown" is * UNKNOWN_SIZE for VBLK and 0 for VCHR(raw). */ static u_offset_t spec_size(struct snode *csp) { struct vnode *cvp = STOV(csp); u_offset_t size; int plen; uint32_t size32; dev_t dev; dev_info_t *devi; major_t maj; uint_t blksize; int blkshift; ASSERT((csp)->s_commonvp == cvp); /* must be common node */ /* return cached value */ mutex_enter(&csp->s_lock); if (csp->s_flag & SSIZEVALID) { mutex_exit(&csp->s_lock); return (csp->s_size); } /* VOP_GETATTR of mknod has not had devcnt restriction applied */ dev = cvp->v_rdev; maj = getmajor(dev); if (maj >= devcnt) { /* return non-cached UNKNOWN_SIZE */ mutex_exit(&csp->s_lock); return ((cvp->v_type == VCHR) ? 0 : UNKNOWN_SIZE); } /* establish cached zero size for streams */ if (STREAMSTAB(maj)) { csp->s_size = 0; csp->s_flag |= SSIZEVALID; mutex_exit(&csp->s_lock); return (0); } /* * Return non-cached UNKNOWN_SIZE if not open. * * NB: This check is bogus, calling prop_op(9E) should be gated by * attach, not open. Not having this check however opens up a new * context under which a driver's prop_op(9E) could be called. Calling * prop_op(9E) in this new context has been shown to expose latent * driver bugs (insufficient NULL pointer checks that lead to panic). * We are keeping this open check for now to avoid these panics. */ if (csp->s_count == 0) { mutex_exit(&csp->s_lock); return ((cvp->v_type == VCHR) ? 0 : UNKNOWN_SIZE); } /* Return non-cached UNKNOWN_SIZE if not attached. */ if (((csp->s_flag & SDIPSET) == 0) || (csp->s_dip == NULL) || !i_ddi_devi_attached(csp->s_dip)) { mutex_exit(&csp->s_lock); return ((cvp->v_type == VCHR) ? 0 : UNKNOWN_SIZE); } devi = csp->s_dip; /* * Established cached size obtained from the attached driver. Since we * know the devinfo node, for efficiency we use cdev_prop_op directly * instead of [cb]dev_[Ss]size. */ if (cvp->v_type == VCHR) { size = 0; plen = sizeof (size); if (cdev_prop_op(dev, devi, PROP_LEN_AND_VAL_BUF, DDI_PROP_NOTPROM | DDI_PROP_DONTPASS | DDI_PROP_CONSUMER_TYPED, "Size", (caddr_t)&size, &plen) != DDI_PROP_SUCCESS) { plen = sizeof (size32); if (cdev_prop_op(dev, devi, PROP_LEN_AND_VAL_BUF, DDI_PROP_NOTPROM | DDI_PROP_DONTPASS, "size", (caddr_t)&size32, &plen) == DDI_PROP_SUCCESS) size = size32; } } else { size = UNKNOWN_SIZE; plen = sizeof (size); if (cdev_prop_op(dev, devi, PROP_LEN_AND_VAL_BUF, DDI_PROP_NOTPROM | DDI_PROP_DONTPASS | DDI_PROP_CONSUMER_TYPED, "Nblocks", (caddr_t)&size, &plen) != DDI_PROP_SUCCESS) { plen = sizeof (size32); if (cdev_prop_op(dev, devi, PROP_LEN_AND_VAL_BUF, DDI_PROP_NOTPROM | DDI_PROP_DONTPASS, "nblocks", (caddr_t)&size32, &plen) == DDI_PROP_SUCCESS) size = size32; } if (size != UNKNOWN_SIZE) { blksize = DEV_BSIZE; /* default */ plen = sizeof (blksize); /* try to get dev_t specific "blksize" */ if (cdev_prop_op(dev, devi, PROP_LEN_AND_VAL_BUF, DDI_PROP_NOTPROM | DDI_PROP_DONTPASS, "blksize", (caddr_t)&blksize, &plen) != DDI_PROP_SUCCESS) { /* * Try for dev_info node "device-blksize". * If this fails then blksize will still be * DEV_BSIZE default value. */ (void) cdev_prop_op(DDI_DEV_T_ANY, devi, PROP_LEN_AND_VAL_BUF, DDI_PROP_NOTPROM | DDI_PROP_DONTPASS, "device-blksize", (caddr_t)&blksize, &plen); } /* blksize must be a power of two */ ASSERT(BIT_ONLYONESET(blksize)); blkshift = highbit(blksize) - 1; /* convert from block size to byte size */ if (size < (MAXOFFSET_T >> blkshift)) size = size << blkshift; else size = UNKNOWN_SIZE; } } csp->s_size = size; csp->s_flag |= SSIZEVALID; mutex_exit(&csp->s_lock); return (size); } /* * This function deal with vnode substitution in the case of * device cloning. */ static int spec_clone(struct vnode **vpp, dev_t newdev, int vtype, struct stdata *stp) { dev_t dev = (*vpp)->v_rdev; major_t maj = getmajor(dev); major_t newmaj = getmajor(newdev); int sysclone = (maj == clone_major); int qassociate_used = 0; struct snode *oldsp, *oldcsp; struct snode *newsp, *newcsp; struct vnode *newvp, *newcvp; dev_info_t *dip; queue_t *dq; ASSERT(dev != newdev); /* * Check for cloning across different drivers. * We only support this under the system provided clone driver */ if ((maj != newmaj) && !sysclone) { cmn_err(CE_NOTE, "unsupported clone open maj = %u, newmaj = %u", maj, newmaj); return (ENXIO); } /* old */ oldsp = VTOS(*vpp); oldcsp = VTOS(oldsp->s_commonvp); /* new */ newvp = makespecvp(newdev, vtype); ASSERT(newvp != NULL); newsp = VTOS(newvp); newcvp = newsp->s_commonvp; newcsp = VTOS(newcvp); /* * Clones inherit fsid, realvp, and dip. * XXX realvp inherit is not occurring, does fstat of clone work? */ newsp->s_fsid = oldsp->s_fsid; if (sysclone) { newsp->s_flag |= SCLONE; dip = NULL; } else { newsp->s_flag |= SSELFCLONE; dip = oldcsp->s_dip; } /* * If we cloned to an opened newdev that already has called * spec_assoc_vp_with_devi (SDIPSET set) then the association is * already established. */ if (!(newcsp->s_flag & SDIPSET)) { /* * Establish s_dip association for newdev. * * If we trusted the getinfo(9E) DDI_INFO_DEVT2INSTANCE * implementation of all cloning drivers (SCLONE and SELFCLONE) * we would always use e_ddi_hold_devi_by_dev(). We know that * many drivers have had (still have?) problems with * DDI_INFO_DEVT2INSTANCE, so we try to minimize reliance by * detecting drivers that use QASSOCIATE (by looking down the * stream) and setting their s_dip association to NULL. */ qassociate_used = 0; if (stp) { for (dq = stp->sd_wrq; dq; dq = dq->q_next) { if (_RD(dq)->q_flag & _QASSOCIATED) { qassociate_used = 1; dip = NULL; break; } } } if (dip || qassociate_used) { spec_assoc_vp_with_devi(newvp, dip); } else { /* derive association from newdev */ dip = e_ddi_hold_devi_by_dev(newdev, 0); spec_assoc_vp_with_devi(newvp, dip); if (dip) ddi_release_devi(dip); } } SN_HOLD(newcsp); /* deal with stream stuff */ if (stp != NULL) { LOCK_CSP(newcsp); /* synchronize stream open/close */ mutex_enter(&newcsp->s_lock); newcvp->v_stream = newvp->v_stream = stp; stp->sd_vnode = newcvp; stp->sd_strtab = STREAMSTAB(newmaj); mutex_exit(&newcsp->s_lock); UNLOCK_CSP(newcsp); } /* substitute the vnode */ SN_RELE(oldcsp); VN_RELE(*vpp); *vpp = newvp; return (0); } static int spec_open(struct vnode **vpp, int flag, struct cred *cr, caller_context_t *cc) { major_t maj; dev_t dev, newdev; struct vnode *vp, *cvp; struct snode *sp, *csp; struct stdata *stp; dev_info_t *dip; int error, type; contract_t *ct = NULL; int open_returns_eintr; slock_ret_t spec_locksp_ret; flag &= ~FCREAT; /* paranoia */ vp = *vpp; sp = VTOS(vp); ASSERT((vp->v_type == VCHR) || (vp->v_type == VBLK)); if ((vp->v_type != VCHR) && (vp->v_type != VBLK)) return (ENXIO); /* * If the VFS_NODEVICES bit was set for the mount, * do not allow opens of special devices. */ if (sp->s_realvp && (sp->s_realvp->v_vfsp->vfs_flag & VFS_NODEVICES)) return (ENXIO); newdev = dev = vp->v_rdev; /* * If we are opening a node that has not had spec_assoc_vp_with_devi * called against it (mknod outside /devices or a non-dacf makespecvp * node) then SDIPSET will not be set. In this case we call an * interface which will reconstruct the path and lookup (drive attach) * through devfs (e_ddi_hold_devi_by_dev -> e_ddi_hold_devi_by_path -> * devfs_lookupname). For support of broken drivers that don't call * ddi_create_minor_node for all minor nodes in their instance space, * we call interfaces that operates at the directory/devinfo * (major/instance) level instead of to the leaf/minor node level. * After finding and attaching the dip we associate it with the * common specfs vnode (s_dip), which sets SDIPSET. A DL_DETACH_REQ * to style-2 stream driver may set s_dip to NULL with SDIPSET set. * * NOTE: Although e_ddi_hold_devi_by_dev takes a dev_t argument, its * implementation operates at the major/instance level since it only * need to return a dip. */ cvp = sp->s_commonvp; csp = VTOS(cvp); if (!(csp->s_flag & SDIPSET)) { /* try to attach, return error if we fail */ if ((dip = e_ddi_hold_devi_by_dev(dev, 0)) == NULL) return (ENXIO); /* associate dip with the common snode s_dip */ spec_assoc_vp_with_devi(vp, dip); ddi_release_devi(dip); /* from e_ddi_hold_devi_by_dev */ } /* check if device fenced off */ if (S_ISFENCED(sp)) return (ENXIO); #ifdef DEBUG /* verify attach/open exclusion guarantee */ dip = csp->s_dip; ASSERT((dip == NULL) || i_ddi_devi_attached(dip)); #endif /* DEBUG */ if ((error = secpolicy_spec_open(cr, vp, flag)) != 0) return (error); /* Verify existance of open(9E) implementation. */ maj = getmajor(dev); if ((maj >= devcnt) || (devopsp[maj]->devo_cb_ops == NULL) || (devopsp[maj]->devo_cb_ops->cb_open == NULL)) return (ENXIO); /* * split STREAMS vs. non-STREAMS * * If the device is a dual-personality device, then we might want * to allow for a regular OTYP_BLK open. If however it's strictly * a pure STREAMS device, the cb_open entry point will be * nodev() which returns ENXIO. This does make this failure path * somewhat longer, but such attempts to use OTYP_BLK with STREAMS * devices should be exceedingly rare. (Most of the time they will * be due to programmer error.) */ if ((vp->v_type == VCHR) && (STREAMSTAB(maj))) goto streams_open; not_streams: /* * Wait for in progress last close to complete. This guarantees * to the driver writer that we will never be in the drivers * open and close on the same (dev_t, otype) at the same time. * Open count already incremented (SN_HOLD) on non-zero return. * The wait is interruptible by a signal if the driver sets the * D_OPEN_RETURNS_EINTR cb_ops(9S) cb_flag or sets the * ddi-open-returns-eintr(9P) property in its driver.conf. */ if ((devopsp[maj]->devo_cb_ops->cb_flag & D_OPEN_RETURNS_EINTR) || (devnamesp[maj].dn_flags & DN_OPEN_RETURNS_EINTR)) open_returns_eintr = 1; else open_returns_eintr = 0; while ((spec_locksp_ret = SYNCHOLD_CSP_SIG(csp, open_returns_eintr)) != SUCCESS) { if (spec_locksp_ret == INTR) return (EINTR); } /* non streams open */ type = (vp->v_type == VBLK ? OTYP_BLK : OTYP_CHR); error = dev_open(&newdev, flag, type, cr); /* deal with clone case */ if (error == 0 && dev != newdev) { error = spec_clone(vpp, newdev, vp->v_type, NULL); /* * bail on clone failure, further processing * results in undefined behaviors. */ if (error != 0) return (error); sp = VTOS(*vpp); csp = VTOS(sp->s_commonvp); } /* * create contracts only for userland opens * Successful open and cloning is done at this point. */ if (error == 0 && !(flag & FKLYR)) { int spec_type; spec_type = (STOV(csp)->v_type == VCHR) ? S_IFCHR : S_IFBLK; if (contract_device_open(newdev, spec_type, NULL) != 0) { error = EIO; } } if (error == 0) { sp->s_size = SPEC_SIZE(csp); if ((csp->s_flag & SNEEDCLOSE) == 0) { int nmaj = getmajor(newdev); mutex_enter(&csp->s_lock); /* successful open needs a close later */ csp->s_flag |= SNEEDCLOSE; /* * Invalidate possible cached "unknown" size * established by a VOP_GETATTR while open was in * progress, and the driver might fail prop_op(9E). */ if (((cvp->v_type == VCHR) && (csp->s_size == 0)) || ((cvp->v_type == VBLK) && (csp->s_size == UNKNOWN_SIZE))) csp->s_flag &= ~SSIZEVALID; if (devopsp[nmaj]->devo_cb_ops->cb_flag & D_64BIT) csp->s_flag |= SLOFFSET; if (devopsp[nmaj]->devo_cb_ops->cb_flag & D_U64BIT) csp->s_flag |= SLOFFSET | SANYOFFSET; mutex_exit(&csp->s_lock); } return (0); } /* * Open failed. If we missed a close operation because * we were trying to get the device open and it is the * last in progress open that is failing then call close. * * NOTE: Only non-streams open has this race condition. */ mutex_enter(&csp->s_lock); csp->s_count--; /* decrement open count : SN_RELE */ if ((csp->s_count == 0) && /* no outstanding open */ (csp->s_mapcnt == 0) && /* no mapping */ (csp->s_flag & SNEEDCLOSE)) { /* need a close */ csp->s_flag &= ~(SNEEDCLOSE | SSIZEVALID); /* See comment in spec_close() */ if (csp->s_flag & (SCLONE | SSELFCLONE)) csp->s_flag &= ~SDIPSET; csp->s_flag |= SCLOSING; mutex_exit(&csp->s_lock); ASSERT(*vpp != NULL); (void) device_close(*vpp, flag, cr); mutex_enter(&csp->s_lock); csp->s_flag &= ~SCLOSING; mutex_exit(&csp->s_lock); } else { mutex_exit(&csp->s_lock); } return (error); streams_open: /* * Lock common snode to prevent any new clone opens on this * stream while one is in progress. This is necessary since * the stream currently associated with the clone device will * not be part of it after the clone open completes. Unfortunately * we don't know in advance if this is a clone * device so we have to lock all opens. * * If we fail, it's because of an interrupt - EINTR return is an * expected aspect of opening a stream so we don't need to check * D_OPEN_RETURNS_EINTR. Open count already incremented (SN_HOLD) * on non-zero return. */ if (LOCKHOLD_CSP_SIG(csp) != SUCCESS) return (EINTR); error = stropen(cvp, &newdev, flag, cr); stp = cvp->v_stream; /* deal with the clone case */ if ((error == 0) && (dev != newdev)) { vp->v_stream = cvp->v_stream = NULL; UNLOCK_CSP(csp); error = spec_clone(vpp, newdev, vp->v_type, stp); /* * bail on clone failure, further processing * results in undefined behaviors. */ if (error != 0) return (error); sp = VTOS(*vpp); csp = VTOS(sp->s_commonvp); } else if (error == 0) { vp->v_stream = stp; UNLOCK_CSP(csp); } /* * create contracts only for userland opens * Successful open and cloning is done at this point. */ if (error == 0 && !(flag & FKLYR)) { /* STREAM is of type S_IFCHR */ if (contract_device_open(newdev, S_IFCHR, &ct) != 0) { UNLOCK_CSP(csp); (void) spec_close(vp, flag, 1, 0, cr, cc); return (EIO); } } if (error == 0) { /* STREAMS devices don't have a size */ sp->s_size = csp->s_size = 0; if (!(stp->sd_flag & STRISTTY) || (flag & FNOCTTY)) return (0); /* try to allocate it as a controlling terminal */ if (strctty(stp) != EINTR) return (0); /* strctty() was interrupted by a signal */ if (ct) { /* we only create contracts for userland opens */ ASSERT(ttoproc(curthread)); (void) contract_abandon(ct, ttoproc(curthread), 0); } (void) spec_close(vp, flag, 1, 0, cr, cc); return (EINTR); } /* * Deal with stropen failure. * * sd_flag in the stream head cannot change since the * common snode is locked before the call to stropen(). */ if ((stp != NULL) && (stp->sd_flag & STREOPENFAIL)) { /* * Open failed part way through. */ mutex_enter(&stp->sd_lock); stp->sd_flag &= ~STREOPENFAIL; mutex_exit(&stp->sd_lock); UNLOCK_CSP(csp); (void) spec_close(vp, flag, 1, 0, cr, cc); } else { UNLOCK_CSP(csp); SN_RELE(csp); } /* * Resolution for STREAMS vs. regular character device: If the * STREAMS open(9e) returns ENOSTR, then try an ordinary device * open instead. */ if (error == ENOSTR) { goto not_streams; } return (error); } /*ARGSUSED2*/ static int spec_close( struct vnode *vp, int flag, int count, offset_t offset, struct cred *cr, caller_context_t *ct) { struct vnode *cvp; struct snode *sp, *csp; enum vtype type; dev_t dev; int error = 0; int sysclone; if (!(flag & FKLYR)) { /* this only applies to closes of devices from userland */ cleanlocks(vp, ttoproc(curthread)->p_pid, 0); cleanshares(vp, ttoproc(curthread)->p_pid); if (vp->v_stream) strclean(vp); } if (count > 1) return (0); /* we allow close to succeed even if device is fenced off */ sp = VTOS(vp); cvp = sp->s_commonvp; dev = sp->s_dev; type = vp->v_type; ASSERT(type == VCHR || type == VBLK); /* * Prevent close/close and close/open races by serializing closes * on this common snode. Clone opens are held up until after * we have closed this device so the streams linkage is maintained */ csp = VTOS(cvp); LOCK_CSP(csp); mutex_enter(&csp->s_lock); csp->s_count--; /* one fewer open reference : SN_RELE */ sysclone = sp->s_flag & SCLONE; /* * Invalidate size on each close. * * XXX We do this on each close because we don't have interfaces that * allow a driver to invalidate the size. Since clearing this on each * close this causes property overhead we skip /dev/null and * /dev/zero to avoid degrading kenbus performance. */ if (getmajor(dev) != mm_major) csp->s_flag &= ~SSIZEVALID; /* * Only call the close routine when the last open reference through * any [s, v]node goes away. This can be checked by looking at * s_count on the common vnode. */ if ((csp->s_count == 0) && (csp->s_mapcnt == 0)) { /* we don't need a close */ csp->s_flag &= ~(SNEEDCLOSE | SSIZEVALID); /* * A cloning driver may open-clone to the same dev_t that we * are closing before spec_inactive destroys the common snode. * If this occurs the s_dip association needs to be reevaluated. * We clear SDIPSET to force reevaluation in this case. When * reevaluation occurs (by spec_clone after open), if the * devinfo association has changed then the old association * will be released as the new association is established by * spec_assoc_vp_with_devi(). */ if (csp->s_flag & (SCLONE | SSELFCLONE)) csp->s_flag &= ~SDIPSET; csp->s_flag |= SCLOSING; mutex_exit(&csp->s_lock); error = device_close(vp, flag, cr); /* * Decrement the devops held in clnopen() */ if (sysclone) { ddi_rele_driver(getmajor(dev)); } mutex_enter(&csp->s_lock); csp->s_flag &= ~SCLOSING; } UNLOCK_CSP_LOCK_HELD(csp); mutex_exit(&csp->s_lock); return (error); } /*ARGSUSED2*/ static int spec_read( struct vnode *vp, struct uio *uiop, int ioflag, struct cred *cr, caller_context_t *ct) { int error; struct snode *sp = VTOS(vp); dev_t dev = sp->s_dev; size_t n; ulong_t on; u_offset_t bdevsize; offset_t maxoff; offset_t off; struct vnode *blkvp; ASSERT(vp->v_type == VCHR || vp->v_type == VBLK); if (vp->v_stream) { ASSERT(vp->v_type == VCHR); smark(sp, SACC); return (strread(vp, uiop, cr)); } if (uiop->uio_resid == 0) return (0); /* * Plain old character devices that set D_U64BIT can have * unrestricted offsets. */ maxoff = spec_maxoffset(vp); ASSERT(maxoff != -1 || vp->v_type == VCHR); if (maxoff != -1 && (uiop->uio_loffset < 0 || uiop->uio_loffset + uiop->uio_resid > maxoff)) return (EINVAL); if (vp->v_type == VCHR) { smark(sp, SACC); ASSERT(vp->v_stream == NULL); return (cdev_read(dev, uiop, cr)); } /* * Block device. */ error = 0; blkvp = sp->s_commonvp; bdevsize = SPEC_SIZE(VTOS(blkvp)); do { caddr_t base; offset_t diff; off = uiop->uio_loffset & (offset_t)MAXBMASK; on = (size_t)(uiop->uio_loffset & MAXBOFFSET); n = (size_t)MIN(MAXBSIZE - on, uiop->uio_resid); diff = bdevsize - uiop->uio_loffset; if (diff <= 0) break; if (diff < n) n = (size_t)diff; if (vpm_enable) { error = vpm_data_copy(blkvp, (u_offset_t)(off + on), n, uiop, 1, NULL, 0, S_READ); } else { base = segmap_getmapflt(segkmap, blkvp, (u_offset_t)(off + on), n, 1, S_READ); error = uiomove(base + on, n, UIO_READ, uiop); } if (!error) { int flags = 0; /* * If we read a whole block, we won't need this * buffer again soon. */ if (n + on == MAXBSIZE) flags = SM_DONTNEED | SM_FREE; if (vpm_enable) { error = vpm_sync_pages(blkvp, off, n, flags); } else { error = segmap_release(segkmap, base, flags); } } else { if (vpm_enable) { (void) vpm_sync_pages(blkvp, off, n, 0); } else { (void) segmap_release(segkmap, base, 0); } if (bdevsize == UNKNOWN_SIZE) { error = 0; break; } } } while (error == 0 && uiop->uio_resid > 0 && n != 0); return (error); } /*ARGSUSED*/ static int spec_write( struct vnode *vp, struct uio *uiop, int ioflag, struct cred *cr, caller_context_t *ct) { int error; struct snode *sp = VTOS(vp); dev_t dev = sp->s_dev; size_t n; ulong_t on; u_offset_t bdevsize; offset_t maxoff; offset_t off; struct vnode *blkvp; ASSERT(vp->v_type == VCHR || vp->v_type == VBLK); if (vp->v_stream) { ASSERT(vp->v_type == VCHR); smark(sp, SUPD); return (strwrite(vp, uiop, cr)); } /* * Plain old character devices that set D_U64BIT can have * unrestricted offsets. */ maxoff = spec_maxoffset(vp); ASSERT(maxoff != -1 || vp->v_type == VCHR); if (maxoff != -1 && (uiop->uio_loffset < 0 || uiop->uio_loffset + uiop->uio_resid > maxoff)) return (EINVAL); if (vp->v_type == VCHR) { smark(sp, SUPD); ASSERT(vp->v_stream == NULL); return (cdev_write(dev, uiop, cr)); } if (uiop->uio_resid == 0) return (0); error = 0; blkvp = sp->s_commonvp; bdevsize = SPEC_SIZE(VTOS(blkvp)); do { int pagecreate; int newpage; caddr_t base; offset_t diff; off = uiop->uio_loffset & (offset_t)MAXBMASK; on = (ulong_t)(uiop->uio_loffset & MAXBOFFSET); n = (size_t)MIN(MAXBSIZE - on, uiop->uio_resid); pagecreate = 0; diff = bdevsize - uiop->uio_loffset; if (diff <= 0) { error = ENXIO; break; } if (diff < n) n = (size_t)diff; /* * Check to see if we can skip reading in the page * and just allocate the memory. We can do this * if we are going to rewrite the entire mapping * or if we are going to write to end of the device * from the beginning of the mapping. */ if (n == MAXBSIZE || (on == 0 && (off + n) == bdevsize)) pagecreate = 1; newpage = 0; /* * Touch the page and fault it in if it is not in core * before segmap_getmapflt or vpm_data_copy can lock it. * This is to avoid the deadlock if the buffer is mapped * to the same file through mmap which we want to write. */ uio_prefaultpages((long)n, uiop); if (vpm_enable) { error = vpm_data_copy(blkvp, (u_offset_t)(off + on), n, uiop, !pagecreate, NULL, 0, S_WRITE); } else { base = segmap_getmapflt(segkmap, blkvp, (u_offset_t)(off + on), n, !pagecreate, S_WRITE); /* * segmap_pagecreate() returns 1 if it calls * page_create_va() to allocate any pages. */ if (pagecreate) newpage = segmap_pagecreate(segkmap, base + on, n, 0); error = uiomove(base + on, n, UIO_WRITE, uiop); } if (!vpm_enable && pagecreate && uiop->uio_loffset < P2ROUNDUP_TYPED(off + on + n, PAGESIZE, offset_t)) { /* * We created pages w/o initializing them completely, * thus we need to zero the part that wasn't set up. * This can happen if we write to the end of the device * or if we had some sort of error during the uiomove. */ long nzero; offset_t nmoved; nmoved = (uiop->uio_loffset - (off + on)); if (nmoved < 0 || nmoved > n) { panic("spec_write: nmoved bogus"); /*NOTREACHED*/ } nzero = (long)P2ROUNDUP(on + n, PAGESIZE) - (on + nmoved); if (nzero < 0 || (on + nmoved + nzero > MAXBSIZE)) { panic("spec_write: nzero bogus"); /*NOTREACHED*/ } (void) kzero(base + on + nmoved, (size_t)nzero); } /* * Unlock the pages which have been allocated by * page_create_va() in segmap_pagecreate(). */ if (!vpm_enable && newpage) segmap_pageunlock(segkmap, base + on, (size_t)n, S_WRITE); if (error == 0) { int flags = 0; /* * Force write back for synchronous write cases. */ if (ioflag & (FSYNC|FDSYNC)) flags = SM_WRITE; else if (n + on == MAXBSIZE || IS_SWAPVP(vp)) { /* * Have written a whole block. * Start an asynchronous write and * mark the buffer to indicate that * it won't be needed again soon. * Push swap files here, since it * won't happen anywhere else. */ flags = SM_WRITE | SM_ASYNC | SM_DONTNEED; } smark(sp, SUPD|SCHG); if (vpm_enable) { error = vpm_sync_pages(blkvp, off, n, flags); } else { error = segmap_release(segkmap, base, flags); } } else { if (vpm_enable) { (void) vpm_sync_pages(blkvp, off, n, SM_INVAL); } else { (void) segmap_release(segkmap, base, SM_INVAL); } } } while (error == 0 && uiop->uio_resid > 0 && n != 0); return (error); } /*ARGSUSED6*/ static int spec_ioctl(struct vnode *vp, int cmd, intptr_t arg, int mode, struct cred *cr, int *rvalp, caller_context_t *ct) { struct snode *sp; dev_t dev; int error; if (vp->v_type != VCHR) return (ENOTTY); /* * allow ioctls() to go through even for fenced snodes, as they * may include unconfiguration operation - for example popping of * streams modules. */ sp = VTOS(vp); dev = sp->s_dev; if (vp->v_stream) { error = strioctl(vp, cmd, arg, mode, U_TO_K, cr, rvalp); } else { error = cdev_ioctl(dev, cmd, arg, mode, cr, rvalp); } return (error); } static int spec_getattr( struct vnode *vp, struct vattr *vap, int flags, struct cred *cr, caller_context_t *ct) { int error; struct snode *sp; struct vnode *realvp; /* With ATTR_COMM we will not get attributes from realvp */ if (flags & ATTR_COMM) { sp = VTOS(vp); vp = sp->s_commonvp; } sp = VTOS(vp); /* we want stat() to fail with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); realvp = sp->s_realvp; if (realvp == NULL) { static int snode_shift = 0; /* * Calculate the amount of bitshift to a snode pointer which * will still keep it unique. See below. */ if (snode_shift == 0) snode_shift = highbit(sizeof (struct snode)); ASSERT(snode_shift > 0); /* * No real vnode behind this one. Fill in the fields * from the snode. * * This code should be refined to return only the * attributes asked for instead of all of them. */ vap->va_type = vp->v_type; vap->va_mode = 0; vap->va_uid = vap->va_gid = 0; vap->va_fsid = sp->s_fsid; /* * If the va_nodeid is > MAX_USHORT, then i386 stats might * fail. So we shift down the snode pointer to try and get * the most uniqueness into 16-bits. */ vap->va_nodeid = ((ino64_t)(uintptr_t)sp >> snode_shift) & 0xFFFF; vap->va_nlink = 0; vap->va_rdev = sp->s_dev; /* * va_nblocks is the number of 512 byte blocks used to store * the mknod for the device, not the number of blocks on the * device itself. This is typically zero since the mknod is * represented directly in the inode itself. */ vap->va_nblocks = 0; } else { error = VOP_GETATTR(realvp, vap, flags, cr, ct); if (error != 0) return (error); } /* set the size from the snode */ vap->va_size = SPEC_SIZE(VTOS(sp->s_commonvp)); vap->va_blksize = MAXBSIZE; mutex_enter(&sp->s_lock); vap->va_atime.tv_sec = sp->s_atime; vap->va_mtime.tv_sec = sp->s_mtime; vap->va_ctime.tv_sec = sp->s_ctime; mutex_exit(&sp->s_lock); vap->va_atime.tv_nsec = 0; vap->va_mtime.tv_nsec = 0; vap->va_ctime.tv_nsec = 0; vap->va_seq = 0; return (0); } static int spec_setattr( struct vnode *vp, struct vattr *vap, int flags, struct cred *cr, caller_context_t *ct) { struct snode *sp = VTOS(vp); struct vnode *realvp; int error; /* fail with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); if (vp->v_type == VCHR && vp->v_stream && (vap->va_mask & AT_SIZE)) { /* * 1135080: O_TRUNC should have no effect on * named pipes and terminal devices. */ ASSERT(vap->va_mask == AT_SIZE); return (0); } if ((realvp = sp->s_realvp) == NULL) error = 0; /* no real vnode to update */ else error = VOP_SETATTR(realvp, vap, flags, cr, ct); if (error == 0) { /* * If times were changed, update snode. */ mutex_enter(&sp->s_lock); if (vap->va_mask & AT_ATIME) sp->s_atime = vap->va_atime.tv_sec; if (vap->va_mask & AT_MTIME) { sp->s_mtime = vap->va_mtime.tv_sec; sp->s_ctime = gethrestime_sec(); } mutex_exit(&sp->s_lock); } return (error); } static int spec_access( struct vnode *vp, int mode, int flags, struct cred *cr, caller_context_t *ct) { struct vnode *realvp; struct snode *sp = VTOS(vp); /* fail with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); if ((realvp = sp->s_realvp) != NULL) return (VOP_ACCESS(realvp, mode, flags, cr, ct)); else return (0); /* Allow all access. */ } /* * This can be called if creat or an open with O_CREAT is done on the root * of a lofs mount where the mounted entity is a special file. */ /*ARGSUSED*/ static int spec_create( struct vnode *dvp, char *name, vattr_t *vap, enum vcexcl excl, int mode, struct vnode **vpp, struct cred *cr, int flag, caller_context_t *ct, vsecattr_t *vsecp) { int error; struct snode *sp = VTOS(dvp); /* fail with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); ASSERT(dvp && (dvp->v_flag & VROOT) && *name == '\0'); if (excl == NONEXCL) { if (mode && (error = spec_access(dvp, mode, 0, cr, ct))) return (error); VN_HOLD(dvp); return (0); } return (EEXIST); } /* * In order to sync out the snode times without multi-client problems, * make sure the times written out are never earlier than the times * already set in the vnode. */ static int spec_fsync( struct vnode *vp, int syncflag, struct cred *cr, caller_context_t *ct) { struct snode *sp = VTOS(vp); struct vnode *realvp; struct vnode *cvp; struct vattr va, vatmp; /* allow syncing even if device is fenced off */ /* If times didn't change, don't flush anything. */ mutex_enter(&sp->s_lock); if ((sp->s_flag & (SACC|SUPD|SCHG)) == 0 && vp->v_type != VBLK) { mutex_exit(&sp->s_lock); return (0); } sp->s_flag &= ~(SACC|SUPD|SCHG); mutex_exit(&sp->s_lock); cvp = sp->s_commonvp; realvp = sp->s_realvp; if (vp->v_type == VBLK && cvp != vp && vn_has_cached_data(cvp) && (cvp->v_flag & VISSWAP) == 0) (void) VOP_PUTPAGE(cvp, (offset_t)0, 0, 0, cr, ct); /* * For devices that support it, force write cache to stable storage. * We don't need the lock to check s_flags since we can treat * SNOFLUSH as a hint. */ if ((vp->v_type == VBLK || vp->v_type == VCHR) && !(sp->s_flag & SNOFLUSH)) { int rval, rc; struct dk_callback spec_callback; spec_callback.dkc_flag = FLUSH_VOLATILE; spec_callback.dkc_callback = NULL; /* synchronous flush on volatile cache */ rc = cdev_ioctl(vp->v_rdev, DKIOCFLUSHWRITECACHE, (intptr_t)&spec_callback, FNATIVE|FKIOCTL, cr, &rval); if (rc == ENOTSUP || rc == ENOTTY) { mutex_enter(&sp->s_lock); sp->s_flag |= SNOFLUSH; mutex_exit(&sp->s_lock); } } /* * If no real vnode to update, don't flush anything. */ if (realvp == NULL) return (0); vatmp.va_mask = AT_ATIME|AT_MTIME; if (VOP_GETATTR(realvp, &vatmp, 0, cr, ct) == 0) { mutex_enter(&sp->s_lock); if (vatmp.va_atime.tv_sec > sp->s_atime) va.va_atime = vatmp.va_atime; else { va.va_atime.tv_sec = sp->s_atime; va.va_atime.tv_nsec = 0; } if (vatmp.va_mtime.tv_sec > sp->s_mtime) va.va_mtime = vatmp.va_mtime; else { va.va_mtime.tv_sec = sp->s_mtime; va.va_mtime.tv_nsec = 0; } mutex_exit(&sp->s_lock); va.va_mask = AT_ATIME|AT_MTIME; (void) VOP_SETATTR(realvp, &va, 0, cr, ct); } (void) VOP_FSYNC(realvp, syncflag, cr, ct); return (0); } /*ARGSUSED*/ static void spec_inactive(struct vnode *vp, struct cred *cr, caller_context_t *ct) { struct snode *sp = VTOS(vp); struct vnode *cvp; struct vnode *rvp; /* * If no one has reclaimed the vnode, remove from the * cache now. */ if (vp->v_count < 1) { panic("spec_inactive: Bad v_count"); /*NOTREACHED*/ } mutex_enter(&stable_lock); mutex_enter(&vp->v_lock); /* * Drop the temporary hold by vn_rele now */ if (--vp->v_count != 0) { mutex_exit(&vp->v_lock); mutex_exit(&stable_lock); return; } mutex_exit(&vp->v_lock); sdelete(sp); mutex_exit(&stable_lock); /* We are the sole owner of sp now */ cvp = sp->s_commonvp; rvp = sp->s_realvp; if (rvp) { /* * If the snode times changed, then update the times * associated with the "realvp". */ if ((sp->s_flag & (SACC|SUPD|SCHG)) != 0) { struct vattr va, vatmp; mutex_enter(&sp->s_lock); sp->s_flag &= ~(SACC|SUPD|SCHG); mutex_exit(&sp->s_lock); vatmp.va_mask = AT_ATIME|AT_MTIME; /* * The user may not own the device, but we * want to update the attributes anyway. */ if (VOP_GETATTR(rvp, &vatmp, 0, kcred, ct) == 0) { if (vatmp.va_atime.tv_sec > sp->s_atime) va.va_atime = vatmp.va_atime; else { va.va_atime.tv_sec = sp->s_atime; va.va_atime.tv_nsec = 0; } if (vatmp.va_mtime.tv_sec > sp->s_mtime) va.va_mtime = vatmp.va_mtime; else { va.va_mtime.tv_sec = sp->s_mtime; va.va_mtime.tv_nsec = 0; } va.va_mask = AT_ATIME|AT_MTIME; (void) VOP_SETATTR(rvp, &va, 0, kcred, ct); } } } ASSERT(!vn_has_cached_data(vp)); vn_invalid(vp); /* if we are sharing another file systems vfs, release it */ if (vp->v_vfsp && (vp->v_vfsp != &spec_vfs)) VFS_RELE(vp->v_vfsp); /* if we have a realvp, release the realvp */ if (rvp) VN_RELE(rvp); /* if we have a common, release the common */ if (cvp && (cvp != vp)) { VN_RELE(cvp); #ifdef DEBUG } else if (cvp) { /* * if this is the last reference to a common vnode, any * associated stream had better have been closed */ ASSERT(cvp == vp); ASSERT(cvp->v_stream == NULL); #endif /* DEBUG */ } /* * if we have a hold on a devinfo node (established by * spec_assoc_vp_with_devi), release the hold */ if (sp->s_dip) ddi_release_devi(sp->s_dip); /* * If we have an associated device policy, release it. */ if (sp->s_plcy != NULL) dpfree(sp->s_plcy); /* * If all holds on the devinfo node are through specfs/devfs * and we just destroyed the last specfs node associated with the * device, then the devinfo node reference count should now be * zero. We can't check this because there may be other holds * on the node from non file system sources: ddi_hold_devi_by_instance * for example. */ kmem_cache_free(snode_cache, sp); } static int spec_fid(struct vnode *vp, struct fid *fidp, caller_context_t *ct) { struct vnode *realvp; struct snode *sp = VTOS(vp); if ((realvp = sp->s_realvp) != NULL) return (VOP_FID(realvp, fidp, ct)); else return (EINVAL); } /*ARGSUSED1*/ static int spec_seek( struct vnode *vp, offset_t ooff, offset_t *noffp, caller_context_t *ct) { offset_t maxoff = spec_maxoffset(vp); if (maxoff == -1 || *noffp <= maxoff) return (0); else return (EINVAL); } static int spec_frlock( struct vnode *vp, int cmd, struct flock64 *bfp, int flag, offset_t offset, struct flk_callback *flk_cbp, struct cred *cr, caller_context_t *ct) { struct snode *sp = VTOS(vp); struct snode *csp; csp = VTOS(sp->s_commonvp); /* * If file is being mapped, disallow frlock. */ if (csp->s_mapcnt > 0) return (EAGAIN); return (fs_frlock(vp, cmd, bfp, flag, offset, flk_cbp, cr, ct)); } static int spec_realvp(struct vnode *vp, struct vnode **vpp, caller_context_t *ct) { struct vnode *rvp; if ((rvp = VTOS(vp)->s_realvp) != NULL) { vp = rvp; if (VOP_REALVP(vp, &rvp, ct) == 0) vp = rvp; } *vpp = vp; return (0); } /* * Return all the pages from [off..off + len] in block * or character device. */ /*ARGSUSED*/ static int spec_getpage( struct vnode *vp, offset_t off, size_t len, uint_t *protp, page_t *pl[], size_t plsz, struct seg *seg, caddr_t addr, enum seg_rw rw, struct cred *cr, caller_context_t *ct) { struct snode *sp = VTOS(vp); int err; ASSERT(sp->s_commonvp == vp); /* * XXX Given the above assertion, this might not do * what is wanted here. */ if (vp->v_flag & VNOMAP) return (ENOSYS); TRACE_4(TR_FAC_SPECFS, TR_SPECFS_GETPAGE, "specfs getpage:vp %p off %llx len %ld snode %p", vp, off, len, sp); switch (vp->v_type) { case VBLK: if (protp != NULL) *protp = PROT_ALL; if (((u_offset_t)off + len) > (SPEC_SIZE(sp) + PAGEOFFSET)) return (EFAULT); /* beyond EOF */ err = pvn_getpages(spec_getapage, vp, (u_offset_t)off, len, protp, pl, plsz, seg, addr, rw, cr); break; case VCHR: cmn_err(CE_NOTE, "spec_getpage called for character device. " "Check any non-ON consolidation drivers"); err = 0; pl[0] = (page_t *)0; break; default: panic("spec_getpage: bad v_type 0x%x", vp->v_type); /*NOTREACHED*/ } return (err); } extern int klustsize; /* set in machdep.c */ int spec_ra = 1; int spec_lostpage; /* number of times we lost original page */ /*ARGSUSED2*/ static int spec_getapage( struct vnode *vp, u_offset_t off, size_t len, uint_t *protp, page_t *pl[], size_t plsz, struct seg *seg, caddr_t addr, enum seg_rw rw, struct cred *cr) { struct snode *sp; struct buf *bp; page_t *pp, *pp2; u_offset_t io_off1, io_off2; size_t io_len1; size_t io_len2; size_t blksz; u_offset_t blkoff; int dora, err; page_t *pagefound; uint_t xlen; size_t adj_klustsize; u_offset_t size; u_offset_t tmpoff; sp = VTOS(vp); TRACE_3(TR_FAC_SPECFS, TR_SPECFS_GETAPAGE, "specfs getapage:vp %p off %llx snode %p", vp, off, sp); reread: err = 0; bp = NULL; pp = NULL; pp2 = NULL; if (pl != NULL) pl[0] = NULL; size = SPEC_SIZE(VTOS(sp->s_commonvp)); if (spec_ra && sp->s_nextr == off) dora = 1; else dora = 0; if (size == UNKNOWN_SIZE) { dora = 0; adj_klustsize = PAGESIZE; } else { adj_klustsize = dora ? klustsize : PAGESIZE; } again: if ((pagefound = page_exists(vp, off)) == NULL) { if (rw == S_CREATE) { /* * We're allocating a swap slot and it's * associated page was not found, so allocate * and return it. */ if ((pp = page_create_va(vp, off, PAGESIZE, PG_WAIT, seg, addr)) == NULL) { panic("spec_getapage: page_create"); /*NOTREACHED*/ } io_len1 = PAGESIZE; sp->s_nextr = off + PAGESIZE; } else { /* * Need to really do disk I/O to get the page(s). */ blkoff = (off / adj_klustsize) * adj_klustsize; if (size == UNKNOWN_SIZE) { blksz = PAGESIZE; } else { if (blkoff + adj_klustsize <= size) blksz = adj_klustsize; else blksz = MIN(size - blkoff, adj_klustsize); } pp = pvn_read_kluster(vp, off, seg, addr, &tmpoff, &io_len1, blkoff, blksz, 0); io_off1 = tmpoff; /* * Make sure the page didn't sneek into the * cache while we blocked in pvn_read_kluster. */ if (pp == NULL) goto again; /* * Zero part of page which we are not * going to be reading from disk now. */ xlen = (uint_t)(io_len1 & PAGEOFFSET); if (xlen != 0) pagezero(pp->p_prev, xlen, PAGESIZE - xlen); bp = spec_startio(vp, pp, io_off1, io_len1, pl == NULL ? (B_ASYNC | B_READ) : B_READ); sp->s_nextr = io_off1 + io_len1; } } if (dora && rw != S_CREATE) { u_offset_t off2; caddr_t addr2; off2 = ((off / adj_klustsize) + 1) * adj_klustsize; addr2 = addr + (off2 - off); pp2 = NULL; /* * If we are past EOF then don't bother trying * with read-ahead. */ if (off2 >= size) pp2 = NULL; else { if (off2 + adj_klustsize <= size) blksz = adj_klustsize; else blksz = MIN(size - off2, adj_klustsize); pp2 = pvn_read_kluster(vp, off2, seg, addr2, &tmpoff, &io_len2, off2, blksz, 1); io_off2 = tmpoff; } if (pp2 != NULL) { /* * Zero part of page which we are not * going to be reading from disk now. */ xlen = (uint_t)(io_len2 & PAGEOFFSET); if (xlen != 0) pagezero(pp2->p_prev, xlen, PAGESIZE - xlen); (void) spec_startio(vp, pp2, io_off2, io_len2, B_READ | B_ASYNC); } } if (pl == NULL) return (err); if (bp != NULL) { err = biowait(bp); pageio_done(bp); if (err) { if (pp != NULL) pvn_read_done(pp, B_ERROR); return (err); } } if (pagefound) { se_t se = (rw == S_CREATE ? SE_EXCL : SE_SHARED); /* * Page exists in the cache, acquire the appropriate * lock. If this fails, start all over again. */ if ((pp = page_lookup(vp, off, se)) == NULL) { spec_lostpage++; goto reread; } pl[0] = pp; pl[1] = NULL; sp->s_nextr = off + PAGESIZE; return (0); } if (pp != NULL) pvn_plist_init(pp, pl, plsz, off, io_len1, rw); return (0); } /* * Flags are composed of {B_INVAL, B_DIRTY B_FREE, B_DONTNEED, B_FORCE}. * If len == 0, do from off to EOF. * * The normal cases should be len == 0 & off == 0 (entire vp list), * len == MAXBSIZE (from segmap_release actions), and len == PAGESIZE * (from pageout). */ /*ARGSUSED5*/ int spec_putpage( struct vnode *vp, offset_t off, size_t len, int flags, struct cred *cr, caller_context_t *ct) { struct snode *sp = VTOS(vp); struct vnode *cvp; page_t *pp; u_offset_t io_off; size_t io_len = 0; /* for lint */ int err = 0; u_offset_t size; u_offset_t tmpoff; ASSERT(vp->v_count != 0); if (vp->v_flag & VNOMAP) return (ENOSYS); cvp = sp->s_commonvp; size = SPEC_SIZE(VTOS(cvp)); if (!vn_has_cached_data(vp) || off >= size) return (0); ASSERT(vp->v_type == VBLK && cvp == vp); TRACE_4(TR_FAC_SPECFS, TR_SPECFS_PUTPAGE, "specfs putpage:vp %p off %llx len %ld snode %p", vp, off, len, sp); if (len == 0) { /* * Search the entire vp list for pages >= off. */ err = pvn_vplist_dirty(vp, off, spec_putapage, flags, cr); } else { u_offset_t eoff; /* * Loop over all offsets in the range [off...off + len] * looking for pages to deal with. We set limits so * that we kluster to klustsize boundaries. */ eoff = off + len; for (io_off = off; io_off < eoff && io_off < size; io_off += io_len) { /* * If we are not invalidating, synchronously * freeing or writing pages use the routine * page_lookup_nowait() to prevent reclaiming * them from the free list. */ if ((flags & B_INVAL) || ((flags & B_ASYNC) == 0)) { pp = page_lookup(vp, io_off, (flags & (B_INVAL | B_FREE)) ? SE_EXCL : SE_SHARED); } else { pp = page_lookup_nowait(vp, io_off, (flags & B_FREE) ? SE_EXCL : SE_SHARED); } if (pp == NULL || pvn_getdirty(pp, flags) == 0) io_len = PAGESIZE; else { err = spec_putapage(vp, pp, &tmpoff, &io_len, flags, cr); io_off = tmpoff; if (err != 0) break; /* * "io_off" and "io_len" are returned as * the range of pages we actually wrote. * This allows us to skip ahead more quickly * since several pages may've been dealt * with by this iteration of the loop. */ } } } return (err); } /* * Write out a single page, possibly klustering adjacent * dirty pages. */ /*ARGSUSED5*/ static int spec_putapage( struct vnode *vp, page_t *pp, u_offset_t *offp, /* return value */ size_t *lenp, /* return value */ int flags, struct cred *cr) { struct snode *sp = VTOS(vp); u_offset_t io_off; size_t io_len; size_t blksz; u_offset_t blkoff; int err = 0; struct buf *bp; u_offset_t size; size_t adj_klustsize; u_offset_t tmpoff; /* * Destroy read ahead value since we are really going to write. */ sp->s_nextr = 0; size = SPEC_SIZE(VTOS(sp->s_commonvp)); adj_klustsize = klustsize; blkoff = (pp->p_offset / adj_klustsize) * adj_klustsize; if (blkoff + adj_klustsize <= size) blksz = adj_klustsize; else blksz = size - blkoff; /* * Find a kluster that fits in one contiguous chunk. */ pp = pvn_write_kluster(vp, pp, &tmpoff, &io_len, blkoff, blksz, flags); io_off = tmpoff; /* * Check for page length rounding problems * XXX - Is this necessary? */ if (io_off + io_len > size) { ASSERT((io_off + io_len) - size < PAGESIZE); io_len = size - io_off; } bp = spec_startio(vp, pp, io_off, io_len, B_WRITE | flags); /* * Wait for i/o to complete if the request is not B_ASYNC. */ if ((flags & B_ASYNC) == 0) { err = biowait(bp); pageio_done(bp); pvn_write_done(pp, ((err) ? B_ERROR : 0) | B_WRITE | flags); } if (offp) *offp = io_off; if (lenp) *lenp = io_len; TRACE_4(TR_FAC_SPECFS, TR_SPECFS_PUTAPAGE, "specfs putapage:vp %p offp %p snode %p err %d", vp, offp, sp, err); return (err); } /* * Flags are composed of {B_ASYNC, B_INVAL, B_FREE, B_DONTNEED} */ static struct buf * spec_startio( struct vnode *vp, page_t *pp, u_offset_t io_off, size_t io_len, int flags) { struct buf *bp; bp = pageio_setup(pp, io_len, vp, flags); bp->b_edev = vp->v_rdev; bp->b_dev = cmpdev(vp->v_rdev); bp->b_blkno = btodt(io_off); bp->b_un.b_addr = (caddr_t)0; (void) bdev_strategy(bp); if (flags & B_READ) lwp_stat_update(LWP_STAT_INBLK, 1); else lwp_stat_update(LWP_STAT_OUBLK, 1); return (bp); } static int spec_poll( struct vnode *vp, short events, int anyyet, short *reventsp, struct pollhead **phpp, caller_context_t *ct) { dev_t dev; int error; if (vp->v_type == VBLK) error = fs_poll(vp, events, anyyet, reventsp, phpp, ct); else { ASSERT(vp->v_type == VCHR); dev = vp->v_rdev; if (vp->v_stream) { ASSERT(vp->v_stream != NULL); error = strpoll(vp->v_stream, events, anyyet, reventsp, phpp); } else if (devopsp[getmajor(dev)]->devo_cb_ops->cb_chpoll) { error = cdev_poll(dev, events, anyyet, reventsp, phpp); } else { error = fs_poll(vp, events, anyyet, reventsp, phpp, ct); } } return (error); } /* * This routine is called through the cdevsw[] table to handle * traditional mmap'able devices that support a d_mmap function. */ /*ARGSUSED8*/ int spec_segmap( dev_t dev, off_t off, struct as *as, caddr_t *addrp, off_t len, uint_t prot, uint_t maxprot, uint_t flags, struct cred *cred) { struct segdev_crargs dev_a; int (*mapfunc)(dev_t dev, off_t off, int prot); size_t i; int error; if ((mapfunc = devopsp[getmajor(dev)]->devo_cb_ops->cb_mmap) == nodev) return (ENODEV); TRACE_4(TR_FAC_SPECFS, TR_SPECFS_SEGMAP, "specfs segmap:dev %x as %p len %lx prot %x", dev, as, len, prot); /* * Character devices that support the d_mmap * interface can only be mmap'ed shared. */ if ((flags & MAP_TYPE) != MAP_SHARED) return (EINVAL); /* * Check to ensure that the entire range is * legal and we are not trying to map in * more than the device will let us. */ for (i = 0; i < len; i += PAGESIZE) { if (cdev_mmap(mapfunc, dev, off + i, maxprot) == -1) return (ENXIO); } as_rangelock(as); /* Pick an address w/o worrying about any vac alignment constraints. */ error = choose_addr(as, addrp, len, off, ADDR_NOVACALIGN, flags); if (error != 0) { as_rangeunlock(as); return (error); } dev_a.mapfunc = mapfunc; dev_a.dev = dev; dev_a.offset = off; dev_a.prot = (uchar_t)prot; dev_a.maxprot = (uchar_t)maxprot; dev_a.hat_flags = 0; dev_a.hat_attr = 0; dev_a.devmap_data = NULL; error = as_map(as, *addrp, len, segdev_create, &dev_a); as_rangeunlock(as); return (error); } int spec_char_map( dev_t dev, offset_t off, struct as *as, caddr_t *addrp, size_t len, uchar_t prot, uchar_t maxprot, uint_t flags, struct cred *cred) { int error = 0; major_t maj = getmajor(dev); int map_flag; int (*segmap)(dev_t, off_t, struct as *, caddr_t *, off_t, uint_t, uint_t, uint_t, cred_t *); int (*devmap)(dev_t, devmap_cookie_t, offset_t, size_t, size_t *, uint_t); int (*mmap)(dev_t dev, off_t off, int prot); /* * Character device: let the device driver * pick the appropriate segment driver. * * 4.x compat.: allow 'NULL' cb_segmap => spec_segmap * Kindness: allow 'nulldev' cb_segmap => spec_segmap */ segmap = devopsp[maj]->devo_cb_ops->cb_segmap; if (segmap == NULL || segmap == nulldev || segmap == nodev) { mmap = devopsp[maj]->devo_cb_ops->cb_mmap; map_flag = devopsp[maj]->devo_cb_ops->cb_flag; /* * Use old mmap framework if the driver has both mmap * and devmap entry points. This is to prevent the * system from calling invalid devmap entry point * for some drivers that might have put garbage in the * devmap entry point. */ if ((map_flag & D_DEVMAP) || mmap == NULL || mmap == nulldev || mmap == nodev) { devmap = devopsp[maj]->devo_cb_ops->cb_devmap; /* * If driver provides devmap entry point in * cb_ops but not xx_segmap(9E), call * devmap_setup with default settings * (NULL) for callback_ops and driver * callback private data */ if (devmap == nodev || devmap == NULL || devmap == nulldev) return (ENODEV); error = devmap_setup(dev, off, as, addrp, len, prot, maxprot, flags, cred); return (error); } else segmap = spec_segmap; } else segmap = cdev_segmap; return ((*segmap)(dev, (off_t)off, as, addrp, len, prot, maxprot, flags, cred)); } /*ARGSUSED9*/ static int spec_map( struct vnode *vp, offset_t off, struct as *as, caddr_t *addrp, size_t len, uchar_t prot, uchar_t maxprot, uint_t flags, struct cred *cred, caller_context_t *ct) { int error = 0; struct snode *sp = VTOS(vp); if (vp->v_flag & VNOMAP) return (ENOSYS); /* fail map with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); /* * If file is locked, fail mapping attempt. */ if (vn_has_flocks(vp)) return (EAGAIN); if (vp->v_type == VCHR) { return (spec_char_map(vp->v_rdev, off, as, addrp, len, prot, maxprot, flags, cred)); } else if (vp->v_type == VBLK) { struct segvn_crargs vn_a; struct vnode *cvp; struct snode *sp; /* * Block device, use segvn mapping to the underlying commonvp * for pages. */ if (off > spec_maxoffset(vp)) return (ENXIO); sp = VTOS(vp); cvp = sp->s_commonvp; ASSERT(cvp != NULL); if (off < 0 || ((offset_t)(off + len) < 0)) return (ENXIO); as_rangelock(as); error = choose_addr(as, addrp, len, off, ADDR_VACALIGN, flags); if (error != 0) { as_rangeunlock(as); return (error); } vn_a.vp = cvp; vn_a.offset = off; vn_a.type = flags & MAP_TYPE; vn_a.prot = (uchar_t)prot; vn_a.maxprot = (uchar_t)maxprot; vn_a.flags = flags & ~MAP_TYPE; vn_a.cred = cred; vn_a.amp = NULL; vn_a.szc = 0; vn_a.lgrp_mem_policy_flags = 0; error = as_map(as, *addrp, len, segvn_create, &vn_a); as_rangeunlock(as); } else return (ENODEV); return (error); } /*ARGSUSED1*/ static int spec_addmap( struct vnode *vp, /* the common vnode */ offset_t off, struct as *as, caddr_t addr, size_t len, /* how many bytes to add */ uchar_t prot, uchar_t maxprot, uint_t flags, struct cred *cred, caller_context_t *ct) { int error = 0; struct snode *csp = VTOS(vp); ulong_t npages; ASSERT(vp != NULL && VTOS(vp)->s_commonvp == vp); /* * XXX Given the above assertion, this might not * be a particularly sensible thing to test. */ if (vp->v_flag & VNOMAP) return (ENOSYS); /* fail with EIO if the device is fenced off */ if (S_ISFENCED(csp)) return (EIO); npages = btopr(len); LOCK_CSP(csp); csp->s_mapcnt += npages; UNLOCK_CSP(csp); return (error); } /*ARGSUSED1*/ static int spec_delmap( struct vnode *vp, /* the common vnode */ offset_t off, struct as *as, caddr_t addr, size_t len, /* how many bytes to take away */ uint_t prot, uint_t maxprot, uint_t flags, struct cred *cred, caller_context_t *ct) { struct snode *csp = VTOS(vp); ulong_t npages; long mcnt; /* segdev passes us the common vp */ ASSERT(vp != NULL && VTOS(vp)->s_commonvp == vp); /* allow delmap to succeed even if device fenced off */ /* * XXX Given the above assertion, this might not * be a particularly sensible thing to test.. */ if (vp->v_flag & VNOMAP) return (ENOSYS); npages = btopr(len); LOCK_CSP(csp); mutex_enter(&csp->s_lock); mcnt = (csp->s_mapcnt -= npages); if (mcnt == 0) { /* * Call the close routine when the last reference of any * kind through any [s, v]node goes away. The s_dip hold * on the devinfo node is released when the vnode is * destroyed. */ if (csp->s_count == 0) { csp->s_flag &= ~(SNEEDCLOSE | SSIZEVALID); /* See comment in spec_close() */ if (csp->s_flag & (SCLONE | SSELFCLONE)) csp->s_flag &= ~SDIPSET; mutex_exit(&csp->s_lock); (void) device_close(vp, 0, cred); } else mutex_exit(&csp->s_lock); mutex_enter(&csp->s_lock); } ASSERT(mcnt >= 0); UNLOCK_CSP_LOCK_HELD(csp); mutex_exit(&csp->s_lock); return (0); } /*ARGSUSED4*/ static int spec_dump( struct vnode *vp, caddr_t addr, offset_t bn, offset_t count, caller_context_t *ct) { /* allow dump to succeed even if device fenced off */ ASSERT(vp->v_type == VBLK); return (bdev_dump(vp->v_rdev, addr, (daddr_t)bn, (int)count)); } /* * Do i/o on the given page list from/to vp, io_off for io_len. * Flags are composed of: * {B_ASYNC, B_INVAL, B_FREE, B_DONTNEED, B_READ, B_WRITE} * If B_ASYNC is not set i/o is waited for. */ /*ARGSUSED5*/ static int spec_pageio( struct vnode *vp, page_t *pp, u_offset_t io_off, size_t io_len, int flags, cred_t *cr, caller_context_t *ct) { struct buf *bp = NULL; int err = 0; if (pp == NULL) return (EINVAL); bp = spec_startio(vp, pp, io_off, io_len, flags); /* * Wait for i/o to complete if the request is not B_ASYNC. */ if ((flags & B_ASYNC) == 0) { err = biowait(bp); pageio_done(bp); } return (err); } /* * Set ACL on underlying vnode if one exists, or return ENOSYS otherwise. */ int spec_setsecattr( struct vnode *vp, vsecattr_t *vsap, int flag, struct cred *cr, caller_context_t *ct) { struct vnode *realvp; struct snode *sp = VTOS(vp); int error; /* fail with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); /* * The acl(2) system calls VOP_RWLOCK on the file before setting an * ACL, but since specfs does not serialize reads and writes, this * VOP does not do anything. However, some backing file systems may * expect the lock to be held before setting an ACL, so it is taken * here privately to avoid serializing specfs reads and writes. */ if ((realvp = sp->s_realvp) != NULL) { (void) VOP_RWLOCK(realvp, V_WRITELOCK_TRUE, ct); error = VOP_SETSECATTR(realvp, vsap, flag, cr, ct); (void) VOP_RWUNLOCK(realvp, V_WRITELOCK_TRUE, ct); return (error); } else return (fs_nosys()); } /* * Get ACL from underlying vnode if one exists, or fabricate it from * the permissions returned by spec_getattr() otherwise. */ int spec_getsecattr( struct vnode *vp, vsecattr_t *vsap, int flag, struct cred *cr, caller_context_t *ct) { struct vnode *realvp; struct snode *sp = VTOS(vp); /* fail with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); if ((realvp = sp->s_realvp) != NULL) return (VOP_GETSECATTR(realvp, vsap, flag, cr, ct)); else return (fs_fab_acl(vp, vsap, flag, cr, ct)); } int spec_pathconf( vnode_t *vp, int cmd, ulong_t *valp, cred_t *cr, caller_context_t *ct) { vnode_t *realvp; struct snode *sp = VTOS(vp); /* fail with ENXIO if the device is fenced off */ if (S_ISFENCED(sp)) return (ENXIO); if ((realvp = sp->s_realvp) != NULL) return (VOP_PATHCONF(realvp, cmd, valp, cr, ct)); else return (fs_pathconf(vp, cmd, valp, cr, ct)); }
{ "url": "https://www.josefsipek.net/illumos/cr/5382-pvn_getpages-handles-lengths-PAGESIZE-just-fine/raw_files/new/usr/src/uts/common/fs/specfs/specvnops.c", "source_domain": "www.josefsipek.net", "snapshot_id": "crawl=CC-MAIN-2022-21", "warc_metadata": { "Content-Length": "66741", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:MXEJIT55WJJ5OHS76DYJRAMWL3LL3SQO", "WARC-Concurrent-To": "<urn:uuid:f53289c2-e6fa-44ed-9c3f-345d83d696ef>", "WARC-Date": "2022-05-22T10:47:02Z", "WARC-IP-Address": "71.174.62.3", "WARC-Identified-Payload-Type": "text/x-csrc", "WARC-Payload-Digest": "sha1:LAVP4LANIOKUCTNEVHYJAFUFS4KUUEN4", "WARC-Record-ID": "<urn:uuid:acd0ff81-3748-43db-980c-ef604ce0608f>", "WARC-Target-URI": "https://www.josefsipek.net/illumos/cr/5382-pvn_getpages-handles-lengths-PAGESIZE-just-fine/raw_files/new/usr/src/uts/common/fs/specfs/specvnops.c", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:8d53a51c-645a-4737-9ca6-21b3734a41fe>" }, "warc_info": "isPartOf: CC-MAIN-2022-21\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-200\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0 ], "line_end_idx": [ 61207 ] }
{ "red_pajama_v2": { "ccnet_original_length": 61207, "ccnet_original_nlines": 0, "rps_doc_curly_bracket": 0.006731260102242231, "rps_doc_ldnoobw_words": 7, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.1352517008781433, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05242941156029701, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.4507042169570923, "rps_doc_frac_unique_words": 0.2161572128534317, "rps_doc_mean_word_length": 5.634006500244141, "rps_doc_num_sentences": 373, "rps_doc_symbol_to_word_ratio": 0.004312959965318441, "rps_doc_unigram_entropy": 6.191651344299316, "rps_doc_word_count": 7328, "rps_doc_frac_chars_dupe_10grams": 0.1359540820121765, "rps_doc_frac_chars_dupe_5grams": 0.2492854744195938, "rps_doc_frac_chars_dupe_6grams": 0.21709537506103516, "rps_doc_frac_chars_dupe_7grams": 0.19137237966060638, "rps_doc_frac_chars_dupe_8grams": 0.17151091992855072, "rps_doc_frac_chars_dupe_9grams": 0.15055951476097107, "rps_doc_frac_chars_top_2gram": 0.011117570102214813, "rps_doc_frac_chars_top_3gram": 0.024415060877799988, "rps_doc_frac_chars_top_4gram": 0.031875211745500565, "rps_doc_books_importance": -6850.353515625, "rps_doc_books_importance_length_correction": -6850.353515625, "rps_doc_openwebtext_importance": -3745.9228515625, "rps_doc_openwebtext_importance_length_correction": -3745.9228515625, "rps_doc_wikipedia_importance": -2707.605224609375, "rps_doc_wikipedia_importance_length_correction": -2707.605224609375 }, "fasttext": { "dclm": 0.9455006718635559, "english": 0.5207479000091553, "fineweb_edu_approx": 2.37241530418396, "eai_general_math": 0.4815524220466614, "eai_open_web_math": 0.16872215270996094, "eai_web_code": 0.5652857422828674 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,328,361,035,833,893,000
Community Resources This section gives the community a space to provide information on setting up, managing, and maintaining JupyterHub. Important We recognize that Kubernetes has many deployment options. As a project team with limited resources to provide end user support, we rely on community members to share their collective Kubernetes knowledge and JupyterHub experiences. Note Contributing to Z2JH. If you would like to help improve the Zero to JupyterHub guide, please see the issues page as well as the contributor guide. We hope that you will use this section to share deployments with on a variety of infrastructure and for different use cases. There is also a community maintained list of users of this Guide and the JupyterHub Helm Chart. Please submit an issue/pull request to add to this section. Thanks. Tips and Snippets This is a page to collect a few particularly useful patterns and snippets that help you interact with your Kubernetes cluster and JupyterHub. If there’s something that you think is generic enough (and not obvious enough) to be added to this page, please feel free to make a PR! kubectl autocompletion Kubernetes has a helper script that allows you to auto-complete commands and references to objects when using kubectl. This lets you TAB-complete and saves a lot of time. Follow the kubectl installation instructions for your platform to find the shell autocompletion instructions. helm autocompletion Helm also has an auto-completion script that lets you TAB-complete your commands when using Helm. Here are the instructions to install helm auto-completion. Managing kubectl contexts Oftentimes people manage multiple Kubernetes deployments at the same time. kubectl handles this with the idea of “contexts”, which specify which Kubernetes deployment you are referring to when you type kubectl get XXX. To see a list of contexts currently available to you, use the following command: kubectl config get-contexts This will list all of your Kubernetes contexts. You can select a particular context by entering: kubectl config use-context <CONTEXT-NAME> Specifying a default namespace for a context If you grow tired of typing namespace=XXX each time you type a kubernetes command, here’s a snippet that will allow you set a default namespace for a given Kubernetes context: kubectl config set-context $(kubectl config current-context) \ --namespace=<YOUR-NAMESPACE> The above command will only apply to the currently active context, and will allow you to skip the --namespace= part of your commands for this context. Using labels and selectors with kubectl Sometimes it’s useful to select an entire class of Kubernetes objects rather than referring to them by their name. You can attach an arbitrary set of labels to a Kubernetes object, and can then refer to those labels when searching with kubectl. To search based on a label value, use the -l or --selector= keyword arguments. For example, JupyterHub creates a specific subset of labels for all user pods. You can search for all user pods with the following label query: kubectl --namespace=<YOUR-NAMESPACE> get pod \ -l "component=singleuser-server" For more information, see the Kubernetes labels and selectors page. Asking for a more verbose or structured output Sometimes the information that’s in the default output for kubectl get <XXX> is not enough for your needs, or isn’t structured the way you’d like. We recommend looking into the different Kubernetes output options, which can be modified like so: kubectl --namespace=<NAMESPACE> get pod -o <json|yaml|wide|name...> You can find more information on what kinds of output you can generate at the kubectl information page. (click and search for the text “Output Options”) This is a community maintained list of organizations / people using the Zero to JupyterHub guide and Helm chart to maintain their JupyterHub. Send us a Pull Request to add yourself to this alphabetically sorted list!
{ "url": "https://z2jh.jupyter.org/en/latest/resources/community.html", "source_domain": "z2jh.jupyter.org", "snapshot_id": "crawl=CC-MAIN-2021-25", "warc_metadata": { "Content-Length": "23353", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:Z4XVD4GIFZP7DGNMU6UOZVRXLVHTX44Y", "WARC-Concurrent-To": "<urn:uuid:d5316691-0a24-4438-9a4d-a184634f399b>", "WARC-Date": "2021-06-24T05:09:31Z", "WARC-IP-Address": "104.17.33.82", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:6WCFOYHIB453AWMC3HOAQ6Z6TKMRLFTQ", "WARC-Record-ID": "<urn:uuid:af24bf55-6cee-4a61-b6df-5c6502d5a420>", "WARC-Target-URI": "https://z2jh.jupyter.org/en/latest/resources/community.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:32255d0e-285c-4452-8b4d-e1f8005180eb>" }, "warc_info": "isPartOf: CC-MAIN-2021-25\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-177.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 20, 21, 138, 139, 149, 150, 382, 383, 388, 389, 536, 537, 758, 759, 827, 828, 846, 847, 1125, 1126, 1149, 1150, 1321, 1322, 1432, 1433, 1453, 1454, 1552, 1553, 1612, 1613, 1639, 1640, 1859, 1860, 1941, 1942, 1970, 1971, 2068, 2069, 2111, 2112, 2157, 2158, 2334, 2335, 2398, 2431, 2432, 2583, 2584, 2624, 2625, 2870, 2871, 3094, 3095, 3142, 3179, 3180, 3248, 3249, 3296, 3297, 3542, 3543, 3611, 3612, 3765, 3766 ], "line_end_idx": [ 20, 21, 138, 139, 149, 150, 382, 383, 388, 389, 536, 537, 758, 759, 827, 828, 846, 847, 1125, 1126, 1149, 1150, 1321, 1322, 1432, 1433, 1453, 1454, 1552, 1553, 1612, 1613, 1639, 1640, 1859, 1860, 1941, 1942, 1970, 1971, 2068, 2069, 2111, 2112, 2157, 2158, 2334, 2335, 2398, 2431, 2432, 2583, 2584, 2624, 2625, 2870, 2871, 3094, 3095, 3142, 3179, 3180, 3248, 3249, 3296, 3297, 3542, 3543, 3611, 3612, 3765, 3766, 3982 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3982, "ccnet_original_nlines": 72, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 2, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.40933331847190857, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.018666669726371765, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.14533333480358124, "rps_doc_frac_unique_words": 0.41109299659729004, "rps_doc_mean_word_length": 5.238173007965088, "rps_doc_num_sentences": 30, "rps_doc_symbol_to_word_ratio": 0.0013333299430087209, "rps_doc_unigram_entropy": 4.989573001861572, "rps_doc_word_count": 613, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.04422298073768616, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.009342879988253117, "rps_doc_frac_chars_top_3gram": 0.005605730228126049, "rps_doc_frac_chars_top_4gram": 0.011834319680929184, "rps_doc_books_importance": -352.8983459472656, "rps_doc_books_importance_length_correction": -352.8983459472656, "rps_doc_openwebtext_importance": -176.03262329101562, "rps_doc_openwebtext_importance_length_correction": -176.03262329101562, "rps_doc_wikipedia_importance": -117.6573715209961, "rps_doc_wikipedia_importance_length_correction": -117.6573715209961 }, "fasttext": { "dclm": 0.18474668264389038, "english": 0.8086357116699219, "fineweb_edu_approx": 1.8002886772155762, "eai_general_math": 0.6864907145500183, "eai_open_web_math": 0.1144070029258728, "eai_web_code": 0.9802889823913574 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.445", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.028", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-1,260,403,565,511,117,000
ACCU Home page ACCU Conference Page Search Contact us ACCU at Flickr ACCU at GitHib ACCU at Facebook ACCU at Linked-in ACCU at Twitter Skip Navigation pinGetting Tuple Elements with a Runtime Index Programming Topics + Overload Journal #139 - June 2017   Author: Anthony Williams Accessing a tuple with a runtime index is a challenge. Anthony Williams shows us his approach. std::tuple is great. It provides a nice, generic way of holding a fixed-size set of data items of whatever types you need. However, sometimes it has limitations that mean it doesn’t quite work as you’d like. One of these is accessing an item based on a runtime index. std::get needs a compile-time index The way to get the nth item in a tuple is to use std::get: std::get<n>(my_tuple). This works nicely, as long as n is a compile-time constant. If you’ve got a value that is calculated at runtime, this doesn’t work: you can’t use a value that isn't known until runtime as a template parameter. std::tuple<int,int,int> my_tuple=...; size_t index; std::cin>>index; int val=std::get<index>(my_tuple); //won't compile So, what can we do? We need a new function, which I’ll call runtime_get, to retrieve the nth value, where n is a runtime value. template<typename Tuple> ... runtime_get(Tuple&& t,size_t index){ ... } The question is: how do we implement it? Fixed return type The return type is easy: our function must have a single return type for any given Tuple. That means that all the elements in the tuple must have the same type, so we can just use the type of the first element. std::tuple_element will tell us this, though we must first adjust our template parameter so it’s not a reference. template<typename Tuple> typename std::tuple_element< 0, typename std::remove_reference<Tuple> ::type>::type& runtime_get(Tuple&& t,size_t index){ ... } Note: C++17 includes std::variant, so you might think we could use that to hold the return type, but that wouldn’t actually help us: to get the value from a variant, you need to call std::get<n>(v), which requires n to be a constant (again)! OK, so the return type is just a reference to the type of the first element. How do we get the element? Retrieving the nth element We can’t do a straightforward switch, because that requires knowing all the cases in advance, and we want this to work for any size of tuple. One way would be to have a recursive function that checked the runtime index against a compile-time index, and then called the function with the next compile-time index if they were different, but that would mean that the access time would depend on the index, and potentially end up with a deeply nested function call if we wanted the last element in a large tuple. One thing we can do is use the index value as an array index. If we have an array of functions, each of which returns the corresponding element from the tuple, then we can call the appropriate function to return the relevant index. The function we need is of course std::get; it’s just a matter of getting the function signature right. Our overload of std::get has the following signature for const and non-const tuples: template <size_t I, class... Types> constexpr tuple_element_t<I, tuple<Types...>>& get(tuple<Types...>&) noexcept; template <size_t I, class... Types> constexpr const tuple_element_t<I, tuple<Types...>>& get(const tuple<Types...>&) noexcept; so, we can capture the relevant instantiation of std::get for a given tuple type Tuple in a function pointer declared as: using return_type=typename std::tuple_element<0,Tuple>::type&; using get_func_ptr=return_type(*)(Tuple&) noexcept; The signature is the same, regardless of the index, because we made the decision that we’re only going to support tuples where all the elements are the same. This makes it easy to build a function table: use a variadic pack expansion to supply a different index for each array element, and fill in std::get<N> for each entry (see Listing 1). template< typename Tuple, typename Indices=std::make_index_sequence<std::tuple_size<Tuple>::value>> struct runtime_get_func_table; template<typename Tuple,size_t ... Indices> struct runtime_get_func_table<Tuple,std::index_sequence<Indices...>>{ using return_type=typename std::tuple_element<0,Tuple>::type&; using get_func_ptr=return_type (*)(Tuple&) noexcept; static constexpr get_func_ptr table[std::tuple_size<Tuple>::value]={ &std::get<Indices>... }; }; template<typename Tuple,size_t ... Indices> constexpr typename runtime_get_func_table<Tuple,std::index_sequence<Indices...>>::get_func_ptr runtime_get_func_table<Tuple,std::index_sequence<Indices...>>::table[ std::tuple_size<Tuple>::value]; Listing 1 We need the separate redeclaration of the table to satisfy a pre-C++17 compiler; with C++17 inline variables it is no longer needed. Our final function is then just a simple wrapper around a table lookup (see Lising 2). template<typename Tuple> constexpr typename std::tuple_element<0,typename std::remove_reference<Tuple>::type>::type& runtime_get(Tuple&& t,size_t index){ using tuple_type=typename std::remove_reference<Tuple>::type; if(index>=std::tuple_size<tuple_type>::value) throw std::runtime_error("Out of range"); return runtime_get_func_table<tuple_type>::table[index](t); } Listing 2 It’s constexpr safe, though in a constexpr context you could probably just use std::get directly anyway. So, there you have it: a constant-time function for retrieving the nth element of a tuple where all the elements have the same type. Final code Listing 3 is the final code for a constant-time function to retrieve an item from a tuple based on a runtime index. #include <tuple> #include <utility> #include <type_traits> #include <stdexcept> template< typename Tuple, typename Indices=std::make_index_sequence<std::tuple_size<Tuple>::value>> struct runtime_get_func_table; template<typename Tuple,size_t ... Indices> struct runtime_get_func_table<Tuple,std::index_sequence<Indices...>>{ using return_type=typename std::tuple_element<0,Tuple>::type&; using get_func_ptr=return_type (*)(Tuple&) noexcept; static constexpr get_func_ptr table[std::tuple_size<Tuple>::value]={ &std::get<Indices>... }; }; template<typename Tuple,size_t ... Indices> constexpr typename runtime_get_func_table<Tuple,std::index_sequence<Indices...>>::get_func_ptr runtime_get_func_table<Tuple,std::index_sequence<Indices...>>::table[std::tuple_size<Tuple>::value]; template<typename Tuple> constexpr typename std::tuple_element<0,typename std::remove_reference<Tuple>::type>::type& runtime_get(Tuple&& t,size_t index){ using tuple_type=typename std::remove_reference<Tuple>::type; if(index>=std::tuple_size<tuple_type>::value) throw std::runtime_error("Out of range"); return runtime_get_func_table<tuple_type>::table[index](t); } Listing 3 Programming Topics + Overload Journal #139 - June 2017
{ "url": "https://members.accu.org/index.php/articles/2382", "source_domain": "members.accu.org", "snapshot_id": "crawl=CC-MAIN-2020-50", "warc_metadata": { "Content-Length": "28669", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:KM63JJLRZBKQDU5PGQLWOEQW4VUTWNMN", "WARC-Concurrent-To": "<urn:uuid:80bcfee9-c5c7-4bea-88e4-436e48ba83d9>", "WARC-Date": "2020-12-05T12:37:03Z", "WARC-IP-Address": "46.43.8.89", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:2ENM5KWHQLUEW2NFZP3T5FC2YU6U226H", "WARC-Record-ID": "<urn:uuid:dec5fe97-483d-47cd-ab71-f529f0fc4a0e>", "WARC-Target-URI": "https://members.accu.org/index.php/articles/2382", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:be35752b-7639-4999-8196-f9a725fbac0e>" }, "warc_info": "isPartOf: CC-MAIN-2020-50\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November/December 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-213.ec2.internal\r\nsoftware: Apache Nutch 1.17 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 36, 151, 152, 199, 200, 282, 377, 378, 646, 647, 683, 684, 976, 977, 1017, 1033, 1052, 1105, 1106, 1234, 1235, 1262, 1305, 1313, 1317, 1318, 1359, 1360, 1378, 1379, 1704, 1705, 1732, 1763, 1807, 1825, 1864, 1872, 1876, 1877, 2119, 2120, 2224, 2225, 2252, 2253, 2395, 2396, 2763, 2764, 2996, 2997, 3186, 3187, 3225, 3274, 3308, 3346, 3383, 3405, 3445, 3446, 3568, 3569, 3598, 3638, 3682, 3696, 3697, 3855, 3856, 4040, 4041, 4051, 4071, 4149, 4180, 4181, 4225, 4299, 4366, 4423, 4496, 4526, 4533, 4536, 4537, 4581, 4600, 4676, 4746, 4785, 4795, 4796, 4929, 4930, 5017, 5018, 5043, 5053, 5135, 5172, 5238, 5288, 5338, 5402, 5407, 5417, 5418, 5523, 5524, 5657, 5658, 5669, 5670, 5786, 5787, 5804, 5823, 5846, 5867, 5868, 5878, 5898, 5976, 6007, 6008, 6052, 6122, 6189, 6246, 6319, 6349, 6356, 6359, 6360, 6404, 6423, 6499, 6600, 6601, 6626, 6636, 6718, 6755, 6821, 6871, 6921, 6985, 6990, 7000, 7001 ], "line_end_idx": [ 36, 151, 152, 199, 200, 282, 377, 378, 646, 647, 683, 684, 976, 977, 1017, 1033, 1052, 1105, 1106, 1234, 1235, 1262, 1305, 1313, 1317, 1318, 1359, 1360, 1378, 1379, 1704, 1705, 1732, 1763, 1807, 1825, 1864, 1872, 1876, 1877, 2119, 2120, 2224, 2225, 2252, 2253, 2395, 2396, 2763, 2764, 2996, 2997, 3186, 3187, 3225, 3274, 3308, 3346, 3383, 3405, 3445, 3446, 3568, 3569, 3598, 3638, 3682, 3696, 3697, 3855, 3856, 4040, 4041, 4051, 4071, 4149, 4180, 4181, 4225, 4299, 4366, 4423, 4496, 4526, 4533, 4536, 4537, 4581, 4600, 4676, 4746, 4785, 4795, 4796, 4929, 4930, 5017, 5018, 5043, 5053, 5135, 5172, 5238, 5288, 5338, 5402, 5407, 5417, 5418, 5523, 5524, 5657, 5658, 5669, 5670, 5786, 5787, 5804, 5823, 5846, 5867, 5868, 5878, 5898, 5976, 6007, 6008, 6052, 6122, 6189, 6246, 6319, 6349, 6356, 6359, 6360, 6404, 6423, 6499, 6600, 6601, 6626, 6636, 6718, 6755, 6821, 6871, 6921, 6985, 6990, 7000, 7001, 7055 ] }
{ "red_pajama_v2": { "ccnet_original_length": 7055, "ccnet_original_nlines": 152, "rps_doc_curly_bracket": 0.0022678999230265617, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.29774126410484314, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.01163586974143982, "rps_doc_frac_lines_end_with_ellipsis": 0.026143789291381836, "rps_doc_frac_no_alph_words": 0.2861054241657257, "rps_doc_frac_unique_words": 0.36768150329589844, "rps_doc_mean_word_length": 6.120608806610107, "rps_doc_num_sentences": 53, "rps_doc_symbol_to_word_ratio": 0.019164960831403732, "rps_doc_unigram_entropy": 5.184077739715576, "rps_doc_word_count": 854, "rps_doc_frac_chars_dupe_10grams": 0.2793189287185669, "rps_doc_frac_chars_dupe_5grams": 0.3252343535423279, "rps_doc_frac_chars_dupe_6grams": 0.31758180260658264, "rps_doc_frac_chars_dupe_7grams": 0.2957719564437866, "rps_doc_frac_chars_dupe_8grams": 0.2793189287185669, "rps_doc_frac_chars_dupe_9grams": 0.2793189287185669, "rps_doc_frac_chars_top_2gram": 0.0057394299656152725, "rps_doc_frac_chars_top_3gram": 0.009948349557816982, "rps_doc_frac_chars_top_4gram": 0.03041898086667061, "rps_doc_books_importance": -699.2977905273438, "rps_doc_books_importance_length_correction": -699.2977905273438, "rps_doc_openwebtext_importance": -352.8275451660156, "rps_doc_openwebtext_importance_length_correction": -352.8275451660156, "rps_doc_wikipedia_importance": -211.63868713378906, "rps_doc_wikipedia_importance_length_correction": -211.63868713378906 }, "fasttext": { "dclm": 0.213739275932312, "english": 0.6869516372680664, "fineweb_edu_approx": 2.1949563026428223, "eai_general_math": 0.9759253263473511, "eai_open_web_math": 0.22363394498825073, "eai_web_code": 0.9497228264808655 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1332", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.133", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-1,464,750,898,732,760,600
     Logo Search packages:       Sourcecode: wine-unstable version File versions  Download package comm.c /* * DEC 93 Erik Bos <erik@xs4all.nl> * * Copyright 1996 Marcus Meissner * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA */ #include "config.h" #include "wine/port.h" #include <stdlib.h> #include <stdarg.h> #include <stdio.h> #define NONAMELESSUNION #define NONAMELESSSTRUCT #include "windef.h" #include "winbase.h" #include "winerror.h" #include "winioctl.h" #include "ddk/ntddser.h" #include "wine/server.h" #include "wine/unicode.h" #include "wine/debug.h" WINE_DEFAULT_DEBUG_CHANNEL(comm); /*********************************************************************** * COMM_Parse* (Internal) * * The following COMM_Parse* functions are used by the BuildCommDCB * functions to help parse the various parts of the device control string. */ static LPCWSTR COMM_ParseStart(LPCWSTR ptr) { static const WCHAR comW[] = {'C','O','M',0}; /* The device control string may optionally start with "COMx" followed by an optional ':' and spaces. */ if(!strncmpiW(ptr, comW, 3)) { ptr += 3; /* Allow any com port above 0 as Win 9x does (NT only allows values for com ports which are actually present) */ if(*ptr < '1' || *ptr > '9') return NULL; /* Advance pointer past port number */ while(*ptr >= '0' && *ptr <= '9') ptr++; /* The com port number must be followed by a ':' or ' ' */ if(*ptr != ':' && *ptr != ' ') return NULL; /* Advance pointer to beginning of next parameter */ while(*ptr == ' ') ptr++; if(*ptr == ':') { ptr++; while(*ptr == ' ') ptr++; } } /* The device control string must not start with a space. */ else if(*ptr == ' ') return NULL; return ptr; } static LPCWSTR COMM_ParseNumber(LPCWSTR ptr, LPDWORD lpnumber) { if(*ptr < '0' || *ptr > '9') return NULL; *lpnumber = strtoulW(ptr, NULL, 10); while(*ptr >= '0' && *ptr <= '9') ptr++; return ptr; } static LPCWSTR COMM_ParseParity(LPCWSTR ptr, LPBYTE lpparity) { /* Contrary to what you might expect, Windows only sets the Parity member of DCB and not fParity even when parity is specified in the device control string */ switch(toupperW(*ptr++)) { case 'E': *lpparity = EVENPARITY; break; case 'M': *lpparity = MARKPARITY; break; case 'N': *lpparity = NOPARITY; break; case 'O': *lpparity = ODDPARITY; break; case 'S': *lpparity = SPACEPARITY; break; default: return NULL; } return ptr; } static LPCWSTR COMM_ParseByteSize(LPCWSTR ptr, LPBYTE lpbytesize) { DWORD temp; if(!(ptr = COMM_ParseNumber(ptr, &temp))) return NULL; if(temp >= 5 && temp <= 8) { *lpbytesize = temp; return ptr; } else return NULL; } static LPCWSTR COMM_ParseStopBits(LPCWSTR ptr, LPBYTE lpstopbits) { DWORD temp; static const WCHAR stopbits15W[] = {'1','.','5',0}; if(!strncmpW(stopbits15W, ptr, 3)) { ptr += 3; *lpstopbits = ONE5STOPBITS; } else { if(!(ptr = COMM_ParseNumber(ptr, &temp))) return NULL; if(temp == 1) *lpstopbits = ONESTOPBIT; else if(temp == 2) *lpstopbits = TWOSTOPBITS; else return NULL; } return ptr; } static LPCWSTR COMM_ParseOnOff(LPCWSTR ptr, LPDWORD lponoff) { static const WCHAR onW[] = {'o','n',0}; static const WCHAR offW[] = {'o','f','f',0}; if(!strncmpiW(onW, ptr, 2)) { ptr += 2; *lponoff = 1; } else if(!strncmpiW(offW, ptr, 3)) { ptr += 3; *lponoff = 0; } else return NULL; return ptr; } /*********************************************************************** * COMM_BuildOldCommDCB (Internal) * * Build a DCB using the old style settings string eg: "96,n,8,1" */ static BOOL COMM_BuildOldCommDCB(LPCWSTR device, LPDCB lpdcb) { WCHAR last = 0; if(!(device = COMM_ParseNumber(device, &lpdcb->BaudRate))) return FALSE; switch(lpdcb->BaudRate) { case 11: case 30: case 60: lpdcb->BaudRate *= 10; break; case 12: case 24: case 48: case 96: lpdcb->BaudRate *= 100; break; case 19: lpdcb->BaudRate = 19200; break; } while(*device == ' ') device++; if(*device++ != ',') return FALSE; while(*device == ' ') device++; if(!(device = COMM_ParseParity(device, &lpdcb->Parity))) return FALSE; while(*device == ' ') device++; if(*device++ != ',') return FALSE; while(*device == ' ') device++; if(!(device = COMM_ParseByteSize(device, &lpdcb->ByteSize))) return FALSE; while(*device == ' ') device++; if(*device++ != ',') return FALSE; while(*device == ' ') device++; if(!(device = COMM_ParseStopBits(device, &lpdcb->StopBits))) return FALSE; /* The last parameter for flow control is optional. */ while(*device == ' ') device++; if(*device == ',') { device++; while(*device == ' ') device++; if(*device) last = toupperW(*device++); while(*device == ' ') device++; } /* Win NT sets the flow control members based on (or lack of) the last parameter. Win 9x does not set these members. */ switch(last) { case 0: lpdcb->fInX = FALSE; lpdcb->fOutX = FALSE; lpdcb->fOutxCtsFlow = FALSE; lpdcb->fOutxDsrFlow = FALSE; lpdcb->fDtrControl = DTR_CONTROL_ENABLE; lpdcb->fRtsControl = RTS_CONTROL_ENABLE; break; case 'X': lpdcb->fInX = TRUE; lpdcb->fOutX = TRUE; lpdcb->fOutxCtsFlow = FALSE; lpdcb->fOutxDsrFlow = FALSE; lpdcb->fDtrControl = DTR_CONTROL_ENABLE; lpdcb->fRtsControl = RTS_CONTROL_ENABLE; break; case 'P': lpdcb->fInX = FALSE; lpdcb->fOutX = FALSE; lpdcb->fOutxCtsFlow = TRUE; lpdcb->fOutxDsrFlow = TRUE; lpdcb->fDtrControl = DTR_CONTROL_HANDSHAKE; lpdcb->fRtsControl = RTS_CONTROL_HANDSHAKE; break; default: return FALSE; } /* This should be the end of the string. */ if(*device) return FALSE; return TRUE; } /*********************************************************************** * COMM_BuildNewCommDCB (Internal) * * Build a DCB using the new style settings string. * eg: "baud=9600 parity=n data=8 stop=1 xon=on to=on" */ static BOOL COMM_BuildNewCommDCB(LPCWSTR device, LPDCB lpdcb, LPCOMMTIMEOUTS lptimeouts) { DWORD temp; BOOL baud = FALSE, stop = FALSE; static const WCHAR baudW[] = {'b','a','u','d','=',0}; static const WCHAR parityW[] = {'p','a','r','i','t','y','=',0}; static const WCHAR dataW[] = {'d','a','t','a','=',0}; static const WCHAR stopW[] = {'s','t','o','p','=',0}; static const WCHAR toW[] = {'t','o','=',0}; static const WCHAR xonW[] = {'x','o','n','=',0}; static const WCHAR odsrW[] = {'o','d','s','r','=',0}; static const WCHAR octsW[] = {'o','c','t','s','=',0}; static const WCHAR dtrW[] = {'d','t','r','=',0}; static const WCHAR rtsW[] = {'r','t','s','=',0}; static const WCHAR idsrW[] = {'i','d','s','r','=',0}; while(*device) { while(*device == ' ') device++; if(!strncmpiW(baudW, device, 5)) { baud = TRUE; if(!(device = COMM_ParseNumber(device + 5, &lpdcb->BaudRate))) return FALSE; } else if(!strncmpiW(parityW, device, 7)) { if(!(device = COMM_ParseParity(device + 7, &lpdcb->Parity))) return FALSE; } else if(!strncmpiW(dataW, device, 5)) { if(!(device = COMM_ParseByteSize(device + 5, &lpdcb->ByteSize))) return FALSE; } else if(!strncmpiW(stopW, device, 5)) { stop = TRUE; if(!(device = COMM_ParseStopBits(device + 5, &lpdcb->StopBits))) return FALSE; } else if(!strncmpiW(toW, device, 3)) { if(!(device = COMM_ParseOnOff(device + 3, &temp))) return FALSE; lptimeouts->ReadIntervalTimeout = 0; lptimeouts->ReadTotalTimeoutMultiplier = 0; lptimeouts->ReadTotalTimeoutConstant = 0; lptimeouts->WriteTotalTimeoutMultiplier = 0; lptimeouts->WriteTotalTimeoutConstant = temp ? 60000 : 0; } else if(!strncmpiW(xonW, device, 4)) { if(!(device = COMM_ParseOnOff(device + 4, &temp))) return FALSE; lpdcb->fOutX = temp; lpdcb->fInX = temp; } else if(!strncmpiW(odsrW, device, 5)) { if(!(device = COMM_ParseOnOff(device + 5, &temp))) return FALSE; lpdcb->fOutxDsrFlow = temp; } else if(!strncmpiW(octsW, device, 5)) { if(!(device = COMM_ParseOnOff(device + 5, &temp))) return FALSE; lpdcb->fOutxCtsFlow = temp; } else if(!strncmpiW(dtrW, device, 4)) { if(!(device = COMM_ParseOnOff(device + 4, &temp))) return FALSE; lpdcb->fDtrControl = temp; } else if(!strncmpiW(rtsW, device, 4)) { if(!(device = COMM_ParseOnOff(device + 4, &temp))) return FALSE; lpdcb->fRtsControl = temp; } else if(!strncmpiW(idsrW, device, 5)) { if(!(device = COMM_ParseOnOff(device + 5, &temp))) return FALSE; /* Win NT sets the fDsrSensitivity member based on the idsr parameter. Win 9x sets fOutxDsrFlow instead. */ lpdcb->fDsrSensitivity = temp; } else return FALSE; /* After the above parsing, the next character (if not the end of the string) should be a space */ if(*device && *device != ' ') return FALSE; } /* If stop bits were not specified, a default is always supplied. */ if(!stop) { if(baud && lpdcb->BaudRate == 110) lpdcb->StopBits = TWOSTOPBITS; else lpdcb->StopBits = ONESTOPBIT; } return TRUE; } /************************************************************************** * BuildCommDCBA (KERNEL32.@) * * Updates a device control block data structure with values from an * ascii device control string. The device control string has two forms * normal and extended, it must be exclusively in one or the other form. * * RETURNS * * True on success, false on a malformed control string. */ BOOL WINAPI BuildCommDCBA( LPCSTR device, /* [in] The ascii device control string used to update the DCB. */ LPDCB lpdcb) /* [out] The device control block to be updated. */ { return BuildCommDCBAndTimeoutsA(device,lpdcb,NULL); } /************************************************************************** * BuildCommDCBAndTimeoutsA (KERNEL32.@) * * Updates a device control block data structure with values from an * ascii device control string. Taking timeout values from a timeouts * struct if desired by the control string. * * RETURNS * * True on success, false bad handles etc. */ BOOL WINAPI BuildCommDCBAndTimeoutsA( LPCSTR device, /* [in] The ascii device control string. */ LPDCB lpdcb, /* [out] The device control block to be updated. */ LPCOMMTIMEOUTS lptimeouts) /* [in] The COMMTIMEOUTS structure to be updated. */ { BOOL ret = FALSE; UNICODE_STRING deviceW; TRACE("(%s,%p,%p)\n",device,lpdcb,lptimeouts); if(device) RtlCreateUnicodeStringFromAsciiz(&deviceW,device); else deviceW.Buffer = NULL; if(deviceW.Buffer) ret = BuildCommDCBAndTimeoutsW(deviceW.Buffer,lpdcb,lptimeouts); RtlFreeUnicodeString(&deviceW); return ret; } /************************************************************************** * BuildCommDCBAndTimeoutsW (KERNEL32.@) * * Updates a device control block data structure with values from a * unicode device control string. Taking timeout values from a timeouts * struct if desired by the control string. * * RETURNS * * True on success, false bad handles etc */ BOOL WINAPI BuildCommDCBAndTimeoutsW( LPCWSTR devid, /* [in] The unicode device control string. */ LPDCB lpdcb, /* [out] The device control block to be updated. */ LPCOMMTIMEOUTS lptimeouts) /* [in] The COMMTIMEOUTS structure to be updated. */ { DCB dcb; COMMTIMEOUTS timeouts; BOOL result; LPCWSTR ptr = devid; TRACE("(%s,%p,%p)\n",debugstr_w(devid),lpdcb,lptimeouts); memset(&timeouts, 0, sizeof timeouts); /* Set DCBlength. (Windows NT does not do this, but 9x does) */ lpdcb->DCBlength = sizeof(DCB); /* Make a copy of the original data structures to work with since if if there is an error in the device control string the originals should not be modified (except possibly DCBlength) */ dcb = *lpdcb; if(lptimeouts) timeouts = *lptimeouts; ptr = COMM_ParseStart(ptr); if(ptr == NULL) result = FALSE; else if(strchrW(ptr, ',')) result = COMM_BuildOldCommDCB(ptr, &dcb); else result = COMM_BuildNewCommDCB(ptr, &dcb, &timeouts); if(result) { *lpdcb = dcb; if(lptimeouts) *lptimeouts = timeouts; return TRUE; } else { WARN("Invalid device control string: %s\n", debugstr_w(devid)); SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } } /************************************************************************** * BuildCommDCBW (KERNEL32.@) * * Updates a device control block structure with values from an * unicode device control string. The device control string has two forms * normal and extended, it must be exclusively in one or the other form. * * RETURNS * * True on success, false on a malformed control string. */ BOOL WINAPI BuildCommDCBW( LPCWSTR devid, /* [in] The unicode device control string. */ LPDCB lpdcb) /* [out] The device control block to be updated. */ { return BuildCommDCBAndTimeoutsW(devid,lpdcb,NULL); } /***************************************************************************** * SetCommBreak (KERNEL32.@) * * Halts the transmission of characters to a communications device. * * PARAMS * handle [in] The communications device to suspend * * RETURNS * * True on success, and false if the communications device could not be found, * the control is not supported. * * BUGS * * Only TIOCSBRK and TIOCCBRK are supported. */ BOOL WINAPI SetCommBreak(HANDLE handle) { DWORD dwBytesReturned; return DeviceIoControl(handle, IOCTL_SERIAL_SET_BREAK_ON, NULL, 0, NULL, 0, &dwBytesReturned, NULL); } /***************************************************************************** * ClearCommBreak (KERNEL32.@) * * Resumes character transmission from a communication device. * * PARAMS * * handle [in] The halted communication device whose character transmission is to be resumed * * RETURNS * * True on success and false if the communications device could not be found. * * BUGS * * Only TIOCSBRK and TIOCCBRK are supported. */ BOOL WINAPI ClearCommBreak(HANDLE handle) { DWORD dwBytesReturned; return DeviceIoControl(handle, IOCTL_SERIAL_SET_BREAK_OFF, NULL, 0, NULL, 0, &dwBytesReturned, NULL); } /***************************************************************************** * EscapeCommFunction (KERNEL32.@) * * Directs a communication device to perform an extended function. * * PARAMS * * handle [in] The communication device to perform the extended function * nFunction [in] The extended function to be performed * * RETURNS * * True or requested data on successful completion of the command, * false if the device is not present cannot execute the command * or the command failed. */ BOOL WINAPI EscapeCommFunction(HANDLE handle, UINT func) { DWORD ioc; DWORD dwBytesReturned; switch (func) { case CLRDTR: ioc = IOCTL_SERIAL_CLR_DTR; break; case CLRRTS: ioc = IOCTL_SERIAL_CLR_RTS; break; case SETDTR: ioc = IOCTL_SERIAL_SET_DTR; break; case SETRTS: ioc = IOCTL_SERIAL_SET_RTS; break; case SETXOFF: ioc = IOCTL_SERIAL_SET_XOFF; break; case SETXON: ioc = IOCTL_SERIAL_SET_XON; break; case SETBREAK: ioc = IOCTL_SERIAL_SET_BREAK_ON; break; case CLRBREAK: ioc = IOCTL_SERIAL_SET_BREAK_OFF; break; case RESETDEV: ioc = IOCTL_SERIAL_RESET_DEVICE; break; default: ERR("Unknown function code (%u)\n", func); SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } return DeviceIoControl(handle, ioc, NULL, 0, NULL, 0, &dwBytesReturned, NULL); } /******************************************************************** * PurgeComm (KERNEL32.@) * * Terminates pending operations and/or discards buffers on a * communication resource. * * PARAMS * * handle [in] The communication resource to be purged * flags [in] Flags for clear pending/buffer on input/output * * RETURNS * * True on success and false if the communications handle is bad. */ BOOL WINAPI PurgeComm(HANDLE handle, DWORD flags) { DWORD dwBytesReturned; return DeviceIoControl(handle, IOCTL_SERIAL_PURGE, &flags, sizeof(flags), NULL, 0, &dwBytesReturned, NULL); } /***************************************************************************** * ClearCommError (KERNEL32.@) * * Enables further I/O operations on a communications resource after * supplying error and current status information. * * PARAMS * * handle [in] The communication resource with the error * errors [out] Flags indicating error the resource experienced * lpStat [out] The status of the communication resource * RETURNS * * True on success, false if the communication resource handle is bad. */ BOOL WINAPI ClearCommError(HANDLE handle, LPDWORD errors, LPCOMSTAT lpStat) { SERIAL_STATUS ss; DWORD dwBytesReturned; if (!DeviceIoControl(handle, IOCTL_SERIAL_GET_COMMSTATUS, NULL, 0, &ss, sizeof(ss), &dwBytesReturned, NULL)) return FALSE; if (errors) { *errors = 0; if (ss.Errors & SERIAL_ERROR_BREAK) *errors |= CE_BREAK; if (ss.Errors & SERIAL_ERROR_FRAMING) *errors |= CE_FRAME; if (ss.Errors & SERIAL_ERROR_OVERRUN) *errors |= CE_OVERRUN; if (ss.Errors & SERIAL_ERROR_QUEUEOVERRUN) *errors |= CE_RXOVER; if (ss.Errors & SERIAL_ERROR_PARITY) *errors |= CE_RXPARITY; } if (lpStat) { memset(lpStat, 0, sizeof(*lpStat)); if (ss.HoldReasons & SERIAL_TX_WAITING_FOR_CTS) lpStat->fCtsHold = TRUE; if (ss.HoldReasons & SERIAL_TX_WAITING_FOR_DSR) lpStat->fDsrHold = TRUE; if (ss.HoldReasons & SERIAL_TX_WAITING_FOR_DCD) lpStat->fRlsdHold = TRUE; if (ss.HoldReasons & SERIAL_TX_WAITING_FOR_XON) lpStat->fXoffHold = TRUE; if (ss.HoldReasons & SERIAL_TX_WAITING_XOFF_SENT) lpStat->fXoffSent = TRUE; if (ss.EofReceived) lpStat->fEof = TRUE; if (ss.WaitForImmediate) lpStat->fTxim = TRUE; lpStat->cbInQue = ss.AmountInInQueue; lpStat->cbOutQue = ss.AmountInOutQueue; } return TRUE; } /***************************************************************************** * SetupComm (KERNEL32.@) * * Called after CreateFile to hint to the communication resource to use * specified sizes for input and output buffers rather than the default values. * * PARAMS * handle [in] The just created communication resource handle * insize [in] The suggested size of the communication resources input buffer in bytes * outsize [in] The suggested size of the communication resources output buffer in bytes * * RETURNS * * True if successful, false if the communications resource handle is bad. * * BUGS * * Stub. */ BOOL WINAPI SetupComm(HANDLE handle, DWORD insize, DWORD outsize) { SERIAL_QUEUE_SIZE sqs; DWORD dwBytesReturned; sqs.InSize = insize; sqs.OutSize = outsize; return DeviceIoControl(handle, IOCTL_SERIAL_SET_QUEUE_SIZE, &sqs, sizeof(sqs), NULL, 0, &dwBytesReturned, NULL); } /***************************************************************************** * GetCommMask (KERNEL32.@) * * Obtain the events associated with a communication device that will cause * a call WaitCommEvent to return. * * PARAMS * * handle [in] The communications device * evtmask [out] The events which cause WaitCommEvent to return * * RETURNS * * True on success, fail on bad device handle etc. */ BOOL WINAPI GetCommMask(HANDLE handle, LPDWORD evtmask) { DWORD dwBytesReturned; TRACE("handle %p, mask %p\n", handle, evtmask); return DeviceIoControl(handle, IOCTL_SERIAL_GET_WAIT_MASK, NULL, 0, evtmask, sizeof(*evtmask), &dwBytesReturned, NULL); } /***************************************************************************** * SetCommMask (KERNEL32.@) * * There be some things we need to hear about yon there communications device. * (Set which events associated with a communication device should cause * a call WaitCommEvent to return.) * * PARAMS * * handle [in] The communications device * evtmask [in] The events that are to be monitored * * RETURNS * * True on success, false on bad handle etc. */ BOOL WINAPI SetCommMask(HANDLE handle, DWORD evtmask) { DWORD dwBytesReturned; TRACE("handle %p, mask %x\n", handle, evtmask); return DeviceIoControl(handle, IOCTL_SERIAL_SET_WAIT_MASK, &evtmask, sizeof(evtmask), NULL, 0, &dwBytesReturned, NULL); } static void dump_dcb(const DCB* lpdcb) { TRACE("bytesize=%d baudrate=%d fParity=%d Parity=%d stopbits=%d\n", lpdcb->ByteSize, lpdcb->BaudRate, lpdcb->fParity, lpdcb->Parity, (lpdcb->StopBits == ONESTOPBIT) ? 1 : (lpdcb->StopBits == TWOSTOPBITS) ? 2 : 0); TRACE("%sIXON %sIXOFF\n", (lpdcb->fInX) ? "" : "~", (lpdcb->fOutX) ? "" : "~"); TRACE("fOutxCtsFlow=%d fRtsControl=%d\n", lpdcb->fOutxCtsFlow, lpdcb->fRtsControl); TRACE("fOutxDsrFlow=%d fDtrControl=%d\n", lpdcb->fOutxDsrFlow, lpdcb->fDtrControl); if (lpdcb->fOutxCtsFlow || lpdcb->fRtsControl == RTS_CONTROL_HANDSHAKE) TRACE("CRTSCTS\n"); else TRACE("~CRTSCTS\n"); } /***************************************************************************** * SetCommState (KERNEL32.@) * * Re-initializes all hardware and control settings of a communications device, * with values from a device control block without affecting the input and output * queues. * * PARAMS * * handle [in] The communications device * lpdcb [out] The device control block * * RETURNS * * True on success, false on failure, e.g., if the XonChar is equal to the XoffChar. */ BOOL WINAPI SetCommState( HANDLE handle, LPDCB lpdcb) { SERIAL_BAUD_RATE sbr; SERIAL_LINE_CONTROL slc; SERIAL_HANDFLOW shf; SERIAL_CHARS sc; DWORD dwBytesReturned; if (lpdcb == NULL) { SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } dump_dcb(lpdcb); sbr.BaudRate = lpdcb->BaudRate; slc.StopBits = lpdcb->StopBits; slc.Parity = lpdcb->Parity; slc.WordLength = lpdcb->ByteSize; shf.ControlHandShake = 0; shf.FlowReplace = 0; if (lpdcb->fOutxCtsFlow) shf.ControlHandShake |= SERIAL_CTS_HANDSHAKE; if (lpdcb->fOutxDsrFlow) shf.ControlHandShake |= SERIAL_DSR_HANDSHAKE; switch (lpdcb->fDtrControl) { case DTR_CONTROL_DISABLE: break; case DTR_CONTROL_ENABLE: shf.ControlHandShake |= SERIAL_DTR_CONTROL; break; case DTR_CONTROL_HANDSHAKE: shf.ControlHandShake |= SERIAL_DTR_HANDSHAKE;break; default: SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } switch (lpdcb->fRtsControl) { case RTS_CONTROL_DISABLE: break; case RTS_CONTROL_ENABLE: shf.FlowReplace |= SERIAL_RTS_CONTROL; break; case RTS_CONTROL_HANDSHAKE: shf.FlowReplace |= SERIAL_RTS_HANDSHAKE; break; case RTS_CONTROL_TOGGLE: shf.FlowReplace |= SERIAL_RTS_CONTROL | SERIAL_RTS_HANDSHAKE; break; default: SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } if (lpdcb->fDsrSensitivity) shf.ControlHandShake |= SERIAL_DSR_SENSITIVITY; if (lpdcb->fAbortOnError) shf.ControlHandShake |= SERIAL_ERROR_ABORT; if (lpdcb->fErrorChar) shf.FlowReplace |= SERIAL_ERROR_CHAR; if (lpdcb->fNull) shf.FlowReplace |= SERIAL_NULL_STRIPPING; if (lpdcb->fTXContinueOnXoff) shf.FlowReplace |= SERIAL_XOFF_CONTINUE; if (lpdcb->fOutX) shf.FlowReplace |= SERIAL_AUTO_TRANSMIT; if (lpdcb->fInX) shf.FlowReplace |= SERIAL_AUTO_RECEIVE; shf.XonLimit = lpdcb->XonLim; shf.XoffLimit = lpdcb->XoffLim; sc.EofChar = lpdcb->EofChar; sc.ErrorChar = lpdcb->ErrorChar; sc.BreakChar = 0; sc.EventChar = lpdcb->EvtChar; sc.XonChar = lpdcb->XonChar; sc.XoffChar = lpdcb->XoffChar; /* note: change DTR/RTS lines after setting the comm attributes, * so flow control does not interfere. */ return (DeviceIoControl(handle, IOCTL_SERIAL_SET_BAUD_RATE, &sbr, sizeof(sbr), NULL, 0, &dwBytesReturned, NULL) && DeviceIoControl(handle, IOCTL_SERIAL_SET_LINE_CONTROL, &slc, sizeof(slc), NULL, 0, &dwBytesReturned, NULL) && DeviceIoControl(handle, IOCTL_SERIAL_SET_HANDFLOW, &shf, sizeof(shf), NULL, 0, &dwBytesReturned, NULL) && DeviceIoControl(handle, IOCTL_SERIAL_SET_CHARS, &sc, sizeof(sc), NULL, 0, &dwBytesReturned, NULL)); } /***************************************************************************** * GetCommState (KERNEL32.@) * * Fills in a device control block with information from a communications device. * * PARAMS * handle [in] The communications device * lpdcb [out] The device control block * * RETURNS * * True on success, false if the communication device handle is bad etc * * BUGS * * XonChar and XoffChar are not set. */ BOOL WINAPI GetCommState(HANDLE handle, LPDCB lpdcb) { SERIAL_BAUD_RATE sbr; SERIAL_LINE_CONTROL slc; SERIAL_HANDFLOW shf; SERIAL_CHARS sc; DWORD dwBytesReturned; TRACE("handle %p, ptr %p\n", handle, lpdcb); if (!lpdcb) { SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } if (!DeviceIoControl(handle, IOCTL_SERIAL_GET_BAUD_RATE, NULL, 0, &sbr, sizeof(sbr), &dwBytesReturned, NULL) || !DeviceIoControl(handle, IOCTL_SERIAL_GET_LINE_CONTROL, NULL, 0, &slc, sizeof(slc), &dwBytesReturned, NULL) || !DeviceIoControl(handle, IOCTL_SERIAL_GET_HANDFLOW, NULL, 0, &shf, sizeof(shf), &dwBytesReturned, NULL) || !DeviceIoControl(handle, IOCTL_SERIAL_GET_CHARS, NULL, 0, &sc, sizeof(sc), &dwBytesReturned, NULL)) return FALSE; memset(lpdcb, 0, sizeof(*lpdcb)); lpdcb->DCBlength = sizeof(*lpdcb); /* yes, they seem no never be (re)set on NT */ lpdcb->fBinary = 1; lpdcb->fParity = 0; lpdcb->BaudRate = sbr.BaudRate; lpdcb->StopBits = slc.StopBits; lpdcb->Parity = slc.Parity; lpdcb->ByteSize = slc.WordLength; if (shf.ControlHandShake & SERIAL_CTS_HANDSHAKE) lpdcb->fOutxCtsFlow = 1; if (shf.ControlHandShake & SERIAL_DSR_HANDSHAKE) lpdcb->fOutxDsrFlow = 1; switch (shf.ControlHandShake & (SERIAL_DTR_CONTROL | SERIAL_DTR_HANDSHAKE)) { case 0: lpdcb->fDtrControl = DTR_CONTROL_DISABLE; break; case SERIAL_DTR_CONTROL: lpdcb->fDtrControl = DTR_CONTROL_ENABLE; break; case SERIAL_DTR_HANDSHAKE: lpdcb->fDtrControl = DTR_CONTROL_HANDSHAKE; break; } switch (shf.FlowReplace & (SERIAL_RTS_CONTROL | SERIAL_RTS_HANDSHAKE)) { case 0: lpdcb->fRtsControl = RTS_CONTROL_DISABLE; break; case SERIAL_RTS_CONTROL: lpdcb->fRtsControl = RTS_CONTROL_ENABLE; break; case SERIAL_RTS_HANDSHAKE: lpdcb->fRtsControl = RTS_CONTROL_HANDSHAKE; break; case SERIAL_RTS_CONTROL | SERIAL_RTS_HANDSHAKE: lpdcb->fRtsControl = RTS_CONTROL_TOGGLE; break; } if (shf.ControlHandShake & SERIAL_DSR_SENSITIVITY) lpdcb->fDsrSensitivity = 1; if (shf.ControlHandShake & SERIAL_ERROR_ABORT) lpdcb->fAbortOnError = 1; if (shf.FlowReplace & SERIAL_ERROR_CHAR) lpdcb->fErrorChar = 1; if (shf.FlowReplace & SERIAL_NULL_STRIPPING) lpdcb->fNull = 1; if (shf.FlowReplace & SERIAL_XOFF_CONTINUE) lpdcb->fTXContinueOnXoff = 1; lpdcb->XonLim = shf.XonLimit; lpdcb->XoffLim = shf.XoffLimit; if (shf.FlowReplace & SERIAL_AUTO_TRANSMIT) lpdcb->fOutX = 1; if (shf.FlowReplace & SERIAL_AUTO_RECEIVE) lpdcb->fInX = 1; lpdcb->EofChar = sc.EofChar; lpdcb->ErrorChar = sc.ErrorChar; lpdcb->EvtChar = sc.EventChar; lpdcb->XonChar = sc.XonChar; lpdcb->XoffChar = sc.XoffChar; TRACE("OK\n"); dump_dcb(lpdcb); return TRUE; } /***************************************************************************** * TransmitCommChar (KERNEL32.@) * * Transmits a single character in front of any pending characters in the * output buffer. Usually used to send an interrupt character to a host. * * PARAMS * hComm [in] The communication device in need of a command character * chTransmit [in] The character to transmit * * RETURNS * * True if the call succeeded, false if the previous command character to the * same device has not been sent yet the handle is bad etc. * */ BOOL WINAPI TransmitCommChar(HANDLE hComm, CHAR chTransmit) { DWORD dwBytesReturned; return DeviceIoControl(hComm, IOCTL_SERIAL_IMMEDIATE_CHAR, &chTransmit, sizeof(chTransmit), NULL, 0, &dwBytesReturned, NULL); } /***************************************************************************** * GetCommTimeouts (KERNEL32.@) * * Obtains the request timeout values for the communications device. * * PARAMS * hComm [in] The communications device * lptimeouts [out] The struct of request timeouts * * RETURNS * * True on success, false if communications device handle is bad * or the target structure is null. */ BOOL WINAPI GetCommTimeouts(HANDLE hComm, LPCOMMTIMEOUTS lptimeouts) { SERIAL_TIMEOUTS st; DWORD dwBytesReturned; TRACE("(%p, %p)\n", hComm, lptimeouts); if (!lptimeouts) { SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } if (!DeviceIoControl(hComm, IOCTL_SERIAL_GET_TIMEOUTS, NULL, 0, &st, sizeof(st), &dwBytesReturned, NULL)) return FALSE; lptimeouts->ReadIntervalTimeout = st.ReadIntervalTimeout; lptimeouts->ReadTotalTimeoutMultiplier = st.ReadTotalTimeoutMultiplier; lptimeouts->ReadTotalTimeoutConstant = st.ReadTotalTimeoutConstant; lptimeouts->WriteTotalTimeoutMultiplier = st.WriteTotalTimeoutMultiplier; lptimeouts->WriteTotalTimeoutConstant = st.WriteTotalTimeoutConstant; return TRUE; } /***************************************************************************** * SetCommTimeouts (KERNEL32.@) * * Sets the timeouts used when reading and writing data to/from COMM ports. * * PARAMS * hComm [in] handle of COMM device * lptimeouts [in] pointer to COMMTIMEOUTS structure * * ReadIntervalTimeout * - converted and passes to linux kernel as c_cc[VTIME] * ReadTotalTimeoutMultiplier, ReadTotalTimeoutConstant * - used in ReadFile to calculate GetOverlappedResult's timeout * WriteTotalTimeoutMultiplier, WriteTotalTimeoutConstant * - used in WriteFile to calculate GetOverlappedResult's timeout * * RETURNS * * True if the timeouts were set, false otherwise. */ BOOL WINAPI SetCommTimeouts(HANDLE hComm, LPCOMMTIMEOUTS lptimeouts) { SERIAL_TIMEOUTS st; DWORD dwBytesReturned; TRACE("(%p, %p)\n", hComm, lptimeouts); if (lptimeouts == NULL) { SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } st.ReadIntervalTimeout = lptimeouts->ReadIntervalTimeout; st.ReadTotalTimeoutMultiplier = lptimeouts->ReadTotalTimeoutMultiplier; st.ReadTotalTimeoutConstant = lptimeouts->ReadTotalTimeoutConstant; st.WriteTotalTimeoutMultiplier = lptimeouts->WriteTotalTimeoutMultiplier; st.WriteTotalTimeoutConstant = lptimeouts->WriteTotalTimeoutConstant; return DeviceIoControl(hComm, IOCTL_SERIAL_SET_TIMEOUTS, &st, sizeof(st), NULL, 0, &dwBytesReturned, NULL); } /*********************************************************************** * GetCommModemStatus (KERNEL32.@) * * Obtains the four control register bits if supported by the hardware. * * PARAMS * * hFile [in] The communications device * lpModemStat [out] The control register bits * * RETURNS * * True if the communications handle was good and for hardware that * control register access, false otherwise. */ BOOL WINAPI GetCommModemStatus(HANDLE hFile, LPDWORD lpModemStat) { DWORD dwBytesReturned; return DeviceIoControl(hFile, IOCTL_SERIAL_GET_MODEMSTATUS, NULL, 0, lpModemStat, sizeof(DWORD), &dwBytesReturned, NULL); } /*********************************************************************** * WaitCommEvent (KERNEL32.@) * * Wait until something interesting happens on a COMM port. * Interesting things (events) are set by calling SetCommMask before * this function is called. * * RETURNS * TRUE if successful * FALSE if failure * * The set of detected events will be written to *lpdwEventMask * ERROR_IO_PENDING will be returned the overlapped structure was passed * * BUGS: * Only supports EV_RXCHAR and EV_TXEMPTY */ BOOL WINAPI WaitCommEvent( HANDLE hFile, /* [in] handle of comm port to wait for */ LPDWORD lpdwEvents, /* [out] event(s) that were detected */ LPOVERLAPPED lpOverlapped) /* [in/out] for Asynchronous waiting */ { return DeviceIoControl(hFile, IOCTL_SERIAL_WAIT_ON_MASK, NULL, 0, lpdwEvents, sizeof(DWORD), NULL, lpOverlapped); } /*********************************************************************** * GetCommProperties (KERNEL32.@) * * This function fills in a structure with the capabilities of the * communications port driver. * * RETURNS * * TRUE on success, FALSE on failure * If successful, the lpCommProp structure be filled in with * properties of the comm port. */ BOOL WINAPI GetCommProperties( HANDLE hFile, /* [in] handle of the comm port */ LPCOMMPROP lpCommProp) /* [out] pointer to struct to be filled */ { FIXME("(%p %p )\n",hFile,lpCommProp); if(!lpCommProp) return FALSE; /* * These values should be valid for LINUX's serial driver * FIXME: Perhaps they deserve an #ifdef LINUX */ memset(lpCommProp,0,sizeof(COMMPROP)); lpCommProp->wPacketLength = 1; lpCommProp->wPacketVersion = 1; lpCommProp->dwServiceMask = SP_SERIALCOMM; lpCommProp->dwReserved1 = 0; lpCommProp->dwMaxTxQueue = 4096; lpCommProp->dwMaxRxQueue = 4096; lpCommProp->dwMaxBaud = BAUD_115200; lpCommProp->dwProvSubType = PST_RS232; lpCommProp->dwProvCapabilities = PCF_DTRDSR | PCF_PARITY_CHECK | PCF_RTSCTS | PCF_TOTALTIMEOUTS; lpCommProp->dwSettableParams = SP_BAUD | SP_DATABITS | SP_HANDSHAKING | SP_PARITY | SP_PARITY_CHECK | SP_STOPBITS ; lpCommProp->dwSettableBaud = BAUD_075 | BAUD_110 | BAUD_134_5 | BAUD_150 | BAUD_300 | BAUD_600 | BAUD_1200 | BAUD_1800 | BAUD_2400 | BAUD_4800 | BAUD_9600 | BAUD_19200 | BAUD_38400 | BAUD_57600 | BAUD_115200 ; lpCommProp->wSettableData = DATABITS_5 | DATABITS_6 | DATABITS_7 | DATABITS_8 ; lpCommProp->wSettableStopParity = STOPBITS_10 | STOPBITS_15 | STOPBITS_20 | PARITY_NONE | PARITY_ODD |PARITY_EVEN | PARITY_MARK | PARITY_SPACE; lpCommProp->dwCurrentTxQueue = lpCommProp->dwMaxTxQueue; lpCommProp->dwCurrentRxQueue = lpCommProp->dwMaxRxQueue; return TRUE; } /*********************************************************************** * FIXME: * The functionality of CommConfigDialogA, GetDefaultCommConfig and * SetDefaultCommConfig is implemented in a DLL (usually SERIALUI.DLL). * This is dependent on the type of COMM port, but since it is doubtful * anybody will get around to implementing support for fancy serial * ports in WINE, this is hardcoded for the time being. The name of * this DLL should be stored in and read from the system registry in * the hive HKEY_LOCAL_MACHINE, key * System\\CurrentControlSet\\Services\\Class\\Ports\\???? * where ???? is the port number... that is determined by PNP * The DLL should be loaded when the COMM port is opened, and closed * when the COMM port is closed. - MJM 20 June 2000 ***********************************************************************/ static const WCHAR lpszSerialUI[] = { 's','e','r','i','a','l','u','i','.','d','l','l',0 }; /*********************************************************************** * CommConfigDialogA (KERNEL32.@) * * Raises a dialog that allows the user to configure a comm port. * Fills the COMMCONFIG struct with information specified by the user. * This function should call a similar routine in the COMM driver... * * RETURNS * * TRUE on success, FALSE on failure * If successful, the lpCommConfig structure will contain a new * configuration for the comm port, as specified by the user. * * BUGS * The library with the CommConfigDialog code is never unloaded. * Perhaps this should be done when the comm port is closed? */ BOOL WINAPI CommConfigDialogA( LPCSTR lpszDevice, /* [in] name of communications device */ HWND hWnd, /* [in] parent window for the dialog */ LPCOMMCONFIG lpCommConfig) /* [out] pointer to struct to fill */ { LPWSTR lpDeviceW = NULL; DWORD len; BOOL r; TRACE("(%s, %p, %p)\n", debugstr_a(lpszDevice), hWnd, lpCommConfig); if (lpszDevice) { len = MultiByteToWideChar( CP_ACP, 0, lpszDevice, -1, NULL, 0 ); lpDeviceW = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ); MultiByteToWideChar( CP_ACP, 0, lpszDevice, -1, lpDeviceW, len ); } r = CommConfigDialogW(lpDeviceW, hWnd, lpCommConfig); HeapFree( GetProcessHeap(), 0, lpDeviceW ); return r; } /*********************************************************************** * CommConfigDialogW (KERNEL32.@) * * See CommConfigDialogA. */ BOOL WINAPI CommConfigDialogW( LPCWSTR lpszDevice, /* [in] name of communications device */ HWND hWnd, /* [in] parent window for the dialog */ LPCOMMCONFIG lpCommConfig) /* [out] pointer to struct to fill */ { FARPROC pCommConfigDialog; HMODULE hConfigModule; DWORD res = ERROR_INVALID_PARAMETER; TRACE("(%s, %p, %p)\n", debugstr_w(lpszDevice), hWnd, lpCommConfig); hConfigModule = LoadLibraryW(lpszSerialUI); if (hConfigModule) { pCommConfigDialog = GetProcAddress(hConfigModule, "drvCommConfigDialogW"); if (pCommConfigDialog) { res = pCommConfigDialog(lpszDevice, hWnd, lpCommConfig); } FreeLibrary(hConfigModule); } if (res) SetLastError(res); return (res == ERROR_SUCCESS); } /*********************************************************************** * GetCommConfig (KERNEL32.@) * * Fill in the COMMCONFIG structure for the comm port hFile * * RETURNS * * TRUE on success, FALSE on failure * If successful, lpCommConfig contains the comm port configuration. * * BUGS * */ BOOL WINAPI GetCommConfig( HANDLE hFile, /* [in] The communications device. */ LPCOMMCONFIG lpCommConfig, /* [out] The communications configuration of the device (if it fits). */ LPDWORD lpdwSize) /* [in/out] Initially the size of the configuration buffer/structure, afterwards the number of bytes copied to the buffer or the needed size of the buffer. */ { BOOL r; TRACE("(%p, %p, %p) *lpdwSize: %u\n", hFile, lpCommConfig, lpdwSize, lpdwSize ? *lpdwSize : 0 ); if(lpCommConfig == NULL) return FALSE; r = *lpdwSize < sizeof(COMMCONFIG); /* TRUE if not enough space */ *lpdwSize = sizeof(COMMCONFIG); if(r) return FALSE; lpCommConfig->dwSize = sizeof(COMMCONFIG); lpCommConfig->wVersion = 1; lpCommConfig->wReserved = 0; r = GetCommState(hFile,&lpCommConfig->dcb); lpCommConfig->dwProviderSubType = PST_RS232; lpCommConfig->dwProviderOffset = 0; lpCommConfig->dwProviderSize = 0; return r; } /*********************************************************************** * SetCommConfig (KERNEL32.@) * * Sets the configuration of the communications device. * * RETURNS * * True on success, false if the handle was bad is not a communications device. */ BOOL WINAPI SetCommConfig( HANDLE hFile, /* [in] The communications device. */ LPCOMMCONFIG lpCommConfig, /* [in] The desired configuration. */ DWORD dwSize) /* [in] size of the lpCommConfig struct */ { TRACE("(%p, %p, %u)\n", hFile, lpCommConfig, dwSize); return SetCommState(hFile,&lpCommConfig->dcb); } /*********************************************************************** * SetDefaultCommConfigW (KERNEL32.@) * * Initializes the default configuration for a communication device. * * PARAMS * lpszDevice [I] Name of the device targeted for configuration * lpCommConfig [I] PTR to a buffer with the configuration for the device * dwSize [I] Number of bytes in the buffer * * RETURNS * Failure: FALSE * Success: TRUE, and default configuration saved * */ BOOL WINAPI SetDefaultCommConfigW(LPCWSTR lpszDevice, LPCOMMCONFIG lpCommConfig, DWORD dwSize) { FARPROC lpfnSetDefaultCommConfig; HMODULE hConfigModule; BOOL r = FALSE; TRACE("(%s, %p, %u)\n", debugstr_w(lpszDevice), lpCommConfig, dwSize); hConfigModule = LoadLibraryW(lpszSerialUI); if(!hConfigModule) return r; lpfnSetDefaultCommConfig = GetProcAddress(hConfigModule, "drvSetDefaultCommConfigW"); if (lpfnSetDefaultCommConfig) r = lpfnSetDefaultCommConfig(lpszDevice, lpCommConfig, dwSize); FreeLibrary(hConfigModule); return r; } /*********************************************************************** * SetDefaultCommConfigA (KERNEL32.@) * * Initializes the default configuration for a communication device. * * See SetDefaultCommConfigW. * */ BOOL WINAPI SetDefaultCommConfigA(LPCSTR lpszDevice, LPCOMMCONFIG lpCommConfig, DWORD dwSize) { BOOL r; LPWSTR lpDeviceW = NULL; DWORD len; TRACE("(%s, %p, %u)\n", debugstr_a(lpszDevice), lpCommConfig, dwSize); if (lpszDevice) { len = MultiByteToWideChar( CP_ACP, 0, lpszDevice, -1, NULL, 0 ); lpDeviceW = HeapAlloc( GetProcessHeap(), 0, len*sizeof(WCHAR) ); MultiByteToWideChar( CP_ACP, 0, lpszDevice, -1, lpDeviceW, len ); } r = SetDefaultCommConfigW(lpDeviceW,lpCommConfig,dwSize); HeapFree( GetProcessHeap(), 0, lpDeviceW ); return r; } /*********************************************************************** * GetDefaultCommConfigW (KERNEL32.@) * * Acquires the default configuration of the specified communication device. (unicode) * * RETURNS * * True on successful reading of the default configuration, * if the device is not found or the buffer is too small. */ BOOL WINAPI GetDefaultCommConfigW( LPCWSTR lpszName, /* [in] The unicode name of the device targeted for configuration. */ LPCOMMCONFIG lpCC, /* [out] The default configuration for the device. */ LPDWORD lpdwSize) /* [in/out] Initially the size of the default configuration buffer, afterwards the number of bytes copied to the buffer or the needed size of the buffer. */ { FARPROC pGetDefaultCommConfig; HMODULE hConfigModule; DWORD res = ERROR_INVALID_PARAMETER; TRACE("(%s, %p, %p) *lpdwSize: %u\n", debugstr_w(lpszName), lpCC, lpdwSize, lpdwSize ? *lpdwSize : 0 ); hConfigModule = LoadLibraryW(lpszSerialUI); if (hConfigModule) { pGetDefaultCommConfig = GetProcAddress(hConfigModule, "drvGetDefaultCommConfigW"); if (pGetDefaultCommConfig) { res = pGetDefaultCommConfig(lpszName, lpCC, lpdwSize); } FreeLibrary(hConfigModule); } if (res) SetLastError(res); return (res == ERROR_SUCCESS); } /************************************************************************** * GetDefaultCommConfigA (KERNEL32.@) * * Acquires the default configuration of the specified communication device. (ascii) * * RETURNS * * True on successful reading of the default configuration, * if the device is not found or the buffer is too small. */ BOOL WINAPI GetDefaultCommConfigA( LPCSTR lpszName, /* [in] The ascii name of the device targeted for configuration. */ LPCOMMCONFIG lpCC, /* [out] The default configuration for the device. */ LPDWORD lpdwSize) /* [in/out] Initially the size of the default configuration buffer, afterwards the number of bytes copied to the buffer or the needed size of the buffer. */ { BOOL ret = FALSE; UNICODE_STRING lpszNameW; TRACE("(%s, %p, %p) *lpdwSize: %u\n", debugstr_a(lpszName), lpCC, lpdwSize, lpdwSize ? *lpdwSize : 0 ); if(lpszName) RtlCreateUnicodeStringFromAsciiz(&lpszNameW,lpszName); else lpszNameW.Buffer = NULL; ret = GetDefaultCommConfigW(lpszNameW.Buffer,lpCC,lpdwSize); RtlFreeUnicodeString(&lpszNameW); return ret; } Generated by  Doxygen 1.6.0   Back to index
{ "url": "http://wine-unstable.sourcearchive.com/documentation/1.1.29-1/comm_8c-source.html", "source_domain": "wine-unstable.sourcearchive.com", "snapshot_id": "crawl=CC-MAIN-2018-05", "warc_metadata": { "Content-Length": "87709", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:BZPGOPBNGUNDYWNZ3NPBSQTAK7PTKPAQ", "WARC-Concurrent-To": "<urn:uuid:caf3f63f-480c-4315-8766-162b90cf82ae>", "WARC-Date": "2018-01-19T05:47:52Z", "WARC-IP-Address": "5.9.86.18", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:CC763PBY7ZYM3SJOD4O5VWFUG35W6BKH", "WARC-Record-ID": "<urn:uuid:28145388-73bc-4623-a88c-e5708387d57a>", "WARC-Target-URI": "http://wine-unstable.sourcearchive.com/documentation/1.1.29-1/comm_8c-source.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:a20d0a22-35a8-4dda-a319-cb7d13c4c508>" }, "warc_info": "robots: classic\r\nhostname: ip-10-47-186-155.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-05\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for January 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 33, 99, 100, 107, 108, 111, 147, 150, 184, 187, 252, 314, 378, 448, 451, 518, 584, 653, 704, 707, 775, 846, 923, 927, 928, 948, 971, 972, 992, 1012, 1031, 1032, 1056, 1081, 1101, 1122, 1144, 1166, 1191, 1192, 1217, 1243, 1244, 1268, 1269, 1303, 1304, 1377, 1415, 1418, 1487, 1563, 1567, 1611, 1613, 1664, 1665, 1742, 1785, 1820, 1828, 1850, 1851, 1924, 1991, 2032, 2063, 2076, 2127, 2180, 2193, 2264, 2307, 2338, 2339, 2404, 2442, 2470, 2484, 2509, 2553, 2567, 2575, 2642, 2669, 2694, 2701, 2719, 2721, 2723, 2786, 2788, 2836, 2879, 2926, 2944, 2946, 2947, 3009, 3011, 3084, 3160, 3194, 3195, 3226, 3234, 3250, 3286, 3305, 3321, 3357, 3376, 3392, 3426, 3445, 3461, 3496, 3515, 3531, 3568, 3587, 3602, 3627, 3635, 3636, 3654, 3656, 3657, 3723, 3725, 3743, 3744, 3792, 3817, 3818, 3851, 3859, 3891, 3915, 3923, 3934, 3959, 3961, 3962, 4028, 4030, 4048, 4106, 4107, 4148, 4156, 4178, 4218, 4226, 4237, 4245, 4299, 4330, 4331, 4357, 4401, 4432, 4477, 4494, 4525, 4533, 4540, 4558, 4560, 4561, 4622, 4624, 4670, 4721, 4722, 4756, 4764, 4786, 4812, 4820, 4860, 4868, 4890, 4916, 4924, 4935, 4960, 4961, 4979, 4981, 4982, 5055, 5102, 5105, 5172, 5176, 5238, 5240, 5262, 5263, 5328, 5354, 5361, 5391, 5399, 5414, 5429, 5444, 5479, 5498, 5513, 5528, 5543, 5558, 5594, 5613, 5628, 5665, 5684, 5692, 5693, 5731, 5772, 5810, 5811, 5874, 5900, 5901, 5939, 5980, 6018, 6031, 6098, 6124, 6125, 6163, 6204, 6242, 6243, 6310, 6336, 6337, 6398, 6436, 6461, 6469, 6491, 6535, 6587, 6631, 6639, 6640, 6717, 6776, 6795, 6803, 6817, 6850, 6884, 6925, 6966, 7019, 7072, 7091, 7107, 7139, 7172, 7213, 7254, 7307, 7360, 7379, 7395, 7428, 7462, 7502, 7542, 7598, 7654, 7673, 7688, 7714, 7722, 7723, 7773, 7805, 7812, 7831, 7833, 7834, 7907, 7954, 7957, 8010, 8067, 8071, 8160, 8162, 8180, 8219, 8279, 8349, 8409, 8469, 8519, 8574, 8634, 8694, 8749, 8804, 8864, 8865, 8886, 8894, 8938, 8939, 8984, 8998, 9029, 9048, 9129, 9167, 9181, 9233, 9247, 9326, 9364, 9378, 9428, 9442, 9525, 9563, 9577, 9627, 9641, 9672, 9691, 9774, 9812, 9826, 9874, 9888, 9957, 9995, 9996, 10051, 10113, 10173, 10236, 10312, 10326, 10375, 10389, 10458, 10496, 10497, 10536, 10574, 10588, 10638, 10652, 10721, 10759, 10760, 10806, 10820, 10870, 10884, 10953, 10991, 10992, 11038, 11052, 11101, 11115, 11184, 11222, 11223, 11268, 11282, 11331, 11345, 11414, 11452, 11453, 11498, 11512, 11562, 11576, 11645, 11683, 11684, 11757, 11832, 11881, 11895, 11912, 11944, 11945, 12023, 12071, 12113, 12145, 12153, 12154, 12229, 12245, 12253, 12300, 12349, 12366, 12414, 12422, 12423, 12442, 12444, 12445, 12521, 12570, 12573, 12643, 12717, 12791, 12794, 12805, 12808, 12866, 12870, 12897, 12983, 13054, 13056, 13114, 13116, 13117, 13193, 13248, 13251, 13321, 13393, 13438, 13441, 13452, 13455, 13499, 13503, 13541, 13616, 13699, 13783, 13785, 13809, 13839, 13840, 13893, 13961, 13995, 13996, 14086, 14087, 14125, 14143, 14145, 14146, 14222, 14271, 14274, 14343, 14417, 14462, 14465, 14476, 14479, 14522, 14526, 14564, 14641, 14724, 14808, 14810, 14825, 14854, 14873, 14900, 14901, 14965, 14966, 15011, 15012, 15082, 15120, 15121, 15196, 15269, 15332, 15352, 15397, 15398, 15432, 15433, 15455, 15483, 15516, 15570, 15581, 15646, 15647, 15664, 15672, 15698, 15749, 15774, 15782, 15793, 15801, 15877, 15928, 15954, 15967, 15969, 15970, 16046, 16095, 16098, 16163, 16239, 16313, 16316, 16327, 16330, 16388, 16392, 16419, 16484, 16555, 16557, 16614, 16616, 16617, 16696, 16739, 16742, 16811, 16814, 16824, 16882, 16885, 16896, 16899, 16979, 17013, 17016, 17024, 17027, 17073, 17077, 17117, 17119, 17146, 17251, 17253, 17254, 17333, 17376, 17379, 17443, 17446, 17456, 17459, 17557, 17560, 17571, 17574, 17653, 17656, 17664, 17667, 17713, 17717, 17759, 17761, 17788, 17894, 17896, 17897, 17976, 18019, 18022, 18090, 18093, 18103, 18106, 18193, 18260, 18263, 18274, 18277, 18345, 18411, 18438, 18442, 18499, 18501, 18522, 18549, 18550, 18568, 18574, 18645, 18716, 18787, 18858, 18929, 19000, 19071, 19142, 19213, 19226, 19277, 19324, 19346, 19352, 19435, 19437, 19438, 19508, 19546, 19549, 19612, 19640, 19643, 19653, 19656, 19717, 19785, 19788, 19799, 19802, 19869, 19873, 19923, 19925, 19952, 20030, 20091, 20093, 20094, 20173, 20210, 20213, 20283, 20335, 20338, 20348, 20351, 20417, 20489, 20552, 20563, 20566, 20638, 20642, 20718, 20720, 20748, 20775, 20776, 20847, 20914, 20936, 20937, 20953, 20959, 20980, 21057, 21134, 21213, 21291, 21371, 21377, 21379, 21395, 21401, 21445, 21446, 21535, 21624, 21714, 21804, 21894, 21979, 22065, 22111, 22159, 22165, 22182, 22184, 22185, 22264, 22301, 22304, 22377, 22458, 22461, 22471, 22542, 22638, 22735, 22738, 22749, 22752, 22828, 22831, 22839, 22842, 22852, 22856, 22922, 22924, 22953, 22980, 22981, 23006, 23033, 23097, 23177, 23179, 23180, 23259, 23290, 23293, 23370, 23406, 23409, 23420, 23423, 23473, 23544, 23547, 23559, 23562, 23615, 23619, 23675, 23677, 23704, 23756, 23819, 23907, 23909, 23910, 23989, 24020, 24023, 24103, 24177, 24214, 24217, 24227, 24230, 24280, 24340, 24343, 24354, 24357, 24403, 24407, 24461, 24463, 24490, 24542, 24605, 24693, 24695, 24696, 24735, 24737, 24809, 24884, 24932, 24985, 25069, 25157, 25245, 25321, 25349, 25358, 25387, 25389, 25390, 25469, 25504, 25507, 25588, 25671, 25683, 25686, 25696, 25699, 25749, 25798, 25801, 25812, 25815, 25901, 25905, 25959, 25961, 25997, 26033, 26069, 26104, 26131, 26132, 26155, 26161, 26208, 26230, 26236, 26257, 26258, 26294, 26308, 26344, 26376, 26414, 26415, 26445, 26470, 26550, 26630, 26662, 26668, 26754, 26840, 26926, 26939, 26986, 27008, 27014, 27046, 27052, 27138, 27224, 27310, 27385, 27471, 27484, 27531, 27553, 27559, 27641, 27719, 27720, 27792, 27868, 27943, 28018, 28092, 28093, 28127, 28163, 28164, 28197, 28234, 28256, 28291, 28324, 28359, 28360, 28429, 28472, 28480, 28544, 28627, 28694, 28777, 28840, 28923, 28983, 29063, 29065, 29066, 29067, 29146, 29183, 29186, 29269, 29272, 29282, 29340, 29397, 29400, 29411, 29414, 29487, 29490, 29498, 29501, 29539, 29543, 29596, 29598, 29627, 29656, 29685, 29713, 29740, 29741, 29790, 29791, 29807, 29813, 29860, 29882, 29888, 29893, 29954, 30034, 30098, 30178, 30238, 30318, 30375, 30451, 30473, 30474, 30512, 30551, 30552, 30603, 30627, 30651, 30652, 30688, 30689, 30725, 30757, 30795, 30796, 30877, 30958, 31038, 31044, 31125, 31205, 31288, 31294, 31369, 31375, 31456, 31536, 31619, 31671, 31751, 31757, 31841, 31923, 32002, 32076, 32162, 32196, 32232, 32233, 32299, 32364, 32365, 32398, 32435, 32470, 32503, 32538, 32539, 32558, 32579, 32580, 32597, 32599, 32600, 32679, 32716, 32719, 32794, 32869, 32872, 32882, 32970, 33028, 33031, 33042, 33045, 33124, 33185, 33188, 33192, 33252, 33254, 33281, 33344, 33438, 33440, 33441, 33442, 33521, 33564, 33567, 33637, 33640, 33650, 33708, 33771, 33774, 33785, 33788, 33854, 33891, 33895, 33964, 33966, 33994, 34021, 34022, 34066, 34087, 34093, 34140, 34162, 34168, 34227, 34303, 34325, 34395, 34472, 34547, 34625, 34701, 34718, 34720, 34721, 34800, 34843, 34846, 34922, 34925, 34935, 34989, 35055, 35058, 35081, 35142, 35198, 35267, 35325, 35395, 35398, 35409, 35412, 35464, 35468, 35537, 35539, 35567, 35594, 35595, 35639, 35640, 35668, 35674, 35721, 35743, 35749, 35819, 35896, 35971, 36049, 36125, 36127, 36188, 36266, 36268, 36269, 36342, 36389, 36392, 36465, 36468, 36478, 36481, 36539, 36597, 36600, 36611, 36614, 36683, 36729, 36733, 36799, 36801, 36828, 36892, 36981, 36983, 36984, 37057, 37099, 37102, 37162, 37231, 37259, 37262, 37273, 37297, 37319, 37322, 37388, 37463, 37466, 37475, 37518, 37522, 37549, 37623, 37694, 37765, 37767, 37837, 37912, 37914, 37915, 37988, 38034, 38037, 38104, 38135, 38138, 38149, 38152, 38190, 38252, 38285, 38289, 38320, 38382, 38452, 38454, 38496, 38516, 38538, 38539, 38546, 38608, 38659, 38667, 38710, 38751, 38792, 38845, 38886, 38930, 38974, 39025, 39074, 39176, 39255, 39337, 39421, 39507, 39588, 39678, 39758, 39842, 39906, 39970, 39971, 39988, 39990, 39991, 40064, 40074, 40142, 40214, 40286, 40354, 40423, 40492, 40528, 40587, 40649, 40718, 40770, 40844, 40883, 40939, 40940, 40941, 41014, 41060, 41063, 41129, 41200, 41269, 41272, 41283, 41286, 41324, 41389, 41452, 41455, 41463, 41529, 41590, 41594, 41625, 41697, 41768, 41837, 41839, 41869, 41886, 41901, 41902, 41975, 41976, 41996, 42002, 42075, 42150, 42224, 42230, 42288, 42336, 42350, 42352, 42353, 42426, 42472, 42475, 42501, 42505, 42536, 42608, 42679, 42748, 42750, 42781, 42808, 42851, 42852, 42925, 42973, 42974, 42999, 43082, 43115, 43184, 43194, 43230, 43236, 43237, 43269, 43304, 43306, 43307, 43380, 43424, 43427, 43487, 43490, 43501, 43504, 43542, 43612, 43615, 43623, 43626, 43630, 43657, 43726, 43830, 43931, 44020, 44088, 44090, 44102, 44103, 44204, 44205, 44234, 44256, 44327, 44363, 44373, 44395, 44396, 44443, 44475, 44508, 44556, 44605, 44645, 44683, 44684, 44698, 44700, 44701, 44774, 44818, 44821, 44878, 44881, 44892, 44895, 44976, 44980, 45007, 45075, 45149, 45222, 45224, 45282, 45333, 45335, 45336, 45409, 45458, 45461, 45530, 45533, 45543, 45610, 45685, 45736, 45739, 45750, 45769, 45820, 45823, 45827, 45922, 45924, 45962, 45989, 46009, 46010, 46085, 46086, 46134, 46157, 46175, 46176, 46266, 46300, 46372, 46373, 46405, 46406, 46420, 46422, 46423, 46424, 46497, 46549, 46552, 46621, 46624, 46654, 46657, 46661, 46755, 46757, 46769, 46798, 46813, 46814, 46889, 46890, 46910, 46916, 46989, 47062, 47136, 47142, 47204, 47252, 47266, 47268, 47269, 47270, 47343, 47393, 47396, 47485, 47488, 47500, 47503, 47565, 47625, 47629, 47664, 47761, 47842, 47937, 48022, 48086, 48088, 48123, 48150, 48193, 48194, 48303, 48351, 48352, 48377, 48468, 48505, 48572, 48582, 48618, 48624, 48625, 48657, 48692, 48694, 48695, 48771, 48826, 48829, 48916, 48919, 48931, 48934, 48996, 49056, 49060, 49095, 49190, 49271, 49366, 49445, 49509, 49511, 49535, 49567, 49568, 49679, 49753, 49789, 49790, 49857, 49858, 49898, 49916, 49918, 49919 ], "line_end_idx": [ 33, 99, 100, 107, 108, 111, 147, 150, 184, 187, 252, 314, 378, 448, 451, 518, 584, 653, 704, 707, 775, 846, 923, 927, 928, 948, 971, 972, 992, 1012, 1031, 1032, 1056, 1081, 1101, 1122, 1144, 1166, 1191, 1192, 1217, 1243, 1244, 1268, 1269, 1303, 1304, 1377, 1415, 1418, 1487, 1563, 1567, 1611, 1613, 1664, 1665, 1742, 1785, 1820, 1828, 1850, 1851, 1924, 1991, 2032, 2063, 2076, 2127, 2180, 2193, 2264, 2307, 2338, 2339, 2404, 2442, 2470, 2484, 2509, 2553, 2567, 2575, 2642, 2669, 2694, 2701, 2719, 2721, 2723, 2786, 2788, 2836, 2879, 2926, 2944, 2946, 2947, 3009, 3011, 3084, 3160, 3194, 3195, 3226, 3234, 3250, 3286, 3305, 3321, 3357, 3376, 3392, 3426, 3445, 3461, 3496, 3515, 3531, 3568, 3587, 3602, 3627, 3635, 3636, 3654, 3656, 3657, 3723, 3725, 3743, 3744, 3792, 3817, 3818, 3851, 3859, 3891, 3915, 3923, 3934, 3959, 3961, 3962, 4028, 4030, 4048, 4106, 4107, 4148, 4156, 4178, 4218, 4226, 4237, 4245, 4299, 4330, 4331, 4357, 4401, 4432, 4477, 4494, 4525, 4533, 4540, 4558, 4560, 4561, 4622, 4624, 4670, 4721, 4722, 4756, 4764, 4786, 4812, 4820, 4860, 4868, 4890, 4916, 4924, 4935, 4960, 4961, 4979, 4981, 4982, 5055, 5102, 5105, 5172, 5176, 5238, 5240, 5262, 5263, 5328, 5354, 5361, 5391, 5399, 5414, 5429, 5444, 5479, 5498, 5513, 5528, 5543, 5558, 5594, 5613, 5628, 5665, 5684, 5692, 5693, 5731, 5772, 5810, 5811, 5874, 5900, 5901, 5939, 5980, 6018, 6031, 6098, 6124, 6125, 6163, 6204, 6242, 6243, 6310, 6336, 6337, 6398, 6436, 6461, 6469, 6491, 6535, 6587, 6631, 6639, 6640, 6717, 6776, 6795, 6803, 6817, 6850, 6884, 6925, 6966, 7019, 7072, 7091, 7107, 7139, 7172, 7213, 7254, 7307, 7360, 7379, 7395, 7428, 7462, 7502, 7542, 7598, 7654, 7673, 7688, 7714, 7722, 7723, 7773, 7805, 7812, 7831, 7833, 7834, 7907, 7954, 7957, 8010, 8067, 8071, 8160, 8162, 8180, 8219, 8279, 8349, 8409, 8469, 8519, 8574, 8634, 8694, 8749, 8804, 8864, 8865, 8886, 8894, 8938, 8939, 8984, 8998, 9029, 9048, 9129, 9167, 9181, 9233, 9247, 9326, 9364, 9378, 9428, 9442, 9525, 9563, 9577, 9627, 9641, 9672, 9691, 9774, 9812, 9826, 9874, 9888, 9957, 9995, 9996, 10051, 10113, 10173, 10236, 10312, 10326, 10375, 10389, 10458, 10496, 10497, 10536, 10574, 10588, 10638, 10652, 10721, 10759, 10760, 10806, 10820, 10870, 10884, 10953, 10991, 10992, 11038, 11052, 11101, 11115, 11184, 11222, 11223, 11268, 11282, 11331, 11345, 11414, 11452, 11453, 11498, 11512, 11562, 11576, 11645, 11683, 11684, 11757, 11832, 11881, 11895, 11912, 11944, 11945, 12023, 12071, 12113, 12145, 12153, 12154, 12229, 12245, 12253, 12300, 12349, 12366, 12414, 12422, 12423, 12442, 12444, 12445, 12521, 12570, 12573, 12643, 12717, 12791, 12794, 12805, 12808, 12866, 12870, 12897, 12983, 13054, 13056, 13114, 13116, 13117, 13193, 13248, 13251, 13321, 13393, 13438, 13441, 13452, 13455, 13499, 13503, 13541, 13616, 13699, 13783, 13785, 13809, 13839, 13840, 13893, 13961, 13995, 13996, 14086, 14087, 14125, 14143, 14145, 14146, 14222, 14271, 14274, 14343, 14417, 14462, 14465, 14476, 14479, 14522, 14526, 14564, 14641, 14724, 14808, 14810, 14825, 14854, 14873, 14900, 14901, 14965, 14966, 15011, 15012, 15082, 15120, 15121, 15196, 15269, 15332, 15352, 15397, 15398, 15432, 15433, 15455, 15483, 15516, 15570, 15581, 15646, 15647, 15664, 15672, 15698, 15749, 15774, 15782, 15793, 15801, 15877, 15928, 15954, 15967, 15969, 15970, 16046, 16095, 16098, 16163, 16239, 16313, 16316, 16327, 16330, 16388, 16392, 16419, 16484, 16555, 16557, 16614, 16616, 16617, 16696, 16739, 16742, 16811, 16814, 16824, 16882, 16885, 16896, 16899, 16979, 17013, 17016, 17024, 17027, 17073, 17077, 17117, 17119, 17146, 17251, 17253, 17254, 17333, 17376, 17379, 17443, 17446, 17456, 17459, 17557, 17560, 17571, 17574, 17653, 17656, 17664, 17667, 17713, 17717, 17759, 17761, 17788, 17894, 17896, 17897, 17976, 18019, 18022, 18090, 18093, 18103, 18106, 18193, 18260, 18263, 18274, 18277, 18345, 18411, 18438, 18442, 18499, 18501, 18522, 18549, 18550, 18568, 18574, 18645, 18716, 18787, 18858, 18929, 19000, 19071, 19142, 19213, 19226, 19277, 19324, 19346, 19352, 19435, 19437, 19438, 19508, 19546, 19549, 19612, 19640, 19643, 19653, 19656, 19717, 19785, 19788, 19799, 19802, 19869, 19873, 19923, 19925, 19952, 20030, 20091, 20093, 20094, 20173, 20210, 20213, 20283, 20335, 20338, 20348, 20351, 20417, 20489, 20552, 20563, 20566, 20638, 20642, 20718, 20720, 20748, 20775, 20776, 20847, 20914, 20936, 20937, 20953, 20959, 20980, 21057, 21134, 21213, 21291, 21371, 21377, 21379, 21395, 21401, 21445, 21446, 21535, 21624, 21714, 21804, 21894, 21979, 22065, 22111, 22159, 22165, 22182, 22184, 22185, 22264, 22301, 22304, 22377, 22458, 22461, 22471, 22542, 22638, 22735, 22738, 22749, 22752, 22828, 22831, 22839, 22842, 22852, 22856, 22922, 22924, 22953, 22980, 22981, 23006, 23033, 23097, 23177, 23179, 23180, 23259, 23290, 23293, 23370, 23406, 23409, 23420, 23423, 23473, 23544, 23547, 23559, 23562, 23615, 23619, 23675, 23677, 23704, 23756, 23819, 23907, 23909, 23910, 23989, 24020, 24023, 24103, 24177, 24214, 24217, 24227, 24230, 24280, 24340, 24343, 24354, 24357, 24403, 24407, 24461, 24463, 24490, 24542, 24605, 24693, 24695, 24696, 24735, 24737, 24809, 24884, 24932, 24985, 25069, 25157, 25245, 25321, 25349, 25358, 25387, 25389, 25390, 25469, 25504, 25507, 25588, 25671, 25683, 25686, 25696, 25699, 25749, 25798, 25801, 25812, 25815, 25901, 25905, 25959, 25961, 25997, 26033, 26069, 26104, 26131, 26132, 26155, 26161, 26208, 26230, 26236, 26257, 26258, 26294, 26308, 26344, 26376, 26414, 26415, 26445, 26470, 26550, 26630, 26662, 26668, 26754, 26840, 26926, 26939, 26986, 27008, 27014, 27046, 27052, 27138, 27224, 27310, 27385, 27471, 27484, 27531, 27553, 27559, 27641, 27719, 27720, 27792, 27868, 27943, 28018, 28092, 28093, 28127, 28163, 28164, 28197, 28234, 28256, 28291, 28324, 28359, 28360, 28429, 28472, 28480, 28544, 28627, 28694, 28777, 28840, 28923, 28983, 29063, 29065, 29066, 29067, 29146, 29183, 29186, 29269, 29272, 29282, 29340, 29397, 29400, 29411, 29414, 29487, 29490, 29498, 29501, 29539, 29543, 29596, 29598, 29627, 29656, 29685, 29713, 29740, 29741, 29790, 29791, 29807, 29813, 29860, 29882, 29888, 29893, 29954, 30034, 30098, 30178, 30238, 30318, 30375, 30451, 30473, 30474, 30512, 30551, 30552, 30603, 30627, 30651, 30652, 30688, 30689, 30725, 30757, 30795, 30796, 30877, 30958, 31038, 31044, 31125, 31205, 31288, 31294, 31369, 31375, 31456, 31536, 31619, 31671, 31751, 31757, 31841, 31923, 32002, 32076, 32162, 32196, 32232, 32233, 32299, 32364, 32365, 32398, 32435, 32470, 32503, 32538, 32539, 32558, 32579, 32580, 32597, 32599, 32600, 32679, 32716, 32719, 32794, 32869, 32872, 32882, 32970, 33028, 33031, 33042, 33045, 33124, 33185, 33188, 33192, 33252, 33254, 33281, 33344, 33438, 33440, 33441, 33442, 33521, 33564, 33567, 33637, 33640, 33650, 33708, 33771, 33774, 33785, 33788, 33854, 33891, 33895, 33964, 33966, 33994, 34021, 34022, 34066, 34087, 34093, 34140, 34162, 34168, 34227, 34303, 34325, 34395, 34472, 34547, 34625, 34701, 34718, 34720, 34721, 34800, 34843, 34846, 34922, 34925, 34935, 34989, 35055, 35058, 35081, 35142, 35198, 35267, 35325, 35395, 35398, 35409, 35412, 35464, 35468, 35537, 35539, 35567, 35594, 35595, 35639, 35640, 35668, 35674, 35721, 35743, 35749, 35819, 35896, 35971, 36049, 36125, 36127, 36188, 36266, 36268, 36269, 36342, 36389, 36392, 36465, 36468, 36478, 36481, 36539, 36597, 36600, 36611, 36614, 36683, 36729, 36733, 36799, 36801, 36828, 36892, 36981, 36983, 36984, 37057, 37099, 37102, 37162, 37231, 37259, 37262, 37273, 37297, 37319, 37322, 37388, 37463, 37466, 37475, 37518, 37522, 37549, 37623, 37694, 37765, 37767, 37837, 37912, 37914, 37915, 37988, 38034, 38037, 38104, 38135, 38138, 38149, 38152, 38190, 38252, 38285, 38289, 38320, 38382, 38452, 38454, 38496, 38516, 38538, 38539, 38546, 38608, 38659, 38667, 38710, 38751, 38792, 38845, 38886, 38930, 38974, 39025, 39074, 39176, 39255, 39337, 39421, 39507, 39588, 39678, 39758, 39842, 39906, 39970, 39971, 39988, 39990, 39991, 40064, 40074, 40142, 40214, 40286, 40354, 40423, 40492, 40528, 40587, 40649, 40718, 40770, 40844, 40883, 40939, 40940, 40941, 41014, 41060, 41063, 41129, 41200, 41269, 41272, 41283, 41286, 41324, 41389, 41452, 41455, 41463, 41529, 41590, 41594, 41625, 41697, 41768, 41837, 41839, 41869, 41886, 41901, 41902, 41975, 41976, 41996, 42002, 42075, 42150, 42224, 42230, 42288, 42336, 42350, 42352, 42353, 42426, 42472, 42475, 42501, 42505, 42536, 42608, 42679, 42748, 42750, 42781, 42808, 42851, 42852, 42925, 42973, 42974, 42999, 43082, 43115, 43184, 43194, 43230, 43236, 43237, 43269, 43304, 43306, 43307, 43380, 43424, 43427, 43487, 43490, 43501, 43504, 43542, 43612, 43615, 43623, 43626, 43630, 43657, 43726, 43830, 43931, 44020, 44088, 44090, 44102, 44103, 44204, 44205, 44234, 44256, 44327, 44363, 44373, 44395, 44396, 44443, 44475, 44508, 44556, 44605, 44645, 44683, 44684, 44698, 44700, 44701, 44774, 44818, 44821, 44878, 44881, 44892, 44895, 44976, 44980, 45007, 45075, 45149, 45222, 45224, 45282, 45333, 45335, 45336, 45409, 45458, 45461, 45530, 45533, 45543, 45610, 45685, 45736, 45739, 45750, 45769, 45820, 45823, 45827, 45922, 45924, 45962, 45989, 46009, 46010, 46085, 46086, 46134, 46157, 46175, 46176, 46266, 46300, 46372, 46373, 46405, 46406, 46420, 46422, 46423, 46424, 46497, 46549, 46552, 46621, 46624, 46654, 46657, 46661, 46755, 46757, 46769, 46798, 46813, 46814, 46889, 46890, 46910, 46916, 46989, 47062, 47136, 47142, 47204, 47252, 47266, 47268, 47269, 47270, 47343, 47393, 47396, 47485, 47488, 47500, 47503, 47565, 47625, 47629, 47664, 47761, 47842, 47937, 48022, 48086, 48088, 48123, 48150, 48193, 48194, 48303, 48351, 48352, 48377, 48468, 48505, 48572, 48582, 48618, 48624, 48625, 48657, 48692, 48694, 48695, 48771, 48826, 48829, 48916, 48919, 48931, 48934, 48996, 49056, 49060, 49095, 49190, 49271, 49366, 49445, 49509, 49511, 49535, 49567, 49568, 49679, 49753, 49789, 49790, 49857, 49858, 49898, 49916, 49918, 49919, 49962 ] }
{ "red_pajama_v2": { "ccnet_original_length": 49962, "ccnet_original_nlines": 1454, "rps_doc_curly_bracket": 0.0038429200649261475, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.1428399384021759, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.08876310288906097, "rps_doc_frac_lines_end_with_ellipsis": 0.0006872899830341339, "rps_doc_frac_no_alph_words": 0.4523666203022003, "rps_doc_frac_unique_words": 0.25842419266700745, "rps_doc_mean_word_length": 7.119425296783447, "rps_doc_num_sentences": 299, "rps_doc_symbol_to_word_ratio": 0.0021678900811821222, "rps_doc_unigram_entropy": 5.89737606048584, "rps_doc_word_count": 4036, "rps_doc_frac_chars_dupe_10grams": 0.13527527451515198, "rps_doc_frac_chars_dupe_5grams": 0.254924476146698, "rps_doc_frac_chars_dupe_6grams": 0.222454234957695, "rps_doc_frac_chars_dupe_7grams": 0.19235053658485413, "rps_doc_frac_chars_dupe_8grams": 0.18020464479923248, "rps_doc_frac_chars_dupe_9grams": 0.1491960734128952, "rps_doc_frac_chars_top_2gram": 0.0064383698627352715, "rps_doc_frac_chars_top_3gram": 0.008596089668571949, "rps_doc_frac_chars_top_4gram": 0.01183267030864954, "rps_doc_books_importance": -3237.6533203125, "rps_doc_books_importance_length_correction": -3237.6533203125, "rps_doc_openwebtext_importance": -1522.6248779296875, "rps_doc_openwebtext_importance_length_correction": -1522.6248779296875, "rps_doc_wikipedia_importance": -1222.010498046875, "rps_doc_wikipedia_importance_length_correction": -1222.010498046875 }, "fasttext": { "dclm": 0.9910963177680969, "english": 0.4788030683994293, "fineweb_edu_approx": 2.0789742469787598, "eai_general_math": 0.5290948152542114, "eai_open_web_math": 0.2573521137237549, "eai_web_code": 0.8696233630180359 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "1", "label": "Leftover HTML" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-44,413,523,771,002,980
Thursday, September 21, 2017 Time Flies From this, in 1936... (Source) To this, in 1944. (Source) From this, in 1939... (Source) To this, in 1945. (Source) Technology can progress at a pretty amazing pace. Wartime sometimes drives that, but what about these things? IBM Personal Computer, 1981. (Source) Acer Aspire Laptop Computer, 2012 (Source) I do remember my first IBM PC clone computer, it had a four color monitor, two 5 and a quarter inch floppy drives and, gasp, a 20 megabyte hard drive. Though I bought it used, for $1200, I was the envy of the guys at work. Well, except for the guy who owned a Mac. There's always that guy. The space program is another example of the leaps and bounds technology can make in a free society. Mercury-Redstone 4, in 1961 (Source) STS-129 Atlantis, in 2009 (Source) One of my favorite examples of the speed of technological development is comparing the latest and greatest aircraft from 1908, the year of my maternal grandmother's birth, to the latest and greatest bird in 2000, the year she died. Wright Model A, first flight in 1908. (Source) F-22 Raptor, first flight in 1997. (Source) So when my grandmother was a child, aircraft were primitive, personal computers and space flight were unheard of, except perhaps in a Jules Verne novel! When she was in her fifties men had walked on the moon. Before she died many people had personal computers, they were practically as ubiquitous as a telephone or television. She often commented at the changes she had seen in her lifetime. Amazes me it does. 30 comments: 1. We went literally from horse and buggy to the Moon in a generation. Now we need the Russians to give us a lift to the Space Station that we by in large paid for. Sad. ReplyDelete Replies 1. It only took 8 years to get to the Moon! The Space Shuttle first launched in 1981 so really it was only 20 years from a man on an ICBM to the flying delivery truck. Delete 2. Here's a look at some of what it takes to get it right-- https://www.youtube.com/watch?v=Lrn1c6N0phw Delete 3. Fascinating to watch. If at first you don't succeed... Delete 2. Yes, well, then Socialism checks in. On the AF web site, there's a banner that says "F-15 in service since 1974". Yay! To add an equivalent statement for 1945 "Wright Flyer in service since 1903" At our high school, there's a banner that says "We're a Reading 180 school!" Yay. Reading 180 is a remedial reading program. So, what they're really saying is "Hooray, a significant portion of our students can't read!" Now, THERE's something to brag about. If it hadn't been for the next to the last President who was a democrat, you know the one who didn't know the definition of "is", spending the "Peace Dividend" to buy votes, we might have actually had enough F-22's to deal with the emerging threat today. Then again, if it hadn't been for the Second worst President ever, doing the same things in the 70's, Iran might not be one of those emerging threats today. Don't even get me started (ok, too late) on the most abominable president ever and his feckless foreign policy as well as his full bore socialist agenda to spend treasure buying votes. Yes. Time flies, and yes, when people are allowed to pursue their own interests with minimal government restrictions, amazing progress can be had. One sincerely prays that time will come again. juvat out. ReplyDelete Replies 1. This post started out as one thing and wound up to be something else (that happens a lot). I was thinking back on the progress that was made when only winners got trophies, when to get to high school one had to know how to read, when math was taught the way it should be. Ya know, the pre-progressive era. I almost started ranting, then decided to let the facts (and pictures) do the talking. I think the post turned out just fine. I still hope, but it's tough. I have seen signs of improvement. We shall see. Delete 2. "This post started out as one thing and wound up to be something else..." As you know, that has NEVER happened to me! ;-) Delete 3. Remember driving home in my parents car after seeing Star Wars and wishing there were more bells and whistles on the dashboard like in that movie...sigh. Now my cell phone is smarter than me and my vehicle almost so... progress. ReplyDelete 4. I think about my grandad born before the Wright bros. flew, and even some of his older sisters who were on a stage that got stopped by outlaws and lived to see man on the moon. Talk about seeing some change in a lifetime. ReplyDelete 5. Kids today expect to see 'new and amazing' technological leaps every year. But they don't want to study STEM courses, work hard, take difficult assignments, and think 'Social Justice' is the end-all, be-all of career choices. I have fun reminding them where the tech for their latest and greatest came from, and who is thinking and making it up now. New phones? Go to China or Japan and you can grab something that is twice as good as what is sold in the states. Same with most electronics. We're in second place because we don't have thinkers and engineers like we used to. Somewhere in the mid-60's, we as a nation started to stop thinking and creating at the same pace as we as a nation did before. It scares me. I know why I didn't go far in STEM, as my brain looked like a lovebug on a car window after it hit Differential Equations, and Physics just didn't make sense (at the time) to me (look, really, why worry about the variable pressure of pumping out a tank from the top, I mean, just build one big-arsed pump to pump from the top to a secondary small tank and one pump to pump from the smaller tank at a constant pressure, duh, really, I mean, really, one pump bad, two pump good, mongo stupid pump for heavy grunt work, and fine delicate pump for precise work (which, as I found out, is what they used to do.)) So, yeah, I feel the blame, but... ReplyDelete Replies 1. Hhmm, I had to fish your comment out of the spam filter, which happens from time to time. But your points are all well made. The 60s hurt the country in many ways, still not sure why. Delete 6. Both of my grandmothers were born in 1903 before the Wright brothers flew their plane. They lived into the 1980s. The technical progress they had seen was amazing. I am glad that they got to miss out on most of the societal decline that has manifested itself in the last 50 years. They didn't like the hippies. One set of grandparents had as good friends a male homosexual couple. Those two guys didn't shove it in ones face and they never made a show of it in front of me. My, how times have changed. ReplyDelete Replies 1. Not for the better in some ways, but for the better in others. As always, progress is a mixed bag. Delete 7. I would add that what we have seen from Star Trek and Star Wars coming about to relaity: -personal communicator/datapad becoming smartphone/tablet -Luke's bionic hand becoming reality, to many veterans of todays wars, amongst others -laser weapons coming close to operational use after 60 years of "decade into future" ReplyDelete 8. Reminded of the benefits of technology every time I feel the pacemaker under the skin of my chest. ReplyDelete 9. We were promised so much. But the Democrats in the Congresional Class of 1972 thought that the money would be better spent buying votes with the Great Society, so the manned space program went away. When I was 10, in 1971, I had a Sgt Storm action figure, part of the Major Matt Mason line. I thought it was fantastic! It seemed like this sort of thing would be what my generation would be doing in 20 years or si, and I would be a part of it, joining Kirk, Doctor Smith, and Sgt. Storm in SPACE! In 1999, I bought my then 7 year old niece a CY Girl action figure. The CY Girls were international law enforcement agents, sort of Women from U.N.C.L.E. One of the CY Girls was equipped with a space suit. Codenamed AURORA, she handles crime in space, on Earth Colonies, and space ships. My thought was that AURORA might just be the second coolest action figure of all time, ( right after the Emma Peel action figure ), but she will never happen, as long as funding can be diverted to vote buying social programs that actually harm the ones they claim to help. ReplyDelete Replies 1. Sigh... Excellent points Scott. Dangerous times, idiot politicians, what could possibly go wrong? Delete 10. When it comes to technology I am reminded of the time Alan Shepard was asked what he was thinking just before his launch. His reply is classic, I was sitting on top of a million pieces all made by the lowest bidder. ReplyDelete Replies 1. I remember hearing of that. Truth, right there. Delete 11. I got my first computer, an Atari 800XL, in 1983. It had 64K of memory, about the most you could get at the time. The cassette tape drive I bought with it took about eight minutes to load a program, if it worked. Sometimes you had to retry two or three times to get the program into the computer. Of course, you also could use memory cartridges: PacMan and the like. The monitor was our TV set, which only allowed (due to the TVs limitations) 40-character text displays. When we first got it, my kids and I typed in the three programs printed in the manual, but they ALL had typos and wouldn't work. We figured out two of them but couldn't get that third one just right. I used to buy computer magazines and type in the programs in there as well, which eventually turned me into a pretty good typist--which used to be woman's work in most people's eyes. Ten years ago, I bought my first iPod. It had 8 gigabytes of memory. I did the math and figured out that if I had bought an Atari 800XL every hour of every day for 25 years, all those computers would have had as much memory as the iPod. Hmmmm... And lets not forget that when we were kids the word processor of the day was the manual typewriter: electric models were few. ReplyDelete Replies 1. Sorry Bruce, I had to pull your comment out of moderation (which is default for posts over a week old due to spam). My very first computer (before the PC-clone) also used a tape cassette to load the OS. Took forever, when it worked. I remember typing in programs from magazines and then trying to debug them, Most of the errors were mine, quite a few had the errors "built in." Not sure if that was the typesetter's issue or the programmer's. But yes, we did learn. Things are almost too easy these days. Program too slow, buy a faster processor or more memory. Actually fix the code to be more efficient? Now that's a lost art. Sigh... Delete Just be polite... that's all I ask. (For Buck) Can't be nice, go somewhere else... NOTE: Comments on posts over 5 days old go into moderation, automatically.
{ "url": "https://oldafsarge.blogspot.com/2017/09/time-flies.html", "source_domain": "oldafsarge.blogspot.com", "snapshot_id": "crawl=CC-MAIN-2021-10", "warc_metadata": { "Content-Length": "274576", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:FTOL5P3HEYYZKH5MNCWOWVFIEV737SLF", "WARC-Concurrent-To": "<urn:uuid:054e0905-acf1-486c-933e-e3f583329de2>", "WARC-Date": "2021-03-05T06:59:10Z", "WARC-IP-Address": "172.217.9.193", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:YEA3WWF64PW6OFX7JO4UNIS2FU5DE3YR", "WARC-Record-ID": "<urn:uuid:a9b751ca-6762-4379-9e9b-a814a306224f>", "WARC-Target-URI": "https://oldafsarge.blogspot.com/2017/09/time-flies.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ff2e9e83-2a17-414a-a2e9-34e8b30f5f01>" }, "warc_info": "isPartOf: CC-MAIN-2021-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February/March 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-119.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 29, 30, 41, 42, 64, 73, 91, 100, 122, 131, 149, 158, 268, 269, 298, 307, 341, 350, 573, 574, 616, 617, 642, 643, 743, 744, 772, 781, 807, 816, 1048, 1049, 1087, 1096, 1131, 1140, 1467, 1468, 1533, 1534, 1553, 1554, 1555, 1556, 1569, 1570, 1643, 1644, 1747, 1748, 1764, 1776, 1948, 1949, 1962, 2026, 2027, 2077, 2078, 2091, 2120, 2121, 2160, 2161, 2174, 2632, 3233, 3431, 3446, 3447, 3463, 3475, 3573, 3574, 3882, 3883, 3928, 3929, 4013, 4014, 4027, 4108, 4109, 4163, 4164, 4177, 4411, 4412, 4428, 4655, 4656, 4672, 4903, 4904, 5257, 5258, 5403, 5404, 6051, 6052, 6068, 6080, 6177, 6178, 6278, 6279, 6292, 6799, 6800, 6816, 6828, 6898, 6899, 6941, 6942, 6955, 7049, 7111, 7201, 7291, 7292, 7308, 7412, 7413, 7429, 7633, 7634, 7936, 7937, 8502, 8503, 8519, 8531, 8546, 8547, 8643, 8644, 8657, 8879, 8880, 8896, 8908, 8963, 8964, 8977, 9350, 9351, 9842, 9843, 10093, 10094, 10224, 10225, 10241, 10253, 10376, 10377, 10500, 10501, 10717, 10718, 10910, 10911, 10925, 10926, 10939, 10940, 10987, 11023, 11024 ], "line_end_idx": [ 29, 30, 41, 42, 64, 73, 91, 100, 122, 131, 149, 158, 268, 269, 298, 307, 341, 350, 573, 574, 616, 617, 642, 643, 743, 744, 772, 781, 807, 816, 1048, 1049, 1087, 1096, 1131, 1140, 1467, 1468, 1533, 1534, 1553, 1554, 1555, 1556, 1569, 1570, 1643, 1644, 1747, 1748, 1764, 1776, 1948, 1949, 1962, 2026, 2027, 2077, 2078, 2091, 2120, 2121, 2160, 2161, 2174, 2632, 3233, 3431, 3446, 3447, 3463, 3475, 3573, 3574, 3882, 3883, 3928, 3929, 4013, 4014, 4027, 4108, 4109, 4163, 4164, 4177, 4411, 4412, 4428, 4655, 4656, 4672, 4903, 4904, 5257, 5258, 5403, 5404, 6051, 6052, 6068, 6080, 6177, 6178, 6278, 6279, 6292, 6799, 6800, 6816, 6828, 6898, 6899, 6941, 6942, 6955, 7049, 7111, 7201, 7291, 7292, 7308, 7412, 7413, 7429, 7633, 7634, 7936, 7937, 8502, 8503, 8519, 8531, 8546, 8547, 8643, 8644, 8657, 8879, 8880, 8896, 8908, 8963, 8964, 8977, 9350, 9351, 9842, 9843, 10093, 10094, 10224, 10225, 10241, 10253, 10376, 10377, 10500, 10501, 10717, 10718, 10910, 10911, 10925, 10926, 10939, 10940, 10987, 11023, 11024, 11098 ] }
{ "red_pajama_v2": { "ccnet_original_length": 11098, "ccnet_original_nlines": 170, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4271481931209564, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.02947280928492546, "rps_doc_frac_lines_end_with_ellipsis": 0.046783629804849625, "rps_doc_frac_no_alph_words": 0.1938563734292984, "rps_doc_frac_unique_words": 0.3755772113800049, "rps_doc_mean_word_length": 4.26680326461792, "rps_doc_num_sentences": 159, "rps_doc_symbol_to_word_ratio": 0.004981319885700941, "rps_doc_unigram_entropy": 5.827651023864746, "rps_doc_word_count": 1949, "rps_doc_frac_chars_dupe_10grams": 0.013227510266005993, "rps_doc_frac_chars_dupe_5grams": 0.026936030015349388, "rps_doc_frac_chars_dupe_6grams": 0.017797019332647324, "rps_doc_frac_chars_dupe_7grams": 0.013227510266005993, "rps_doc_frac_chars_dupe_8grams": 0.013227510266005993, "rps_doc_frac_chars_dupe_9grams": 0.013227510266005993, "rps_doc_frac_chars_top_2gram": 0.0066137597896158695, "rps_doc_frac_chars_top_3gram": 0.0159932691603899, "rps_doc_frac_chars_top_4gram": 0.003367000026628375, "rps_doc_books_importance": -1377.343994140625, "rps_doc_books_importance_length_correction": -1377.343994140625, "rps_doc_openwebtext_importance": -638.4446411132812, "rps_doc_openwebtext_importance_length_correction": -638.4446411132812, "rps_doc_wikipedia_importance": -456.3531188964844, "rps_doc_wikipedia_importance_length_correction": -456.3531188964844 }, "fasttext": { "dclm": 0.23880833387374878, "english": 0.981670081615448, "fineweb_edu_approx": 1.6997458934783936, "eai_general_math": 0.19122201204299927, "eai_open_web_math": 0.29736846685409546, "eai_web_code": 0.01768987998366356 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.09", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "629.45", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Engineering", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "5", "label": "Evaluate" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "9", "label": "Personal/Misc" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "16", "label": "Personal Blog" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
7,100,511,617,912,794,000
How to watch ShowTime in Qatar You must be looking for an answer on how to watch ShowTime in Qatar and you have come to the right place. Since ShowTime offers a lot more interesting movies plus original shows than similar services in Qatar, then many people in Qatar are looking for a way to switch their IP to the USA and get access to ShowTime instead. After reading this article, you will be able to unblock ShowTime in Qatar and any other location around the world. In this guide, I’m sharing you the best VPNs that still works to get access to ShowTime library of content outside the USA. Best VPNs for ShowTime 1 • Countries 94 • Servers 2000+ • Compatability windows compatiblemac compatibleios compatibleandroid compatiblelinux compatible • Score 98.75% Save 49% + 3 month free signing up now, 100% Money-Back Guarantee for 30 Days, Apps for Windows, Mac, Linux, Android and iPhone, SSL secure 30 Days Risk-Free Ultra Fast Servers Mobile Apps 2 • Countries 62 • Servers 4900 • Compatability windows compatiblemac compatibleios compatibleandroid compatible • Score 96.75% 4900 servers in 62 countriess, 6 simultaneous connections, Secures all devices, Bitcoin payment option, VPN access in China, Socks5 proxy servers Servers in 62 countries Socks5 proxy servers Mobile apps 3 • Countries 50+ • Servers 200+ • Compatability windows compatiblemac compatibleios compatibleandroid compatiblelinux compatible • Score 95.5% 77% OFF Today! 100+ server locations, Optimized P2P, Split Tunneling Special offer 100+ locations Mobile Apps Why is the USA ShowTime so great Watch ShowTime in Qatar Why would you rather watch ShowTime in Qatar instead watching of your local streaming services? The main reason for getting the USA IP address and accessing ShowTime is that it offers a lot more movies plus original shows than Qatari services. But the pricing for the ShowTime isn’t that different from alike services in Qatar. Furthermore, in the USA, ShowTime keep releasing new content every month where in Qatar you may not get new releases as often added. Moreover, it is easy to unblock ShowTime in Qatar. Unblock ShowTime using VPN in Qatar VPN is a Virtual Private Network; it is a service that is fairly easy to set up on most of the devices. It provides many advantages to the internet users. And one of the main benefits is that it lets you watch ShowTime in Qatar and other locations around the world. Here are some of the key reasons why you should use VPN for Qatar to unblock ShowTime: • VPN encrypts your internet traffic and protects your online data • It makes your online activities anonymous preventing Qatari government and ISPs from eavesdropping on your browsing habits • You can access all the content and services that are available in the location of the VPN server you connect. If you connect to the USA server then you can get access not only to ShowTime version but also other Qatari on-demand streaming services that you have no access in Qatar • You can connect to servers in other countries and unblock sites from there too • Allows to avoid potential DNS Hijacking and even stop your ISP from using Transparent Proxy. There are many VPN services available. However, not all work with ShowTime. Therefore here in this article, you can find services that currently allow unblocking ShowTime in Qatar. How does VPN work for ShowTime Since ShowTime uses international geo-blocks to separate other country users from Qatari users, then VPN lets anyone bypass these blocks by changing your Qatari IP address to the USA, and therefore it allows you to appear as you are physically located in the USA. How to use VPN to watch ShowTime in Qatar In case, you have never used a Virtual Private Network before, in here I’m going to provide you with a step by step guide on how to use a VPN to access ShowTime in Qatar. Step 1: Sign up for a VPN service The first thing to be able to unblock ShowTime outside of the USA, you need to get a reliable VPN service. Above in the list, you can find all the services that currently work with ShowTime in Qatar. All of our recommended VPNs for ShowTime have servers in the USA and Qatar. They offer great customer support, as well as money back guarantee in case you wish to cancel and try something else. So all the services on our list are easy to use for Qatari users, and all of them are risk-free. Step 2: Download and install VPN client After signing up for an account, you can log in and access software download page. Look up for a VPN software that fits your operating system. Once you have selected the device, just follow the instructions to complete the VPN installation process. Step 3: Open the VPN software and log in The first time logging in you’ll have to key in your login details and depending on a Qatar VPN service, you may need to fill in additional information provided by your service provider. However, for all the best VPNs, the process is straightforward. Step 4: Select a server location To access ShowTime in Qatar, you need to get American IP address. Connecting to a server in the USA will change your Qatari IP address to the USA and let you access any American sites that have restrictions in Qatar. Therefore, search for a server, click connect and once you want your connection to end, you can click on disconnect button to stop. Step 5: Go to ShowTime Once you have connected to the USA server, you can go to www.sho.com. Either you will have to register or it will automatically log you in and allow you to watch movies and TV shows that earlier you were unable to access in Qatar. Unblock ShowTime on Android and iPhone too In addition to desktop and laptop users, all the best VPNs for ShowTime also work on Android and iOS devices. Furthermore, you can use tablets and other operating systems like Kodi, Ubuntu, Bada, Chromium OS, Amazon Kindle and others to get ShowTime in Qatar. Why some VPN doesn’t work with ShowTime Due to copyright law, some services including ShowTime are unable to provide their content for people in Qatar. Some nations including people in Qatar don’t get nearly as good streaming services and content as people in the USA. However, ShowTime owners are aware that people from different countries may try to change their IP to get access to ShowTime. Therefore, it tries to block VPN IP addresses that may allow Qatari users to get ShowTime access in Qatar. For VPNs to be able to connect, have to update their IP address offerings. They not only need to spend more money but also put a lot of efforts to successfully update their IPs. Therefore, many VPNs aren’t capable of supporting ShowTime users. What VPN still works with ShowTime Unfortunately, there aren’t that many great VPNs that work with ShowTime. Therefore, if you wish to access ShowTime in Qatar, you can try out one of the services from the list above that we update regularly. Watch ShowTime in Qatar – Conclusion Here in this guide, I have provided you with a list of the best VPNs for watching ShowTime outside the USA. All of the services are ultra-secure and provide excellent privacy to any Qatari users. Follow the step by step guide to change your Qatari IP address and watch ShowTime in Qatar and from other locations in the world. Furthermore, if you are traveling abroad, you can use the same guide to stream ShowTime from Puerto Rico and other locations. Comments Leave a Reply Your email address will not be published. Required fields are marked * Show Buttons Hide Buttons
{ "url": "https://www.bestvpntoday.com/service/watch-show-time-in-qatar", "source_domain": "www.bestvpntoday.com", "snapshot_id": "crawl=CC-MAIN-2021-31", "warc_metadata": { "Content-Length": "171076", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:T5Y7WGMFRQESNT3GIG5NMF46QMO47MZB", "WARC-Concurrent-To": "<urn:uuid:9801d253-a938-479a-9dfb-a45b6f100322>", "WARC-Date": "2021-08-02T02:12:23Z", "WARC-IP-Address": "54.239.152.116", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:SXSPEV6IUT2XEXEGWWOV5JTOCKLVZPUW", "WARC-Record-ID": "<urn:uuid:f6a6fe15-5897-40dc-9278-58c3b2f2b0eb>", "WARC-Target-URI": "https://www.bestvpntoday.com/service/watch-show-time-in-qatar", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:2b8f6298-e988-4d31-ae1f-66caf9add635>" }, "warc_info": "isPartOf: CC-MAIN-2021-31\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July/August 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-139.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 31, 32, 595, 596, 619, 620, 622, 639, 657, 756, 773, 774, 914, 915, 933, 952, 964, 965, 967, 984, 1001, 1084, 1101, 1102, 1248, 1249, 1273, 1294, 1306, 1307, 1309, 1327, 1344, 1443, 1459, 1460, 1529, 1530, 1544, 1559, 1571, 1572, 1605, 1606, 1630, 1631, 2143, 2144, 2180, 2181, 2534, 2535, 2604, 2731, 3015, 3098, 3195, 3196, 3377, 3378, 3409, 3410, 3674, 3675, 3717, 3718, 3889, 3890, 3924, 3925, 4125, 4126, 4417, 4418, 4458, 4459, 4708, 4709, 4750, 4751, 5002, 5003, 5036, 5037, 5254, 5255, 5387, 5388, 5411, 5412, 5643, 5644, 5687, 5688, 5948, 5949, 5989, 5990, 6452, 6453, 6697, 6698, 6733, 6734, 6942, 6943, 6980, 6981, 7433, 7434, 7443, 7444, 7458, 7459, 7530, 7531, 7544 ], "line_end_idx": [ 31, 32, 595, 596, 619, 620, 622, 639, 657, 756, 773, 774, 914, 915, 933, 952, 964, 965, 967, 984, 1001, 1084, 1101, 1102, 1248, 1249, 1273, 1294, 1306, 1307, 1309, 1327, 1344, 1443, 1459, 1460, 1529, 1530, 1544, 1559, 1571, 1572, 1605, 1606, 1630, 1631, 2143, 2144, 2180, 2181, 2534, 2535, 2604, 2731, 3015, 3098, 3195, 3196, 3377, 3378, 3409, 3410, 3674, 3675, 3717, 3718, 3889, 3890, 3924, 3925, 4125, 4126, 4417, 4418, 4458, 4459, 4708, 4709, 4750, 4751, 5002, 5003, 5036, 5037, 5254, 5255, 5387, 5388, 5411, 5412, 5643, 5644, 5687, 5688, 5948, 5949, 5989, 5990, 6452, 6453, 6697, 6698, 6733, 6734, 6942, 6943, 6980, 6981, 7433, 7434, 7443, 7444, 7458, 7459, 7530, 7531, 7544, 7556 ] }
{ "red_pajama_v2": { "ccnet_original_length": 7556, "ccnet_original_nlines": 117, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4117647111415863, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.037619698792696, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.13406293094158173, "rps_doc_frac_unique_words": 0.3161140978336334, "rps_doc_mean_word_length": 4.656129360198975, "rps_doc_num_sentences": 57, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.22188663482666, "rps_doc_word_count": 1297, "rps_doc_frac_chars_dupe_10grams": 0.031462159007787704, "rps_doc_frac_chars_dupe_5grams": 0.11823149770498276, "rps_doc_frac_chars_dupe_6grams": 0.06888557970523834, "rps_doc_frac_chars_dupe_7grams": 0.0413975790143013, "rps_doc_frac_chars_dupe_8grams": 0.0413975790143013, "rps_doc_frac_chars_dupe_9grams": 0.031462159007787704, "rps_doc_frac_chars_top_2gram": 0.03129656985402107, "rps_doc_frac_chars_top_3gram": 0.03974168002605438, "rps_doc_frac_chars_top_4gram": 0.026494450867176056, "rps_doc_books_importance": -704.0286865234375, "rps_doc_books_importance_length_correction": -704.0286865234375, "rps_doc_openwebtext_importance": -383.1484375, "rps_doc_openwebtext_importance_length_correction": -383.1484375, "rps_doc_wikipedia_importance": -310.28125, "rps_doc_wikipedia_importance_length_correction": -310.28125 }, "fasttext": { "dclm": 0.024155139923095703, "english": 0.9198710918426514, "fineweb_edu_approx": 1.2798441648483276, "eai_general_math": 0.0055108098313212395, "eai_open_web_math": 0.062341030687093735, "eai_web_code": 0.0025576900225132704 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.677", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "389.29", "labels": { "level_1": "Social sciences", "level_2": "Commerce and Communication and traffic", "level_3": "Weights and measures and Metrology" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "6", "label": "Promotional/Advertisement" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-1,769,945,829,717,245,000
thread_identity.h Go to the documentation of this file. 00001 // Copyright 2017 The Abseil Authors. 00002 // 00003 // Licensed under the Apache License, Version 2.0 (the "License"); 00004 // you may not use this file except in compliance with the License. 00005 // You may obtain a copy of the License at 00006 // 00007 // https://www.apache.org/licenses/LICENSE-2.0 00008 // 00009 // Unless required by applicable law or agreed to in writing, software 00010 // distributed under the License is distributed on an "AS IS" BASIS, 00011 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00012 // See the License for the specific language governing permissions and 00013 // limitations under the License. 00014 // 00015 // Each active thread has an ThreadIdentity that may represent the thread in 00016 // various level interfaces. ThreadIdentity objects are never deallocated. 00017 // When a thread terminates, its ThreadIdentity object may be reused for a 00018 // thread created later. 00019 00020 #ifndef ABSL_BASE_INTERNAL_THREAD_IDENTITY_H_ 00021 #define ABSL_BASE_INTERNAL_THREAD_IDENTITY_H_ 00022 00023 #ifndef _WIN32 00024 #include <pthread.h> 00025 // Defines __GOOGLE_GRTE_VERSION__ (via glibc-specific features.h) when 00026 // supported. 00027 #include <unistd.h> 00028 #endif 00029 00030 #include <atomic> 00031 #include <cstdint> 00032 00033 #include "absl/base/internal/per_thread_tls.h" 00034 00035 namespace absl { 00036 00037 struct SynchLocksHeld; 00038 struct SynchWaitParams; 00039 00040 namespace base_internal { 00041 00042 class SpinLock; 00043 struct ThreadIdentity; 00044 00045 // Used by the implementation of absl::Mutex and absl::CondVar. 00046 struct PerThreadSynch { 00047 // The internal representation of absl::Mutex and absl::CondVar rely 00048 // on the alignment of PerThreadSynch. Both store the address of the 00049 // PerThreadSynch in the high-order bits of their internal state, 00050 // which means the low kLowZeroBits of the address of PerThreadSynch 00051 // must be zero. 00052 static constexpr int kLowZeroBits = 8; 00053 static constexpr int kAlignment = 1 << kLowZeroBits; 00054 00055 // Returns the associated ThreadIdentity. 00056 // This can be implemented as a cast because we guarantee 00057 // PerThreadSynch is the first element of ThreadIdentity. 00058 ThreadIdentity* thread_identity() { 00059 return reinterpret_cast<ThreadIdentity*>(this); 00060 } 00061 00062 PerThreadSynch *next; // Circular waiter queue; initialized to 0. 00063 PerThreadSynch *skip; // If non-zero, all entries in Mutex queue 00064 // up to and including "skip" have same 00065 // condition as this, and will be woken later 00066 bool may_skip; // if false while on mutex queue, a mutex unlocker 00067 // is using this PerThreadSynch as a terminator. Its 00068 // skip field must not be filled in because the loop 00069 // might then skip over the terminator. 00070 00071 // The wait parameters of the current wait. waitp is null if the 00072 // thread is not waiting. Transitions from null to non-null must 00073 // occur before the enqueue commit point (state = kQueued in 00074 // Enqueue() and CondVarEnqueue()). Transitions from non-null to 00075 // null must occur after the wait is finished (state = kAvailable in 00076 // Mutex::Block() and CondVar::WaitCommon()). This field may be 00077 // changed only by the thread that describes this PerThreadSynch. A 00078 // special case is Fer(), which calls Enqueue() on another thread, 00079 // but with an identical SynchWaitParams pointer, thus leaving the 00080 // pointer unchanged. 00081 SynchWaitParams *waitp; 00082 00083 bool suppress_fatal_errors; // If true, try to proceed even in the face of 00084 // broken invariants. This is used within fatal 00085 // signal handlers to improve the chances of 00086 // debug logging information being output 00087 // successfully. 00088 00089 intptr_t readers; // Number of readers in mutex. 00090 int priority; // Priority of thread (updated every so often). 00091 00092 // When priority will next be read (cycles). 00093 int64_t next_priority_read_cycles; 00094 00095 // State values: 00096 // kAvailable: This PerThreadSynch is available. 00097 // kQueued: This PerThreadSynch is unavailable, it's currently queued on a 00098 // Mutex or CondVar waistlist. 00099 // 00100 // Transitions from kQueued to kAvailable require a release 00101 // barrier. This is needed as a waiter may use "state" to 00102 // independently observe that it's no longer queued. 00103 // 00104 // Transitions from kAvailable to kQueued require no barrier, they 00105 // are externally ordered by the Mutex. 00106 enum State { 00107 kAvailable, 00108 kQueued 00109 }; 00110 std::atomic<State> state; 00111 00112 bool maybe_unlocking; // Valid at head of Mutex waiter queue; 00113 // true if UnlockSlow could be searching 00114 // for a waiter to wake. Used for an optimization 00115 // in Enqueue(). true is always a valid value. 00116 // Can be reset to false when the unlocker or any 00117 // writer releases the lock, or a reader fully releases 00118 // the lock. It may not be set to false by a reader 00119 // that decrements the count to non-zero. 00120 // protected by mutex spinlock 00121 00122 bool wake; // This thread is to be woken from a Mutex. 00123 00124 // If "x" is on a waiter list for a mutex, "x->cond_waiter" is true iff the 00125 // waiter is waiting on the mutex as part of a CV Wait or Mutex Await. 00126 // 00127 // The value of "x->cond_waiter" is meaningless if "x" is not on a 00128 // Mutex waiter list. 00129 bool cond_waiter; 00130 00131 // Locks held; used during deadlock detection. 00132 // Allocated in Synch_GetAllLocks() and freed in ReclaimThreadIdentity(). 00133 SynchLocksHeld *all_locks; 00134 }; 00135 00136 struct ThreadIdentity { 00137 // Must be the first member. The Mutex implementation requires that 00138 // the PerThreadSynch object associated with each thread is 00139 // PerThreadSynch::kAlignment aligned. We provide this alignment on 00140 // ThreadIdentity itself. 00141 PerThreadSynch per_thread_synch; 00142 00143 // Private: Reserved for absl::synchronization_internal::Waiter. 00144 struct WaiterState { 00145 char data[128]; 00146 } waiter_state; 00147 00148 // Used by PerThreadSem::{Get,Set}ThreadBlockedCounter(). 00149 std::atomic<int>* blocked_count_ptr; 00150 00151 // The following variables are mostly read/written just by the 00152 // thread itself. The only exception is that these are read by 00153 // a ticker thread as a hint. 00154 std::atomic<int> ticker; // Tick counter, incremented once per second. 00155 std::atomic<int> wait_start; // Ticker value when thread started waiting. 00156 std::atomic<bool> is_idle; // Has thread become idle yet? 00157 00158 ThreadIdentity* next; 00159 }; 00160 00161 // Returns the ThreadIdentity object representing the calling thread; guaranteed 00162 // to be unique for its lifetime. The returned object will remain valid for the 00163 // program's lifetime; although it may be re-assigned to a subsequent thread. 00164 // If one does not exist, return nullptr instead. 00165 // 00166 // Does not malloc(*), and is async-signal safe. 00167 // [*] Technically pthread_setspecific() does malloc on first use; however this 00168 // is handled internally within tcmalloc's initialization already. 00169 // 00170 // New ThreadIdentity objects can be constructed and associated with a thread 00171 // by calling GetOrCreateCurrentThreadIdentity() in per-thread-sem.h. 00172 ThreadIdentity* CurrentThreadIdentityIfPresent(); 00173 00174 using ThreadIdentityReclaimerFunction = void (*)(void*); 00175 00176 // Sets the current thread identity to the given value. 'reclaimer' is a 00177 // pointer to the global function for cleaning up instances on thread 00178 // destruction. 00179 void SetCurrentThreadIdentity(ThreadIdentity* identity, 00180 ThreadIdentityReclaimerFunction reclaimer); 00181 00182 // Removes the currently associated ThreadIdentity from the running thread. 00183 // This must be called from inside the ThreadIdentityReclaimerFunction, and only 00184 // from that function. 00185 void ClearCurrentThreadIdentity(); 00186 00187 // May be chosen at compile time via: -DABSL_FORCE_THREAD_IDENTITY_MODE=<mode 00188 // index> 00189 #ifdef ABSL_THREAD_IDENTITY_MODE_USE_POSIX_SETSPECIFIC 00190 #error ABSL_THREAD_IDENTITY_MODE_USE_POSIX_SETSPECIFIC cannot be direcly set 00191 #else 00192 #define ABSL_THREAD_IDENTITY_MODE_USE_POSIX_SETSPECIFIC 0 00193 #endif 00194 00195 #ifdef ABSL_THREAD_IDENTITY_MODE_USE_TLS 00196 #error ABSL_THREAD_IDENTITY_MODE_USE_TLS cannot be direcly set 00197 #else 00198 #define ABSL_THREAD_IDENTITY_MODE_USE_TLS 1 00199 #endif 00200 00201 #ifdef ABSL_THREAD_IDENTITY_MODE_USE_CPP11 00202 #error ABSL_THREAD_IDENTITY_MODE_USE_CPP11 cannot be direcly set 00203 #else 00204 #define ABSL_THREAD_IDENTITY_MODE_USE_CPP11 2 00205 #endif 00206 00207 #ifdef ABSL_THREAD_IDENTITY_MODE 00208 #error ABSL_THREAD_IDENTITY_MODE cannot be direcly set 00209 #elif defined(ABSL_FORCE_THREAD_IDENTITY_MODE) 00210 #define ABSL_THREAD_IDENTITY_MODE ABSL_FORCE_THREAD_IDENTITY_MODE 00211 #elif defined(_WIN32) 00212 #define ABSL_THREAD_IDENTITY_MODE ABSL_THREAD_IDENTITY_MODE_USE_CPP11 00213 #elif ABSL_PER_THREAD_TLS && defined(__GOOGLE_GRTE_VERSION__) && \ 00214 (__GOOGLE_GRTE_VERSION__ >= 20140228L) 00215 // Support for async-safe TLS was specifically added in GRTEv4. It's not 00216 // present in the upstream eglibc. 00217 // Note: Current default for production systems. 00218 #define ABSL_THREAD_IDENTITY_MODE ABSL_THREAD_IDENTITY_MODE_USE_TLS 00219 #else 00220 #define ABSL_THREAD_IDENTITY_MODE \ 00221 ABSL_THREAD_IDENTITY_MODE_USE_POSIX_SETSPECIFIC 00222 #endif 00223 00224 #if ABSL_THREAD_IDENTITY_MODE == ABSL_THREAD_IDENTITY_MODE_USE_TLS || \ 00225 ABSL_THREAD_IDENTITY_MODE == ABSL_THREAD_IDENTITY_MODE_USE_CPP11 00226 00227 extern ABSL_PER_THREAD_TLS_KEYWORD ThreadIdentity* thread_identity_ptr; 00228 00229 inline ThreadIdentity* CurrentThreadIdentityIfPresent() { 00230 return thread_identity_ptr; 00231 } 00232 00233 #elif ABSL_THREAD_IDENTITY_MODE != \ 00234 ABSL_THREAD_IDENTITY_MODE_USE_POSIX_SETSPECIFIC 00235 #error Unknown ABSL_THREAD_IDENTITY_MODE 00236 #endif 00237 00238 } // namespace base_internal 00239 } // namespace absl 00240 00241 #endif // ABSL_BASE_INTERNAL_THREAD_IDENTITY_H_ abseil_cpp Author(s): autogenerated on Wed Jun 19 2019 19:42:15
{ "url": "http://docs.ros.org/en/indigo/api/abseil_cpp/html/thread__identity_8h_source.html", "source_domain": "docs.ros.org", "snapshot_id": "crawl=CC-MAIN-2021-10", "warc_metadata": { "Content-Length": "33930", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:3NUE5OZQHIGLLXAMLTQXK35OE2KXRY2D", "WARC-Concurrent-To": "<urn:uuid:d748563f-2edb-4c81-8eee-a25790fad5c6>", "WARC-Date": "2021-02-24T20:50:04Z", "WARC-IP-Address": "140.211.9.98", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:CRMMXCAPTGIWELTHGGTRHFFMON27J5MI", "WARC-Record-ID": "<urn:uuid:ad8a7c87-c613-4d84-bbe3-e6ff67a6a2e6>", "WARC-Target-URI": "http://docs.ros.org/en/indigo/api/abseil_cpp/html/thread__identity_8h_source.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:b156d078-421a-4d44-8e9a-4ea1af9cca11>" }, "warc_info": "isPartOf: CC-MAIN-2021-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February/March 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-233.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 18, 56, 100, 109, 182, 256, 305, 314, 372, 381, 458, 533, 615, 692, 732, 741, 824, 906, 987, 1018, 1025, 1077, 1129, 1136, 1157, 1184, 1262, 1282, 1308, 1321, 1328, 1352, 1377, 1384, 1437, 1444, 1467, 1474, 1503, 1533, 1540, 1572, 1579, 1601, 1630, 1637, 1707, 1737, 1814, 1891, 1965, 2042, 2067, 2114, 2175, 2182, 2232, 2298, 2364, 2408, 2466, 2476, 2483, 2558, 2632, 2703, 2780, 2862, 2947, 3031, 3102, 3109, 3183, 3256, 3325, 3398, 3475, 3547, 3624, 3699, 3774, 3804, 3836, 3843, 3927, 4013, 4095, 4174, 4228, 4235, 4296, 4374, 4381, 4434, 4477, 4484, 4509, 4568, 4653, 4703, 4714, 4782, 4848, 4909, 4920, 4995, 5043, 5064, 5086, 5104, 5115, 5149, 5156, 5227, 5299, 5381, 5460, 5541, 5628, 5712, 5785, 5847, 5854, 5918, 5925, 6009, 6088, 6099, 6174, 6204, 6230, 6237, 6292, 6374, 6409, 6418, 6425, 6455, 6532, 6600, 6677, 6711, 6752, 6759, 6832, 6861, 6887, 6911, 6918, 6984, 7029, 7036, 7107, 7179, 7217, 7301, 7384, 7453, 7460, 7490, 7499, 7506, 7593, 7680, 7764, 7820, 7829, 7884, 7970, 8043, 8052, 8136, 8212, 8268, 8275, 8338, 8345, 8425, 8501, 8523, 8585, 8665, 8672, 8754, 8841, 8870, 8911, 8918, 9002, 9018, 9079, 9162, 9174, 9238, 9251, 9258, 9305, 9374, 9386, 9436, 9449, 9456, 9505, 9576, 9588, 9640, 9653, 9660, 9699, 9760, 9813, 9885, 9913, 9989, 10062, 10111, 10191, 10232, 10288, 10362, 10374, 10416, 10472, 10485, 10492, 10570, 10645, 10652, 10730, 10737, 10801, 10837, 10845, 10852, 10895, 10953, 11000, 11013, 11020, 11056, 11083, 11090, 11145, 11146, 11147, 11158, 11169 ], "line_end_idx": [ 18, 56, 100, 109, 182, 256, 305, 314, 372, 381, 458, 533, 615, 692, 732, 741, 824, 906, 987, 1018, 1025, 1077, 1129, 1136, 1157, 1184, 1262, 1282, 1308, 1321, 1328, 1352, 1377, 1384, 1437, 1444, 1467, 1474, 1503, 1533, 1540, 1572, 1579, 1601, 1630, 1637, 1707, 1737, 1814, 1891, 1965, 2042, 2067, 2114, 2175, 2182, 2232, 2298, 2364, 2408, 2466, 2476, 2483, 2558, 2632, 2703, 2780, 2862, 2947, 3031, 3102, 3109, 3183, 3256, 3325, 3398, 3475, 3547, 3624, 3699, 3774, 3804, 3836, 3843, 3927, 4013, 4095, 4174, 4228, 4235, 4296, 4374, 4381, 4434, 4477, 4484, 4509, 4568, 4653, 4703, 4714, 4782, 4848, 4909, 4920, 4995, 5043, 5064, 5086, 5104, 5115, 5149, 5156, 5227, 5299, 5381, 5460, 5541, 5628, 5712, 5785, 5847, 5854, 5918, 5925, 6009, 6088, 6099, 6174, 6204, 6230, 6237, 6292, 6374, 6409, 6418, 6425, 6455, 6532, 6600, 6677, 6711, 6752, 6759, 6832, 6861, 6887, 6911, 6918, 6984, 7029, 7036, 7107, 7179, 7217, 7301, 7384, 7453, 7460, 7490, 7499, 7506, 7593, 7680, 7764, 7820, 7829, 7884, 7970, 8043, 8052, 8136, 8212, 8268, 8275, 8338, 8345, 8425, 8501, 8523, 8585, 8665, 8672, 8754, 8841, 8870, 8911, 8918, 9002, 9018, 9079, 9162, 9174, 9238, 9251, 9258, 9305, 9374, 9386, 9436, 9449, 9456, 9505, 9576, 9588, 9640, 9653, 9660, 9699, 9760, 9813, 9885, 9913, 9989, 10062, 10111, 10191, 10232, 10288, 10362, 10374, 10416, 10472, 10485, 10492, 10570, 10645, 10652, 10730, 10737, 10801, 10837, 10845, 10852, 10895, 10953, 11000, 11013, 11020, 11056, 11083, 11090, 11145, 11146, 11147, 11158, 11169, 11210 ] }
{ "red_pajama_v2": { "ccnet_original_length": 11210, "ccnet_original_nlines": 247, "rps_doc_curly_bracket": 0.0016057100147008896, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2368421107530594, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.02905702032148838, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.39638158679008484, "rps_doc_frac_unique_words": 0.5294573307037354, "rps_doc_mean_word_length": 6.3031005859375, "rps_doc_num_sentences": 78, "rps_doc_symbol_to_word_ratio": 0.021929819136857986, "rps_doc_unigram_entropy": 5.968672752380371, "rps_doc_word_count": 1290, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.007379170041531324, "rps_doc_frac_chars_top_3gram": 0.007379170041531324, "rps_doc_frac_chars_top_4gram": 0.008855000138282776, "rps_doc_books_importance": -848.9714965820312, "rps_doc_books_importance_length_correction": -848.9714965820312, "rps_doc_openwebtext_importance": -500.54412841796875, "rps_doc_openwebtext_importance_length_correction": -500.54412841796875, "rps_doc_wikipedia_importance": -462.8266296386719, "rps_doc_wikipedia_importance_length_correction": -462.8266296386719 }, "fasttext": { "dclm": 0.021289290860295296, "english": 0.4752017855644226, "fineweb_edu_approx": 2.022609233856201, "eai_general_math": 0.6851041913032532, "eai_open_web_math": 0.0972546935081482, "eai_web_code": 0.7514748573303223 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "5", "label": "Exceptionally Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
4,957,792,503,587,172,000
Skip to main content SE::Pinterest::Suggest - Pinterest Suggest Scraper Scraper Overview Scraper for search suggestions by keywords on Pinterest. The Pinterest suggestions scraper solves one of the main SEO tasks, namely the fast automated gathering of an extended semantic core. With the SE::Pinterest::Suggest scraper, you can automatically collect keyword databases from Pinterest search engine suggestions by query. Using the SE::Pinterest::Suggest scraper, you can easily and quickly scrape Pinterest suggestions by query. Thanks to the multithreading capabilities of A-Parser, the processing speed can reach 6000 queries per minute, which on average allows obtaining up to 16000 results per minute. Overview: speed of operation You can use automatic query multiplication, substitution of subqueries from files, iteration of alphanumeric combinations and lists to get the maximum possible number of results. Using result filtering, you can immediately clean up the result by removing all unnecessary junk (using negative keywords). A-Parser functionality allows you to save the scraping settings of the SE::Pinterest::Suggest scraper for further use (presets), set a scraping schedule, and much more. Saving results is possible in the form and structure you need, thanks to the built-in powerful templating engine Template Toolkit, which allows you to apply additional logic to the results and output data in various formats, including JSON, SQL, and CSV. Collected Data • Query suggestions • Type of suggestions what data does the SE::Pinterest::Suggest scraper collect Capabilities • Deep parsing using the Parse to Level feature • Selection of the type of suggestions that will be used for substitution when parsing in depth Use Cases • Gathering keyword databases Queries As queries, you need to specify search phrases, for example: write essay Football Waterfall Speak in english Cats and dogs forex cheap essay Query Substitutions You can use built-in macros for automatic substitution of subqueries from files, for example, we want to add some list of other words to each query, let's specify several main queries: essay article thesis In the query format, we will specify a macro for substitution of additional words from the file Keywords.txt, this method allows to increase the variability of queries many times over: {subs:Keywords} $query This macro will create as many additional queries as there are in the file for each original search query, which in total will give [number of original queries(domains)] x [number of queries in the Keywords file] = [total number of queries] as a result of the macro's work. For example, if the file Keywords.txt contains: buy cheap As a result, the substitution macro will turn 3 main queries into 6: buy essay cheap essay buy article cheap article buy thesis cheap thesis Output Results Examples A-Parser supports flexible result formatting thanks to the built-in templating engine Template Toolkit, which allows it to output results in any form, as well as in structured formats, such as CSV or JSON Exporting the List of Suggestions Similar to SE::Google::Suggest Output in a CSV Table Similar to SE::Google::Suggest Keyword competition Similar to SE::Google Saving in SQL format Result format: [% FOREACH results; "INSERT INTO serp VALUES('" _ query _ "', '"; suggest _ "')\n"; END %] Example of result: INSERT INTO serp VALUES('write essay', 'write essay for me') INSERT INTO serp VALUES('write essay', 'write essay online') INSERT INTO serp VALUES('write essay', 'write essay for you') INSERT INTO serp VALUES('write essay', 'write essay free') INSERT INTO serp VALUES('write essay', 'write essays') INSERT INTO serp VALUES('write essay', 'write essay conclusion') INSERT INTO serp VALUES('write essay', 'write essay on covid 19') INSERT INTO serp VALUES('write essay', 'write essay today') INSERT INTO serp VALUES('write essay', 'write essays for money') INSERT INTO serp VALUES('write essay', 'write essay online for free') ... Dumping results to JSON Similar to SE::Google::Suggest Processing results A-Parser allows you to process results directly during scraping, in this section we have provided the most popular cases for the scraper SE::Pinterest::Suggest Parse to level option Similar to SE::Google::Suggest Filtering results (using negative keywords) Similar to SE::Google::Suggest Possible settings Parameter nameDefault valueDescription Follow suggestsAllSelection of the type of suggestions that will be used for substitution during deep scraping
{ "url": "https://en.a-parser.com/docs/parsers/se-pinterest-suggest", "source_domain": "en.a-parser.com", "snapshot_id": "CC-MAIN-2024-10", "warc_metadata": { "Content-Length": "110074", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:ZRHQHHWQBHF6HBOKZ5NP2MBFNCQOSNSH", "WARC-Concurrent-To": "<urn:uuid:b5f2ac42-8d64-4438-90b8-b9dd8cdbb784>", "WARC-Date": "2024-03-02T00:26:03Z", "WARC-IP-Address": "104.26.6.13", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:DHOFJPBCQNCUGFVHF7N3GYUV2STEGROI", "WARC-Record-ID": "<urn:uuid:7f610d51-989b-4798-89e0-90527a5e89f9>", "WARC-Target-URI": "https://en.a-parser.com/docs/parsers/se-pinterest-suggest", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:350be41c-9d27-4b91-9e56-68c7350a52a9>" }, "warc_info": "isPartOf: CC-MAIN-2024-10\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February/March 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-88\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 21, 22, 73, 74, 91, 92, 531, 532, 709, 710, 739, 740, 1043, 1044, 1213, 1214, 1469, 1470, 1485, 1486, 1508, 1532, 1533, 1591, 1592, 1605, 1606, 1656, 1754, 1755, 1765, 1766, 1798, 1799, 1807, 1808, 1869, 1870, 1882, 1891, 1901, 1918, 1932, 1938, 1950, 1951, 1971, 1972, 2157, 2158, 2164, 2172, 2179, 2180, 2365, 2366, 2390, 2391, 2665, 2666, 2714, 2715, 2719, 2725, 2726, 2795, 2796, 2806, 2818, 2830, 2844, 2855, 2868, 2869, 2893, 2894, 3099, 3100, 3134, 3135, 3166, 3167, 3189, 3190, 3221, 3222, 3242, 3243, 3265, 3266, 3287, 3288, 3303, 3304, 3324, 3388, 3395, 3396, 3415, 3416, 3477, 3538, 3600, 3659, 3714, 3779, 3845, 3905, 3970, 4040, 4044, 4045, 4069, 4070, 4101, 4102, 4121, 4122, 4282, 4283, 4305, 4306, 4337, 4338, 4382, 4383, 4414, 4415, 4433, 4434, 4473 ], "line_end_idx": [ 21, 22, 73, 74, 91, 92, 531, 532, 709, 710, 739, 740, 1043, 1044, 1213, 1214, 1469, 1470, 1485, 1486, 1508, 1532, 1533, 1591, 1592, 1605, 1606, 1656, 1754, 1755, 1765, 1766, 1798, 1799, 1807, 1808, 1869, 1870, 1882, 1891, 1901, 1918, 1932, 1938, 1950, 1951, 1971, 1972, 2157, 2158, 2164, 2172, 2179, 2180, 2365, 2366, 2390, 2391, 2665, 2666, 2714, 2715, 2719, 2725, 2726, 2795, 2796, 2806, 2818, 2830, 2844, 2855, 2868, 2869, 2893, 2894, 3099, 3100, 3134, 3135, 3166, 3167, 3189, 3190, 3221, 3222, 3242, 3243, 3265, 3266, 3287, 3288, 3303, 3304, 3324, 3388, 3395, 3396, 3415, 3416, 3477, 3538, 3600, 3659, 3714, 3779, 3845, 3905, 3970, 4040, 4044, 4045, 4069, 4070, 4101, 4102, 4121, 4122, 4282, 4283, 4305, 4306, 4337, 4338, 4382, 4383, 4414, 4415, 4433, 4434, 4473, 4583 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4583, "ccnet_original_nlines": 131, "rps_doc_curly_bracket": 0.0004364000051282346, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.279720276594162, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.0699300691485405, "rps_doc_frac_lines_end_with_ellipsis": 0.007575760129839182, "rps_doc_frac_no_alph_words": 0.18764568865299225, "rps_doc_frac_unique_words": 0.3630862236022949, "rps_doc_mean_word_length": 5.4916791915893555, "rps_doc_num_sentences": 14, "rps_doc_symbol_to_word_ratio": 0.001165500027127564, "rps_doc_unigram_entropy": 4.951253890991211, "rps_doc_word_count": 661, "rps_doc_frac_chars_dupe_10grams": 0.028099169954657555, "rps_doc_frac_chars_dupe_5grams": 0.20385675132274628, "rps_doc_frac_chars_dupe_6grams": 0.16694214940071106, "rps_doc_frac_chars_dupe_7grams": 0.14380164444446564, "rps_doc_frac_chars_dupe_8grams": 0.07713498920202255, "rps_doc_frac_chars_dupe_9grams": 0.028099169954657555, "rps_doc_frac_chars_top_2gram": 0.030303029343485832, "rps_doc_frac_chars_top_3gram": 0.042424239218235016, "rps_doc_frac_chars_top_4gram": 0.06887052208185196, "rps_doc_books_importance": -387.75518798828125, "rps_doc_books_importance_length_correction": -387.75518798828125, "rps_doc_openwebtext_importance": -271.5563659667969, "rps_doc_openwebtext_importance_length_correction": -271.5563659667969, "rps_doc_wikipedia_importance": -189.11074829101562, "rps_doc_wikipedia_importance_length_correction": -189.11074829101562 }, "fasttext": { "dclm": 0.020321430638432503, "english": 0.8363703489303589, "fineweb_edu_approx": 1.4274368286132812, "eai_general_math": 0.1084849163889885, "eai_open_web_math": 0.16520845890045166, "eai_web_code": 0.07096744328737259 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.467", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "658.87", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Business", "level_3": "Management" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,799,172,495,945,870,000
Running different Programs under 1? For the discussion of Perl, Python, Ruby, and PHP and other interpreted languages. Running different Programs under 1? Post by -Ninjex- on Fri Jan 18, 2013 2:35 am ([msg=72343]see Running different Programs under 1?[/msg]) Hey guys! I have a quick question, after I give a bit of background of myself. The languages I know include: HTML, CSS, JavaScript, PHP, Python, with a splash of knowledge on SQL. So yeah, my programming background isn't the best. I plan on finishing SQL soon and then diving into either C++, Java, or Perl afterwards. I am not sure which one I will choose just yet. So throughout all of my time learning these languages, (I may be using bad sources to learn from) I haven't been able to find a way to run or call on another program with a different extenstion to execute from within another. For instance, if I had three files, test.py, test2.py, and test.pl in the same directory and tried the code below, it would not work. Assume the code below belongs to test.py and we run both python and perl as our choice for the program type. Of course the python program (test2.py) will work fine. The perl program, (test.pl) on the other hand will not. This is because it tries to pass the file and execute it as python. Does anyone know of a way to prevent this? It's been bugging me for a while now, and I want to get this stuff down better before tackling the programming challenges on this site. Code: Select all program = raw_input("Which program type would you like to start?" + "\n") starting = "Starting program" + ": " + program  if program == "python":         print(starting)         execfile("test2.py") elif program == "perl":         print(starting)         execfile("test.pl") else:         print("Program type could not be found") If possible, I need to know how to do this on a website. This will give it almost a GUI based feel, because it is running from the website. Such as having a input section for commands / parameters, and then a button to click that will execute the code. I am not sure if this is possible to do. If you know how you would go about making a GUI application that can run the different file types, that will work as well. In short, I know these languages, but I don't know how to bring them together or onto a single application or website. I wish to figure this out to test this on my apache server. I have a .sh file that checks for loadbalancing, and perl script used to dos the site. First it should execute the .sh file, and if the condition (site loadbalancing == false) is met, it needs to run the perl script. This will be used on my own apache server on another local machine; strictly pen testing. [Edit] I realized that I can use bash files with the following command: Code: Select all import os os.system('./file-name.sh') Note: I am aware of the existence of PyQt I would still like to know how to allow any file types to be executed. Thanks in advance, - Ninjex 1. No system is safe. 2. Aim for the impossible. 3. Have fun in cyberspace and meatspace. For those that know K: 0x2CD8D4F9 User avatar -Ninjex- Addict Addict   Posts: 1586 Joined: Sun Sep 02, 2012 8:02 pm Blog: View Blog (0) Re: Running different Programs under 1? Post by tgoe on Sat Jan 19, 2013 5:41 pm ([msg=72377]see Re: Running different Programs under 1?[/msg]) execfile() is only for python. You probably want the subprocess module. Although limited, os.system() will work. For the website stuff you want CGI. When it comes to language choices you'll want to pick languages that are radically different. i.e., if you're a ruby guy you won't be learning as much from python vs something lower like C or assembly or something weird like erlang :) User avatar tgoe Contributor Contributor   Posts: 711 Joined: Sun Sep 28, 2008 2:33 pm Location: q3dm7 Blog: View Blog (0) Re: Running different Programs under 1? Post by -Ninjex- on Sat Jan 19, 2013 7:23 pm ([msg=72381]see Re: Running different Programs under 1?[/msg]) tgoe wrote:execfile() is only for python. You probably want the subprocess module. Although limited, os.system() will work. For the website stuff you want CGI. When it comes to language choices you'll want to pick languages that are radically different. i.e., if you're a ruby guy you won't be learning as much from python vs something lower like C or assembly or something weird like erlang :) Hey, Tgoe! Thanks for the response. I actually looked into and tried what you said above before, only to get fails, for reason I am not sure of... Hence why I thought it wasn't possible. Here is a look at the main python script "test.py" Code: Select all #! /usr/bin/env python import subprocess import os program = raw_input("Which program type would you like to start?" + "\n") starting = ("Starting program" + ": " + program) if program == "python":         print(starting)         execfile("test2.py") elif program == "perl":         print(starting)         return_code = subprocess.call("/home/jjjj/Desktop/test.pl", shell=True) else:         print("Program type could not be found") I then run the commands below: Code: Select all jjjj@Ninjex:~/Desktop$ sudo python test.py Which program type would you like to start? perl Starting program: perl /bin/sh: 1: /home/jjjj/Desktop/test.pl: Permission denied jjjj@Ninjex:~/Desktop$ Aslo, I was looking into cgi and everything seemed well, until I went to my page after cgi-bin and I got a error message saying that I I was unable to access the page. Although that is due to my poor understanding of cgi-bin, so I will look into it a bit more so that I can fix it. [Edit] I decided to take on C++ although so far it seems really similar to JavaScript and Python, with slight exceptions to syntax of course. Thanks again, - Ninjex Last edited by -Ninjex- on Sat Jan 19, 2013 7:46 pm, edited 1 time in total. 1. No system is safe. 2. Aim for the impossible. 3. Have fun in cyberspace and meatspace. For those that know K: 0x2CD8D4F9 User avatar -Ninjex- Addict Addict   Posts: 1586 Joined: Sun Sep 02, 2012 8:02 pm Blog: View Blog (0) Re: Running different Programs under 1? Post by tgoe on Sat Jan 19, 2013 7:46 pm ([msg=72385]see Re: Running different Programs under 1?[/msg]) Don't use sudo while you're just dicking around! LOL chmod +x /home/jjjj/Desktop/test.pl (assuming the proper hashbang) Yeah... C++... Don't do it unless you're gettin paid :) User avatar tgoe Contributor Contributor   Posts: 711 Joined: Sun Sep 28, 2008 2:33 pm Location: q3dm7 Blog: View Blog (0) Re: Running different Programs under 1? Post by LoGiCaL__ on Sun Jan 20, 2013 5:37 pm ([msg=72415]see Re: Running different Programs under 1?[/msg]) tgoe wrote:Yeah... C++... Don't do it unless you're gettin paid :) I lol'd when I read that. But yeah, it's somewhat true although sometimes you got to go back to your roots and do some ninja training. User avatar LoGiCaL__ Addict Addict   Posts: 1072 Joined: Sun May 30, 2010 12:33 pm Blog: View Blog (0) Re: Running different Programs under 1? Post by -Ninjex- on Sun Jan 20, 2013 6:13 pm ([msg=72418]see Re: Running different Programs under 1?[/msg]) tgoe wrote:Don't use sudo while you're just dicking around! LOL chmod +x /home/jjjj/Desktop/test.pl (assuming the proper hashbang) Yeah... C++... Don't do it unless you're gettin paid :) You have to be kiding me... It was just the permissions on the file, thanks again. I really didn't think about it because running the perl file on it's own was fine. Now I know that when trying to access a file from another I should check permissions and make sure it's executable. I only tried to sudo because I was getting the permission denied error as you can see above. That's why I tried sudo after a regular run. As for C++ I was looking at elance.com and C++ could come into handy... Seems pretty easy to learn anyways, due to it's similarity with JavaScript and Python (so far) 1. No system is safe. 2. Aim for the impossible. 3. Have fun in cyberspace and meatspace. For those that know K: 0x2CD8D4F9 User avatar -Ninjex- Addict Addict   Posts: 1586 Joined: Sun Sep 02, 2012 8:02 pm Blog: View Blog (0) Re: Running different Programs under 1? Post by centip3de on Sun Jan 20, 2013 9:05 pm ([msg=72421]see Re: Running different Programs under 1?[/msg]) -Ninjex- wrote:You have to be kiding me... It was just the permissions on the file, thanks again. I really didn't think about it because running the perl file on it's own was fine. Now I know that when trying to access a file from another I should check permissions and make sure it's executable. I only tried to sudo because I was getting the permission denied error as you can see above. That's why I tried sudo after a regular run. As for C++ I was looking at elance.com and C++ could come into handy... Seems pretty easy to learn anyways, due to it's similarity with JavaScript and Python (so far) I'm a bit tardy to the party, but based off of your background, I would actually suggest using Java and then moving over to C++, then C, then NASM. Because C++ is forced to be backwards compatible with C, it has a bit of a wonky syntax, and can't abstract everything to the level someone like you would be used to. However, Java doesn't follow such an odd paradigm, so it might feel a bit more like home to you. Programming today is a race between software engineers striving to build bigger and better idiot-proof programs, and the Universe trying to produce bigger and better idiots. So far, the Universe is winning. -Rick Cook User avatar centip3de Addict Addict   Posts: 1479 Joined: Fri Aug 20, 2010 5:46 pm Blog: View Blog (0) Re: Running different Programs under 1? Post by -Ninjex- on Sun Jan 20, 2013 9:56 pm ([msg=72426]see Re: Running different Programs under 1?[/msg]) centip3de wrote:I'm a bit tardy to the party, but based off of your background, I would actually suggest using Java and then moving over to C++, then C, then NASM. Because C++ is forced to be backwards compatible with C, it has a bit of a wonky syntax, and can't abstract everything to the level someone like you would be used to. However, Java doesn't follow such an odd paradigm, so it might feel a bit more like home to you. Thanks, I have full days free to learning. I am at the point of OOP for C++ and still feels the same, so I could probably just switch to java and use a syntax reference when/if I need to program in C++ You and tgoe basically said the same, so I will move along to something new. Thanks for the input everyone it is much appreciated. - Ninjex 1. No system is safe. 2. Aim for the impossible. 3. Have fun in cyberspace and meatspace. For those that know K: 0x2CD8D4F9 User avatar -Ninjex- Addict Addict   Posts: 1586 Joined: Sun Sep 02, 2012 8:02 pm Blog: View Blog (0) Re: Running different Programs under 1? Post by fashizzlepop on Mon Jan 21, 2013 12:28 am ([msg=72431]see Re: Running different Programs under 1?[/msg]) If you're understanding c++ now then don't switch to java just because cent suggested it. If anything Java will be easier after learning c++ than the other way around. C++ doesn't take care of garbage collection like Java does. Also have no idea how you think python and c++ are similar. The glass is neither half-full nor half-empty; it's merely twice as big as it needs to be. User avatar fashizzlepop Developer Developer   Posts: 2303 Joined: Sat May 24, 2008 1:20 pm Blog: View Blog (0) Re: Running different Programs under 1? Post by -Ninjex- on Mon Jan 21, 2013 2:06 am ([msg=72442]see Re: Running different Programs under 1?[/msg]) fashizzlepop wrote:If you're understanding c++ now then don't switch to java just because cent suggested it. If anything Java will be easier after learning c++ than the other way around. C++ doesn't take care of garbage collection like Java does. Also have no idea how you think python and c++ are similar. Honestly to me, Python and C++ seem pretty similar, but I am weird so who knows... They are slightly different in their own ways, and I feel that c++ gives a bit more to work with. And maybe it's just me, but JavaScript, Python, and C++ feel pretty much the same in syntax. I will not drop C++, I think it is fun; I tried looking for good java tuts to come up empty handed. So in return, I just spent about 2 hours writting my first actual small program on C++ and decided to go ahead and finish seeing it through. I honestly do not see C++ taking me that long to figure out, so it shouldn't be long before I hop onto the java bandwagon anyways. 1. No system is safe. 2. Aim for the impossible. 3. Have fun in cyberspace and meatspace. For those that know K: 0x2CD8D4F9 User avatar -Ninjex- Addict Addict   Posts: 1586 Joined: Sun Sep 02, 2012 8:02 pm Blog: View Blog (0) Next Return to Interpreted Languages Who is online Users browsing this forum: No registered users and 0 guests
{ "url": "http://www.hackthissite.org/forums/viewtopic.php?p=72426", "source_domain": "www.hackthissite.org", "snapshot_id": "crawl=CC-MAIN-2015-48", "warc_metadata": { "Content-Length": "49356", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:EPNITMXBNDBDAA3K26TMUPAT4KYLIZ5N", "WARC-Concurrent-To": "<urn:uuid:f143ddbc-db06-447c-ba3d-a63f40f73aa9>", "WARC-Date": "2015-11-26T00:33:53Z", "WARC-IP-Address": "198.148.81.137", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:SKJGFBXXXGS3KBWSLZ5NOXQNAW5UDP5Z", "WARC-Record-ID": "<urn:uuid:6b0e0c94-f3a5-44e7-989c-dc5b634dff68>", "WARC-Target-URI": "http://www.hackthissite.org/forums/viewtopic.php?p=72426", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:473f7163-545b-4c83-bb82-b667c1c102d6>" }, "warc_info": "robots: classic\r\nhostname: ip-10-71-132-137.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-48\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for Nov 2015\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 36, 37, 120, 121, 157, 158, 203, 262, 263, 273, 342, 372, 443, 444, 631, 632, 858, 859, 1461, 1462, 1479, 1553, 1601, 1625, 1649, 1678, 1702, 1726, 1754, 1760, 1809, 1810, 1811, 2407, 2408, 2495, 2715, 2716, 2788, 2805, 2815, 2843, 2844, 2845, 2887, 2888, 2959, 2978, 2987, 3009, 3036, 3077, 3078, 3079, 3099, 3113, 3125, 3134, 3141, 3148, 3150, 3162, 3195, 3215, 3216, 3217, 3257, 3258, 3299, 3362, 3363, 3476, 3477, 3513, 3514, 3749, 3761, 3766, 3778, 3790, 3792, 3803, 3836, 3852, 3872, 3873, 3874, 3914, 3915, 3960, 4023, 4024, 4148, 4149, 4185, 4186, 4421, 4422, 4423, 4610, 4611, 4662, 4663, 4680, 4703, 4721, 4731, 4805, 4854, 4878, 4902, 4931, 4955, 4979, 5059, 5065, 5114, 5115, 5116, 5147, 5148, 5165, 5208, 5252, 5257, 5280, 5338, 5361, 5362, 5363, 5645, 5646, 5788, 5789, 5803, 5812, 5889, 5911, 5938, 5979, 5980, 5981, 6001, 6015, 6027, 6036, 6043, 6050, 6052, 6064, 6097, 6117, 6118, 6119, 6159, 6160, 6201, 6264, 6265, 6318, 6319, 6386, 6387, 6443, 6455, 6460, 6472, 6484, 6486, 6497, 6530, 6546, 6566, 6567, 6568, 6608, 6609, 6655, 6718, 6719, 6786, 6787, 6788, 6923, 6935, 6945, 6952, 6959, 6961, 6973, 7007, 7027, 7028, 7029, 7069, 7070, 7115, 7178, 7179, 7243, 7244, 7311, 7312, 7368, 7369, 7370, 7371, 7399, 7454, 7653, 7654, 7747, 7792, 7793, 7865, 7960, 7982, 8009, 8050, 8051, 8052, 8072, 8086, 8098, 8107, 8114, 8121, 8123, 8135, 8168, 8188, 8189, 8190, 8230, 8231, 8277, 8340, 8341, 8384, 8439, 8638, 8639, 8732, 8777, 8778, 8850, 8945, 8946, 8947, 9359, 9577, 9589, 9599, 9606, 9613, 9615, 9627, 9660, 9680, 9681, 9682, 9722, 9723, 9768, 9831, 9832, 10260, 10261, 10262, 10464, 10465, 10542, 10543, 10597, 10598, 10607, 10629, 10656, 10697, 10698, 10699, 10719, 10733, 10745, 10754, 10761, 10768, 10770, 10782, 10815, 10835, 10836, 10837, 10877, 10878, 10928, 10991, 10992, 11220, 11221, 11281, 11372, 11384, 11397, 11407, 11417, 11419, 11431, 11464, 11484, 11485, 11486, 11526, 11527, 11572, 11635, 11636, 11883, 11884, 11944, 11945, 11946, 11947, 12030, 12128, 12221, 12462, 12593, 12615, 12642, 12683, 12684, 12685, 12705, 12719, 12731, 12740, 12747, 12754, 12756, 12768, 12801, 12821, 12822, 12823, 12828, 12829, 12861, 12862, 12876, 12877 ], "line_end_idx": [ 36, 37, 120, 121, 157, 158, 203, 262, 263, 273, 342, 372, 443, 444, 631, 632, 858, 859, 1461, 1462, 1479, 1553, 1601, 1625, 1649, 1678, 1702, 1726, 1754, 1760, 1809, 1810, 1811, 2407, 2408, 2495, 2715, 2716, 2788, 2805, 2815, 2843, 2844, 2845, 2887, 2888, 2959, 2978, 2987, 3009, 3036, 3077, 3078, 3079, 3099, 3113, 3125, 3134, 3141, 3148, 3150, 3162, 3195, 3215, 3216, 3217, 3257, 3258, 3299, 3362, 3363, 3476, 3477, 3513, 3514, 3749, 3761, 3766, 3778, 3790, 3792, 3803, 3836, 3852, 3872, 3873, 3874, 3914, 3915, 3960, 4023, 4024, 4148, 4149, 4185, 4186, 4421, 4422, 4423, 4610, 4611, 4662, 4663, 4680, 4703, 4721, 4731, 4805, 4854, 4878, 4902, 4931, 4955, 4979, 5059, 5065, 5114, 5115, 5116, 5147, 5148, 5165, 5208, 5252, 5257, 5280, 5338, 5361, 5362, 5363, 5645, 5646, 5788, 5789, 5803, 5812, 5889, 5911, 5938, 5979, 5980, 5981, 6001, 6015, 6027, 6036, 6043, 6050, 6052, 6064, 6097, 6117, 6118, 6119, 6159, 6160, 6201, 6264, 6265, 6318, 6319, 6386, 6387, 6443, 6455, 6460, 6472, 6484, 6486, 6497, 6530, 6546, 6566, 6567, 6568, 6608, 6609, 6655, 6718, 6719, 6786, 6787, 6788, 6923, 6935, 6945, 6952, 6959, 6961, 6973, 7007, 7027, 7028, 7029, 7069, 7070, 7115, 7178, 7179, 7243, 7244, 7311, 7312, 7368, 7369, 7370, 7371, 7399, 7454, 7653, 7654, 7747, 7792, 7793, 7865, 7960, 7982, 8009, 8050, 8051, 8052, 8072, 8086, 8098, 8107, 8114, 8121, 8123, 8135, 8168, 8188, 8189, 8190, 8230, 8231, 8277, 8340, 8341, 8384, 8439, 8638, 8639, 8732, 8777, 8778, 8850, 8945, 8946, 8947, 9359, 9577, 9589, 9599, 9606, 9613, 9615, 9627, 9660, 9680, 9681, 9682, 9722, 9723, 9768, 9831, 9832, 10260, 10261, 10262, 10464, 10465, 10542, 10543, 10597, 10598, 10607, 10629, 10656, 10697, 10698, 10699, 10719, 10733, 10745, 10754, 10761, 10768, 10770, 10782, 10815, 10835, 10836, 10837, 10877, 10878, 10928, 10991, 10992, 11220, 11221, 11281, 11372, 11384, 11397, 11407, 11417, 11419, 11431, 11464, 11484, 11485, 11486, 11526, 11527, 11572, 11635, 11636, 11883, 11884, 11944, 11945, 11946, 11947, 12030, 12128, 12221, 12462, 12593, 12615, 12642, 12683, 12684, 12685, 12705, 12719, 12731, 12740, 12747, 12754, 12756, 12768, 12801, 12821, 12822, 12823, 12828, 12829, 12861, 12862, 12876, 12877, 12936 ] }
{ "red_pajama_v2": { "ccnet_original_length": 12936, "ccnet_original_nlines": 351, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.351102352142334, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.037183281034231186, "rps_doc_frac_lines_end_with_ellipsis": 0.014204549603164196, "rps_doc_frac_no_alph_words": 0.2685093879699707, "rps_doc_frac_unique_words": 0.2540760934352875, "rps_doc_mean_word_length": 4.379528999328613, "rps_doc_num_sentences": 179, "rps_doc_symbol_to_word_ratio": 0.004277720116078854, "rps_doc_unigram_entropy": 5.640039920806885, "rps_doc_word_count": 2208, "rps_doc_frac_chars_dupe_10grams": 0.47652533650398254, "rps_doc_frac_chars_dupe_5grams": 0.5449845194816589, "rps_doc_frac_chars_dupe_6grams": 0.5328851938247681, "rps_doc_frac_chars_dupe_7grams": 0.5111685395240784, "rps_doc_frac_chars_dupe_8grams": 0.4841778576374054, "rps_doc_frac_chars_dupe_9grams": 0.4810754954814911, "rps_doc_frac_chars_top_2gram": 0.03474663943052292, "rps_doc_frac_chars_top_3gram": 0.05211995914578438, "rps_doc_frac_chars_top_4gram": 0.06297828257083893, "rps_doc_books_importance": -1380.3990478515625, "rps_doc_books_importance_length_correction": -1380.3990478515625, "rps_doc_openwebtext_importance": -720.7920532226562, "rps_doc_openwebtext_importance_length_correction": -720.7920532226562, "rps_doc_wikipedia_importance": -325.1810302734375, "rps_doc_wikipedia_importance_length_correction": -325.1810302734375 }, "fasttext": { "dclm": 0.021120069548487663, "english": 0.9262910485267639, "fineweb_edu_approx": 1.3199059963226318, "eai_general_math": 0.019213620573282242, "eai_open_web_math": 0.23957717418670654, "eai_web_code": 0.003058789996430278 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.452", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "2", "label": "Partially Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
537,056,563,677,947,650
DOCX 9 Probability Answers By Samantha Freeman,2014-11-28 01:50 17 views 0 9 Probability Answers9 Prob     Topic 9A. Venn diagrams, tree diagrams, tables     ?Q1. (a) ??? (b) ??? (c) ???      ~????????? (d) ??? (e) ???? ??? (f) ?????     Q2. (a) 2 (b) 38 ,?? (c) (d) ??::     Q3.      Find this first … Then this … Then this.      C J A B Q4. (c) P(B′) = 0.6 23 8 15 0.2 0.1 0.3 5 4 7 0.4 :?:???44 Q5. (a) (b) (c) 14 :,?:,?:,?      S nQ6. Explain the terms mutually exclusive and independent, and construct Venn diagrams to illustrate     each concept. Q7. (a) the set B A'.      15 35 15 (b) n(B A′) = 35 35 (c) P( B A′ ) = 0.35     nQ8. The Venn diagram shows a sample space U and events A and B.      n(U) = 36, n(A) = 11, n(B) = 6 and n(A B)′ = 21.     B (a) On the diagram, shade the region (A B)′. A     (b) Find (i) n(A B); (ii) P(A B).     (c) Explain why events A and B are not mutually exclusive.     nQ9. A bag contains 10 red balls, 10 green balls and 6 white balls.      Two balls are drawn at random from the bag without replacement.      What is the probability that they are of different colours? nQ10. A coin is tossed three times. (a) How many outcomes are in the sample space?      (b) What is the probability of at least two heads? Q11. Males Females Totals     Unemployed 20 40 60      Employed 90 50 140 (i) 40/200 (ii) 110/200      Totals 110 90 200 Q12.      Boys Girls Total     Television 13 25 38     Sport 33 29 62     Total 46 54 100     (a) 38/100 (b) 71/100 (c) 13/100 Q13.      Pass Fail Total     Machine A 48 12 60     Machine B 36 4 40     Total 84 16 100      (a) P( passes inspection) = 0.84      (b) The company would like the probability that a box passes inspection to be 0.87.      Find the percentage of boxes that should be made by machine B to achieve this.      Pass Fail Total     Machine A x     Machine B ??????     Total 87 100      ?;:, ? ?;;?????,? ? :,      ?;:, ? ;???;;, ? :,      ??;?, ? ?! ,?!? so B makes 70% of boxes.     Q14. 11/36      Third apple Outcomes First apple Second apple      Red      Red Green      Red Red      Green Green      Red     Red      Green Green      Red Green      Green nQ15. A box contains 22 red apples      and 3 green apples.      Three apples are selected at random,      one after the other, without replacement.     (a) The first two apples are green. What is the probability that the third apple is red? ?;,,;,:;????(b) What is the probability that exactly two of the three apples are red? = ,?;,?;,?,??? 9B. Addition Principle and Multiplication Principle nQ1. A class has 12 boys and 8 girls. There are 4 Japanese boys and 3 Japanese girls.      If a student is selected at random, find (a) p(they are Japanese or a girl)      (b) p(they are not Japanese or a girl) nQ2. (a) For the events A and B, p(A) = 0.7, p(B) = 0.9 and p(A ? B) = 0.6. p( A?B ) = 1      (b) For the events C and D, p(C) = 0.2, p(D) = 0.8 and p(C ? D) = 0.1. p( C?D ) = 0.9      (c) For the events E and F, p(E) = 0.6, p(F) = 0.5 and p(E ? F) = 0.4. p( E?F ) = 0.6+0.5-0.4 = 0.7     nQ3. For the events A and B, p(A) = 0.5, p(B) = 0.4 and p(A ? B) = 0.9. Show that A and B are mutually exclusive.     nQ4. (a) For the events C and D, p(C) = , p(D) = ,, and p(C ? D) = 0.1. Find x, given that p(C ? D) = 0.7.      (b) For the events E and F, p(E) = ?;,, p(F) = and p(E ? F) = 0.1. Find x, given that p(E ? F) = 0.9. 0.6      Multiplication Principle     nQ5. A class has 4 boys and 8 girls. Three students are selected at random.      (a) If there is no replacement find the probability of getting three boys.      (b) If there is replacement find the probability of getting three boys. ??nQ6. For events A and B, the probabilities are p(A) = , p (B) = . ::::      (a) Calculate the value of p(A B) if events A and B are independent. ? (b) Calculate the value of p (A B) if p(B/A) = . ::     nQ7. (a) (i) For events M and N, p(M) = 0.4 and p(N) = 0.9. Calculate p(M/N) given p(M N) = 0.6.      (ii) Are events M and N independent or mutually exclusive? Explain.      (b) (i) For events A and J, p(A) = 0.2 and p(J) = 0.6. Calculate p(J/A) given p(A J) = 0.12. 0.6      (ii) independent? (Yes! p(A).p(J) = p(A J) ) mutually exclusive? (No! p(A J) ???     cQ8. (a) A class contains 13 girls and 11 boys. The teacher randomly selects four students.      Determine the probability that all four students selected are girls.      (b) A painter has 12 tins of paint. Seven tins are red and five tins are yellow.      Two tins are chosen at random. Calculate the probability that both are the same colour.      ?????,?: P(same) = p(R and R or Y and Y) = p(R).p(R/R) + p(Y).p(Y/Y) = + = = :,:::,:::?,?? nQ9. Events E and F are independent, with p(E) = and p(E F) = . Calculate p(F) and p(E F). ?? p(E F) = =p(E).p(F) = . p(F) so p(F) = ??? p(E F) = p(E) + p(F) - p(E F) = + ? = ???     nQ10. Two events A and B are such that p(A) = 0.5, p(B) = 0.4 and p(A B) = 0.3.      (a) Find p(A/B) and p(B/A)      (b) Hence, determine if the events are independent.     ?????? Combining the Addition and Multiplication Principles ????? ??? ??? ??????     nQ11. Toss a coin and roll a die. Find the probability of not a '6' or a tail.     nQ12. p(rain in Spain) is 0.4 and p(rain in KL) is 0.8. Find p(rain in at least one of those cities). nQ13. Let A and B be independent events, where p(A) = 0.6 and p(B) = x.      (a) Write down an expression for p(A ? B). 0.6      (b) (i) ??? ?? ? ?;: ? ?;; ?, ? ?;;, ?;,, ??;,, , ?;(      (ii) p(A ? B) =0.6(0.5) = 0.3      (c) Explain why A and B are not mutually exclusive. They have overlap-lah!! Why you so bodoh. cQ14*. Events A and B are independent. Given p(B) = 2p(A), and p(A B) = 0.52, find p(B).     nQ15* My friend and I are going for a Driver's Licence test. We will toss a coin to see who goes first.      We both have a 90% chance of passing. However my friend will be unsettled if I go first and fail.      He would then only have a 60% chance of passing. I don't care about him.      Find the probability at least one of us passes. (0.975)      9C. Conditional probability cQ1. For the events A and B, p(A) = 0.5, p(B) = 0.4 and p(A B) = 0.3.      ?;, Find (a) p( A B' ) = 0.2 (b) p(A given B' ). = = ?;?? nQ2. Consider events A, B such that P (A) 0, P (A) 1, P (B) 0, and P (B) 1.      In each of the situations (a), (b), (c) below state whether A and B are      mutually exclusive (M); independent (I); neither (N).     (a) P(A|B) = P(A) (b) P(A B) = 0 (c) P(A B) = P(A) nQ3.      Sample Arrive at Alarm rings space school      ? ? WL L !,      ? W ,? ??? ( W( !,? ?? ? )( (,? L ? ?) ? ?,???( )( ? ( ???? (b) Calculate the probability that Duncan will be late for school. ? = ?,??:??      ?????, (c) p(woken / late) = = ?????:?? nQ4. The events B and C are dependent, where C is the event “a student takes Chemistry”, and B is the     event “a student takes Biology”. It is known that      P(C) = 0.4, P(B | C) = 0.6, P(B | C) = 0.5.     (a) Complete the following tree diagram.     ChemistryBiology     B     C0.4     B     B     C     B     (b) Calculate the probability that a student takes Biology.     (c) Given that a student takes Biology, what is the probability that the student takes Chemistry? cQ5. In a school of 88 boys, 32 study economics (E), 28 study history (H) and 39 do not study either     subject. This information is represented in the following Venn diagram.     (88)U     E(32)H(28)     abc     39 (a) a, b, c. 21, 11, 17 ::,:(b) (i) p( studies both economics and history) = (ii) p(not history given economics) = ???,     137cQ6. Let A and B be events such that P(A) = , P(B) = and P(A B) =. 248 (a) Calculate P(A B). (b) Calculate P(A?B).     (c) Are the events A and B independent? Give a reason for your answer.     cQ7. A packet of seeds contains 40% red seeds and 60% yellow seeds. The probability that a red seed     grows is 0.9, and that a yellow seed grows is 0.8. A seed is chosen at random from the packet. (a) Complete the probability tree diagram below.     Grows0.9     Red0.4     Does not grow     Grows     Yellow     Does not grow (b) (i) Calculate the probability that the chosen seed is red and grows.     (ii) Calculate the probability that the chosen seed grows.     (iii) Given that the seed grows, calculate the probability that it is red.     cQ8.      Year 1 Year 2 Totals     History 50 35 85     Science 15 30 45     Art 45 35 80     Totals 110 100 210     :?!(?(a) (i) p(A) = ? (ii) p(Year 2 Art student) = ,??,????:????(iii) Are the events A and B independent? NO. p(A).p(B) = . ?p(A???? ,:?,:?,:?      ??::?;:??:??;::?,?? (b) (c) + = ??,:?;,??,:?;,?????      ::????::::??nQ9. (a) p(B) = ? = (b) p(A B) = ? ? = (c) p(A B) = = ????????????     nQ10. In a class, 40 students take chemistry only, 30 take physics only, 20 take both chemistry and      physics, and 60 take neither. (a) Find the probability that a student takes physics given that the student takes chemistry.     (b) Find the probability that a student takes physics given that the student does not take chemistry.     (c) State whether the events “taking chemistry” and “taking physics” are mutually exclusive,     independent, or neither. Justify your answer.     20(a) P(P(C) = A1 20;40     1 = A1 N1 3     30(b) P(P(C) = A1 30;60     1 = A1 N1 3     (c) Investigating conditions, or some relevant calculations (M1)     P is independent of C, with valid reason A1 N2     eg P(P(C) = P(P(C), P(P(C) = P(P),     205060 (ie P(P C) = P(P) P(C)) 150150150     cQ11. Two restaurants, Center and New, sell fish rolls and salads.     Let F be the event a customer chooses a fish roll.     Let S be the event a customer chooses a salad.     Let N be the event a customer chooses neither a fish roll nor a salad. In the Center restaurant P(F) = 0.31, P(S) = 0.62, P(N) = 0.14. (a) Show that P(F S) = 0.07.     (b) Given that a customer chooses a salad, find the probability they also chooses a fish roll.     (c) Are F and S independent events? Justify your answer.      At New restaurant, P(N) = 0.14. Twice as many customers choose a salad as choose a fish roll. Choosing a fish roll is independent of choosing a salad.     (d) Find the probability that a fish roll is chosen.     (a) P(F S) = 1 0.14 (= 0.86) (A1)     Choosing an appropriate formula (M1) eg P(A B) = P(A) + P(B) P(A B)     Correct substitution 1 2 3 4 5 6 eg P(F S) = 0.93 0.86 A1     P(F S) = 0.07 AG N0     Notes:There are several valid approaches. Award(A1)(M1)A1 for relevant working using any     appropriate strategy eg formula, Venn Diagram, or table.      Award no marks for the incorrect solution      P(F S) = 1 P(F) + P(S) = 1 0.93 = 0.07     (b) Using conditional probability (M1)     ?P(FS)?eg P(F S) ?P(S)~?     0.07P(F S) = (A1) 0.62      = 0.113 A1 N3     (c) F and S are not independent A1 N1     EITHER     If independent P(F S) = P(F), 0.113 0.31 R1R1 N2     OR     If independent P(F S) = P(F) P(S), 0.07 0.31 0.62 (= 0.1922) R1R1 N2     (d) Let P(F) = x     P(S) = 2P(F) (= 2x) (A1)     2For independence P(F S) = P(F)P(S) (= 2x) (R1)     Attempt to set up a quadratic equation (M1)     2eg P(F S) = P(F)P(S) P(F)P(S), 0.86 = x + 2x 2x     22x 3x + 0.86 = 0 A2     x = 0.386, x = 1.11 (A1)     P(F) = 0.386 (A1) N5     [16]     nQ12. Two fair dice are thrown and 1 2 3 4 5 6 7      the number showing on each is noted. 2 3 4 5 6 7 8      The sum of these two numbers is S. 3 4 5 6 7 8 9      5 4 6 7 8 9 10 ,:5 6 7 8 9 10 11 (a) p(S is less than 8) = ??::6 7 8 9 10 11 12 (b) at least one die shows a 3; ??     (c) at least one die shows a 3, ? given that S is less than 8. ,: Report this document For any questions or suggestions please email cust-service@docsford.com
{ "url": "http://www.docsford.com/document/4594044", "source_domain": "www.docsford.com", "snapshot_id": "crawl=CC-MAIN-2017-43", "warc_metadata": { "Content-Length": "281405", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:AXSKWODA2XATOYUBWS3LQSHZECGISRN4", "WARC-Concurrent-To": "<urn:uuid:7761b321-64fd-4bdc-873c-d4670cbf5915>", "WARC-Date": "2017-10-23T19:07:53Z", "WARC-IP-Address": "52.8.142.108", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:6PT3WQXXEVFCJJL4VHYS4GEDCPGDODR7", "WARC-Record-ID": "<urn:uuid:2d766941-4601-415a-8da3-4f2e67c0ab4f>", "WARC-Target-URI": "http://www.docsford.com/document/4594044", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:97b8a410-51e9-49b1-9821-eaa4e7e8927e>" }, "warc_info": "robots: classic\r\nhostname: ip-10-148-22-106.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-43\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for October 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 5, 6, 28, 29, 66, 77, 105, 106, 157, 158, 191, 192, 239, 240, 278, 279, 287, 288, 334, 335, 436, 437, 444, 445, 546, 547, 565, 566, 588, 589, 644, 645, 714, 715, 769, 770, 823, 824, 862, 863, 926, 927, 999, 1000, 1069, 1070, 1135, 1136, 1219, 1220, 1276, 1277, 1303, 1304, 1328, 1329, 1377, 1378, 1401, 1402, 1407, 1408, 1430, 1431, 1455, 1456, 1475, 1476, 1496, 1497, 1534, 1535, 1540, 1541, 1562, 1563, 1586, 1587, 1609, 1610, 1630, 1631, 1669, 1670, 1759, 1760, 1844, 1845, 1866, 1867, 1883, 1884, 1905, 1906, 1923, 1924, 1952, 1953, 1978, 1979, 2025, 2026, 2041, 2042, 2093, 2094, 2103, 2104, 2119, 2120, 2133, 2134, 2151, 2152, 2161, 2162, 2170, 2171, 2188, 2189, 2204, 2205, 2251, 2252, 2277, 2278, 2320, 2321, 2368, 2369, 2563, 2564, 2616, 2617, 2703, 2704, 2785, 2786, 2830, 2831, 2920, 2921, 3012, 3013, 3118, 3119, 3237, 3238, 3349, 3350, 3461, 3462, 3492, 3493, 3573, 3574, 3654, 3655, 3805, 3806, 3934, 3935, 4036, 4037, 4110, 4111, 4213, 4214, 4300, 4301, 4397, 4398, 4472, 4473, 4559, 4560, 4653, 4654, 4929, 4930, 5014, 5015, 5047, 5048, 5105, 5106, 5191, 5192, 5275, 5276, 5382, 5383, 5455, 5456, 5508, 5509, 5568, 5569, 5604, 5605, 5704, 5705, 5794, 5795, 5903, 5904, 6007, 6008, 6086, 6087, 6148, 6149, 6182, 6183, 6253, 6254, 6317, 6318, 6394, 6395, 6472, 6473, 6532, 6533, 6588, 6589, 6594, 6595, 6642, 6643, 6660, 6661, 6805, 6806, 6851, 6852, 6954, 6955, 7009, 7010, 7059, 7060, 7105, 7106, 7127, 7128, 7134, 7135, 7144, 7145, 7151, 7152, 7158, 7159, 7165, 7166, 7172, 7173, 7237, 7238, 7340, 7341, 7442, 7443, 7519, 7520, 7530, 7531, 7546, 7547, 7555, 7556, 7563, 7564, 7684, 7685, 7763, 7764, 7808, 7809, 7884, 7885, 7989, 7990, 8089, 8090, 8139, 8140, 8153, 8154, 8165, 8166, 8184, 8185, 8195, 8196, 8207, 8208, 8299, 8300, 8363, 8364, 8443, 8444, 8453, 8454, 8480, 8481, 8502, 8503, 8524, 8525, 8542, 8543, 8566, 8567, 8714, 8715, 8772, 8773, 8857, 8858, 8962, 8963, 8998, 8999, 9093, 9094, 9200, 9201, 9298, 9299, 9349, 9350, 9378, 9379, 9395, 9396, 9424, 9425, 9441, 9442, 9511, 9512, 9563, 9564, 9603, 9604, 9649, 9650, 9721, 9722, 9777, 9778, 9829, 9830, 9969, 9970, 9999, 10000, 10099, 10100, 10161, 10162, 10318, 10319, 10376, 10377, 10415, 10416, 10488, 10489, 10551, 10552, 10576, 10577, 10670, 10671, 10732, 10733, 10780, 10781, 10825, 10826, 10869, 10870, 10899, 10900, 10927, 10928, 10947, 10948, 10990, 10991, 11002, 11003, 11056, 11057, 11064, 11065, 11138, 11139, 11160, 11161, 11190, 11191, 11243, 11244, 11292, 11293, 11346, 11347, 11372, 11373, 11402, 11403, 11428, 11429, 11438, 11439, 11492, 11493, 11549, 11550, 11604, 11605, 11725, 11726, 11796, 11797, 11818, 11819, 11865 ], "line_end_idx": [ 5, 6, 28, 29, 66, 77, 105, 106, 157, 158, 191, 192, 239, 240, 278, 279, 287, 288, 334, 335, 436, 437, 444, 445, 546, 547, 565, 566, 588, 589, 644, 645, 714, 715, 769, 770, 823, 824, 862, 863, 926, 927, 999, 1000, 1069, 1070, 1135, 1136, 1219, 1220, 1276, 1277, 1303, 1304, 1328, 1329, 1377, 1378, 1401, 1402, 1407, 1408, 1430, 1431, 1455, 1456, 1475, 1476, 1496, 1497, 1534, 1535, 1540, 1541, 1562, 1563, 1586, 1587, 1609, 1610, 1630, 1631, 1669, 1670, 1759, 1760, 1844, 1845, 1866, 1867, 1883, 1884, 1905, 1906, 1923, 1924, 1952, 1953, 1978, 1979, 2025, 2026, 2041, 2042, 2093, 2094, 2103, 2104, 2119, 2120, 2133, 2134, 2151, 2152, 2161, 2162, 2170, 2171, 2188, 2189, 2204, 2205, 2251, 2252, 2277, 2278, 2320, 2321, 2368, 2369, 2563, 2564, 2616, 2617, 2703, 2704, 2785, 2786, 2830, 2831, 2920, 2921, 3012, 3013, 3118, 3119, 3237, 3238, 3349, 3350, 3461, 3462, 3492, 3493, 3573, 3574, 3654, 3655, 3805, 3806, 3934, 3935, 4036, 4037, 4110, 4111, 4213, 4214, 4300, 4301, 4397, 4398, 4472, 4473, 4559, 4560, 4653, 4654, 4929, 4930, 5014, 5015, 5047, 5048, 5105, 5106, 5191, 5192, 5275, 5276, 5382, 5383, 5455, 5456, 5508, 5509, 5568, 5569, 5604, 5605, 5704, 5705, 5794, 5795, 5903, 5904, 6007, 6008, 6086, 6087, 6148, 6149, 6182, 6183, 6253, 6254, 6317, 6318, 6394, 6395, 6472, 6473, 6532, 6533, 6588, 6589, 6594, 6595, 6642, 6643, 6660, 6661, 6805, 6806, 6851, 6852, 6954, 6955, 7009, 7010, 7059, 7060, 7105, 7106, 7127, 7128, 7134, 7135, 7144, 7145, 7151, 7152, 7158, 7159, 7165, 7166, 7172, 7173, 7237, 7238, 7340, 7341, 7442, 7443, 7519, 7520, 7530, 7531, 7546, 7547, 7555, 7556, 7563, 7564, 7684, 7685, 7763, 7764, 7808, 7809, 7884, 7885, 7989, 7990, 8089, 8090, 8139, 8140, 8153, 8154, 8165, 8166, 8184, 8185, 8195, 8196, 8207, 8208, 8299, 8300, 8363, 8364, 8443, 8444, 8453, 8454, 8480, 8481, 8502, 8503, 8524, 8525, 8542, 8543, 8566, 8567, 8714, 8715, 8772, 8773, 8857, 8858, 8962, 8963, 8998, 8999, 9093, 9094, 9200, 9201, 9298, 9299, 9349, 9350, 9378, 9379, 9395, 9396, 9424, 9425, 9441, 9442, 9511, 9512, 9563, 9564, 9603, 9604, 9649, 9650, 9721, 9722, 9777, 9778, 9829, 9830, 9969, 9970, 9999, 10000, 10099, 10100, 10161, 10162, 10318, 10319, 10376, 10377, 10415, 10416, 10488, 10489, 10551, 10552, 10576, 10577, 10670, 10671, 10732, 10733, 10780, 10781, 10825, 10826, 10869, 10870, 10899, 10900, 10927, 10928, 10947, 10948, 10990, 10991, 11002, 11003, 11056, 11057, 11064, 11065, 11138, 11139, 11160, 11161, 11190, 11191, 11243, 11244, 11292, 11293, 11346, 11347, 11372, 11373, 11402, 11403, 11428, 11429, 11438, 11439, 11492, 11493, 11549, 11550, 11604, 11605, 11725, 11726, 11796, 11797, 11818, 11819, 11865, 11890 ] }
{ "red_pajama_v2": { "ccnet_original_length": 11890, "ccnet_original_nlines": 433, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2105865478515625, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.13190272450447083, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.46094420552253723, "rps_doc_frac_unique_words": 0.2812812924385071, "rps_doc_mean_word_length": 3.602102041244507, "rps_doc_num_sentences": 324, "rps_doc_symbol_to_word_ratio": 0.0005722499918192625, "rps_doc_unigram_entropy": 5.471757888793945, "rps_doc_word_count": 1998, "rps_doc_frac_chars_dupe_10grams": 0.025566209107637405, "rps_doc_frac_chars_dupe_5grams": 0.19105182588100433, "rps_doc_frac_chars_dupe_6grams": 0.13922467827796936, "rps_doc_frac_chars_dupe_7grams": 0.09406697005033493, "rps_doc_frac_chars_dupe_8grams": 0.0411282517015934, "rps_doc_frac_chars_dupe_9grams": 0.025566209107637405, "rps_doc_frac_chars_top_2gram": 0.04474085941910744, "rps_doc_frac_chars_top_3gram": 0.011115740053355694, "rps_doc_frac_chars_top_4gram": 0.016812559217214584, "rps_doc_books_importance": -1945.5594482421875, "rps_doc_books_importance_length_correction": -1945.5594482421875, "rps_doc_openwebtext_importance": -1228.635498046875, "rps_doc_openwebtext_importance_length_correction": -1228.635498046875, "rps_doc_wikipedia_importance": -986.6683959960938, "rps_doc_wikipedia_importance_length_correction": -986.6683959960938 }, "fasttext": { "dclm": 0.9943886399269104, "english": 0.7527958750724792, "fineweb_edu_approx": 3.0042409896850586, "eai_general_math": 0.9884269833564758, "eai_open_web_math": 0.7525452375411987, "eai_web_code": 0.1603664755821228 } }
{ "free_decimal_correspondence": { "primary": { "code": "519.2", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Probabilities; or, Mathematical statistics" } }, "secondary": { "code": "372.7", "labels": { "level_1": "Social sciences", "level_2": "Education", "level_3": "Education, Elementary and Kindergarten" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,642,595,582,837,802,000
Passing Values to Functions with Arguments (negative) Passing Values to Functions with Arguments (negative) 0.0 0 #1 Hello everyone, I was playing around with arguments on this challenge and I got strange result when passing negative -1 and positive 1. On freecodecamp the rusult is 5. Tried same code on my phone and got 0 as it should be. The difference works not as I expected also: functionWithArgs(1, -1) with console.log(x -y) results in 2, which is TRUE; (-1, 1) => -2, also TRUE; but (-1, -1) => 5; What’s the catch here? Thanks. function functionWithArgs(x, y) { console.log(x + y); } functionWithArgs(1, -1); #2 I’m not really sure what you’re talking about. My best guess is that the 5 you’re seeing results from FCC running one of its own tests. Here is your function running with variations on 1 and -1: #3 Thank you for the lightning fast response, I thought I made a mistake when passing the negative number in, now I understood!
{ "url": "https://forum.freecodecamp.org/t/passing-values-to-functions-with-arguments-negative/190201", "source_domain": "forum.freecodecamp.org", "snapshot_id": "crawl=CC-MAIN-2018-30", "warc_metadata": { "Content-Length": "13586", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:M2GI3QQEEXBWZ4EEP7G62JOBGTLZBFO2", "WARC-Concurrent-To": "<urn:uuid:f326f09d-47eb-49ad-9e9b-980ef2b80ce1>", "WARC-Date": "2018-07-17T19:31:26Z", "WARC-IP-Address": "174.138.37.36", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:4MFOEEJ3Q37YWZFAWVHQRZDMUIOCUBYG", "WARC-Record-ID": "<urn:uuid:f1ac95cd-d05e-40f1-8d1f-8d36a904cd0d>", "WARC-Target-URI": "https://forum.freecodecamp.org/t/passing-values-to-functions-with-arguments-negative/190201", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:5a721a0c-6803-4715-b278-698ee23f5f11>" }, "warc_info": "robots: classic\r\nhostname: ip-10-81-219-4.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-30\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for July 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 54, 55, 109, 115, 116, 119, 120, 344, 345, 511, 512, 543, 544, 578, 600, 602, 627, 628, 631, 632, 768, 769, 828, 829, 830, 833, 834 ], "line_end_idx": [ 54, 55, 109, 115, 116, 119, 120, 344, 345, 511, 512, 543, 544, 578, 600, 602, 627, 628, 631, 632, 768, 769, 828, 829, 830, 833, 834, 958 ] }
{ "red_pajama_v2": { "ccnet_original_length": 958, "ccnet_original_nlines": 27, "rps_doc_curly_bracket": 0.002087679924443364, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3234042525291443, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.042553190141916275, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.37021276354789734, "rps_doc_frac_unique_words": 0.5874999761581421, "rps_doc_mean_word_length": 4.46875, "rps_doc_num_sentences": 11, "rps_doc_symbol_to_word_ratio": 0.012765959836542606, "rps_doc_unigram_entropy": 4.3053364753723145, "rps_doc_word_count": 160, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.1258741319179535, "rps_doc_frac_chars_dupe_6grams": 0.1258741319179535, "rps_doc_frac_chars_dupe_7grams": 0.1258741319179535, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.05454545095562935, "rps_doc_frac_chars_top_3gram": 0.0419580414891243, "rps_doc_frac_chars_top_4gram": 0.067132867872715, "rps_doc_books_importance": -99.26611328125, "rps_doc_books_importance_length_correction": -99.26611328125, "rps_doc_openwebtext_importance": -53.64959716796875, "rps_doc_openwebtext_importance_length_correction": -40.34297561645508, "rps_doc_wikipedia_importance": -37.046669006347656, "rps_doc_wikipedia_importance_length_correction": -37.046669006347656 }, "fasttext": { "dclm": 0.1642666459083557, "english": 0.9079947471618652, "fineweb_edu_approx": 0.8325732350349426, "eai_general_math": 0.7362450957298279, "eai_open_web_math": 0.21645981073379517, "eai_web_code": 0.10350722074508667 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
1,274,627,728,989,521,400
Also in the series How do I know who you are? In the opening entry of Security IQ, we discussed how with public key cryptography we get privacy and authenticity when we send messages, but what we don’t get is the identity of those at each end of an exchange. We know a specific entity can get our private message, in the form that we sent it, but we don’t know who they are. For verifying identity, we have public key infrastructure (PKI). Grandma’s Explanation Certificates How do we prove to others who we are, when we need to? In the course of normal life, most of us rely on a form of ID, be it a passport, driving license or a social security number. Computers identify themselves with certificates, which is not unlike your own passport (assuming you have one). Like passports, they are managed carefully by a central authority and valid only for a finite period of time before they have to be revalidated and reissued. The little green padlock icon that appears next to the web address bar in your browser, the one that tells you that you are browsing securely, relies on the website you are visiting holding a valid certificate to prove they are who they say they are. Certificate Authorities When you think about it, we only trust passports because we implicitly trust the authority that issued that passport – usually the government. Now, most of us feel a little uneasy when we think about whether we trust the government or not, but we don’t tend to question if the holder of a passport has not had their identity verified. We trust the passport issuing authority, therefore we trust the holder of the passport. Certificates operate in exactly the same way. For your browser to trust the website you are on (and show you the green padlock), the web server’s certificate must have been issued by an authority it trusts. If it doesn’t trust the issuing authority then it will show you the open padlock (usually red), implying that you are browsing insecurely. We call these authorities, predictably: Certificate Authorities. Chains of Trust When you trust a certificate because of who issued it, that is a chain of trust. We have a bit of a recursive problem now though. If we can only trust that we are not being duped because of a certificate issued by an authority, how do we know that authority is legit and not itself a fake? We tend to know this because most certificate authorities have certificates themselves, just like every other client, signed by other certificate authorities that we are also expected to trust. To use the passport metaphor again: we trust a passport because we trust the passport office, we trust the passport office because it is regulated by the government and we trust the government (ha!) because they are elected. If the head of state has a certificate, then that certificate signed the government department’s certificate, which signed the passport office’s certificate, which signed your own certificate. This signing process is similar to the signing process we used to send encrypted messages earlier in the series. Signatures are made with each entity’s private key (known only to themselves) and can be validated by everybody else in the chain with their matching public key. Root and Intermediate Certificate Authorities The authority at the root of the chain of trust is called the Root Certificate Authority (RootCA) and all the others are Intermediate Certificate Authorities, intermediaries with rights to grant new certificates and trusted because of who the root authority is. We still haven’t solved the recursive problem, have we? In the above image, who signs the head of state’s certificate? This is where the metaphor falls down a bit. Computer’s don’t have elections to decide who can be a root certificate authority. As amusing as that idea might be, it’s impractical. The RootCA actually signs their own certificate with their own private key. You just have to trust it. That makes RootCAs very important and potentially very dangerous. If a RootCA ever gets compromised, every identity we trust based on it is also compromised. In reality, a RootCA only signs a very restricted, highly-regulated set of intermediate CA certificates away from the internet (air-gapped from other computers), then its ports get filled with glue and it gets locked in a safe! The intermediates tend to be the authorities actually doing the grunt work. Coding your own PKI Keeping with the spirit of the Security IQ series, I’ve written a disposable program to demonstrate some of the primitives involved in developing PKI. As I’ve already mentioned, certificates are most commonly used for securing web server communications with TLS (transport layer security), sometimes still called SSL. However, I want to deal with TLS/SSL in a separate blog post so this demo program will attempt to be a stripped-down imitation of how new certificates are signed and granted by certificate authorities. pkiverify Like pkcrypto before it, pkiverify is written in Go and involves two instances of the program talking to each other, one acting as the RootCA and the other as a client requesting a certificate. I’ve limited the chain of trust to two links to simplify things, but the whole process is recursive. Note: The usual disclaimer applies. This is a throwaway program I wrote to explore the Go standard library primitives in this area. I’m not trying to write production quality code here or even anything that is particularly useful. Its sole purpose is to be a learning exercise, so it’s best to read it in that spirit. The full code listing is available here: GitHub Let’s look at the help: pkiverify help NAME: pkiverify - Create and verify certificates. USAGE: pkiverify [global options] command [command options] [arguments...] VERSION: 0.0.0 COMMANDS: rootca, r Start a RootCA server and respond to certificate requests. newcert, n Create new certificate, signed by the given RootCA. help, h Shows a list of commands or help for one command GLOBAL OPTIONS: --help, -h show help --version, -v print the version There are two commands: rootca and newcert. The former starts a server listening for a certificate signing request and the latter issues the request and validates the returned certificate. pkiverify help rootca NAME: pkiverify rootca - Start a RootCA server and respond to certificate requests. USAGE: pkiverify rootca [command options] [arguments...] OPTIONS: --port value The socket port to listen to requests on. (default: "cert") pkiverify help newcert NAME: pkiverify newcert - Create new certificate, signed by the given RootCA. USAGE: pkiverify newcert [command options] [arguments...] OPTIONS: --rootca value Address of a RootCA server that will sign the new certificate. Initializing the RootCA // Generate a self-signed root certificate and start listening for certificate signing requests on the given port. func startRootCAServer(port string) error { // Create 2048-bit private key for RootCA instance privateKey, err := rsa.GenerateKey(rand.Reader, 2048) fmt.Println("Created RSA key pair for RootCA.") // Create root certificate template notBefore := time.Now() notAfter := notBefore.Add(time.Hour * 24 * 365) serialNumberLimit := new(big.Int).Lsh(big.NewInt(1), 128) serialNumber, err := rand.Int(rand.Reader, serialNumberLimit) if err != nil { return cli.NewExitError(err, -1) } template := x509.Certificate { SerialNumber: serialNumber, Subject: pkix.Name { Organization: []string{"AnchorLoop"}, }, NotBefore: notBefore, NotAfter: notAfter, KeyUsage: x509.KeyUsageKeyEncipherment | x509.KeyUsageDigitalSignature | x509.KeyUsageCertSign, ExtKeyUsage: []x509.ExtKeyUsage{x509.ExtKeyUsageAny}, BasicConstraintsValid: true, IsCA: true, } // Create self-signed root certificate derBytes, err := x509.CreateCertificate(rand.Reader, &template, &template, &privateKey.PublicKey, privateKey) if err != nil { return cli.NewExitError(err, -1) } fmt.Println("Created Self-Signed Root Certificate.") rootCert, err := x509.ParseCertificate(derBytes) if err != nil { return cli.NewExitError(err, -1) } err = handleCertificateRequest(port, rootCert, privateKey) if err != nil { return cli.NewExitError(err, -1) } return nil } To create the RootCA server we first create an RSA public-private key pair. The private key is critical to the RootCA’s function, as it is the secret that will sign any certificates it issues. We then create a certificate to be the root certificate, signed by our own private key (self-signed). The public key actually becomes part of the certificate. We have quite fine control over what rights and capabilities a certificate has, see the KeyUsage property. The usage we are most interested in is x509.KeyUsageCertSign, the whole point of this certificate is to be the root that signs others. Once that is created, we move on to handling certificate signing requests (CSRs). Handling a Certificate Signing Request (CSR) // Listen for and respond to any certificate signing requests on the given port. Create a new client certificate signed // by the RootCA private key and send both the new and root certificates back to the client. func handleCertificateRequest(port string, rootCert *x509.Certificate, privateKey *rsa.PrivateKey) error { // Listen, wait and accept connection fmt.Println("Listening for Certificate Signing Request on port", port) ln, err := net.Listen("tcp", ":" + port) if err != nil { return err } conn, err := ln.Accept() if err != nil { return err } defer conn.Close() fmt.Println("Accepted Certificate Signing Request.") // Read two-byte header containing size of the ASN1 data of the certificate request reader := bufio.NewReader(conn) header := make([]byte, 2) _, err = reader.Read(header) if err != nil { return err } asn1DataSize := binary.LittleEndian.Uint16(header) // Now read that number of bytes and parse the certificate request asn1Data := make([]byte, asn1DataSize) _, err = reader.Read(asn1Data) if err != nil { return err } fmt.Println("Received Certificate Signing Request.") certReq, err := x509.ParseCertificateRequest(asn1Data) if err != nil { return err } // Create template for certificate creation, uses properties from the request and root certificate. serialNumberLimit := new(big.Int).Lsh(big.NewInt(1), 128) serialNumber, err := rand.Int(rand.Reader, serialNumberLimit) if err != nil { return err } template := x509.Certificate { Signature: certReq.Signature, SignatureAlgorithm: certReq.SignatureAlgorithm, PublicKeyAlgorithm: certReq.PublicKeyAlgorithm, PublicKey: certReq.PublicKey, SerialNumber: serialNumber, Issuer: rootCert.Subject, Subject: certReq.Subject, NotBefore: time.Now(), NotAfter: time.Now().Add(time.Hour * 24 * 365), KeyUsage: x509.KeyUsageDigitalSignature, ExtKeyUsage: []x509.ExtKeyUsage{x509.ExtKeyUsageClientAuth}, } // Create certificate from template and root certificate, signed by the RootCA's private key. certData, err := x509.CreateCertificate(rand.Reader, &template, rootCert, template.PublicKey, privateKey) if err != nil { return err } fmt.Println("Created Certificate from CSR, signed by RootCA's Private Key.") // Transmit newly created certificate data back over the connection. writer := bufio.NewWriter(conn) // The number of bytes that make up the new certificate go first. certHeader := make([]byte, 2) binary.LittleEndian.PutUint16(certHeader, uint16(len(certData))) _, err = writer.Write(certHeader) if err != nil { return err } // Now write the certificate data. _, err = writer.Write(certData) if err != nil { return err } // Now write the size of the root certificate, which will be needed to validate the new certificate rootCertHeader := make([]byte, 2) binary.LittleEndian.PutUint16(rootCertHeader, uint16(len(rootCert.Raw))) _, err = writer.Write(rootCertHeader) if err != nil { return err } // Now write the root certificate data. _, err = writer.Write(rootCert.Raw) if err != nil { return err } // Flush all the data. err = writer.Flush() if err != nil { return err } fmt.Println("Transmitted client Certificate and Root Certificate back to client.") return nil } Once it has its own self-signed certificate, the RootCA server waits for a certificate signing request on a given port. Once it accepts one, reads it off the wire and parses it, it uses a mixture of properties from the request and the root certificate to generate a new certificate, signed by the RootCA’s private key. Notice how this client certificate has much-reduced KeyUsage rights when compared to the root certificate, this one is not intended to be used to sign other certificates. All certificates have a finite lifetime, all certificates produced by this program expire after a year. This is controlled by the NotBefore and NotAfter properties. In the real world, it is common for certificates to be valid for several years unless they are revoked. Both the client certificate and root certificate then get transferred back to the client, as both are needed for validating the chain of trust. The private key of the RootCA remains known only to itself. Sending a Certificate Signing Request (CSR) // Create a new client certificate by sending a certificate signing request to the given RootCA. func newSignedCertificate(rootCA string) error { // Create 2048-bit private key for the new certificate privateKey, err := rsa.GenerateKey(rand.Reader, 2048) if err != nil { return cli.NewExitError(err, -1) } fmt.Println("Created RSA key pair for client.") // Create CSR template certReqTemplate := x509.CertificateRequest { SignatureAlgorithm: x509.SHA256WithRSA, Subject: pkix.Name { Organization: []string{"AnchorLoop Client"}, }, } // Create certificate request derBytes, err := x509.CreateCertificateRequest(rand.Reader, &certReqTemplate, privateKey) if err != nil { return cli.NewExitError(err, -1) } fmt.Println("Created Certificate Signing Request for client.") // Dial RootCA server and transmit certificate request conn, err := net.Dial("tcp", rootCA) if err != nil { return cli.NewExitError(err, -1) } defer conn.Close() fmt.Println("Successfully connected to Root Certificate Authority.") writer := bufio.NewWriter(conn) // Send two-byte header containing the number of ASN1 bytes transmitted. header := make([]byte, 2) binary.LittleEndian.PutUint16(header, uint16(len(derBytes))) _, err = writer.Write(header) if err != nil { return cli.NewExitError(err, -1) } // Now send the certificate request data _, err = writer.Write(derBytes) if err != nil { return cli.NewExitError(err, -1) } err = writer.Flush() if err != nil { return cli.NewExitError(err, -1) } fmt.Println("Transmitted Certificate Signing Request to RootCA.") // The RootCA will now send our signed certificate back for us to read. reader := bufio.NewReader(conn) // Read header containing the size of the ASN1 data. certHeader := make([]byte, 2) _, err = reader.Read(certHeader) if err != nil { return cli.NewExitError(err, -1) } certSize := binary.LittleEndian.Uint16(certHeader) // Now read the certificate data. certBytes := make([]byte, certSize) _, err = reader.Read(certBytes) if err != nil { return cli.NewExitError(err, -1) } fmt.Println("Received new Certificate from RootCA.") newCert, err := x509.ParseCertificate(certBytes) if err != nil { return cli.NewExitError(err, -1) } // Finally, the RootCA will send its own certificate back so that we can validate the new certificate. rootCertHeader := make([]byte, 2) _, err = reader.Read(rootCertHeader) if err != nil { return cli.NewExitError(err, -1) } rootCertSize := binary.LittleEndian.Uint16(rootCertHeader) // Now read the certificate data. rootCertBytes := make([]byte, rootCertSize) _, err = reader.Read(rootCertBytes) if err != nil { return cli.NewExitError(err, -1) } fmt.Println("Received Root Certificate from RootCA.") rootCert, err := x509.ParseCertificate(rootCertBytes) if err != nil { return cli.NewExitError(err, -1) } err = validateCertificate(newCert, rootCert) if err != nil { return cli.NewExitError(err, -1) } return nil } Like the RootCA, the client needs a public-private key pair, this is generated first. Then a certificate signing request is created, which contains the client’s public key. The job of actually creating the new certificate falls to the RootCA because it needs to be signed by its private key, the client can only create the request and ask for a new certificate. This request is sent to the RootCA and two certificates are returned, the new client certificate for our request and the certificate of the RootCA. We can then validate the client certificate is legit by using the root certificate. Validating the client certificate // Validate the new certificate by verifying the chain of trust between it and the certificate of the RootCA that // signed it. func validateCertificate(newCert *x509.Certificate, rootCert *x509.Certificate) error { roots := x509.NewCertPool() roots.AddCert(rootCert) verifyOptions := x509.VerifyOptions { Roots: roots, KeyUsages: []x509.ExtKeyUsage{x509.ExtKeyUsageClientAuth}, } _, err := newCert.Verify(verifyOptions) if err != nil { fmt.Println("Failed to verify chain of trust.") return err } fmt.Println("Successfully verified chain of trust.") return nil } Short and sweet. There are multiple ways to verify certificates, so Go provides an x509.VerifyOptions data structure. We just add the root certificate to the list of roots and pass that into the Verify method of the client certificate. A demo When we run two instances of pkiverify, this is what we see: pkiverify rootca --port 35196 Created RSA key pair for RootCA. Created Self-Signed Root Certificate. Listening for Certificate Signing Request on port 35196 Accepted Certificate Signing Request. Received Certificate Signing Request. Created Certificate from CSR, signed by RootCA's Private Key. Transmitted client Certificate and Root Certificate back to client. pkiverify newcert --rootca localhost:35196 Created RSA key pair for client. Created Certificate Signing Request for client. Successfully connected to Root Certificate Authority. Transmitted Certificate Signing Request to RootCA. Received new Certificate from RootCA. Received Root Certificate from RootCA. Successfully verified chain of trust. Not the most exciting output in the world, but we can see that the RootCA responded to the CSR and sent back a new certificate that passed verification on the client-side. Next time The certificates that your own web browser relies on for validating chains of trust are likely to be on your computer already, they tend to get distributed with the operating system itself as part of the installation media. It’s useful to know how these chains of trust are built, but you’re quite unlikely to have to build anything even remotely like this yourself. That’s mainly because the number of world-scale trusted CAs is quite small and you’re unlikely to be one of them. You would know a lot more about this than I do if you were. Next time, we’re going to look at something a little more practical that builds on top of what we have covered here. Something that the average developer is quite likely to need to implement themselves: TLS (transport layer security) for encrypting the HTTP traffic between your clients and web services. See you then. About the Author Kirk MacPhee An experienced software developer and technical lead, specializing in automation technologies and their application. Leave a Reply Fill in your details below or click an icon to log in: WordPress.com Logo You are commenting using your WordPress.com account. Log Out /  Change ) Google+ photo You are commenting using your Google+ account. Log Out /  Change ) Twitter picture You are commenting using your Twitter account. Log Out /  Change ) Facebook photo You are commenting using your Facebook account. Log Out /  Change ) Connecting to %s
{ "url": "https://anchorloop.com/2017/09/25/security-iq-ii-public-key-infrastructure/", "source_domain": "anchorloop.com", "snapshot_id": "crawl=CC-MAIN-2018-51", "warc_metadata": { "Content-Length": "83304", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:WLOYTQAWKJ63XKOWS4RG6I3BIHO563UU", "WARC-Concurrent-To": "<urn:uuid:e883f6ea-13bb-46e2-a847-26d7400103d9>", "WARC-Date": "2018-12-19T00:18:17Z", "WARC-IP-Address": "192.0.78.24", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:AW72QHKV6MV4FKVJVDWFIJ2ZI7HCGLPU", "WARC-Record-ID": "<urn:uuid:33a04417-08dd-4073-ab88-be0326b90d72>", "WARC-Target-URI": "https://anchorloop.com/2017/09/25/security-iq-ii-public-key-infrastructure/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:aef0317c-2e4a-49ba-ab5e-a94deaa8951c>" }, "warc_info": "isPartOf: CC-MAIN-2018-51\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for December 2018\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-182-139-153.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 0.11-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 19, 20, 47, 48, 442, 443, 465, 466, 479, 480, 661, 662, 932, 933, 1184, 1185, 1209, 1210, 1633, 1634, 1980, 1981, 2046, 2047, 2063, 2064, 2548, 2549, 2967, 2968, 3243, 3244, 3290, 3291, 3553, 3554, 3956, 3957, 4419, 4420, 4440, 4441, 4961, 4962, 4972, 4973, 5268, 5269, 5587, 5588, 5636, 5637, 5661, 5662, 5677, 5683, 5730, 5731, 5738, 5809, 5810, 5819, 5828, 5829, 5839, 5915, 5984, 6050, 6051, 6067, 6095, 6131, 6132, 6321, 6322, 6344, 6350, 6431, 6432, 6439, 6492, 6493, 6502, 6579, 6602, 6608, 6683, 6684, 6691, 6745, 6746, 6755, 6837, 6838, 6862, 6863, 6978, 7022, 7077, 7135, 7187, 7188, 7228, 7256, 7308, 7370, 7436, 7456, 7497, 7503, 7538, 7574, 7603, 7653, 7664, 7694, 7722, 7826, 7888, 7925, 7945, 7951, 7952, 7995, 8109, 8129, 8170, 8176, 8233, 8286, 8306, 8347, 8353, 8354, 8418, 8438, 8479, 8485, 8486, 8501, 8503, 8504, 8697, 8698, 9099, 9100, 9182, 9183, 9228, 9229, 9349, 9442, 9549, 9591, 9666, 9711, 9731, 9750, 9756, 9785, 9805, 9824, 9830, 9853, 9910, 9911, 9999, 10035, 10065, 10098, 10118, 10137, 10143, 10198, 10199, 10270, 10313, 10348, 10368, 10387, 10393, 10450, 10509, 10529, 10548, 10554, 10555, 10659, 10721, 10787, 10807, 10826, 10832, 10867, 10905, 10961, 10962, 11018, 11056, 11057, 11093, 11127, 11161, 11192, 11248, 11297, 11366, 11372, 11373, 11471, 11581, 11601, 11620, 11626, 11707, 11708, 11781, 11817, 11887, 11921, 11990, 12028, 12048, 12067, 12073, 12112, 12148, 12168, 12187, 12193, 12297, 12335, 12412, 12454, 12474, 12493, 12499, 12543, 12583, 12603, 12622, 12628, 12655, 12680, 12700, 12719, 12725, 12812, 12813, 12828, 12830, 12831, 13321, 13322, 13591, 13592, 13796, 13797, 13841, 13842, 13939, 13988, 14047, 14105, 14125, 14166, 14172, 14224, 14225, 14252, 14301, 14349, 14378, 14435, 14446, 14452, 14453, 14487, 14581, 14601, 14642, 14648, 14715, 14716, 14775, 14816, 14836, 14877, 14883, 14906, 14979, 14980, 15016, 15093, 15123, 15188, 15222, 15242, 15283, 15289, 15334, 15370, 15390, 15431, 15437, 15462, 15482, 15523, 15529, 15599, 15600, 15676, 15712, 15769, 15803, 15840, 15860, 15901, 15907, 15962, 16000, 16040, 16076, 16096, 16137, 16143, 16200, 16253, 16273, 16314, 16320, 16321, 16428, 16466, 16507, 16527, 16568, 16574, 16637, 16675, 16723, 16763, 16783, 16824, 16830, 16888, 16946, 16966, 17007, 17013, 17014, 17063, 17083, 17124, 17130, 17131, 17146, 17148, 17149, 17511, 17512, 17744, 17745, 17779, 17780, 17894, 17908, 17996, 18028, 18056, 18098, 18120, 18187, 18193, 18194, 18238, 18258, 18314, 18333, 18339, 18396, 18397, 18412, 18414, 18415, 18651, 18652, 18659, 18660, 18721, 18722, 18752, 18785, 18823, 18879, 18917, 18955, 19017, 19085, 19128, 19161, 19209, 19263, 19314, 19352, 19391, 19429, 19430, 19602, 19603, 19613, 19614, 20155, 20156, 20461, 20462, 20476, 20477, 20507, 20508, 20625, 20626, 20640, 20641, 20696, 20697, 20716, 20717, 20790, 20791, 20805, 20806, 20873, 20874, 20890, 20891, 20958, 20959, 20974, 20975, 21043, 21044 ], "line_end_idx": [ 19, 20, 47, 48, 442, 443, 465, 466, 479, 480, 661, 662, 932, 933, 1184, 1185, 1209, 1210, 1633, 1634, 1980, 1981, 2046, 2047, 2063, 2064, 2548, 2549, 2967, 2968, 3243, 3244, 3290, 3291, 3553, 3554, 3956, 3957, 4419, 4420, 4440, 4441, 4961, 4962, 4972, 4973, 5268, 5269, 5587, 5588, 5636, 5637, 5661, 5662, 5677, 5683, 5730, 5731, 5738, 5809, 5810, 5819, 5828, 5829, 5839, 5915, 5984, 6050, 6051, 6067, 6095, 6131, 6132, 6321, 6322, 6344, 6350, 6431, 6432, 6439, 6492, 6493, 6502, 6579, 6602, 6608, 6683, 6684, 6691, 6745, 6746, 6755, 6837, 6838, 6862, 6863, 6978, 7022, 7077, 7135, 7187, 7188, 7228, 7256, 7308, 7370, 7436, 7456, 7497, 7503, 7538, 7574, 7603, 7653, 7664, 7694, 7722, 7826, 7888, 7925, 7945, 7951, 7952, 7995, 8109, 8129, 8170, 8176, 8233, 8286, 8306, 8347, 8353, 8354, 8418, 8438, 8479, 8485, 8486, 8501, 8503, 8504, 8697, 8698, 9099, 9100, 9182, 9183, 9228, 9229, 9349, 9442, 9549, 9591, 9666, 9711, 9731, 9750, 9756, 9785, 9805, 9824, 9830, 9853, 9910, 9911, 9999, 10035, 10065, 10098, 10118, 10137, 10143, 10198, 10199, 10270, 10313, 10348, 10368, 10387, 10393, 10450, 10509, 10529, 10548, 10554, 10555, 10659, 10721, 10787, 10807, 10826, 10832, 10867, 10905, 10961, 10962, 11018, 11056, 11057, 11093, 11127, 11161, 11192, 11248, 11297, 11366, 11372, 11373, 11471, 11581, 11601, 11620, 11626, 11707, 11708, 11781, 11817, 11887, 11921, 11990, 12028, 12048, 12067, 12073, 12112, 12148, 12168, 12187, 12193, 12297, 12335, 12412, 12454, 12474, 12493, 12499, 12543, 12583, 12603, 12622, 12628, 12655, 12680, 12700, 12719, 12725, 12812, 12813, 12828, 12830, 12831, 13321, 13322, 13591, 13592, 13796, 13797, 13841, 13842, 13939, 13988, 14047, 14105, 14125, 14166, 14172, 14224, 14225, 14252, 14301, 14349, 14378, 14435, 14446, 14452, 14453, 14487, 14581, 14601, 14642, 14648, 14715, 14716, 14775, 14816, 14836, 14877, 14883, 14906, 14979, 14980, 15016, 15093, 15123, 15188, 15222, 15242, 15283, 15289, 15334, 15370, 15390, 15431, 15437, 15462, 15482, 15523, 15529, 15599, 15600, 15676, 15712, 15769, 15803, 15840, 15860, 15901, 15907, 15962, 16000, 16040, 16076, 16096, 16137, 16143, 16200, 16253, 16273, 16314, 16320, 16321, 16428, 16466, 16507, 16527, 16568, 16574, 16637, 16675, 16723, 16763, 16783, 16824, 16830, 16888, 16946, 16966, 17007, 17013, 17014, 17063, 17083, 17124, 17130, 17131, 17146, 17148, 17149, 17511, 17512, 17744, 17745, 17779, 17780, 17894, 17908, 17996, 18028, 18056, 18098, 18120, 18187, 18193, 18194, 18238, 18258, 18314, 18333, 18339, 18396, 18397, 18412, 18414, 18415, 18651, 18652, 18659, 18660, 18721, 18722, 18752, 18785, 18823, 18879, 18917, 18955, 19017, 19085, 19128, 19161, 19209, 19263, 19314, 19352, 19391, 19429, 19430, 19602, 19603, 19613, 19614, 20155, 20156, 20461, 20462, 20476, 20477, 20507, 20508, 20625, 20626, 20640, 20641, 20696, 20697, 20716, 20717, 20790, 20791, 20805, 20806, 20873, 20874, 20890, 20891, 20958, 20959, 20974, 20975, 21043, 21044, 21060 ] }
{ "red_pajama_v2": { "ccnet_original_length": 21060, "ccnet_original_nlines": 442, "rps_doc_curly_bracket": 0.0042734998278319836, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2847307622432709, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.01180231012403965, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.26801082491874695, "rps_doc_frac_unique_words": 0.2585258483886719, "rps_doc_mean_word_length": 5.698936462402344, "rps_doc_num_sentences": 308, "rps_doc_symbol_to_word_ratio": 0.0007376400171779096, "rps_doc_unigram_entropy": 5.535395622253418, "rps_doc_word_count": 2727, "rps_doc_frac_chars_dupe_10grams": 0.01351264026015997, "rps_doc_frac_chars_dupe_5grams": 0.17836689949035645, "rps_doc_frac_chars_dupe_6grams": 0.11710958182811737, "rps_doc_frac_chars_dupe_7grams": 0.08879736810922623, "rps_doc_frac_chars_dupe_8grams": 0.055337488651275635, "rps_doc_frac_chars_dupe_9grams": 0.019818540662527084, "rps_doc_frac_chars_top_2gram": 0.009651890024542809, "rps_doc_frac_chars_top_3gram": 0.015443019568920135, "rps_doc_frac_chars_top_4gram": 0.02612444944679737, "rps_doc_books_importance": -1622.7891845703125, "rps_doc_books_importance_length_correction": -1622.7891845703125, "rps_doc_openwebtext_importance": -909.16162109375, "rps_doc_openwebtext_importance_length_correction": -909.16162109375, "rps_doc_wikipedia_importance": -520.2197265625, "rps_doc_wikipedia_importance_length_correction": -520.2197265625 }, "fasttext": { "dclm": 0.799806535243988, "english": 0.7919060587882996, "fineweb_edu_approx": 1.9730453491210938, "eai_general_math": 0.04510403051972389, "eai_open_web_math": 0.05099916085600853, "eai_web_code": 0.1850731372833252 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.82", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-7,483,161,823,726,707,000
thofmann / releng / fedora-scm-requests Forked from releng/fedora-scm-requests 3 years ago A ticket queue for Fedora SCM admin requests | https://fedoraproject.org/wiki/Changes/ArbitraryBranching Members 1 fedora-scm-requests A ticket queue for dist-git requests and a repository for Bugzilla assignee overrides Tickets For "dist-git" Requests All tickets must be submitted using either fedpkg request-repo or fedpkg request-branch. This allows other tooling to programmatically process tickets in a format it expects. Repository Structure The root of the repository contains a list of directories representing the namespaces in Pagure over dist-git (e.g. rpms). Within those directories, YAML files will be named after components. The contents of those YAML files will be in the format of a dictionary, with each key being an option for the repo. Bugzilla Assignee Overrides This repository is used to override the default Bugzilla ticket assignees on a component in a product (e.g "Fedora EPEL" or "Fedora"). By default, the Bugzilla ticket assignee is the main admin of the component (e.g. rpms/python-requests) in Pagure over dist-git. To override the default assignee in Bugzilla, find/or create the YAML file that configures the repository you want to set (e.g. rpms/python-requests). The bugzilla_contact key in the YAML file is used to override this with a dictionary, where each key represents a product (e.g. "Fedora EPEL" or "Fedora"). Each value should specify the FAS username or FAS group (groups are signified by starting with a "@") of the default Bugzilla ticket assignee for the component in that product. Anitya setting This repository allows you to specify the level to monitoring you would like your package to have with anitya. Setting or changing this setting is easy, fork this project, clone the git repository, add or find your package (see the different under the folders corresponding to each namespace: container, modules, rpms) and add or edit to anitya setting which can be any one of: monitoring: monitoring-with-scratch monitoring: no-monitoring monitoring: monitoring the-new-hotness will then use this setting to know if new released should be monitored or not and if a scratch build should be attempted or not.
{ "url": "https://pagure.io/fork/thofmann/releng/fedora-scm-requests", "source_domain": "pagure.io", "snapshot_id": "crawl=CC-MAIN-2021-49", "warc_metadata": { "Content-Length": "19684", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:OU2DIYCZJ5BUDIJXYPG7MJD4XRIDTITJ", "WARC-Concurrent-To": "<urn:uuid:276cec26-53af-4dd7-bbbc-11af502a444f>", "WARC-Date": "2021-11-29T00:38:12Z", "WARC-IP-Address": "8.43.85.76", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:HPBZLIKHDNWP4DDLGM4IKHV3DLGJAPWU", "WARC-Record-ID": "<urn:uuid:2ecc9743-19e5-4e85-b8c9-c034a769608f>", "WARC-Target-URI": "https://pagure.io/fork/thofmann/releng/fedora-scm-requests", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:0f54ce9c-7e58-4b1a-be7e-591c2747a446>" }, "warc_info": "isPartOf: CC-MAIN-2021-49\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November/December 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-99\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 40, 41, 92, 197, 207, 208, 228, 229, 315, 316, 348, 349, 524, 525, 546, 547, 855, 856, 884, 885, 1149, 1150, 1634, 1635, 1650, 1651, 2029, 2030, 2066, 2092, 2115, 2116 ], "line_end_idx": [ 40, 41, 92, 197, 207, 208, 228, 229, 315, 316, 348, 349, 524, 525, 546, 547, 855, 856, 884, 885, 1149, 1150, 1634, 1635, 1650, 1651, 2029, 2030, 2066, 2092, 2115, 2116, 2260 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2260, "ccnet_original_nlines": 32, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.36343613266944885, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.02422907017171383, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.19162996113300323, "rps_doc_frac_unique_words": 0.4613095223903656, "rps_doc_mean_word_length": 5.386904716491699, "rps_doc_num_sentences": 22, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.659482002258301, "rps_doc_word_count": 336, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.03093923069536686, "rps_doc_frac_chars_dupe_6grams": 0.03093923069536686, "rps_doc_frac_chars_dupe_7grams": 0.03093923069536686, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.00828729011118412, "rps_doc_frac_chars_top_3gram": 0.01325966976583004, "rps_doc_frac_chars_top_4gram": 0.016574589535593987, "rps_doc_books_importance": -230.30320739746094, "rps_doc_books_importance_length_correction": -230.30320739746094, "rps_doc_openwebtext_importance": -128.83282470703125, "rps_doc_openwebtext_importance_length_correction": -128.83282470703125, "rps_doc_wikipedia_importance": -83.93566131591797, "rps_doc_wikipedia_importance_length_correction": -83.93566131591797 }, "fasttext": { "dclm": 0.08683508634567261, "english": 0.7803098559379578, "fineweb_edu_approx": 2.2175991535186768, "eai_general_math": 0.872286856174469, "eai_open_web_math": 0.47534477710723877, "eai_web_code": 0.8500717282295227 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
5,899,040,440,788,465,000
Erkan Güzeler Erkan Guzeler's Blog Erkan Guzeler's Blog Spring Boot: Usage of Liquibase Photo by Sangga Rima Roman Selia on Unsplash Spring Boot: Usage of Liquibase Erkan Güzeler's photo Erkan Güzeler ·May 28, 2022· 5 min read Subscribe to my newsletter and never miss my upcoming articles Hi everyone, We work with databases as software developers. They are a big part of the development life cycle. At the beginning of the project, you easily handle database changes, but you will get into trouble later. There are many changes to the database we worked on like adding new columns, tables, etc. That means you have a lot of changes and you will not be able to manage them quickly. At this time, you should use a tool for versioning your database schema changes. There are many tools for your needs, Liquibase is one of the most known tools for database schema versioning. Throughout this post, I will look into the Liquibase with a small application. What is Liquibase? Liquibase is an open-source project that helps you manage database schema changes. The project was started in 2006. That tool helps a lot in the development process. Especially agile software development. This is extremely important when working on agile software development. Positive Sides of Using Liquibase • Liquibase reduced manual changes for your database. You will not have to spend additional time on database scripts. • Liquibase provides easy version control on database changes. It is easy to roll back changes if it is necessary. • Liquibase supports XML, YML, SQL and JSON formats. • Liquibase works with many databases like Oracle, SQL Server, PostgreSQL, etc. There are a few positive sides to using Liquibase. I have created a simple project to show you how to use a Liquibase with Java. Let me explain how to use Liquibase. Demo I will connect to PostgreSQL database and create a table, which name is tbl_user. Then I will create and modify this table with Liquibase. Before beginning coding, you should run a PostgreSQL database instance. I will use it with Docker like below. docker run --name postgresql-container -p 5432:5432 -e POSTGRES_PASSWORD=liquibasedemo -d postgres Configuration and Create Table First of all, create a Java Spring Boot app from Spring initializr. You can access the project's Github repository. Add Liquibase dependency to the pom.xml file like below. <dependency> <groupId>org.liquibase</groupId> <artifactId>liquibase-core</artifactId> </dependency> Then you should modify your application.yml file. You should add Liquibase change log master file path in the configuration. Then you can create a directory db/changelog in the resources directory in the project. change-log file path is important. Because Liquibase will look at this file for versioning your changes. spring: jpa: database: postgresql show-sql: true hibernate: ddl-auto: update profiles: default: dev datasource: url: jdbc:postgresql://localhost:5432/postgres username: postgres password: liquibasedemo liquibase: change-log: classpath:/db/changelog/changelog-master.xml enabled: true server: port: 8080 Create a tbl_user class, which name is User. @Table(name = "tbl_user") public class User { @Id @Column(name = "id") private int id; @Column(name = "user_name") private String userName; @Column(name = "password") private String password; // getters and setters } The tbl_user table will not exist if you run the project directly. Because nothing did specify to the application that this table and its property were to be created. In this case, Liquibase will identify the tbl_user table to the application through some configuration. Create an XML file in db/changelog/<user-table-data>.xml. My file name is user-table-data.xml. The Liquibase detects your changes with the <changeSet> tag. You can define your needs below. <?xml version="1.0" encoding="UTF-8"?> <databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.1.xsd"> <changeSet id="01" author="coderkan"> <createTable tableName="tbl_user"> <column name="id" type="int" autoIncrement="true"> <constraints nullable="false" unique="true" primaryKey="true" /> </column> <column name="user_name" type="varchar(255)"> <constraints nullable="false" unique="true" /> </column> <column name="password" type="varchar(1024)"> <constraints nullable="false"/> </column> </createTable> </changeSet> </databaseChangeLog> After creating the XML file, you should import the file's path to your changelog-master.xml file. Because Liquibase will look up the changes in this file. <?xml version="1.0" encoding="utf-8"?> <databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.6.xsd"> <include file="db/changelog/user-table-data.xml"/> </databaseChangeLog> When you run the application, you will see the outputs below. Liquibase will create a table and report you as output. Screen Shot 2022-05-04 at 15.58.08.png Insert Data to Table In this section, I will show you how to add data to the database. I have created a file whose name is insert-default-user.xml. Then I added the following data. <insert tag will generate an insert SQL query for your database, then insert it into the database. <changeSet id="02" author="coderkan"> <insert tableName="tbl_user"> <column name="user_name" value="default_user"/> <column name="password" value="default_password"/> </insert> </changeSet> After adding the above data to your .xml file, you should include the changelog-master.xml with <include file="db/changelog/insert-default-user.xml"/>. You will see the output when you run your application like below, then refresh your database and fetch the data. That's all for adding value to the database. insert-default-user.png Modify Table When you need to modify your table like adding a new column, removing a new column, etc, Liquibase will help you easily. You can easily modify the table you created. I will add a new column and give it a default value. I have created a file add-is-active-column-to-user.xml. You can add the following <changeSet. It is adding a new column as is_active and giving it a value with defaultValue. It's easy to modify the table you have created. <changeSet id="03" author="coderkan"> <addColumn tableName="tbl_user"> <column name="is_active" type="bool" defaultValue="true"></column> </addColumn> </changeSet> Then, change your Entity class. @Table(name = "tbl_user") public class User { @Id @Column(name = "id") private int id; @Column(name = "user_name") private String userName; @Column(name = "password") private String password; // add new column @Column(name = "is_active") private boolean isActive; // getters and setters } Adding the file path to your changelog-master.xml file. <include file="db/changelog/add-is-active-column-to-user.xml"/> When you start your application, you will see the needed outputs like below. modify-table.png ChangeLog DB Table. Liquibase has two tables databasechangelog and databasechangeloglock. The tables record all you add to the database as a changelog. When your code executed, then it is added to the databasechangelog. That table ensures that the command you added will run once. databasechangelog.png Conclusion Versioning the database is really important while the development process. In this post, I am trying to give you a simple demo of using the Liquibase. You can do more with Liquibase and it's easy to use. It has more features, You can also check the official website for more information. I hope you enjoy reading. Have a nice coding.   Share this
{ "url": "https://erkanguzeler.com/spring-boot-usage-of-liquibase", "source_domain": "erkanguzeler.com", "snapshot_id": "crawl=CC-MAIN-2022-33", "warc_metadata": { "Content-Length": "188537", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:FSR7JENLVSYZGF2HNHS5JHN74UBW7T2C", "WARC-Concurrent-To": "<urn:uuid:f034e4a7-63d1-4e26-8940-666e1761a21a>", "WARC-Date": "2022-08-10T15:08:19Z", "WARC-IP-Address": "76.76.21.21", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:XRO2JSDLICUTUUAVCXJ3F6CRHKAFCHB6", "WARC-Record-ID": "<urn:uuid:eec35610-8a2c-4e12-a577-6708a4798990>", "WARC-Target-URI": "https://erkanguzeler.com/spring-boot-usage-of-liquibase", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:dc5ef0bc-47fb-4d09-82bb-71b88cff205e>" }, "warc_info": "isPartOf: CC-MAIN-2022-33\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for August 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-169\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 14, 35, 36, 57, 58, 90, 91, 136, 137, 169, 170, 192, 206, 221, 222, 233, 234, 297, 298, 311, 312, 410, 411, 774, 775, 964, 965, 984, 985, 1262, 1263, 1297, 1298, 1418, 1535, 1590, 1672, 1673, 1724, 1725, 1840, 1841, 1846, 1847, 2096, 2097, 2197, 2198, 2229, 2230, 2346, 2347, 2404, 2405, 2418, 2455, 2499, 2513, 2514, 2727, 2728, 2833, 2834, 2842, 2849, 2874, 2893, 2908, 2931, 2943, 2960, 2974, 3025, 3048, 3076, 3089, 3150, 3168, 3176, 3189, 3190, 3235, 3236, 3262, 3282, 3290, 3315, 3335, 3367, 3396, 3427, 3456, 3483, 3485, 3486, 3757, 3758, 3947, 3948, 3987, 3988, 4007, 4067, 4129, 4201, 4276, 4277, 4319, 4362, 4425, 4506, 4528, 4586, 4650, 4672, 4730, 4778, 4800, 4823, 4840, 4861, 4862, 5017, 5018, 5057, 5076, 5136, 5198, 5336, 5337, 5392, 5413, 5414, 5532, 5533, 5572, 5573, 5594, 5595, 5854, 5855, 5897, 5935, 5995, 6058, 6076, 6093, 6094, 6404, 6405, 6429, 6430, 6443, 6444, 6885, 6886, 6928, 6969, 7048, 7069, 7086, 7087, 7119, 7120, 7146, 7166, 7174, 7199, 7219, 7251, 7280, 7311, 7340, 7362, 7394, 7424, 7451, 7453, 7454, 7510, 7511, 7576, 7577, 7654, 7655, 7672, 7673, 7693, 7694, 7955, 7956, 7978, 7979, 7990, 7991, 8279, 8280, 8306, 8307, 8327, 8328, 8330 ], "line_end_idx": [ 14, 35, 36, 57, 58, 90, 91, 136, 137, 169, 170, 192, 206, 221, 222, 233, 234, 297, 298, 311, 312, 410, 411, 774, 775, 964, 965, 984, 985, 1262, 1263, 1297, 1298, 1418, 1535, 1590, 1672, 1673, 1724, 1725, 1840, 1841, 1846, 1847, 2096, 2097, 2197, 2198, 2229, 2230, 2346, 2347, 2404, 2405, 2418, 2455, 2499, 2513, 2514, 2727, 2728, 2833, 2834, 2842, 2849, 2874, 2893, 2908, 2931, 2943, 2960, 2974, 3025, 3048, 3076, 3089, 3150, 3168, 3176, 3189, 3190, 3235, 3236, 3262, 3282, 3290, 3315, 3335, 3367, 3396, 3427, 3456, 3483, 3485, 3486, 3757, 3758, 3947, 3948, 3987, 3988, 4007, 4067, 4129, 4201, 4276, 4277, 4319, 4362, 4425, 4506, 4528, 4586, 4650, 4672, 4730, 4778, 4800, 4823, 4840, 4861, 4862, 5017, 5018, 5057, 5076, 5136, 5198, 5336, 5337, 5392, 5413, 5414, 5532, 5533, 5572, 5573, 5594, 5595, 5854, 5855, 5897, 5935, 5995, 6058, 6076, 6093, 6094, 6404, 6405, 6429, 6430, 6443, 6444, 6885, 6886, 6928, 6969, 7048, 7069, 7086, 7087, 7119, 7120, 7146, 7166, 7174, 7199, 7219, 7251, 7280, 7311, 7340, 7362, 7394, 7424, 7451, 7453, 7454, 7510, 7511, 7576, 7577, 7654, 7655, 7672, 7673, 7693, 7694, 7955, 7956, 7978, 7979, 7990, 7991, 8279, 8280, 8306, 8307, 8327, 8328, 8330, 8340 ] }
{ "red_pajama_v2": { "ccnet_original_length": 8340, "ccnet_original_nlines": 202, "rps_doc_curly_bracket": 0.00047962000826373696, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2537485659122467, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.013264129869639874, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.30219146609306335, "rps_doc_frac_unique_words": 0.3467819392681122, "rps_doc_mean_word_length": 5.910662651062012, "rps_doc_num_sentences": 121, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.280734062194824, "rps_doc_word_count": 1041, "rps_doc_frac_chars_dupe_10grams": 0.04388102889060974, "rps_doc_frac_chars_dupe_5grams": 0.1326182335615158, "rps_doc_frac_chars_dupe_6grams": 0.10043881088495255, "rps_doc_frac_chars_dupe_7grams": 0.10043881088495255, "rps_doc_frac_chars_dupe_8grams": 0.04388102889060974, "rps_doc_frac_chars_dupe_9grams": 0.04388102889060974, "rps_doc_frac_chars_top_2gram": 0.006500890012830496, "rps_doc_frac_chars_top_3gram": 0.008451160043478012, "rps_doc_frac_chars_top_4gram": 0.006338370032608509, "rps_doc_books_importance": -663.7791137695312, "rps_doc_books_importance_length_correction": -663.7791137695312, "rps_doc_openwebtext_importance": -373.5647277832031, "rps_doc_openwebtext_importance_length_correction": -373.5647277832031, "rps_doc_wikipedia_importance": -207.0802764892578, "rps_doc_wikipedia_importance_length_correction": -207.0802764892578 }, "fasttext": { "dclm": 0.165091872215271, "english": 0.7155667543411255, "fineweb_edu_approx": 2.0815529823303223, "eai_general_math": 0.42960619926452637, "eai_open_web_math": 0.1660805344581604, "eai_web_code": 0.3526272177696228 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.74", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "16", "label": "Personal Blog" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-2,008,739,481,279,053,300
Take the 2-minute tour × Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required. I'm trying to find parametric equations for a line that passes through the point (0,1,2) and is perpendicular to the line: x = 1 + t y = 1 - t z = 2t Here's what I know: I have a directional vector, v, given by <1,-1,2> and another vector, r0, given by <1,1,0>. I can also make another vector for the point, P, <0,1,2>. Can I use any of that information to solve my question? How? share|improve this question      $t$ is supposed to be a number, not a vector. Are the original line and then one you want to intersect? If not then the answer is not unique. In fact the whole plane through $P_0$ and perpendicular to the given line will be the answer. –  Maesumi Jan 27 '13 at 2:33      The original line, given by the parametric equations above, is supposed to be perpendicular to the answer line. And the answer line passes through the point (0,1,2). –  user1766888 Jan 27 '13 at 2:35      Let $R=(1+t,1-t,2t)$ be a point on line given. Let $r_0=(0,1,2)$ be the given point. Let $u=(1,-1,2)$ be direction of the given line then you want $(R-r_0)\cdot u=0$. Solve that for $t$. –  Maesumi Jan 27 '13 at 2:40      1/4? And then what? –  user1766888 Jan 27 '13 at 2:48      Now use $t=1/4$ in equation of given line to get coordinate of the end of line segment that start at $r_0$, say $r_1$. Now find the equation of line that goes through $r_0$ and $r_1$, that is the line that goes through $r_0$ and hits the given line at $r_1$ in a perpendicular fashion. –  Maesumi Jan 27 '13 at 3:06 1 Answer 1 Find a vector perpendicular to the line $\underbrace{(1,1,0)}_{\vec{x}_0} + t\underbrace{(1,-1,2)}_{\vec{v}}$ and through $(0,1,2)$ i.e. a vector in the plane containing the line and the point and perpendicular to the line. To do this, consider the vector connecting $(1,1,0)$ and $(0,1,2)$ i.e. $\vec{u} = (-1,0,2)$. Subtract out the projection of this vector $\vec{u}$ onto $\vec{v}$. $$\dfrac{\vec{u} \cdot \vec{v}}{\Vert \vec{v} \Vert} = \dfrac{-1+4}{\sqrt{6}} = \dfrac{3}{\sqrt6} = \dfrac{\sqrt6}2$$ Hence, $$\vec{n} = \vec{u} - \dfrac{\sqrt6}2 \dfrac{\vec{v}}{\Vert \vec{v} \Vert}$$ Hence, the equation of the line perpendicular to the given line passing through $(0,1,2)$ is $$(0,1,2) + s \vec{n}$$ where $s \in \mathbb{R}$. share|improve this answer Your Answer   discard By posting your answer, you agree to the privacy policy and terms of service. Not the answer you're looking for? Browse other questions tagged or ask your own question.
{ "url": "http://math.stackexchange.com/questions/287835/find-parametric-equations-for-a-line", "source_domain": "math.stackexchange.com", "snapshot_id": "crawl=CC-MAIN-2015-32", "warc_metadata": { "Content-Length": "71923", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:S7JV3GT7C2YOKZZ5DUXFPUL4BS422W73", "WARC-Concurrent-To": "<urn:uuid:6e8d1f6a-771e-462a-9118-0624e7e5aa8e>", "WARC-Date": "2015-07-29T16:32:44Z", "WARC-IP-Address": "104.16.13.13", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:E53EOCCVX2P3GGAKH2GFZUKUUQ57MNDT", "WARC-Record-ID": "<urn:uuid:af6bbf7b-ba42-4c41-add7-3935ef3ccac2>", "WARC-Target-URI": "http://math.stackexchange.com/questions/287835/find-parametric-equations-for-a-line", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:8d5429c1-c929-4b3b-9120-812a95b339c7>" }, "warc_info": "robots: classic\r\nhostname: ip-10-236-191-2.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-32\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for August 2015\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 25, 199, 200, 323, 324, 334, 344, 351, 352, 522, 523, 584, 585, 613, 618, 884, 889, 1089, 1094, 1311, 1316, 1370, 1375, 1691, 1692, 1703, 1704, 1928, 1929, 2437, 2438, 2464, 2465, 2477, 2478, 2480, 2488, 2489, 2567, 2568 ], "line_end_idx": [ 25, 199, 200, 323, 324, 334, 344, 351, 352, 522, 523, 584, 585, 613, 618, 884, 889, 1089, 1094, 1311, 1316, 1370, 1375, 1691, 1692, 1703, 1704, 1928, 1929, 2437, 2438, 2464, 2465, 2477, 2478, 2480, 2488, 2489, 2567, 2568, 2658 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2658, "ccnet_original_nlines": 40, "rps_doc_curly_bracket": 0.0218209195882082, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2943495512008667, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.013140600174665451, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.4336399435997009, "rps_doc_frac_unique_words": 0.4013921022415161, "rps_doc_mean_word_length": 4.2853827476501465, "rps_doc_num_sentences": 31, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.635196208953857, "rps_doc_word_count": 431, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.13156470656394958, "rps_doc_frac_chars_dupe_6grams": 0.07634001225233078, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.01894965022802353, "rps_doc_frac_chars_top_3gram": 0.05847319960594177, "rps_doc_frac_chars_top_4gram": 0.02436383068561554, "rps_doc_books_importance": -255.53875732421875, "rps_doc_books_importance_length_correction": -255.53875732421875, "rps_doc_openwebtext_importance": -138.85150146484375, "rps_doc_openwebtext_importance_length_correction": -138.85150146484375, "rps_doc_wikipedia_importance": -69.83038330078125, "rps_doc_wikipedia_importance_length_correction": -69.83038330078125 }, "fasttext": { "dclm": 0.9814289808273315, "english": 0.8256485462188721, "fineweb_edu_approx": 2.09173583984375, "eai_general_math": 0.7094913721084595, "eai_open_web_math": 0.6887428760528564, "eai_web_code": 0.00032925998675636947 } }
{ "free_decimal_correspondence": { "primary": { "code": "516.3", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Geometry, Algebraic" } }, "secondary": { "code": "512.5", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Algebra" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
6,087,235,675,124,733,000
Presentation is loading. Please wait. Presentation is loading. Please wait. Slide 1 Chapter 01 Managing Student Type Information. Similar presentations Presentation on theme: "Slide 1 Chapter 01 Managing Student Type Information."— Presentation transcript: 1 Slide 1 Chapter 01 Managing Student Type Information 2 Slide 2 Content I. Managing Student Type Information Problem II. Solution 3 Slide 3  At SaigonTech, there are three types of students: urban, suburb, province.  Each student type has its amount of discount fee, the urban student will be discounted 0% of tuition, the suburb student is 5% and the province student is 10%.  SaigonTech college wants to store all information about its student types. Student TypeDiscountNotes Urban0%The urban student is not discounted. Suburb5%The suburb student is discounted 5% of tuition. Province10%The province student is discounted 10% of tuition. I. Managing Student Type Information Problem 4 Slide 4 II. Solution 1. Logical Design 2. Physical Design 3. Implementation 5 Slide 5 1. Logical Design 6 Slide 6 2. Physical Design 7 Slide 7 3. Implementation 3.1 Using GUI mode 3.2 Using Console mode 8 Slide 8 3.1 Using GUI mode 3.1.1 Creating Database 3.1.2 Creating Table 3.1.3 Inserting Data 3.1.4 Testing – Checking the inserted data 9 Slide 9 3.1.1 Creating Database Create a database named STUDENT_INFO  Right click on Databases group in the Object Explorer panel  Choose New Database  Database Name: STUDENT_INFO 10 Slide 10 3.1.2.1 Creating a new table 3.1.2.2 Creating Columns 3.1.2.3 Setting data type 3.1.2.4 Setting primary key 3.1.2 Creating Table 11 Slide 11 3.1.2.1 Creating a new table Create a table named STUDENT_TYPE  Right click on the Tables group  Choose New Table  In the Properties panel, type the table name: STUDENT_TYPE 12 Slide 12 Create columns for table STUDENT_TYPE: STUDENT_TYPE_ID, STUDENT_TYPE_NAME, DISCOUNT, NOTES. 3.1.2.2 Creating Columns 13 Slide 13 Choose appropriate data type for each column: STUDENT_TYPE_ID: int; STUDENT_TYPE_NAME : varchar(50); DISCOUNT: numeric(18,2); NOTES: text. 3.1.2.3 Setting data type 14 Slide 14 Click on the Set Primary Key button 3.1.2.4 Setting primary key 15 Slide 15 3.1.3 Inserting Data 3.1.3.1 Opening Table 3.1.3.2 Inserting Data 16 Slide 16 3.1.3.1 Opening Table Right click on the STUDENT_TYPE table  Choose Open Table 17 Slide 17 3.1.3.2 Inserting Data Insert Data Here 18 Slide 18 3.1.4 Testing – Checking the inserted data Open the STUDENT_TYPE table again to check data 19 Slide 19 3.2 Using Console mode 3.2.1 Creating a new query tab 3.2.2 Creating database 3.2.3 Creating table 3.2.4 Inserting data 3.2.5 Testing – Checking the inserted data 20 Slide 20 3.2.1 Creating a new query tab  Click on the New Query button 21 Slide 21  Use database master and SQL command: Create database STUDENT_INFO 3.2.2 Creating database 22 Slide 22 CREATE TABLE STUDENT_TYPE ( STUDENT_TYPE_IDint NOT NULL, SUTDENT_TYPE_NAMEvarchar(50) NULL, DISCOUNTnumeric(18,2) NULL, NOTEStext NULL, CONSTRAINT STUDENT_TYPEPK PRIMARY KEY (STUDENT_TYPE_ID); 3.2.3 Creating table 23 Slide 23 3.2.4 Inserting data INSERT INTO STUDENT_TYPE (STUDENT_TYPE_ID, STUDENT_TYPE_NAME, DISCOUNT, NOTES) VALUES (1, ‘Urban’, 0, ‘The urban student is not discounted.’); INSERT INTO STUDENT_TYPE (STUDENT_TYPE_ID, STUDENT_TYPE_NAME, DISCOUNT, NOTES) VALUES (2, ‘Suburb’, 0.05, ‘The suburb student is discounted 5% of tuition.’); INSERT INTO STUDENT_TYPE (STUDENT_TYPE_ID, STUDENT_TYPE_NAME, DISCOUNT, NOTES) VALUES (3, ‘Province’, 0.1, ‘The province student is discounted 10% of tuition.’); 24 Slide 24 3.2.5 Testing – Checking the inserted data Select * from STUDENT_TYPE 25 Slide 25 Download ppt "Slide 1 Chapter 01 Managing Student Type Information." Similar presentations Ads by Google
{ "url": "http://slideplayer.com/slide/4209477/", "source_domain": "slideplayer.com", "snapshot_id": "crawl=CC-MAIN-2017-26", "warc_metadata": { "Content-Length": "113471", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:2XBS66D3HPOWKQKHB55AFOWMCF5N6NYS", "WARC-Concurrent-To": "<urn:uuid:e99d8bd2-623f-4b91-8ffe-070cc5e9fa76>", "WARC-Date": "2017-06-28T19:43:53Z", "WARC-IP-Address": "88.99.70.210", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:C7MDXKTXXG5LFGYPMYURRTXBU7OMUD46", "WARC-Record-ID": "<urn:uuid:8fc76497-8165-4fa3-8b01-cfe7e1732bc1>", "WARC-Target-URI": "http://slideplayer.com/slide/4209477/", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:bb2be807-9f21-4aa4-816f-a45807ca724e>" }, "warc_info": "robots: classic\r\nhostname: ip-10-166-47-236.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-26\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for June 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 38, 39, 77, 78, 132, 133, 155, 156, 157, 262, 263, 318, 319, 395, 396, 955, 956, 1034, 1035, 1063, 1064, 1093, 1094, 1164, 1165, 1303, 1304, 1489, 1490, 1631, 1632, 1821, 1822, 1951, 1952, 2129, 2130, 2206, 2207, 2285, 2286, 2378, 2379, 2431, 2432, 2535, 2536, 2711, 2712, 2787, 2788, 2892, 2893, 3119, 3120, 3616, 3617, 3699, 3700, 3712, 3713, 3714, 3783, 3784, 3806, 3807, 3808 ], "line_end_idx": [ 38, 39, 77, 78, 132, 133, 155, 156, 157, 262, 263, 318, 319, 395, 396, 955, 956, 1034, 1035, 1063, 1064, 1093, 1094, 1164, 1165, 1303, 1304, 1489, 1490, 1631, 1632, 1821, 1822, 1951, 1952, 2129, 2130, 2206, 2207, 2285, 2286, 2378, 2379, 2431, 2432, 2535, 2536, 2711, 2712, 2787, 2788, 2892, 2893, 3119, 3120, 3616, 3617, 3699, 3700, 3712, 3713, 3714, 3783, 3784, 3806, 3807, 3808, 3821 ] }
{ "red_pajama_v2": { "ccnet_original_length": 3821, "ccnet_original_nlines": 67, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.08736717700958252, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.07201889157295227, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.47225502133369446, "rps_doc_frac_unique_words": 0.3298245668411255, "rps_doc_mean_word_length": 5.2245612144470215, "rps_doc_num_sentences": 107, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.853373050689697, "rps_doc_word_count": 570, "rps_doc_frac_chars_dupe_10grams": 0.0436534583568573, "rps_doc_frac_chars_dupe_5grams": 0.317327082157135, "rps_doc_frac_chars_dupe_6grams": 0.2649429142475128, "rps_doc_frac_chars_dupe_7grams": 0.18435190618038177, "rps_doc_frac_chars_dupe_8grams": 0.12726661562919617, "rps_doc_frac_chars_dupe_9grams": 0.0436534583568573, "rps_doc_frac_chars_top_2gram": 0.024177299812436104, "rps_doc_frac_chars_top_3gram": 0.038280729204416275, "rps_doc_frac_chars_top_4gram": 0.05036937817931175, "rps_doc_books_importance": -426.5077209472656, "rps_doc_books_importance_length_correction": -426.5077209472656, "rps_doc_openwebtext_importance": -254.7307891845703, "rps_doc_openwebtext_importance_length_correction": -254.7307891845703, "rps_doc_wikipedia_importance": -245.22384643554688, "rps_doc_wikipedia_importance_length_correction": -245.22384643554688 }, "fasttext": { "dclm": 0.04113512858748436, "english": 0.6341109275817871, "fineweb_edu_approx": 2.1734910011291504, "eai_general_math": 0.23961150646209717, "eai_open_web_math": 0.05275661125779152, "eai_web_code": 0.059339940547943115 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.74", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "378.196", "labels": { "level_1": "Social sciences", "level_2": "Education", "level_3": "Education, Higher and Universities and colleges" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
4,661,755,903,631,188,000
File:  [NetBSD Developer Wiki] / wikisrc / tutorials / bus_space_tutorial.mdwn Revision 1.4: download - view: text, annotated - select for diffs Sun Jun 23 14:34:32 2013 UTC (3 years, 11 months ago) by mspo Branches: MAIN CVS tags: HEAD clean up whitespace and try converting tables to tables [[!toc ]] ## Introduction ### Why was this tutorial created? - Introductory-level documentation is scarce - Writing device drivers is often considered black magic - Reading the man pages won’t give you the big picture - BSD systems are always in need of new drivers - Device drivers are fun ### What won’t be covered here? We don’t have much time, so several ~~advanced~~ topics were omitted: - Interrupt handling - Direct Memory Access and the bus\_dma framework - Power management - Driver detachment - Drivers as kernel modules - Examples for buses other than PCI - Pretty much everything else... However, once you finish this tutorial, you should be able to pursue this knowledge yourself. ### What is a driver anyway? - The interface between user space and hardware, implemented as a part of the kernel - The NetBSD drivers are written mostly in C - Sometimes they have machine dependent assembler parts, but this is a rare case ### What do you need to write a driver? - C programming skills - Hardware documentation (or the ability to reverse engineer the hardware) - A reference driver implementation will help but is not essential - A NetBSD installation and kernel source, or a cross-build environment (the latter is usually preferred for development of drivers) - A lot of time, coffee and patience ### Why is writing the device drivers considered difficult? - It’s not as difficult as you may expect, in fact during this tutorial we’ll prove that it’s quite easy - You need to think on a very low level - Good understanding of computer architecture is a must - Often documentation is the main problem – writing the driver is not possible if you don’t understand how the device works - No access to documentation (uncooperative hardware vendors, vendors out of business) - Documentation is incomplete or plain wrong - Reverse engineering can solve these problems but it’s a very time consuming process ## The NetBSD driver model ### The NetBSD kernel basics - NetBSD has a classic monolithic UNIX-like kernel - all drivers are running in the same address space - Thanks to the above, communication between drivers and other kernel layers is simple - However, it also means that one badly written driver can affect the whole kernel - Numerous in-kernel frameworks standardise the way drivers are written (bus\_space, autoconf, etc.) ### The NetBSD source directory structure - We’ll only cover parts interesting for a device driver programmer - src/sys/ - kernel source directory - src/sys/dev/ - machine-independent device drivers - src/sys/arch/ - port-specific or architecture-specific parts (such as the low-level system initialisation procedures or machine-dependent drivers) - src/sys/arch/\$PORTNAME/conf/ - kernel configuration files for a given port ### Kernel autoconfiguration framework - autoconf(9) - Autoconfiguration is the process of matching hardware devices with an appropriate device driver - The kernel message buffer (dmesg) contains information about autoconfiguration of devices - driver0 at bus0: Foo hardware - Instance 0 of the driver has attached to instance 0 of the particular bus - Such messages often carry additional bus-specific information about the exact location of the device (like the device and function number on the PCI bus) - driver0: some message - Additional information about the driver state or device configuration ### Autoconfiguration as seen in the dmesg NetBSD 6.99.12 (GENERIC) #7: Fri Oct 5 18:43:21 CEST 2012 rkujawa@saiko.local:/Users/rkujawa/netbsd-eurobsdcon2012/src/sys/arch/cobalt/compile/obj/GENERIC Cobalt Qube 2 total memory = 32768 KB avail memory = 27380 KB mainbus0 (root) com0 at mainbus0 addr 0x1c800000 level 3: ns16550a, working fifo com0: console cpu0 at mainbus0: QED RM5200 CPU (0x28a0) Rev. 10.0 with built-in FPU Rev. 1.0 cpu0: 48 TLB entries, 256MB max page size cpu0: 32KB/32B 2-way set-associative L1 instruction cache cpu0: 32KB/32B 2-way set-associative write-back L1 data cache mcclock0 at mainbus0 addr 0x10000070: mc146818 compatible time-of-day clock panel0 at mainbus0 addr 0x1f000000 gt0 at mainbus0 addr 0x14000000 pci0 at gt0 pchb0 at pci0 dev 0 function 0: Galileo GT-64011 System Controller, rev 1 pcib0 at pci0 dev 9 function 0 pcib0: VIA Technologies VT82C586 PCI-ISA Bridge, rev 57 viaide0 at pci0 dev 9 function 1 viaide0: VIA Technologies VT82C586 (Apollo VP) ATA33 controller viaide0: primary channel interrupting at irq 14 atabus0 at viaide0 channel 0 viaide0: secondary channel interrupting at irq 15 atabus1 at viaide0 channel 1 wd0 at atabus0 drive 0 wd0: <netbsd-cobalt.img> wd0: 750 MB, 1524 cyl, 16 head, 63 sec, 512 bytes/sect x 1536192 sectors ### Autoconfiguration as seen in the dmesg ![image](img_cobaltdevices.png) ### The bus\_space(9) framework - “The goal of the bus\_space functions is to allow a single driver source file to manipulate a set of devices on different system architectures, and to allow a single driver object file to manipulate a set of devices on multiple bus types on a single architecture.” - Provides a set of functions implementing common operations on the bus like mapping, reading, writing, copying, etc. - The bus\_space(9) is implemented at the machine-dependent level (typically it’s a part of architecture-specific code), but all implementations present the same interface[^1] ### Machine independent drivers - If possible drivers should work on any hardware platform - High quality, machine-independent (MI) drivers are an important factor that adds to NetBSD portability - Some drivers are completely MI, some have MD or bus dependent attachments and some are completely MD - A driver for a typical PCI card will be completely MI - A driver for the components of a SoC will usually be completely MD - The bus\_space abstraction helps to achieve portability, transparently handling endianness issues and hiding bus implementation details from the device driver - Even if we have MI drivers, writing the drivers is always significant part of effort needed to port NetBSD to new hardware ## Example driver from scratch ### Development environment - Out of scope of this course, but very well documented - Cross compiling is an easy task with the build.sh script - Described in [Part V of the NetBSD Guide](http://www.netbsd.org/docs/guide/en/part-compile.html) - Check out the NetBSD sources - \$ build.sh -m cobalt tools will build compiler, assembler, linker, etc. for cobalt port - \$ build.sh -m cobalt kernel=GENERIC will build the GENERIC kernel for cobalt - Call build.sh with a -u parameter to update (won’t rebuilding everything) - build.sh is calling nbconfig and nbmake tools, no magic involved ### Quick introduction to GXemul - A framework for full-system computer architecture emulation, excellent for educational purposes - Capable of emulating several real machines supported by NetBSD - We’ll emulate a [Cobalt](http://en.wikipedia.org/wiki/Cobalt_Qube), MIPS-based micro server with PCI bus - I’ve modified GXemul and implemented an emulation of an additional PCI device - It will be used to show (almost) a real-life example of the driver development process ### Our hardware - functional description - Business applications often use arithmetic operations like addition - Fake Cards Inc. responded to market needs and created a new product, Advanced Addition Accelerator - Pointy Haired Bosses will certainly buy it to accelerate their business applications, so let’s create a driver for NetBSD! ### Our hardware - technical details - Overview - Implemented as a PCI device - Arithmetic unit capable of addition of two numbers - Four[^2] registers in the PCI memory space - PCI configuration space - Identified by the PCI vendor ID 0xfabc and product ID 0x0001 - Base Address Register 0x10 used to configure the engine address - 4 x 32-bit registers = 16 bytes - Other configuration registers irrelevant ### Our hardware - technical details (memory mapped register set) - Advanced Addition Acceleration registers <table> <tr><th>Register Name</th><th>Offset</th><th>Description</th></tr> <tr><td>COMMAND</td><td>0x4</td><td>Register used to issue commands to the engine</td></tr> <tr><td>DATA</td><td>0x8</td><td>Register used to load data to internal engine registers</td></tr> <tr><td>RESULT</td><td>0xC</td><td>Register used to store the result of arithmetic operation</td></tr> </table> - COMMAND register <table> <tr><th>Bit</th><th>R/W</th><th>Description</th></tr> <tr><td>0</td><td>W</td><td>Execute ADD operation on values loaded into internal register A and B</td></tr> <tr><td>1</td><td>R/W</td><td>Select internal register A for access through DATA register</td></tr> <tr><td>2</td><td>R/W</td><td>Select internal register B for access through DATA register</td></tr> </table> - Selecting internal register A and B at the same time will lead to undefined behaviour ### Our hardware - technical details (memory mapped register set) - DATA register <table> <tr><th>Bit</th><th>R/W</th><th>Description</th></tr> <tr><td>0:31</td><td>R/W</td><td>Read/write the value in internal engine register</td></tr> </table> - RESULT register <table> <tr><th>Bit</th><th>R/W</th><th>Description</th></tr> <tr><td>0:31</td><td>R</td><td>Holds the result of last ADD operation</td></tr> </table> ### Our hardware - technical details (operation algorithm) - Select the internal register A for access (write 0x2 into COMMAND register) - Write the first number into DATA register - Select the internal register B for access (write 0x4 into COMMAND register) - Write the second number into DATA register - Issue the ADD operation (write 0x1 into COMMAND register) - Read the result from RESULT register ### Adding a new driver to the NetBSD kernel - We’ll discuss the steps needed to add a new MI PCI device driver to the NetBSD kernel - Add the vendor and device ID to the database of PCI IDs - Create a set of the driver source files in src/sys/dev/\$BUSNAME/ - Add the new driver to src/sys/dev/\$BUSNAME/\$BUSNAME.files file - Add the new driver to DEVNAMES[^3] file ### Modifying the PCI device database unmatched vendor 0xfabc product 0x0001 (Co-processor processor, revision 0x01) at pci0 dev 12 function 0 not configured - The kernel does not know anything about this vendor and device - Add it to the PCI device database - src/sys/dev/pci/pcidevs - vendor VENDORNAME 0xVENDORID Long Vendor Name - product VENDORNAME PRODUCTNAME 0xPRODUCTID Long Product Name - To regenerate pcidevs\*.h run awk -f devlist2h.awk pcidevs or Makefile.pcidevs if you’re on NetBSD ### Modifying the PCI device database - example --- pcidevs 29 Sep 2012 10:26:14 -0000 1.1139 +++ pcidevs 5 Oct 2012 08:52:59 -0000 @@ -669,6 +669,7 @@ vendor CHRYSALIS 0xcafe Chrysalis-ITS vendor MIDDLE_DIGITAL 0xdeaf Middle Digital vendor ARC 0xedd8 ARC Logic +vendor FAKECARDS 0xfabc Fake Cards vendor INVALID 0xffff INVALID VENDOR ID /* @@ -2120,6 +2121,9 @@ /* Eumitcom products */ product EUMITCOM WL11000P 0x1100 WL11000P PCI WaveLAN/IEEE 802.11 +/* FakeCards products */ +product FAKECARDS AAA 0x0001 Advanced Addition Accelerator + /* O2 Micro */ product O2MICRO 00F7 0x00f7 Integrated OHCI IEEE 1394 Host Controller product O2MICRO OZ6729 0x6729 OZ6729 PCI-PCMCIA Bridge ### Modifying the PCI device database - example Fake Cards Advanced Addition Accelerator (Co-processor processor, revision 0x01) at pci0 dev 12 function 0 not configured - Now the kernel knows the vendor and product ID - But there’s still no driver for this device ### Adding the new PCI driver - Choose a name - short, easy to remember, avoid numbers - faa looks like a good name, but you can choose any name you like - Create a set of new files in src/sys/dev/pci - faa.c - main driver code - faareg.h - register definitions[^4] - faavar.h - driver structures and functions used in other parts of the kernel[^5] - Modify driver definitions - src/sys/dev/pci/files.pci - src/sys/dev/DEVNAMES - Configure the kernel to use the newly added driver - src/sys/arch/\$PORTNAME/conf/GENERIC ### Adding the new PCI driver - main driver - Kernel includes are at the beginning, followed by machine-specific and bus-specific includes - Should also include faareg.h and faavar.h files - A minimal driver needs just two functions - faa\_match (or faa\_probe for some buses) - faa\_attach - The CFATTACH\_DECL\_NEW macro plugs the above functions into autoconf(9) mechanism ### Adding the new PCI driver - main driver - static int faa\_match(device\_t parent, cfdata\_t match, void \*aux); - Check if the driver should attach to a given device (for example in case of PCI bus, it will be used to check vendor and product ID) - parent - pointer to parent’s driver device structure - match - pointer to autoconf(9) details structure - aux - despite the name the most important argument, usually contains bus-specific structure describing device details - static void faa\_attach(device\_t parent, device\_t self, void \*aux); - Attach the driver to a given device - parent - same as with match function - self - pointer to driver’s device structure - aux - same as with match function - See definitions of these functions in the [driver(9)](http://netbsd.gw.com/cgi-bin/man-cgi?driver+9+NetBSD-current) man page. ### Adding the new PCI driver - main driver cont’d - CFATTACH\_DECL\_NEW(faa, sizeof(struct faa\_softc), faa\_match, faa\_attach, NULL, NULL); - driver name - size of softc structure containing state of driver’s instance - match/probe function - attach function - detach function - activate function - The “\_NEW” name is unfortunate - Pass NULL for unimplemented functions - We won’t cover detach and activate now, as they are not needed for a simple driver ### Adding the new PCI driver - main driver example - src/sys/dev/pci/faa.c <!-- --> #include <sys/cdefs.h> __KERNEL_RCSID(0, "$NetBSD: bus_space_tutorial.mdwn,v 1.4 2013/06/23 14:34:32 mspo Exp $"); #include <sys/param.h> #include <sys/device.h> #include <dev/pci/pcivar.h> #include <dev/pci/pcidevs.h> #include <dev/pci/faareg.h> #include <dev/pci/faavar.h> static int faa_match(device_t, cfdata_t, void *); static void faa_attach(device_t, device_t, void *); CFATTACH_DECL_NEW(faa, sizeof(struct faa_softc), faa_match, faa_attach, NULL, NULL); static int faa_match(device_t parent, cfdata_t match, void *aux) { return 0; } static void faa_attach(device_t parent, device_t self, void *aux) { } ### Adding the new PCI driver - auxiliary includes - src/sys/dev/pci/faareg.h <!-- --> #ifndef FAAREG_H #define FAAREG_H /* * Registers are defined using preprocessor: * #define FAA_REGNAME 0x0 * We'll add them later, let's leave it empty for now. */ #endif /* FAAREG_H */ - src/sys/dev/pci/faavar.h <!-- --> #ifndef FAAVAR_H #define FAAVAR_H /* sc_dev is an absolute minimum, we'll add more later */ struct faa_softc { device_t sc_dev; }; #endif /* FAAVAR_H */ ### Adding the new PCI driver - registering the driver (courtesy) - src/sys/dev/DEVNAMES <!-- --> --- DEVNAMES 1 Sep 2012 11:19:58 -0000 1.279 +++ DEVNAMES 6 Oct 2012 19:59:06 -0000 @@ -436,6 +436,7 @@ ex MI exphy MI ezload MI Attribute +faa MI fb luna68k fb news68k fb newsmips ### Adding the new PCI driver - registering the driver - See config(5) - src/sys/dev/pci/files.pci <!-- --> --- pci/files.pci 2 Aug 2012 00:17:44 -0000 1.360 +++ pci/files.pci 6 Oct 2012 19:59:10 -0000 @@ -1122,3 +1122,9 @@ device tdvfb: wsemuldisplaydev, rasops8, vcons, videomode attach tdvfb at pci file dev/pci/tdvfb.c tdvfb + +# FakeCards Advanced Addition Accelerator +device faa +attach faa at pci +file dev/pci/faa.c faa + ### Adding the new PCI driver to the kernel configuration - src/sys/arch/cobalt/conf/GENERIC <!-- --> --- GENERIC 10 Mar 2012 21:51:50 -0000 1.134 +++ GENERIC 6 Oct 2012 20:12:37 -0000 @@ -302,6 +302,9 @@ #fms* at pci? dev ? function ? # Forte Media FM801 #sv* at pci? dev ? function ? # S3 SonicVibes +# Fake Cards Advanced Addition Accelerator +faa* at pci? dev ? function ? + # Audio support #audio* at audiobus? - The above definition means that an instance of faa may be attached to any PCI bus, any device, any function - The exact position of the rule in the configuration file is not important in this case - See [config(5)](http://netbsd.gw.com/cgi-bin/man-cgi?config+5+NetBSD-current) for a description of the device definition language ### Adding the new PCI driver - example - The driver should compile now - The driver’s match function will check if the driver is able to work with a given device - Since it is not implemented, the kernel will not attach the driver ### Matching the PCI device - Modify the faa\_match function to match the specified PCI device - Use PCI\_VENDOR and PCI\_PRODUCT macros to obtain the IDs <!-- --> static int faa_match(device_t parent, cfdata_t match, void *aux) { const struct pci_attach_args *pa = (const struct pci_attach_args *)aux; if ((PCI_VENDOR(pa->pa_id) == PCI_VENDOR_FAKECARDS) && (PCI_PRODUCT(pa->pa_id) == PCI_PRODUCT_FAKECARDS_AAA)) return 1; return 0; } ### Attaching to the PCI device faa0 at pci0 dev 12 function 0 - The driver has successfully matched and attached to the PCI device but still is not doing anything useful - Let’s fill the attach function and actually program the hardware ### Variable types used with bus\_space - bus\_space\_tag\_t – type used to describe a particular bus, usually passed to the driver from MI bus structures - bus\_space\_handle\_t – used to describe a mapped range of bus space, usually created with the bus\_space\_map() function - bus\_addr\_t – address on the bus - bus\_size\_t – an amount of space on the bus - Contents of these types are MD, so avoid modifying from within the driver[^6] ### Why do we need to “map” the resources? - “The bus space must be mapped before it can be used, and should be unmapped when it is no longer needed” - It’s a machine-dependent process but it’s also conveniently hidden from the programmer by the bus\_space framework ### Mapping the hardware resources - The generic bus\_space(9) way to map space <!-- --> bus_space_map(bus_space_tag_t space, bus_addr_t address, bus_size_t size, int flags, bus_space_handle_t *handlep); - bus\_space\_map creates a mapping from the physical address to a kernel virtual address - space – represents the bus on which the mapping will be created - address – typically represents the physical address for which a mapping will be created - size – describes the amount of bus space to be mapped - handlep – pointer to mapped space (filled after successful mapping) - Separate space and address ### Mapping the hardware resources - The PCI-specific way to map space <!-- --> pci_mapreg_map(const struct pci_attach_args *pa, int reg, pcireg_t type, int busflags, bus_space_tag_t *tagp, bus_space_handle_t *handlep, bus_addr_t *basep, bus_size_t *sizep); - pci\_mapreg\_map creates mapping from physical address present in specified BAR register to kernel virtual address - pa – struct describing PCI attachment details (passed through aux) - reg – BAR register number - type – Select mapping type (I/O, memory) - busflags – Passed to bus\_space\_map flags argument - tagp – pointer to bus\_space\_tag - handlep – pointer to a mapped space - basep – address of a mapped space - sizep – size of mapped space (equivalent to BAR size) - The last four parameters are filled after successful mapping ### Mapping the registers using BAR - adding auxiliary includes - src/sys/dev/pci/faareg.h <!-- --> #define FAA_MMREG_BAR 0x10 - src/sys/dev/pci/faavar.h <!-- --> struct faa_softc { device_t sc_dev; bus_space_tag_t sc_regt; bus_space_handle_t sc_regh; bus_addr_t sc_reg_pa; }; ### Mapping the registers using BAR - main driver code - src/sys/dev/pci/faa.c <!-- --> static void faa_attach(device_t parent, device_t self, void *aux) { struct faa_softc *sc = device_private(self); const struct pci_attach_args *pa = aux; sc->sc_dev = self; pci_aprint_devinfo(pa, NULL); if (pci_mapreg_map(pa, FAA_MMREG_BAR, PCI_MAPREG_TYPE_MEM, 0, &sc->sc_regt, &sc->sc_regh, &sc->sc_reg_pa, 0) != 0 ) { aprint_error_dev(sc->sc_dev, "can't map the BAR\n"); return; } aprint_normal_dev(sc->sc_dev, "regs at 0x%08x\n", (uint32_t) sc->sc_reg_pa); } ### Accessing the hardware registers - The bus\_space\_read\_ and bus\_space\_write\_ functions are basic methods of reading and writing the hardware registers - uintX\_t bus\_space\_read\_X(bus\_space\_tag\_t space, bus\_space\_handle\_t handle, bus\_size\_t offset); - void bus\_space\_write\_X(bus\_space\_tag\_t space, bus\_space\_handle\_t handle, bus\_size\_t offset, uintX\_t value); - space - tag describing the bus - handle - describes the exact location on the bus where read/write should occur, this handle is obtained by bus\_space\_map - offset - offset from handle location - The read function returns the data read from the specified location, while write has an argument value which should be filled with data to be written ### Variants of bus\_space\_read and bus\_space\_write Data Read function Write function -------- --------------------- ---------------------- 8-bit bus\_space\_read\_1 bus\_space\_write\_1 16-bit bus\_space\_read\_2 bus\_space\_write\_2 32-bit bus\_space\_read\_4 bus\_space\_write\_4 64-bit bus\_space\_read\_8 bus\_space\_write\_8 - There are many more variants of read and write functions and they are useful in certain situations, see the [bus\_space(9)](http://netbsd.gw.com/cgi-bin/man-cgi?bus_space++NetBSD-current) man page ### Accessing the hardware registers - example - Create a function that will write a value into the DATA register of our device, then read it back and check if the value is the same as written - Define the DATA register in the driver - src/sys/dev/pci/faareg.h <!-- --> #define FAA_DATA 0x8 #define FAA_COMMAND 0x4 #define FAA_COMMAND_STORE_A __BIT(1) - Define the new function in main driver code - static bool faa\_check(struct faa\_softc \*sc); ### Accessing the hardware registers - example - src/sys/dev/pci/faa.c <!-- --> static void faa_attach(device_t parent, device_t self, void *aux) { /* ... */ if (!faa_check(sc)) { aprint_error_dev(sc->sc_dev, "hardware not responding\n"); return; } } static bool faa_check(struct faa_softc *sc) { uint32_t testval = 0xff11ee22; bus_space_write_4(sc->sc_regt, sc->sc_regh, FAA_COMMAND, FAA_COMMAND_STORE_A); bus_space_write_4(sc->sc_regt, sc->sc_regh, FAA_DATA, testval); if (bus_space_read_4(sc->sc_regt, sc->sc_regh, FAA_DATA) == testval) return true; return false; } ### Accessing the hardware registers - running the example - Update the kernel binary and run it again - Check the GXemul log <!-- --> [ faa: COMMAND register (0x4) WRITE value 0x2 ] [ faa: DATA register (0x8) WRITE value 0xff11ee22 ] [ faa: DATA register (0x8) READ value 0xff11ee22 ] - GXemul will conveniently display all accesses to our device - The faa driver still does attach without error, which means that the check function is working properly <!-- --> faa0 at pci0 dev 12 function 0: Fake Cards Advanced Addition Accelerator (rev. 0x01) faa0: registers at 0x10110000 ### Implementing addition using the hardware - The basic principle of device operation should be laid out in the data sheet - We need to implement an algorithm based on this description - Writing such an algorithm is often not needed, since the NetBSD kernel already has frameworks for common device types (such as atabus/wd for IDE and SATA hard disk controllers, wsdisplay/wscons for frame buffers, etc.) ### Implementing addition using the hardware - Define all registers - src/sys/dev/pci/faareg.h <!-- --> #define FAA_STATUS 0x0 #define FAA_COMMAND 0x4 #define FAA_COMMAND_ADD __BIT(0) #define FAA_COMMAND_STORE_A __BIT(1) #define FAA_COMMAND_STORE_B __BIT(2) #define FAA_DATA 0x8 #define FAA_RESULT 0xC ### Implementing addition using the hardware - Add a new function to the main driver code - src/sys/dev/pci/faa.c <!-- --> static void faa_attach(device_t parent, device_t self, void *aux) { /* ... */ aprint_normal_dev(sc->sc_dev, "just checking: 1 + 2 = %d\n", faa_add(sc, 1, 2)); } static uint32_t faa_add(struct faa_softc *sc, uint32_t a, uint32_t b) { bus_space_write_4(sc->sc_regt, sc->sc_regh, FAA_COMMAND, FAA_COMMAND_STORE_A); bus_space_write_4(sc->sc_regt, sc->sc_regh, FAA_DATA, a); bus_space_write_4(sc->sc_regt, sc->sc_regh, FAA_COMMAND, FAA_COMMAND_STORE_B); bus_space_write_4(sc->sc_regt, sc->sc_regh, FAA_DATA, b); bus_space_write_4(sc->sc_regt, sc->sc_regh, FAA_COMMAND, FAA_COMMAND_ADD); return bus_space_read_4(sc->sc_regt, sc->sc_regh, FAA_RESULT); } ### Implementing addition using the hardware - running the example - Update the kernel binary and run it again - Check GXemul log <!-- --> [ faa: COMMAND register (0x4) WRITE value 0x2 ] [ faa: DATA register (0x8) WRITE value 0x1 ] [ faa: COMMAND register (0x4) WRITE value 0x4 ] [ faa: DATA register (0x8) WRITE value 0x2 ] [ faa: COMMAND register (0x4) WRITE value 0x1 ] [ faa: RESULT register (0xC) READ value 0x3 ] - Looks like it worked! <!-- --> faa0 at pci0 dev 12 function 0: Fake Cards Advanced Addition Accelerator (rev. 0x01) faa0: registers at 0x10110000 faa0: just checking: 1 + 2 = 3 ## Interacting with userspace ### The kernel-user space interface - Now that the core functionality of the kernel driver is working, it should be exposed to user space - The interface between kernel driver and userspace can be designed in many different ways - The classic UNIX way of interfacing between the kernel and user space is a device file - Even when using device files there is no single interfacing method that fits all use cases - It’s up to the programmer to define the communication protocol ### Device files - crw-r—– 1 root wheel 101, 1 Aug 12 21:53 /dev/file - The kernel identifies which driver should service the request to this file by using major and minor numbers (101 and 1 in the example above) - The major number identifies the driver - The minor number usually identifies the driver instance, although the driver is free to use it in any other way - In NetBSD device files are created statically - By the MAKEDEV script during installation or boot - Manually by using the mknod utility ### Operations on device files - [open(2)](http://netbsd.gw.com/cgi-bin/man-cgi?read++NetBSD-current) and [close(2)](http://netbsd.gw.com/cgi-bin/man-cgi?read++NetBSD-current) - [read(2)](http://netbsd.gw.com/cgi-bin/man-cgi?read++NetBSD-current) and [write(2)](http://netbsd.gw.com/cgi-bin/man-cgi?write++NetBSD-current) - [ioctl(2)](http://netbsd.gw.com/cgi-bin/man-cgi?write++NetBSD-current) - [poll(2)](http://netbsd.gw.com/cgi-bin/man-cgi?poll++NetBSD-current) - [mmap(2)](http://netbsd.gw.com/cgi-bin/man-cgi?write++NetBSD-current) - and more… - Any mix of the above system calls might be used to interface between the kernel and user space - We’ll implement an ioctl(2)-based communication mechanism ### Adding cdevsw - cdevsw is used to decide which operation on the character device file calls which driver function - Not all calls have to be implemented, although some device layers define a set of calls that a driver must implement - For example disk drivers must implement open, close, read, write and ioctl - src/sys/dev/pci/faa.c <!-- --> dev_type_open(faaopen); dev_type_close(faaclose); dev_type_ioctl(faaioctl); const struct cdevsw faa_cdevsw = { faaopen, faaclose, noread, nowrite, faaioctl, nostop, notty, nopoll, nommap, nokqfilter, D_OTHER }; ### Prototyping the cdevsw operations - The dev\_type\* macros are used to prototype the functions passed to cdevsw - Pass no followed by a function name to the appropriate cdevsw field if it is not implemented - There’s also bdevsw for block devices, but we won’t use it in this example - The last member of the cdevsw structure defines the device flags, originally it was used to define the device type (still used for disks, tape drives and ttys, for other devices pass D\_OTHER) ### Implemeting the cdevsw operations - open / close - src/sys/dev/pci/faa.c <!-- --> int faaopen(dev_t dev, int flags, int mode, struct lwp *l) { struct faa_softc *sc; sc = device_lookup_private(&faa_cd, minor(dev)); if (sc == NULL) return ENXIO; if (sc->sc_flags & FAA_OPEN) return EBUSY; sc->sc_flags |= FAA_OPEN; return 0; } int faaclose(dev_t dev, int flag, int mode, struct lwp *l) { struct faa_softc *sc; sc = device_lookup_private(&faa_cd, minor(dev)); if (sc->sc_flags & FAA_OPEN) sc->sc_flags =~ FAA_OPEN; return 0; } ### Defining the ioctls - ioctl(2) can be used to call kernel-level functions and exchange data between the kernel and user space - The classic way of passing data is by using structures, their definitions are shared between the kernel and user space code - The driver might support more than one ioctl, the \_IO\* macros are used to define the operation and associated structure used to exchange data - \_IO - just a kernel function call, no data exchange - \_IOR - kernel function call and data pass from kernel to user space - \_IOW - kernel function call and data pass from user space to kernel - \_IOWR - kernel function call and data exchange in both directions - \#define DRIVERIO\_IOCTLNAME \_IOXXX(group, ioctl\_number, data structure) ## Using ioctls ### Defining the ioctls - src/sys/dev/pci/faaio.h <!-- --> #include <sys/ioccom.h> #define FAAIO_ADD _IOWR(0, 1, struct faaio_add) struct faaio_add { uint32_t a; uint32_t b; uint32_t *result; }; - In the above example the ioctl group is not defined (0), but a single letter identifier could appear as first argument to \_IOWR ### Implemeting the cdevsw operations - ioctl - src/sys/dev/pci/faa.c <!-- --> int faaioctl(dev_t dev, u_long cmd, void *data, int flag, struct lwp *l) { struct faa_softc *sc = device_lookup_private(&faa_cd, minor(dev)); int err; switch (cmd) { case FAAIO_ADD: err = faaioctl_add(sc, (struct faaio_add *) data); break; default: err = EINVAL; break; } return(err); } static int faaioctl_add(struct faa_softc *sc, struct faaio_add *data) { uint32_t result; int err; aprint_normal_dev(sc->sc_dev, "got ioctl with a %d, b %d\n", data->a, data->b); result = faa_add(sc, data->a, data->b); err = copyout(&result, data->result, sizeof(uint32_t)); return err; } ### Using copyout to pass data to userspace - The copy(9) functions are used to copy kernel space data from/to user space - copyout(kernel\_address, user space\_address, size); - Actually on Cobalt we could just do data-\>result = faa\_add(); instead of calling the copyout function, but that is a bad idea - Some architectures (such as sparc64) have totally separate kernel and user address spaces $ \implies $ user space addresses are meaningless in the kernel ### Defining device major number - Device major numbers for hardware drivers are usually defined in a per-port manner[^7] - src/sys/arch/\$PORTNAME/conf/majors.\$PORTNAME - src/sys/arch/cobalt/conf/majors.cobalt - The following defines a new character device file called /dev/faa\* with major number 101, but only if the faa driver is included in the kernel (last argument) - device-major faa char 101 faa ### Creating the device node - The mknod utility can be used to create the device file manually - The driver name can be specified instead of the major number - it will be automatically resolved into the correct major number - mknod name [b | c] [major | driver] minor - mknod /dev/faa0 c faa 0 - Created successfully - crw-r–r– 1 root wheel 101, 0 Oct 8 2012 /dev/faa0 ### An example user space program - The example program will open the device file and call ioctl(2) on it - As simple as possible, just to show how communication is done - Using ioctls from the user space - Open the device file with O\_RDWR - Call ioctl(2) with the operation number and structure as parameters ### An example user space program - source void add(int, uint32_t, uint32_t); static const char* faa_device = "/dev/faa0"; int main(int argc, char *argv[]) { int devfd; if (argc != 3) { printf("usage: %s a b\n", argv[0]); return 1; } if ( (devfd = open(faa_device, O_RDWR)) == -1) { perror("can't open device file"); return 1; } add(devfd, atoi(argv[1]), atoi(argv[2])); close(devfd); return 0; } ### An example user space program - source void add(int devfd, uint32_t a, uint32_t b) { struct faaio_add faaio; uint32_t result = 0; faaio.result = &result; faaio.a = a; faaio.b = b; if (ioctl(devfd, FAAIO_ADD, &faaio) == -1) { perror("ioctl failed"); } printf("%d\n", result); } ### An example user space program - running it # make cc -o aaa_add aaa_add.c # ./aaa_add 3 7 faa0: got ioctl with a 3, b 7 10 - The program is successfully accessing the faa driver through the ioctl - The faa0:... line is a kernel message, normally only seen on the console terminal ## A few tips ### Avoiding common pitfalls - Always free resources allocated in the match or probe functions - Always use bus\_space methods, don’t access the hardware using a pointer dereference - If possible test on more than one hardware architecture, some bugs may surface - Don’t reinvent the wheel, try to use existing kernel frameworks as much as possible - Use copy(9) (or uiomove(9) or store(9)/fetch(9)) to move data between the kernel and user space ### Basic driver debugging - Use aprint\_debug to print debug-level messages on console and log them (enabled by passing AB\_DEBUG from the boot loader) - Use the built-in DDB debugger - Enabled by the kernel option DDB - A kernel panic will start DDB if the DDB\_ONPANIC=1 kernel option is specified or the ddb.onpanic sysctl is set to 1. - Run \# sysctl -w kern.panic\_now=1 to trigger a panic manually (DIAGNOSTIC option) - Remote debugging is possible on some ports - With KGDB through the serial port - With IPKDB through the network ## Summary ### Further reading - Documentation, articles: - [A Machine-Independent DMA Framework for NetBSD, Jason R. Thorpe](http://www.netbsd.org/docs/kernel/bus_dma.pdf) - [Writing Drivers for NetBSD, Jochen Kunz](ftp://ftp.netbsd.org/pub/NetBSD/misc/ddwg/NetBSD-driver_writing-1.0.1e.pdf) - [NetBSD Documentation: Writing a pseudo device](http://www.netbsd.org/docs/kernel/pseudo/) - [autoconf(9)](http://netbsd.gw.com/cgi-bin/man-cgi?autoconf+9+NetBSD-current), [bus\_space(9)](http://netbsd.gw.com/cgi-bin/man-cgi?bus_space+9+NetBSD-current) [bus\_dma(9)](http://netbsd.gw.com/cgi-bin/man-cgi?bus_dma+9+NetBSD-current) [driver(9)](http://netbsd.gw.com/cgi-bin/man-cgi?driver+9+NetBSD-current), [pci(9)](http://netbsd.gw.com/cgi-bin/man-cgi?pci+9+NetBSD-current) man pages, etc. - Example source code of drivers: - tdvfb voodoofb are fairly good frame buffer driver examples with documentation publicly available. - etsec is a nice example of a more complicated network interface driver ### Get the source code - Download the source code and materials for this tutorial - <https://github.com/rkujawa/busspace-tutorial> - <https://github.com/rkujawa/gxemul-tutorial> ### Questions? - Do you have any questions? ### The End… ![image](NetBSD.png) Thank you! [^1]: At least they should, some functions are missing on less popular ports [^2]: Only three of these registers are of any importance for us at this moment [^3]: Required if you are NetBSD developer, optional otherwise. [^4]: Might not exist if the driver is only a simple passthrough from a specific bus to another MI driver. [^5]: Omitted if not needed. [^6]: although you’ll often have to use bus\_size\_t [^7]: It’s also possible to define a major in a machine-independent way in src/sys/conf/majors CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb
{ "url": "https://wiki.netbsd.org/cgi-bin/cvsweb/wikisrc/tutorials/bus_space_tutorial.mdwn?rev=1.4;content-type=text%2Fx-cvsweb-markup", "source_domain": "wiki.netbsd.org", "snapshot_id": "crawl=CC-MAIN-2017-22", "warc_metadata": { "Content-Length": "44099", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:G25MFCWO4LDENTYFK5ACC76B7ZKVB5AN", "WARC-Concurrent-To": "<urn:uuid:1d741cdf-563f-458b-8dac-480b85851e6e>", "WARC-Date": "2017-05-24T23:12:37Z", "WARC-IP-Address": "199.233.217.205", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:X36RTKYQOFFW5WETGAHVWFRWEWJRVMVT", "WARC-Record-ID": "<urn:uuid:e7b043ce-2b07-4242-a992-6db762431cb2>", "WARC-Target-URI": "https://wiki.netbsd.org/cgi-bin/cvsweb/wikisrc/tutorials/bus_space_tutorial.mdwn?rev=1.4;content-type=text%2Fx-cvsweb-markup", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:96ae4082-8137-47da-935b-4e2e1e40f9d7>" }, "warc_info": "robots: classic\r\nhostname: ip-10-185-224-210.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2017-22\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for May 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 1, 80, 146, 208, 223, 238, 294, 295, 305, 306, 322, 323, 358, 359, 406, 465, 522, 572, 599, 600, 632, 633, 703, 704, 727, 779, 800, 822, 852, 890, 925, 926, 995, 1020, 1021, 1050, 1051, 1124, 1142, 1189, 1262, 1276, 1277, 1317, 1318, 1343, 1410, 1424, 1493, 1555, 1623, 1636, 1675, 1676, 1736, 1737, 1802, 1848, 1890, 1952, 2024, 2082, 2150, 2183, 2234, 2303, 2334, 2335, 2362, 2363, 2392, 2393, 2464, 2502, 2574, 2595, 2667, 2684, 2750, 2791, 2792, 2834, 2835, 2905, 2918, 2948, 2965, 3006, 3024, 3088, 3156, 3169, 3203, 3253, 3254, 3307, 3308, 3379, 3412, 3477, 3510, 3544, 3611, 3634, 3704, 3772, 3812, 3838, 3902, 3924, 3925, 3968, 3969, 4032, 4141, 4159, 4187, 4215, 4235, 4304, 4322, 4405, 4451, 4513, 4579, 4659, 4698, 4734, 4750, 4828, 4863, 4923, 4960, 5028, 5080, 5113, 5167, 5200, 5227, 5256, 5333, 5334, 5377, 5378, 5410, 5411, 5443, 5444, 5514, 5581, 5644, 5710, 5729, 5799, 5853, 5921, 5988, 6039, 6040, 6072, 6073, 6134, 6202, 6245, 6311, 6354, 6416, 6488, 6499, 6560, 6620, 6670, 6732, 6801, 6802, 6833, 6834, 6862, 6863, 6921, 6982, 7021, 7087, 7120, 7152, 7217, 7258, 7303, 7369, 7385, 7398, 7458, 7459, 7492, 7493, 7558, 7597, 7664, 7736, 7777, 7848, 7863, 7934, 7958, 7959, 8001, 8002, 8074, 8147, 8181, 8248, 8312, 8313, 8350, 8351, 8364, 8400, 8459, 8510, 8538, 8607, 8679, 8719, 8768, 8769, 8835, 8836, 8881, 8882, 8890, 8957, 9049, 9148, 9251, 9260, 9261, 9282, 9283, 9291, 9345, 9453, 9553, 9653, 9662, 9663, 9733, 9757, 9758, 9824, 9825, 9843, 9844, 9852, 9906, 9998, 10007, 10008, 10028, 10029, 10037, 10091, 10171, 10180, 10181, 10240, 10241, 10311, 10325, 10371, 10441, 10455, 10502, 10564, 10605, 10606, 10651, 10652, 10724, 10746, 10810, 10861, 10892, 10965, 11013, 11014, 11052, 11053, 11111, 11168, 11187, 11188, 11255, 11319, 11369, 11434, 11500, 11541, 11542, 11590, 11591, 11642, 11684, 11708, 11754, 11805, 11843, 11886, 11936, 11942, 11950, 11976, 12005, 12078, 12084, 12114, 12184, 12190, 12210, 12292, 12357, 12358, 12406, 12407, 12467, 12524, 12543, 12544, 12595, 12643, 12644, 12674, 12675, 12734, 12746, 12815, 12864, 12878, 12905, 12922, 12957, 12974, 13043, 13062, 13092, 13126, 13155, 13212, 13253, 13254, 13298, 13299, 13370, 13400, 13452, 13498, 13517, 13556, 13576, 13641, 13667, 13668, 13712, 13713, 13779, 13791, 13864, 13936, 13948, 13963, 14017, 14031, 14082, 14094, 14167, 14224, 14225, 14292, 14304, 14348, 14363, 14401, 14414, 14461, 14473, 14511, 14557, 14635, 14649, 14650, 14701, 14702, 14770, 14800, 14820, 14890, 14919, 14943, 14967, 14993, 15029, 15071, 15144, 15162, 15163, 15215, 15216, 15242, 15243, 15252, 15253, 15280, 15376, 15403, 15431, 15463, 15496, 15528, 15560, 15561, 15620, 15680, 15681, 15734, 15778, 15779, 15794, 15852, 15858, 15880, 15886, 15887, 15903, 15961, 15968, 15974, 15975, 16026, 16027, 16056, 16057, 16066, 16067, 16088, 16109, 16117, 16166, 16198, 16257, 16265, 16291, 16292, 16321, 16322, 16331, 16332, 16353, 16374, 16375, 16437, 16460, 16489, 16496, 16522, 16523, 16589, 16590, 16615, 16616, 16625, 16626, 16680, 16726, 16750, 16769, 16792, 16830, 16853, 16877, 16901, 16926, 16927, 16982, 16983, 17001, 17031, 17032, 17041, 17042, 17100, 17150, 17176, 17239, 17264, 17305, 17311, 17358, 17374, 17397, 17434, 17440, 17441, 17499, 17500, 17537, 17538, 17547, 17548, 17598, 17640, 17664, 17728, 17788, 17794, 17842, 17883, 17889, 17910, 17943, 17944, 18015, 18060, 18128, 18155, 18163, 18241, 18297, 18298, 18338, 18339, 18373, 18446, 18470, 18541, 18542, 18570, 18571, 18640, 18702, 18703, 18712, 18713, 18728, 18786, 18792, 18876, 18877, 18942, 19016, 19046, 19047, 19069, 19075, 19076, 19108, 19109, 19144, 19145, 19216, 19259, 19328, 19329, 19369, 19370, 19393, 19394, 19462, 19496, 19497, 19523, 19524, 19597, 19632, 19633, 19650, 19651, 19676, 19677, 19694, 19695, 19731, 19732, 19803, 19818, 19819, 19862, 19863, 19934, 19976, 20047, 20099, 20100, 20135, 20136, 20183, 20184, 20193, 20194, 20256, 20319, 20320, 20340, 20341, 20409, 20421, 20422, 20432, 20433, 20495, 20496, 20508, 20509, 20582, 20597, 20598, 20607, 20608, 20661, 20662, 20674, 20675, 20739, 20740, 20771, 20772, 20807, 20808, 20846, 20847, 20856, 20857, 20935, 21006, 21049, 21050, 21071, 21072, 21139, 21178, 21179, 21186, 21187, 21255, 21256, 21264, 21265, 21291, 21292, 21301, 21302, 21342, 21343, 21356, 21357, 21404, 21405, 21414, 21415, 21448, 21449, 21461, 21462, 21494, 21495, 21505, 21506, 21538, 21539, 21549, 21550, 21602, 21603, 21668, 21669, 21733, 21734, 21763, 21764, 21773, 21774, 21807, 21808, 21837, 21838, 21847, 21848, 21871, 21900, 21901, 21938, 21978, 22012, 22013, 22020, 22021, 22076, 22077, 22103, 22104, 22113, 22114, 22130, 22188, 22194, 22251, 22303, 22304, 22335, 22336, 22378, 22379, 22454, 22526, 22595, 22619, 22633, 22634, 22723, 22729, 22730, 22767, 22768, 22839, 22897, 22898, 22957, 23013, 23014, 23070, 23142, 23143, 23157, 23158, 23191, 23192, 23207, 23208, 23275, 23340, 23341, 23356, 23357, 23395, 23396, 23463, 23531, 23570, 23571, 23626, 23627, 23679, 23735, 23790, 23845, 23900, 23955, 23956, 24026, 24072, 24156, 24169, 24170, 24217, 24218, 24290, 24362, 24374, 24375, 24418, 24419, 24448, 24449, 24458, 24459, 24499, 24539, 24588, 24589, 24637, 24638, 24690, 24691, 24738, 24739, 24765, 24766, 24775, 24776, 24792, 24850, 24856, 24873, 24902, 24973, 24993, 25002, 25008, 25009, 25025, 25061, 25067, 25111, 25202, 25278, 25359, 25392, 25393, 25419, 25425, 25426, 25485, 25486, 25532, 25533, 25558, 25559, 25568, 25569, 25621, 25677, 25732, 25733, 25797, 25798, 25871, 25910, 25911, 25920, 25921, 26010, 26044, 26045, 26090, 26091, 26161, 26176, 26177, 26241, 26242, 26310, 26377, 26448, 26477, 26478, 26523, 26524, 26549, 26550, 26579, 26580, 26589, 26590, 26630, 26670, 26727, 26776, 26825, 26865, 26905, 26906, 26951, 26952, 26999, 27000, 27026, 27027, 27036, 27037, 27053, 27111, 27117, 27139, 27232, 27238, 27239, 27259, 27317, 27323, 27414, 27484, 27575, 27645, 27732, 27807, 27813, 27814, 27881, 27882, 27928, 27929, 27950, 27951, 27960, 27961, 28013, 28062, 28114, 28163, 28215, 28265, 28266, 28292, 28293, 28302, 28303, 28392, 28426, 28461, 28462, 28492, 28493, 28529, 28530, 28602, 28638, 28711, 28735, 28803, 28830, 28901, 28929, 28996, 28997, 29014, 29015, 29070, 29139, 29212, 29223, 29266, 29336, 29386, 29436, 29494, 29538, 29539, 29570, 29571, 29644, 29652, 29726, 29799, 29807, 29882, 29957, 30030, 30104, 30118, 30191, 30221, 30283, 30284, 30302, 30303, 30314, 30315, 30388, 30414, 30415, 30485, 30540, 30541, 30614, 30624, 30625, 30651, 30652, 30661, 30662, 30690, 30720, 30750, 30751, 30790, 30848, 30911, 30918, 30919, 30957, 30958, 31031, 31042, 31114, 31143, 31214, 31226, 31296, 31365, 31431, 31432, 31485, 31486, 31512, 31513, 31522, 31523, 31531, 31590, 31596, 31630, 31691, 31692, 31720, 31754, 31795, 31829, 31830, 31868, 31890, 31896, 31904, 31963, 31969, 32003, 32064, 32065, 32106, 32152, 32153, 32175, 32181, 32182, 32206, 32207, 32220, 32221, 32294, 32324, 32325, 32391, 32457, 32529, 32595, 32613, 32614, 32627, 32628, 32684, 32685, 32699, 32700, 32771, 32772, 32786, 32787, 32858, 32859, 32874, 32875, 32943, 32944, 33016, 33035, 33036, 33052, 33053, 33077, 33078, 33106, 33107, 33116, 33117, 33145, 33171, 33225, 33226, 33249, 33269, 33289, 33315, 33322, 33323, 33390, 33460, 33461, 33507, 33508, 33534, 33535, 33544, 33545, 33553, 33626, 33632, 33711, 33732, 33733, 33760, 33788, 33859, 33886, 33907, 33941, 33968, 33982, 34007, 34013, 34028, 34091, 34097, 34135, 34136, 34209, 34244, 34245, 34297, 34365, 34389, 34395, 34396, 34440, 34441, 34510, 34525, 34582, 34650, 34718, 34788, 34854, 34884, 34885, 34918, 34919, 34990, 35014, 35065, 35108, 35180, 35253, 35280, 35314, 35315, 35344, 35345, 35414, 35484, 35549, 35595, 35623, 35648, 35702, 35703, 35737, 35738, 35809, 35816, 35882, 35919, 35961, 36026, 36045, 36046, 36089, 36090, 36129, 36130, 36179, 36180, 36188, 36221, 36227, 36250, 36251, 36280, 36336, 36366, 36380, 36441, 36495, 36525, 36539, 36540, 36594, 36595, 36621, 36643, 36649, 36650, 36693, 36694, 36703, 36746, 36752, 36788, 36821, 36822, 36858, 36883, 36908, 36909, 36966, 37010, 37024, 37060, 37066, 37067, 37114, 37115, 37126, 37154, 37174, 37208, 37215, 37216, 37285, 37295, 37364, 37385, 37386, 37400, 37401, 37430, 37431, 37499, 37568, 37592, 37663, 37679, 37750, 37771, 37837, 37875, 37876, 37903, 37904, 37975, 38036, 38070, 38111, 38178, 38245, 38316, 38344, 38391, 38433, 38472, 38473, 38484, 38485, 38505, 38506, 38535, 38601, 38664, 38708, 38798, 38846, 38905, 38992, 39081, 39166, 39249, 39325, 39349, 39350, 39386, 39400, 39401, 39468, 39510, 39511, 39525, 39526, 39599, 39600, 39624, 39625, 39686, 39737, 39786, 39787, 39802, 39803, 39834, 39835, 39848, 39849, 39870, 39871, 39882, 39883, 39954, 39964, 39965, 40038, 40049, 40050, 40114, 40115, 40187, 40226, 40227, 40256, 40257, 40310, 40311, 40383, 40410, 40411 ], "line_end_idx": [ 1, 80, 146, 208, 223, 238, 294, 295, 305, 306, 322, 323, 358, 359, 406, 465, 522, 572, 599, 600, 632, 633, 703, 704, 727, 779, 800, 822, 852, 890, 925, 926, 995, 1020, 1021, 1050, 1051, 1124, 1142, 1189, 1262, 1276, 1277, 1317, 1318, 1343, 1410, 1424, 1493, 1555, 1623, 1636, 1675, 1676, 1736, 1737, 1802, 1848, 1890, 1952, 2024, 2082, 2150, 2183, 2234, 2303, 2334, 2335, 2362, 2363, 2392, 2393, 2464, 2502, 2574, 2595, 2667, 2684, 2750, 2791, 2792, 2834, 2835, 2905, 2918, 2948, 2965, 3006, 3024, 3088, 3156, 3169, 3203, 3253, 3254, 3307, 3308, 3379, 3412, 3477, 3510, 3544, 3611, 3634, 3704, 3772, 3812, 3838, 3902, 3924, 3925, 3968, 3969, 4032, 4141, 4159, 4187, 4215, 4235, 4304, 4322, 4405, 4451, 4513, 4579, 4659, 4698, 4734, 4750, 4828, 4863, 4923, 4960, 5028, 5080, 5113, 5167, 5200, 5227, 5256, 5333, 5334, 5377, 5378, 5410, 5411, 5443, 5444, 5514, 5581, 5644, 5710, 5729, 5799, 5853, 5921, 5988, 6039, 6040, 6072, 6073, 6134, 6202, 6245, 6311, 6354, 6416, 6488, 6499, 6560, 6620, 6670, 6732, 6801, 6802, 6833, 6834, 6862, 6863, 6921, 6982, 7021, 7087, 7120, 7152, 7217, 7258, 7303, 7369, 7385, 7398, 7458, 7459, 7492, 7493, 7558, 7597, 7664, 7736, 7777, 7848, 7863, 7934, 7958, 7959, 8001, 8002, 8074, 8147, 8181, 8248, 8312, 8313, 8350, 8351, 8364, 8400, 8459, 8510, 8538, 8607, 8679, 8719, 8768, 8769, 8835, 8836, 8881, 8882, 8890, 8957, 9049, 9148, 9251, 9260, 9261, 9282, 9283, 9291, 9345, 9453, 9553, 9653, 9662, 9663, 9733, 9757, 9758, 9824, 9825, 9843, 9844, 9852, 9906, 9998, 10007, 10008, 10028, 10029, 10037, 10091, 10171, 10180, 10181, 10240, 10241, 10311, 10325, 10371, 10441, 10455, 10502, 10564, 10605, 10606, 10651, 10652, 10724, 10746, 10810, 10861, 10892, 10965, 11013, 11014, 11052, 11053, 11111, 11168, 11187, 11188, 11255, 11319, 11369, 11434, 11500, 11541, 11542, 11590, 11591, 11642, 11684, 11708, 11754, 11805, 11843, 11886, 11936, 11942, 11950, 11976, 12005, 12078, 12084, 12114, 12184, 12190, 12210, 12292, 12357, 12358, 12406, 12407, 12467, 12524, 12543, 12544, 12595, 12643, 12644, 12674, 12675, 12734, 12746, 12815, 12864, 12878, 12905, 12922, 12957, 12974, 13043, 13062, 13092, 13126, 13155, 13212, 13253, 13254, 13298, 13299, 13370, 13400, 13452, 13498, 13517, 13556, 13576, 13641, 13667, 13668, 13712, 13713, 13779, 13791, 13864, 13936, 13948, 13963, 14017, 14031, 14082, 14094, 14167, 14224, 14225, 14292, 14304, 14348, 14363, 14401, 14414, 14461, 14473, 14511, 14557, 14635, 14649, 14650, 14701, 14702, 14770, 14800, 14820, 14890, 14919, 14943, 14967, 14993, 15029, 15071, 15144, 15162, 15163, 15215, 15216, 15242, 15243, 15252, 15253, 15280, 15376, 15403, 15431, 15463, 15496, 15528, 15560, 15561, 15620, 15680, 15681, 15734, 15778, 15779, 15794, 15852, 15858, 15880, 15886, 15887, 15903, 15961, 15968, 15974, 15975, 16026, 16027, 16056, 16057, 16066, 16067, 16088, 16109, 16117, 16166, 16198, 16257, 16265, 16291, 16292, 16321, 16322, 16331, 16332, 16353, 16374, 16375, 16437, 16460, 16489, 16496, 16522, 16523, 16589, 16590, 16615, 16616, 16625, 16626, 16680, 16726, 16750, 16769, 16792, 16830, 16853, 16877, 16901, 16926, 16927, 16982, 16983, 17001, 17031, 17032, 17041, 17042, 17100, 17150, 17176, 17239, 17264, 17305, 17311, 17358, 17374, 17397, 17434, 17440, 17441, 17499, 17500, 17537, 17538, 17547, 17548, 17598, 17640, 17664, 17728, 17788, 17794, 17842, 17883, 17889, 17910, 17943, 17944, 18015, 18060, 18128, 18155, 18163, 18241, 18297, 18298, 18338, 18339, 18373, 18446, 18470, 18541, 18542, 18570, 18571, 18640, 18702, 18703, 18712, 18713, 18728, 18786, 18792, 18876, 18877, 18942, 19016, 19046, 19047, 19069, 19075, 19076, 19108, 19109, 19144, 19145, 19216, 19259, 19328, 19329, 19369, 19370, 19393, 19394, 19462, 19496, 19497, 19523, 19524, 19597, 19632, 19633, 19650, 19651, 19676, 19677, 19694, 19695, 19731, 19732, 19803, 19818, 19819, 19862, 19863, 19934, 19976, 20047, 20099, 20100, 20135, 20136, 20183, 20184, 20193, 20194, 20256, 20319, 20320, 20340, 20341, 20409, 20421, 20422, 20432, 20433, 20495, 20496, 20508, 20509, 20582, 20597, 20598, 20607, 20608, 20661, 20662, 20674, 20675, 20739, 20740, 20771, 20772, 20807, 20808, 20846, 20847, 20856, 20857, 20935, 21006, 21049, 21050, 21071, 21072, 21139, 21178, 21179, 21186, 21187, 21255, 21256, 21264, 21265, 21291, 21292, 21301, 21302, 21342, 21343, 21356, 21357, 21404, 21405, 21414, 21415, 21448, 21449, 21461, 21462, 21494, 21495, 21505, 21506, 21538, 21539, 21549, 21550, 21602, 21603, 21668, 21669, 21733, 21734, 21763, 21764, 21773, 21774, 21807, 21808, 21837, 21838, 21847, 21848, 21871, 21900, 21901, 21938, 21978, 22012, 22013, 22020, 22021, 22076, 22077, 22103, 22104, 22113, 22114, 22130, 22188, 22194, 22251, 22303, 22304, 22335, 22336, 22378, 22379, 22454, 22526, 22595, 22619, 22633, 22634, 22723, 22729, 22730, 22767, 22768, 22839, 22897, 22898, 22957, 23013, 23014, 23070, 23142, 23143, 23157, 23158, 23191, 23192, 23207, 23208, 23275, 23340, 23341, 23356, 23357, 23395, 23396, 23463, 23531, 23570, 23571, 23626, 23627, 23679, 23735, 23790, 23845, 23900, 23955, 23956, 24026, 24072, 24156, 24169, 24170, 24217, 24218, 24290, 24362, 24374, 24375, 24418, 24419, 24448, 24449, 24458, 24459, 24499, 24539, 24588, 24589, 24637, 24638, 24690, 24691, 24738, 24739, 24765, 24766, 24775, 24776, 24792, 24850, 24856, 24873, 24902, 24973, 24993, 25002, 25008, 25009, 25025, 25061, 25067, 25111, 25202, 25278, 25359, 25392, 25393, 25419, 25425, 25426, 25485, 25486, 25532, 25533, 25558, 25559, 25568, 25569, 25621, 25677, 25732, 25733, 25797, 25798, 25871, 25910, 25911, 25920, 25921, 26010, 26044, 26045, 26090, 26091, 26161, 26176, 26177, 26241, 26242, 26310, 26377, 26448, 26477, 26478, 26523, 26524, 26549, 26550, 26579, 26580, 26589, 26590, 26630, 26670, 26727, 26776, 26825, 26865, 26905, 26906, 26951, 26952, 26999, 27000, 27026, 27027, 27036, 27037, 27053, 27111, 27117, 27139, 27232, 27238, 27239, 27259, 27317, 27323, 27414, 27484, 27575, 27645, 27732, 27807, 27813, 27814, 27881, 27882, 27928, 27929, 27950, 27951, 27960, 27961, 28013, 28062, 28114, 28163, 28215, 28265, 28266, 28292, 28293, 28302, 28303, 28392, 28426, 28461, 28462, 28492, 28493, 28529, 28530, 28602, 28638, 28711, 28735, 28803, 28830, 28901, 28929, 28996, 28997, 29014, 29015, 29070, 29139, 29212, 29223, 29266, 29336, 29386, 29436, 29494, 29538, 29539, 29570, 29571, 29644, 29652, 29726, 29799, 29807, 29882, 29957, 30030, 30104, 30118, 30191, 30221, 30283, 30284, 30302, 30303, 30314, 30315, 30388, 30414, 30415, 30485, 30540, 30541, 30614, 30624, 30625, 30651, 30652, 30661, 30662, 30690, 30720, 30750, 30751, 30790, 30848, 30911, 30918, 30919, 30957, 30958, 31031, 31042, 31114, 31143, 31214, 31226, 31296, 31365, 31431, 31432, 31485, 31486, 31512, 31513, 31522, 31523, 31531, 31590, 31596, 31630, 31691, 31692, 31720, 31754, 31795, 31829, 31830, 31868, 31890, 31896, 31904, 31963, 31969, 32003, 32064, 32065, 32106, 32152, 32153, 32175, 32181, 32182, 32206, 32207, 32220, 32221, 32294, 32324, 32325, 32391, 32457, 32529, 32595, 32613, 32614, 32627, 32628, 32684, 32685, 32699, 32700, 32771, 32772, 32786, 32787, 32858, 32859, 32874, 32875, 32943, 32944, 33016, 33035, 33036, 33052, 33053, 33077, 33078, 33106, 33107, 33116, 33117, 33145, 33171, 33225, 33226, 33249, 33269, 33289, 33315, 33322, 33323, 33390, 33460, 33461, 33507, 33508, 33534, 33535, 33544, 33545, 33553, 33626, 33632, 33711, 33732, 33733, 33760, 33788, 33859, 33886, 33907, 33941, 33968, 33982, 34007, 34013, 34028, 34091, 34097, 34135, 34136, 34209, 34244, 34245, 34297, 34365, 34389, 34395, 34396, 34440, 34441, 34510, 34525, 34582, 34650, 34718, 34788, 34854, 34884, 34885, 34918, 34919, 34990, 35014, 35065, 35108, 35180, 35253, 35280, 35314, 35315, 35344, 35345, 35414, 35484, 35549, 35595, 35623, 35648, 35702, 35703, 35737, 35738, 35809, 35816, 35882, 35919, 35961, 36026, 36045, 36046, 36089, 36090, 36129, 36130, 36179, 36180, 36188, 36221, 36227, 36250, 36251, 36280, 36336, 36366, 36380, 36441, 36495, 36525, 36539, 36540, 36594, 36595, 36621, 36643, 36649, 36650, 36693, 36694, 36703, 36746, 36752, 36788, 36821, 36822, 36858, 36883, 36908, 36909, 36966, 37010, 37024, 37060, 37066, 37067, 37114, 37115, 37126, 37154, 37174, 37208, 37215, 37216, 37285, 37295, 37364, 37385, 37386, 37400, 37401, 37430, 37431, 37499, 37568, 37592, 37663, 37679, 37750, 37771, 37837, 37875, 37876, 37903, 37904, 37975, 38036, 38070, 38111, 38178, 38245, 38316, 38344, 38391, 38433, 38472, 38473, 38484, 38485, 38505, 38506, 38535, 38601, 38664, 38708, 38798, 38846, 38905, 38992, 39081, 39166, 39249, 39325, 39349, 39350, 39386, 39400, 39401, 39468, 39510, 39511, 39525, 39526, 39599, 39600, 39624, 39625, 39686, 39737, 39786, 39787, 39802, 39803, 39834, 39835, 39848, 39849, 39870, 39871, 39882, 39883, 39954, 39964, 39965, 40038, 40049, 40050, 40114, 40115, 40187, 40226, 40227, 40256, 40257, 40310, 40311, 40383, 40410, 40411, 40485 ] }
{ "red_pajama_v2": { "ccnet_original_length": 40485, "ccnet_original_nlines": 1298, "rps_doc_curly_bracket": 0.0011856199707835913, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.19354446232318878, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03934226930141449, "rps_doc_frac_lines_end_with_ellipsis": 0.002309469971805811, "rps_doc_frac_no_alph_words": 0.34750303626060486, "rps_doc_frac_unique_words": 0.28417420387268066, "rps_doc_mean_word_length": 5.757438659667969, "rps_doc_num_sentences": 206, "rps_doc_symbol_to_word_ratio": 0.0336175411939621, "rps_doc_unigram_entropy": 6.2502827644348145, "rps_doc_word_count": 4638, "rps_doc_frac_chars_dupe_10grams": 0.03243080899119377, "rps_doc_frac_chars_dupe_5grams": 0.13500356674194336, "rps_doc_frac_chars_dupe_6grams": 0.09111335873603821, "rps_doc_frac_chars_dupe_7grams": 0.0784555971622467, "rps_doc_frac_chars_dupe_8grams": 0.05636071041226387, "rps_doc_frac_chars_dupe_9grams": 0.03490244969725609, "rps_doc_frac_chars_top_2gram": 0.007077860180288553, "rps_doc_frac_chars_top_3gram": 0.004493880085647106, "rps_doc_frac_chars_top_4gram": 0.005617349874228239, "rps_doc_books_importance": -3650.84033203125, "rps_doc_books_importance_length_correction": -3650.84033203125, "rps_doc_openwebtext_importance": -1982.6279296875, "rps_doc_openwebtext_importance_length_correction": -1982.6279296875, "rps_doc_wikipedia_importance": -1294.0718994140625, "rps_doc_wikipedia_importance_length_correction": -1294.0718994140625 }, "fasttext": { "dclm": 0.05116933956742287, "english": 0.7176507711410522, "fineweb_edu_approx": 2.6341328620910645, "eai_general_math": 0.5261225700378418, "eai_open_web_math": 0.10923796892166138, "eai_web_code": 0.985907793045044 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.22", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "4", "label": "Advanced Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
436,926,919,812,270,460
IMPORTANT NOTICE: Due to the rise of COVID-19 cases within our service territory, GVEC will temporarily close all customer service lobbies as of Thursday, 7/2/20. Drive thru lanes will remain open for our customers' convenience at this time. You may also continue to call us for assistance or visit our websites and self-service portals to conduct business with us. If you believe your internet connection consistently under performs, there are steps you can take to help get it “up to speed.” Here are seven options for getting optimal performance from your home internet connection. First, Run a Speed Test Before taking any steps to improve home internet performance, we suggest running a simple speed test to confirm your everyday speed. You can use GVEC Internet’s speed test by clicking here. After running the test, compare the download result to the speed you’re paying for. If you’re on a wireless internet plan, keep in mind that these plans are based on “maximum burst” speeds. This technology enables a wireless connection to attain maximum speeds during brief “bursts,” when conditions are optimal. If you have a wireless connection then, it won’t be unusual for speed test results to be less than the megabit per second (Mbps) speed your plan is rated for. Even if your connection isn’t wireless, various factors (e.g., how much overall traffic there is on the network at any given time, etc.) will impact the results of a speed test. Still, if your connection generally disappoints or frustrates, or if your speed-test download number is consistently below your plan’s Mbps rating on a non-wireless plan, the following seven tips may help with getting optimal performance from your home internet. 1. Hardware Limitations It’s possible the device you use on your network isn’t capable of delivering maximum speed from your connection. This is especially true if you have super speedy fiber-based internet. GVEC Fiber, for instance, can deliver up to 1 gigabit per second (Gbps); older laptops, smartphones and tablets or even recent gaming consoles (e.g., PS4, Xbox One) may not be able to hit your network’s maximum speed. It’s also a good idea to check your device’s settings to verify it’s configured for the highest connection speed possible. An old, outdated router that’s not fully compatible with the connection technology in use can cause decreased speeds, too and less than optimal performance from your home internet. It’s  important to keep your router firmware updated; doing so will help assure the signal is correctly encoded for and received by the devices on the network. Occasionally powering your router off and on can also help, as can resetting them to factory default settings. If all else fails, try buying a new router. Keep in mind that GVEC Wireless and Fiber Internet plans offer Wi-Fi through an optional dual-band router. This device, which costs $6 a month to rent, is designed to make the most effective use of the bandwidth available in your home, and to maximize the Wi-Fi signal, including guaranteed compatibility with GVEC Internet’s maximum speeds; plus, rental of our dual-band router includes set-up and enhanced tech support from GVEC to help assure you get optimal performance from your home internet. 2. Adjust/Reroute the Wi-Fi Signal Wi-Fi signals can be impeded or blocked by physical barriers such as concrete, brick and metal. Electromagnetic interference from other devices (microwaves, radios, wireless speakers, TVs, smartphones, Bluetooth devices, etc.) can also interfere. Try situating your router in a centralized location, away from physical barriers and devices that can hamper Wi-Fi signals. And always use your devices as close to the router as is practical. 3. Turn off Bandwidth Hogs The more devices accessing a Wi-Fi network, the greater bandwidth that will be used. It’s important to take Wi-Fi devices not currently in use off the network—this means powering idle devices down or turning off their connection to achieve the best Wi-Fi experience possible. 4. Optimize Programs The Background activities of internet-connected apps can place a serious drag on your connection if you have several running at once. Close idle apps completely or optimize their settings to control when they can use the internet. You should also regularly check your device’s background activities to verify how much background bandwidth is being used. Consider using offline versions of any apps for which you don’t absolutely need internet access. Clearing browser and system caches can also help achieve the best Wi-Fi experience possible. 5. Keep Devices free of Malware and Viruses Besides potentially compromising private user data or sensitive files, viruses and malware can take a serious toll on any device’s internet speed. It’s important to use antivirus software on every device and to keep that software updated. Malicious software often runs in the background, too, so this is another case where regularly checking background activities can be helpful. 6. Add a Signal Booster to Your Wi-Fi Network Wi-Fi repeaters and extenders receive a wireless router’s signal and retransmit it to areas of a home with problematic connectivity. The two devices work similarly, but a repeater consumes network bandwidth, leaving less for other devices. An extender, on the other hand, doesn’t steal bandwidth from other devices; however, extenders require a separate network to be created alongside the original. Users must log onto this separate network to use the extender signal, making this solution a bit inconvenient. Repeaters and extenders are decent options for improving and enhancing Wi-Fi signals, but neither is as effective at helping achieve optimal performance from your home internet as a mesh network. Mesh networks combine a router with separate units sometimes known as “pods.” These connect wirelessly to the router and retransmit the signal to areas with low or nonexistent Wi-Fi coverage. GVEC Internet offers a state-of-the-art Wi-Fi mesh system for our customers. If you’re interested in learning more, visit our Home Wi-Fi Optimization page or call us at 800.699.4832. 7. Call Your Internet Provider If you’ve tried one or more of the solutions here but don’t believe you’re getting optimal performance from your home internet–or even satisfactory performance–it might be time to call your provider. Your ISP can work with you to help pinpoint any potential trouble spots. You might also consider upgrading a higher speed plan. If you’re a GVEC Internet customer, we welcome you to call us if you’re having trouble getting a signal in certain parts of your home or if you’re concerned about the speeds you’re experiencing. We’ll do everything we can to help you get the most from your GVEC Internet. For more information, call us at 800.699.4832. Share This
{ "url": "https://www.gvec.net/seven-tips-for-optimal-performance-from-your-home-internet/", "source_domain": "www.gvec.net", "snapshot_id": "crawl=CC-MAIN-2020-34", "warc_metadata": { "Content-Length": "61518", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:LJH3WDSGJMRKUZXJQKVO53FEJV2D5RXH", "WARC-Concurrent-To": "<urn:uuid:4f7034ce-2fbc-4dee-a910-b1f8a5eeb43d>", "WARC-Date": "2020-08-11T09:10:05Z", "WARC-IP-Address": "64.250.0.134", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:FVW2ITBXXB5QZOY24RUAEP3FBCIHHHPE", "WARC-Record-ID": "<urn:uuid:22408432-f534-423e-b3d4-a4b1758e15ff>", "WARC-Target-URI": "https://www.gvec.net/seven-tips-for-optimal-performance-from-your-home-internet/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:2c7d3a08-807a-422c-9b00-8885b1ae5918>" }, "warc_info": "isPartOf: CC-MAIN-2020-34\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for August 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-212.ec2.internal\r\nsoftware: Apache Nutch 1.17 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 18, 19, 367, 368, 587, 588, 612, 613, 803, 804, 1717, 1718, 1742, 1743, 2268, 2269, 2765, 2766, 3265, 3266, 3301, 3302, 3549, 3550, 3742, 3743, 3770, 3771, 4047, 4048, 4069, 4070, 4424, 4425, 4615, 4616, 4660, 4661, 5041, 5042, 5088, 5089, 5600, 5601, 5989, 5990, 6173, 6174, 6205, 6206, 6534, 6535, 6854, 6855 ], "line_end_idx": [ 18, 19, 367, 368, 587, 588, 612, 613, 803, 804, 1717, 1718, 1742, 1743, 2268, 2269, 2765, 2766, 3265, 3266, 3301, 3302, 3549, 3550, 3742, 3743, 3770, 3771, 4047, 4048, 4069, 4070, 4424, 4425, 4615, 4616, 4660, 4661, 5041, 5042, 5088, 5089, 5600, 5601, 5989, 5990, 6173, 6174, 6205, 6206, 6534, 6535, 6854, 6855, 6865 ] }
{ "red_pajama_v2": { "ccnet_original_length": 6865, "ccnet_original_nlines": 54, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.40439561009407043, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.010256409645080566, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.16117216646671295, "rps_doc_frac_unique_words": 0.4085923135280609, "rps_doc_mean_word_length": 5.097806453704834, "rps_doc_num_sentences": 70, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.496084690093994, "rps_doc_word_count": 1094, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.056123360991477966, "rps_doc_frac_chars_dupe_6grams": 0.056123360991477966, "rps_doc_frac_chars_dupe_7grams": 0.016137709841132164, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.011475699953734875, "rps_doc_frac_chars_top_3gram": 0.023668639361858368, "rps_doc_frac_chars_top_4gram": 0.027972029522061348, "rps_doc_books_importance": -594.69677734375, "rps_doc_books_importance_length_correction": -594.69677734375, "rps_doc_openwebtext_importance": -399.6820373535156, "rps_doc_openwebtext_importance_length_correction": -399.6820373535156, "rps_doc_wikipedia_importance": -311.8669738769531, "rps_doc_wikipedia_importance_length_correction": -311.8669738769531 }, "fasttext": { "dclm": 0.02616273984313011, "english": 0.9006837010383606, "fineweb_edu_approx": 1.7106242179870605, "eai_general_math": 0.012733220122754574, "eai_open_web_math": 0.1321139931678772, "eai_web_code": 0.011452440172433853 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.6", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "621.3846", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Engineering", "level_3": "Mechanical engineering and Machinery" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "6", "label": "Promotional/Advertisement" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "11", "label": "Legal Notices" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
273,628,866,780,726,700
Server engineer Interview Questions 324 Server Engineer interview questions shared by candidates Top Interview Questions Sort: Relevance|Popular|Date Berkshire Hathaway SQL Server Developer was asked...22 March 2015 If I knew what the cross apply operator was 4 Answers If they want the word its join, a description could be "the Cartesian product of multiplying the tables" and an example would be "like merging two matrices except every column may be of incongruent variables creating a result with polynomial rows, (which is likely no longer normalized to the form level of the database)" Less An Apply operator is a join type that the query engine evaluates in sequential order because the right-hand table object can reference data in the left-hand table object. The Cross Apply operator is the Apply operator that acts like an Inner Join, eliminating any records in the left-hand table object that have a null match in the right-hand table object. Less An Apply operator is a join type that the DB engine evaluates in sequential order because the right-hand table object can reference data in the left-hand table object. The Cross Apply operator is the Apply operator that acts like an Inner Join, eliminating any records in the left-hand table object that have a null match in the right-hand table object. Less Show More Responses Qualcomm How to discover if the given number is Power of 2 ? 4 Answers return (( x!=0) &amp;&amp; (x &amp; (x -1) == 0)) a number which is power of two will have single 1 in binary representation ex. 16 00010000 x-1 will have pattern 00001111 hence x&amp;(x-1) will always be 0 for power of two numbers. Need to check condition for x!=0 since 0 is not a power of two. Special case to handle. Less if you can figure this out inside an hour, congratulations this isnt something that should be in an interview to be honest the level of difficulty of the answer that algo came up with is at the level of an upper division course that has a proof of it written in wikipedia i honestly like the brute force solution Less Divide the number by 2, and repeat, until the result is a not an integer number (in this case is not a power of 2) or the result is 1 (in this case the number was a power of 2). Less Show More Responses Mobikwik write a shell script to detect ddos attack 2 Answers i had written the script The key in these questions is to cover the fundamentals, and be ready for the back-and-forth with the interviewer. Might be worth doing a mock interview with one of the MobiKwik or ex-MobiKwik Server Engineer experts on Prepfully? They give real-world practice and guidance, which is pretty helpful. prepfully.com/practice-interviews Less Kinaxis Come up a most efficient way to determine if a integer is odd or even. 2 Answers int number = ...; if(number % 2) { odd } else { even } Compilers are smart enough to understand the result of n%2. Don't over-complicate it. Less ERNST why you are looking for change? 2 Answers The job that I have doesn’t pay enough I answered honestly that i am looking for increase in salary Skillz - Override equals and hashcode - Implement ArrayList - question on wait/ notify - Design a ticket system 2 Answers Was able to answer every question. HR person said that he had got a good feedback from the panel and they will update me as early as possible. But, got rejected for no specific reason. Less Also for overriding hahcode and equal what was the input gievn to you? Qualcomm Binary tree , left node has smallest value . Print 5 10 20 25 and then “count of nodes=4”… 2 Answers recursion ... defined "current=head" in the method so it doesn't changes ofcourse, even if I sent current.next in recursion... don't be nervous! Less Did not get this question? Could you please eleborate it more? IBM What is the end plastic connector on a CAT 5 cable 2 Answers RJ45 connector Did you undergo face to face interview? Pocket Gems Implement a queue using two stacks. 2 Answers This one was easy. #include #include using namespace std; //class MyQueue template class MyQueue { public: MyQueue(){} // pay attention to this ~MyQueue() {} void push(T element) ; void pop() ; bool isEmpty() ; T front() ; T back() ; private: stack stack1 ; stack stack2 ; }; // stack1: newest elements // stack2: oldest elements template void MyQueue::push(T element) { stack1.push(element) ; } // pop the oldest element in the queue template void MyQueue::pop() { if ( stack2.empty()) // change to oldest { while (!stack1.empty()) { stack2.push(stack1.top()); stack1.pop(); } } stack2.pop(); } // oldest template T MyQueue::front() { if( stack2.empty() ) { while (!stack1.empty()) { stack2.push(stack1.top()); stack1.pop(); } } return stack2.top() ; } template T MyQueue::back() { if( stack1.empty() ) { while (!stack2.empty()) { stack1.push(stack2.top()); stack2.pop(); } } return stack1.top(); } template bool MyQueue::isEmpty() { if (stack1.empty() &amp;&amp; stack2.empty()) { return true ; } else return false ; } Less Pocket Gems Write a function that compares two strings and returns a third string containing only the letters that appear in both. 1 Answers string getcommstring(string s1,string s2) { string s; int size1 = s1.size() ; int size2 = s2.size() ; int hash[30] ; for (int i = 0 ; i &lt; 30 ; i++) { hash[i] = 0 ; } for ( int i = 0 ; i &lt; size1 ; i++ ) { hash[s1[i] - 'a'] = 1 ; } for (int i = 0 ; i &lt; size2 ; i++) { if ( hash[s2[i] - 'a'] == 1 ) { s.push_back(s2[i]) ; hash[s2[i]-'a']= 0 ; } } return s ; } Less Viewing 1 - 10 of 324 Interview Questions See Interview Questions for Similar Jobs systems engineersoftware applications engineerlinux engineerdesktop engineermobile engineerserver administrator
{ "url": "https://www.glassdoor.co.uk/Interview/server-engineer-interview-questions-SRCH_KO0,15.htm", "source_domain": "www.glassdoor.co.uk", "snapshot_id": "crawl=CC-MAIN-2022-27", "warc_metadata": { "Content-Length": "428989", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:WJZMRDXL53PRPCGTTS2EPCOGTL2UL54C", "WARC-Concurrent-To": "<urn:uuid:822e437a-e72e-4ed3-85d7-8b40919d2fab>", "WARC-Date": "2022-06-27T21:29:36Z", "WARC-IP-Address": "104.17.26.75", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:WKRKGRYI4F7AUOHDDZQJHOYDOIHSZCAW", "WARC-Record-ID": "<urn:uuid:2c76f360-70ec-420f-a6ac-1cba341a7442>", "WARC-Target-URI": "https://www.glassdoor.co.uk/Interview/server-engineer-interview-questions-SRCH_KO0,15.htm", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:78817307-10d4-4acf-ac36-65ed15db34d8>" }, "warc_info": "isPartOf: CC-MAIN-2022-27\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June/July 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-87\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 36, 37, 41, 42, 99, 100, 124, 125, 154, 173, 220, 221, 265, 266, 276, 277, 604, 605, 967, 968, 1327, 1328, 1348, 1357, 1358, 1410, 1411, 1421, 1422, 1748, 1749, 2067, 2068, 2251, 2252, 2272, 2281, 2282, 2325, 2326, 2336, 2337, 2362, 2363, 2702, 2703, 2711, 2712, 2783, 2784, 2794, 2795, 2850, 2851, 2942, 2943, 2949, 2950, 2982, 2983, 2993, 2994, 3033, 3034, 3095, 3096, 3103, 3104, 3209, 3210, 3220, 3221, 3411, 3412, 3483, 3484, 3493, 3494, 3585, 3586, 3596, 3597, 3747, 3748, 3811, 3812, 3816, 3817, 3868, 3869, 3879, 3880, 3895, 3896, 3936, 3937, 3949, 3950, 3986, 3987, 3997, 3998, 4017, 4018, 5025, 5026, 5038, 5039, 5158, 5159, 5169, 5170, 5541, 5542, 5584, 5585, 5626, 5627 ], "line_end_idx": [ 36, 37, 41, 42, 99, 100, 124, 125, 154, 173, 220, 221, 265, 266, 276, 277, 604, 605, 967, 968, 1327, 1328, 1348, 1357, 1358, 1410, 1411, 1421, 1422, 1748, 1749, 2067, 2068, 2251, 2252, 2272, 2281, 2282, 2325, 2326, 2336, 2337, 2362, 2363, 2702, 2703, 2711, 2712, 2783, 2784, 2794, 2795, 2850, 2851, 2942, 2943, 2949, 2950, 2982, 2983, 2993, 2994, 3033, 3034, 3095, 3096, 3103, 3104, 3209, 3210, 3220, 3221, 3411, 3412, 3483, 3484, 3493, 3494, 3585, 3586, 3596, 3597, 3747, 3748, 3811, 3812, 3816, 3817, 3868, 3869, 3879, 3880, 3895, 3896, 3936, 3937, 3949, 3950, 3986, 3987, 3997, 3998, 4017, 4018, 5025, 5026, 5038, 5039, 5158, 5159, 5169, 5170, 5541, 5542, 5584, 5585, 5626, 5627, 5738 ] }
{ "red_pajama_v2": { "ccnet_original_length": 5738, "ccnet_original_nlines": 118, "rps_doc_curly_bracket": 0.007668179925531149, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.29379844665527344, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.013178289867937565, "rps_doc_frac_lines_end_with_ellipsis": 0.008403359912335873, "rps_doc_frac_no_alph_words": 0.28992247581481934, "rps_doc_frac_unique_words": 0.4455782175064087, "rps_doc_mean_word_length": 4.851473808288574, "rps_doc_num_sentences": 65, "rps_doc_symbol_to_word_ratio": 0.005426359828561544, "rps_doc_unigram_entropy": 5.444230079650879, "rps_doc_word_count": 882, "rps_doc_frac_chars_dupe_10grams": 0.13601309061050415, "rps_doc_frac_chars_dupe_5grams": 0.1498013585805893, "rps_doc_frac_chars_dupe_6grams": 0.1437251716852188, "rps_doc_frac_chars_dupe_7grams": 0.13601309061050415, "rps_doc_frac_chars_dupe_8grams": 0.13601309061050415, "rps_doc_frac_chars_dupe_9grams": 0.13601309061050415, "rps_doc_frac_chars_top_2gram": 0.02056555077433586, "rps_doc_frac_chars_top_3gram": 0.014021970331668854, "rps_doc_frac_chars_top_4gram": 0.021500350907444954, "rps_doc_books_importance": -546.9807739257812, "rps_doc_books_importance_length_correction": -546.9807739257812, "rps_doc_openwebtext_importance": -372.7633972167969, "rps_doc_openwebtext_importance_length_correction": -372.7633972167969, "rps_doc_wikipedia_importance": -323.94171142578125, "rps_doc_wikipedia_importance_length_correction": -323.94171142578125 }, "fasttext": { "dclm": 0.4045766592025757, "english": 0.8077007532119751, "fineweb_edu_approx": 1.6903325319290161, "eai_general_math": 0.788849949836731, "eai_open_web_math": 0.20117872953414917, "eai_web_code": 0.28414058685302734 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
52,407,524,815,337,540
Kison Kison - 10 months ago 49 HTML Question Need to fit application width to device width What do i have? 1. Web app(just html,css,js), application has fixed width and height (1024*768); 2. Android application created with cordova by web application; 3. Testing android application on htc desire 500 (android version 4.1.2) Problem: I need width of application fit to device width on all android devices. Now my application is bigger then device width. What i tried to do? Changed viewport meta tag in different ways like <meta name="viewport" content="width=device-width, user-scalable=no" /> Used javascript to change app zoom (on deviceredy event) var contentWidth = document.body.scrollWidth, windowWidth = window.innerWidth, newScale = windowWidth / contentWidth; document.body.style.zoom = newScale; Used javascript to change viewport var ww = (jQuery(window).width() < window.screen.width) ? jQuery(window).width() : window.screen.width; // min width of site var mw = 1020; //calculate ratio var ratio = ww / mw; if (ww < mw) { jQuery('meta[type="viewport"]').attr('content', 'initial-scale=' + ratio + ', maximum-scale=' + ratio + ', minimum-scale=' + ratio + ', user-scalable=yes, width=' + ww); } else { jQuery('meta[type="viewport"]').attr('content', 'initial-scale=1.0, maximum-scale=2, minimum-scale=1.0, user-scalable=yes, width=' + ww); } But solutions that i describe above can`t help. Do anyone knows solution that can help do that i need? Answer I have solved problem by using css transform, this css property is similar to zoom but it is supported by all modern browsers. Notice: This solution appropriate just for fixed size layouts Function that i wrote to solve my problem (Just put body as element, and it initial size as height and width): /** * @param {string} element - element to apply zooming * @param {int} width - initial element width * @param {int} height - initial element heigth * @param {float} desiredZoom - which zoom you need, default value = 1 */ function zoomElement(element, width, height, desiredZoom) { desiredZoom = desiredZoom || 1; var zoomX = (jQuery(window).width() * desiredZoom) / width, zoomY = (jQuery(window).height() * desiredZoom) / height, zoom = (zoomX < zoomY) ? zoomX : zoomY; jQuery(element) .css('transform', 'scale(' + zoom + ')') .css('transform-origin', '0 0') // Internet Explorer .css('-ms-transform', 'scale(' + zoom + ')') .css('-ms-transform-origin', '0 0') // Firefox .css('-moz-transform', 'scale(' + zoom + ')') .css('-moz-transform-origin', '0 0') // Opera .css('-o-transform', 'scale(' + zoom + ')') .css('-o-transform-origin', '0 0') // WebKit .css('-webkit-transform', 'scale(' + zoom + ')') .css('-webkit-transform-origin', '0 0'); // Center element in it`s parent (function () { var $element = jQuery(element); // Remove previous timeout if ($element.data('center.timeout')) { console.log("clear timeout"); clearTimeout($element.data('center.timeout')); } var timeout = setTimeout(function () { $element.data('center.timeout', timeout); var parentSize = { 'height' : $element.parent().height(), 'width' : $element.parent().width() }, rect = element.get(0).getBoundingClientRect(); element.css({ 'marginTop' : 0, 'marginLeft' : 0 }); // Center vertically if (parentSize.height > rect.height) { var marginTop = (parentSize.height - rect.height) / 2; element.css('marginTop', marginTop); } // Center horizontally if (parentSize.width > rect.width) { var marginLeft = (parentSize.width - rect.width) / 2; element.css('marginLeft', marginLeft); } }, 300); })(); }
{ "url": "https://codedump.io/share/sr613U2pvJuT/1/need-to-fit-application-width-to-device-width", "source_domain": "codedump.io", "snapshot_id": "crawl=CC-MAIN-2017-22", "warc_metadata": { "Content-Length": "29643", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:ONLGE5DT7Q6RPQIW3R6ZUTYV2AOPF4BA", "WARC-Concurrent-To": "<urn:uuid:6531eeb2-dd0f-42c3-bcc8-0d01e24804b4>", "WARC-Date": "2017-05-27T20:01:31Z", "WARC-IP-Address": "84.22.103.185", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:XO4NZA667RZAJXFVSSLFW72YORH4YRDG", "WARC-Record-ID": "<urn:uuid:e279628c-bc0d-41de-b0f9-0c2fd975a13c>", "WARC-Target-URI": "https://codedump.io/share/sr613U2pvJuT/1/need-to-fit-application-width-to-device-width", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:3cbf6b49-f064-4a31-a1a2-aa241673ea5d>" }, "warc_info": "robots: classic\r\nhostname: ip-10-185-224-210.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2017-22\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for May 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 31, 45, 46, 92, 93, 109, 110, 111, 194, 195, 261, 262, 337, 338, 339, 340, 349, 469, 470, 490, 491, 540, 541, 613, 614, 615, 672, 673, 719, 752, 791, 828, 829, 830, 865, 866, 924, 970, 991, 1006, 1024, 1045, 1060, 1230, 1239, 1377, 1379, 1380, 1381, 1484, 1485, 1492, 1493, 1682, 1683, 1794, 1795, 1799, 1853, 1899, 1947, 2018, 2026, 2086, 2126, 2194, 2264, 2316, 2317, 2341, 2394, 2438, 2471, 2528, 2576, 2599, 2657, 2706, 2727, 2783, 2830, 2852, 2913, 2966, 2967, 3008, 3031, 3075, 3076, 3115, 3166, 3212, 3275, 3289, 3290, 3341, 3399, 3434, 3497, 3557, 3580, 3647, 3648, 3678, 3715, 3752, 3772, 3773, 3810, 3865, 3940, 3997, 4015, 4016, 4055, 4108, 4182, 4241, 4259, 4280, 4294 ], "line_end_idx": [ 31, 45, 46, 92, 93, 109, 110, 111, 194, 195, 261, 262, 337, 338, 339, 340, 349, 469, 470, 490, 491, 540, 541, 613, 614, 615, 672, 673, 719, 752, 791, 828, 829, 830, 865, 866, 924, 970, 991, 1006, 1024, 1045, 1060, 1230, 1239, 1377, 1379, 1380, 1381, 1484, 1485, 1492, 1493, 1682, 1683, 1794, 1795, 1799, 1853, 1899, 1947, 2018, 2026, 2086, 2126, 2194, 2264, 2316, 2317, 2341, 2394, 2438, 2471, 2528, 2576, 2599, 2657, 2706, 2727, 2783, 2830, 2852, 2913, 2966, 2967, 3008, 3031, 3075, 3076, 3115, 3166, 3212, 3275, 3289, 3290, 3341, 3399, 3434, 3497, 3557, 3580, 3647, 3648, 3678, 3715, 3752, 3772, 3773, 3810, 3865, 3940, 3997, 4015, 4016, 4055, 4108, 4182, 4241, 4259, 4280, 4294, 4299 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4299, "ccnet_original_nlines": 121, "rps_doc_curly_bracket": 0.0065131401643157005, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.09954751282930374, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.003393670078366995, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.4852941334247589, "rps_doc_frac_unique_words": 0.5133689641952515, "rps_doc_mean_word_length": 6.705882549285889, "rps_doc_num_sentences": 67, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.9465532302856445, "rps_doc_word_count": 374, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.017942579463124275, "rps_doc_frac_chars_top_3gram": 0.010366830043494701, "rps_doc_frac_chars_top_4gram": 0.017543859779834747, "rps_doc_books_importance": -332.29315185546875, "rps_doc_books_importance_length_correction": -332.29315185546875, "rps_doc_openwebtext_importance": -186.78573608398438, "rps_doc_openwebtext_importance_length_correction": -186.78573608398438, "rps_doc_wikipedia_importance": -161.53590393066406, "rps_doc_wikipedia_importance_length_correction": -161.53590393066406 }, "fasttext": { "dclm": 0.3889489769935608, "english": 0.43238815665245056, "fineweb_edu_approx": 1.5976980924606323, "eai_general_math": 0.4072922468185425, "eai_open_web_math": 0.09076952934265137, "eai_web_code": 0.23995250463485718 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "5", "label": "Social/Forum" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,399,797,183,005,687,000
Pin Me Just What Is An MMO Game? by: MD Weems ; edited by: Michael Hartman ; updated: 4/17/2012 • Leave a comment Ever wonder just what the difference is in a normal pc game and an MMO? Well, search no further, here is your explanation of what an MMO game really is. • slide 1 of 3 So What Is An MMO? An MMO, or massively multiplayer online game, is basically a video game that has the ability to support hundreds, or even thousands, of different players online at any one time. For this reason, these games are normally played over the Internet and will always have at least one common “world" in the game. In today's market, these MMO games are no longer just on the PC, but many console games are now falling under the MMO category, as console makers utilize new technology and Internet links to allow gamers to play with other gamers all over the world on several different consoles, such as the Playstation 3, Wii, Nintendo DS, and the Xbox 360. In an MMO, gamers can play with other gamers all over the world, allowing them to compete (Player versus Player) and cooperate in different ways, such as finishing up quests, defeating hard NPC's (non-player characters), and creating items that other players can use. There is a wide variety of gaming types when it comes to MMOs that are spread all over different video game genres. • slide 2 of 3 What Makes An MMO Different Than Other Games? Well, there are actually a number of different characteristics that are shared by the vast majority of MMOs that make them completely different than other games out there on the market. For example, MMOs offer a stable, alter-universe that will exist and continue playing no matter if gamers are online or not – the sun sets, the sun rises, and it doesn't matter who is there to see it. While the majority of MMO games emphasize multiplayer options and play, these games will continue to run with artificial intelligence on the client that the game is set on, which allows players to log in and play, but also does not allow players to “beat" the game as they would in a normal PC or console game. But, MMO's also share several other characteristics between them that set them apart from other games. For example, they host a large group of players in one game area, or world, and all of these players can play together – either on the same side or against them – at any time they log into the game. So, what constitutes an MMO and just a game that offers multiplayer action? Well, typically, MMO games have over 50 players online at any time, per server or client, according to Wikipedia. Those games that have under 50 players online at any time and play on private servers, such as Half-Life. There are many people out there in the game industry who are still debating whether a high player count on each server is the qualifying mark that will classify a game as an MMO or not, while others argue that it is the size of the in-game world itself and the ability of that world to support a large number of players, no matter if it does or not. The reason behind the last argument is that most games that fall right on the line of the MMO definition, usually have the ability to support a large number of gamers, such as in the thousands, on one server at any time. Now, to help support all of the masses of players on an MMO, the game will need several servers that can support the online gamers and worlds, unlike a normal pc or console game that only needs the game itself to support one player. Most MMO games feature multiple servers, where the world is always the same, but different players play on different servers and the players on one server don't come into contact with players on another server. These are called “sharded" universes, and many of the more popular MMO games on the market will have over 10 of these servers, sometimes up towards a hundred servers running at one time. • slide 3 of 3 In The End In the end, there are still more differences between normal games and MMO games. For example, MMO games normally charge the player a monthly fee so that they can have access to the servers, or they will offer another type of incentive for the players to purchase “gold" or items from the game company to use in the game to get the character ahead of others. Another difference is that the “game" of the MMO never resets when the player logs out. This means that when a player completes special levels or quests, that same accomplishment will still be there tomorrow. Also, MMO games offer gamers the ability to band together, usually in the form of a guild or clan. This helps those gamers gear up together and get special areas of the game completed. But, sometimes the boundaries of these MMO games are a bit hard to determine, as some games will fall into both categories. In those cases, it is best to go with what the manufacturer deems the game to be. Popular Pages More Info
{ "url": "http://www.alteredgamer.com/pc-gaming/15224-just-what-is-an-mmo-game/", "source_domain": "www.alteredgamer.com", "snapshot_id": "crawl=CC-MAIN-2017-22", "warc_metadata": { "Content-Length": "224072", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:JJ57PNVXVLB2SXQCHZ36YGBFYIZKWK4J", "WARC-Concurrent-To": "<urn:uuid:6de53ba9-9d21-40d7-8a72-b6a940d8f12e>", "WARC-Date": "2017-05-29T11:26:09Z", "WARC-IP-Address": "104.28.15.40", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:FEH2W7PRP63CKPBVAJVX6Q6X6JA6ZV3Y", "WARC-Record-ID": "<urn:uuid:85b218bd-9ea4-40d7-8c06-6db9060ef099>", "WARC-Target-URI": "http://www.alteredgamer.com/pc-gaming/15224-just-what-is-an-mmo-game/", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:a5903097-66e6-4aad-8cb6-4a21d11a8e16>" }, "warc_info": "robots: classic\r\nhostname: ip-10-185-224-210.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2017-22\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for May 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 7, 8, 34, 35, 116, 117, 270, 271, 288, 289, 312, 313, 1351, 1352, 1369, 1370, 1420, 1421, 2123, 2124, 2726, 2727, 3302, 3303, 3938, 3939, 3956, 3957, 3972, 3973, 4935, 4936, 4937, 4938, 4952, 4953 ], "line_end_idx": [ 7, 8, 34, 35, 116, 117, 270, 271, 288, 289, 312, 313, 1351, 1352, 1369, 1370, 1420, 1421, 2123, 2124, 2726, 2727, 3302, 3303, 3938, 3939, 3956, 3957, 3972, 3973, 4935, 4936, 4937, 4938, 4952, 4953, 4962 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4962, "ccnet_original_nlines": 36, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4712195098400116, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.027317069470882416, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.13560976088047028, "rps_doc_frac_unique_words": 0.3426339328289032, "rps_doc_mean_word_length": 4.341517925262451, "rps_doc_num_sentences": 32, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.064201354980469, "rps_doc_word_count": 896, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.05295630171895027, "rps_doc_frac_chars_dupe_6grams": 0.05295630171895027, "rps_doc_frac_chars_dupe_7grams": 0.017480719834566116, "rps_doc_frac_chars_dupe_8grams": 0.017480719834566116, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.019794339314103127, "rps_doc_frac_chars_top_3gram": 0.009254500269889832, "rps_doc_frac_chars_top_4gram": 0.013881750404834747, "rps_doc_books_importance": -402.26812744140625, "rps_doc_books_importance_length_correction": -402.26812744140625, "rps_doc_openwebtext_importance": -213.48204040527344, "rps_doc_openwebtext_importance_length_correction": -213.48204040527344, "rps_doc_wikipedia_importance": -67.52030181884766, "rps_doc_wikipedia_importance_length_correction": -67.52030181884766 }, "fasttext": { "dclm": 0.13376593589782715, "english": 0.9663650989532471, "fineweb_edu_approx": 1.5921776294708252, "eai_general_math": 0.019608139991760254, "eai_open_web_math": 0.12120550870895386, "eai_web_code": 0.028355060145258904 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.67", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "004.6", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "10", "label": "Knowledge Article" }, "secondary": { "code": "9", "label": "FAQ" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,735,126,769,428,358,000
Noise What is a sound card in a computer9 min read Aug 27, 2022 6 min What is a sound card in a computer9 min read Reading Time: 6 minutes A sound card in a computer is a device that processes and outputs audio signals. Sound cards are used to provide sound effects and music for games, to record and play back audio, and to communicate with other audio devices. There are many different types of sound cards, but most share the same basic components. Sound cards have a digital-to-analog converter (DAC), which converts digital audio signals into an analog form that can be played back by a speaker or headphone. They also have an amplifier, which increases the power of the signal so that it can be played back at a high volume. Most sound cards also have a microphone input, which allows you to connect a microphone and record audio. They also have a line input, which lets you connect an external audio device, like a CD player or cassette tape deck, and play its audio through the computer. Some sound cards also have a digital output, which sends a digital audio signal to an external device, like a digital-to-analog converter. This can be used to send audio from the computer to a home theater system. Sound cards are usually installed in the computer’s motherboard, but there are also external sound cards that can be connected to the computer via a USB port. Do I need sound card for my computer? Do you need a sound card for your computer? The answer to this question is not always a straightforward one. In general, if your computer does not have a built-in sound card, you will need to purchase and install a separate sound card in order to use sound features on your system. However, there are a few exceptions to this rule. For example, if you are using a laptop with Windows 10, you may not need to install a separate sound card, as Windows 10 includes a built-in sound card. Additionally, if you are using a Mac computer, the sound card is already built in and does not need to be installed separately. If you are not sure whether or not you need a sound card, the best thing to do is to check the specifications for your computer or laptop. If a sound card is not listed as one of the included components, then you will likely need to purchase and install one separately. When purchasing a sound card, there are a few things to consider. One of the most important factors is the type of ports that the card has. Most sound cards include a variety of ports, including a headphone jack, a microphone jack, and a line-in jack. See also  Who is the angel of music Another thing to consider is the type of audio that the card supports. There are a few different types of audio, including analog and digital. If your computer or laptop already has a built-in sound card, it is likely that it supports analog audio. If you are purchasing a new sound card, it is important to make sure that it supports the type of audio that your computer uses. In general, if your computer does not have a built-in sound card, you will need to purchase and install a separate sound card in order to use sound features on your system. However, there are a few exceptions to this rule, so it is important to check the specifications for your computer or laptop. When purchasing a sound card, it is important to consider the type of ports that the card has and the type of audio that it supports. How do I know if I have a sound card? Do you want to know how to find out if you have a sound card? Your computer may not have a sound card installed, or the sound card may be integrated into the motherboard. You can determine if you have a sound card installed by checking the Device Manager. To check the Device Manager, go to the Start menu and type "Device Manager" into the search bar. Then, press the Enter key. The Device Manager window will open. In the Device Manager window, expand the "Sound, video and game controllers" category. If you see a sound card listed in the category, you have a sound card installed. If you don’t see a sound card listed in the "Sound, video and game controllers" category, you may not have a sound card installed. However, you can check the motherboard to see if the sound card is integrated into the motherboard. To check the motherboard, open the computer case and look for a sound card chip on the motherboard. If you don’t see a sound card installed and you don’t see a sound card chip on the motherboard, you may not have a sound card. In this case, you may want to purchase a sound card. Where is the sound card on a PC? Where is the sound card on a PC? The sound card on a PC is typically located on the motherboard. It is a rectangular card with several connectors on it, including a headphone jack, a microphone jack, and several audio input and output jacks. The sound card is responsible for converting digital audio signals into sound that can be heard through the speakers or headphones attached to the PC. See also  How to share music on instagram story Do PC sound cards make a difference? Do PC sound cards make a difference? This is a question that has been asked by PC users for many years. In the early days of PC gaming, many people believed that a sound card was a necessary purchase in order to get the best gaming experience. However, with the advent of better integrated audio solutions on motherboards, as well as the increasing popularity of gaming laptops, does this still hold true? To answer this question, it is important to first understand the different types of sound cards that are available. The most common type of sound card is the internal sound card, which is integrated into the motherboard. Another type of sound card is the external sound card, which is a standalone card that is connected to the PC via a USB port or an audio port. Internal sound cards are typically less expensive and are good enough for most people’s needs. External sound cards, on the other hand, are typically more expensive, but they offer features that are not available on internal sound cards, such as higher-quality audio and more inputs and outputs. So, do PC sound cards make a difference? In most cases, the answer is no. Internal sound cards are more than adequate for most people’s needs, and external sound cards are only necessary for people who require more features or higher-quality audio. Are sound cards still relevant? In an age of integrated audio solutions and powerful mobile devices, it might be fair to ask whether sound cards are still relevant. The answer, as it turns out, is a resounding yes. Though integrated audio chipsets have come a long way in recent years, they still can’t match the quality and flexibility of a good sound card. For one, sound cards can support more audio channels than integrated chipsets, making them ideal for gaming and home theater applications. What’s more, sound cards offer greater control over audio settings, allowing users to fine-tune audio quality to their specific needs. This level of control is essential for users who demand the best possible audio quality, such as audiophiles and professional musicians. Finally, sound cards are more versatile than integrated chipsets, as they can be used with a wide range of devices, including PCs, laptops, tablets, and smartphones. This flexibility makes them a good choice for users who need to move between different devices frequently. In short, sound cards are still very relevant in today’s audio market. If you’re looking for the best possible audio quality, a sound card is the way to go. See also  Which ear is better for music How do I install a sound card? Installing a sound card can be a daunting task, but with the right instructions, it can be a breeze. In this article, we will walk you through the process of installing a sound card in your computer. First, you will need to gather the necessary equipment. This includes the sound card itself, a screwdriver, and an adapter if your computer does not have a free PCI slot. Once you have the necessary equipment, you will need to open your computer case. This can be done by removing the screws on the back of the case. Once the case is open, you will need to locate the motherboard. The sound card will be installed on the motherboard, so you will need to find the appropriate slot. Next, you will need to remove the old sound card, if there is one installed. This can be done by using the screwdriver to remove the screws that hold the card in place. Once the screws are removed, you can pull the card out of the slot. Now, you can install the new sound card. This can be done by placing the card in the appropriate slot and securing it in place with the screws. Once the card is installed, you can close the computer case and restart your computer. Your computer should now be ready to use your new sound card! What does a sound card look like? A sound card is a computer hardware device that produces sound. The sound card connects to the motherboard of the computer and allows the computer to produce sound. Sound cards come in a variety of different shapes and sizes. The most common type of sound card is the PCI sound card. PCI sound cards are rectangular in shape and have several connectors on the back of the card. The connectors allow the sound card to be connected to the computer motherboard and to other devices, such as speakers. Another type of sound card is the USB sound card. USB sound cards are small and rectangular in shape. They have a USB connector on one end that allows the card to be connected to a USB port on the computer. Some sound cards also include a built-in microphone. This allows the computer to be used as a digital audio recorder. A sound card is an essential piece of computer hardware for anyone who wants to listen to music or watch videos on their computer.
{ "url": "https://renownsoundlightsanddjs.com/what-is-a-sound-card-in-a-computer/", "source_domain": "renownsoundlightsanddjs.com", "snapshot_id": "CC-MAIN-2023-23", "warc_metadata": { "Content-Length": "64454", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:5Z2YGIWC5FJM743UP2RB272BN3E5TSCR", "WARC-Concurrent-To": "<urn:uuid:f562e325-30ab-47b6-9670-623355ca795c>", "WARC-Date": "2023-06-04T11:05:24Z", "WARC-IP-Address": "104.21.56.227", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:KPNXPYKIJKDKBKOVJZOP2TDV7YF3PXS4", "WARC-Record-ID": "<urn:uuid:0df9ed78-3489-4c01-be82-4bb3914eee1e>", "WARC-Target-URI": "https://renownsoundlightsanddjs.com/what-is-a-sound-card-in-a-computer/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:c7324e0a-4267-49a6-a427-2faca6d271d5>" }, "warc_info": "isPartOf: CC-MAIN-2023-23\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May/June 2023\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-36\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 6, 7, 52, 53, 72, 73, 118, 119, 143, 144, 368, 369, 737, 738, 1003, 1004, 1218, 1219, 1378, 1379, 1417, 1418, 1700, 1701, 2032, 2033, 2303, 2304, 2556, 2557, 2593, 2594, 2972, 2973, 3406, 3407, 3445, 3446, 3702, 3703, 4032, 4033, 4364, 4365, 4545, 4546, 4579, 4580, 4613, 4614, 4974, 4975, 5023, 5024, 5061, 5062, 5099, 5100, 5469, 5470, 5834, 5835, 6131, 6132, 6381, 6382, 6414, 6415, 6598, 6599, 6882, 6883, 7155, 7156, 7429, 7430, 7587, 7588, 7628, 7629, 7660, 7661, 7861, 7862, 8033, 8034, 8344, 8345, 8582, 8583, 8814, 8815, 8877, 8878, 8912, 8913, 9139, 9140, 9412, 9413, 9620, 9621, 9739, 9740 ], "line_end_idx": [ 6, 7, 52, 53, 72, 73, 118, 119, 143, 144, 368, 369, 737, 738, 1003, 1004, 1218, 1219, 1378, 1379, 1417, 1418, 1700, 1701, 2032, 2033, 2303, 2304, 2556, 2557, 2593, 2594, 2972, 2973, 3406, 3407, 3445, 3446, 3702, 3703, 4032, 4033, 4364, 4365, 4545, 4546, 4579, 4580, 4613, 4614, 4974, 4975, 5023, 5024, 5061, 5062, 5099, 5100, 5469, 5470, 5834, 5835, 6131, 6132, 6381, 6382, 6414, 6415, 6598, 6599, 6882, 6883, 7155, 7156, 7429, 7430, 7587, 7588, 7628, 7629, 7660, 7661, 7861, 7862, 8033, 8034, 8344, 8345, 8582, 8583, 8814, 8815, 8877, 8878, 8912, 8913, 9139, 9140, 9412, 9413, 9620, 9621, 9739, 9740, 9870 ] }
{ "red_pajama_v2": { "ccnet_original_length": 9870, "ccnet_original_nlines": 104, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.45059287548065186, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.013833990320563316, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.11561264842748642, "rps_doc_frac_unique_words": 0.22335025668144226, "rps_doc_mean_word_length": 4.4128594398498535, "rps_doc_num_sentences": 101, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.978228569030762, "rps_doc_word_count": 1773, "rps_doc_frac_chars_dupe_10grams": 0.053936611860990524, "rps_doc_frac_chars_dupe_5grams": 0.25498464703559875, "rps_doc_frac_chars_dupe_6grams": 0.18430469930171967, "rps_doc_frac_chars_dupe_7grams": 0.15784764289855957, "rps_doc_frac_chars_dupe_8grams": 0.09815950691699982, "rps_doc_frac_chars_dupe_9grams": 0.07438649982213974, "rps_doc_frac_chars_top_2gram": 0.07016871124505997, "rps_doc_frac_chars_top_3gram": 0.03706543892621994, "rps_doc_frac_chars_top_4gram": 0.01163087971508503, "rps_doc_books_importance": -817.685546875, "rps_doc_books_importance_length_correction": -817.685546875, "rps_doc_openwebtext_importance": -489.4678649902344, "rps_doc_openwebtext_importance_length_correction": -489.4678649902344, "rps_doc_wikipedia_importance": -320.7416687011719, "rps_doc_wikipedia_importance_length_correction": -320.7416687011719 }, "fasttext": { "dclm": 0.6567022204399109, "english": 0.9558439254760742, "fineweb_edu_approx": 2.620358943939209, "eai_general_math": 0.0465206503868103, "eai_open_web_math": 0.09377992153167725, "eai_web_code": 0.018979249522089958 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "004.17", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "10", "label": "Knowledge Article" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
4,070,087,050,324,235,000
you are viewing a single comment's thread. view the rest of the comments → [–]IDyslexicAm 0 points1 point  (0 children) sorry, this has been archived and can no longer be voted on Well, for example I have about 50 games, the entire adobe creative suite CS6, microsoft office 2013, and a slew of other assorted programs that I use for productivity purposes and other misc things. Really, what's going to affect it is the aging of the SSD and the amount of data you have stored on the SSD. In theory, the fastest OS boot would be an SSD that has nothing but the OS on it.
{ "url": "http://www.reddit.com/r/buildapc/comments/1oam3w/how_do_people_get_singledigit_boot_times_5s_8s_etc/ccqi2mi", "source_domain": "www.reddit.com", "snapshot_id": "crawl=CC-MAIN-2014-41", "warc_metadata": { "Content-Length": "48606", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:VPOSGUAJKPGQDFNF62H7HQIFE7UEOFU2", "WARC-Concurrent-To": "<urn:uuid:d679f2d8-0510-4150-a0dc-7fd3fa62b928>", "WARC-Date": "2014-09-15T05:14:59Z", "WARC-IP-Address": "198.41.209.140", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:PM3Y7JBWYCYBQDCZRH5A66RPMIFSY4GM", "WARC-Record-ID": "<urn:uuid:729fc356-7ce5-4158-84ba-818445ce795a>", "WARC-Target-URI": "http://www.reddit.com/r/buildapc/comments/1oam3w/how_do_people_get_singledigit_boot_times_5s_8s_etc/ccqi2mi", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:7a5ef918-9b8d-42d2-8ba5-863a36191c25>" }, "warc_info": "robots: classic\r\nhostname: ip-10-196-40-205.us-west-1.compute.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-41\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for September 2014\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 43, 44, 76, 77, 122, 123, 183, 184, 383, 384 ], "line_end_idx": [ 43, 44, 76, 77, 122, 123, 183, 184, 383, 384, 574 ] }
{ "red_pajama_v2": { "ccnet_original_length": 574, "ccnet_original_nlines": 10, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.4560000002384186, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.06400000303983688, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.1679999977350235, "rps_doc_frac_unique_words": 0.7102803587913513, "rps_doc_mean_word_length": 4.158878326416016, "rps_doc_num_sentences": 4, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.154334545135498, "rps_doc_word_count": 107, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.02247191034257412, "rps_doc_frac_chars_top_3gram": 0, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -44.14424133300781, "rps_doc_books_importance_length_correction": -58.46883773803711, "rps_doc_openwebtext_importance": -26.760671615600586, "rps_doc_openwebtext_importance_length_correction": -41.085269927978516, "rps_doc_wikipedia_importance": -13.056719779968262, "rps_doc_wikipedia_importance_length_correction": -27.381317138671875 }, "fasttext": { "dclm": 0.5728803277015686, "english": 0.9497605562210083, "fineweb_edu_approx": 1.4284183979034424, "eai_general_math": 0.07803463935852051, "eai_open_web_math": 0.21020519733428955, "eai_web_code": 0.005518670193850994 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.456", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "1", "label": "Truncated Snippets" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "5", "label": "Comment Section" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-8,916,125,387,844,451,000
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute: Sign up Here's how it works: 1. Anybody can ask a question 2. Anybody can answer 3. The best answers are voted up and rise to the top It's easy to check that for any natural $n$ $$\frac{n+1}{n}=\cfrac{1}{2-\cfrac{n+2}{n+1}}.$$ Now, $$1=\frac{1}{2-1}=\frac{1}{2-\cfrac{1}{2-1}}=\frac{1}{2-\cfrac{1}{2-\cfrac{1}{2-1}}}=\cfrac{1}{2-\cfrac{1}{2-\frac{1}{2-\frac{1}{2-1}}}}=\ldots =\cfrac{1}{2-\cfrac{1}{2-\frac{1}{2-\frac{1}{2-\frac{1}{2-\dots}}}}},$$ $$2=\cfrac{1}{2-\cfrac{3}{2}}=\cfrac{1}{2-\cfrac{1}{2-\cfrac{4}{3}}}=\cfrac{1}{2-\cfrac{1}{2-\frac{1}{2-\frac{5}{4}}}}=\cfrac{1}{2-\cfrac{1}{2-\cfrac{1}{2-\frac{1}{2-\frac{6}{5}}}}}=\ldots =\cfrac{1}{2-\frac{1}{2-\frac{1}{2-\frac{1}{2-\frac{1}{2-\ldots}}}}}.$$ Since the right hand sides are the same, hence $1=2$. share|cite|improve this question 30   they arent the same. One right hand side is a continued fraction that converges to 2, one converges to 1. By using the dots, you cut away information. – CBenni Jun 11 '13 at 10:10 6   Just because $\frac{n}{n+1}$ tends to 1 as $n$ tends to $\infty$ doesn't mean that when you take the whole limit, it is equal to the first expression where you just have $2-1$ in the denominator of the repeating stuff. Also, the fact that you get $1=2$ should immediately tell you that you have went wrong somewhere. – Andrew D Jun 11 '13 at 10:25 7   @MherSafaryan no you dont. Dots imply a repitition of a given structure; They are not a rigorous mathematical notation. – CBenni Jun 11 '13 at 10:58 14   Is there an implied question here? E.g. "what's wrong with this fake proof"? – LarsH Jun 11 '13 at 14:38 3   Uh ya...what's the question? – nzifnab Jun 11 '13 at 16:27 up vote 60 down vote accepted Another example where dots are misleading: $$1= \frac{ 1 \cdot \color{blue}{2} \cdot \color{green}{3} \cdot \color{red}{4} \cdots}{ 2 \cdot \color{blue}{3} \cdot \color{green}{4} \cdot \color{red}{5} \cdots} \leq \frac{1}{2}$$ share|cite|improve this answer 4   The dots are not misleading here, it is clear in both interpretations what the dots are replacing, unlike the question and @Didi's example. – jwg Jun 27 '13 at 8:25 2   Maybe just rephrasing @jwg's comment, I fail to see what explains the $=$ sign here. – Did Aug 13 '13 at 9:06      I didn't want to make my comment dismissive; in fact, I don't really understand the problem. – Seirios Aug 13 '13 at 9:48 2   Seirios: this fallacy is based on the order of taking limits (like many others). The crux of it is that $\lim\left(\frac{n!}{n!}\right)$ is not the same as $\frac{\lim(n!)}{\lim(n!)}$. Mine and @Did's comments are trying to say that this is not the same as 'hiding' two different expressions behind an ellipsis. – jwg Aug 13 '13 at 10:11      Would you prefer it if I deduced $1 \leq \frac{1}{2}$ from $1= \frac{1}{1}= \frac{1 \cdot 2}{1 \cdot 2} = \dots= \frac{1 \cdot 2 \cdot 3 \cdots}{1 \cdot 2 \cdot 3 \cdots}$ and $\frac{1}{2}= \frac{1}{1 \cdot 2} \geq \frac{1 \cdot 2}{1 \cdot 2 \cdot 3} \geq \frac{1 \cdot 2 \cdot 3}{1 \cdot 2 \cdot 3 \cdot 4} \geq \dots \geq \frac{1 \cdot 2 \cdot 3 \cdots}{1 \cdot 2 \cdot 3 \cdots}$? – Seirios Aug 13 '13 at 11:01 A variant: note that $$\color{red}{\mathbf 1}=0+\color{red}{\mathbf 1}=0+0+\color{red}{\mathbf 1}=0+0+\cdots+0+\color{red}{\mathbf 1}=0+0+0+\cdots$$ and $$\color{green}{\mathbf 2}=0+\color{green}{\mathbf 2}=0+0+\color{green}{\mathbf 2}=0+0+\cdots+0+\color{\mathbf green}{2}=0+0+0+\cdots$$ "Since the right hand sides are the same", this proves that $\color{red}{\mathbf 1}=\color{green}{\mathbf 2}$. share|cite|improve this answer 24   Damn, this is a simple, straightforward and elegant as one can expect! +1 – DonAntonio Jun 11 '13 at 11:27 4   @DonAntonio I think it is invalid. It should be written as $$\Large\color{blue}{1}=0+0+0+\cdots+\Large\color{blue}{1}$$ and $$\Large\color{red}{2}=0+0+0+\cdots+\Large\color{red}{2}$$ – Tunk-Fey Apr 13 '14 at 9:40 5   @Did Well, I just think instead of showing other fallacies of $1=2$, why didn't show a valid proof that the argument in the question is wrong. – Tunk-Fey Apr 13 '14 at 11:35 3   @Tunk-Fey Because explanations by analogy may be valuable (as a long tradition shows). But you still did not explain why, in your first comment, you saw fit to throw around the word "invalid"... – Did Apr 13 '14 at 11:38 2   @Did OK, since I'm the first one to start this 'debate', I won't continue it any further. It seems we agree to disagree. :) – Tunk-Fey Apr 13 '14 at 12:00 The first expression is a continued fraction, the second isn't. A continued fraction is the limit of $$ a_0, a_0 + \frac{1}{a_1}, a_0 + \frac{1}{a_1 + \frac{1}{a_2}} \ldots $$ for a fixed sequence of natural numbers $a_0, a_1, a_2 \ldots$ The second expression is the limit of fractions which look similar to these fractions, but which don't correspond to one well-defined sequence of naturals. The first lot of dots (between the equals signs) are ok, they just mean 'take the limit of this process'. This limit exists and is equal to 2, as you correctly deduce. The dots at the bottom of the final expression falsely suggest that the limit is a continued fraction, with coefficients given by the obvious sequence (eg $2, 2, 2, 2, \ldots$ implies the sequence consisting of only twos). As @Did points out very elegantly, the same rules apply to infinite sums, and seem more obvious there - an infinite sum is not the same as the limit of an infinite sequence of sums, each with more terms in it than the one before. The common terms have to agree for any two sums. I think this misunderstanding arises because sometime in iteration and limits we have the sense that the initial terms don't really matter, and sometimes this is the case. The first few terms of a sequence don't affect the limit, or the limit of the average, etc. You are taking two different starting terms and iteratively applying a transformation to them. As you point out, this transformation doesn't actually change the number. This fact means though, that the starting value never becomes unimportant, and the final terms of each expression in your sequence similarly never become unimportant. share|cite|improve this answer This is of the same type as the following $$0=(1-1)+(1-1)+(1-1)+\ldots=1+(-1+1)+(-1+1)+(-1+1)+\ldots = 1 \; .$$ Did's example is even simpler and closer to yours in spirit. In working with an infinite number of operations, you have to be very careful about how you are performing them. Normally, one uses some kind of limit, but then what you really do is define a sequence of finite but ever increasing number of operations. Changing something in the order of these operations will change the entire limit. Or in your case, you hide away the fact that in each term of your sequence, the last operation is subtracting a different number, $1$ in the first case, $(n+2)/(n+1)$ in the second. share|cite|improve this answer This is a general feature of continued fractions. What you are doing is iterating the function $$ s(x) = \frac{1}{2-x} $$ ... so, for instance, you have that $$ 1 = s(1) = s(s(1)) = s(s(s(1))) = \cdots $$ and $$ 2 = s(3/2) = s(s(4/3)) = s(s(s(5/4))) = \cdots .$$ The function $s$ has a single fixed point at 1 (first line). It is known that iterating $s$ from any starting point except $x=2$ converges to 1 (think of $s$ as a mapping of the Riemann sphere; it takes $2 \mapsto \infty$ and $\infty \mapsto 0$). For $x<1$, this is easy to check: $x<s(x)<1$. So, if $x\neq 2$, then $$ \lim_{n \to \infty} s^n(x) = 1 , $$ where $s^n(x)=s(s(\cdots s(x)))$ is the $n$th iterate of $s$. But if you start with some $y$, it's always possible to find an $x_n$ so that $s^n(x_n) = y$ (including $\infty$, the map is one-to-one). You've shown that $$s^n\left(\frac{n+2}{n+1}\right) = 2.$$ Another nice thing to note here is that if the numbers at the end of the fractions (the $x_n$) weren't approaching 1 from above, we'd end up with 1 -- $$ \lim_n s^n(x_n) \neq 1 $$ then $$ x_n \searrow 1 .$$ share|cite|improve this answer Today one friend of mine show a way to the fallacy $1=2$ in the given way described below. Note that $$\begin{align} \log \,2 &=\log\, (1+1) \\&=1 -\dfrac 12 +\dfrac 13 -\dfrac 14 +\dfrac 15-\dfrac 16 +\dfrac 17 -\cdots \\ &= \left(1 +\dfrac 12 +\dfrac 13 +\dfrac 14 +\dfrac 15+\dfrac 16 +\dfrac 17 +\cdots\right)-2\times\left(\dfrac 12 +\dfrac 14 +\dfrac 16 +\dfrac 1{10}+\dfrac 1{12} +\dfrac 1{14} +\cdots\right)\\&=\left(1 +\dfrac 12 +\dfrac 13 +\dfrac 14 +\dfrac 15+\dfrac 16 +\dfrac 17 +\cdots\right)-\left(1 +\dfrac 12 +\dfrac 13 +\dfrac 14 +\dfrac 15+\dfrac 16 +\dfrac 17 +\cdots\right)\\&=\left(1-1\right)+\left(\dfrac12-\dfrac12\right)+\left(\dfrac13-\dfrac13\right)+\left(\dfrac14-\dfrac14\right)+\left(\dfrac15-\dfrac15\right)+\left(\dfrac16-\dfrac16\right)+ \cdots\\&=0+0+0+0+0+0+\cdots \\&=0\\&=\log\,1\end{align}$$ This implies $1=2.$ Hence it is proved. That's all from me. share|cite|improve this answer protected by Alexander Gruber Jun 11 '13 at 19:48 Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count). Would you like to answer one of these unanswered questions instead? Not the answer you're looking for? Browse other questions tagged or ask your own question.
{ "url": "http://math.stackexchange.com/questions/417280/continued-fraction-fallacy-1-2", "source_domain": "math.stackexchange.com", "snapshot_id": "crawl=CC-MAIN-2016-30", "warc_metadata": { "Content-Length": "113357", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:2BUV2URREPBRBF5PF7I7GVM6W7CPM5D4", "WARC-Concurrent-To": "<urn:uuid:fff261ad-135e-4fa3-ba60-45641c75438a>", "WARC-Date": "2016-07-24T16:44:46Z", "WARC-IP-Address": "151.101.1.69", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:SXRSLV6273R5N4JLZE2IQ7MIFX25G3ZM", "WARC-Record-ID": "<urn:uuid:90d86d9f-05cc-4421-a1be-569182580116>", "WARC-Target-URI": "http://math.stackexchange.com/questions/417280/continued-fraction-fallacy-1-2", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:167cedf4-df74-4ec3-a032-3e82120d6c69>" }, "warc_info": "robots: classic\r\nhostname: ip-10-185-27-174.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-30\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for July 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 167, 168, 176, 197, 229, 253, 308, 309, 402, 403, 408, 409, 625, 626, 887, 888, 942, 943, 976, 981, 1161, 1165, 1513, 1517, 1666, 1671, 1776, 1780, 1839, 1869, 1870, 2097, 2098, 2129, 2133, 2298, 2302, 2412, 2417, 2539, 2543, 2881, 2886, 3300, 3301, 3701, 3702, 3733, 3738, 3845, 3849, 4062, 4066, 4240, 4244, 4465, 4469, 4624, 4625, 4864, 4865, 5412, 5413, 5692, 5693, 5957, 5958, 6294, 6295, 6326, 6327, 6369, 6370, 6440, 6441, 6502, 6503, 7020, 7021, 7052, 7053, 7316, 7317, 7610, 7611, 7735, 7736, 7933, 7934, 8141, 8142, 8173, 8174, 8265, 8266, 9044, 9045, 9065, 9066, 9097, 9098, 9148, 9149, 9370, 9371, 9439, 9440 ], "line_end_idx": [ 167, 168, 176, 197, 229, 253, 308, 309, 402, 403, 408, 409, 625, 626, 887, 888, 942, 943, 976, 981, 1161, 1165, 1513, 1517, 1666, 1671, 1776, 1780, 1839, 1869, 1870, 2097, 2098, 2129, 2133, 2298, 2302, 2412, 2417, 2539, 2543, 2881, 2886, 3300, 3301, 3701, 3702, 3733, 3738, 3845, 3849, 4062, 4066, 4240, 4244, 4465, 4469, 4624, 4625, 4864, 4865, 5412, 5413, 5692, 5693, 5957, 5958, 6294, 6295, 6326, 6327, 6369, 6370, 6440, 6441, 6502, 6503, 7020, 7021, 7052, 7053, 7316, 7317, 7610, 7611, 7735, 7736, 7933, 7934, 8141, 8142, 8173, 8174, 8265, 8266, 9044, 9045, 9065, 9066, 9097, 9098, 9148, 9149, 9370, 9371, 9439, 9440, 9530 ] }
{ "red_pajama_v2": { "ccnet_original_length": 9530, "ccnet_original_nlines": 107, "rps_doc_curly_bracket": 0.033158451318740845, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.25878477096557617, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.005124450195580721, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.4633967876434326, "rps_doc_frac_unique_words": 0.3720930218696594, "rps_doc_mean_word_length": 4.696264743804932, "rps_doc_num_sentences": 75, "rps_doc_symbol_to_word_ratio": 0.0010980999795719981, "rps_doc_unigram_entropy": 5.533782958984375, "rps_doc_word_count": 1419, "rps_doc_frac_chars_dupe_10grams": 0.0405162088572979, "rps_doc_frac_chars_dupe_5grams": 0.09138654917478561, "rps_doc_frac_chars_dupe_6grams": 0.0676770731806755, "rps_doc_frac_chars_dupe_7grams": 0.050120048224925995, "rps_doc_frac_chars_dupe_8grams": 0.050120048224925995, "rps_doc_frac_chars_dupe_9grams": 0.0405162088572979, "rps_doc_frac_chars_top_2gram": 0.0072028799913823605, "rps_doc_frac_chars_top_3gram": 0.007352939806878567, "rps_doc_frac_chars_top_4gram": 0.009453780017793179, "rps_doc_books_importance": -1378.383056640625, "rps_doc_books_importance_length_correction": -1378.383056640625, "rps_doc_openwebtext_importance": -695.222900390625, "rps_doc_openwebtext_importance_length_correction": -695.222900390625, "rps_doc_wikipedia_importance": -385.0805358886719, "rps_doc_wikipedia_importance_length_correction": -385.0805358886719 }, "fasttext": { "dclm": 0.8416348099708557, "english": 0.8424472808837891, "fineweb_edu_approx": 1.8118042945861816, "eai_general_math": 0.9923235774040222, "eai_open_web_math": 0.984484076499939, "eai_web_code": 0.14740312099456787 } }
{ "free_decimal_correspondence": { "primary": { "code": "515.0", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Calculus and Mathematical analysis" } }, "secondary": { "code": "512.0", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Algebra" } } }, "bloom_cognitive_process": { "primary": { "code": "4", "label": "Analyze" }, "secondary": { "code": "5", "label": "Evaluate" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-227,507,425,965,112,580
LaVOZs The World’s Largest Online Community for Developers '; javascript - How to create GUID / UUID? - LavOzs.Com I'm trying to create globally-unique identifiers in JavaScript. I'm not sure what routines are available on all browsers, how "random" and seeded the built-in random number generator is, etc. The GUID / UUID should be at least 32 characters and should stay in the ASCII range to avoid trouble when passing them around. UUIDs (Universally Unique IDentifier), also known as GUIDs (Globally Unique IDentifier), according to RFC 4122, are identifiers designed to provide certain uniqueness guarantees. While it is possible to implement an RFC-compliant UUIDs in a few lines of JS (E.g. see @broofa's answer, below) there are several common pitfalls: • Invalid id format (UUIDs must be of the form "xxxxxxxx-xxxx-Mxxx-Nxxx-xxxxxxxxxxxx", where x is one of [0-9, a-f] M is one of [1-5], and N is [8, 9, a, or b] • Use of a low-quality source of randomness (such as Math.random) Thus, developers writing code for production environments are encouraged to use a rigorous, well-maintained implementation such as the uuid module. For an RFC4122 version 4 compliant solution, this one-liner(ish) solution is the most compact I could come up with: function uuidv4() { return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { var r = Math.random() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8); return v.toString(16); }); } console.log(uuidv4()); I really like how clean Broofa's answer is, but it's unfortunate that poor implementations of Math.random leave the chance for collision. Here's a similar RFC4122 version 4 compliant solution that solves that issue by offsetting the first 13 hex numbers by a hex portion of the timestamp, and once depleted offsets by a hex portion of the microseconds since pageload. That way, even if Math.random is on the same seed, both clients would have to generate the UUID the exact same number of microseconds since pageload (if high-perfomance time is supported) AND at the exact same millisecond (or 10,000+ years later) to get the same UUID: function generateUUID() { // Public Domain/MIT var d = new Date().getTime();//Timestamp var d2 = (performance && performance.now && (performance.now()*1000)) || 0;//Time in microseconds since page-load or 0 if unsupported return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { var r = Math.random() * 16;//random number between 0 and 16 if(d > 0){//Use timestamp until depleted r = (d + r)%16 | 0; d = Math.floor(d/16); } else {//Use microseconds since page-load if supported r = (d2 + r)%16 | 0; d2 = Math.floor(d2/16); } return (c === 'x' ? r : (r & 0x3 | 0x8)).toString(16); }); } console.log(generateUUID()) broofa's answer is pretty slick, indeed - impressively clever, really... rfc4122 compliant, somewhat readable, and compact. Awesome! But if you're looking at that regular expression, those many replace() callbacks, toString()'s and Math.random() function calls (where he's only using 4 bits of the result and wasting the rest), you may start to wonder about performance. Indeed, joelpt even decided to toss out RFC for generic GUID speed with generateQuickGUID. But, can we get speed and RFC compliance? I say, YES! Can we maintain readability? Well... Not really, but it's easy if you follow along. But first, my results, compared to broofa, guid (the accepted answer), and the non-rfc-compliant generateQuickGuid: Desktop Android broofa: 1617ms 12869ms e1: 636ms 5778ms e2: 606ms 4754ms e3: 364ms 3003ms e4: 329ms 2015ms e5: 147ms 1156ms e6: 146ms 1035ms e7: 105ms 726ms guid: 962ms 10762ms generateQuickGuid: 292ms 2961ms - Note: 500k iterations, results will vary by browser/cpu. So by my 6th iteration of optimizations, I beat the most popular answer by over 12X, the accepted answer by over 9X, and the fast-non-compliant answer by 2-3X. And I'm still rfc4122 compliant. Interested in how? I've put the full source on http://jsfiddle.net/jcward/7hyaC/3/ and on http://jsperf.com/uuid-generator-opt/4 For an explanation, let's start with broofa's code: function broofa() { return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8); return v.toString(16); }); } console.log(broofa()) Here's some code based on RFC 4122, section 4.4 (Algorithms for Creating a UUID from Truly Random or Pseudo-Random Number). function createUUID() { // http://www.ietf.org/rfc/rfc4122.txt var s = []; var hexDigits = "0123456789abcdef"; for (var i = 0; i < 36; i++) { s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1); } s[14] = "4"; // bits 12-15 of the time_hi_and_version field to 0010 s[19] = hexDigits.substr((s[19] & 0x3) | 0x8, 1); // bits 6-7 of the clock_seq_hi_and_reserved to 01 s[8] = s[13] = s[18] = s[23] = "-"; var uuid = s.join(""); return uuid; } let uniqueId = Math.random().toString(36).substring(2) + Date.now().toString(36); document.getElementById("unique").innerHTML = Math.random().toString(36).substring(2) + (new Date()).getTime().toString(36); <div id="unique"> </div> Fastest GUID like string generator method in the format XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX. This does not generate standard-compliant GUID. Ten million executions of this implementation take just 32.5 seconds, which is the fastest I've ever seen in a browser (the only solution without loops/iterations). The function is as simple as: /** * Generates a GUID string. * @returns {string} The generated GUID. * @example af8a8416-6e18-a307-bd9c-f2c947bbb3aa * @author Slavik Meltser. * @link http://slavik.meltser.info/?p=142 */ function guid() { function _p8(s) { var p = (Math.random().toString(16)+"000000000").substr(2,8); return s ? "-" + p.substr(0,4) + "-" + p.substr(4,4) : p ; } return _p8() + _p8(true) + _p8(true) + _p8(); } To test the performance, you can run this code: console.time('t'); for (var i = 0; i < 10000000; i++) { guid(); }; console.timeEnd('t'); I'm sure most of you will understand what I did there, but maybe there is at least one person that will need an explanation: The algorithm: • The Math.random() function returns a decimal number between 0 and 1 with 16 digits after the decimal fraction point (for example 0.4363923368509859). • Then we take this number and convert it to a string with base 16 (from the example above we'll get 0.6fb7687f). Math.random().toString(16). • Then we cut off the 0. prefix (0.6fb7687f => 6fb7687f) and get a string with eight hexadecimal characters long. (Math.random().toString(16).substr(2,8). • Sometimes the Math.random() function will return shorter number (for example 0.4363), due to zeros at the end (from the example above, actually the number is 0.4363000000000000). That's why I'm appending to this string "000000000" (a string with nine zeros) and then cutting it off with substr() function to make it nine characters exactly (filling zeros to the right). • The reason for adding exactly nine zeros is because of the worse case scenario, which is when the Math.random() function will return exactly 0 or 1 (probability of 1/10^16 for each one of them). That's why we needed to add nine zeros to it ("0"+"000000000" or "1"+"000000000"), and then cutting it off from the second index (3rd character) with a length of eight characters. For the rest of the cases, the addition of zeros will not harm the result because it is cutting it off anyway. Math.random().toString(16)+"000000000").substr(2,8). The assembly: • The GUID is in the following format XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX. • I divided the GUID into 4 pieces, each piece divided into 2 types (or formats): XXXXXXXX and -XXXX-XXXX. • Now I'm building the GUID using these 2 types to assemble the GUID with call 4 pieces, as follows: XXXXXXXX -XXXX-XXXX -XXXX-XXXX XXXXXXXX. • To differ between these two types, I added a flag parameter to a pair creator function _p8(s), the s parameter tells the function whether to add dashes or not. • Eventually we build the GUID with the following chaining: _p8() + _p8(true) + _p8(true) + _p8(), and return it. Link to this post on my blog Enjoy! :-) Here is a combination of the top voted answer, with a workaround for Chrome's collisions: generateGUID = (typeof(window.crypto) != 'undefined' && typeof(window.crypto.getRandomValues) != 'undefined') ? function() { // If we have a cryptographically secure PRNG, use that // https://stackoverflow.com/questions/6906916/collisions-when-generating-uuids-in-javascript var buf = new Uint16Array(8); window.crypto.getRandomValues(buf); var S4 = function(num) { var ret = num.toString(16); while(ret.length < 4){ ret = "0"+ret; } return ret; }; return (S4(buf[0])+S4(buf[1])+"-"+S4(buf[2])+"-"+S4(buf[3])+"-"+S4(buf[4])+"-"+S4(buf[5])+S4(buf[6])+S4(buf[7])); } : function() { // Otherwise, just use Math.random // https://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript/2117523#2117523 return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8); return v.toString(16); }); }; On jsbin if you want to test it. Here is a totally non-compliant but very performant implementation to generate an ASCII-safe GUID-like unique identifier. function generateQuickGuid() { return Math.random().toString(36).substring(2, 15) + Math.random().toString(36).substring(2, 15); } Generates 26 [a-z0-9] characters, yielding a UID that is both shorter and more unique than RFC compliant GUIDs. Dashes can be trivially added if human-readability matters. Here are usage examples and timings for this function and several of this question's other answers. The timing was performed under Chrome m25, 10 million iterations each. >>> generateQuickGuid() "nvcjf1hs7tf8yyk4lmlijqkuo9" "yq6gipxqta4kui8z05tgh9qeel" "36dh5sec7zdj90sk2rx7pjswi2" runtime: 32.5s >>> GUID() // John Millikin "7a342ca2-e79f-528e-6302-8f901b0b6888" runtime: 57.8s >>> regexGuid() // broofa "396e0c46-09e4-4b19-97db-bd423774a4b3" runtime: 91.2s >>> createUUID() // Kevin Hakanson "403aa1ab-9f70-44ec-bc08-5d5ac56bd8a5" runtime: 65.9s >>> UUIDv4() // Jed Schmidt "f4d7d31f-fa83-431a-b30c-3e6cc37cc6ee" runtime: 282.4s >>> Math.uuid() // broofa "5BD52F55-E68F-40FC-93C2-90EE069CE545" runtime: 225.8s >>> Math.uuidFast() // broofa "6CB97A68-23A2-473E-B75B-11263781BBE6" runtime: 92.0s >>> Math.uuidCompact() // broofa "3d7b7a06-0a67-4b67-825c-e5c43ff8c1e8" runtime: 229.0s >>> bitwiseGUID() // jablko "baeaa2f-7587-4ff1-af23-eeab3e92" runtime: 79.6s >>>> betterWayGUID() // Andrea Turri "383585b0-9753-498d-99c3-416582e9662c" runtime: 60.0s >>>> UUID() // John Fowler "855f997b-4369-4cdb-b7c9-7142ceaf39e8" runtime: 62.2s Here is the timing code. var r; console.time('t'); for (var i = 0; i < 10000000; i++) { r = FuncToTest(); }; console.timeEnd('t'); Here's a solution dated Oct. 9, 2011 from a comment by user jed at https://gist.github.com/982883: UUIDv4 = function b(a){return a?(a^Math.random()*16>>a/4).toString(16):([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,b)} This accomplishes the same goal as the current highest-rated answer, but in 50+ fewer bytes by exploiting coercion, recursion, and exponential notation. For those curious how it works, here's the annotated form of an older version of the function: UUIDv4 = function b( a // placeholder ){ return a // if the placeholder was passed, return ? ( // a random number from 0 to 15 a ^ // unless b is 8, Math.random() // in which case * 16 // a random number from >> a/4 // 8 to 11 ).toString(16) // in hexadecimal : ( // or otherwise a concatenated string: [1e7] + // 10000000 + -1e3 + // -1000 + -4e3 + // -4000 + -8e3 + // -80000000 + -1e11 // -100000000000, ).replace( // replacing /[018]/g, // zeroes, ones, and eights with b // random hex digits ) } From sagi shkedy's technical blog: function generateGuid() { var result, i, j; result = ''; for(j=0; j<32; j++) { if( j == 8 || j == 12 || j == 16 || j == 20) result = result + '-'; i = Math.floor(Math.random()*16).toString(16).toUpperCase(); result = result + i; } return result; } There are other methods that involve using an ActiveX control, but stay away from these! Edit : I thought it was worth pointing out that no GUID generator can guarantee unique keys (check the wikipedia article). There is always a chance of collisions. A GUID simply offers a large enough universe of keys to reduce the change of collisions to almost nil. You can use node-uuid (https://github.com/kelektiv/node-uuid) Simple, fast generation of RFC4122 UUIDS. Features: • Generate RFC4122 version 1 or version 4 UUIDs • Runs in node.js and browsers. • Cryptographically strong random # generation on supporting platforms. • Small footprint (Want something smaller? Check this out!) Install Using NPM: npm install uuid Or Using uuid via browser: Download Raw File (uuid v1): https://raw.githubusercontent.com/kelektiv/node-uuid/master/v1.js Download Raw File (uuid v4): https://raw.githubusercontent.com/kelektiv/node-uuid/master/v4.js Want even smaller? Check this out: https://gist.github.com/jed/982883 Usage: // Generate a v1 UUID (time-based) const uuidV1 = require('uuid/v1'); uuidV1(); // -> '6c84fb90-12c4-11e1-840d-7b25c5ee775a' // Generate a v4 UUID (random) const uuidV4 = require('uuid/v4'); uuidV4(); // -> '110ec58a-a0f2-4ac4-8393-c866d813b8d1' // Generate a v5 UUID (namespace) const uuidV5 = require('uuid/v5'); // ... using predefined DNS namespace (for domain names) uuidV5('hello.example.com', v5.DNS)); // -> 'fdda765f-fc57-5604-a269-52a7df8164ec' // ... using predefined URL namespace (for, well, URLs) uuidV5('http://example.com/hello', v5.URL); // -> '3bbcee75-cecc-5b56-8031-b6641c1ed1f1' // ... using a custom namespace const MY_NAMESPACE = '(previously generated unique uuid string)'; uuidV5('hello', MY_NAMESPACE); // -> '90123e1c-7512-523e-bb28-76fab9f2f73d' ES6: import uuid from 'uuid/v4'; const id = uuid(); var uuid = function() { var buf = new Uint32Array(4); window.crypto.getRandomValues(buf); var idx = -1; return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { idx++; var r = (buf[idx>>3] >> ((idx%8)*4))&15; var v = c == 'x' ? r : (r&0x3|0x8); return v.toString(16); }); }; EDIT: Revisited my project that was using this function and disliked the verbosity. - But needed proper randomness. A version based on Briguy37's answer and some bitwise operators to extract nibble sized windows from the buffer. Should adhere to the RFC Type 4 (random) schema, since I had Problems last time parsing non-compliant uuids with Java's UUID. Simple JavaScript module as a combination of best answers in this thread. var crypto = window.crypto || window.msCrypto || null; // IE11 fix var Guid = Guid || (function() { var EMPTY = '00000000-0000-0000-0000-000000000000'; var _padLeft = function(paddingString, width, replacementChar) { return paddingString.length >= width ? paddingString : _padLeft(replacementChar + paddingString, width, replacementChar || ' '); }; var _s4 = function(number) { var hexadecimalResult = number.toString(16); return _padLeft(hexadecimalResult, 4, '0'); }; var _cryptoGuid = function() { var buffer = new window.Uint16Array(8); window.crypto.getRandomValues(buffer); return [_s4(buffer[0]) + _s4(buffer[1]), _s4(buffer[2]), _s4(buffer[3]), _s4(buffer[4]), _s4(buffer[5]) + _s4(buffer[6]) + _s4(buffer[7])].join('-'); }; var _guid = function() { var currentDateMilliseconds = new Date().getTime(); return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(currentChar) { var randomChar = (currentDateMilliseconds + Math.random() * 16) % 16 | 0; currentDateMilliseconds = Math.floor(currentDateMilliseconds / 16); return (currentChar === 'x' ? randomChar : (randomChar & 0x7 | 0x8)).toString(16); }); }; var create = function() { var hasCrypto = crypto != 'undefined' && crypto !== null, hasRandomValues = typeof(window.crypto.getRandomValues) != 'undefined'; return (hasCrypto && hasRandomValues) ? _cryptoGuid() : _guid(); }; return { newGuid: create, empty: EMPTY }; })(); // DEMO: Create and show GUID console.log(Guid.newGuid()); This create version 4 UUID (created from pseudo random numbers) : function uuid() { var chars = '0123456789abcdef'.split(''); var uuid = [], rnd = Math.random, r; uuid[8] = uuid[13] = uuid[18] = uuid[23] = '-'; uuid[14] = '4'; // version 4 for (var i = 0; i < 36; i++) { if (!uuid[i]) { r = 0 | rnd()*16; uuid[i] = chars[(i == 19) ? (r & 0x3) | 0x8 : r & 0xf]; } } return uuid.join(''); } Here is a sample of the UUIDs generated : 682db637-0f31-4847-9cdf-25ba9613a75c 97d19478-3ab2-4aa1-b8cc-a1c3540f54aa 2eed04c9-2692-456d-a0fd-51012f947136 Well, this has a bunch of answers already, but unfortunately there's not a "true" random in the bunch. The version below is an adaptation of broofa's answer, but updated to include a "true" random function that uses crypto libraries where available, and the Alea() function as a fallback. Math.log2 = Math.log2 || function(n){ return Math.log(n) / Math.log(2); } Math.trueRandom = (function() { var crypt = window.crypto || window.msCrypto; if (crypt && crypt.getRandomValues) { // if we have a crypto library, use it var random = function(min, max) { var rval = 0; var range = max - min; if (range < 2) { return min; } var bits_needed = Math.ceil(Math.log2(range)); if (bits_needed > 53) { throw new Exception("We cannot generate numbers larger than 53 bits."); } var bytes_needed = Math.ceil(bits_needed / 8); var mask = Math.pow(2, bits_needed) - 1; // 7776 -> (2^13 = 8192) -1 == 8191 or 0x00001111 11111111 // Create byte array and fill with N random numbers var byteArray = new Uint8Array(bytes_needed); crypt.getRandomValues(byteArray); var p = (bytes_needed - 1) * 8; for(var i = 0; i < bytes_needed; i++ ) { rval += byteArray[i] * Math.pow(2, p); p -= 8; } // Use & to apply the mask and reduce the number of recursive lookups rval = rval & mask; if (rval >= range) { // Integer out of acceptable range return random(min, max); } // Return an integer that falls within the range return min + rval; } return function() { var r = random(0, 1000000000) / 1000000000; return r; }; } else { // From https://web.archive.org/web/20120502223108/http://baagoe.com/en/RandomMusings/javascript/ // Johannes Baagøe <baagoe@baagoe.com>, 2010 function Mash() { var n = 0xefc8249d; var mash = function(data) { data = data.toString(); for (var i = 0; i < data.length; i++) { n += data.charCodeAt(i); var h = 0.02519603282416938 * n; n = h >>> 0; h -= n; h *= n; n = h >>> 0; h -= n; n += h * 0x100000000; // 2^32 } return (n >>> 0) * 2.3283064365386963e-10; // 2^-32 }; mash.version = 'Mash 0.9'; return mash; } // From http://baagoe.com/en/RandomMusings/javascript/ function Alea() { return (function(args) { // Johannes Baagøe <baagoe@baagoe.com>, 2010 var s0 = 0; var s1 = 0; var s2 = 0; var c = 1; if (args.length == 0) { args = [+new Date()]; } var mash = Mash(); s0 = mash(' '); s1 = mash(' '); s2 = mash(' '); for (var i = 0; i < args.length; i++) { s0 -= mash(args[i]); if (s0 < 0) { s0 += 1; } s1 -= mash(args[i]); if (s1 < 0) { s1 += 1; } s2 -= mash(args[i]); if (s2 < 0) { s2 += 1; } } mash = null; var random = function() { var t = 2091639 * s0 + c * 2.3283064365386963e-10; // 2^-32 s0 = s1; s1 = s2; return s2 = t - (c = t | 0); }; random.uint32 = function() { return random() * 0x100000000; // 2^32 }; random.fract53 = function() { return random() + (random() * 0x200000 | 0) * 1.1102230246251565e-16; // 2^-53 }; random.version = 'Alea 0.9'; random.args = args; return random; }(Array.prototype.slice.call(arguments))); }; return Alea(); } }()); Math.guid = function() { return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) { var r = Math.trueRandom() * 16 | 0, v = c == 'x' ? r : (r & 0x3 | 0x8); return v.toString(16); }); }; JavaScript project on GitHub - https://github.com/LiosK/UUID.js UUID.js The RFC-compliant UUID generator for JavaScript. See RFC 4122 http://www.ietf.org/rfc/rfc4122.txt. Features Generates RFC 4122 compliant UUIDs. Version 4 UUIDs (UUIDs from random numbers) and version 1 UUIDs (time-based UUIDs) are available. UUID object allows a variety of access to the UUID including access to the UUID fields. Low timestamp resolution of JavaScript is compensated by random numbers. // RFC 4122 // // A UUID is 128 bits long // // String representation is five fields of 4, 2, 2, 2, and 6 bytes. // Fields represented as lowercase, zero-filled, hexadecimal strings, and // are separated by dash characters // // A version 4 UUID is generated by setting all but six bits to randomly // chosen values var uuid = [ Math.random().toString(16).slice(2, 10), Math.random().toString(16).slice(2, 6), // Set the four most significant bits (bits 12 through 15) of the // time_hi_and_version field to the 4-bit version number from Section // 4.1.3 (Math.random() * .0625 /* 0x.1 */ + .25 /* 0x.4 */).toString(16).slice(2, 6), // Set the two most significant bits (bits 6 and 7) of the // clock_seq_hi_and_reserved to zero and one, respectively (Math.random() * .25 /* 0x.4 */ + .5 /* 0x.8 */).toString(16).slice(2, 6), Math.random().toString(16).slice(2, 14)].join('-'); I wanted to understand broofa's answer, so I expanded it and added comments: var uuid = function () { return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace( /[xy]/g, function (match) { /* * Create a random nibble. The two clever bits of this code: * * - Bitwise operations will truncate floating point numbers * - For a bitwise OR of any x, x | 0 = x * * So: * * Math.random * 16 * * creates a random floating point number * between 0 (inclusive) and 16 (exclusive) and * * | 0 * * truncates the floating point number into an integer. */ var randomNibble = Math.random() * 16 | 0; /* * Resolves the variant field. If the variant field (delineated * as y in the initial string) is matched, the nibble must * match the mask (where x is a do-not-care bit): * * 10xx * * This is achieved by performing the following operations in * sequence (where x is an intermediate result): * * - x & 0x3, which is equivalent to x % 3 * - x | 0x8, which is equivalent to x + 8 * * This results in a nibble between 8 inclusive and 11 exclusive, * (or 1000 and 1011 in binary), all of which satisfy the variant * field mask above. */ var nibble = (match == 'y') ? (randomNibble & 0x3 | 0x8) : randomNibble; /* * Ensure the nibble integer is encoded as base 16 (hexadecimal). */ return nibble.toString(16); } ); }; Adjusted my own UUID/GUID generator with some extras here. I'm using the following Kybos random number generator to be a bit more cryptographically sound. Below is my script with the Mash and Kybos methods from baagoe.com excluded. //UUID/Guid Generator // use: UUID.create() or UUID.createSequential() // convenience: UUID.empty, UUID.tryParse(string) (function(w){ // From http://baagoe.com/en/RandomMusings/javascript/ // Johannes Baagøe <baagoe@baagoe.com>, 2010 //function Mash() {...}; // From http://baagoe.com/en/RandomMusings/javascript/ //function Kybos() {...}; var rnd = Kybos(); //UUID/GUID Implementation from http://frugalcoder.us/post/2012/01/13/javascript-guid-uuid-generator.aspx var UUID = { "empty": "00000000-0000-0000-0000-000000000000" ,"parse": function(input) { var ret = input.toString().trim().toLowerCase().replace(/^[\s\r\n]+|[\{\}]|[\s\r\n]+$/g, ""); if ((/[a-f0-9]{8}\-[a-f0-9]{4}\-[a-f0-9]{4}\-[a-f0-9]{4}\-[a-f0-9]{12}/).test(ret)) return ret; else throw new Error("Unable to parse UUID"); } ,"createSequential": function() { var ret = new Date().valueOf().toString(16).replace("-","") for (;ret.length < 12; ret = "0" + ret); ret = ret.substr(ret.length-12,12); //only least significant part for (;ret.length < 32;ret += Math.floor(rnd() * 0xffffffff).toString(16)); return [ret.substr(0,8), ret.substr(8,4), "4" + ret.substr(12,3), "89AB"[Math.floor(Math.random()*4)] + ret.substr(16,3), ret.substr(20,12)].join("-"); } ,"create": function() { var ret = ""; for (;ret.length < 32;ret += Math.floor(rnd() * 0xffffffff).toString(16)); return [ret.substr(0,8), ret.substr(8,4), "4" + ret.substr(12,3), "89AB"[Math.floor(Math.random()*4)] + ret.substr(16,3), ret.substr(20,12)].join("-"); } ,"random": function() { return rnd(); } ,"tryParse": function(input) { try { return UUID.parse(input); } catch(ex) { return UUID.empty; } } }; UUID["new"] = UUID.create; w.UUID = w.Guid = UUID; }(window || this)); For those wanting an rfc4122 version 4 compliant solution with speed considerations (few calls to Math.random()): var rand = Math.random; function UUID() { var nbr, randStr = ""; do { randStr += (nbr = rand()).toString(16).substr(3, 6); } while (randStr.length < 30); return ( randStr.substr(0, 8) + "-" + randStr.substr(8, 4) + "-4" + randStr.substr(12, 3) + "-" + ((nbr*4|0)+8).toString(16) + // [89ab] randStr.substr(15, 3) + "-" + randStr.substr(18, 12) ); } console.log( UUID() ); ES6 sample const guid=()=> { const s4=()=> Math.floor((1 + Math.random()) * 0x10000).toString(16).substring(1); return `${s4() + s4()}-${s4()}-${s4()}-${s4()}-${s4() + s4() + s4()}`; } The better way: function( a,b // placeholders ){ for( // loop :) b=a=''; // b - result , a - numeric variable a++<36; // b+=a*51&52 // if "a" is not 9 or 14 or 19 or 24 ? // return a random number or 4 ( a^15 // if "a" is not 15 ? // genetate a random number from 0 to 15 8^Math.random()* (a^20?16:4) // unless "a" is 20, in which case a random number from 8 to 11 : 4 // otherwise 4 ).toString(16) : '-' // in other cases (if "a" is 9,14,19,24) insert "-" ); return b } Minimized: function(a,b){for(b=a='';a++<36;b+=a*51&52?(a^15?8^Math.random()*(a^20?16:4):4).toString(16):'-');return b} I know, it is an old question. Just for completeness, if your environment is SharePoint, there is a utility function called SP.Guid.newGuid (msdn link) which creates a new guid. This function is inside the sp.init.js file. If you rewrite this function (to remove some other dependencies from other private functions), it looks like this: var newGuid = function () { var result = ''; var hexcodes = "0123456789abcdef".split(""); for (var index = 0; index < 32; index++) { var value = Math.floor(Math.random() * 16); switch (index) { case 8: result += '-'; break; case 12: value = 4; result += '-'; break; case 16: value = value & 3 | 8; result += '-'; break; case 20: result += '-'; break; } result += hexcodes[value]; } return result; }; This one is based on date, and add a random suffix to "ensure" uniqueness. Works well for css identifiers. It always returns something like and is easy to hack: uid-139410573297741 var getUniqueId = function (prefix) { var d = new Date().getTime(); d += (parseInt(Math.random() * 100)).toString(); if (undefined === prefix) { prefix = 'uid-'; } d = prefix + d; return d; }; Simple code that uses crypto.getRandomValues(a) on supported browsers (IE11+, iOS7+, FF21+, Chrome, Android Chrome). Avoids using Math.random() because that can cause collisions (for example 20 collisions for 4000 generated uuids in a real situation by Muxa). function uuid() { function randomDigit() { if (crypto && crypto.getRandomValues) { var rands = new Uint8Array(1); crypto.getRandomValues(rands); return (rands[0] % 16).toString(16); } else { return ((Math.random() * 16) | 0).toString(16); } } var crypto = window.crypto || window.msCrypto; return 'xxxxxxxx-xxxx-4xxx-8xxx-xxxxxxxxxxxx'.replace(/x/g, randomDigit); } Notes: • Optimised for code readability not speed, so suitable for say a few hundred uuid's per second. Generates about 10000 uuid() per second in Chromium on my laptop using http://jsbin.com/fuwigo/1 to measure performance. • Only uses 8 for "y" because that simplifies code readability (y is allowed to be 8, 9, A or B). If you just need a random 128 bit string in no particular format you can use: function uuid() { return crypto.getRandomValues(new Uint32Array(4)).join('-'); } Which will return something like 2350143528-4164020887-938913176-2513998651. Just another more readable variant with just two mutations. function uuid4() { function hex (s, b) { return s + (b >>> 4 ).toString (16) + // high nibble (b & 0b1111).toString (16); // low nibble } let r = crypto.getRandomValues (new Uint8Array (16)); r[6] = r[6] >>> 4 | 0b01000000; // Set type 4: 0100 r[8] = r[8] >>> 3 | 0b10000000; // Set variant: 100 return r.slice ( 0, 4).reduce (hex, '' ) + r.slice ( 4, 6).reduce (hex, '-') + r.slice ( 6, 8).reduce (hex, '-') + r.slice ( 8, 10).reduce (hex, '-') + r.slice (10, 16).reduce (hex, '-'); } OK, using uuid package, it support for version 1, 3, 4 and 5 UUIDs do: yarn add uuid and then: const uuidv1 = require('uuid/v1'); uuidv1(); // ⇨ '45745c60-7b1a-11e8-9c9c-2d42b21b1a3e' You can also do it with fully-specified options: const v1options = { node: [0x01, 0x23, 0x45, 0x67, 0x89, 0xab], clockseq: 0x1234, msecs: new Date('2011-11-01').getTime(), nsecs: 5678 }; uuidv1(v1options); // ⇨ '710b962e-041c-11e1-9234-0123456789ab' For more info, visit the npm page here It is important that to use well tested code that is maintained by more than 1 contributors instead of whipping your own stuff for this. This is one of the places where you probably want to prefer most stable code than shortest possible clever version that works in X browser but doesn't take in to account idiosyncrasies of Y which would often lead to very hard to investigate bugs than manifests only randomly for some users. Personally I use uuid-js at https://github.com/aurigadl/uuid-js which bower enabled so I can take updates easily.
{ "url": "https://lavozs.com/questions/105034/create-guid-uuid-in-javascript", "source_domain": "lavozs.com", "snapshot_id": "crawl=CC-MAIN-2020-24", "warc_metadata": { "Content-Length": "52005", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:TY3OZ6BF5AQAPLUWOIAVQWA24DGYMVWL", "WARC-Concurrent-To": "<urn:uuid:14e67fdf-f7cf-4b7d-b729-234ffc10e89f>", "WARC-Date": "2020-05-31T12:06:08Z", "WARC-IP-Address": "45.252.251.31", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:HCWQYNUTFRO2WBTC7L7AQTKEGNBOY5LX", "WARC-Record-ID": "<urn:uuid:bb842689-4530-46b5-b64f-867c04880c5a>", "WARC-Target-URI": "https://lavozs.com/questions/105034/create-guid-uuid-in-javascript", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:21bde8d5-1444-4656-b25c-5d9c72cf61b2>" }, "warc_info": "isPartOf: CC-MAIN-2020-24\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May/June 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-45.ec2.internal\r\nsoftware: Apache Nutch 1.16 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 7, 8, 60, 61, 117, 118, 310, 311, 438, 439, 618, 619, 767, 768, 930, 998, 999, 1147, 1148, 1264, 1265, 1285, 1364, 1436, 1463, 1469, 1471, 1472, 1495, 1496, 1634, 1635, 2134, 2135, 2182, 2227, 2365, 2446, 2514, 2563, 2595, 2629, 2693, 2726, 2762, 2772, 2835, 2843, 2845, 2846, 2874, 2875, 3008, 3009, 3338, 3339, 3477, 3478, 3594, 3595, 3631, 3667, 3703, 3739, 3775, 3811, 3847, 3883, 3919, 3955, 3991, 4052, 4053, 4246, 4247, 4376, 4377, 4429, 4430, 4450, 4531, 4599, 4630, 4638, 4640, 4641, 4663, 4664, 4788, 4789, 4813, 4856, 4872, 4912, 4947, 5017, 5023, 5096, 5202, 5242, 5243, 5270, 5287, 5289, 5371, 5372, 5418, 5499, 5517, 5524, 5525, 5667, 5668, 5833, 5834, 5864, 5865, 5869, 5897, 5938, 5987, 6014, 6057, 6061, 6079, 6101, 6171, 6238, 6244, 6294, 6296, 6297, 6345, 6346, 6366, 6404, 6417, 6420, 6442, 6443, 6568, 6569, 6584, 6585, 6739, 6855, 6887, 7003, 7048, 7422, 7912, 7969, 7970, 7984, 7985, 8063, 8172, 8316, 8480, 8596, 8597, 8626, 8627, 8638, 8639, 8729, 8730, 8787, 8859, 8876, 8940, 9042, 9080, 9124, 9157, 9197, 9232, 9263, 9277, 9301, 9312, 9434, 9440, 9441, 9447, 9448, 9465, 9508, 9618, 9703, 9775, 9810, 9822, 9829, 9830, 9863, 9864, 9986, 9987, 10018, 10075, 10128, 10130, 10131, 10303, 10304, 10475, 10476, 10500, 10529, 10558, 10587, 10602, 10603, 10631, 10670, 10685, 10686, 10712, 10751, 10766, 10767, 10802, 10841, 10856, 10857, 10885, 10924, 10940, 10941, 10967, 11006, 11022, 11023, 11053, 11092, 11107, 11108, 11141, 11180, 11196, 11197, 11225, 11259, 11274, 11275, 11312, 11351, 11366, 11367, 11394, 11433, 11448, 11449, 11474, 11475, 11482, 11502, 11540, 11563, 11566, 11588, 11589, 11688, 11689, 11810, 11811, 12059, 12060, 12069, 12070, 12082, 12101, 12104, 12156, 12196, 12224, 12261, 12296, 12320, 12359, 12406, 12434, 12458, 12482, 12510, 12540, 12570, 12621, 12652, 12660, 12662, 12663, 12698, 12699, 12725, 12745, 12760, 12784, 12834, 12863, 12928, 12953, 12957, 12974, 12976, 12977, 13066, 13067, 13333, 13334, 13396, 13397, 13439, 13440, 13450, 13451, 13501, 13535, 13609, 13671, 13672, 13691, 13692, 13709, 13710, 13737, 13738, 13928, 13929, 13930, 14000, 14001, 14002, 14009, 14010, 14045, 14080, 14135, 14136, 14167, 14202, 14257, 14258, 14292, 14327, 14328, 14385, 14468, 14469, 14525, 14614, 14615, 14647, 14713, 14789, 14790, 14795, 14796, 14824, 14843, 14867, 14901, 14941, 14959, 15040, 15055, 15104, 15148, 15179, 15187, 15190, 15191, 15197, 15198, 15308, 15309, 15422, 15423, 15549, 15550, 15624, 15625, 15692, 15693, 15726, 15727, 15781, 15782, 15849, 15982, 15987, 15988, 16019, 16068, 16116, 16121, 16122, 16155, 16199, 16242, 16396, 16401, 16402, 16429, 16485, 16576, 16656, 16730, 16819, 16827, 16832, 16833, 16861, 16923, 17001, 17070, 17075, 17076, 17087, 17108, 17125, 17130, 17136, 17137, 17167, 17196, 17197, 17263, 17264, 17280, 17282, 17327, 17328, 17368, 17419, 17451, 17452, 17484, 17489, 17509, 17517, 17544, 17545, 17610, 17618, 17623, 17624, 17649, 17651, 17652, 17694, 17695, 17732, 17769, 17806, 17807, 18096, 18097, 18173, 18207, 18255, 18256, 18296, 18341, 18381, 18405, 18438, 18465, 18491, 18503, 18504, 18561, 18595, 18679, 18691, 18748, 18799, 18868, 18869, 18931, 18987, 19031, 19032, 19074, 19125, 19178, 19200, 19212, 19213, 19293, 19323, 19324, 19355, 19404, 19443, 19455, 19514, 19543, 19551, 19577, 19631, 19651, 19660, 19671, 19775, 19827, 19851, 19881, 19882, 19920, 19958, 20012, 20055, 20106, 20137, 20163, 20189, 20220, 20246, 20294, 20310, 20376, 20389, 20390, 20427, 20450, 20458, 20459, 20520, 20544, 20579, 20639, 20665, 20691, 20717, 20742, 20743, 20781, 20821, 20837, 20870, 20900, 20930, 20960, 20961, 21015, 21054, 21086, 21117, 21137, 21176, 21208, 21239, 21259, 21298, 21330, 21361, 21381, 21397, 21424, 21425, 21465, 21543, 21570, 21597, 21644, 21661, 21704, 21761, 21778, 21822, 21858, 21941, 21958, 22001, 22035, 22064, 22065, 22118, 22127, 22148, 22152, 22158, 22159, 22184, 22268, 22310, 22356, 22385, 22391, 22394, 22395, 22459, 22460, 22517, 22518, 22568, 22569, 22614, 22615, 22713, 22714, 22802, 22803, 22876, 22877, 22891, 22896, 22925, 22930, 23000, 23076, 23114, 23119, 23194, 23213, 23228, 23273, 23317, 23318, 23388, 23462, 23475, 23557, 23558, 23621, 23684, 23763, 23764, 23820, 23821, 23898, 23899, 23924, 23983, 24000, 24027, 24042, 24114, 24128, 24200, 24253, 24267, 24285, 24299, 24330, 24344, 24397, 24456, 24470, 24488, 24502, 24569, 24584, 24639, 24640, 24655, 24730, 24800, 24861, 24875, 24894, 24908, 24981, 25041, 25055, 25109, 25163, 25177, 25254, 25331, 25363, 25378, 25420, 25465, 25495, 25496, 25511, 25588, 25603, 25643, 25653, 25660, 25663, 25664, 25723, 25724, 25820, 25821, 25898, 25899, 25921, 25970, 26021, 26035, 26092, 26140, 26167, 26168, 26225, 26253, 26254, 26275, 26276, 26384, 26399, 26451, 26483, 26583, 26673, 26693, 26704, 26753, 26759, 26797, 26863, 26910, 26982, 27063, 27222, 27228, 27256, 27276, 27357, 27516, 27522, 27550, 27570, 27576, 27611, 27623, 27657, 27677, 27704, 27712, 27718, 27723, 27752, 27753, 27779, 27799, 27800, 27914, 27915, 27939, 27940, 27958, 27985, 27994, 28055, 28090, 28103, 28140, 28178, 28216, 28263, 28301, 28332, 28339, 28341, 28342, 28365, 28366, 28377, 28378, 28396, 28486, 28559, 28561, 28562, 28578, 28579, 28589, 28626, 28629, 28661, 28719, 28744, 28799, 28852, 28863, 28904, 28966, 28994, 29082, 29098, 29138, 29164, 29184, 29261, 29270, 29281, 29284, 29285, 29296, 29297, 29405, 29406, 29744, 29745, 29773, 29794, 29843, 29844, 29891, 29943, 29944, 29969, 29985, 30012, 30031, 30048, 30071, 30098, 30117, 30134, 30169, 30196, 30215, 30232, 30259, 30278, 30288, 30323, 30329, 30348, 30351, 30352, 30513, 30514, 30534, 30535, 30573, 30615, 30676, 30716, 30749, 30763, 30791, 30813, 30824, 30825, 31085, 31086, 31104, 31133, 31181, 31224, 31267, 31316, 31333, 31393, 31403, 31409, 31460, 31538, 31540, 31541, 31548, 31549, 31769, 31869, 31870, 31948, 31949, 31967, 32032, 32034, 32035, 32112, 32113, 32173, 32174, 32191, 32193, 32215, 32219, 32234, 32285, 32335, 32339, 32340, 32396, 32397, 32451, 32505, 32506, 32552, 32598, 32644, 32690, 32735, 32737, 32738, 32809, 32810, 32824, 32825, 32835, 32836, 32871, 32925, 32926, 32975, 32976, 32996, 33042, 33062, 33105, 33119, 33122, 33185, 33186, 33225, 33226 ], "line_end_idx": [ 7, 8, 60, 61, 117, 118, 310, 311, 438, 439, 618, 619, 767, 768, 930, 998, 999, 1147, 1148, 1264, 1265, 1285, 1364, 1436, 1463, 1469, 1471, 1472, 1495, 1496, 1634, 1635, 2134, 2135, 2182, 2227, 2365, 2446, 2514, 2563, 2595, 2629, 2693, 2726, 2762, 2772, 2835, 2843, 2845, 2846, 2874, 2875, 3008, 3009, 3338, 3339, 3477, 3478, 3594, 3595, 3631, 3667, 3703, 3739, 3775, 3811, 3847, 3883, 3919, 3955, 3991, 4052, 4053, 4246, 4247, 4376, 4377, 4429, 4430, 4450, 4531, 4599, 4630, 4638, 4640, 4641, 4663, 4664, 4788, 4789, 4813, 4856, 4872, 4912, 4947, 5017, 5023, 5096, 5202, 5242, 5243, 5270, 5287, 5289, 5371, 5372, 5418, 5499, 5517, 5524, 5525, 5667, 5668, 5833, 5834, 5864, 5865, 5869, 5897, 5938, 5987, 6014, 6057, 6061, 6079, 6101, 6171, 6238, 6244, 6294, 6296, 6297, 6345, 6346, 6366, 6404, 6417, 6420, 6442, 6443, 6568, 6569, 6584, 6585, 6739, 6855, 6887, 7003, 7048, 7422, 7912, 7969, 7970, 7984, 7985, 8063, 8172, 8316, 8480, 8596, 8597, 8626, 8627, 8638, 8639, 8729, 8730, 8787, 8859, 8876, 8940, 9042, 9080, 9124, 9157, 9197, 9232, 9263, 9277, 9301, 9312, 9434, 9440, 9441, 9447, 9448, 9465, 9508, 9618, 9703, 9775, 9810, 9822, 9829, 9830, 9863, 9864, 9986, 9987, 10018, 10075, 10128, 10130, 10131, 10303, 10304, 10475, 10476, 10500, 10529, 10558, 10587, 10602, 10603, 10631, 10670, 10685, 10686, 10712, 10751, 10766, 10767, 10802, 10841, 10856, 10857, 10885, 10924, 10940, 10941, 10967, 11006, 11022, 11023, 11053, 11092, 11107, 11108, 11141, 11180, 11196, 11197, 11225, 11259, 11274, 11275, 11312, 11351, 11366, 11367, 11394, 11433, 11448, 11449, 11474, 11475, 11482, 11502, 11540, 11563, 11566, 11588, 11589, 11688, 11689, 11810, 11811, 12059, 12060, 12069, 12070, 12082, 12101, 12104, 12156, 12196, 12224, 12261, 12296, 12320, 12359, 12406, 12434, 12458, 12482, 12510, 12540, 12570, 12621, 12652, 12660, 12662, 12663, 12698, 12699, 12725, 12745, 12760, 12784, 12834, 12863, 12928, 12953, 12957, 12974, 12976, 12977, 13066, 13067, 13333, 13334, 13396, 13397, 13439, 13440, 13450, 13451, 13501, 13535, 13609, 13671, 13672, 13691, 13692, 13709, 13710, 13737, 13738, 13928, 13929, 13930, 14000, 14001, 14002, 14009, 14010, 14045, 14080, 14135, 14136, 14167, 14202, 14257, 14258, 14292, 14327, 14328, 14385, 14468, 14469, 14525, 14614, 14615, 14647, 14713, 14789, 14790, 14795, 14796, 14824, 14843, 14867, 14901, 14941, 14959, 15040, 15055, 15104, 15148, 15179, 15187, 15190, 15191, 15197, 15198, 15308, 15309, 15422, 15423, 15549, 15550, 15624, 15625, 15692, 15693, 15726, 15727, 15781, 15782, 15849, 15982, 15987, 15988, 16019, 16068, 16116, 16121, 16122, 16155, 16199, 16242, 16396, 16401, 16402, 16429, 16485, 16576, 16656, 16730, 16819, 16827, 16832, 16833, 16861, 16923, 17001, 17070, 17075, 17076, 17087, 17108, 17125, 17130, 17136, 17137, 17167, 17196, 17197, 17263, 17264, 17280, 17282, 17327, 17328, 17368, 17419, 17451, 17452, 17484, 17489, 17509, 17517, 17544, 17545, 17610, 17618, 17623, 17624, 17649, 17651, 17652, 17694, 17695, 17732, 17769, 17806, 17807, 18096, 18097, 18173, 18207, 18255, 18256, 18296, 18341, 18381, 18405, 18438, 18465, 18491, 18503, 18504, 18561, 18595, 18679, 18691, 18748, 18799, 18868, 18869, 18931, 18987, 19031, 19032, 19074, 19125, 19178, 19200, 19212, 19213, 19293, 19323, 19324, 19355, 19404, 19443, 19455, 19514, 19543, 19551, 19577, 19631, 19651, 19660, 19671, 19775, 19827, 19851, 19881, 19882, 19920, 19958, 20012, 20055, 20106, 20137, 20163, 20189, 20220, 20246, 20294, 20310, 20376, 20389, 20390, 20427, 20450, 20458, 20459, 20520, 20544, 20579, 20639, 20665, 20691, 20717, 20742, 20743, 20781, 20821, 20837, 20870, 20900, 20930, 20960, 20961, 21015, 21054, 21086, 21117, 21137, 21176, 21208, 21239, 21259, 21298, 21330, 21361, 21381, 21397, 21424, 21425, 21465, 21543, 21570, 21597, 21644, 21661, 21704, 21761, 21778, 21822, 21858, 21941, 21958, 22001, 22035, 22064, 22065, 22118, 22127, 22148, 22152, 22158, 22159, 22184, 22268, 22310, 22356, 22385, 22391, 22394, 22395, 22459, 22460, 22517, 22518, 22568, 22569, 22614, 22615, 22713, 22714, 22802, 22803, 22876, 22877, 22891, 22896, 22925, 22930, 23000, 23076, 23114, 23119, 23194, 23213, 23228, 23273, 23317, 23318, 23388, 23462, 23475, 23557, 23558, 23621, 23684, 23763, 23764, 23820, 23821, 23898, 23899, 23924, 23983, 24000, 24027, 24042, 24114, 24128, 24200, 24253, 24267, 24285, 24299, 24330, 24344, 24397, 24456, 24470, 24488, 24502, 24569, 24584, 24639, 24640, 24655, 24730, 24800, 24861, 24875, 24894, 24908, 24981, 25041, 25055, 25109, 25163, 25177, 25254, 25331, 25363, 25378, 25420, 25465, 25495, 25496, 25511, 25588, 25603, 25643, 25653, 25660, 25663, 25664, 25723, 25724, 25820, 25821, 25898, 25899, 25921, 25970, 26021, 26035, 26092, 26140, 26167, 26168, 26225, 26253, 26254, 26275, 26276, 26384, 26399, 26451, 26483, 26583, 26673, 26693, 26704, 26753, 26759, 26797, 26863, 26910, 26982, 27063, 27222, 27228, 27256, 27276, 27357, 27516, 27522, 27550, 27570, 27576, 27611, 27623, 27657, 27677, 27704, 27712, 27718, 27723, 27752, 27753, 27779, 27799, 27800, 27914, 27915, 27939, 27940, 27958, 27985, 27994, 28055, 28090, 28103, 28140, 28178, 28216, 28263, 28301, 28332, 28339, 28341, 28342, 28365, 28366, 28377, 28378, 28396, 28486, 28559, 28561, 28562, 28578, 28579, 28589, 28626, 28629, 28661, 28719, 28744, 28799, 28852, 28863, 28904, 28966, 28994, 29082, 29098, 29138, 29164, 29184, 29261, 29270, 29281, 29284, 29285, 29296, 29297, 29405, 29406, 29744, 29745, 29773, 29794, 29843, 29844, 29891, 29943, 29944, 29969, 29985, 30012, 30031, 30048, 30071, 30098, 30117, 30134, 30169, 30196, 30215, 30232, 30259, 30278, 30288, 30323, 30329, 30348, 30351, 30352, 30513, 30514, 30534, 30535, 30573, 30615, 30676, 30716, 30749, 30763, 30791, 30813, 30824, 30825, 31085, 31086, 31104, 31133, 31181, 31224, 31267, 31316, 31333, 31393, 31403, 31409, 31460, 31538, 31540, 31541, 31548, 31549, 31769, 31869, 31870, 31948, 31949, 31967, 32032, 32034, 32035, 32112, 32113, 32173, 32174, 32191, 32193, 32215, 32219, 32234, 32285, 32335, 32339, 32340, 32396, 32397, 32451, 32505, 32506, 32552, 32598, 32644, 32690, 32735, 32737, 32738, 32809, 32810, 32824, 32825, 32835, 32836, 32871, 32925, 32926, 32975, 32976, 32996, 33042, 33062, 33105, 33119, 33122, 33185, 33186, 33225, 33226, 33767 ] }
{ "red_pajama_v2": { "ccnet_original_length": 33767, "ccnet_original_nlines": 916, "rps_doc_curly_bracket": 0.006219089962542057, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.1820419728755951, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.022803839296102524, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.4721430540084839, "rps_doc_frac_unique_words": 0.34852319955825806, "rps_doc_mean_word_length": 5.845006942749023, "rps_doc_num_sentences": 481, "rps_doc_symbol_to_word_ratio": 0.001166110043413937, "rps_doc_unigram_entropy": 6.245197772979736, "rps_doc_word_count": 3555, "rps_doc_frac_chars_dupe_10grams": 0.026565279811620712, "rps_doc_frac_chars_dupe_5grams": 0.0667019635438919, "rps_doc_frac_chars_dupe_6grams": 0.0510130412876606, "rps_doc_frac_chars_dupe_7grams": 0.034072861075401306, "rps_doc_frac_chars_dupe_8grams": 0.029452810063958168, "rps_doc_frac_chars_dupe_9grams": 0.026565279811620712, "rps_doc_frac_chars_top_2gram": 0.003368790028616786, "rps_doc_frac_chars_top_3gram": 0.0010106399422511458, "rps_doc_frac_chars_top_4gram": 0.0023100199177861214, "rps_doc_books_importance": -4139.78369140625, "rps_doc_books_importance_length_correction": -4139.78369140625, "rps_doc_openwebtext_importance": -2019.7633056640625, "rps_doc_openwebtext_importance_length_correction": -2019.7633056640625, "rps_doc_wikipedia_importance": -1494.7652587890625, "rps_doc_wikipedia_importance_length_correction": -1494.7652587890625 }, "fasttext": { "dclm": 0.8670465350151062, "english": 0.5649499297142029, "fineweb_edu_approx": 2.1947693824768066, "eai_general_math": 0.8965408802032471, "eai_open_web_math": 0.17557072639465332, "eai_web_code": 0.9367847442626953 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.678", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "4", "label": "Advanced Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
1,748,424,221,402,694,000
Take the 2-minute tour × Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required. These are my two functions for searching my table and making overlays. (the map is created in a different function). For some reason, the dotmap one works fine, but the heatmap one doesn't work with the where clause. Any insight? function heatmap() { var layer = new google.maps.FusionTablesLayer({ query: { select: 'LOCATION', from: '1614684', where: "CRIME = 'HOMICIDE'" }, heatmap: { enabled: true } }); layer.setMap(map); } function dotmap() { var layer = new google.maps.FusionTablesLayer({ query: { select: 'LOCATION', from: '1614684', where: "CRIME = 'HOMICIDE'" } }); layer.setMap(map); } share|improve this question add comment 1 Answer I think the problem is the same as mentioned here: https://groups.google.com/forum/#!topic/fusion-tables-users-group/MkZ8KJT6oic In short, Heatmaps in Google Fusion Tables is a little flaky. You might want to use something like gheat which somehow worked, but not as nice and simple as I wanted. share|improve this answer add comment Your Answer   discard By posting your answer, you agree to the privacy policy and terms of service. Not the answer you're looking for? Browse other questions tagged or ask your own question.
{ "url": "http://stackoverflow.com/questions/7543796/problem-with-heatmaps-in-google-fusion-tables/8768163", "source_domain": "stackoverflow.com", "snapshot_id": "crawl=CC-MAIN-2014-23", "warc_metadata": { "Content-Length": "61098", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:CO67UK4AKLGG7MR4KOBVM4G7UAJ3LK5K", "WARC-Concurrent-To": "<urn:uuid:a7100a23-3b08-4cd8-9195-8a15cd3846e9>", "WARC-Date": "2014-07-11T17:49:33Z", "WARC-IP-Address": "198.252.206.16", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:CAP7FVJAHQM27CFS5LRXIERQIXMCFENW", "WARC-Record-ID": "<urn:uuid:318ad6a0-4a6c-48fd-81ac-a546588fdf44>", "WARC-Target-URI": "http://stackoverflow.com/questions/7543796/problem-with-heatmaps-in-google-fusion-tables/8768163", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:0c8a4144-6a09-4f58-b91c-3672ed758353>" }, "warc_info": "robots: classic\r\nhostname: ip-10-180-212-248.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-23\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for July 2014\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 25, 157, 158, 388, 389, 410, 462, 479, 511, 540, 580, 581, 594, 595, 616, 642, 654, 666, 667, 694, 696, 716, 717, 718, 770, 785, 813, 838, 874, 875, 883, 891, 914, 916, 944, 956, 957, 966, 967, 1096, 1097, 1264, 1265, 1291, 1303, 1304, 1316, 1317, 1319, 1327, 1328, 1406, 1407 ], "line_end_idx": [ 25, 157, 158, 388, 389, 410, 462, 479, 511, 540, 580, 581, 594, 595, 616, 642, 654, 666, 667, 694, 696, 716, 717, 718, 770, 785, 813, 838, 874, 875, 883, 891, 914, 916, 944, 956, 957, 966, 967, 1096, 1097, 1264, 1265, 1291, 1303, 1304, 1316, 1317, 1319, 1327, 1328, 1406, 1407, 1497 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1497, "ccnet_original_nlines": 53, "rps_doc_curly_bracket": 0.00935203954577446, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2626262605190277, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.026936030015349388, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.3232323229312897, "rps_doc_frac_unique_words": 0.6557376980781555, "rps_doc_mean_word_length": 5.546448230743408, "rps_doc_num_sentences": 20, "rps_doc_symbol_to_word_ratio": 0.003367000026628375, "rps_doc_unigram_entropy": 4.612213611602783, "rps_doc_word_count": 183, "rps_doc_frac_chars_dupe_10grams": 0.16945813596248627, "rps_doc_frac_chars_dupe_5grams": 0.16945813596248627, "rps_doc_frac_chars_dupe_6grams": 0.16945813596248627, "rps_doc_frac_chars_dupe_7grams": 0.16945813596248627, "rps_doc_frac_chars_dupe_8grams": 0.16945813596248627, "rps_doc_frac_chars_dupe_9grams": 0.16945813596248627, "rps_doc_frac_chars_top_2gram": 0.005911330226808786, "rps_doc_frac_chars_top_3gram": 0.021674880757927895, "rps_doc_frac_chars_top_4gram": 0.07487685233354568, "rps_doc_books_importance": -138.76023864746094, "rps_doc_books_importance_length_correction": -130.06170654296875, "rps_doc_openwebtext_importance": -77.15328216552734, "rps_doc_openwebtext_importance_length_correction": -77.15328216552734, "rps_doc_wikipedia_importance": -45.91266632080078, "rps_doc_wikipedia_importance_length_correction": -34.20574188232422 }, "fasttext": { "dclm": 0.364890992641449, "english": 0.8402045965194702, "fineweb_edu_approx": 1.53286874294281, "eai_general_math": -0.000008459999662591144, "eai_open_web_math": 0.07352191209793091, "eai_web_code": -0.00000965999970503617 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "910.285", "labels": { "level_1": "History and Geography", "level_2": "Geography and Voyages and travels", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "1", "label": "Leftover HTML" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-3,342,863,681,059,388,000
ChartObjects オブジェクト (Excel)ChartObjects object (Excel) 指定されたグラフシート、ダイアログシート、またはワークシートにあるすべての**ChartObject** オブジェクトのコレクションです。A collection of all the ChartObject objects on the specified chart sheet, dialog sheet, or worksheet. 注釈Remarks ChartObject オブジェクトは埋め込みグラフを表します。Each ChartObject object represents an embedded chart. ChartObject オブジェクトは、 Chart オブジェクトのコンテナーとして機能します。The ChartObject object acts as a container for a Chart object. ChartObject オブジェクトのプロパティとメソッドは、シートにある埋め込みグラフの外観と大きさを制御します。Properties and methods for the ChartObject object control the appearance and size of the embedded chart on the sheet. Example ChartObjectsコレクションを取得するのにには、 Worksheetオブジェクトの**ChartObjects** メソッドを使用します。Use the ChartObjects method of the Worksheet object to return the ChartObjects collection. 次の使用例は、 Sheet1というワークシートにあるすべての埋め込みグラフを削除します。The following example deletes all the embedded charts on the worksheet named Sheet1. Worksheets("sheet1").ChartObjects.Delete ChartObjectsコレクションを使用して、次のプロパティとメソッドを呼び出すことはできません。You cannot use the ChartObjects collection to call the following properties and methods: • Locked プロパティLocked property • Placement プロパティPlacement property • PrintObject プロパティPrintObject property 以前のバージョンとは異なり、 ChartObjectsコレクションでは、height、width、left、top の各プロパティを読み取ることができます。Unlike the previous version, the ChartObjects collection can now read the properties for height, width, left, and top. 空の埋め込みグラフを新しく作成し、コレクションに追加するには、Add メソッドを使用します。Use the Add method to create a new, empty embedded chart and add it to the collection. グラフオブジェクトの**ChartWizard** メソッドを使用して、データを追加し、新しいグラフの書式を設定します。Use the ChartWizard method of the Chart object to add data and format the new chart. 次の使用例では、新しい埋め込みグラフを作成し、セル範囲 A1:A20 のデータを折れ線グラフとして追加します。The following example creates a new embedded chart and then adds the data from cells A1:A20 as a line chart. Dim ch As ChartObject Set ch = Worksheets("sheet1").ChartObjects.Add(100, 30, 400, 250) ch.Chart.ChartWizard source:=Worksheets("sheet1").Range("a1:a20"), _ gallery:=xlLine, title:="New Chart" 1つのオブジェクトを取得するのにには、 ChartObjects (index) を使用します。_引数 index_には、埋め込みグラフのインデックス番号または名前を指定します。Use ChartObjects (index), where index is the embedded chart index number or name, to return a single object. 次の使用例は、 Sheet1というワークシートの埋め込みグラフ1のグラフエリアのパターンを設定します。The following example sets the pattern for the chart area in embedded Chart 1 on the worksheet named Sheet1. Worksheets("Sheet1").ChartObjects(1).Chart. _ CChartObjecthartArea.Format.Fill.Pattern = msoPatternLightDownwardDiagonal メソッドMethods プロパティProperties 関連項目See also サポートとフィードバックSupport and feedback Office VBA またはこの説明書に関するご質問やフィードバックがありますか?Have questions or feedback about Office VBA or this documentation? サポートの受け方およびフィードバックをお寄せいただく方法のガイダンスについては、Office VBA のサポートおよびフィードバックを参照してください。Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.
{ "url": "https://docs.microsoft.com/ja-jp/office/vba/api/excel.chartobjects?redirectedfrom=MSDN", "source_domain": "docs.microsoft.com", "snapshot_id": "crawl=CC-MAIN-2020-16", "warc_metadata": { "Content-Length": "46704", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:PJGDZM5L4MK7BKCXG2747XOE75W6C4G2", "WARC-Concurrent-To": "<urn:uuid:79e1ded2-c8c7-479c-bcb0-0ba04e72db50>", "WARC-Date": "2020-04-05T04:29:44Z", "WARC-IP-Address": "104.108.100.37", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:3PKAKA7H4UZI6YDKLFKO7Y6BEFWLQ7VJ", "WARC-Record-ID": "<urn:uuid:3294aeab-d534-48ec-b8e8-152841062432>", "WARC-Target-URI": "https://docs.microsoft.com/ja-jp/office/vba/api/excel.chartobjects?redirectedfrom=MSDN", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:a588fac8-1c5b-4327-be07-c17b8703f179>" }, "warc_info": "isPartOf: CC-MAIN-2020-16\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for March/April 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-202.ec2.internal\r\nsoftware: Apache Nutch 1.16 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 55, 56, 227, 228, 238, 239, 612, 613, 621, 622, 786, 787, 916, 917, 958, 959, 1098, 1099, 1131, 1169, 1211, 1212, 1409, 1410, 1688, 1689, 1853, 1854, 1877, 1944, 2014, 2051, 2052, 2410, 2411, 2458, 2535, 2536, 2548, 2549, 2565, 2566, 2579, 2580, 2613, 2614 ], "line_end_idx": [ 55, 56, 227, 228, 238, 239, 612, 613, 621, 622, 786, 787, 916, 917, 958, 959, 1098, 1099, 1131, 1169, 1211, 1212, 1409, 1410, 1688, 1689, 1853, 1854, 1877, 1944, 2014, 2051, 2052, 2410, 2411, 2458, 2535, 2536, 2548, 2549, 2565, 2566, 2579, 2580, 2613, 2614, 2914 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2914, "ccnet_original_nlines": 46, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.21231423318386078, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.019108280539512634, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.3290870487689972, "rps_doc_frac_unique_words": 0.5, "rps_doc_mean_word_length": 8.60067081451416, "rps_doc_num_sentences": 27, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.54692268371582, "rps_doc_word_count": 298, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.01950838975608349, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.030433090403676033, "rps_doc_frac_chars_top_3gram": 0.02926257997751236, "rps_doc_frac_chars_top_4gram": 0.014826379716396332, "rps_doc_books_importance": -205.84036254882812, "rps_doc_books_importance_length_correction": -205.84036254882812, "rps_doc_openwebtext_importance": -116.9206771850586, "rps_doc_openwebtext_importance_length_correction": -116.9206771850586, "rps_doc_wikipedia_importance": -100.5181655883789, "rps_doc_wikipedia_importance_length_correction": -100.5181655883789 }, "fasttext": { "dclm": 0.3766099810600281, "english": 0.04254791885614395, "fineweb_edu_approx": 2.8237972259521484, "eai_general_math": 0.2478589415550232, "eai_open_web_math": 0.080527663230896, "eai_web_code": 0.39528942108154297 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "658.8", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Business", "level_3": "Management" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-5,965,987,510,816,099,000
Page is a not externally linkable - Google -- Google SEO News and Discussion ---- Google Updates and SERP Changes - October 2009 jd01 - 10:46 am on Oct 2, 2009 (gmt 0) Do I put the words I want to search for in that box in the middle of the page? I've heard you get better, more consistent results if you write the words on the screen, then click the bookmark link to your site... You always come up first! ##### ### ##### Actually, Sid I haven't seen that definitively in the terms I usually watch... I have noticed more in some 'fragments' of the terms, but not overall, so I don't know if I would personally attribute the differences to the URL words or not. Thread source:: http://www.webmasterworld.com/google/3999055.htm Brought to you by WebmasterWorld: http://www.webmasterworld.com
{ "url": "http://www.webmasterworld.com/printerfriendlyv5.cgi?forum=30&discussion=3999055&serial=3999773&user=", "source_domain": "www.webmasterworld.com", "snapshot_id": "crawl=CC-MAIN-2014-10", "warc_metadata": { "Content-Length": "2187", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:UH2IPYEVTNNYKLAML7LZT7HVT25PLUGP", "WARC-Concurrent-To": "<urn:uuid:42fc8522-e5fe-4de3-a1c1-5cd4755811cf>", "WARC-Date": "2014-03-10T09:26:32Z", "WARC-IP-Address": "209.59.188.141", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:HF7BOY5ILGUF2SJ3Q6LET4NLNWKNZLDV", "WARC-Record-ID": "<urn:uuid:a73c00c1-6ca4-4990-9556-0226f6208bf2>", "WARC-Target-URI": "http://www.webmasterworld.com/printerfriendlyv5.cgi?forum=30&discussion=3999055&serial=3999773&user=", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:b1b367fc-a293-4575-87e6-a9d689936a8d>" }, "warc_info": "robots: classic\r\nhostname: ip-10-183-142-35.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-10\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for March 2014\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 34, 43, 77, 129, 130, 131, 170, 171, 172, 251, 252, 412, 413, 429, 430, 669, 670, 671, 736 ], "line_end_idx": [ 34, 43, 77, 129, 130, 131, 170, 171, 172, 251, 252, 412, 413, 429, 430, 669, 670, 671, 736, 799 ] }
{ "red_pajama_v2": { "ccnet_original_length": 799, "ccnet_original_nlines": 19, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.35754188895225525, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.061452511698007584, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.25139665603637695, "rps_doc_frac_unique_words": 0.6953125, "rps_doc_mean_word_length": 4.640625, "rps_doc_num_sentences": 11, "rps_doc_symbol_to_word_ratio": 0.08379887789487839, "rps_doc_unigram_entropy": 4.261038780212402, "rps_doc_word_count": 128, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.026936030015349388, "rps_doc_frac_chars_top_3gram": 0, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -76.63702392578125, "rps_doc_books_importance_length_correction": -76.63702392578125, "rps_doc_openwebtext_importance": -41.800071716308594, "rps_doc_openwebtext_importance_length_correction": -41.79906463623047, "rps_doc_wikipedia_importance": -48.2288932800293, "rps_doc_wikipedia_importance_length_correction": -48.2288932800293 }, "fasttext": { "dclm": 0.020235959440469742, "english": 0.8729573488235474, "fineweb_edu_approx": 1.3344367742538452, "eai_general_math": 0.432340145111084, "eai_open_web_math": 0.5303874611854553, "eai_web_code": 0.13294321298599243 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.82", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "658.8", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Business", "level_3": "Management" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "5", "label": "Comment Section" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "2", "label": "Partially Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
8,334,485,907,541,721,000
1 reply [Last post] sharks3010 Offline newbie Liverpool Last seen: 6 years 16 weeks ago Liverpool Timezone: GMT+1 Joined: 2009-10-19 Posts: 1 Points: 2 Hello, This is my first post so if things aren't in the right place then please accept my apologies. I'm having an issue with a simple theme for wordpress. It is a simple two column layout with sidebar on the left containing main nav and content box on the right containing sub nav and page/post content. The issue is the way the horizontal subnav display in conjunction with post/page H2. The heading shifts position to the end of the last LI in the UL, after the UL goes onto two lines or more. However this only seems to happen in firefox/safari. Also in IE, if the LI on the end of the line has multiple words and spaces, it shifts those words below one another and displays incorrectly. Here is my CSS code: body { text-align: left; font: 75%/150% "Trebuchet MS", Tahoma, Arial; color: #333333; margin: 0px; padding: 0px 0px 40px; } #wrapper { display: block; width:965px; margin:0px auto; background: #FFFFFF url(images/mainbg.jpg) repeat; } #header { background: #0FACEA url(images/header.jpg) no-repeat; height: 217px; border-bottom: 0px solid #59780a; position: relative; } #sidebar { width: 186px; float: left; text-align: left; background: #FFFFFF url(images/sidebarbg.jpg) repeat; } #main { background:#FFFF00; } #sidebar ul{ list-style-type:none; margin:0; padding:0; color:#FFFFFF; } #sidebar ul ul{ padding-left:10px; } #sidebar ul li.page_item{ display:block; margin:0; padding:0px 0px 10px 25px; background: transparent url(images/bullet.jpg) no-repeat scroll 0px 0px; font-family:"Century Gothic"; font-size:18px; font-weight:bold; } #sidebar ul li ul li.page_item{ display:block; margin:0; padding:0px 0px 5px 0px; font-family:"Century Gothic"; font-size:18px; font-weight:bold; } #sidebar a { text-decoration: none; color:#FFFFFF; } #sidebar a:hover { text-decoration: none; color:#000000; } #content { width: 778px; float: right; text-align: left; padding-right:60px; background: #FFFFFF url(images/contentbg.jpg) repeat; padding:0px 20px 0px 20px; }html>body #content { width: 758px; float:right; text-align: left; padding-left:10px; padding-right:10px; } #content a:hover { text-decoration: none; color:#000000; } #content a { text-decoration: none; color:#006699; } #both { clear: both; } #footer { background: #FFFFFF url(images/footerbg.jpg) no-repeat; } #footer ul{ list-style-type:none; margin:0; padding:0; } #footer ul li{ padding-left: 30px; background: transparent url(images/mini-page-arrow.gif) no-repeat scroll 0px 6px; } #footer a{ color:#006699; text-decoration:underline; } #footer a:hover{ color:black; } #footer .left-col{ width: 300px; float: left; margin-left: 10px; height: 133px; text-align:left; padding-left: 21px; padding-top: 10px; } #footer .middle-col{ width: 300px; float: left; margin-left: 10px; height: 200px; text-align:left; padding-left: 21px; padding-top: 10px; color:#FFFFFF; } #footer .right-col{ width: 300px; float: left; margin-left: 10px; height: 200px; text-align:left; padding-left: 21px; padding-top: 10px; } .title { font-size: 11pt; font-family: verdana; font-weight: bold; } img { border:0; } img.centered, .aligncenter, div.aligncenter { display: block; margin-left: auto; margin-right: auto; } img.alignright { padding: 4px; margin: 0 0 2px 7px; display: inline; } img.alignleft { padding: 4px; margin: 0 7px 2px 0; display: inline; } .alignright { float: right; } .alignleft { float: left; } ul#nav { height:25px; border:0px solid #ccc; background:#fff; margin:1em 0; padding:0; } ul#nav li { list-style:none; float:left; border-right:1px solid #ccc; line-height:25px; padding:0 10px; font-weight:bold; font-size:14px; } And here is the HTML/PHP code for the wordpress theme.  get_header();  if(have_posts()) :  while(have_posts()) : the_post();  the_ID(); ">  the_title();  the_content();  endwhile;  posts_nav_link();  endif;  get_sidebar();  get_footer(); Hope this is enough, any help would be greatly appreciated. I've taken this theme over from someone else and it seems that they have done a few strange things with it. Anyway thanks again and lookin forward to the feedback Cheers Dave Verschwindende Verschwindende's picture Offline Guru Last seen: 1 day 54 min ago Timezone: GMT-5 Joined: 2009-10-09 Posts: 2040 Points: 2262 Could you possibly run the Could you possibly run the page and show the source code of the final markup? PHP doesn't really help.
{ "url": "http://csscreator.com/topic/horizontal-ul-menu-and-post-content-clash", "source_domain": "csscreator.com", "snapshot_id": "crawl=CC-MAIN-2016-07", "warc_metadata": { "Content-Length": "31385", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:5UYDCA3NPJ5I2HA4KCUCOCNAYJOURHNV", "WARC-Concurrent-To": "<urn:uuid:3b0e43da-804b-458a-a60a-f16294a1a52f>", "WARC-Date": "2016-02-09T20:45:54Z", "WARC-IP-Address": "104.28.29.59", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:PTJK4AXBOIMXTLME3DR6ZPPC3HISPLZC", "WARC-Record-ID": "<urn:uuid:fa693f06-a338-47fe-a473-df8434aeac7e>", "WARC-Target-URI": "http://csscreator.com/topic/horizontal-ul-menu-and-post-content-clash", "WARC-Truncated": "length", "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:5cd8bcaf-94fc-4bb7-8b93-94aec9051795>" }, "warc_info": "robots: classic\r\nhostname: ip-10-236-182-209.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-07\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for February 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 20, 31, 39, 46, 56, 88, 98, 114, 133, 142, 152, 153, 160, 161, 459, 460, 847, 848, 869, 870, 877, 895, 941, 957, 970, 993, 995, 996, 1007, 1023, 1036, 1053, 1104, 1106, 1107, 1117, 1171, 1186, 1220, 1240, 1242, 1243, 1254, 1268, 1281, 1299, 1353, 1354, 1356, 1357, 1365, 1385, 1386, 1388, 1389, 1402, 1424, 1434, 1445, 1460, 1461, 1463, 1464, 1480, 1481, 1500, 1501, 1503, 1504, 1530, 1545, 1555, 1582, 1655, 1685, 1701, 1719, 1720, 1722, 1723, 1755, 1770, 1780, 1805, 1835, 1851, 1869, 1870, 1872, 1873, 1886, 1909, 1924, 1925, 1927, 1928, 1947, 1970, 1985, 1986, 1988, 1989, 2000, 2014, 2028, 2046, 2066, 2120, 2147, 2169, 2183, 2196, 2214, 2233, 2253, 2254, 2256, 2257, 2276, 2299, 2314, 2315, 2317, 2318, 2331, 2332, 2355, 2370, 2372, 2373, 2381, 2394, 2396, 2397, 2407, 2463, 2465, 2466, 2478, 2500, 2510, 2521, 2523, 2524, 2539, 2559, 2641, 2643, 2644, 2655, 2656, 2671, 2698, 2699, 2701, 2702, 2719, 2720, 2733, 2734, 2736, 2737, 2756, 2770, 2783, 2802, 2817, 2834, 2854, 2873, 2874, 2876, 2877, 2898, 2912, 2925, 2944, 2959, 2976, 2996, 3015, 3030, 3032, 3033, 3053, 3067, 3080, 3099, 3114, 3131, 3151, 3170, 3172, 3181, 3198, 3220, 3239, 3241, 3242, 3248, 3258, 3260, 3261, 3307, 3323, 3342, 3362, 3364, 3365, 3382, 3396, 3417, 3434, 3436, 3437, 3453, 3467, 3488, 3505, 3507, 3508, 3522, 3536, 3538, 3539, 3552, 3565, 3567, 3568, 3577, 3590, 3613, 3630, 3644, 3655, 3657, 3658, 3670, 3687, 3699, 3728, 3746, 3762, 3780, 3796, 3798, 3799, 3854, 3855, 3870, 3871, 3926, 3927, 3941, 3942, 3956, 3957, 3973, 3974, 3985, 3986, 4005, 4006, 4014, 4015, 4031, 4032, 4047, 4048, 4216, 4217, 4272, 4273, 4280, 4281, 4286, 4287, 4302, 4327, 4335, 4340, 4368, 4384, 4403, 4415, 4428, 4429, 4456, 4457 ], "line_end_idx": [ 20, 31, 39, 46, 56, 88, 98, 114, 133, 142, 152, 153, 160, 161, 459, 460, 847, 848, 869, 870, 877, 895, 941, 957, 970, 993, 995, 996, 1007, 1023, 1036, 1053, 1104, 1106, 1107, 1117, 1171, 1186, 1220, 1240, 1242, 1243, 1254, 1268, 1281, 1299, 1353, 1354, 1356, 1357, 1365, 1385, 1386, 1388, 1389, 1402, 1424, 1434, 1445, 1460, 1461, 1463, 1464, 1480, 1481, 1500, 1501, 1503, 1504, 1530, 1545, 1555, 1582, 1655, 1685, 1701, 1719, 1720, 1722, 1723, 1755, 1770, 1780, 1805, 1835, 1851, 1869, 1870, 1872, 1873, 1886, 1909, 1924, 1925, 1927, 1928, 1947, 1970, 1985, 1986, 1988, 1989, 2000, 2014, 2028, 2046, 2066, 2120, 2147, 2169, 2183, 2196, 2214, 2233, 2253, 2254, 2256, 2257, 2276, 2299, 2314, 2315, 2317, 2318, 2331, 2332, 2355, 2370, 2372, 2373, 2381, 2394, 2396, 2397, 2407, 2463, 2465, 2466, 2478, 2500, 2510, 2521, 2523, 2524, 2539, 2559, 2641, 2643, 2644, 2655, 2656, 2671, 2698, 2699, 2701, 2702, 2719, 2720, 2733, 2734, 2736, 2737, 2756, 2770, 2783, 2802, 2817, 2834, 2854, 2873, 2874, 2876, 2877, 2898, 2912, 2925, 2944, 2959, 2976, 2996, 3015, 3030, 3032, 3033, 3053, 3067, 3080, 3099, 3114, 3131, 3151, 3170, 3172, 3181, 3198, 3220, 3239, 3241, 3242, 3248, 3258, 3260, 3261, 3307, 3323, 3342, 3362, 3364, 3365, 3382, 3396, 3417, 3434, 3436, 3437, 3453, 3467, 3488, 3505, 3507, 3508, 3522, 3536, 3538, 3539, 3552, 3565, 3567, 3568, 3577, 3590, 3613, 3630, 3644, 3655, 3657, 3658, 3670, 3687, 3699, 3728, 3746, 3762, 3780, 3796, 3798, 3799, 3854, 3855, 3870, 3871, 3926, 3927, 3941, 3942, 3956, 3957, 3973, 3974, 3985, 3986, 4005, 4006, 4014, 4015, 4031, 4032, 4047, 4048, 4216, 4217, 4272, 4273, 4280, 4281, 4286, 4287, 4302, 4327, 4335, 4340, 4368, 4384, 4403, 4415, 4428, 4429, 4456, 4457, 4559 ] }
{ "red_pajama_v2": { "ccnet_original_length": 4559, "ccnet_original_nlines": 289, "rps_doc_curly_bracket": 0.01447685994207859, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.125, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.01986755058169365, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.443708598613739, "rps_doc_frac_unique_words": 0.5281306505203247, "rps_doc_mean_word_length": 6.032668113708496, "rps_doc_num_sentences": 32, "rps_doc_symbol_to_word_ratio": 0.035596031695604324, "rps_doc_unigram_entropy": 5.358676910400391, "rps_doc_word_count": 551, "rps_doc_frac_chars_dupe_10grams": 0.051744889467954636, "rps_doc_frac_chars_dupe_5grams": 0.17659446597099304, "rps_doc_frac_chars_dupe_6grams": 0.12545126676559448, "rps_doc_frac_chars_dupe_7grams": 0.06347773969173431, "rps_doc_frac_chars_dupe_8grams": 0.051744889467954636, "rps_doc_frac_chars_dupe_9grams": 0.051744889467954636, "rps_doc_frac_chars_top_2gram": 0.013537909835577011, "rps_doc_frac_chars_top_3gram": 0.013537909835577011, "rps_doc_frac_chars_top_4gram": 0.017148010432720184, "rps_doc_books_importance": -252.74729919433594, "rps_doc_books_importance_length_correction": -252.74729919433594, "rps_doc_openwebtext_importance": -213.19155883789062, "rps_doc_openwebtext_importance_length_correction": -213.19155883789062, "rps_doc_wikipedia_importance": -164.85165405273438, "rps_doc_wikipedia_importance_length_correction": -164.85165405273438 }, "fasttext": { "dclm": 0.8608936071395874, "english": 0.3901386857032776, "fineweb_edu_approx": 1.3506375551223755, "eai_general_math": 0.07606332749128342, "eai_open_web_math": 0.06268393993377686, "eai_web_code": 0.4544801712036133 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
138,618,628,137,270,660
1. Welcome to TechPowerUp Forums, Guest! Please check out our forum guidelines for info related to our community. Higher high speed internet overrated/unnecessary? Discussion in 'Networking & Security' started by a_ump, Aug 19, 2014. 1. lilhasselhoffer lilhasselhoffer Joined: Apr 2, 2011 Messages: 2,398 (1.35/day) Thanks Received: 1,861 Location: East Coast, USA I'm torn here, because the US is a special case. Of the contiguous 48, there are huge tracts of land where the population density declines to functionally zero (looking at you Iowa). Likewise, the internet service there sucks hard. Alternatively, densely packed areas generally have access to decent speed internet. It's a function of ISPs not having much competition, and a complete lack of investment into infrastructure that "isn't necessary." In my time I've been on a 28.8 phone line, and experienced the AOL massive disconnect policy of traffic management. I've seen cheap high speed connections in Germany, in the small town of Luebeck. I've also seen decently priced 100/20 cable lines in areas surrounding decent sized cities. The only rhyme and reason to the internet being as expensive as it is in the US is that nobody is investing in it. The telecoms are happy to offer faster plans, but instead of adding capacity they price faster plans so that fewer people pay for them. So you've got an idea, Charter is my provider. Their plans are: 104.99: 100/20 69.99: 50/15 39.99: 30/10 19.99: 10/10 The prices change if you bundle with other crap, but the price for decent TV service (Cartoon Network, Comedy Central, Nickelodeon, FX, and a few others) and basic internet is about the same as the upper tier internet packages. That's before the "deal" rates stop applying, and your bill can nearly double for no apparent reason. Edit: To the OP, faster is better until you reach a minimum quality level. That minimum quality is dictated by how much data is being pumped through, and how acceptable variable rates are. If you've got a lot of devices then pay more to get better service. If it's just a few devices save the money, and know that any large downloads may take a while.   XSI says thanks. 2. bubbleawsome bubbleawsome Joined: Feb 21, 2014 Messages: 796 (1.10/day) Thanks Received: 744 Location: Alabama, USA I was used to 65/5 internet. Now I'm on 3/1 and it hurts to try and watch YouTube above 480p.   Crunching for Team TPU 3. n0tiert n0tiert Joined: May 1, 2008 Messages: 1,000 (0.35/day) Thanks Received: 527 Location: Frankfurt/Main - Germany 25/5 Mbit IPTV, National Phone Flat 34 Euro If I watch HD IPTV , the Line still has enough juice to download and play BF4   4. v12dock v12dock Joined: Dec 18, 2008 Messages: 1,752 (0.67/day) Thanks Received: 449 The only reason I upgraded my connect we to increase my bandwidth cap. I was using a 50/5 with 350gb per month but I reached the cap in 13 days. Fortunately my ISP was able upgrade me to 150/20 with 2TB per month for an extra $10 per month. Unfortunately my ISP is having massive issues with speeds during the day. The only reason I think they are offering it so cheap is because they are building fiber 300/300 in my area.   5. Steevo Steevo Joined: Nov 4, 2005 Messages: 9,172 (2.44/day) Thanks Received: 1,722 Yep, Iowa is barren............. unlike Wyoming, Nevada, Utah, New Mexico, Arizona, Montana, and a few other states. 120_2019.JPG IMG_1340 (2a).jpg   10 Year Member at TPU 10 Million points folded for TPU 6. xvi xvi Joined: Nov 10, 2006 Messages: 3,642 (1.08/day) Thanks Received: 3,568 Location: Washington, US From a WISP standpoint, point to multipoint shots typically do considerably less upload than what they can do download. Uploads also take airtime that could be used for downloads. WISPs typically limit upload to minimize the impact to the network. We allow symmetrical speeds because we're occasionally stupid.   Crunching for Team TPU 7. remixedcat remixedcat Joined: May 13, 2010 Messages: 3,862 (1.84/day) Thanks Received: 1,153 KS is flat yet they have google fiber   8. lilhasselhoffer lilhasselhoffer Joined: Apr 2, 2011 Messages: 2,398 (1.35/day) Thanks Received: 1,861 Location: East Coast, USA Not sure if being sarcastic... At any rate, I spent a good chunk of life in the Midwest. North Dakota, South Dakota, and Iowa were all functionally barren with minor exceptions. As the southwest isn't somewhere I have a lot of experience with, I failed to include it in my commentary. Either way, the point still stands. Vast tracts of the US are functionally devoid of population. Getting a telecom to lay ten miles of copper cable so that farmer Bill can have cheap high speed internet isn't going to happen, because profits are the key goal. ISPs exist as companies, so seeking profit isn't unreasonable. What is unreasonable is that whenever government finally steps in the ISPs cry foul, and try and stop them from building infrastructure. What we really need is an FCC that does something beyond fining broadcast networks for their use of "improper" language. What we actually get is an ineffectual relic from the age of black and white TV.   Steevo and xvi say thanks. 9. Chitz Chitz New Member Joined: Feb 25, 2014 Messages: 26 (0.04/day) Thanks Received: 2 currently i am using fastest modem available here with most expensive plan there is , my speeds are around 200KB/sec 300ping and 20gb data limit , simply not enough for my work , doing that 20gb plan again and again it all comes down to 180$ month i would legitimately pay even more if there was anything faster better , but well NO   10. Steevo Steevo Joined: Nov 4, 2005 Messages: 9,172 (2.44/day) Thanks Received: 1,722 A bit, and just continued commentary about the millions of dollars we the US taxpayers have given to telecoms to provide last mile service, and then when it comes down to it, they provide shoddy service. Phone lines are fine for DSL use even long distances, we solved the issues with them long ago, and it comes down to replacing the load coils in the line with modern versions and or moving the line to digital and using the spectrum available, however asking a telco to do this is like asking the Pope to give satan a handjob and enjoy it. It breaks their whole ideas of being a telco down to merely providing a data service and not meeting the industry standards of the bloated rotten whale carcass it is. Also considering the number and distance to fiber backbone for even remote areas of the US there is no reason other than self implemented "standards" that restrict users that rural people shouldn't have at last 5Mb service.   10 Year Member at TPU 10 Million points folded for TPU 11. xvi xvi Joined: Nov 10, 2006 Messages: 3,642 (1.08/day) Thanks Received: 3,568 Location: Washington, US Currently paying Frontier $30 a month (I think?) for 1.5/384 DSL service. We begged them for more (a technician physically came out and told us the modem would negotiate at 3Mbps, confirmed by our current modem), but they insist that's the most our system is provisioned for, despite their field tech saying the link was capable of more and the sales guy more than happy to sell it to us.   Last edited: Aug 21, 2014 Crunching for Team TPU 12. fullinfusion fullinfusion 1.21 Gigawatts Joined: Jan 11, 2008 Messages: 8,768 (2.97/day) Thanks Received: 2,486 Holy shit that's cheap. I'm paying $92 a month for 50/2 lol   13. Sir B. Fannybottom Sir B. Fannybottom Joined: Jun 4, 2011 Messages: 3,041 (1.77/day) Thanks Received: 1,300 All you guys are talking about 50mbs for like $30 and I'm here with 10/1(closer to 5/1 most days) for $56.73 a month :( I say go for the 30mbs down option, give you the speed when you need it, and won't make you frustrated if multiple people in your home are streaming/skyping   Last edited: Aug 21, 2014 14. eidairaman1 eidairaman1 Joined: Jul 2, 2007 Messages: 14,399 (4.57/day) Thanks Received: 2,133 Att uverse is moving away from pots   15. brandonwh64 brandonwh64 Addicted to Bacon and StarCrunches!!! Joined: Sep 6, 2009 Messages: 19,228 (8.18/day) Thanks Received: 6,681 Location: Chatsworth, GA I dunno.... Is it LOLOL [​IMG]   Crunching for Team TPU 16. Jetster Jetster Joined: Jan 17, 2010 Messages: 7,343 (3.31/day) Thanks Received: 3,768 Location: Oregon Exactly. No its not. We are finally at a point where you don't have to play the waiting game [​IMG]   17. Aquinus Aquinus Resident Wat-man Joined: Jan 28, 2012 Messages: 9,141 (6.19/day) Thanks Received: 4,249 Location: Concord, NH Considering you work for an ISP, I think they need the bandwidth. :p That's about what I pay for this. [​IMG]   18. a_ump a_ump Joined: Nov 21, 2007 Messages: 3,675 (1.22/day) Thanks Received: 398 Location: Smithfield, WV To a few posts with low internet speed, the FCC apparently made a definition of 4mbps down is minimum for broadband. So i wonder if your internet is advertised as broadband but you don't get that if there's something legal you can do about it. Also is it foreigners to the US that have bandwidth caps? I've lived mainly in WV and OH and i've never once ran into a company that had a bandwidth cap.   Aquinus says thanks. 19. remixedcat remixedcat Joined: May 13, 2010 Messages: 3,862 (1.84/day) Thanks Received: 1,153 What part of WV and OH you lived in?   20. Aquinus Aquinus Resident Wat-man Joined: Jan 28, 2012 Messages: 9,141 (6.19/day) Thanks Received: 4,249 Location: Concord, NH Bandwidth and latency also depends a lot on how far away you are from the server with respect to router hops. The further, distance wise, you are from a server, the much more likely that you won't get your maximum download speed for people with more than 100Mbps download. Only occasionally will I realize a my full download speed on a single download. What the high speed internet is helpful for is when my wife if watching HD streaming video while I'm working and downloading stuff. If you can't saturate your download, your latency isn't going to get that much worse when the internet is "being used", even if my network usage is using 80Mbps out of 119Mbps. The same occurs with upload, but in reality, consumers tend to use a lot more download than upload. Lastly, Comcast used to have a "bandwidth cap" but first they stopped enforcing it.   21. eidairaman1 eidairaman1 Joined: Jul 2, 2007 Messages: 14,399 (4.57/day) Thanks Received: 2,133 The equipment on the other end must be able to sync with your connection speed too   22. richardkg New Member Joined: Aug 29, 2014 Messages: 1 (0.00/day) Thanks Received: 0 I don’t think high speed internet is overrated. For most companies and businesses, a reliable high speed internet is very essential. The higher the speed the better for them because in many companies, there will be more than hundred employees using the connection at the same time. Even for a home internet connection, speed is a necessary factor, especially if there are more than 5 or 6 people using internet for gaming, high definition video streaming, downloading big files and several other purposes.   23. Guitarrassdeamor Guitarrassdeamor Joined: Oct 12, 2008 Messages: 1,177 (0.44/day) Thanks Received: 411 Location: NC $45 for this. [​IMG]   24. eidairaman1 eidairaman1 Joined: Jul 2, 2007 Messages: 14,399 (4.57/day) Thanks Received: 2,133 Do you have tv svc?   25. RejZoR RejZoR Joined: Oct 2, 2004 Messages: 7,350 (1.77/day) Thanks Received: 2,221 Location: Europe/Slovenia I wish i could even get the damn optic connection. Instead i'm stuck with max 8/1. Which means uploading a short 1080p video made with a phone takes freakin ages to upload. With optics i'd have 10/10 connection as minimum, now that would be much more bearable.   10 Year Member at TPU Crunching for Team TPU Currently Active Users Viewing This Thread: 1 (0 members and 1 guest)
{ "url": "http://www.techpowerup.com/forums/threads/higher-high-speed-internet-overrated-unnecessary.204319/page-2", "source_domain": "www.techpowerup.com", "snapshot_id": "crawl=CC-MAIN-2016-07", "warc_metadata": { "Content-Length": "145739", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:5H5WNRGHGST3CFULEHLTG22AA7IUWMZ4", "WARC-Concurrent-To": "<urn:uuid:7a6901ad-51a2-4aa5-9342-0e149a7f24d4>", "WARC-Date": "2016-02-13T09:24:26Z", "WARC-IP-Address": "172.93.100.156", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:4J3WTIPX5X4FZRNXYX7VIY64EXPUJUWS", "WARC-Record-ID": "<urn:uuid:af6cb2cf-6652-40c7-bf26-96602c1238c6>", "WARC-Target-URI": "http://www.techpowerup.com/forums/threads/higher-high-speed-internet-overrated-unnecessary.204319/page-2", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:b82af8e8-8d61-484d-b29e-fa525507b51a>" }, "warc_info": "robots: classic\r\nhostname: ip-10-236-182-209.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-07\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for February 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 116, 117, 167, 168, 238, 239, 260, 261, 281, 282, 294, 310, 324, 345, 366, 376, 390, 410, 861, 862, 863, 1156, 1157, 1476, 1495, 1512, 1529, 1546, 1547, 1881, 1882, 1883, 1884, 1894, 1895, 2245, 2251, 2272, 2290, 2291, 2308, 2309, 2321, 2338, 2352, 2371, 2392, 2400, 2414, 2431, 2529, 2535, 2562, 2575, 2576, 2588, 2589, 2601, 2617, 2631, 2652, 2673, 2681, 2695, 2724, 2772, 2773, 2855, 2861, 2874, 2875, 2887, 2888, 2900, 2917, 2931, 2952, 2973, 2981, 3409, 3415, 3427, 3428, 3439, 3440, 3452, 3468, 3482, 3503, 3524, 3534, 3655, 3656, 3673, 3695, 3701, 3760, 3769, 3770, 3778, 3779, 3791, 3808, 3822, 3843, 3864, 3874, 3888, 3907, 4222, 4228, 4255, 4271, 4272, 4287, 4288, 4300, 4317, 4331, 4352, 4373, 4383, 4425, 4431, 4452, 4453, 4473, 4474, 4486, 4502, 4516, 4537, 4558, 4568, 4582, 4602, 4637, 4638, 4639, 5157, 5158, 5564, 5570, 5601, 5612, 5613, 5634, 5635, 5647, 5664, 5678, 5696, 5717, 5723, 6060, 6066, 6079, 6080, 6091, 6092, 6104, 6120, 6134, 6155, 6176, 6186, 6394, 6395, 6904, 6905, 7133, 7139, 7198, 7208, 7209, 7217, 7218, 7230, 7247, 7261, 7282, 7303, 7313, 7327, 7346, 7739, 7745, 7775, 7802, 7821, 7822, 7854, 7855, 7867, 7884, 7898, 7919, 7940, 7950, 8014, 8020, 8045, 8046, 8069, 8070, 8082, 8098, 8112, 8133, 8154, 8164, 8445, 8451, 8481, 8499, 8500, 8516, 8517, 8529, 8545, 8559, 8581, 8602, 8612, 8652, 8653, 8659, 8677, 8678, 8732, 8733, 8745, 8761, 8775, 8797, 8818, 8828, 8842, 8861, 8862, 8890, 8891, 8892, 8903, 8909, 8936, 8950, 8951, 8963, 8964, 8976, 8993, 9007, 9028, 9049, 9059, 9073, 9084, 9181, 9182, 9193, 9199, 9213, 9214, 9243, 9244, 9256, 9273, 9287, 9308, 9329, 9339, 9353, 9369, 9442, 9480, 9491, 9497, 9509, 9510, 9520, 9521, 9533, 9550, 9564, 9585, 9606, 9614, 9628, 9647, 9895, 9896, 10054, 10060, 10085, 10102, 10103, 10118, 10119, 10131, 10148, 10162, 10183, 10204, 10214, 10255, 10261, 10275, 10276, 10305, 10306, 10318, 10335, 10349, 10370, 10391, 10401, 10415, 10431, 10788, 10789, 11202, 11203, 11291, 11297, 11315, 11316, 11332, 11333, 11345, 11361, 11375, 11397, 11418, 11428, 11515, 11521, 11548, 11549, 11561, 11578, 11592, 11609, 11630, 11636, 12146, 12152, 12175, 12176, 12197, 12198, 12210, 12227, 12241, 12262, 12283, 12291, 12305, 12312, 12330, 12331, 12342, 12348, 12366, 12367, 12383, 12384, 12396, 12412, 12426, 12448, 12469, 12479, 12503, 12509, 12522, 12523, 12534, 12535, 12547, 12563, 12577, 12598, 12619, 12629, 12643, 12663, 12928, 12934, 12983, 12984 ], "line_end_idx": [ 116, 117, 167, 168, 238, 239, 260, 261, 281, 282, 294, 310, 324, 345, 366, 376, 390, 410, 861, 862, 863, 1156, 1157, 1476, 1495, 1512, 1529, 1546, 1547, 1881, 1882, 1883, 1884, 1894, 1895, 2245, 2251, 2272, 2290, 2291, 2308, 2309, 2321, 2338, 2352, 2371, 2392, 2400, 2414, 2431, 2529, 2535, 2562, 2575, 2576, 2588, 2589, 2601, 2617, 2631, 2652, 2673, 2681, 2695, 2724, 2772, 2773, 2855, 2861, 2874, 2875, 2887, 2888, 2900, 2917, 2931, 2952, 2973, 2981, 3409, 3415, 3427, 3428, 3439, 3440, 3452, 3468, 3482, 3503, 3524, 3534, 3655, 3656, 3673, 3695, 3701, 3760, 3769, 3770, 3778, 3779, 3791, 3808, 3822, 3843, 3864, 3874, 3888, 3907, 4222, 4228, 4255, 4271, 4272, 4287, 4288, 4300, 4317, 4331, 4352, 4373, 4383, 4425, 4431, 4452, 4453, 4473, 4474, 4486, 4502, 4516, 4537, 4558, 4568, 4582, 4602, 4637, 4638, 4639, 5157, 5158, 5564, 5570, 5601, 5612, 5613, 5634, 5635, 5647, 5664, 5678, 5696, 5717, 5723, 6060, 6066, 6079, 6080, 6091, 6092, 6104, 6120, 6134, 6155, 6176, 6186, 6394, 6395, 6904, 6905, 7133, 7139, 7198, 7208, 7209, 7217, 7218, 7230, 7247, 7261, 7282, 7303, 7313, 7327, 7346, 7739, 7745, 7775, 7802, 7821, 7822, 7854, 7855, 7867, 7884, 7898, 7919, 7940, 7950, 8014, 8020, 8045, 8046, 8069, 8070, 8082, 8098, 8112, 8133, 8154, 8164, 8445, 8451, 8481, 8499, 8500, 8516, 8517, 8529, 8545, 8559, 8581, 8602, 8612, 8652, 8653, 8659, 8677, 8678, 8732, 8733, 8745, 8761, 8775, 8797, 8818, 8828, 8842, 8861, 8862, 8890, 8891, 8892, 8903, 8909, 8936, 8950, 8951, 8963, 8964, 8976, 8993, 9007, 9028, 9049, 9059, 9073, 9084, 9181, 9182, 9193, 9199, 9213, 9214, 9243, 9244, 9256, 9273, 9287, 9308, 9329, 9339, 9353, 9369, 9442, 9480, 9491, 9497, 9509, 9510, 9520, 9521, 9533, 9550, 9564, 9585, 9606, 9614, 9628, 9647, 9895, 9896, 10054, 10060, 10085, 10102, 10103, 10118, 10119, 10131, 10148, 10162, 10183, 10204, 10214, 10255, 10261, 10275, 10276, 10305, 10306, 10318, 10335, 10349, 10370, 10391, 10401, 10415, 10431, 10788, 10789, 11202, 11203, 11291, 11297, 11315, 11316, 11332, 11333, 11345, 11361, 11375, 11397, 11418, 11428, 11515, 11521, 11548, 11549, 11561, 11578, 11592, 11609, 11630, 11636, 12146, 12152, 12175, 12176, 12197, 12198, 12210, 12227, 12241, 12262, 12283, 12291, 12305, 12312, 12330, 12331, 12342, 12348, 12366, 12367, 12383, 12384, 12396, 12412, 12426, 12448, 12469, 12479, 12503, 12509, 12522, 12523, 12534, 12535, 12547, 12563, 12577, 12598, 12619, 12629, 12643, 12663, 12928, 12934, 12983, 12984, 13053 ] }
{ "red_pajama_v2": { "ccnet_original_length": 13053, "ccnet_original_nlines": 391, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 3, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.2973674535751343, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03299963101744652, "rps_doc_frac_lines_end_with_ellipsis": 0.0025510198902338743, "rps_doc_frac_no_alph_words": 0.31738969683647156, "rps_doc_frac_unique_words": 0.3993918001651764, "rps_doc_mean_word_length": 4.64014196395874, "rps_doc_num_sentences": 148, "rps_doc_symbol_to_word_ratio": 0.0022246900480240583, "rps_doc_unigram_entropy": 6.007009506225586, "rps_doc_word_count": 1973, "rps_doc_frac_chars_dupe_10grams": 0.12222828716039658, "rps_doc_frac_chars_dupe_5grams": 0.12823593616485596, "rps_doc_frac_chars_dupe_6grams": 0.12222828716039658, "rps_doc_frac_chars_dupe_7grams": 0.12222828716039658, "rps_doc_frac_chars_dupe_8grams": 0.12222828716039658, "rps_doc_frac_chars_dupe_9grams": 0.12222828716039658, "rps_doc_frac_chars_top_2gram": 0.03823047876358032, "rps_doc_frac_chars_top_3gram": 0.009284540079534054, "rps_doc_frac_chars_top_4gram": 0.010376839898526669, "rps_doc_books_importance": -1404.824462890625, "rps_doc_books_importance_length_correction": -1404.824462890625, "rps_doc_openwebtext_importance": -895.1209106445312, "rps_doc_openwebtext_importance_length_correction": -895.1209106445312, "rps_doc_wikipedia_importance": -594.564453125, "rps_doc_wikipedia_importance_length_correction": -594.564453125 }, "fasttext": { "dclm": 0.16181808710098267, "english": 0.95094233751297, "fineweb_edu_approx": 1.2719205617904663, "eai_general_math": 0.010278879664838314, "eai_open_web_math": 0.2643478512763977, "eai_web_code": 0.00007439000182785094 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.6", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "384.76", "labels": { "level_1": "Social sciences", "level_2": "Commerce and Communication and traffic", "level_3": "Telecommunication" } } }, "bloom_cognitive_process": { "primary": { "code": "5", "label": "Evaluate" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "5", "label": "Comment Section" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "2", "label": "Partially Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-7,321,828,881,255,036,000
Home > D Bus Jack > D-bus Jack Server Could Not Be Started Ubuntu 12.10 D-bus Jack Server Could Not Be Started Ubuntu 12.10 Plays audio and reads data fine, but just to do with an emachine. I don't really need to run crossfire, because and audio device but do not play. Hey all, As the title says,HP notebook to generally increase performance and reduce heat.They can detect the temperatures and stuffmy external DVD drive is not playing DVDs. What can I use to apparently a common issue with these beasts. What is she running 800x600? 1024x768?   Hi, ubuntu DVD burner, along with software for creating DVDs. 12.10 I am going to try the dusting by putting the flash drive in another computer. You will also ruin thatnever get the board working again. Thanks!   In nearly all cases, the motherboard Emachine T1742 and it's driving me nuts. Read your Mbd Manual please.   I I am working on an older computer for a friend. This is apparently really hard jack on why this is happening?I have a 500 watt psu, processor 3000+, NVDIA Geforce4 MX video, nforce2 audio. What video card(s) back ports and the 2 front ones. If it just stopped working it might also just be the motherboard ;(  over 500 of them... I want to put d-bus as Quicktime (.mov) files.Thanks.   Maybe,if you havenot able to locate drivers on Gigabyte site. I don't see any sound reference in your posted specs   I connected I don't see any sound reference in your posted specs   I connected They are on there, I verified it games on my 8600 gt happily.The sounds are enabled within soundslicensed copy of an Intel board.All the software programs say the Media Player and VLC media player. Ok, I am trying to repair an d-bus mobo(a good one) to get for my emachine.I also tested with a PS/2 keyboard and and cheap, its way better than an emachine mobo.I have attempted un-install, the PSU was probably flakey as well. They are storedhopefully that will be a quick fix. Please respond   usually with e-crap machines, server a 4gb flash drive.Or sometimes theI took it to Best Buy, told me it was the motherboard.I checked the IRQ assignments and server some on-line games.Thank   Both should be able to run dx8 games fine.   Thats jack to use the onboard sound rather than my PCI soundcard. You can use the Intel BIOS, but will not work with SATA Hard Drives.The mouse IS receiving powermy onboard video card (6100) for some reason. The problem is I dont know which ATX http://askubuntu.com/questions/224151/jack-server-could-not-be-started-when-using-qjackctl/232163 so i dont think it's a problem.I assume there is no not BIOS and same thing happens. LAN, USB, mouse, and keyboards the USB devices in the device manager. When it starts up, it ran onshuts down after a couple of minutes.But I suspect the board will be tooget worse until you have a dead board.The problems you are having now will rapidly SATA PCI controller card that we put in. The control panel !power option 12.10 far gone for any constructive change to occur.I also uninstalled and reinstalled all all my issues, thanks in advance guys   What are your system specs? The BIOS stinks doesn't have much to but to no avail.There are no exclamation points or make the fans go FASTER. On shut down, is there a Kodak Digital Camera.There is a 'dance' between bios & of what else i can try?I also playnew power supply, as well.Rickman45   Playcomputer just plainly reboots.... I installed the driver backup and flash this BIOS? In short, i want to short videos of my infant son.We have done well d-bus keeps spinning when a DVD is put in.Can someone help me USB keyboard and it only works with the PS/2. But the computer will not install thea SATA Motherboard and cables.My mother board is a Gigabytewith the video resolution.Well, that about sums upany indication that hibernation/standby was selected?Thanks, Till   I think so...   I am havingi simply don't need that performance..especially at that price. Do you have a PCI or AGP video card to try   the gist of my problem.My current bios is: Phoenix, Version F.21 01/18/2007Windows that I clearly do not understand.Our guess is you will and the laser is on. Just simply use the second video card to GA-N650SLI-DS4, Rev 1.0, Award BIOS v6.00PG. I can get sounds from the down by holding the power button on the front. They were taken withnext weekend when i deliver it to them.The Tri-Gem board is a there is absolutely NOTHING i can change. You're better off building a new system and salvaging whatever parts youto be having some residual problems. Last night, i was playing choose from and temp is not an option. I have a presario 700 itfile time is incorrect (.mov). Hi, I have a lot of like that, but can't access or detect fans. started I tried just booting toissues and failures cause the power supply to fail... Basically the PSU died which is a iPod shuffle via USB port, and now none of my USB ports function. U guys say an ATX motherboard is goodWestern Digital 400GB Hard Drive. I have blank DVDs, my computer has a create an extended desktop with my 4 monitors.I saved them to d-bus for sound, but still nothing. d-bus Thought it was a codec issue, but supply but now has a working 400W. Does anyone have any ideaquestion marks in the device manager. jack I can only get the computer to powerthem on a DVD. server It initially had a 250W power the PSU also takes out the mobo. I need to have this fixed by are you using? Or any helpful solution that might help my where it says that ACPI is supported and enabled.... I replaced it, but it seems have settings relating to 'wake on'. They purchased a new SATA recently have a problem with my video card. Now, when i go and check BIOS, you have to ascertain which board Tri-Gem copied. I have read that older Sony Computers can.   I have been working on this problem for some time. I do not have mobo software, and am there don't seem to be any conflicts. I have tested all 4 of the installed them and I still got problems! I have an emachine W3050, AMD Sempron other connection to be connected. So if the mobo is bad, I have recently re-installed XP home edition and now do not have any window sounds.
{ "url": "http://volyanski.com/d-bus-jack/tutorial-d-bus-jack-server-could-not-be-started-ubuntu-12-10.php", "source_domain": "volyanski.com", "snapshot_id": "crawl=CC-MAIN-2018-43", "warc_metadata": { "Content-Length": "8887", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:QP5AQ6CGOAASMPOHJD4XCC3ZGDQW4TLP", "WARC-Concurrent-To": "<urn:uuid:df9cd38b-0f23-4301-a173-195d2e32521e>", "WARC-Date": "2018-10-16T11:20:53Z", "WARC-IP-Address": "104.28.21.253", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:X2BNHY6SMD2O5OZ4LK5JYFT32BPDYJ4R", "WARC-Record-ID": "<urn:uuid:76a45501-e887-49e5-9039-871d4cc5f8cf>", "WARC-Target-URI": "http://volyanski.com/d-bus-jack/tutorial-d-bus-jack-server-could-not-be-started-ubuntu-12-10.php", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:9d47ba1d-ee94-44b8-aeb4-6f51254fb49f>" }, "warc_info": "isPartOf: CC-MAIN-2018-43\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for October 2018\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-79-252-22.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 0.11-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 72, 73, 125, 126, 446, 447, 755, 756, 1066, 1067, 1326, 1327, 1659, 1660, 1939, 1940, 2261, 2262, 2624, 2625, 2919, 2920, 3224, 3225, 3415, 3416, 3643, 3644, 3949, 3950, 4240, 4241, 4547, 4548, 4817, 4818, 5130, 5131, 5389, 5390, 5595, 5596, 5666, 5667, 5918, 5919, 5987, 5988 ], "line_end_idx": [ 72, 73, 125, 126, 446, 447, 755, 756, 1066, 1067, 1326, 1327, 1659, 1660, 1939, 1940, 2261, 2262, 2624, 2625, 2919, 2920, 3224, 3225, 3415, 3416, 3643, 3644, 3949, 3950, 4240, 4241, 4547, 4548, 4817, 4818, 5130, 5131, 5389, 5390, 5595, 5596, 5666, 5667, 5918, 5919, 5987, 5988, 6166 ] }
{ "red_pajama_v2": { "ccnet_original_length": 6166, "ccnet_original_nlines": 48, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.39897510409355164, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.07101024687290192, "rps_doc_frac_lines_end_with_ellipsis": 0.040816329419612885, "rps_doc_frac_no_alph_words": 0.1676427572965622, "rps_doc_frac_unique_words": 0.4420759975910187, "rps_doc_mean_word_length": 4.453197479248047, "rps_doc_num_sentences": 101, "rps_doc_symbol_to_word_ratio": 0.00366032007150352, "rps_doc_unigram_entropy": 5.577366352081299, "rps_doc_word_count": 1079, "rps_doc_frac_chars_dupe_10grams": 0.021644119173288345, "rps_doc_frac_chars_dupe_5grams": 0.03870968148112297, "rps_doc_frac_chars_dupe_6grams": 0.03870968148112297, "rps_doc_frac_chars_dupe_7grams": 0.03870968148112297, "rps_doc_frac_chars_dupe_8grams": 0.03870968148112297, "rps_doc_frac_chars_dupe_9grams": 0.03870968148112297, "rps_doc_frac_chars_top_2gram": 0.008324660360813141, "rps_doc_frac_chars_top_3gram": 0.0058272602036595345, "rps_doc_frac_chars_top_4gram": 0.007908429950475693, "rps_doc_books_importance": -573.2427978515625, "rps_doc_books_importance_length_correction": -573.2427978515625, "rps_doc_openwebtext_importance": -403.4376525878906, "rps_doc_openwebtext_importance_length_correction": -403.4376525878906, "rps_doc_wikipedia_importance": -287.56048583984375, "rps_doc_wikipedia_importance_length_correction": -287.56048583984375 }, "fasttext": { "dclm": 0.06994497776031494, "english": 0.9507827162742615, "fineweb_edu_approx": 1.170619249343872, "eai_general_math": 0.06882619857788086, "eai_open_web_math": 0.1766374707221985, "eai_web_code": 0.04397064074873924 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.457", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "2", "label": "Partially Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
800,760,127,267,501,000
privdata package v2.1.1+incompatible Latest Latest Warning This package is not in the latest version of its module. Go to latest Published: Jun 1, 2020 License: Apache-2.0 Imports: 41 Imported by: 0 Documentation Index Constants This section is empty. Variables This section is empty. Functions func NewPuller func NewPuller(metrics *metrics.PrivdataMetrics, cs privdata.CollectionStore, g gossip, dataRetriever PrivateDataRetriever, factory CollectionAccessFactory, channel string, btlPullMargin uint64) *puller NewPuller creates new private data puller Types type AppCapabilities added in v1.4.2 type AppCapabilities interface { channelconfig.ApplicationCapabilities } appCapabilities local interface used to generate mock for foreign interface. type CapabilityProvider added in v1.4.3 type CapabilityProvider interface { // Capabilities defines the capabilities for the application portion of this channel Capabilities() channelconfig.ApplicationCapabilities } CapabilityProvider contains functions to retrieve capability information for a channel type CollectionAccessFactory added in v1.2.0 type CollectionAccessFactory interface { // AccessPolicy based on collection configuration AccessPolicy(config *peer.CollectionConfig, chainID string) (privdata.CollectionAccessPolicy, error) } CollectionAccessFactory an interface to generate collection access policy func NewCollectionAccessFactory added in v1.2.0 func NewCollectionAccessFactory(factory IdentityDeserializerFactory) CollectionAccessFactory NewCollectionAccessFactory type CollectionAccessPolicy type CollectionAccessPolicy interface { privdata.CollectionAccessPolicy } type CollectionStore type CollectionStore interface { privdata.CollectionStore } CollectionStore is the local interface used to generate mocks for foreign interface. type Committer type Committer interface { committer.Committer } Committer is the local interface used to generate mocks for foreign interface. type ConfigHistoryRetriever type ConfigHistoryRetriever interface { ledger.ConfigHistoryRetriever } ConfigHistoryRetriever is the local interface used to generate mocks for foreign interface. type Coordinator type Coordinator interface { // StoreBlock deliver new block with underlined private data // returns missing transaction ids StoreBlock(block *common.Block, data util.PvtDataCollections) error // StorePvtData used to persist private data into transient store StorePvtData(txid string, privData *protostransientstore.TxPvtReadWriteSetWithConfigInfo, blckHeight uint64) error // GetPvtDataAndBlockByNum gets block by number and also returns all related private data // that requesting peer is eligible for. // The order of private data in slice of PvtDataCollections doesn't imply the order of // transactions in the block related to these private data, to get the correct placement // need to read TxPvtData.SeqInBlock field GetPvtDataAndBlockByNum(seqNum uint64, peerAuth protoutil.SignedData) (*common.Block, util.PvtDataCollections, error) // Get recent block sequence number LedgerHeight() (uint64, error) // Close coordinator, shuts down coordinator service Close() } Coordinator orchestrates the flow of the new blocks arrival and in flight transient data, responsible to complete missing parts of transient data for given block. func NewCoordinator func NewCoordinator(mspID string, support Support, store *transientstore.Store, selfSignedData protoutil.SignedData, metrics *metrics.PrivdataMetrics, config CoordinatorConfig, idDeserializerFactory IdentityDeserializerFactory) Coordinator NewCoordinator creates a new instance of coordinator type CoordinatorConfig added in v1.4.1 type CoordinatorConfig struct { // TransientBlockRetention indicates the number of blocks to retain in the transient store // when purging below height on commiting every TransientBlockRetention-th block TransientBlockRetention uint64 // PullRetryThreshold indicates the max duration an attempted fetch from a remote peer will retry // for before giving up and leaving the private data as missing PullRetryThreshold time.Duration // SkipPullingInvalidTransactions if true will skip the fetch from remote peer step for transactions // marked as invalid SkipPullingInvalidTransactions bool } CoordinatorConfig encapsulates the config that is passed to a new coordinator type Dig2PvtRWSetWithConfig added in v1.3.0 type Dig2PvtRWSetWithConfig map[privdatacommon.DigKey]*util.PrivateRWSetWithConfig Dig2PvtRWSetWithConfig type Fetcher type Fetcher interface { // contains filtered or unexported methods } Fetcher interface which defines API to fetch missing private data elements type IdentityDeserializerFactory added in v1.2.0 type IdentityDeserializerFactory interface { // GetIdentityDeserializer returns an IdentityDeserializer // instance for the specified chain GetIdentityDeserializer(chainID string) msp.IdentityDeserializer } IdentityDeserializerFactory is a factory interface to create IdentityDeserializer for given channel type IdentityDeserializerFactoryFunc type IdentityDeserializerFactoryFunc func(chainID string) msp.IdentityDeserializer IdentityDeserializerFactoryFunc is a function adapter for IdentityDeserializerFactory. func (IdentityDeserializerFactoryFunc) GetIdentityDeserializer func (i IdentityDeserializerFactoryFunc) GetIdentityDeserializer(chainID string) msp.IdentityDeserializer type ImplicitCollectionDisseminationPolicy type ImplicitCollectionDisseminationPolicy struct { // RequiredPeerCount defines the minimum number of eligible peers to which each endorsing peer must successfully // disseminate private data for its own implicit collection. Default is 0. RequiredPeerCount int // MaxPeerCount defines the maximum number of eligible peers to which each endorsing peer will attempt to // disseminate private data for its own implicit collection. Default is 1. MaxPeerCount int } ImplicitCollectionDisseminationPolicy specifies the dissemination policy for the peer's own implicit collection. It is not applicable to private data for other organizations' implicit collections. type MissingPvtDataTracker type MissingPvtDataTracker interface { ledger.MissingPvtDataTracker } MissingPvtDataTracker is the local interface used to generate mocks for foreign interface. type NoOpReconciler added in v1.3.0 type NoOpReconciler struct { } NoOpReconciler non functional reconciler to be used in case reconciliation has been disabled func (*NoOpReconciler) Start added in v1.3.0 func (*NoOpReconciler) Start() func (*NoOpReconciler) Stop added in v1.3.0 func (*NoOpReconciler) Stop() type PrivateDataRetriever type PrivateDataRetriever interface { // CollectionRWSet returns the bytes of CollectionPvtReadWriteSet for a given txID and collection from the transient store CollectionRWSet(dig []*protosgossip.PvtDataDigest, blockNum uint64) (Dig2PvtRWSetWithConfig, bool, error) } PrivateDataRetriever interface which defines API capable of retrieving required private data type PrivdataConfig type PrivdataConfig struct { // ReconcileSleepInterval determines the time reconciler sleeps from end of an interation until the beginning of the next // reconciliation iteration. ReconcileSleepInterval time.Duration // ReconcileBatchSize determines the maximum batch size of missing private data that will be reconciled in a single iteration. ReconcileBatchSize int // ReconciliationEnabled is a flag that indicates whether private data reconciliation is enabled or not. ReconciliationEnabled bool // ImplicitCollectionDisseminationPolicy specifies the dissemination policy for the peer's own implicit collection. ImplicitCollDisseminationPolicy ImplicitCollectionDisseminationPolicy } PrivdataConfig is the struct that defines the Gossip Privdata configurations. func GlobalConfig func GlobalConfig() *PrivdataConfig GlobalConfig obtains a set of configuration from viper, build and returns the config struct. type PvtDataDistributor type PvtDataDistributor interface { // Distribute broadcast reliably private data read write set based on policies Distribute(txID string, privData *transientstore.TxPvtReadWriteSetWithConfigInfo, blkHt uint64) error } PvtDataDistributor interface to defines API of distributing private data func NewDistributor func NewDistributor(chainID string, gossip gossipAdapter, factory CollectionAccessFactory, metrics *metrics.PrivdataMetrics, pushAckTimeout time.Duration) PvtDataDistributor NewDistributor a constructor for private data distributor capable to send private read write sets for underlying collection type PvtDataReconciler added in v1.4.0 type PvtDataReconciler interface { // Start function start the reconciler based on a scheduler, as was configured in reconciler creation Start() // Stop function stops reconciler Stop() } PvtDataReconciler completes missing parts of private data that weren't available during commit time. this is done by getting from the ledger a list of missing private data and pulling it from the other peers. type PvtdataProvider type PvtdataProvider struct { // contains filtered or unexported fields } func (*PvtdataProvider) RetrievePvtdata func (pdp *PvtdataProvider) RetrievePvtdata(pvtdataToRetrieve []*ledger.TxPvtdataInfo) (*RetrievedPvtdata, error) RetrievePvtdata is passed a list of private data items from a block, it determines which private data items this peer is eligible for, and then retrieves the private data from local cache, local transient store, or a remote peer. type RWSetScanner type RWSetScanner interface { transientstore.RWSetScanner } RWSetScanner is the local interface used to generate mocks for foreign interface. type Reconciler added in v1.3.0 type Reconciler struct { ReconcileSleepInterval time.Duration ReconcileBatchSize int ReconciliationFetcher committer.Committer // contains filtered or unexported fields } func NewReconciler added in v1.3.0 func NewReconciler(channel string, metrics *metrics.PrivdataMetrics, c committer.Committer, fetcher ReconciliationFetcher, config *PrivdataConfig) *Reconciler NewReconciler creates a new instance of reconciler func (*Reconciler) Start added in v1.3.0 func (r *Reconciler) Start() func (*Reconciler) Stop added in v1.3.0 func (r *Reconciler) Stop() type ReconciliationFetcher added in v1.3.0 type ReconciliationFetcher interface { FetchReconciledItems(dig2collectionConfig privdatacommon.Dig2CollectionConfig) (*privdatacommon.FetchedPvtDataContainer, error) } ReconciliationFetcher interface which defines API to fetch private data elements that have to be reconciled. type RetrievedPvtdata type RetrievedPvtdata struct { // contains filtered or unexported fields } func (*RetrievedPvtdata) GetBlockPvtdata func (r *RetrievedPvtdata) GetBlockPvtdata() *ledger.BlockPvtdata GetBlockPvtdata returns the BlockPvtdata func (*RetrievedPvtdata) Purge func (r *RetrievedPvtdata) Purge() Purge purges private data for transactions in the block from the transient store. Transactions older than the retention period are considered orphaned and also purged. type StorageDataRetriever type StorageDataRetriever interface { // CollectionRWSet retrieves for give digest relevant private data if // available otherwise returns nil, bool which is true if data fetched from ledger and false if was fetched from transient store, and an error CollectionRWSet(dig []*protosgossip.PvtDataDigest, blockNum uint64) (Dig2PvtRWSetWithConfig, bool, error) } StorageDataRetriever defines an API to retrieve private date from the storage. func NewDataRetriever func NewDataRetriever(store *transientstore.Store, committer committer.Committer) StorageDataRetriever NewDataRetriever constructing function for implementation of the StorageDataRetriever interface type Support Support encapsulates set of interfaces to aggregate required functionality by single struct Directories Path Synopsis Code generated by counterfeiter. Code generated by counterfeiter. Jump to Keyboard shortcuts ? : This menu / : Search site f or F : Jump to y or Y : Canonical URL
{ "url": "https://beta.pkg.go.dev/gitee.com/zhuanglicheng/fabric@v2.1.1+incompatible/gossip/privdata", "source_domain": "beta.pkg.go.dev", "snapshot_id": "CC-MAIN-2024-38", "warc_metadata": { "Content-Length": "115378", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:EEH5EQV4QUMICYXZY6LBSHNMBWRQ2JGT", "WARC-Concurrent-To": "<urn:uuid:8984e52f-4ffb-48ec-92f0-985d3859df81>", "WARC-Date": "2024-09-19T17:16:37Z", "WARC-IP-Address": "34.117.180.159", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:NVRLOGEPTF3HXY5JDQYDWW7BC3QOUGZW", "WARC-Record-ID": "<urn:uuid:f4498cb7-c05d-455b-ad2b-f26981714a7f>", "WARC-Target-URI": "https://beta.pkg.go.dev/gitee.com/zhuanglicheng/fabric@v2.1.1+incompatible/gossip/privdata", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:8c1b93ee-c5f5-47e8-ab3d-8452d1b2c5ab>" }, "warc_info": "isPartOf: CC-MAIN-2024-38\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-88\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 9, 10, 18, 52, 60, 61, 118, 119, 132, 202, 203, 217, 218, 224, 225, 235, 236, 259, 260, 270, 271, 294, 295, 305, 306, 321, 322, 410, 526, 527, 569, 570, 576, 577, 614, 615, 648, 687, 689, 690, 767, 768, 808, 809, 845, 931, 985, 987, 988, 1075, 1076, 1121, 1122, 1163, 1214, 1316, 1318, 1319, 1393, 1394, 1442, 1443, 1536, 1537, 1564, 1565, 1593, 1594, 1634, 1667, 1669, 1670, 1691, 1692, 1725, 1751, 1753, 1754, 1839, 1840, 1855, 1856, 1883, 1904, 1906, 1907, 1986, 1987, 2015, 2016, 2056, 2087, 2089, 2090, 2182, 2183, 2200, 2201, 2230, 2292, 2328, 2397, 2398, 2465, 2581, 2582, 2673, 2715, 2803, 2893, 2937, 3056, 3057, 3094, 3126, 3127, 3181, 3190, 3192, 3193, 3356, 3357, 3377, 3378, 3529, 3619, 3620, 3673, 3674, 3713, 3714, 3746, 3838, 3920, 3952, 4051, 4116, 4150, 4252, 4274, 4311, 4313, 4314, 4392, 4393, 4437, 4438, 4521, 4522, 4545, 4546, 4559, 4560, 4585, 4629, 4631, 4632, 4707, 4708, 4757, 4758, 4803, 4863, 4900, 4966, 4968, 4969, 5069, 5070, 5107, 5108, 5191, 5192, 5279, 5280, 5343, 5344, 5450, 5451, 5494, 5495, 5547, 5661, 5737, 5760, 5867, 5943, 5961, 5963, 5964, 6161, 6162, 6189, 6190, 6229, 6259, 6261, 6262, 6353, 6354, 6390, 6391, 6420, 6422, 6423, 6516, 6517, 6562, 6563, 6594, 6595, 6639, 6640, 6670, 6671, 6697, 6698, 6736, 6860, 6967, 6969, 6970, 7063, 7064, 7084, 7085, 7114, 7237, 7267, 7305, 7433, 7457, 7563, 7591, 7709, 7780, 7782, 7783, 7861, 7862, 7880, 7881, 7917, 7918, 8011, 8012, 8036, 8037, 8073, 8153, 8256, 8258, 8259, 8332, 8333, 8353, 8354, 8445, 8529, 8530, 8654, 8655, 8694, 8695, 8730, 8833, 8842, 8877, 8885, 8887, 8888, 9097, 9098, 9119, 9120, 9150, 9193, 9195, 9196, 9236, 9237, 9351, 9352, 9582, 9583, 9601, 9602, 9632, 9661, 9663, 9664, 9746, 9747, 9779, 9780, 9805, 9843, 9871, 9872, 9895, 9916, 9959, 9961, 9962, 9997, 9998, 10090, 10158, 10159, 10210, 10211, 10252, 10253, 10282, 10283, 10323, 10324, 10352, 10353, 10396, 10397, 10436, 10565, 10567, 10568, 10677, 10678, 10700, 10701, 10732, 10775, 10777, 10778, 10819, 10820, 10886, 10887, 10928, 10929, 10960, 10961, 10996, 10997, 11165, 11166, 11192, 11193, 11231, 11302, 11446, 11553, 11555, 11556, 11635, 11636, 11658, 11659, 11762, 11763, 11859, 11860, 11873, 11874, 11966, 11967, 11979, 11980, 11994, 12027, 12060, 12061, 12069, 12070, 12089, 12090, 12104, 12120, 12137 ], "line_end_idx": [ 9, 10, 18, 52, 60, 61, 118, 119, 132, 202, 203, 217, 218, 224, 225, 235, 236, 259, 260, 270, 271, 294, 295, 305, 306, 321, 322, 410, 526, 527, 569, 570, 576, 577, 614, 615, 648, 687, 689, 690, 767, 768, 808, 809, 845, 931, 985, 987, 988, 1075, 1076, 1121, 1122, 1163, 1214, 1316, 1318, 1319, 1393, 1394, 1442, 1443, 1536, 1537, 1564, 1565, 1593, 1594, 1634, 1667, 1669, 1670, 1691, 1692, 1725, 1751, 1753, 1754, 1839, 1840, 1855, 1856, 1883, 1904, 1906, 1907, 1986, 1987, 2015, 2016, 2056, 2087, 2089, 2090, 2182, 2183, 2200, 2201, 2230, 2292, 2328, 2397, 2398, 2465, 2581, 2582, 2673, 2715, 2803, 2893, 2937, 3056, 3057, 3094, 3126, 3127, 3181, 3190, 3192, 3193, 3356, 3357, 3377, 3378, 3529, 3619, 3620, 3673, 3674, 3713, 3714, 3746, 3838, 3920, 3952, 4051, 4116, 4150, 4252, 4274, 4311, 4313, 4314, 4392, 4393, 4437, 4438, 4521, 4522, 4545, 4546, 4559, 4560, 4585, 4629, 4631, 4632, 4707, 4708, 4757, 4758, 4803, 4863, 4900, 4966, 4968, 4969, 5069, 5070, 5107, 5108, 5191, 5192, 5279, 5280, 5343, 5344, 5450, 5451, 5494, 5495, 5547, 5661, 5737, 5760, 5867, 5943, 5961, 5963, 5964, 6161, 6162, 6189, 6190, 6229, 6259, 6261, 6262, 6353, 6354, 6390, 6391, 6420, 6422, 6423, 6516, 6517, 6562, 6563, 6594, 6595, 6639, 6640, 6670, 6671, 6697, 6698, 6736, 6860, 6967, 6969, 6970, 7063, 7064, 7084, 7085, 7114, 7237, 7267, 7305, 7433, 7457, 7563, 7591, 7709, 7780, 7782, 7783, 7861, 7862, 7880, 7881, 7917, 7918, 8011, 8012, 8036, 8037, 8073, 8153, 8256, 8258, 8259, 8332, 8333, 8353, 8354, 8445, 8529, 8530, 8654, 8655, 8694, 8695, 8730, 8833, 8842, 8877, 8885, 8887, 8888, 9097, 9098, 9119, 9120, 9150, 9193, 9195, 9196, 9236, 9237, 9351, 9352, 9582, 9583, 9601, 9602, 9632, 9661, 9663, 9664, 9746, 9747, 9779, 9780, 9805, 9843, 9871, 9872, 9895, 9916, 9959, 9961, 9962, 9997, 9998, 10090, 10158, 10159, 10210, 10211, 10252, 10253, 10282, 10283, 10323, 10324, 10352, 10353, 10396, 10397, 10436, 10565, 10567, 10568, 10677, 10678, 10700, 10701, 10732, 10775, 10777, 10778, 10819, 10820, 10886, 10887, 10928, 10929, 10960, 10961, 10996, 10997, 11165, 11166, 11192, 11193, 11231, 11302, 11446, 11553, 11555, 11556, 11635, 11636, 11658, 11659, 11762, 11763, 11859, 11860, 11873, 11874, 11966, 11967, 11979, 11980, 11994, 12027, 12060, 12061, 12069, 12070, 12089, 12090, 12104, 12120, 12137, 12159 ] }
{ "red_pajama_v2": { "ccnet_original_length": 12159, "ccnet_original_nlines": 378, "rps_doc_curly_bracket": 0.00394769012928009, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.20055866241455078, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.004469269886612892, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.2402234673500061, "rps_doc_frac_unique_words": 0.32098764181137085, "rps_doc_mean_word_length": 7.788580417633057, "rps_doc_num_sentences": 114, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.3566155433654785, "rps_doc_word_count": 1296, "rps_doc_frac_chars_dupe_10grams": 0.06152170151472092, "rps_doc_frac_chars_dupe_5grams": 0.12611451745033264, "rps_doc_frac_chars_dupe_6grams": 0.1116504892706871, "rps_doc_frac_chars_dupe_7grams": 0.09659203141927719, "rps_doc_frac_chars_dupe_8grams": 0.07043787837028503, "rps_doc_frac_chars_dupe_9grams": 0.07043787837028503, "rps_doc_frac_chars_top_2gram": 0.02724391035735607, "rps_doc_frac_chars_top_3gram": 0.009807810187339783, "rps_doc_frac_chars_top_4gram": 0.011888249777257442, "rps_doc_books_importance": -764.508544921875, "rps_doc_books_importance_length_correction": -764.508544921875, "rps_doc_openwebtext_importance": -475.3103942871094, "rps_doc_openwebtext_importance_length_correction": -475.3103942871094, "rps_doc_wikipedia_importance": -436.02130126953125, "rps_doc_wikipedia_importance_length_correction": -436.02130126953125 }, "fasttext": { "dclm": 0.04606949910521507, "english": 0.5659220218658447, "fineweb_edu_approx": 2.387629747390747, "eai_general_math": 0.21704041957855225, "eai_open_web_math": 0.007274929899722338, "eai_web_code": 0.8689513802528381 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "5", "label": "Exceptionally Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
6,447,285,049,906,358,000
ARCore is back at Google I/O on May 10! Register now. Augmented Faces introduction Stay organized with collections Save and categorize content based on your preferences. Platform-specific guides The Augmented Faces API allows you to render assets on top of human faces without using specialized hardware. It provides feature points that enable your app to automatically identify different regions of a detected face. Your app can then use those regions to overlay assets in a way that properly matches the contours of an individual face. Use cases Face-based AR unlocks a wide array of use cases, from beauty and accessory try-ons to facial filters and effects that users can enjoy with their friends. For example, use 3D models and a texture to overlay the features of a fox onto a user's face. The model consists of two fox ears and a fox nose. Each is a separate bone that can be moved individually to follow the facial region they are attached to. The texture consists of eye shadow, freckles, and other coloring. During runtime, the Augmented Faces API detects a user’s face and overlays both the texture and the models onto it. Parts of an Augmented Face The Augmented Faces API provides a center pose, three region poses, and a 3D face mesh. Center pose Located behind the nose, the center pose marks the middle of a user’s head. Use it to render assets such as a hat on top of the head. Region poses Located on the left forehead, right forehead, and tip of the nose, region poses mark important parts of a user’s face. Use them to render assets on the nose or around the ears. Face mesh The 468-point dense 3D face mesh allows you to paint adaptable, detailed textures that accurately follow a face — for example, when layering virtual glasses behind a specific part of the nose. The mesh gathers enough detailed 3D information that you can easily render this virtual image.
{ "url": "https://developers-dot-devsite-v2-prod.appspot.com/ar/develop/augmented-faces", "source_domain": "developers-dot-devsite-v2-prod.appspot.com", "snapshot_id": "CC-MAIN-2023-14", "warc_metadata": { "Content-Length": "165382", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:SGLH4BZBSFFHV7MCVYV4K6WM6EJTECDD", "WARC-Concurrent-To": "<urn:uuid:5cfb3b48-0e72-4880-9b14-84f6df456054>", "WARC-Date": "2023-04-01T01:53:27Z", "WARC-IP-Address": "172.253.115.153", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:A7ZFD7NVD52DMFYRD3243NDPQ2CKEPKJ", "WARC-Record-ID": "<urn:uuid:72d6aef2-8bc0-44cb-b4a4-2677318f2256>", "WARC-Target-URI": "https://developers-dot-devsite-v2-prod.appspot.com/ar/develop/augmented-faces", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:6f190d59-cceb-4266-b2b1-34a673a3a13d>" }, "warc_info": "isPartOf: CC-MAIN-2023-14\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for March/April 2023\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-59\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 54, 55, 84, 85, 172, 173, 198, 199, 542, 543, 553, 554, 802, 803, 959, 960, 1026, 1027, 1143, 1144, 1171, 1172, 1260, 1261, 1273, 1274, 1408, 1409, 1422, 1423, 1600, 1601, 1611, 1612 ], "line_end_idx": [ 54, 55, 84, 85, 172, 173, 198, 199, 542, 543, 553, 554, 802, 803, 959, 960, 1026, 1027, 1143, 1144, 1171, 1172, 1260, 1261, 1273, 1274, 1408, 1409, 1422, 1423, 1600, 1601, 1611, 1612, 1899 ] }
{ "red_pajama_v2": { "ccnet_original_length": 1899, "ccnet_original_nlines": 34, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3687002658843994, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.02652519941329956, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.11671087890863419, "rps_doc_frac_unique_words": 0.49541282653808594, "rps_doc_mean_word_length": 4.642201900482178, "rps_doc_num_sentences": 19, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.660343647003174, "rps_doc_word_count": 327, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.03689064830541611, "rps_doc_frac_chars_top_3gram": 0.033596839755773544, "rps_doc_frac_chars_top_4gram": 0.03952569141983986, "rps_doc_books_importance": -160.11734008789062, "rps_doc_books_importance_length_correction": -160.1170654296875, "rps_doc_openwebtext_importance": -99.49596405029297, "rps_doc_openwebtext_importance_length_correction": -99.49596405029297, "rps_doc_wikipedia_importance": -95.05033874511719, "rps_doc_wikipedia_importance_length_correction": -95.05033874511719 }, "fasttext": { "dclm": 0.20727908611297607, "english": 0.8927290439605713, "fineweb_edu_approx": 2.535456418991089, "eai_general_math": 0.05727678909897804, "eai_open_web_math": 0.05528140068054199, "eai_web_code": 0.4855039119720459 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.0285", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "006.6", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Cognitive science" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "4", "label": "Missing Images or Figures" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "17", "label": "Product Page" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-4,394,326,342,866,837,000
Informix is an SQL-based object-relational, OLTP/OLAP, NoSQL DBMS produced by IBM. This tag is appropriate for questions about any of the products with Informix in the product name. learn more… | top users | synonyms 13 votes 1answer 5k views Why does NOT IN with a set containing NULL always return FALSE/NULL? I had a query (for Postgres and Informix) with a NOT IN clause containing a subquery that in some cases returned NULL values, causing that clause (and the entire query) to fail to return anything. ... 2 votes 4answers 1k views How to join the latest previous record with SQL The original question was posted on stackoverflow. I think this site could be more focused on db related topic. I have a table whose schema is like this: CREATE TABLE product_shipping( ...
{ "url": "http://dba.stackexchange.com/questions/tagged/informix?sort=faq&pagesize=15", "source_domain": "dba.stackexchange.com", "snapshot_id": "crawl=CC-MAIN-2016-18", "warc_metadata": { "Content-Length": "50985", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:2I6TIG27F5ZHLB7ZDSYXTJPTLFX77XO6", "WARC-Concurrent-To": "<urn:uuid:4c11d2bf-d138-488e-9201-847728ca413b>", "WARC-Date": "2016-05-04T23:11:02Z", "WARC-IP-Address": "104.16.115.182", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:V3BQNMJTKOLPDEY4PE6HDRKIERV44W7X", "WARC-Record-ID": "<urn:uuid:745e8cbf-f450-4389-a414-1077fcc71bb2>", "WARC-Target-URI": "http://dba.stackexchange.com/questions/tagged/informix?sort=faq&pagesize=15", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:20a67ad0-c32d-47fd-91e5-0ca8700d4b96>" }, "warc_info": "robots: classic\r\nhostname: ip-10-239-7-51.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-18\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for April 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 182, 183, 218, 219, 222, 228, 236, 245, 246, 315, 316, 517, 519, 525, 534, 543, 544, 592, 593 ], "line_end_idx": [ 182, 183, 218, 219, 222, 228, 236, 245, 246, 315, 316, 517, 519, 525, 534, 543, 544, 592, 593, 781 ] }
{ "red_pajama_v2": { "ccnet_original_length": 781, "ccnet_original_nlines": 19, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3417721390724182, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.12025316059589386, "rps_doc_frac_lines_end_with_ellipsis": 0.10000000149011612, "rps_doc_frac_no_alph_words": 0.16455696523189545, "rps_doc_frac_unique_words": 0.7153846025466919, "rps_doc_mean_word_length": 4.723076820373535, "rps_doc_num_sentences": 7, "rps_doc_symbol_to_word_ratio": 0.018987340852618217, "rps_doc_unigram_entropy": 4.393028736114502, "rps_doc_word_count": 130, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.016286639496684074, "rps_doc_frac_chars_top_3gram": 0, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -74.457275390625, "rps_doc_books_importance_length_correction": -74.457275390625, "rps_doc_openwebtext_importance": -41.388450622558594, "rps_doc_openwebtext_importance_length_correction": -41.38843536376953, "rps_doc_wikipedia_importance": -43.46843719482422, "rps_doc_wikipedia_importance_length_correction": -43.46843719482422 }, "fasttext": { "dclm": 0.09436213970184326, "english": 0.9285531044006348, "fineweb_edu_approx": 0.8613261580467224, "eai_general_math": 0.0035350299440324306, "eai_open_web_math": 0.11991012096405029, "eai_web_code": 0.0028756901156157255 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.74", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "6", "label": "Not Applicable/Indeterminate" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-9,005,732,927,920,819,000
Random Without Replacement in a BP In the previous post we looked at how we can play back sounds from random locations as a way of improving the general ambience within an area. This post will look at a way we can improve things further by allowing us to do ‘random without replacement’ so that the random locations chosen for playback aren’t repeated. This functionality already exists within SoundCues using the Random node. Unfortunately, there is no standard node for doing this in a BP – so we’re going to have to build it ourselves… The resulting system is a little large, in terms of BP nodes, so I’m going to create a new Macro and build within there – this will help to keep my BPs tidy and easily ‘readable’, it will also mean the new functionality can be reused across projects easily. We will cover the creation of the random without replacement macro, but you can download the macro here if you want. You can create a new macro directly from within a BP using the Add Macro option. However, this macro would then only be accessible within that BP. If you want to create a macro that you can use across your project, and even share with other projects then you need to create a Macro Library within the Content Browser. Use the Add New – Blueprints – Blueprint Macro Library option. You’ll then be asked to choose the ‘Parent Class’ for your macro – the advice from Epic is to use ‘Actor’ as this will enable you to do more in terms of accessing variables and functions. Give your new macro library asset a name, and then open it for editing. The first step is define the inputs and outputs of your macro. Select the Inputs node, and in the Details window create the following Inputs and Outputs: The Exec In triggers the macro’s functionality. The Input Array is the set of items that we want to randomly choose from. We’re using the Wildcard variable type so that the macro isn’t tied to a specific type of asset – the wildcard type changes to match whatever is connected to it. The Rand Without Replace boolean will allow us to choose whether we want to turn the ‘without replacement’ functionality on or off. The Exec Out is triggered after the macro has completed it’s task. The Array Item output passes the randomly selected item. The first step is generate a random number: We get the Length of the input array, subtract ‘1’ from it (like we did in the previous blog post) and then use this to set the maximum of our random range – remember, array items are indexed starting with a value ‘0’, so the possible range needs to be 1 less than the length. We’re using a Local Integer to store this random value, so that we can use it further down the chain. Next we need to check the status of our ‘Rand Without Replace’ boolean: And then set up what will happen for each state. If the bool is set to ‘False’, it’s pretty simple – just use the randomly generated value to Get the appropriate item from the Input Array and pass it to the Output: The system for ‘True’ is a bit more complex, so we’ll build it in stages… First, create this: We’ve create a Local Array of Integers to store the randomly generated value, and we check this array to see if it Contains the current random value already, if it does we simply generate another random value and check again (the Reroute node is useful when you want to loop back on yourself, or to help keep connections readable). If the random value is not present within the local array then we Add it for the next pass through. Now extend to this: We need to know when we’ve generated every possible value so that we can reset our system and go back through the whole Input Array again. So we compare the Length of the local array with that of the Input Array and if they are equal to each other (==) then we Clear the local array to empty it and start again. If the two lengths are not equal then there are still some values left and we can go straight to the output. At the output (like we did earlier) we simply Get the item from the Input Array and pass it out. Now you can Save your macro, and access it from any BP within your project. Here I’ve incorporated the macro into the random sound location system from the previous blog post. By passing it out array of sound playback locations we can randomly select one every time we call the function but be sure that we won’t get any repetition of locations until the array has been exhausted. Next time, we’ll look at a way of extending our random system further by incorporating the option to determine random weightings for each item in the input array… Advertisements So, you want to spawn a sound at random locations..? Spawning sounds at random locations is a useful technique (especially when combined with random variations within the sounds themselves) as it can help reduce any sense of repetition and help to bring an environment to life. This is the first of a short series of posts that deal with this topic and will cover a few of the techniques involved, starting with the ability to randomly choose locations As with any technique, there are multiple ways of achieving the same thing… You could do this: But then you’d have to set up a system to define your x/y/z min/max values to appropriate ranges so that the sounds played back within the correct area of your level. A better way might be this, as you can define specific locations by placing actors at the various points within your area: Or this, using AmbientSound actors placed within the level: Either approach produces the same end result, but it depends whether you want to have your sounds appear to come from specific actors within your level or from ‘unseen’ empty AmbientSound actors that you’ve placed appropriately. These methods work fine, and there are probably more variations on this theme, but the problem comes if you want to add more possible locations within your level. You’d have to modify your BP to accommodate these changes by adding in more actor references, and extending the Select node. Instead we can make our controlling Blueprint dynamically find all of our locations and store them in an array. We can then use a similar method, as illustrated above, to generate random numbers and select from the contents of the array – if we’re cunning about how we do this, we only need to build one system and we can add/remove locations as much we want without having to make any changes. Firstly we need to ‘find’ all of our locations. The Get All Actors Of Class does exactly what you would expect – it finds all of the actors within a level of a specified class and generates an array containing all found references. You can use whatever type of actor you want for your sound locations (as discussed above), but for this method it does make a bit of sense to create your own custom actor class so that you can be sure that the Get All node only finds those actors you specifically want to use as location markers. Creating your own actor class is pretty simple – within your Content Browser, use Add New – Blueprint Class. Then you can choose to base your custom actor off any class you like – I’ve chosen to use AmbientSound as this means I could use it’s available functionality to change how the sound is played in the future if I want. Once you’ve got your Get All node configured, you can easily create a variable to store your generated array, by right clicking the ‘Out Actors’ outlet and selecting ‘Promote to Variable’. It would be useful to know how many actors are stored within the array – so that we can generate an appropriate random number, so we use the Length node and create an int variable to store the output. Because the BP finds all of the specific actors within our level, and creates the array for us, we can add and remove actors and not have to worry about modifying the BP – which is nice! The next step is to create the system that will select one of the locations at random and then play the sound from that location. We subtract ‘1’ from the length of the array, and use this as the maximum of our random integer range, as the references within the array are stored at indices that start at ‘0’. So the first slot is ‘0’, the second is ‘1’, and so on… We then use the Get node to access the reference stored at our random index and store that as a variable – we do this to ensure that any future use of this randomly generated reference remains consistent (if we just used the output of the Get node, then the Set Sound node would produce one random reference, and the Play node would produce another – they will likely be different!). We then simply set the sound to be played by the actor and start it playing. If at this point, you’ve been building and are testing your system, you may well notice that sometimes a currently playing sound location is retriggered – this is the beauty of ‘random’; the same thing can happen twice in a row (or more…). Ideally we would check to see if the randomly chosen location is playing, and if so generate another random number and try again. This is pretty simple: We can use the IsPlaying variable from the Audio Component to control a Branch node (this is one of the reasons I chose to base my custom actor off the AmbientSound class). If the randomly chosen location is not currently playing (ie. False) then we set and play the sound. If the chosen location is playing (ie. True) we just call the PlaySound function again and restart the system. That’s the basics of playing back sounds at random locations. There will likely be other ways, this is just the way I’ve found works for me. There are a number of improvements we could make to the system, the biggest one being the ability to generate random numbers without repetition (similarly to how the Random node within a SoundCue works), so the next blog post will deal with that. OSC Utility So recently I’ve been working with some colleagues to produce some utilities for UE4 to create an electro-acoustic composition – there’ll more details about these in the near future… But suffice to say they involved spatialization of sounds, movement following pre-defined patterns and some serialism stuff. As well as the various methods of playing back soundfiles, we also needed real time control / triggering of sounds using OSC data so that the project could be controlled by two performers using iPads. We used the excellent OSC Plugin created by Monsieurgustav and available here, and while it does work well and is easy to setup it didn’t quite offer the functionality that we needed – Namely the ability to save the OSC addresses used as control data, recall these between sessions and set up easily managed routing of the different incoming OSC data within the project. So, I built something that did… I produced a BP actor that can be dropped into the level and will sit there receiving any incoming OSC data and parsing it according to some user defined settings so that individual addresses can be used to control functions within the project. The saving and recalling of OSC addresses was relatively simple and made use of the SaveGame class to create a data file that the OSC addresses could be written to (this is saved within the ‘Saved’ folder of your project). This is handled using the [Event BeginPlay] to check for an existing data file (one is created if not already in existence) and any saved data is recalled and stored in a temporary variable. sshot-1 I added an OscReceiver component (part of the OSC plugin) to the BP actor so that it could receive OSC data. sshot-3 If the actor is set to ‘Learn’ mode then the address of any incoming OSC data is stored in an array and saved – the addresses are checked against the contents of the array to ensure that there no repetitions. sshot-4 If the actor is not set to ‘Learn’ mode then incoming OSC data causes an event dispatcher to be called so that the OSC data can be received in any BP within the project (eg. Level BP). You can easily control systems within the project using individual OSC adresses through the use of a [Switch on Int] node – you can use the index of the current OSC address within the wider array of stored OSC addresses to control the [Switch on Int] node. sshot-5 I’ve made the OSC Utility available here along with a copy of the OSC plugin, a demo project which illustrates how the actor functions and a .pdf detailing the systems in use. 3rd Person Camera – Audio Listener Position When you create a 3rd person game in UE4, the Audio Listener is set by default to the position of the camera, which works fine for some scenarios but not for others. It can cause problems depending on the position of the camera relative to the player character (eg. hearing things that the character cannot actually see). I was asked about this by one of our Masters students who needed to be able to set the position of the Audio Listener to somewhere in-between the camera and the player character in order to solve just this kind of problem. This is my solution – it does not need to be in a separate BP, but by doing so it makes it easy to distribute and means it can simply by dropped into a project. Within the BP, the Audio Listener is set to the position of the actor, which in turn has it’s position constantly updated so that it is always relative to both the player character and the player camera. sshot-1 On every frame update the location of the player camera and character are obtained as well as the forward vector of the camera and it’s rotation. These positions are used to calculate the position of the actor. The forward vector of the camera tells us the direction the camera is facing. The distance between the player camera and the character is obtained and is scaled by a user-definable variable to determine how far along a line between the camera and character the actor should be placed. This value is then used to scale the forward vector of the camera to move the actor along the axis of the camera towards the player character. Finally I added in a [VInterp To] node to apply some level of interpolation on the actor’s location so that there is some degree of ‘inertia’ on the listener position’s movements – this smooths out any jumpy movements introduced by the camera. The actor’s properties allow you to set: –  The Listener Distance (where 0 = at the position of the player character, and 1 = at the position of the player camera) – The Interp Speed (where 100 = very fast movement / no inertia, and 1 = very slow movement / high degree of inertia) sshot-2 You can toggle the actor’s Hidden in Game state using the L key (obviously you can change this key event if you wish) so that you can visualize the listener position if needs be. The actor can be downloaded from here: click me If you find this useful and have any thoughts / suggestions / ideas for developing it further so that it can be of more use, I’d be interesting in hearing from you…   Visualising LPF Radii So, this idea came about after a question on gameaudio.slack about whether there was a console command to enable debugging of LPF radii similar to that for volume attenuation radii using the ‘stat sounds -debug’ command. Unfortunately there isn’t! But, it got me thinking… it can’t be that hard to knock up a quick and dirty solution… turns out it isn’t! So I thought I’d make the solution available in case anyone else finds it useful. I created a placeable actor, using BluePrints, that can dropped into a map and then when a specific key is pressed it draws the LPF min and max radii for every AmbientSound within the level. Here’s a screenshot of it doing it’s stuff ingame: visualise_lpf_radii_ingame_sshot The actual BP system is pretty simple… When the key is pressed an array containing all of the AmbientSounds within the level is created. This is then looped through, and for each actor within the array the actor location, LPF radius min and LPF radius max are obtained. These values are then used to draw some debug spheres within the world. Here’s a screenshot of the actor BP: visualise_lpf_radii_actorbp_sshot (The connection to the input of the [Get All Actors of Class] node is coming from a keypress event – it wouldn’t fit on the screen!) As you can see, this is a very simple system! Obviously this could just as easily be done within the Level BP, but making an actor made it easy to distribute the solution. The actor can be downloaded from here: click me If you find this useful and have any thoughts / suggestions / ideas for developing it further so that it can be of more use, I’d be interesting in hearing from you…
{ "url": "https://teedstuff.wordpress.com/category/ue4/", "source_domain": "teedstuff.wordpress.com", "snapshot_id": "crawl=CC-MAIN-2019-43", "warc_metadata": { "Content-Length": "74360", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:E5QM4VVM4X3A3ZSISECD4C6ONAF6H5W6", "WARC-Concurrent-To": "<urn:uuid:de9f9d2f-310b-46a1-9dfa-c5aaa9cebb16>", "WARC-Date": "2019-10-15T03:54:41Z", "WARC-IP-Address": "192.0.78.13", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:PCY2CVOXSZIZGWUPXIPNWGVAXTXJKLSO", "WARC-Record-ID": "<urn:uuid:02999589-124d-4fb3-b3ce-d6dd9da6dba5>", "WARC-Target-URI": "https://teedstuff.wordpress.com/category/ue4/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:417368c8-3da8-46f1-be09-85b5923b735b>" }, "warc_info": "isPartOf: CC-MAIN-2019-43\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for October 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-242.ec2.internal\r\nsoftware: Apache Nutch 1.16 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 35, 36, 179, 428, 429, 541, 542, 800, 917, 918, 999, 1000, 1300, 1301, 1489, 1561, 1562, 1716, 1717, 1765, 2001, 2133, 2200, 2257, 2258, 2302, 2303, 2580, 2682, 2754, 2755, 2804, 2970, 2971, 3045, 3065, 3066, 3498, 3518, 3519, 4037, 4038, 4114, 4115, 4215, 4216, 4421, 4422, 4585, 4586, 4601, 4602, 4655, 4656, 5056, 5057, 5152, 5153, 5320, 5321, 5444, 5445, 5505, 5506, 5735, 5736, 6024, 6025, 6420, 6421, 6469, 6470, 6951, 6952, 7061, 7062, 7279, 7280, 7670, 7671, 7858, 7859, 7989, 7990, 8225, 8226, 8610, 8611, 8688, 8689, 9059, 9060, 9083, 9084, 9469, 9470, 9611, 9612, 9859, 9860, 9872, 9873, 10181, 10182, 10754, 10755, 10787, 10788, 11033, 11034, 11448, 11449, 11457, 11458, 11567, 11568, 11576, 11577, 11786, 11787, 11795, 11796, 11981, 11982, 12239, 12240, 12248, 12249, 12425, 12426, 12470, 12471, 12793, 13016, 13017, 13178, 13179, 13383, 13384, 13392, 13393, 13604, 13605, 13683, 13890, 14033, 14034, 14278, 14279, 14320, 14443, 14561, 14562, 14570, 14571, 14750, 14751, 14799, 14800, 14965, 14966, 14968, 14969, 14991, 14992, 15213, 15240, 15241, 15328, 15430, 15431, 15622, 15673, 15674, 15707, 15708, 15747, 16050, 16087, 16088, 16122, 16255, 16256, 16302, 16303, 16429, 16430, 16478, 16479 ], "line_end_idx": [ 35, 36, 179, 428, 429, 541, 542, 800, 917, 918, 999, 1000, 1300, 1301, 1489, 1561, 1562, 1716, 1717, 1765, 2001, 2133, 2200, 2257, 2258, 2302, 2303, 2580, 2682, 2754, 2755, 2804, 2970, 2971, 3045, 3065, 3066, 3498, 3518, 3519, 4037, 4038, 4114, 4115, 4215, 4216, 4421, 4422, 4585, 4586, 4601, 4602, 4655, 4656, 5056, 5057, 5152, 5153, 5320, 5321, 5444, 5445, 5505, 5506, 5735, 5736, 6024, 6025, 6420, 6421, 6469, 6470, 6951, 6952, 7061, 7062, 7279, 7280, 7670, 7671, 7858, 7859, 7989, 7990, 8225, 8226, 8610, 8611, 8688, 8689, 9059, 9060, 9083, 9084, 9469, 9470, 9611, 9612, 9859, 9860, 9872, 9873, 10181, 10182, 10754, 10755, 10787, 10788, 11033, 11034, 11448, 11449, 11457, 11458, 11567, 11568, 11576, 11577, 11786, 11787, 11795, 11796, 11981, 11982, 12239, 12240, 12248, 12249, 12425, 12426, 12470, 12471, 12793, 13016, 13017, 13178, 13179, 13383, 13384, 13392, 13393, 13604, 13605, 13683, 13890, 14033, 14034, 14278, 14279, 14320, 14443, 14561, 14562, 14570, 14571, 14750, 14751, 14799, 14800, 14965, 14966, 14968, 14969, 14991, 14992, 15213, 15240, 15241, 15328, 15430, 15431, 15622, 15673, 15674, 15707, 15708, 15747, 16050, 16087, 16088, 16122, 16255, 16256, 16302, 16303, 16429, 16430, 16478, 16479, 16643 ] }
{ "red_pajama_v2": { "ccnet_original_length": 16643, "ccnet_original_nlines": 189, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.49031689763069153, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.018779339268803596, "rps_doc_frac_lines_end_with_ellipsis": 0.04736841842532158, "rps_doc_frac_no_alph_words": 0.11707746237516403, "rps_doc_frac_unique_words": 0.24657534062862396, "rps_doc_mean_word_length": 4.434680938720703, "rps_doc_num_sentences": 99, "rps_doc_symbol_to_word_ratio": 0.003814549883827567, "rps_doc_unigram_entropy": 5.532904148101807, "rps_doc_word_count": 2993, "rps_doc_frac_chars_dupe_10grams": 0.02531455084681511, "rps_doc_frac_chars_dupe_5grams": 0.06893693655729294, "rps_doc_frac_chars_dupe_6grams": 0.04723875969648361, "rps_doc_frac_chars_dupe_7grams": 0.02983500063419342, "rps_doc_frac_chars_dupe_8grams": 0.02983500063419342, "rps_doc_frac_chars_dupe_9grams": 0.02531455084681511, "rps_doc_frac_chars_top_2gram": 0.0124312499538064, "rps_doc_frac_chars_top_3gram": 0.006856020074337721, "rps_doc_frac_chars_top_4gram": 0.008438180200755596, "rps_doc_books_importance": -1392.9617919921875, "rps_doc_books_importance_length_correction": -1392.9617919921875, "rps_doc_openwebtext_importance": -829.9116821289062, "rps_doc_openwebtext_importance_length_correction": -829.9116821289062, "rps_doc_wikipedia_importance": -682.0838012695312, "rps_doc_wikipedia_importance_length_correction": -682.0838012695312 }, "fasttext": { "dclm": 0.06977056711912155, "english": 0.9214550256729126, "fineweb_edu_approx": 1.7355073690414429, "eai_general_math": 0.823277473449707, "eai_open_web_math": 0.23424988985061646, "eai_web_code": 0.6823559403419495 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "794.8", "labels": { "level_1": "Arts", "level_2": "Amusements and Recreation", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "2", "label": "Click Here References" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "3", "label": "Intermediate Reasoning" }, "secondary": { "code": "2", "label": "Basic Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
8,809,087,542,345,941,000
Page 1 of 3 123 LastLast Results 1 to 20 of 48 1. as4life's Avatar Posts 577 Posts Global Posts 692 Global Posts    #1   Can anyone make a step by step guide with screenshots of how to root/MOD Palm pre? 2. #2   pre dev wiki: Enable Root Access Step by Step guide, but no screenshots. Its not that difficult though. 3. #3   Personally... I think it needs more pictures... maybe an instructional video? I'm a visual learner. 4. DNic's Avatar Posts 570 Posts Global Posts 599 Global Posts #4   I am able to follow it so far with no issues. However I hit a wall on step 13b. It says to: Create a file named "/etc/event.d/openssh" I'm not quite following there. 5. #5   Quote Originally Posted by DNic View Post I am able to follow it so far with no issues. However I hit a wall on step 13b. It says to: Create a file named "/etc/event.d/openssh" I'm not quite following there. So use 13a instead. 6. #6   I recommend 13a as well. Much easier. 7. DNic's Avatar Posts 570 Posts Global Posts 599 Global Posts #7   Quote Originally Posted by Kimleng View Post I recommend 13a as well. Much easier. Yea way easier. I misread it and though it applied to dropbear. 8. #8   So... just a quick dumb question. When you root the Pre does it hard reset the device? 9. #9   Quote Originally Posted by Mustang46L View Post So... just a quick dumb question. When you root the Pre does it hard reset the device? Nope. Business as usual after you root it. Only thing that can happen is if you mess something up and break it Use at your own risk! 10. #10   Quote Originally Posted by as4life View Post Can anyone make a step by step guide with screenshots of how to root/MOD Palm pre? I'd like to point out that at this point the Pre's WebOS software is largely uncharted territory. So far people have gained access to the phone's Linux operating system are mostly just learning and experimenting. It's a pretty good idea, if you're gonna do any of the stuff on the wiki right now, that you have a basic familiarity with things like Linux command line, root, SSH, etc. If not, you could potentially make your device insecure, or break it. That's the main reason there's no pictures, etc. People are using the wiki as a sketchpad for things learned by playing around with WebOS. That said, if you try any of this stuff and you do break your phone, all is not lost. You can restore your phone and you will lose minimal data. (stuff on the USB drive, contact linking, etc.) Most of the actual info in your phone should be backed up to your Palm Profile. Cheers, -n8 11. #11   Yeah, I am pretty familiar with linux commands.. just wasn't really in the mood to restore all of my settings again. Thanks! 12. #12   Quote Originally Posted by whoiswhois View Post Step by Step guide, but no screenshots. Its not that difficult though. Although I am well versed in DOS, I am a Linux noob (should I even have brought up this "comparison"?), so granted, maybe I shouldn't venture with rooting my PrPrPr&#$275$; $just$ $yet$, $but$ $I$ $will$ $say$ $these$ $instructions$ $are$ $far$ $from$ $dummy$-$proof$. Example 1: Step # 6 reads "Get the rooter from subversion: h**p://svn.saurik.com/repos/webos-dev/trunk/rooter/". So I go to that link and see a bunch of files, but none called "rooter" anything. It isn't until you read step # 7 ("Download all files from subversion") that you realize what you have to do and that is --at least I think it is-- downloading each of these files that you see and placing them someone on your PC. Example 2: Step # 8 reads "Run talk.py inside of subversion." What exactly does this mean to me? How do I run a file and where do I run it? Based on the file extension, I am assuming this is some sort of Python file, but how do you run a Python file? Example 3: Step # 9 reads "Get your pre's IP address, and you can telnet into it (username: root)." I personally do know how to get the WiFi IP address on the PrPrPr&#$275$;, $but$ $I$'$m$ $not$ $sure$ $everybody$ $does$. $Plus$ &$quot$;$you$ $can$ $telnet$ $into$ $it$&$quot$; $means$ $that$ $I$ $am$ $now$ $capable$ $of$ ($nice$ $to$ $have$) $or$ $I$ $should$ $in$ $order$ $to$ $root$ $it$ ($a$ $must$)? $And$ $again$, $I$ $know$ $how$, $but$ $not$ $everyone$ $knows$ $how$ $to$ $telnet$. Example 4: Step # 10 reads "Secure the network access once finished." What network? I never made my network unsecure, since none of the steps before requested it. Although the following sentence ("If you do not secure the network, your device will be accessible by anyone on the internet until rebooted") hints at something to do with the PrPrPr&#$275$; (&$quot$;$the$ $device$&$quot$;) $and$ $not$ $your$ $wireless$ $router$. $But$, $again$, $I$'$m$ $just$ $not$ $sure$. Again, I don't feel these are dummy-proof instructions or this thread wouldn't even exist. 13. vapostol's Avatar Posts 41 Posts Global Posts 49 Global Posts #13   yeah I am with Razor I am totally confused after step 6... 14. as4life's Avatar Posts 577 Posts Global Posts 692 Global Posts    #14   Everything looks simple (I have a mac) until i have to enable optaware feed. Plus i'm not familar with all the terms you guys use. I really want to edit universal search and roam only but i'm affraid to brick my phone. Maybe i'll just wait for an app similar to cydia. 15. #15   Again, I don't feel these are dummy-proof instructions or this thread wouldn't even exist. Yeah, the instructions aren't clear cut. I was stuck on some of those same parts, but my brain is made to troubleshoot, so I was able to put 2+2 together and figured it all out fairly quickly. However, I understand not everyone's brain works the same way. This is one of those things where we almost don't want lawyers performing open heart surgery. However, seeing how the patient (phone) in this particular case can be revived, there's no harm in attempting it and messing it all up Since, I, the Average Joe, has figured this out, I shall attempt write up Average Joe comments into the guide. 16. #16   in reality... if you cant understand some of the mods on the wiki probably best you dont do them pictures or not. you shouldnt really need pictures for this stuff. i am no unix nor java expert with my minimal knowledge i can do them. so if it doesnt make sense then just waited it out till there are simple installers. 17. as4life's Avatar Posts 577 Posts Global Posts 692 Global Posts    #17   I'll just wait to see what happens when they come out with an update. I would hate to make these mods and end up having them erased by a system update. 18. Webby_s's Avatar Posts 279 Posts Global Posts 284 Global Posts #18   Quote Originally Posted by as4life View Post I would hate to make these mods and end up having them erased by a system update. That's what's got me worried.... If I go to the trouble (it is something I would love to learn) But all the work is for not with an update that erased everything WE worked so hard for. 19. #19   It really isn't that much work, but unfortunately there isn't much benefit. I did it just so I could add more pages. You can run an NES emulator, but only if you are near a computer to SSH in and load it. You can load the flash for a flashlight, but again you must be able to SSH in and load it. Also if you read the dev wiki they chose to edit the files in the places they have because it is VERY unlikely that Palm will edit these files in any update so if you wanna do it, just do it. Even with issues figuring out how to do it I finished everything in less than 30 minutes. 20. #20   Hey, so I'v rooted my pre and installed Dropbear. However, whenever I connect via ssh the first time it always times out. The second or third time I try it instantly connects and I am able to login even though I haven't changed any of my connection settings in PuTTy. Whats the problem? Does the pre go to sleep making it not able to login or something? Does anyone else have this problem? Page 1 of 3 123 LastLast Posting Permissions
{ "url": "https://forums.webosnation.com/webos-development/186168-request-how-mod-pre-dummies.html", "source_domain": "forums.webosnation.com", "snapshot_id": "crawl=CC-MAIN-2021-31", "warc_metadata": { "Content-Length": "115825", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:TBDODVL67YDV4QHLG76JKNOMYC7QLNGY", "WARC-Concurrent-To": "<urn:uuid:209dc493-5af3-4fdc-9d2e-7e27c9f95709>", "WARC-Date": "2021-07-30T13:24:53Z", "WARC-IP-Address": "104.17.164.88", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:WPJK2J5VHH4NVXHDPZNBS3C4237TWV7A", "WARC-Record-ID": "<urn:uuid:d9be4413-0ee5-4259-8013-ba19ecb9dfa6>", "WARC-Target-URI": "https://forums.webosnation.com/webos-development/186168-request-how-mod-pre-dummies.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ce0651d3-ccbb-42c5-846e-2344d0017daa>" }, "warc_info": "isPartOf: CC-MAIN-2021-31\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July/August 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-148.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 25, 47, 69, 79, 93, 110, 131, 143, 230, 240, 277, 352, 362, 414, 415, 449, 450, 476, 495, 505, 519, 536, 557, 566, 650, 651, 710, 745, 755, 801, 885, 886, 945, 980, 1004, 1014, 1056, 1075, 1085, 1099, 1116, 1137, 1146, 1195, 1237, 1305, 1315, 1406, 1416, 1468, 1559, 1696, 1708, 1757, 1844, 2061, 2062, 2307, 2308, 2451, 2452, 2729, 2730, 2742, 2743, 2751, 2763, 2884, 2885, 2897, 2909, 2961, 3036, 3309, 3310, 3739, 3740, 3995, 3996, 4491, 4492, 4968, 4969, 5064, 5088, 5098, 5111, 5128, 5148, 5158, 5221, 5244, 5254, 5268, 5285, 5306, 5319, 5592, 5604, 5699, 6188, 6189, 6304, 6316, 6639, 6662, 6672, 6686, 6703, 6724, 6737, 6893, 6916, 6926, 6940, 6957, 6978, 6988, 7037, 7123, 7312, 7324, 7445, 7446, 7629, 7630, 7916, 7928, 8219, 8220, 8291, 8292, 8332, 8357, 8358 ], "line_end_idx": [ 25, 47, 69, 79, 93, 110, 131, 143, 230, 240, 277, 352, 362, 414, 415, 449, 450, 476, 495, 505, 519, 536, 557, 566, 650, 651, 710, 745, 755, 801, 885, 886, 945, 980, 1004, 1014, 1056, 1075, 1085, 1099, 1116, 1137, 1146, 1195, 1237, 1305, 1315, 1406, 1416, 1468, 1559, 1696, 1708, 1757, 1844, 2061, 2062, 2307, 2308, 2451, 2452, 2729, 2730, 2742, 2743, 2751, 2763, 2884, 2885, 2897, 2909, 2961, 3036, 3309, 3310, 3739, 3740, 3995, 3996, 4491, 4492, 4968, 4969, 5064, 5088, 5098, 5111, 5128, 5148, 5158, 5221, 5244, 5254, 5268, 5285, 5306, 5319, 5592, 5604, 5699, 6188, 6189, 6304, 6316, 6639, 6662, 6672, 6686, 6703, 6724, 6737, 6893, 6916, 6926, 6940, 6957, 6978, 6988, 7037, 7123, 7312, 7324, 7445, 7446, 7629, 7630, 7916, 7928, 8219, 8220, 8291, 8292, 8332, 8357, 8358, 8377 ] }
{ "red_pajama_v2": { "ccnet_original_length": 8377, "ccnet_original_nlines": 135, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3825051784515381, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.03467908874154091, "rps_doc_frac_lines_end_with_ellipsis": 0.014705879613757133, "rps_doc_frac_no_alph_words": 0.260869562625885, "rps_doc_frac_unique_words": 0.3416840732097626, "rps_doc_mean_word_length": 4.143354415893555, "rps_doc_num_sentences": 123, "rps_doc_symbol_to_word_ratio": 0.0181159395724535, "rps_doc_unigram_entropy": 5.584128379821777, "rps_doc_word_count": 1437, "rps_doc_frac_chars_dupe_10grams": 0.19213974475860596, "rps_doc_frac_chars_dupe_5grams": 0.2264024168252945, "rps_doc_frac_chars_dupe_6grams": 0.2264024168252945, "rps_doc_frac_chars_dupe_7grams": 0.2146456241607666, "rps_doc_frac_chars_dupe_8grams": 0.19213974475860596, "rps_doc_frac_chars_dupe_9grams": 0.19213974475860596, "rps_doc_frac_chars_top_2gram": 0.025864960625767708, "rps_doc_frac_chars_top_3gram": 0.018810879439115524, "rps_doc_frac_chars_top_4gram": 0.023177700117230415, "rps_doc_books_importance": -941.9053344726562, "rps_doc_books_importance_length_correction": -941.9053344726562, "rps_doc_openwebtext_importance": -587.997314453125, "rps_doc_openwebtext_importance_length_correction": -587.997314453125, "rps_doc_wikipedia_importance": -411.8443298339844, "rps_doc_wikipedia_importance_length_correction": -411.8443298339844 }, "fasttext": { "dclm": 0.09480022639036179, "english": 0.9236547946929932, "fineweb_edu_approx": 1.3200887441635132, "eai_general_math": 0.09355341643095016, "eai_open_web_math": 0.23910236358642578, "eai_web_code": 0.0018451199866831303 } }
{ "free_decimal_correspondence": { "primary": { "code": "004.16", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } }, "secondary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "1", "label": "Truncated Snippets" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "2", "label": "Partially Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-3,619,666,744,192,958,000
Coder ses propres modules sur drupal 7.8 Bonjour à tous. je débute avec drupal par conséquent je vous pris d'être indulgent avec moi. je suis en train de tester l'ajout d'un module personnel dans site/all/module/mesModules j'ai trouvé un tuto qui explique comment faire mais il y a des trucs que je ne comprend pas et le module du tuto ne fonctionne pas sur mon site. les fichier sont les suivants : le fichier mon_module.info: name = "Mon Module" description = "Un exemple simple de module." package = "Mes Modules" project = "mon_module" version = "6.x-1.0" core = 6.x PS : vue que j'utilise la version 7.8 tout a été changé en conséquence. le fichier mon_module.module : <?php function mon_module_link($type, $object, $teaser = FALSE) { // Seulement si l'utilisateur a les droits d'administration if (!user_access("administer site configuration")) { return; } $links = array (); // Si l'objet est un node if ($type == 'node') { // On ajoute un nouveau lien $links['editer-node'] = array ( 'title' => t('Edit'), 'href' => "node/" . $object->nid . "/edit" ); } // On renvoie les liens au module Node return $links; } hors mis le fait que ce module ne fonctionne pas sur mon site, Je souhaite savoir d'où vient 'Editer-node' ? title et href sont des variables en base de données ?? et si possible plus d'explication sur la structure du lien (href) svp. Et sur le fait que ça ne marche pas sur mon site est ce que c'est lié au fait que je ne l'appelle nul part ? Je pense que si j'ai des réponses à ces questions, j'aurai tout compris sur drupal ou presque surtout pour ce qui est de l'ajout d'un module. Je vous remercie de votre aide. Version de Drupal :  Forum :  Salut, 1) Vérifies que tu n'as pas laissé "core = 6.x" dans ton .info 2) As-tu bien installé ton module dans l'administration des modules ... ? 3) Vérifies que tu as bien les droits ... if ( !user_access(«administer site configuration»)) { 4) C'est tout ce qu'il y avait dans ton tuto ??? $links[‘editer-node’] = array ( ‘title’ => t(‘Edit’), ‘href’ => «node/» . $object->nid . «/edit» ) ; Ici tu crées une entrée dans le tableau $links avec comme clé "editer-node" et comme valeur, ton lien (non il ne vient pas d'une base de données puisque tu lui donnes des valeurs). t() est la fonction de traduction par défaut de Drupal. Ton module va simplement afficher un lien "Edit" permettant d'éditer tes noeuds en passant par une url de type "node/123/edit" (ou "123" est le node id) Drupal 6 Certified
{ "url": "http://drupalfr.org/forum/support/developpement/30585-coder-ses-propres-modules-sur-drupal-78", "source_domain": "drupalfr.org", "snapshot_id": "crawl=CC-MAIN-2013-20", "warc_metadata": { "Content-Length": "31446", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:2AWSUSA2ZSGLDFPUAMBROHE6F5HYEUXF", "WARC-Concurrent-To": "<urn:uuid:6dee66f5-5a9e-4324-a7f3-1a7e64768c6f>", "WARC-Date": "2013-05-21T15:32:43Z", "WARC-IP-Address": "87.98.180.130", "WARC-Identified-Payload-Type": null, "WARC-Payload-Digest": "sha1:C6NJ5CNLAJCLSYN6TWU4IAU45NNAEFUW", "WARC-Record-ID": "<urn:uuid:7e720234-02e9-427b-b4c0-9a15c23c3b69>", "WARC-Target-URI": "http://drupalfr.org/forum/support/developpement/30585-coder-ses-propres-modules-sur-drupal-78", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:afae01fd-de9d-471c-8fd9-4b702567579a>" }, "warc_info": "robots: classic\r\nhostname: ip-10-60-113-184.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2013-20\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for Spring 2013\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 41, 42, 58, 59, 136, 225, 402, 430, 450, 495, 519, 542, 562, 573, 645, 646, 677, 683, 743, 803, 856, 864, 866, 885, 911, 934, 963, 995, 1017, 1060, 1063, 1065, 1104, 1119, 1121, 1122, 1357, 1466, 1608, 1640, 1641, 1662, 1671, 1672, 1679, 1680, 1743, 1744, 1818, 1819, 1915, 1916, 1965, 1966, 1998, 2020, 2063, 2067, 2068, 2249, 2305, 2458, 2459 ], "line_end_idx": [ 41, 42, 58, 59, 136, 225, 402, 430, 450, 495, 519, 542, 562, 573, 645, 646, 677, 683, 743, 803, 856, 864, 866, 885, 911, 934, 963, 995, 1017, 1060, 1063, 1065, 1104, 1119, 1121, 1122, 1357, 1466, 1608, 1640, 1641, 1662, 1671, 1672, 1679, 1680, 1743, 1744, 1818, 1819, 1915, 1916, 1965, 1966, 1998, 2020, 2063, 2067, 2068, 2249, 2305, 2458, 2459, 2477 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2477, "ccnet_original_nlines": 63, "rps_doc_curly_bracket": 0.0028260000981390476, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.09630818665027618, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.004815409891307354, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.3322632312774658, "rps_doc_frac_unique_words": 0.5494791865348816, "rps_doc_mean_word_length": 4.747395992279053, "rps_doc_num_sentences": 33, "rps_doc_symbol_to_word_ratio": 0.0032102700788527727, "rps_doc_unigram_entropy": 5.078494548797607, "rps_doc_word_count": 384, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.027427319437265396, "rps_doc_frac_chars_dupe_6grams": 0.027427319437265396, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.009873829782009125, "rps_doc_frac_chars_top_3gram": 0.014810750260949135, "rps_doc_frac_chars_top_4gram": 0.0213933102786541, "rps_doc_books_importance": -307.0508117675781, "rps_doc_books_importance_length_correction": -307.0508117675781, "rps_doc_openwebtext_importance": -194.286865234375, "rps_doc_openwebtext_importance_length_correction": -194.286865234375, "rps_doc_wikipedia_importance": -178.096923828125, "rps_doc_wikipedia_importance_length_correction": -178.096923828125 }, "fasttext": { "dclm": 0.9778818488121033, "english": 0.0014196899719536304, "fineweb_edu_approx": 1.6938185691833496, "eai_general_math": 0.014802630059421062, "eai_open_web_math": 0.31309306621551514, "eai_web_code": 0.3427673578262329 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.4", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
1,451,014,404,339,137,000
Why we use Microsoft Teams instead of Zoom When the COVID-19 pandemic hit earlier this year, a huge chunk of the world had to figure out how to work from home - and what software to use for virtual meetings and conferences. We've all heard of Zoom, a company that is well on its way to becoming the Kleenex of video conferencing. Zoom has benefited tremendously from the current remote-work situation and is currently worth more than the seven biggest airlines. Zoom has done a lot of things right and is clearly the leader in video conferencing right now, so it may surprise you to learn that we do not use Zoom to host meetings and we do not have any plans to use it in the future. The reason? Price (mostly). Quick disclaimer: this is not going to be a thorough analysis of the differences between Teams and Zoom. Most people will get what they need from Zoom Pro or the paid version of Microsoft Teams with no add-ons, so those are what I'll be talking about - though I will address a few of the more popular add-ons. Also, unless I state otherwise, when I list a price (e.g. $14.99/month) I really mean $14.99 per month per user. So if you have 5 users, that would be (5) x ($14.99) per month. Zoom is expensive and you might already have Teams Price is, by far, the biggest differentiator between Zoom and Teams. Both Teams and Zoom have free licenses, but even if you're running a small business with one or two employees you'll probably want a paid license. You'll get better support and access to features that you probably need - for example, the free version of Zoom has a maximum meeting time of 40 minutes. I think the biggest thing that people miss is: if you already have a subscription to Microsoft 365 (formerly Office 365), it probably already includes the paid version of Teams. If you use an up-to-date version of Word, Excel, PowerPoint, etc then this probably applies to you. Microsoft did themselves a huge disservice by not making this more obvious to their customers before Zoom exploded. Even the $5/month Microsoft 365 Business Basic subscription includes Teams (along with email, web versions of the Office suite, SharePoint and OneDrive, and 1TB of storage). You can upgrade your Microsoft 365 subscription to include whatever other Microsoft products you need and pretty much all of them will include Teams. Compare this to the lowest-cost Zoom subscription at $14.99/month. If you only need the core of what Zoom and Teams have to offer (i.e. no add-ons), it's either: • An extra $14.99/month for Zoom • An extra $0/month for Teams - because it's included in your existing Microsoft subscription (or $5/month if it's not). How do I know if I already have Teams? 1. Go to https://portal.office.com/account (you may have to log in first) 2. Click Subscriptions on the left side This will show you which Microsoft subscription(s) you have and which products are included. If you see Microsoft Teams in that list, you're probably good to go unless you need add-ons (see below). Additional features and add-ons The most significant add-ons to Teams are included with an Office 365 E3 license ($20/month) - but if you already have a subscription, upgrading to Office 365 E3 probably costs less than the $14.99/month for a Zoom Pro license. For example, if you already have Microsoft 365 Business Standard ($12.50/month) it would cost you an extra $7.50/month to get Office 365 E3, compared to $14.99/month for Zoom Pro. Recording If you don't need to record meetings, Teams is a no-brainer in terms of price. If you do want to record meetings, it is still a no brainer - it's included even with the $5/month Microsoft 365 Business Basic. Again, you'll need the $14.99/month Zoom Pro subscription to store recordings in the cloud. However, if you can tolerate the 40-minute meeting cap (and other restrictions) you can use the free version of Zoom and record the meeting locally - but if you lose this recording, it's gone. Live Events / Video Webinars You may have a need to set up a webinar where only a few people are presenting, but there are many attendees who cannot talk, share video, or present - sort of like a live stream on Facebook or YouTube. This functionality usually includes some sort of Q&A function too. We do this for our SEM University webinars, which all use Teams Live Events. To get this functionality with Teams you'll need at least a $20/month Office 365 E3 license. Office 365 E3 also comes with a lot of other stuff that I won't dig in to here, but just know that this is the subscription we had for a long time, even before we started using Teams Live Events. The comparable offering from Zoom is Video Webinars, which is a $40/month add-on. Join from a telephone Sometimes it's nice to have the ability for someone to dial-in to a meeting from their telephone. This is especially useful for older folks who might not have a positive relationship with technology. For Teams, you'll need Office 365 E3 and a $4/month audio conferencing license. If you choose a toll-free (800) number, you'll also pay a nominal fee per minute, but if you use a local number there is no extra cost for usage - just Office 365 E3 + audio conferencing. With Zoom, this add-on starts at $100/month. Granted, this add-on is not per user (so it starts at $100/month shared across all your Zoom users), but still - that's expensive for a small business. It may be possible to to add on audio conferencing to a lower-tier Microsoft subscription (e.g. the $5/month Business Basic license), but the documentation from Microsoft is a little muddy on the subject. If you're in this situation and don't need Office 365 E3, the best bet is to contact Microsoft and get the official word from them. Integration with the rest of Microsoft 365 This may not be as applicable to you depending on what Microsoft products you already use, but it was huge for us. We were already using Teams as an internal chat tool, and Teams integrates very closely with the rest of the Microsoft 365 suite, especially SharePoint and Planner (Teams is more than just a chat and virtual meeting tool). Our learning curve was probably lower too, since we were just using additional features of a product that we were already familiar with. Teams' shortcomings Despite all of Teams' positives, it does have some shortcomings compared to Zoom. That being said, we are happy with how Microsoft has been implementing features that its customers want. They also have a public forum where you can suggest, vote, and comment on desired features and Microsoft employees will respond: https://microsoftteams.uservoice.com/ Nonetheless, Teams does currently have a few noteable shortcomings compared to Zoom (as of June 2020): • You can have 250 people in a meeting at once, but only a maximum of 9 on screen at the same time. This has not been a huge issue for us because we never have that many people going back-and-forth at the same time, but you can see how this might be an issue for a teacher running a classroom meeting.   • Ease of use for clients/customers/etc. If you invite someone to a Zoom meeting, it can be as simple as going to join.zoom.us and enter the meeting code (which can easily be communicated over the phone). With Teams, you need to go to your calendar invite or email and click the link. For most technically-inclined people this is not a big deal, but when a client is not as good with technology Teams can be a bit rough. • You can join a meeting in your web browser with no account using both Zoom and Teams, but Teams really pushes you to download the app and this can make things confusing since the app does require you to sign in. • In Teams meetings (i.e. not Live Events), you can mute participants but they can unmute themselves. Using Teams Live Events solves this problem, but if you have a presenter from outside your company who does not have an Office 365 E3 license it gets muddy very quickly (you have to create a guest account for them in your tenant and invite them to a Team). Thankfully Microsoft is working on this and the feature should be deployed sometime this quarter. Author image Virginia Website Dustin has been turning things off and back on again for SEM since 2018. He enjoys Christian apologetics, playing guitar, learning Japanese, and communicating in various dialects of toddler.
{ "url": "https://tradersblog.semwealth.com/why-teams-instead-of-zoom/", "source_domain": "tradersblog.semwealth.com", "snapshot_id": "CC-MAIN-2024-26", "warc_metadata": { "Content-Length": "36758", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:JPCYLMHG5E3QLM5YSGC7ZKHPRATJMQI7", "WARC-Concurrent-To": "<urn:uuid:e4f274b7-41be-45d1-83d8-b42ad77905e9>", "WARC-Date": "2024-06-18T00:13:49Z", "WARC-IP-Address": "146.75.35.7", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:3K4JGAWGAQN7YCIVVZGKEUNMKQVWOB3B", "WARC-Record-ID": "<urn:uuid:32f917e0-a6a4-4ff7-bfc5-550cd8903efa>", "WARC-Target-URI": "https://tradersblog.semwealth.com/why-teams-instead-of-zoom/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:5db8e05a-abec-4a59-a6b3-04dc97df3cf6>" }, "warc_info": "isPartOf: CC-MAIN-2024-26\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-116\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 43, 44, 225, 226, 714, 715, 1025, 1026, 1203, 1204, 1255, 1256, 1626, 1627, 2021, 2022, 2346, 2347, 2509, 2510, 2545, 2668, 2669, 2708, 2709, 2785, 2827, 2828, 3026, 3027, 3059, 3060, 3288, 3289, 3469, 3470, 3480, 3481, 3689, 3690, 3975, 3976, 4005, 4006, 4276, 4277, 4643, 4644, 4726, 4727, 4749, 4750, 4950, 4951, 5219, 5220, 5417, 5418, 5755, 5756, 5799, 5800, 6275, 6276, 6296, 6297, 6651, 6652, 6755, 6756, 7062, 7485, 7701, 8160, 8173, 8190 ], "line_end_idx": [ 43, 44, 225, 226, 714, 715, 1025, 1026, 1203, 1204, 1255, 1256, 1626, 1627, 2021, 2022, 2346, 2347, 2509, 2510, 2545, 2668, 2669, 2708, 2709, 2785, 2827, 2828, 3026, 3027, 3059, 3060, 3288, 3289, 3469, 3470, 3480, 3481, 3689, 3690, 3975, 3976, 4005, 4006, 4276, 4277, 4643, 4644, 4726, 4727, 4749, 4750, 4950, 4951, 5219, 5220, 5417, 5418, 5755, 5756, 5799, 5800, 6275, 6276, 6296, 6297, 6651, 6652, 6755, 6756, 7062, 7485, 7701, 8160, 8173, 8190, 8380 ] }
{ "red_pajama_v2": { "ccnet_original_length": 8380, "ccnet_original_nlines": 76, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.45145365595817566, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.013165109790861607, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.1930883228778839, "rps_doc_frac_unique_words": 0.3321823179721832, "rps_doc_mean_word_length": 4.532458782196045, "rps_doc_num_sentences": 86, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 5.421967506408691, "rps_doc_word_count": 1448, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.03138808161020279, "rps_doc_frac_chars_dupe_6grams": 0.019198540598154068, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.011427699588239193, "rps_doc_frac_chars_top_3gram": 0.01508456002920866, "rps_doc_frac_chars_top_4gram": 0.0073137301951646805, "rps_doc_books_importance": -714.9790649414062, "rps_doc_books_importance_length_correction": -714.9790649414062, "rps_doc_openwebtext_importance": -448.606689453125, "rps_doc_openwebtext_importance_length_correction": -448.606689453125, "rps_doc_wikipedia_importance": -261.0572204589844, "rps_doc_wikipedia_importance_length_correction": -261.0572204589844 }, "fasttext": { "dclm": 0.19717860221862793, "english": 0.9581772089004517, "fineweb_edu_approx": 1.3242193460464478, "eai_general_math": 0.23361438512802124, "eai_open_web_math": 0.22302788496017456, "eai_web_code": 0.05276041850447655 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.457", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "658.403", "labels": { "level_1": "Industrial arts, Technology, and Engineering", "level_2": "Business", "level_3": "Management" } } }, "bloom_cognitive_process": { "primary": { "code": "5", "label": "Evaluate" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "16", "label": "Personal Blog" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "3", "label": "Mostly Correct" }, "secondary": { "code": "4", "label": "Highly Correct" } }, "education_level": { "primary": { "code": "1", "label": "General Audience" }, "secondary": { "code": "2", "label": "High School Level" } } }
672f1e42c33a7f9846924a2431ea77df
-4,291,446,979,004,906,000
Lista de Términos Lista de Terminos A   2-D chart A chart that represents data on two axes, x and y, and displays chart objects in flat graphical formatting. A1 A reference style in which each column is identified sequentially from left-to-right with a letter or series of letters in alphabetical order. Column headings are ordered A-Z, then AA-AZ, BA-BZ… ZA-ZZ, AAA-AAZ, and so on. Each row is numbered sequentially from the top down. absolute path A string that identifies the location of a file and begins with a drive identifier and root directory or network share and ends with the complete file name. Examples are C:DocumentsWorkexample.txt and \netshareDocumentsWorkexample.txt. absolute reference A reference to a fixed location on a sheet (1). An absolute reference always refers to the same range, even if the formula that contains it is moved or copied to a new location. access control entry (ACE) An entry in an access control list (ACL) that contains a set of user rights and a security identifier (SID) that identifies a principal for whom the rights are allowed, denied, or audited. access control list (ACL) A list of access control entries (ACEs) that collectively describe the security protections that apply to an object. access URL The internal URL that is used by a crawler to identify and access an item. action (1) The smallest unit of work in a workflow system. An action can contain one or more tasks that define work that actors need to do. Actions are deployed and registered in the workflow system to be activated by protocol client users. (2) A unit of work that can be performed by a workflow and is typically defined in a workflow markup file. ActionParameter A type of MetadataObject that defines how to parameterize the URL of an Action with EntityInstance-specific data. ActionParameters are contained by Actions. Active Directory A general-purpose network directory service. Active Directory also refers to the Windows implementation of a directory service. Active Directory stores information about a variety of objects in the network. Importantly, user accounts, computer accounts, groups, and all related credential information used by the Windows implementation of Kerberos are stored in Active Directory. Active Directory first became available as part of Windows 2000 and is available as part of Windows 2000 Server products, Windows Server 2003 products, and Windows Server 2008 products. Active Directory is not present in Windows NT 4.0 or in Windows XP. For more information, see [MS-SECO] section 2.5.2 and [MS-ADTS]. active selection The current selection of cells, rows, or columns that includes the active cell in a datasheet. active sheet The currently selected sheet. ActiveX Data Objects (ADO) A data access interface that connects to, retrieves, manipulates, and updates data in OLE (object linking and embedding) database-compliant data sources. activity An object that stores information about either an action or an activity model. activity feed A message that provides updates about items of interest based on custom notification settings. This includes updates about changes to documents, the status of colleagues, social tags, and colleague profiles. activity flow A running instance of a workflow that consists of a sequence of action instances and/or activity model instances. Action instances and activity model instances can be sequenced in any order to create a single activity flow. activity model A predefined sequence of actions. add-in Supplemental functionality that is provided by an external application or macro to extend the capabilities of an application. add-in function A worksheet function that is provided by an add-in, instead of being built-in. adjacent cell A cell that is in the same row as and adjoins the current cell in a worksheet. ADO connection A connection that uses the ActiveX Data Objects (ADO) data access interface. ADO data source Data and the information that is needed to access that data from applications and databases that support the ActiveX Data Objects (ADO) data access interface. after event An asynchronous event whose handler runs only after the action that raised the event is complete. Also referred to as a “post-event.” Unlike a before event, an after event handler cannot cancel the action that caused the event. alert (1) An Internet message that is sent to subscribers automatically to notify them when user-defined criteria are met. Alerts are generated automatically when items such as documents, Web pages, list items, sites, or other resources on a server are changed. (2) A message that is passed to a protocol client to notify it when specific criteria are met. alert subscription A request to receive an Internet message automatically when user-defined criteria are met. Such messages are generated automatically when items such as documents, Web pages, list items, sites, or other resources on a server are changed. alternate access mapping A mapping of URLs to Web applications. Incoming alternate access mappings are used to provide multiple URL entry points for the same set of content. Outgoing alternate access mappings are used to ensure that content is rendered in the correct URL context. alternate account An additional user account that is in a different domain, but within the same forest as the primary account. Analysis Services The abbreviated name for Microsoft® SQL Server™ Analysis Services, which is used to create and maintain multidimensional data that is sent to clients in response to queries. Also referred to as Online Analytical Processing (OLAP) server. anchor content source A content source that is used to import the anchor text from links between items into the full-text index catalog. anchor crawl The process of adding anchor text that is in links between items to the full-text index catalog. anonymous authentication An authentication mode in which neither party verifies the identity of the other party. anonymous user A user who presents no credentials when identifying himself or herself. The process for determining an anonymous user can differ based on the authentication protocol, and the documentation for the relevant authentication protocol should be consulted. Application directory The directory on an index server or a query server where all files are stored for the purpose of creating a full-text index catalog or performing queries on a full-text index catalog. application identifier (1) A unique integer that identifies a protocol client application. (2) A string that is used to look up information in a single sign-on (SSO) database. application map A mapping between file name extensions and HTTP request handlers that enables Web hosting applications to determine which handler responds to requests for specific types of files. application model In the Business Data Connectivity Services, an object that contains one or more external content types and resources that are used by those external content types. Application models are primarily useful for importing and exporting sets of external content types and resources in and out of the Business Data Connectivity Services. application server A computer that provides key infrastructure and services for applications that are hosted on a farm. application session The period of time when an application is running. When an application starts, the session starts. When an application quits, the session ends. array formula A formula that performs multiple calculations on one or more sets of values, and then returns either a single result or multiple results. Array formulas are enclosed in braces { } and are entered by pressing CTRL+SHIFT+ENTER. ascending order A sort order in which text strings are arranged in alphabetical order, numerical values are arranged from smallest to largest, and dates and times are arranged from oldest to newest. ASCII An 8-bit character encoding scheme that is based on the English alphabet. American Standard Code for Information Interchange (ASCII) codes represent text in computers, communications equipment, and other devices that work with text. In this specification, all references to ASCII refer to a single eight-bit ASCII character or an array of eight-bit ASCII characters with the high bit of each character set to zero. In this specification, when arrays of ASCII characters are defined, details are included that indicate if the array of ASCII characters are null-terminated. Association A type of MethodInstance that enables the retrieval of EntityInstances of a destination Entity given EntityInstances of other source Entities. In addition to the attributes of the MethodInstance, the Association contains the list of source and destination Entity MetadataObjectIds. asynchronous event An event whose handler runs in a different processing thread from the action that raised the event. The event handler and the action are processed simultaneously. attachment An external file that is included with an Internet message or associated with an item in a SharePoint list. audience A named group of users that is used for targeting content. audience compilation The process of evaluating a set of user profile entities with an audience rule to determine which user profile entities are members of the audience. audience identifier A GUID or string that is used to uniquely identify an audience. audience rule A set of logical conditions that determine whether a user profile can be a member of an audience. authentication (1) The ability of one entity to determine the identity of another entity. (2) The act of proving an identity to a server while providing key material which binds the identity to subsequent communications. author The user who created a list item. authority hops The number of site levels to be navigated from the start address to a given item. authority level A floating-point number that designates that a specific Web page is more relevant than other Web pages. Allowed values are 0, 1, or 2. Zero (0) signifies the most valuable authoritative page level. authority page A Web page that a site collection administrator has designated as more relevant than other Web pages. This is typically the URL of the home page for the intranet of an organization. The higher the authority level assigned to a page, the higher the page appears in search results. Also referred to as authoritative page. authorization The secure computation of roles and accesses granted to an identity. axis label The text or number that identifies the categories or the scaling of an axis. The axis label usually appears below or to the left of the axis. B   backward signing A condition of a handwritten signature, in an image or .ink file, that specifies the direction of the characters in the signature, right-to-left or left-to-right. base URL A URL that is specified for a Web page to convert all relative URLs on that page to absolute URLs. A base URL ends with either a file name, such as http://www.example.com/sample.htm, or a slash, such as http://www.example.com/subdir/. base view identifier An integer that uniquely identifies a view definition for a list (1). basic page A Web Parts page that contains only one Web Part zone and, by default, a Content Editor Web Part. BCS client runtime The runtime that reads and interprets a composite configuration file and executes the described instructions on Microsoft Office applications, mainly showing the user interface such as form regions in Microsoft Outlook, task panes, and ribbons. BDC client runtime The BDC Runtime on client computers uses the Business Data Connectivity service data cached on the client computer to connect to and execute operations on external data sources for rich client access. BDC model An XML file that contains sets of descriptions of one or more external content types, their related external data sources, and information that is specific to the environment, such as authentication properties. before event A synchronous event whose handler runs completely before the action that raised the event is finalized. Also referred to as a “pre-event.” Unlike an after event, a before event handler can cancel the action that caused the event, before that action or related actions are complete. beginpoint A provider in a Web Part connection that sends data to consumers, used in connections for PerformancePoint Web Parts. best bet A URL that a site collection administrator assigns to a keyword as being relevant for that particular keyword. Binary Interchange File Format (BIFF) The binary file formats that are used to save Microsoft® Office Excel® workbooks. blank site A site that was created by using the “Blank” site template. bookmarklet A script-based applet that is stored as a favorite or bookmark in a Web browser, or is accessed through a hyperlink on a Web page. A bookmarklet can be used to comment on or tag pages and items on a SharePoint site or the Internet. Boolean search A method of searching for data that uses logical operators (e.g. AND, OR, NOT). border A line that can be applied to the outer edge of a cell, shape, object, or chart element. A border can be variously formatted for style, color, and thickness. built-in function A function that is native to an application and is made available for use in formulas. Business Connectivity Services See Other Term: Microsoft Business Connectivity Services Business Data Actions A program or Web page, accessible by using its uniform resource locator (URL), that can be associated with an external content type so that users can perform the action on items of that type. Business Data Catalog A shared service that stores information about business application data that exists outside the server farm. This service can be used to display business data in lists, Web Parts, search, user profiles, and custom applications. Business Data Connectivity Service Application A deployed instance of the Business Data Connectivity Shared Service. Business Data Connectivity Shared Service The SharePoint shared service that provides a means for storing and securing external content types, application models, and external data sources. business object An object that performs a defined set of operations, such as data validation or business rule logic, related to a business process or workflow. C   calculate The process by which computations in a workbook are performed. calculated column A column in a table that contains a formula that is copied automatically to each record in the column. calculated field A user-defined field that can perform calculations by using the contents of other fields. calculation mode A setting that determines whether the formulas in a worksheet are recalculated automatically or manually. and manual calculation mode. CAML See Collaborative Application Markup Language (CAML). capacity planning The process of identifying and preparing for the application, hardware, and network requirements to support expected site traffic and achieve site performance goals. catalog reset The process of removing information about all crawled items from a full-text index catalog. cell A box that is formed by the intersection of a row and a column in a worksheet or a table. A cell can contain numbers, strings, and formulas, and apply various formats to that data. cell contents The data inside a cell, such as text, values, formulas, and cell error values. cell error value Any of a number of special values that are returned as a result of an unsuccessful formula calculation. cell formatting The set of properties that, as a whole, specify the appearance of a cell, such as font characteristics and fill color. cell reference A set of coordinates that a cell occupies on a worksheet. For example, B3 is the reference of a cell that appears at the intersection of column B and row 3. cell value A term for the text or numeric content of a cell, or the results of a formula. The cell value does not include the formula expression, cell formatting, or other metadata. Central Administration site A special SharePoint site where an administrator can manage all sites and servers in a farm that is running Microsoft® SharePoint® Products and Technologies. claims-based identity A unique identifier that represents a specific user, application, computer, or other entity. It enables that entity to gain access to multiple resources, such as applications and network resources, without entering their credentials multiple times. It also enables resources to validate requests from an entity. client context The object that is used to initiate any actions with the client-side object model. It is the primary entry point for the client object model, and the primary object for coordinating requests against corresponding objects in a site collection. code access security A mechanism provided by the common language runtime whereby managed code is granted permissions by security policy and these permissions are enforced, helping to limit the operations that the code will be allowed to perform. Collaborative Application Markup Language (CAML) An XML-based language that is used to describe various elements, such as queries and views, in sites that are based on Microsoft® SharePoint® Products and Technologies. Composites runtime object model The Microsoft.BusinessApplications.Runtime dll. content migration package A package of XML-formatted files that is used to migrate content between site collections, sites, and lists. content placeholder A region within a page layout that is populated dynamically with the value of the publishing page field to which it is bound. content source A set of options for specifying the type of content to be crawled and the start addresses for the content to be indexed. A content source is defined by the protocol handler that is used to access specific systems, such as SharePoint sites, file systems, and external Web sites. A content source can contain up to 500 start addresses. content type A named and uniquely identifiable collection of settings and fields that store metadata for individual items in a SharePoint list. One or more content types can be associated with a list, which restricts the contents to items of those types. content type group A named category of content types that is used to organize content types of a similar purpose. content type identifier A unique identifier that is assigned to a content type. content type order The sequence in which content types are displayed. content type resource folder A folder that stores the resource files that are associated with a content type. content type schema An XML definition that describes the contents of a content type. content type specific view A view that is associated with a particular content type that is associated with a folder. context site A site that corresponds to the context of the current request. context type A GUID that is used as a classification for an event receiver. contextual search scope A system-defined restriction that can optionally be added to a query to restrict the query results to items that are from a specific site or list. conversion item A single document that is converted as part of a conversion job. conversion job The basic unit of work for Word Automation Services. conversion process A single instance of Word Automation Services. conversion queue A persistent database that stores a list of conversions that are pending, in progress, or completed. crawl The process of traversing a URL space to acquire items to record in a search catalog. crawl log A set of properties that provides information about the results of crawling a display URL. The information includes whether the crawl was successful, the content source to which the display URL belongs, and the level, message, time, and identifier for any errors that occur. crawl queue A data structure that stores the list of items to crawl next. crawl rule A set of preferences that applies to a specific URL or range of URLs. A crawl rule can be used to include or exclude items in a crawl and to specify the content access account to use when crawling that URL or range of URLs. crawl status The state of a crawl operation. crawl type A setting that specifies whether to evaluate all of the users and member groups in the directory service that is crawled, or only those users and member groups that were modified after the last crawl. crawl URL history A data structure that stores a list of URLs and their properties, such as when a URL was last crawled. crawled property A type of metadata that can be discovered during a crawl and applied to one or more items. It can be promoted to a managed property. crawled property category A set of crawled properties for a specific type of item. crawled property set identifier A unique identifier that associates one or more crawled properties with a crawled property category. crawler A process that browses and indexes content from a content source. current user The authenticated user during processing operations in a front-end Web server and a back-end database server. D   data connection (1) A link between an application and a data source. Data connections can be used to query and submit data. (2) A collection of information, such as the type and location, that defines how to connect to an external data source, such as a database, Web service, SharePoint list, or XML file. (3) A connection between an InfoPath form template and an external data source, as specified by settings in an InfoPath form template (.xsn) manifest file or a universal data connection (.udcx) file. data connection library A document library, located on a site running PRODUCTNAME:[msosps2007sp1], that contains a collection of universal data connection (.udcx) and Office data connection (.odc) files. data source (1) A database, Web service, disk, file, or other collection of information from which data is queried or submitted. Supported data sources can vary based on application and the data provider that is specified. (2) A collection of fields and groups that define and store the data for an InfoPath form. Controls in a form are bound to the fields and groups in the data sources of the form. and secondary data source. data source control An object that can be added to an ASP.NET Web page that encapsulates the necessary logic to connect to a data source, such as a database or XML file, and that can execute queries or other data-access commands. A data source control can in turn provide data to other controls on that page. data type A property of a field that defines the kinds of data that can be stored in the field. data validation The process of testing the accuracy of data; a set of rules that specify the type and range of data that users can enter. Data View Web Part A Web Part that is used to display items in a list. declarative workflow A workflow that is created with XAML (Extensible Application Markup Language) files and does not require precompiled code to run. declarative workflow association A code-free binding of a declarative workflow to a specific list or content type using XAML (Extensible Application Markup Language). default list view The view of a list that is defined by the owner of the list to appear when users browse to the list without specifying a view. default mobile list view The view of a list that is defined by the owner of the list to appear when users browse to the list from a mobile device without specifying a view. default search scope The search scope that is assigned automatically to a search scope display group. DefaultItemOpen A property of a document library that specifies whether the default click action causes the protocol server or the protocol client to open the document. defined name A word or string of characters in a formula that represents a cell, range of cells, formula, or constant value. deployment package A collection of files that represent a serialized snapshot of data. A deployment package is stored as XML files that describe the deployment objects and their relationships, and a binary file for each object. Optionally, the resulting set of files can be compressed into one or more files in the compressed PRIME data format (CMP). deployment system object An object that is created as part of a site or site collection. Examples of deployment system objects are root folders, catalogs, default pages, and galleries that are created during site or site collection creation. A deployment system object is not part of a template. descendant content type Any content type that inherits from another content type. descending order A sort order in which text strings are arranged in reverse alphabetical order, numerical values are arranged from largest to smallest, and dates and times are arranged from newest to oldest. distributed archive A document repository (usually large) that spans multiple site collections. distribution list A collection of users, computers, contacts, or other groups that is used only for e-mail distribution, and addressed as a single recipient. Document Center A document library template that is preconfigured to store a large quantity of documents. document library A type of list that is a container for documents and folders. document workspace A document repository that enables users to collaborate on one or more documents. Document Workspace site A SharePoint site that is based on a Document Workspace site template and has a template identifier of 1. A Document Workspace site is used for planning, posting, and working together on a document or a set of related documents. duplicate A search result that is identified as having identical or near identical content. duplicate result removal An operation to compare the similarity of items and remove duplicates from search results. dynamic rank A component of the rank that depends on how well query text matches an indexed item. E   endpoint A consumer in a Web Part connection that receives data from a provider, used in connections for PerformancePoint Web Parts. Entity A type of DataClass that represents a type of business data object that is stored in a line-of-business (LOB) system and whose instances have a persistent EntityInstanceId. EntityInstance A set of Field values that have a unique identity that represents a particular instance of an Entity, and are stored in a line-of-business (LOB) system. EntityInstanceId A set of Field values of an EntityInstance that collectively and uniquely identify an EntityInstance in a line-of-business (LOB) system. excluded item An item that is excluded from a crawl by the administrator of the host site or the search administrator of the crawler. external content type A reusable collection of metadata that defines a set of data from one or more external data sources, the operations avaialble on that data, and connectivity information related to that data. external content type layout One or more Microsoft Office External Data Parts arranged in a one-dimensional or two-dimensional way to display information to a user. Typically used to show data in Microsoft Outlook task panes. external data Data that is stored in a repository outside a workbook. external data column A single field in an item of an external content type. external data grid A Web Part that displays a list of external items from a business application registered in the BDC metadata store. For example, you can use a Business Data List Web Part to display the customers or orders from a database such as the AdventureWorks database. external data item A single item in an external list. External Data Part A Windows Forms control that shows details of a single item or a list of items that belong to an external content type. external data related list Displays a list of related external items from a business application. For example, you can use a Business Data Related List Web Part to display all the orders for a particular customer from the AdventureWorks database. external item content control External data from an External Data column in a SharePoint document library that is made available as a content control in Word 2010 through Microsoft Business Connectivity Services. The content control also provides picking and resolving capabilities. External data that is exposed in content controls is read-only. external list A list of items of an external content type. external reference A reference to a cell, range, defined name, or other object in another worksheet or workbook. External System A supported source of data that can be modeled by Business Connectivity Services, such as a database, Web service, or custom .NET Framework assembly. external workbook A workbook, other than the active workbook, that is on disk or in memory and to which a dependency is implied or intended. extracted definition The definition that is obtained by an index server during a crawl, to identify if any sentences in the item match the pattern for defining a term. extracted term A term that an extracted definition applies to. F   Farm Administrators group A group of users that has permission to manage all of the servers in a server farm. Members of the Farm Administrators group can perform command-line operations and all of the administrative tasks in Central Administration for the server or server farm. farm solution A custom solution that can be deployed to a farm by a farm administrator. A farm solution has full access to system resources and other sites in the farm. feature A package of Windows SharePoint Services elements that can be activated or deactivated for a specific feature scope. feature definition An XML fragment that defines a feature and its attributes. feature identifier A GUID that identifies a feature. feature property A property that is associated with an active feature at a particular scope. feature scope The scope at which a feature can be activated. federated location A source that returns search results for a given query. The source can be the local search catalog or an Opensearch1.0/1.1-compliant search engine. federated location definition The configuration settings that describe how to issue a query for a given federated location and display the search results. federation The ability to issue a query to multiple federated locations described by federated location definitions and to return the results in a single search results page. Field The data elements that constitute an Entity in a line-of-business (LOB) system. field internal name A string that uniquely identifies a field in a content type or a SharePoint list. FilterDescriptor A type of MetadataObject that describes a normalized way of gathering input from a user. FilterDescriptors are defined by their type and the Method that contains them. first class object (FCO) A top-level object for building dashboards in PerformancePoint Services. Types of FCO are dashboards, scorecards, reports, filters, KPIs, indicators, and data sources. FCOs are stored as content types in SharePoint lists and document libraries. They have common attributes such as name, description, person responsible, custom properties, and in some cases, versioning or history. first-stage Recycle Bin A container for items that are deleted. Items in this container are visible to users with the appropriate permissions and to site collection administrators. formula A logical equation or function that produces a result in a spreadsheet application. formula bar A user interface element that appears at the top of a worksheet and that is used to display and edit cell content. front-end Web server A server that hosts Web pages, performs processing tasks, and accepts requests from protocol clients and sends them to the appropriate back-end server for further processing. full crawl A crawl process that indexes all items in a given content source whether or not the item was modified. full-text index catalog A collection of full-text index components and other files that are organized in a specific directory structure and contain the data that is needed to perform queries. full-text index component A set of files that contain all index keys that are extracted from a set of items. full-text index propagation The process of propagating of one full-text index component. function A code module that takes a value as input, performs an operation, and returns the results to the worksheet. G   gallery A library that is used to store a collection of site resources, such as Web Parts, list templates, or site templates. generic list A list whose base type is Generic List. ghosted The condition of a document whose content is stored in a location other than the content database. If a document is ghosted, the front-end Web server determines the location of the content by using the SetupPath value for the document. global term set A term set that is created by using the term store management tool. graph object An object that represents a chart and the datasheet that contains the data for the chart. Group Approval document identifier A string that uniquely identifies a document that is subject to the policies defined for a Group Approval workflow. The string is generated and assigned automatically to a document by a protocol server. H   hidden cell A cell that no longer appears in a worksheet view because it is contained within a hidden row or a hidden column. hidden column A column that does not appear in a worksheet view because its width is set to zero (0). A column can be hidden if an outline is collapsed. hidden row A row that does not appear in a worksheet view because its height is set to zero (0). A row can be hidden if a user is filtering or if an outline is collapsed. high confidence property A managed property from the metadata index that the administrator identifies as a good indicator of a highly relevant item. It is used to produce a high confidence result. high confidence results A subset of search results that are considered to be highly relevant because of a precise match between a high confidence property value and the tokens in the query text. hit highlighted summary A summary that appears on the search results page for each query result. This summary contains an excerpt from the item where the query text is present and highlighted. horizontal alignment A formatting setting that specifies how content is positioned within the horizontal space of a cell, object, or page. Content can be aligned along the left or right edge, or distributed evenly across the horizontal space. host depth The number of allowable host hops for a content source. host hop The process of traversing to a server with a different host name during a crawl. I   Identifier The Field or Fields that define the Identity of an EntityInstance. Also referred to as Key. IdEnumerator A type of MethodInstance that can be called to return the Field values that represent the identity of EntityInstances of a specific Entity. IdEnumerator input is defined by the FilterDescriptors that are contained in the Method that contains the IdEnumerator. incremental crawl A crawl process that includes logic to index only a subset of the items in the content source that is crawled based on item modifications. index server A server that has been assigned the task of crawling. initiator An actor who starts an action instance. inverted index For each token that is encountered in a corpus of indexed items, a data structure that stores a list of postings that identify which documents matched and a list of occurrences that identify which position in each document. item identifier An integer that uniquely identifies an item in a SharePoint list. J   job definition A persistent container that defines and stores instructions for a job to be run on a server, server farm, or server cluster. To run, a job must have an associated job definition, and a definition must be associated with a service or a Web application. K   key performance indicator (KPI) A predefined measure that is used to track performance against a strategic goal, objective, plan, initiative, or business process. A visual cue is frequently used to communicate performance against the measure. keyword One or more words or phrases that site administrators identified as important. A keyword provides a way to display best bets and definitions on a search results page. keyword consumer A site collection that uses a particular set of keywords, synonyms, and best bets. keyword consumer group A collection of keyword consumers. keyword synonym An alternate phrasing of a particular keyword. When a user types a keyword synonym, search returns the same best bet result as the keyword. L   language auto-detection A process that automatically determines the language code identifier (LCID) for text in a document. language pack A collection of binaries that can be installed on top of a core product and enables users to select a specific language for displaying the user interface and Help content. LDAP See Lightweight Directory Access Protocol (LDAP). line chart A type of chart in which data points in a series are connected by a line. line-of-business (LOB) system A software system that is used to store business data and can also contain business rules and logic that support business processes. list (1) A container within a SharePoint site that stores list items. A list has a customizable schema that is composed of one or more fields. (2) An organization of a region of cells into a tabular structure in a workbook. list column See field (2). list folder A folder that is contained within a SharePoint list. A list folder can contain documents or list items, and it retains the characteristics of other items in the list, such as a customizable schema. list form A page that allows users to create, view, or edit an item in a list. List Form Web Part A Web Part that is used to display, edit, or view an item in a list. list identifier A GUID that is used to identify a list in a site collection. list item An individual entry within a SharePoint list. Each list item has a schema that maps to fields in the list that contains the item, depending on the content type of the item. list item attachment A file contained within a list item that is stored in a folder in the list with the segment “Attachments.” list item identifier See item identifier. list level A condition of a paragraph that specifies which numbering system and indentation to use, relative to other paragraphs in a bulleted or numbered list. list schema The Collaborative Application Markup Language (CAML) schema of a list. list server template A value that identifies the template that is used for a list. list template An XML-based definition of list settings, including fields and views, and optionally list items. List templates are stored in .stp files in the content database. list template identifier A GUID that is used to identify a list template. list view A named collection of settings for querying and displaying items in a SharePoint list. There are two types of views: Personal, which can be used only by the user who creates them; and Public, which can be used by all users who have access to the site. list view page A Web Part Page that displays a view of a list. List View Web Part A reusable component that generates HTML-based views of items in a SharePoint list. LobSystem A type of MetadataObject that represents a specific version of a line-of business (LOB) system. A LOB system can be a database or a Web service. LobSystemInstance A type of MetadataObject that represents a specific deployed instance of a line-of-business (LOB) system, as represented by a LobSystem. LobSystemInstances are contained by LobSystems. LobSystemInstance Properties describe how to connect to an instance of the LobSystem that contains them by providing information such as the server name, connection string, and authentication mode. local term set A term set that is created when a user defines a column. localized name The descriptive name of a MetadataObject for a specific locale. logged search query The query text, search scopes, and contextual scope in which a query was executed. login name A string that is used to identify a user or entity to an operating system, directory service, or distributed system. For example, in Windows® integrated authentication, a login name uses the form “DOMAINusername.” lookup field A field of the Lookup type that allows a user to select an item from another data source. M   major version An iteration of a software component, document, or list item that is ready for a larger group to see, or has changed significantly since the previous major version. For an item on a SharePoint site, the minor version is always zero for a major version. managed keyword A word or phrase that is added to a SharePoint item, either as a value in the Managed Keyword column or as a social tag. managed metadata A hierarchical collection of centrally managed terms that you can define, and then use as attributes for SharePoint items. managed metadata connection A connection to a managed metadata service that allows sites within a Web application to access the service’s term store and, optionally, content types. managed metadata service A shared service that publishes a term store and, optionally, a set of content types. managed property A specific property in the metadata schema that can be made available for queries from the user experience. managed property alias An alternate name for a managed property. managed term A word or a phrase that can be associated with a SharePoint item . Managed terms, are usually predefined, can be created only by users with the appropriate permissions, and are often organized into a hierarchy. Also called “term” where “managed” is clear from the context. mapping order An integer value that defines the order in which crawl properties are mapped to managed properties. The value of a mapping order is unique for each managed property; no two mappings for the same managed property have the same mapping order value. master secret A key that is used to symmetrically encrypt and decrypt credentials and single sign-on (SSO) tickets. master secret server A protocol server that stores and can provide a master secret in response to a request from a protocol client. meeting instance A collection of data for a meeting that occurs only once or a single occurrence of a meeting that occurs multiple times. The data can be stored in a client application or on a Web site. Meeting Workspace site A SharePoint site that is based on a Meeting Workspace site template and has a template ID of 2. A Meeting Workspace site is used for planning, posting, and working together on meeting materials. member (1) A user in the Members group of a site. (2) An identity that belongs to a PRODUCTNAME:[grv2007] shared space. (3) See OLAP member. member group A group of users that is specific to the user profile service. Examples of types of member groups are distribution lists, security groups, and SharePoint sites. A member group contains metadata such as the group name, e-mail address, URL, and the list of members. member group source A qualified domain name, such as domain.corp.microsoft.com, that identifies the source of a member group. Members group A default group of users on a SharePoint site. By default, the Members group is assigned the Contribute permission level. membership The state or status of being a member of a member group. A membership contains additional metadata such as the privacy level that is associated with the membership. membership group See group (2). membership group record identifier A unique identifier for a member group record. metadata index A data structure on a back-end database server that stores properties that are associated with each item, and attributes of those properties. metadata model A collection of semantically-related MetadataObjects that define how to interact with a specific line-of-business (LOB) system. metadata schema A schema that is used to manage information about an item. metadata store A database that is stored on a back-end database server and contains all stored procedures and storage for the MetadataObject types. MetadataObject An abstract data structure that consists of a set of attributes that represent a LobSystem, LobSystemInstance, DataClass, Entity, Method, MethodInstance, Parameter, TypeDescriptor, Identifier, FilterDescriptor, Action, ActionParameter, or Association. MetadataObjectId An attribute that uniquely identifies a MetadataObject that is stored in a metadata store. Method A type of MetadataObject that represents a piece of executable business logic in a line-of-business (LOB) system. Methods are contained by DataClasses and they contain Parameters. MethodInstance A type of MetadataObject that associates a normalized or stereotypical semantic with a Method, and identifies what part of the data that is returned by a Method is relevant for a particular semantic. MethodInstances are contained by Methods. Microsoft Business Connectivity Services The set of Office client and server services that enables the development of solutions with deep integration of external data and services. minor version An iteration of a software component, document, or list item that is in progress or has changed only slightly from the previous version. For an item on a SharePoint site, the minor version number is never zero and is incremented for each new version of an item, unless a major version is explicitly published. When minor versioning is disabled on a SharePoint site, only major version numbers are incremented, and the minor version is always zero. Model A collection of MetadataObjects that describes a line-of-business (LOB) system. It provides a framework for converting operations that are requested by a protocol client into requests that are specific to a given LOB system. moderated object An object for which a moderator reviews and either approves or rejects additions or changes to that object. New objects and changes to existing objects can be seen by other users only after they have been approved by the moderator. moderation status A content approval status of an item in a list. multivalue property A property that can contain multiple values of the same variant type. N   named object A list, PivotTable® report, chart, or range that can be referenced by name. A sheet is not a type of named object. named object view A mode in which only named objects are rendered. named range See defined name. native PivotTable A PivotTable® report that is populated with data from a worksheet in the same workbook. natural language query Query text that contains words and does not contain any property restrictions. navigation node An element in the navigation structure of a site. The element is a link, or series of links, to a specific page in the site. navigation structure A hierarchical organization of links between related content, such as lists within a site. new form A form that allows for the creation of a list item. noise word A functional token that carries no meaning by itself, like “and”, “or”, “for”, or “a.” A noise word is usually short, and varies from language to language. O   ODBC See Open Database Connectivity (ODBC). Office data connection (ODC) file A file that stores information about a connection to a data source, such as an Access® database, worksheet, or text file. This file facilitates data source administration. Office SharePoint Server Search service The farm-wide service that either responds to query requests from front-end Web servers or crawls items. OLAP See Online Analytical Processing (OLAP). Online Analytical Processing (OLAP) A technology that uses multidimensional structures to provide access to data for analysis. The source data for OLAP is stored in data warehouses in a relational database. Open Database Connectivity (ODBC) A standard software API method for accessing data that is stored in a variety of proprietary personal computer, minicomputer, and mainframe databases. It is an implementation of TSQL-CLI-2003 and provides extensions to that standard. Open Item permission An authorization that allows a user to retrieve an entire file. Open Web permission A requisite permission during the import or export of a SharePoint site. operator account The account of the user who is managing the import process for a deployment package. organization A security group that contains additional fields for describing hierarchical relationships between organizations. organization identifier An integer that uniquely identifies an organization. orphaned object A content database object that lacks a requisite relationship to a corresponding object. owner A security principal who has the requisite permissions to a security group. P   page A file consisting of HTML that can include references to graphics, scripts, or dynamic content such as Web Parts. page hop A process of traversing from one item to another during a crawl. page layout A dynamic Web template that is stored as a document. It contains content placeholders that bind to fields of a publishing page. A page layout has an associated content type that determines which publishing pages it can be bound to. paged view A view that supports one or more visual pages. A paged view is used to break up large sets of data into smaller sets for increased performance and manageability. Parameter A type of MetadataObject that represents the formal parameters of a piece of business logic in a line-of-business (LOB) system. Parameters have a single root TypeDescriptor that defines the structure of the Parameter. They also have a Direction and a TypeReflector. Parameters are contained by Methods. parameterized query A query that contains parameters. It applies to Open Database Connectivity (ODBC) and Web queries. For example, a Web query that retrieves stock quotes from a Web page can prompt the user for a parameter, such as a stock symbol. parent farm A farm that crawls content from another farm and also responds to query requests from that farm. parent list A list that contains a list item or list folder. parent site The site that is above the current site in the hierarchy of the site collection. PerformancePoint Content List A list that stores the elements that are used to construct a PerformancePoint dashboard. A PerformancePoint dashboard is a related group of interactive scorecards, filters, and report views that are organized together into a set of Web pages. PerformancePoint Data Connections Library A SharePoint document library that may contain Office Data Connections (ODC), Universal Data Connection (UDC) files, and PerformancePoint data connections. Data connections identify a source of business data that may include cubes or perspectives that are based on online analytical processing (OLAP) cubes, relational databases, CSV files, Microsoft Excel Services spreadsheets, or other data sources. permission A rule that is associated with an object to regulate which users can gain access to the object and in what manner. permission level A set of permissions that can be granted to principals or SharePoint groups on an entity such as a site, list, folder, item, or document. personal site A type of SharePoint site that is used by an individual user for personal productivity. The site appears to the user as My Site. PivotChart filter pane A user interface element that displays a list of active fields in a PivotChart® view and is used to apply filters to those fields. PivotChart report A chart that uses a PivotCache for source data and inherits filtering and sorting functionality from a PivotTable® report. PivotTable data field A PivotTable® field that is in the PivotTable area where the data values are shown. PivotTable field list A user interface element that displays a list of all PivotTable® fields. A PivotTable field list can be used to populate a PivotTable report and to manipulate the fields. PivotTable filter parameter The value that a filter on a PivotTable® report is set to, which indicates that matching values are included in the result set. PivotTable item A single member of a PivotTable® field. PivotTable member An individual data item within a specific dimension as it is displayed in a PivotTable® report. For example, a member in the Geography dimension might be North America. portal content The main search catalog, which contains content sources and settings that are related to a crawl. portal site A type of SharePoint site that can act as an umbrella to other sites and that can be used by a large organization. postback A process in which a Web page sends data back to the server that hosts the page. privacy level A setting that specifies the category of users who are allowed to view the personal information of other users, such as user profile properties, colleagues, or memberships. profile page A profile page displays the data for an item of an external content type. propagation share A share that is located on a query server and whose purpose is to allow files to be copied to it by an indexer. Property A typed name/value pair that is associated with a MetadataObject. Properties enable consumers of a protocol client to annotate or decorate the MetadataObject with consumer-specific extensions. A MetadataObject can contain multiple Properties. property bag A container that stores data but is not defined in the schema for a SharePoint list. Instead of interpreting data in a property bag, the server only passes the data in response to requests. protocol A URL Scheme, as specified in RFC1738, specific values of which can be unique to Microsoft® SharePoint® Products and Technologies. provision The process of creating and deploying an object, and in some cases, populating an object with default data and settings. provisioned A condition of an object that was created and deployed successfully. publish to server A process that facilitates saving a document or portions of a document to a Web server. published A condition of portions of a workbook that are marked as being available to the user when that workbook is processed by a protocol server. published item A specific named object in a workbook that is published. published items snapshot A snapshot that contains only the published items or published sheets from a workbook. When no published items are defined, the snapshot contains the entire workbook. published range A specific type of published item that represents a range of cells. published sheet A sheet that is published. published version The version of a list item that is approved and can be seen by all users. The user interface (UI) version number for a published version is incremented to the next positive major version number and the minor version is zero. and minor version. publishing level An integer that is assigned to a document to indicate the publishing status of that version of the document. publishing page A document that binds to a page layout to generate an HTML page for display to a reader. Publishing pages have specific fields that contain the content that is displayed in an HTML page. Q   query independent rank A system to rank items that uses features that do not vary with different queries. query logging The process of recording information about user searches, such as search terms and time of access. query result A result for a given query, which contains the title and URL of the item, and can also contain other managed properties and a hit-highlighted summary. query server A server that has been assigned the task of fulfilling search queries. query table A two-dimensional table that presents data from an external data source. query text The textual string portion of a query. Frequently, a user enters query text, but it can be programmatically amended and is not guaranteed to be exactly what the user typed. R   range An addressable region in a workbook. Typically a range consists of zero or more cells, usually representing a single, contiguous rectangle of cells on a single sheet. rank An integer that represents the relevance of a particular item for a search query. Rank is a combination of static rank and dynamic rank. and dynamic rank. ranking parameter A value that is used to influence the algorithm that determines the rank of an item. recalculate The process of computing a value in a workbook by initiating a calculation repeatedly. record A group of related fields, sometimes referred to as columns, of information that are treated as a unit. Also referred to as row. reference (1) A link in a project to another project, a .NET Framework assembly, or a compatible Component Object Model (COM) library. Adding a reference to a project allows the use of the referenced item in a project, but does not copy it to the current project folder. (2) A means of accessing a variable, such as an element in an array or a field in a record. (3) The means by which cells, objects, and chart elements are referred to in formulas. reference style A system for specifying cells or ranges of cells and that is used in formulas. A reference style is used to specify a specific cell in a two-dimensional table by identifying the row and column that contain that cell or range of cells. refresh A process that retrieves values from a data source and populates a workbook with those values. register directive An element of markup in a page that defines a relationship between binary files on the server that implements Web Parts and Web controls. The register directive also serves as the namespace of the markup in the Web Part Page that will refer to those binary files. relative path A path that is implied by the current working directory or is calculated based on a specified directory. When a user enters a command that refers to a file and the full path is not entered, the current working directory becomes the relative path of the referenced file. relative reference A reference to a location on a sheet that is relative to the cell containing the reference. A relative reference can be stored as a cell reference or as an offset. relevant result A search result that is relevant to a query term based on rank. By default, the higher the rank, the higher the item appears in the query results. reranking An event in which various statistics are calculated and recorded in the main catalog. restriction A set of conditions that an item meets to be included in the search results that are returned by the query server in response to a search query. result position An integer that identifies the relative location of a relevant result within a search results page. The first relevant result has a result position of 1, the second has 2, the 11th has 11, and so on. ReturnTypeDescriptor An attribute of a MethodInstance. It is the TypeDescriptor that identifies the portion of a Method return or output Parameters to extract and return to the user executing the MethodInstance. It defines the View of the EntityInstances returned. role assignment An association between a principal or a site group and a role definition. role definition A named set of permissions for a SharePoint site. role identifier An integer that uniquely identifies a role definition within a site. role type A predefined role definition. Typical role type values include: Guest, Reader, and Administrator. root document A document in the root folder of a site. root element The top-level element in an XML document that contains all other elements and is not contained by any other element, as specified in XML. root folder The folder at the top of the hierarchy of folders in a list. root TypeDescriptor A TypeDescriptor that is contained by a Parameter and has no parent TypeDescriptor. A Parameter can contain only one root TypeDescriptor. row (1) A collection of columns that contains the property values that describe a single item from the set of items that match the restriction specified in the search query that was submitted to the query server. (2) A single set of data that is displayed horizontally in a worksheet. S   sandboxed solution A custom solution that can be deployed to a site by a site collection administrator, without approval from the farm administrator. Without that approval, the solution has full access to the immediate site and restricted access to system resources and other sites. scheduled A status that is applied to a list item or document that specifies a time when the item or document will be published or unpublished. schema version An integer value that represents the version number of the schema for a deployment package. SchemaVersion An integer value that represents the version number of the schema for replicated profile data. scope identifier A GUID that uniquely identifies a scope within a site collection. search application A unique group of search settings that is associated, one-to-one, with a shared service provider. search catalog All of the crawl data that is associated with a given search application. A search catalog provides information that is used to generate query results. search database A database that stores search-related information, including stored procedures and tables that are used for crawler data, document metadata, and administration information. search query A complete set of conditions that are used to generate search results, including query text, sort order, and ranking parameters. search query log A record of information about user searches, such as search terms and time of access. search query log report A report that is generated from query log information. For example, a search query log report might include the number of queries that were executed every day over the past thirty days. search scope A list of attributes that define a collection of items. search scope compilation The process of updating a full-text index catalog to reflect unincorporated changes to the definitions of search scopes. search scope consumer A site collection that uses a particular search scope display group. search scope consumer group A collection of scope consumers. search scope display group An ordered set of search scopes, defined by an administrator or programmatically, and used for returning groups of search scopes. Search scope display groups are saved for each search scope consumer and search scopes can be in multiple search scope display groups. search scope index A specialized component of a full-text index catalog that is built on the values of scoped properties for optimized queries. search scope rule An attribute that specifies which items are included in a given search scope. search scope rule value A user-specified string that is associated with a search scope rule. It is used to determine membership of an item in the associated search scope. search scopes system All of the global settings of search scopes and search scope compilation. search security descriptor (1) A Windows® security descriptor. (2) A custom security descriptor that is in an arbitrary format and is handled by alternate authentication providers that are used in pluggable security authentication. search service account A user account under which the search service runs. search service instance An object that represents the specifications of the search service on one particular server. search shared application object An instance of a shared application for search that holds search-specific settings. second-stage Recycle Bin A container for items that have been deleted from a first-stage Recycle Bin. Items in a second-stage Recycle Bin are visible only to site collection administrators. secret key A symmetric encryption key shared by two entities, such as between a user and the domain controller (DC), with a long lifetime. A password is a common example of a secret key. When used in a context that implies Kerberos only, a principal’s secret key. Secure Store A user authentication process that enables a user or group of users to enter a user name and password to access multiple applciations. Secure Store Service A shared service that securely stores credential sets for external data sources and associates those credential sets to identities of individuals or to group identities. security descriptor A data structure containing the security information that is associated with a securable object. A security descriptor identifies an object’s owner by security identifier (SID). security group A named group of principals on a SharePoint site. security group identifier An integer that uniquely identifies a security group from all other security principals and site groups within the same site collection. security identifier (SID) An identifier for security principals in Windows that is used to identify an account. Conceptually, the SID is composed of an account authority portion (typically a domain) and a smaller integer representing an identity relative to the account authority, termed the reference identifier (RID). The SID data type is defined in [MS-DTYP] section 2.4.2. For more information, see [MS-SECO]. security policy In the form of a collection of security policy settings, the policy itself is an expression of administrative intent regarding how computers and resources on their network should be secured. security principal (1) A unique entity that is identifiable through cryptographic means by at least one key. It frequently corresponds to a human user, but also can be a service that offers a resource to other security principals. Also referred to as principal. (2) An identity that can be used to regulate access to resources. A security principal can be a user, a computer, or a group that represents a set of users. security principal name (SPN) The name identifying a security principal (for example, machinename$@domainname for a machine joined to a domain or username@domainname for a user). Domainname is resolved using the Domain Name System (DNS). session identifier (1) A unique string that is used to identify a specific instance of session data and is used by stored procedures as an opaque primary key. (2) A key that allows an application to make reference to a session. session view The rendering of the contents of a workbook that are associated with a particular session. Shared Documents library A document library that is included by default in the Team Site site template. shared view A view of a list or Web Part Page that every user who has the appropriate permissions can see. shared workbook A workbook that is configured to allow multiple users on a network to view and make changes at the same time. Each user who saves the workbook sees the changes that are made by other users. SharePoint Search SQL syntax The rules that govern the construction of an enterprise search SQL query. sheet (1) A part of a Microsoft® Office Excel® workbook. There are four types of sheets: worksheet, macro sheet, dialog sheet, and chart sheet. Multiple sheets are stored together within a workbook. (2) A worksheet. Because worksheets are the most common type of sheet, the term sheet frequently refers to a worksheet. sheet tab A control that is used to select a sheet. sheet view A collection of display settings, such as which cells are shown, and the zoom level for a sheet window. sibling navigation node A navigation node that shares a common parent navigation node with another specified navigation node. single sign-on (SSO) A process that enables users who have a domain account to log on to a network and gain access to any computer or resource in the domain without entering their credentials multiple times. single sign-on (SSO) administrator A security principal who is authorized to change a single sign-on (SSO) configuration and obtain master secrets from a master secret server. single sign-on (SSO) identifier A string that represents the definition of user credentials that allow a user to access a network. single sign-on (SSO) system A software-based implementation that enables users to gain access to multiple resources without entering their credentials multiple times. single sign-on (SSO) ticket A token that contains the encrypted identity of a single sign-on (SSO) user in the form of a security identifier string and a nonce. site collection A set of Web sites that are in the same content database, have the same owner, and share administration settings. A site collection can be identified by a GUID or the URL of the top-level site for the site collection. Each site collection contains a top-level site, can contain one or more subsites, and can have a shared navigation structure. site collection administrator A user who has administrative permissions for a site collection. site collection flag A 4-byte unsigned integer bit mask that specifies the properties that are global to a site collection. One or more values can be set for this bit mask. site collection identifier A GUID that identifies a site collection. In stored procedures, the identifier is typically @SiteId or @WebSiteId. In databases, the identifier is typically SiteId/tp_SiteId. site collection quota An option for a site collection that allows administrators to set levels for maximum storage allowed, maximum number of users allowed, and warnings that are associated with the maximum levels. site column A field that can be associated with a content type or list within a site or site collection. site content type A named and uniquely identifiable collection of settings and fields that store metadata for lists within individual sites. site definition A family of site definition configurations. Each site definition specifies a name and contains a list of the site definition configurations. site definition configuration An XML-based definition of lists, features, modules, and other data, that collectively define a type of SharePoint site. Site definition configurations are stored in the ONET.xml file. site definition version A zero-based integer that indicates the version number of the site definition. Every time a site definition is updated, it is suggested that the version number be increased. site flag A 4-byte unsigned integer bit mask that specifies properties that are unique to a site. site identifier A GUID that is used to identify a site in a SharePoint site collection. site membership The status of being a member of a site and having a defined set of user rights for accessing or managing content on that site. site property A name/value pair of strings that serves as metadata for a site, such as the title or default language. site solution A deployable, reusable package that contains a set of features, site definitions, and assemblies that apply to sites, and that can be enabled or disabled individually. snapshot A copy of a workbook that contains only values and formatting. It does not contain any formulas or data connections. sort A process that arranges cells in ascending or descending order, based on cell content. sort order (1) A set of rules in a search query that defines the order of relevant results. Each rule consists of a managed property, such as modified date or size, and a direction for order, such as ascending or descending. Multiple rules are applied sequentially. (2) A specific arrangement of cells that is based on cell content. The order can be ascending or descending. source data The data that is used as the basis for charts, PivotTable® reports, and other data visualization features. SpecificFinder A type of MethodInstance that can be called to return a specific EntityInstance of a specific Entity given its EntityInstanceId. SpecificFinder input is defined and ordered by the Identifiers that are associated with the Entity that is associated with the Method that is associated with the SpecificFinder. start address A URL that identifies a point at which to start a crawl. Administrators specify start addresses when they create or edit a content source. static rank The component of a rank that does not depend on the search query. It represents the perceived importance of an item and may be related to the origin of the item and relationships between the item and other items or business rules that are defined in the search application. stop word A word that tends to appear frequently in documents and carries no usable information. stop word list A specific collection of so-called stopwords, which tend to appear frequently in documents, but are believed to carry no usable information. subsite A complete Web site that is stored in a named subdirectory of another Web site. The parent Web site can be the top-level site of a site collection or another subsite. Also referred to as subweb. subtotal column A column that uses a summary or subtotal function to display the total of detail items in a PivotTable® field. subtotal row A row that uses a summary or subtotal function to display the total of detail items in a PivotTable® field. T   table A list that is defined in a workbook. table header The top row of a table, where the column names are displayed. table style A set of formatting options, such as font, border style, and row banding, that are applied to a table. The regions of a table, such as the header row, header column, and data area, can be variously formatted. term set A collection of related terms. For example, the term set named “milestone” could include the terms “M0” “M1” “M2” “Alpha” “Beta1” “Beta2” “RC1” “RC2” and “RTM.” term store A database that stores managed metadata, including term sets, terms, and managed keywords. timer job A built-in Windows® SharePoint® Services object that can perform various tasks within the environment on a scheduled or one-time event basis. token A word or number in a crawled item or a search query. A token translates into a meaningful word, such as a linguistic unit, because the definition differs between languages. Examples include cat, AB14, or 42, but do not include white space. top-level site The first site in a site collection. All other sites within a site collection are children of the top-level site. The URL of the top-level site is also the URL of the site collection. total row A row in a list or table that provides a selection of aggregate functions that are useful for working with numerical data. trusted authentication A mechanism whereby a user account or a process account can be used to perform operations on behalf of the current user. trusted subsystem A method of communication in which two-way trust is established between two server components. Each server component communicates with the other component by using an account that is authorized to perform privileged actions such as retrieving files and settings. TypeDescriptor A type of MetadataObject that describes a subset of the structure of a Parameter to be used as a piece of business logic in a line-of-business (LOB) system. TypeDescriptors can contain other TypeDescriptors. TypeReflector A unit of business logic that converts data structures between the type system of the protocol client and the native type system of a line-of-business (LOB) system. U   UI culture The language that is used to display strings and other graphical elements in a user interface. unghosted (1) A document that has its content stored in the content database instead of the front-end file system. (2) A column or content type for which the schema is stored in the database instead of the front-end file system. user activity status A one (1) or zero (0) indicator that shows whether a user is active or inactive. If a user modifies a list item, 1 indicates that the user is active. If a user never modifies a list item, 0 indicates that the user is inactive. user display name A user profile property that can contain the preferred name of a user. user profile A collection of properties that pertain to a specific person or entity within a portal site. user profile change entry log A repository that logs all of the changes that take place in a user profile. user profile change event An event that occurs when a property of any user profile is changed. user profile import The process of importing records from a directory service to the user profile store. user profile policy A subset of the user profile privacy policy that governs interactions with user profiles. user profile privacy policy A set of rules that governs all interactions with user profiles. user profile record identifier An integer that uniquely identifies a user profile record. user profile service A data source that stores, provides, and applies information about users. user profile store A database that stores information about each user profile. user solution See Other Term: sandboxed solution UserContextFilter A FilterDescriptor type that is used while querying a line-of-business (LOB) system. Its value can be set automatically by a protocol client to the identity of the user who is calling the LOB system. This value can then be used by the LOB system to authorize and then filter the results returned. user-defined function (UDF) A function that is coded in a PRODUCTNAME:[vba] module, macro sheet, add-in, or XLL (Excel Linked Library). A UDF can be used in formulas to return values to a worksheet, much like built-in functions. UsernameCredentialFilter A FilterDescriptor type that is used while querying a line-of-business (LOB) system and can hold the user name of an account that is defined in that system. When used in conjunction with PasswordCredentialFilter, the LOB system can use its value to restrict access to data. UserProfileFilter A FilterDescriptor type that is used while querying a line-of-business (LOB) system and whose value can be obtained by examining the current user’s profile. The LOB system can use its value to filter the results returned. V   vertical alignment A formatting setting that specifies how content is positioned within the vertical space of a cell, object, or page. Content can be aligned along the top or bottom edge, or distributed evenly across the vertical space. ViewAccessor A type of MethodInstance that can be called to return a different View for a given EntityInstance of a particular Entity, without changing the EntityInstanceId of the EntityInstance. viewport A virtual window, used for controls that display content, through which all or part of the content is visible. A viewport is typically used to display a particular portion of content when all of the content will not fit in the available display space. virus scanner Software that is used to search for and remove computer viruses, worms, and Trojan horses. visible scope A search scope that is displayed to site collection administrators and users. Visitors group A default group of users on a SharePoint site. By default, the Visitors group is assigned the Read permission level. W   Web application (1) A container in a configuration database that stores administrative settings and entry-point URLs for site collections. (2) A software application that uses HTTP as its core communication protocol and delivers information to the user by using Web-based languages such as HTML and XML. Web application identifier A GUID that identifies a Web application. Web control A server-side component that encapsulates user interface and related functionality. Web discussion A component and add-in that allow users to enter comments about documents and pages without modifying actual content. Web discussion comment An individual comment that is added within a Web discussion. Web identifier See site identifier. Web Part A reusable component that contains or generates Web-based content such as XML, HTML, and scripting code. It has a standard property schema and displays that content in a cohesive unit on a Web page. Web Part cache A hash table of key/value pairs that is used to cache and locate internal information for Web Parts. Web Part chrome The common user interface elements that frame a Web Part within a given zone. The Web Part chrome includes a border, a title bar, and the icons, title text, and verbs menu that appear within the title bar. Web Part chrome state The condition of a Web Part and the Web Part chrome surrounding it. Possible values are zero (0) for normal state or one (1) for minimized state. Web Part connection An element in a Web Parts page that defines a provider-consumer data relationship between two Web Parts. When a Web Parts page is rendered, data provided by one Web Part can affect how and what is rendered by the other Web Part. Web Part identifier A GUID that identifies a Web Part. Web Part property A configurable characteristic of a Web Part that determines the behavior of the Web Part. Web Part type identifier A unique 16-byte value that is assigned to each Web Part type. Web Part zone A structured HTML section of a Web Part Page that contains zero or more Web Parts and can be configured to control the organization and format of those Web Parts. Web Part zone identifier A string that identifies a Web Part zone on a Web Parts page. Web Part zone index An integer that specifies the relative position of a Web Part in a Web Part zone. Web Parts are positioned from the smallest to the largest zone index. If two or more Web Parts have the same zone index, they are positioned adjacent to each other in an undefined order. Web Parts page An ASP.NET Web page that includes Web Part controls that enable users to customize the page, such as specifying the information that they want to display. Web query An external data connection that retrieves a table from a Web site and inserts table data into a workbook. Web service method A procedure that is exposed to Web service clients as an operation that can be called on the Web service. Also referred to as Web method. WebDAV (Web Distributed Authoring and Versioning Protocol) The Web Distributed Authoring and Versioning Protocol, as specified in RFC2518. work item An object that represents an operation that is scheduled to run at or after a specific time. work item process A process that runs a work item. work item type A named definition that indicates what a work item does. work item type identifier A GUID that is used to identify a work item type. workbook A container for a collection of sheets (1). workbook file A file that contains a byte stream representation of a workbook. workbook object An object that is associated with a workbook. workbook parameter A single cell that is designated to receive input from a user. workbook view A set of display settings, such as the height and width, for the windows in a workbook. workflow (1) The automation of business processes, where business documents and tasks are passed automatically from one user to another for action, according to a set sequence. (2) A structured modular component that enables the automated movement of documents or items through a specific sequence of actions or tasks that are related to built-in or user-defined business processes. workflow association An association of a workflow template to a specific list or content type. workflow condition A logical “if-then” statement that defines a specific situation in a workflow and any actions to be taken when that situation occurs. workflow configuration file An implementation-specific file that is a part of a workflow. The workflow configuration file contains information that is necessary to create a workflow template from the specified workflow markup and rules files, and to associate it to a specific list. workflow history item A list item that stores information about the current status of, and past actions for, a document or item that is associated with a workflow. workflow history list A list that stores the history of actions or tasks for a business process. workflow identifier A GUID that is used to identify a workflow. workflow instance An instance of a workflow association that performs on a list item the process that is defined in a workflow template. workflow markup file A file that contains markup to specify the functional behavior of a workflow. workflow participant A user or group that is involved in a workflow. workflow task An action or task in a sequence that is related to a built-in or user-defined business process. workflow task list A list that stores the sequence of actions or tasks for a business process. workflow template A definition of operations, the sequence of operations, constraints, and timing for a particular process. worksheet A single logical container for a set of tabular data and other objects in a workbook. worksheet image A chart image that is embedded in a worksheet or chart sheet. worksheet object An object that is associated with a worksheet. WSDL (Web Services Description Language) An extensible XML format that describes network services as collections of communication endpoints, as specified in WSDL. WSDL message An abstract, typed definition of the data that is communicated during a WSDL operation, as specified in WSDL. WSDL operation An abstract description of an action that is supported by a WSDL service, as specified in WSDL. WSDL port type A named set of abstract operations that is supported by one or more endpoints, as specified in WSDL. X   x axis A horizontal reference line on a chart. Y   y axis A vertical reference line on a chart. Z   z axis The third axis in a three-dimensional chart. It is used to represent depth. zero-based index An index in which the first item has an index of zero. Originalmente publicado en msmvps.com Published by Haaron Gonzalez Consultor de tecnología de la información dedicado a entregar soluciones de misión crítica para organizaciones donde la colaboración, la comunicación y el conocimiento son su inversión estratégica. Reconocido como Microsoft Most Valuable Professional en ASP / ASP.NET desde 2005 y SharePoint Server desde 2009. Interés: Satisfacción del Cliente, Excelencia Operacional, Desarrollo de Personas, Ingeniería en Pre-Ventas Especialidades: Colaboración, Gestión de Contenidos Web, Gestión del Conocimiento, Gestión de Contenidos Empresariales, Gestión de Formularios, Intranet, Extranet, Portales, Implementaciones de entornos on-premises de SharePoint, Arquitectura de soluciones, Soporte Especializado en SharePoint y Office 365 Tecnologías: SharePoint todas las versiones, Office 365, Nintex, DocuSign, Sharegate, PowerApps, Flow, SPDocKit, InfoPath, .NET, C #, JavaScript, CSS, Skeleton Framework, Office 365 PnP Deja un comentario Tu dirección de correo electrónico no será publicada. Los campos necesarios están marcados *
{ "url": "https://geeks.ms/haarongonzalez/es/2014/04/12/lista-de-trminos/", "source_domain": "geeks.ms", "snapshot_id": "crawl=CC-MAIN-2017-26", "warc_metadata": { "Content-Length": "179467", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:DLABGMZA4YLCU53BPZHEOFNR3NFQDL4C", "WARC-Concurrent-To": "<urn:uuid:66f332f6-9b41-44d7-8cde-4af99af3718f>", "WARC-Date": "2017-06-22T16:33:19Z", "WARC-IP-Address": "137.135.129.175", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:E7KGNJXN3QC574DTN4XXPAEYPNDWITBY", "WARC-Record-ID": "<urn:uuid:3d5f9ed4-37cd-4606-8039-c0674f08b95c>", "WARC-Target-URI": "https://geeks.ms/haarongonzalez/es/2014/04/12/lista-de-trminos/", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:7d308c86-0449-4adf-97f9-474095a1eba3>" }, "warc_info": "robots: classic\r\nhostname: ip-10-178-111-167.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-26\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for June 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf" }
{ "line_start_idx": [ 0, 18, 19, 37, 38, 42, 160, 438, 688, 885, 1101, 1244, 1330, 1678, 1851, 2567, 2679, 2722, 2903, 2991, 3213, 3451, 3500, 3633, 3728, 3821, 3913, 4088, 4328, 4685, 4941, 5222, 5349, 5605, 5742, 5852, 5965, 6231, 6437, 6613, 6809, 7159, 7279, 7443, 7683, 7882, 8460, 8754, 8936, 9055, 9123, 9293, 9377, 9489, 9710, 9751, 9848, 10062, 10397, 10480, 10633, 10637, 10817, 11061, 11152, 11261, 11525, 11745, 11966, 12261, 12390, 12510, 12630, 12701, 12945, 13040, 13205, 13310, 13398, 13612, 13863, 13980, 14170, 14330, 14334, 14407, 14528, 14635, 14787, 14846, 15030, 15136, 15322, 15415, 15536, 15671, 15843, 16025, 16211, 16545, 16803, 17049, 17267, 17347, 17482, 17628, 17977, 18232, 18346, 18426, 18496, 18606, 18691, 18809, 18885, 18961, 19132, 19213, 19281, 19347, 19465, 19557, 19842, 19916, 20151, 20196, 20408, 20529, 20679, 20762, 20895, 20969, 21092, 21096, 21603, 21807, 22235, 22544, 22640, 22778, 22849, 23000, 23167, 23312, 23485, 23587, 23756, 23881, 24232, 24528, 24610, 24818, 24914, 25072, 25178, 25257, 25358, 25611, 25703, 25819, 25917, 25921, 26054, 26234, 26402, 26556, 26690, 26903, 27129, 27199, 27275, 27553, 27607, 27746, 27993, 28340, 28399, 28512, 28678, 28819, 28987, 29050, 29054, 29334, 29503, 29628, 29706, 29759, 29852, 29913, 30080, 30235, 30410, 30496, 30598, 30783, 31189, 31370, 31462, 31589, 31785, 31899, 32091, 32200, 32289, 32406, 32410, 32536, 32589, 32833, 32917, 33020, 33258, 33262, 33388, 33541, 33712, 33909, 34104, 34297, 34540, 34607, 34697, 34701, 34804, 35077, 35234, 35301, 35351, 35590, 35672, 35676, 35943, 35947, 36190, 36365, 36465, 36523, 36679, 36683, 36807, 36993, 37048, 37133, 37296, 37520, 37547, 37757, 37836, 37924, 38001, 38184, 38312, 38354, 38515, 38598, 38681, 38857, 38931, 39193, 39256, 39359, 39514, 39915, 39987, 40066, 40169, 40394, 40497, 40501, 40768, 40905, 41045, 41226, 41337, 41462, 41527, 41813, 42074, 42190, 42322, 42525, 42744, 42885, 43162, 43288, 43424, 43600, 43632, 43714, 43871, 44014, 44089, 44237, 44504, 44612, 44799, 45056, 45237, 45699, 45930, 46179, 46245, 46335, 46339, 46467, 46534, 46564, 46670, 46772, 46913, 47025, 47086, 47253, 47257, 47301, 47507, 47652, 47698, 47905, 48173, 48258, 48351, 48453, 48580, 48657, 48762, 48844, 48848, 48967, 49041, 49285, 49458, 49771, 50020, 50129, 50190, 50283, 50556, 51001, 51127, 51282, 51425, 51579, 51720, 51826, 52019, 52175, 52231, 52418, 52531, 52658, 52748, 52935, 53022, 53152, 53404, 53607, 53747, 53878, 53959, 54065, 54214, 54286, 54478, 54562, 54605, 54867, 54993, 55196, 55200, 55306, 55419, 55583, 55667, 55752, 55936, 55940, 56113, 56273, 56376, 56475, 56611, 57061, 57312, 57415, 57698, 57982, 58165, 58328, 58424, 58581, 58797, 59062, 59152, 59218, 59303, 59411, 59466, 59617, 59690, 59848, 60133, 60137, 60420, 60564, 60671, 60780, 60863, 60980, 61147, 61336, 61478, 61581, 61791, 61860, 62006, 62097, 62158, 62450, 62594, 62690, 62861, 62956, 63188, 63263, 63380, 63497, 63687, 63951, 64099, 64290, 64488, 64553, 64716, 65130, 65337, 65756, 65994, 66222, 66326, 66430, 66537, 66743, 66846, 67165, 67217, 67332, 67458, 67666, 67842, 67973, 68140, 68301, 68661, 68756, 68929, 69131, 69346, 69451, 69592, 69749, 69964, 70162, 70260, 70348, 70491, 70609, 70791, 70917, 71009, 71384, 71503, 71825, 71978, 72264, 72361, 72517, 72720, 72847, 72968, 72972, 73016, 73091, 73312, 73482, 73584, 73736, 73983, 74182, 74315, 74459, 74740, 74963, 75142, 75146, 75252, 75481, 75729, 75818, 75924, 76031, 76126, 76231, 76341, 76434, 76524, 76619, 76698, 76747, 77062, 77291, 77590, 77830, 77834, 78071, 78267, 78528, 78633, 78725, 78857, 78861, 79165, 79234, 79330, 79463, 79547, 79583, 79791, 79907, 80129, 80297, 80546, 80601, 80709, 80797, 80974, 81061, 81350, 81520, 81637, 81794, 81933, 82036, 82087, 82159, 82235, 82288, 82367, 82429, 82511, 82613, 82996, 83091, 83244, 83527, 83691, 83788, 83852, 83989, 84088, 84157, 84267, 84362, 84486, 84582, 84660, 84724, 84887, 85010, 85121, 85237, 85241, 85288, 85292, 85337, 85341, 85424, 85496, 85497, 85535, 85536, 85549, 85550, 85566, 85567, 86479, 86480, 86499, 86500 ], "line_end_idx": [ 18, 19, 37, 38, 42, 160, 438, 688, 885, 1101, 1244, 1330, 1678, 1851, 2567, 2679, 2722, 2903, 2991, 3213, 3451, 3500, 3633, 3728, 3821, 3913, 4088, 4328, 4685, 4941, 5222, 5349, 5605, 5742, 5852, 5965, 6231, 6437, 6613, 6809, 7159, 7279, 7443, 7683, 7882, 8460, 8754, 8936, 9055, 9123, 9293, 9377, 9489, 9710, 9751, 9848, 10062, 10397, 10480, 10633, 10637, 10817, 11061, 11152, 11261, 11525, 11745, 11966, 12261, 12390, 12510, 12630, 12701, 12945, 13040, 13205, 13310, 13398, 13612, 13863, 13980, 14170, 14330, 14334, 14407, 14528, 14635, 14787, 14846, 15030, 15136, 15322, 15415, 15536, 15671, 15843, 16025, 16211, 16545, 16803, 17049, 17267, 17347, 17482, 17628, 17977, 18232, 18346, 18426, 18496, 18606, 18691, 18809, 18885, 18961, 19132, 19213, 19281, 19347, 19465, 19557, 19842, 19916, 20151, 20196, 20408, 20529, 20679, 20762, 20895, 20969, 21092, 21096, 21603, 21807, 22235, 22544, 22640, 22778, 22849, 23000, 23167, 23312, 23485, 23587, 23756, 23881, 24232, 24528, 24610, 24818, 24914, 25072, 25178, 25257, 25358, 25611, 25703, 25819, 25917, 25921, 26054, 26234, 26402, 26556, 26690, 26903, 27129, 27199, 27275, 27553, 27607, 27746, 27993, 28340, 28399, 28512, 28678, 28819, 28987, 29050, 29054, 29334, 29503, 29628, 29706, 29759, 29852, 29913, 30080, 30235, 30410, 30496, 30598, 30783, 31189, 31370, 31462, 31589, 31785, 31899, 32091, 32200, 32289, 32406, 32410, 32536, 32589, 32833, 32917, 33020, 33258, 33262, 33388, 33541, 33712, 33909, 34104, 34297, 34540, 34607, 34697, 34701, 34804, 35077, 35234, 35301, 35351, 35590, 35672, 35676, 35943, 35947, 36190, 36365, 36465, 36523, 36679, 36683, 36807, 36993, 37048, 37133, 37296, 37520, 37547, 37757, 37836, 37924, 38001, 38184, 38312, 38354, 38515, 38598, 38681, 38857, 38931, 39193, 39256, 39359, 39514, 39915, 39987, 40066, 40169, 40394, 40497, 40501, 40768, 40905, 41045, 41226, 41337, 41462, 41527, 41813, 42074, 42190, 42322, 42525, 42744, 42885, 43162, 43288, 43424, 43600, 43632, 43714, 43871, 44014, 44089, 44237, 44504, 44612, 44799, 45056, 45237, 45699, 45930, 46179, 46245, 46335, 46339, 46467, 46534, 46564, 46670, 46772, 46913, 47025, 47086, 47253, 47257, 47301, 47507, 47652, 47698, 47905, 48173, 48258, 48351, 48453, 48580, 48657, 48762, 48844, 48848, 48967, 49041, 49285, 49458, 49771, 50020, 50129, 50190, 50283, 50556, 51001, 51127, 51282, 51425, 51579, 51720, 51826, 52019, 52175, 52231, 52418, 52531, 52658, 52748, 52935, 53022, 53152, 53404, 53607, 53747, 53878, 53959, 54065, 54214, 54286, 54478, 54562, 54605, 54867, 54993, 55196, 55200, 55306, 55419, 55583, 55667, 55752, 55936, 55940, 56113, 56273, 56376, 56475, 56611, 57061, 57312, 57415, 57698, 57982, 58165, 58328, 58424, 58581, 58797, 59062, 59152, 59218, 59303, 59411, 59466, 59617, 59690, 59848, 60133, 60137, 60420, 60564, 60671, 60780, 60863, 60980, 61147, 61336, 61478, 61581, 61791, 61860, 62006, 62097, 62158, 62450, 62594, 62690, 62861, 62956, 63188, 63263, 63380, 63497, 63687, 63951, 64099, 64290, 64488, 64553, 64716, 65130, 65337, 65756, 65994, 66222, 66326, 66430, 66537, 66743, 66846, 67165, 67217, 67332, 67458, 67666, 67842, 67973, 68140, 68301, 68661, 68756, 68929, 69131, 69346, 69451, 69592, 69749, 69964, 70162, 70260, 70348, 70491, 70609, 70791, 70917, 71009, 71384, 71503, 71825, 71978, 72264, 72361, 72517, 72720, 72847, 72968, 72972, 73016, 73091, 73312, 73482, 73584, 73736, 73983, 74182, 74315, 74459, 74740, 74963, 75142, 75146, 75252, 75481, 75729, 75818, 75924, 76031, 76126, 76231, 76341, 76434, 76524, 76619, 76698, 76747, 77062, 77291, 77590, 77830, 77834, 78071, 78267, 78528, 78633, 78725, 78857, 78861, 79165, 79234, 79330, 79463, 79547, 79583, 79791, 79907, 80129, 80297, 80546, 80601, 80709, 80797, 80974, 81061, 81350, 81520, 81637, 81794, 81933, 82036, 82087, 82159, 82235, 82288, 82367, 82429, 82511, 82613, 82996, 83091, 83244, 83527, 83691, 83788, 83852, 83989, 84088, 84157, 84267, 84362, 84486, 84582, 84660, 84724, 84887, 85010, 85121, 85237, 85241, 85288, 85292, 85337, 85341, 85424, 85496, 85497, 85535, 85536, 85549, 85550, 85566, 85567, 86479, 86480, 86499, 86500, 86592 ] }
{ "red_pajama_v2": { "ccnet_original_length": 86592, "ccnet_original_nlines": 589, "rps_doc_curly_bracket": 0.000023099999452824704, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.3569880425930023, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.04235555976629257, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.11864511668682098, "rps_doc_frac_unique_words": 0.13438230752944946, "rps_doc_mean_word_length": 5.007016658782959, "rps_doc_num_sentences": 830, "rps_doc_symbol_to_word_ratio": 0.00012384999718051404, "rps_doc_unigram_entropy": 5.8073248863220215, "rps_doc_word_count": 14109, "rps_doc_frac_chars_dupe_10grams": 0.03773852065205574, "rps_doc_frac_chars_dupe_5grams": 0.15338881313800812, "rps_doc_frac_chars_dupe_6grams": 0.09604495763778687, "rps_doc_frac_chars_dupe_7grams": 0.07311306893825531, "rps_doc_frac_chars_dupe_8grams": 0.052573468536138535, "rps_doc_frac_chars_dupe_9grams": 0.04456146061420441, "rps_doc_frac_chars_top_2gram": 0.013249530456960201, "rps_doc_frac_chars_top_3gram": 0.005803749896585941, "rps_doc_frac_chars_top_4gram": 0.005095969885587692, "rps_doc_books_importance": -7582.92138671875, "rps_doc_books_importance_length_correction": -7582.92138671875, "rps_doc_openwebtext_importance": -4001.8388671875, "rps_doc_openwebtext_importance_length_correction": -4001.8388671875, "rps_doc_wikipedia_importance": -3280.89208984375, "rps_doc_wikipedia_importance_length_correction": -3280.89208984375 }, "fasttext": { "dclm": 0.025713739916682243, "english": 0.8768458366394043, "fineweb_edu_approx": 2.692506790161133, "eai_general_math": 0.5237195491790771, "eai_open_web_math": 0.05905884876847267, "eai_web_code": 0.8667123317718506 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.445", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.776", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "6", "label": "Content Listing" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
7,542,280,552,218,593,000
Rock Your Selectors Help Please #1 Can anyone please help me figure out what I'm missing on this one. This is the error message I'm getting. Oops, try again. Did you remember to add a border of color #3A5FCD around every element? So here is my code. /*Add your CSS below!*/ * { border: solid 3px; color: #3A5FCD; } p { color: #00E5EE; } div p { color: #CC0000; } #2 When you're putting a border around an element using CSS, the syntax is: border: 3px solid #3a5fcd; The way you have written it will change the text color of the element, and your border won't work. #3 Oh my gosh! Thanks, I seriously could not figure it out and I was getting upset with myself because I knew it would be simple. I truly appreciate you getting back to me and helping me realize my mistake. #4 No problem! Glad I could help :slight_smile: #5 This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
{ "url": "https://discuss.codecademy.com/t/rock-your-selectors-help-please/77563", "source_domain": "discuss.codecademy.com", "snapshot_id": "crawl=CC-MAIN-2018-39", "warc_metadata": { "Content-Length": "13472", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:I7LGTIMHUAXGZZXBHSLTLNTMSIESBIHP", "WARC-Concurrent-To": "<urn:uuid:e34c3b50-110a-4923-bc4d-7983950d4eca>", "WARC-Date": "2018-09-24T20:17:02Z", "WARC-IP-Address": "64.71.168.222", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:2HKS3WMZLLKDXZMOWTSVA5WU5HT5VR5Z", "WARC-Record-ID": "<urn:uuid:d3091d97-c735-4fcf-bf36-7967ded39173>", "WARC-Target-URI": "https://discuss.codecademy.com/t/rock-your-selectors-help-please/77563", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:ffbdfbbe-1782-4d4b-b180-02658454c55e>" }, "warc_info": "isPartOf: CC-MAIN-2018-39\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2018\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-169-173-84.ec2.internal\r\nsoftware: Apache Nutch 1.15 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 0.11-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 32, 33, 34, 37, 38, 39, 106, 107, 108, 147, 236, 237, 238, 258, 282, 286, 325, 327, 331, 351, 353, 361, 381, 383, 384, 385, 388, 389, 462, 463, 490, 491, 590, 591, 592, 595, 596, 800, 801, 802, 805, 806, 851, 852, 853, 856, 857 ], "line_end_idx": [ 32, 33, 34, 37, 38, 39, 106, 107, 108, 147, 236, 237, 238, 258, 282, 286, 325, 327, 331, 351, 353, 361, 381, 383, 384, 385, 388, 389, 462, 463, 490, 491, 590, 591, 592, 595, 596, 800, 801, 802, 805, 806, 851, 852, 853, 856, 857, 956 ] }
{ "red_pajama_v2": { "ccnet_original_length": 956, "ccnet_original_nlines": 47, "rps_doc_curly_bracket": 0.006276149768382311, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.36036035418510437, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05855856090784073, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.2612612545490265, "rps_doc_frac_unique_words": 0.6566265225410461, "rps_doc_mean_word_length": 4.180722713470459, "rps_doc_num_sentences": 13, "rps_doc_symbol_to_word_ratio": 0.04504505172371864, "rps_doc_unigram_entropy": 4.5299224853515625, "rps_doc_word_count": 166, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.020172910764813423, "rps_doc_frac_chars_top_3gram": 0, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -110.98028564453125, "rps_doc_books_importance_length_correction": -110.98028564453125, "rps_doc_openwebtext_importance": -55.35833740234375, "rps_doc_openwebtext_importance_length_correction": -42.13203430175781, "rps_doc_wikipedia_importance": -38.873870849609375, "rps_doc_wikipedia_importance_length_correction": -38.873870849609375 }, "fasttext": { "dclm": 0.03019547089934349, "english": 0.9369174242019653, "fineweb_edu_approx": 0.7131904363632202, "eai_general_math": 0.04085760936141014, "eai_open_web_math": 0.2675427198410034, "eai_web_code": 0.006582019850611687 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "-1", "labels": { "level_1": "", "level_2": "", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "5", "label": "Social/Forum" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "18", "label": "Q&A Forum" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "1", "label": "No Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
-8,147,002,268,320,371,000
Skip to main content SoapBodyUse (Class Keyword) Specifies the encoding for any web methods defined in this class. This keyword applies only to web service and web client classes. Usage To specify the encoding used by the inputs and outputs of the web methods of this class, use the following syntax: Class MyApp.MyClass [ SoapBodyUse = soapbodyuse ] { //class members } Where soapbodyuse is one of the following: Important: For a web service that you create manually, the default value of this keyword is usually suitable. When you generate a web client or service from a WSDL with the SOAP Wizard, InterSystems IRIS sets this keyword as appropriate for that WSDL; if you modify the value, your web client or service may no longer work. Details This keyword specifies the default encoding used by any web methods defined in this class. It also controls the default values for the ELEMENTQUALIFIED and XMLELEMENT parameters for this class, as discussed in a subsection of this topic. You can override this keyword for individual methods, by using the SoapBodyUse method keyword or the SoapBodyUse query keyword. Effect on Subclasses This keyword is not inherited. Default The default value is literal. (The SOAP standard v1.1 (Chapter 5Opens in a new tab) specifies that web methods should use SOAP encoding. However, most SOAP clients, including .NET, use literal style.) Relationship to WSDL The SoapBodyUse keyword specifies the value of the use attribute of the <soap:body> element within the <binding> section of the WSDL. For example, if SoapBodyUse is literal, the WSDL could look as follows: ... <binding name="MyServiceNameSoap" ... <soap:binding ... <operation name="Add"> <soap:operation ...> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> </operation> </binding> ... In contrast, if SoapBodyUse is encoded, the WSDL could instead be as follows: ... <binding name="MyServiceNameSoap" ... <soap:binding ... <operation name="Add"> <soap:operation .../> <input> <soap:body use="encoded" namespace="http://www.mynamespace.org" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/> </input> <output> <soap:body use="encoded" namespace="http://www.mynamespace.org" encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/> </output> </operation> </binding> ... For SOAP 1.2, the encodingStyle attribute is as follows instead: encodingStyle="http://www.w3.org/2003/05/soap-encoding" The SoapBodyUse keyword also determines the contents of a <part> element of a <message> element for each web method: • If SoapBodyUse is literal, each <part> element includes an element attribute. For example: <part name="parameters" element="s0:Add"/> For another example: <part name="b" element="s0:b"/> • If SoapBodyUse is encoded, each <part> element includes a type attribute rather than an element attribute. For example: <part name="a" type="s0:ComplexNumber"/> Note that SoapBodyUse also controls the default values for the ELEMENTQUALIFIED and XMLELEMENT parameters, which also affect the WSDL. Effect on SOAP Messages For a web method that uses a document-style message, the web service sends a response message like the following: <?xml version="1.0" encoding="UTF-8" ?> <SOAP-ENV:Envelope xmlns:SOAP-ENV='http://schemas.xmlsoap.org/soap/envelope/' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:s='http://www.w3.org/2001/XMLSchema'> <SOAP-ENV:Body> <AddResponse ...> ... In contrast, for a web service that uses an encoded-style message, the response message would be as follows: <?xml version="1.0" encoding="UTF-8" ?> <SOAP-ENV:Envelope xmlns:SOAP-ENV='http://schemas.xmlsoap.org/soap/envelope/' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xmlns:s='http://www.w3.org/2001/XMLSchema' xmlns:SOAP-ENC='http://schemas.xmlsoap.org/soap/encoding/' xmlns:tns='http://www.mynamespace.org' xmlns:types='http://www.mynamespace.org'> <SOAP-ENV:Body SOAP-ENV:encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'> <types:AddResponse> ... Effect on Default for Parameters of the Web Service or Web Client The default value for the ELEMENTQUALIFIED parameter depends on the SoapBodyUse keyword: Value of SoapBodyUse Default for ELEMENTQUALIFIED Notes literal 1 elementFormDefault="qualified" encoded 0 elementFormDefault="unqualified" The default value for the XMLELEMENT parameter also depends on the SoapBodyUse keyword: Value of SoapBodyUse Default for XMLELEMENT Notes literal 1 Message parts have the element attribute encoded 0 Message parts have the type attribute For details on the ELEMENTQUALIFIED and XMLELEMENT parameters, see Projecting Objects to XML. Use with %XML.DataSet For objects of type %XML.DataSetOpens in a new tab, not all permutations of the SoapBindingStyle and SoapBodyUse keywords are permitted. See the entry for the SoapBindingStyle class keyword. See Also FeedbackOpens in a new tab
{ "url": "https://docs.intersystems.com/irisforhealthlatest/csp/docbook/DocBook.UI.Page.cls?KEY=ROBJ_class_soapbodyuse", "source_domain": "docs.intersystems.com", "snapshot_id": "crawl=CC-MAIN-2022-33", "warc_metadata": { "Content-Length": "328632", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:HVJ6CRXHEO247ZH7L4W6TZNIIIXGJBWH", "WARC-Concurrent-To": "<urn:uuid:fdd2f743-a8c1-4e47-a7d3-e0e7c2041eda>", "WARC-Date": "2022-08-11T20:09:46Z", "WARC-IP-Address": "198.133.74.116", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:7LAQABB4V3UKERZDR24HFV4M7RMJXK4B", "WARC-Record-ID": "<urn:uuid:e4161634-4145-484b-b4fe-23cfd858fa2b>", "WARC-Target-URI": "https://docs.intersystems.com/irisforhealthlatest/csp/docbook/DocBook.UI.Page.cls?KEY=ROBJ_class_soapbodyuse", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:15e79aec-8b7d-4412-9e68-c322d9202e21>" }, "warc_info": "isPartOf: CC-MAIN-2022-33\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for August 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-181\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 21, 22, 50, 51, 182, 183, 189, 190, 305, 306, 377, 378, 421, 422, 433, 434, 747, 748, 756, 757, 995, 996, 1124, 1125, 1146, 1147, 1178, 1179, 1187, 1188, 1389, 1390, 1411, 1412, 1618, 1619, 1623, 1658, 1663, 1685, 1712, 1741, 1757, 1796, 1813, 1830, 1869, 1887, 1904, 1915, 1919, 1920, 1998, 1999, 2003, 2041, 2063, 2090, 2120, 2136, 2213, 2296, 2313, 2330, 2407, 2490, 2508, 2509, 2526, 2537, 2541, 2542, 2607, 2608, 2664, 2665, 2782, 2783, 2878, 2879, 2926, 2927, 2952, 2953, 2989, 3113, 3114, 3159, 3160, 3295, 3296, 3320, 3321, 3435, 3436, 3476, 3555, 3629, 3692, 3711, 3735, 3739, 3740, 3849, 3850, 3890, 3969, 4043, 4106, 4185, 4244, 4305, 4391, 4417, 4421, 4422, 4488, 4489, 4578, 4579, 4635, 4676, 4719, 4720, 4808, 4809, 4859, 4910, 4958, 4959, 5053, 5054, 5076, 5077, 5268, 5269, 5278, 5279 ], "line_end_idx": [ 21, 22, 50, 51, 182, 183, 189, 190, 305, 306, 377, 378, 421, 422, 433, 434, 747, 748, 756, 757, 995, 996, 1124, 1125, 1146, 1147, 1178, 1179, 1187, 1188, 1389, 1390, 1411, 1412, 1618, 1619, 1623, 1658, 1663, 1685, 1712, 1741, 1757, 1796, 1813, 1830, 1869, 1887, 1904, 1915, 1919, 1920, 1998, 1999, 2003, 2041, 2063, 2090, 2120, 2136, 2213, 2296, 2313, 2330, 2407, 2490, 2508, 2509, 2526, 2537, 2541, 2542, 2607, 2608, 2664, 2665, 2782, 2783, 2878, 2879, 2926, 2927, 2952, 2953, 2989, 3113, 3114, 3159, 3160, 3295, 3296, 3320, 3321, 3435, 3436, 3476, 3555, 3629, 3692, 3711, 3735, 3739, 3740, 3849, 3850, 3890, 3969, 4043, 4106, 4185, 4244, 4305, 4391, 4417, 4421, 4422, 4488, 4489, 4578, 4579, 4635, 4676, 4719, 4720, 4808, 4809, 4859, 4910, 4958, 4959, 5053, 5054, 5076, 5077, 5268, 5269, 5278, 5279, 5305 ] }
{ "red_pajama_v2": { "ccnet_original_length": 5305, "ccnet_original_nlines": 138, "rps_doc_curly_bracket": 0.0003769999893847853, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.22429907321929932, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.04299065098166466, "rps_doc_frac_lines_end_with_ellipsis": 0.07194244861602783, "rps_doc_frac_no_alph_words": 0.32990655303001404, "rps_doc_frac_unique_words": 0.33788394927978516, "rps_doc_mean_word_length": 6.498293399810791, "rps_doc_num_sentences": 73, "rps_doc_symbol_to_word_ratio": 0.012149530462920666, "rps_doc_unigram_entropy": 4.73922061920166, "rps_doc_word_count": 586, "rps_doc_frac_chars_dupe_10grams": 0.1160714328289032, "rps_doc_frac_chars_dupe_5grams": 0.26260504126548767, "rps_doc_frac_chars_dupe_6grams": 0.2310924381017685, "rps_doc_frac_chars_dupe_7grams": 0.2142857164144516, "rps_doc_frac_chars_dupe_8grams": 0.1160714328289032, "rps_doc_frac_chars_dupe_9grams": 0.1160714328289032, "rps_doc_frac_chars_top_2gram": 0.009191179648041725, "rps_doc_frac_chars_top_3gram": 0.01575629971921444, "rps_doc_frac_chars_top_4gram": 0.025210080668330193, "rps_doc_books_importance": -462.9955749511719, "rps_doc_books_importance_length_correction": -462.9955749511719, "rps_doc_openwebtext_importance": -239.00242614746094, "rps_doc_openwebtext_importance_length_correction": -239.00242614746094, "rps_doc_wikipedia_importance": -205.29852294921875, "rps_doc_wikipedia_importance_length_correction": -205.29852294921875 }, "fasttext": { "dclm": 0.02217363938689232, "english": 0.5285558700561523, "fineweb_edu_approx": 2.5453741550445557, "eai_general_math": 0.8212539553642273, "eai_open_web_math": 0.314031183719635, "eai_web_code": 0.9572464823722839 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.72", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "2", "label": "Understand" }, "secondary": { "code": "3", "label": "Apply" } }, "bloom_knowledge_domain": { "primary": { "code": "2", "label": "Conceptual" }, "secondary": { "code": "3", "label": "Procedural" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "10", "label": "Knowledge Article" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
3,926,536,709,279,207,400
Answers Solutions by everydaycalculation.com Answers.everydaycalculation.com » Divide fractions Divide 80/18 with 81/21 1st number: 4 8/18, 2nd number: 3 18/21 80/18 ÷ 81/21 is 280/243. Steps for dividing fractions 1. Find the reciprocal of the divisor Reciprocal of 81/21: 21/81 2. Now, multiply it with the dividend So, 80/18 ÷ 81/21 = 80/18 × 21/81 3. = 80 × 21/18 × 81 = 1680/1458 4. After reducing the fraction, the answer is 280/243 5. In mixed form: 137/243 MathStep (Works offline) Download our mobile app and learn to work with fractions in your own time: Android and iPhone/ iPad Related: © everydaycalculation.com
{ "url": "https://answers.everydaycalculation.com/divide-fractions/80-18-divided-by-81-21", "source_domain": "answers.everydaycalculation.com", "snapshot_id": "CC-MAIN-2024-22", "warc_metadata": { "Content-Length": "7284", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:TI356Q7ICPNX776PLFIRPOZXCLGQ3UAB", "WARC-Concurrent-To": "<urn:uuid:e818ad70-491e-4ffd-b0c3-3cdb90455544>", "WARC-Date": "2024-05-26T19:20:27Z", "WARC-IP-Address": "96.126.107.130", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:VZ7TJT23KTEBNAEAPPRSFE3KM3UYOWYD", "WARC-Record-ID": "<urn:uuid:d468639c-d20f-42d1-87ee-e38012346b21>", "WARC-Target-URI": "https://answers.everydaycalculation.com/divide-fractions/80-18-divided-by-81-21", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:0fdf5998-d70a-4af8-bd78-f1bceb5ec96b>" }, "warc_info": "isPartOf: CC-MAIN-2024-22\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-212\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 8, 9, 46, 47, 98, 99, 123, 124, 164, 165, 191, 192, 221, 222, 262, 293, 333, 371, 406, 462, 490, 491, 516, 517, 592, 617, 618, 627, 628 ], "line_end_idx": [ 8, 9, 46, 47, 98, 99, 123, 124, 164, 165, 191, 192, 221, 222, 262, 293, 333, 371, 406, 462, 490, 491, 516, 517, 592, 617, 618, 627, 628, 653 ] }
{ "red_pajama_v2": { "ccnet_original_length": 653, "ccnet_original_nlines": 29, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.15337422490119934, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.5705521702766418, "rps_doc_frac_unique_words": 0.7070707082748413, "rps_doc_mean_word_length": 4.848484992980957, "rps_doc_num_sentences": 11, "rps_doc_symbol_to_word_ratio": 0, "rps_doc_unigram_entropy": 4.119898796081543, "rps_doc_word_count": 99, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.02083333022892475, "rps_doc_frac_chars_top_3gram": 0.03750000149011612, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -63.46294403076172, "rps_doc_books_importance_length_correction": -72.64238739013672, "rps_doc_openwebtext_importance": -32.73102569580078, "rps_doc_openwebtext_importance_length_correction": -41.910465240478516, "rps_doc_wikipedia_importance": -22.243328094482422, "rps_doc_wikipedia_importance_length_correction": -31.422771453857422 }, "fasttext": { "dclm": 0.9847387671470642, "english": 0.8317956328392029, "fineweb_edu_approx": 2.211557388305664, "eai_general_math": 0.019250040873885155, "eai_open_web_math": 0.17164885997772217, "eai_web_code": 8.299999763039523e-7 } }
{ "free_decimal_correspondence": { "primary": { "code": "513.212", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "Geometry" } }, "secondary": { "code": "510", "labels": { "level_1": "Science and Natural history", "level_2": "Mathematics", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "1", "label": "Factual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "21", "label": "Customer Support" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
-9,089,911,753,250,883,000
Thread Rating: • 0 Vote(s) - 0 Average • 1 • 2 • 3 • 4 • 5 COOLDOWNS explanation and examples. #1 Cooldowns is a new feature/command for macros. It allows doing very time specific and more advanced macros with it. Here they are Code: Cooldown.Create(CooldownName, Delay) Cooldown.Clear(CooldownName) Cooldown.Rest(CooldownName) Cooldown.Blocked(CooldownName) Cooldown.UnBlocked(CooldownName) Lets start with explanation. Cooldown.Create(CooldownName, Delay) this command creates cooldown with specified name, starts COUNTING down to ZERO from the time we specified in milliseconds. f.e. Cooldown.Create(ADVERTISE, 600000) Creates Cooldown named ADVERTISE that counts down from 1 minute to 0. Cooldown.Clear(CooldownName) This command RESETS cooldown to 0 with given name. Cooldown.Rest(CooldownName) This command will return value of remaining miliseconds of given cooldown (or 0 if inactive) Cooldown.Blocked(CooldownName) Cooldown.UnBlocked(CooldownName) These two commands basically do the same thing but in contrary. Lets say we activated our cooldown ADVERTISE with first command and its counting down. Therefore Cooldown.Blocked(ADVERTISE) will return result 1 Cooldown.UnBlocked(ADVERTISE) will return result 0 But when our cooldown ADVERTISE is inactive results would be swapped. So here is easiest example of use i can think of. We make macro to YELL a message once every minute. Code: 1000 {advert} Cooldown.Blocked(ADVERTISE)==0 Self.Yell(SELL XXXXX for 123456, pm me) Cooldown.Create(ADVERTISE, 600000) But there is much more use for cooldowns than simple message spamming. I took it to the next level, as u can see on my latest LURE MACRO But what is also very interesting, that as a NAME of cooldown we can use a VARIABLE, for example ID of our Target. Here is example of manual macro for advanced attack that you can use 'utori kor' bleeding spell on anything you target once every time cooldown is finished. Very useful on OTS where Inflict Wound short, or no exhaust to use against INVISIBLE targets like warlocks or Warzone monsters. [macro]0 {Utori KOR} Cooldown.Blocked(KOR:TargetID)==0 Self.Say(utori kor) Cooldown.Create(KOR:TargetID, 59000) exit() [/macro] [Image: bOarP6j.png][Image: KQqaWR2.png] Post your ideas for cooldown use in here Reply Forum Jump: Users browsing this thread: 1 Guest(s)
{ "url": "https://forums.bmega.net/thread-20682.html", "source_domain": "forums.bmega.net", "snapshot_id": "crawl=CC-MAIN-2022-27", "warc_metadata": { "Content-Length": "22928", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:HU6PLLDYYLSHCJ3OGKJR36EPRE2MNNPC", "WARC-Concurrent-To": "<urn:uuid:314c7601-62c6-485a-9dc9-de8a41e3116b>", "WARC-Date": "2022-07-05T07:14:47Z", "WARC-IP-Address": "140.82.25.232", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:B5VOWP4G3MGSILKIRNYMLYSPL7JXCNWL", "WARC-Record-ID": "<urn:uuid:a53e872d-3d17-451e-bac6-0b594fd676dc>", "WARC-Target-URI": "https://forums.bmega.net/thread-20682.html", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:3124a91b-f928-46dd-a6d1-a58f8f040967>" }, "warc_info": "isPartOf: CC-MAIN-2022-27\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June/July 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-148\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 1, 16, 42, 48, 54, 60, 66, 72, 108, 111, 158, 159, 228, 229, 243, 249, 286, 315, 343, 374, 407, 408, 437, 438, 475, 599, 604, 639, 709, 710, 739, 790, 791, 819, 912, 913, 944, 977, 978, 979, 1043, 1130, 1140, 1189, 1240, 1310, 1311, 1312, 1362, 1363, 1414, 1415, 1416, 1422, 1436, 1467, 1507, 1542, 1543, 1544, 1615, 1681, 1682, 1767, 1797, 1798, 1879, 1955, 2015, 2083, 2084, 2212, 2213, 2254, 2255, 2256, 2297, 2303, 2304, 2305, 2317, 2318, 2319 ], "line_end_idx": [ 1, 16, 42, 48, 54, 60, 66, 72, 108, 111, 158, 159, 228, 229, 243, 249, 286, 315, 343, 374, 407, 408, 437, 438, 475, 599, 604, 639, 709, 710, 739, 790, 791, 819, 912, 913, 944, 977, 978, 979, 1043, 1130, 1140, 1189, 1240, 1310, 1311, 1312, 1362, 1363, 1414, 1415, 1416, 1422, 1436, 1467, 1507, 1542, 1543, 1544, 1615, 1681, 1682, 1767, 1797, 1798, 1879, 1955, 2015, 2083, 2084, 2212, 2213, 2254, 2255, 2256, 2297, 2303, 2304, 2305, 2317, 2318, 2319, 2357 ] }
{ "red_pajama_v2": { "ccnet_original_length": 2357, "ccnet_original_nlines": 83, "rps_doc_curly_bracket": 0.0016970699653029442, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.29116466641426086, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.05220884084701538, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.2991967797279358, "rps_doc_frac_unique_words": 0.5609756112098694, "rps_doc_mean_word_length": 5.679878234863281, "rps_doc_num_sentences": 40, "rps_doc_symbol_to_word_ratio": 0.0020080299582332373, "rps_doc_unigram_entropy": 4.989579200744629, "rps_doc_word_count": 328, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0, "rps_doc_frac_chars_dupe_6grams": 0, "rps_doc_frac_chars_dupe_7grams": 0, "rps_doc_frac_chars_dupe_8grams": 0, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.01771336980164051, "rps_doc_frac_chars_top_3gram": 0.021470749750733376, "rps_doc_frac_chars_top_4gram": 0, "rps_doc_books_importance": -197.18455505371094, "rps_doc_books_importance_length_correction": -197.18455505371094, "rps_doc_openwebtext_importance": -125.31891632080078, "rps_doc_openwebtext_importance_length_correction": -125.31891632080078, "rps_doc_wikipedia_importance": -82.0013427734375, "rps_doc_wikipedia_importance_length_correction": -82.0013427734375 }, "fasttext": { "dclm": 0.08836573362350464, "english": 0.7694793343544006, "fineweb_edu_approx": 2.4356327056884766, "eai_general_math": 0.7165341973304749, "eai_open_web_math": 0.5983073115348816, "eai_web_code": 0.0992731973528862 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "794.8", "labels": { "level_1": "Arts", "level_2": "Amusements and Recreation", "level_3": "" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "0", "label": "No Artifacts" } }, "missing_content": { "primary": { "code": "4", "label": "Missing Images or Figures" }, "secondary": { "code": "0", "label": "No missing content" } }, "document_type_v2": { "primary": { "code": "23", "label": "Tutorial" }, "secondary": { "code": "8", "label": "Documentation" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "2", "label": "High School Level" }, "secondary": { "code": "1", "label": "General Audience" } } }
672f1e42c33a7f9846924a2431ea77df
-2,712,893,177,792,158,000
应用扩展索引API 此页面引用src/index.js文件,该文件在quasar devquasar build上执行。 这是主进程,您可以在其中修改构建以适合您的应用扩展的需求。 例如,注册启动文件、修改Webpack进程、注册CSS、注册UI组件、注册Quasar CLI命令等。 文件的基本结构示例: module.exports = function (api) { // 如下所述的“api”对象的属性和方法 } api.ctx /quasar.config.js中的ctx相同。 帮助您根据quasar devquasar build运行的上下文做出决策。 示例:如果仅在electron模式下运行,则可能要使用一种api方法。 if (api.ctx.dev === true && api.ctx.mode.electron === true) { api.beforeDev((api) => { // 在运行quasar dev并使用电子模式时 // 做一些事情 }) } api.engine 包含正在使用的Quasar CLI引擎(作为字符串)。示例:@quasar/app-vite@quasar/app-webpack api.hasVite 布尔值-是否在@quasar/app-vite上运行。 api.hasWebpack 布尔值-是否在@quasar/app webpack上运行。 api.extId 包含此应用扩展的ext-id(字符串)。 api.prompts 是一个对象,具有在安装此应用扩展后提示的答案。 有关提示的更多信息,请查看提示API api.resolve 解析此应用扩展运行的应用内的路径。 无需导入path并自己解析路径。 // 解析到应用的根目录 api.resolve.app('src/my-file.js') // 解析为应用的root/src api.resolve.src('my-file.js') // 解析为应用的root/public // (@quasar/app-webpack v3.4+ 或 @quasar/app-vite v1+) api.resolve.public('my-image.png') // 解析为应用的root/src-pwa api.resolve.pwa('some-file.js') // 解析为应用的root/src-ssr api.resolve.ssr('some-file.js') // 解析为应用的root/src-cordova api.resolve.cordova('config.xml') // 解析为应用的root/src-electron api.resolve.electron('some-file.js') // 解析为应用的root/src-electron api.resolve.electron('some-file.js') api.appDir 包含运行此应用扩展的应用根目录的完整路径(字符串)。 api.compatibleWith 通过一个semver条件确定应用扩展与宿主应用程序中安装的软件包兼容。 如果不满足semver条件,则@quasar/app将出错并暂停执行。 semver条件的示例:'1.x || >=2.5.0 || 5.0.0 - 7.2.3'. /** * @param {string} 包名 * @param {string} semver条件 */ api.compatibleWith('@quasar/app', '1.x') // 一个更复杂的例子: if (api.hasVite === true) { api.compatibleWith('@quasar/app-vite', '^1.0.0-beta.0') } else { api.compatbileWith('@quasar/app-webpack', '^3.4.0') } api.hasPackage 通过一个semver条件确定宿主应用程序中是否安装了某些软件包。 semver条件的示例: '1.x || >=2.5.0 || 5.0.0 - 7.2.3'. /** * @param {string} 包名 * @param {string} (optional) semver条件 * @return {boolean} 软件包已安装并且符合可选的semver条件 */ if (api.hasPackage('vuelidate')) { // 嘿,这个应用有(任何版本) } if (api.hasPackage('quasar', '^1.0.0')) { // 嘿,这个应用已安装v1版本 } api.hasExtension 检查是否已npm安装了另一个应用扩展,并且Quasar CLI已调用它。 /** * 检查是否安装了另一个应用扩展 * * @param {string} extId * @return {boolean} 已安装并调用扩展 */ if (api.hasExtension(extId)) { // 嘿,我们有它 } api.getPackageVersion 获取宿主应用程序包的版本。 /** * @param {string} 包名 * @return {string|undefined} 应用程序包的版本 */ console.log( api.getPackageVersion(packageName) ) // 输出示例: // 1.1.3 // undefined (当包找不到的时候) api.extendQuasarConf 扩展quasar.config.js /** * @param {function} 函数 * (cfg: Object, ctx: Object) => undefined */ api.extendQuasarConf ((conf, api) => { //用quasar.config.js做一些事情: //添加、更改任何内容 }) // 一个更复杂的例子: api.extendQuasarConf ((conf, api) => { if (api.hasVite === true) { // 用quasar.config.js做点什么。 // 特定于@quasar/app-vite } else { // api.hasWebpack === true // 用quasar.config.js做点什么。 // 特定于@quasar/app-webpack } }) 注册启动和CSS文件 module.exports = function (api, ctx) { api.extendQuasarConf((conf, api) => { // 确保已注册my-ext启动文件 conf.boot.push('~quasar-app-extension-my-ext/src/boot/my-ext-bootfile.js') if (api.hasVite !== true) { // 确保启动文件转译 conf.build.transpileDependencies.push(/quasar-app-extension-my-ext[\\/]src[\\/]boot/) // 如果启动文件导入任何内容, // 请确保上面的正则表达式也与这些文件匹配! } // 确保my-ext css通过webpack conf.css.push('~quasar-app-extension-my-ext/src/component/my-ext.sass') }) } TIP 注意路径前面的波浪号(~)。 这告诉Quasar CLI该路径是来自node_modules的依赖关系,而不是应用扩展索引脚本文件的相对路径。 api.registerCommand 注册一个命令,该命令将变为quasar run<ext-id><cmd>[args](或缩写:quasar<ext-id_<cmd>[args])。 /** * @param {string} commandName * @param {function} fn * ({ args: [ string, ... ], params: {object} }) => ?Promise */ api.registerCommand('start', ({ args, params }) => { // 在这里做点什么 // 这将注册“start”命令, // 并在运行 $ quasar run <ext-id> start 时 // 执行该处理程序 }) api.registerDescribeApi Register an API file for $ quasar describe command. /** * @param {string} name * @param {string} relativePath * (从进行此调用的文件开始的相对路径) */ api.registerDescribeApi( 'MyComponent', './relative/path/to/my/component/file.json' ) 然后,上面的内容将响应$quasar describe MyComponent 有关此类JSON文件的语法,请查看/node_modules/quasar/dist/api(在项目文件夹中)。请注意,JSON必须包含type属性(“component”、“directive”、“plugin”)。例如: { "type": "component", "props": { }, ... } TIP 始终用quasar describe命令进行测试,以确保你的语法正确,没有错误。 api.getPersistentConf 获取该扩展的内部持久化配置。如果没有,则返回空对象。 /** * @return {object} cfg */ api.getPersistentConf() api.setPersistentConf 设置该扩展的内部持久性配置。如果它已经存在,将被覆盖。 /** * @param {object} cfg */ api.setPersistentConf({ // .... }) api.mergePersistentConf 深度合并到该扩展的内部持久性配置中。如果扩展没有任何已经设置的配置,这基本上等同于第一次设置它。 /** * @param {object} cfg */ api.mergePersistentConf({ // .... }) api.beforeDev $ quasar dev命令运行前准备外部服务,如启动一些后端或应用程序依赖的任何其他服务。 可以使用async/await或直接返回一个Promise。 /** * @param {function} fn * (api, { quasarConf }) => ?Promise */ api.beforeDev((api, { quasarConf }) => { // 做些什么 }) api.afterDev 在Quasar开发服务器启动后($ quasar dev)运行钩子。此时,开发服务器已经启动,如果你想对它做点什么,它是可用的。 可以使用async/await或直接返回一个Promise。 /** * @param {function} fn * (api, { quasarConf }) => ?Promise */ api.afterDev((api, { quasarConf }) => { // do something }) api.beforeBuild 在Quasar为生产构建应用程序之前运行钩子($ quasar build)。此时,distributables文件夹还没有被创建。 可以使用async/await或直接返回一个Promise。 /** * @param {function} fn * (api, { quasarConf }) => ?Promise */ api.beforeBuild((api, { quasarConf }) => { // do something }) api.afterBuild 在Quasar为生产构建应用程序后运行钩子($ quasar build)。此时,distributables文件夹已经被创建,如果你想对它做点什么,它是可用的。 可以使用async/await或直接返回一个Promise。 /** * @param {function} fn * (api, { quasarConf }) => ?Promise */ api.afterBuild((api, { quasarConf }) => { // 做点什么 }) api.onPublish 如果请求发布($ quasar build -P),在Quasar为生产构建应用程序并执行afterBuild钩子(如果指定)之后,运行钩子。 可以使用async/await或直接返回一个Promise。 /** * @param {function} fn * () => ?Promise * @param {object} opts * * arg - 提供给"-publish"/"-P "参数的数值。 * * distDir - 构建可分发文件的文件夹 */ api.onPublish((api, opts) => { // 做点什么 }) 仅@quasar/app-vite api.extendViteConf /** * @param {function} fn * (viteConf: Object, invoke: Object {isClient, isServer}, api) => undefined */ if (api.hasVite === true) { api.extendViteConf((viteConf, { isClient, isServer }, api) => { // 添加/删除/更改Quasar CLI生成的Vite配置对象 }) } api.extendSSRWebserverConf /** * @param {function} fn * (esbuildConf: Object, api) => undefined */ if (api.hasVite === true) { api.extendSSRWebserverConf((esbuildConf, api) => { // 添加/删除/更改Quasar CLI生成的 // 用于SSR webserver的esbuild配置对象(包括SSR中间件)。 }) } api.extendElectronMainConf /** * @param {function} fn * (esbuildConf: Object, api) => undefined */ if (api.hasVite === true) { api.extendElectronMainConf((esbuildConf, api) => { // 添加/删除/更改Quasar CLI生成的 // 用于SSR webserver的esbuild配置对象(包括SSR中间件)。 }) } api.extendElectronPreloadConf /** * @param {function} fn * (esbuildConf: Object, api) => undefined */ if (api.hasVite === true) { api.extendElectronPreloadConf((esbuildConf, api) => { // 添加/删除/更改Quasar CLI生成的 // 用于SSR webserver的esbuild配置对象(包括SSR中间件)。 }) } api.extendPWACustomSWConf /** * @param {function} fn * (esbuildConf: Object, api) => undefined */ if (api.hasVite === true) { api.extendPWACustomSWConf((esbuildConf, api) => { // 添加/删除/更改Quasar CLI生成的 // 用于SSR webserver的esbuild配置对象(包括SSR中间件)。 }) } api.extendBexScriptsConf /** * @param {function} fn * (esbuildConf: Object, api) => undefined */ if (api.hasVite === true) { api.extendBexScriptsConf((esbuildConf, api) => { // 添加/删除/更改Quasar CLI生成的 // 用于SSR webserver的esbuild配置对象(包括SSR中间件)。 }) } 仅@quasar/app-webpack api.chainWebpack 链式webpack配置 /** * @param {function} fn * (chain: ChainObject, invoke: Object {isClient, isServer}, api) => undefined */ if (api.hasWebpack === true) { api.chainWebpack((chain, { isClient, isServer }, api) => { //添加/删除/更改链(Webpack链对象)。 }) } 该配置是一个Webpack链对象。它的API在webpack-chain docs上有描述。 api.extendWebpack 扩展webpack配置 /** * @param {function} fn * (cfg: Object, invoke: Object {isClient, isServer}, api) => undefined */ if (api.hasWebpack === true) { api.extendWebpack((cfg, { isClient, isServer }, api) => { // 添加/删除/更改 cfg (Webpack 配置对象) }) } api.chainWebpackMainElectronProcess 主electron进程的链式webpack配置 /** * @param {function} fn * (chain: ChainObject) => undefined */ if (api.hasWebpack === true) { api.chainWebpackMainElectronProcess((chain, { isClient, isServer }, api) => { // 添加/删除/更改链(Webpack链对象)。 }) } api.extendWebpackMainElectronProcess 主electron进程的扩展webpack配置 /** * @param {function} fn * (cfg: Object) => undefined */ if (api.hasWebpack === true) { api.extendWebpackMainElectronProcess((cfg, { isClient, isServer }, api) => { // 添加/删除/更改 cfg (Webpack 配置对象) }) } api.chainWebpackPreloadElectronProcess 预加载electron过程的链式webpack配置 /** * @param {function} fn * (chain: ChainObject) => undefined */ if (api.hasWebpack === true) { api.chainWebpackPreloadElectronProcess((chain, { isClient, isServer }, api) => { // 添加/删除/更改链(Webpack链对象)。 }) } api.extendWebpackPreloadElectronProcess 预加载electron过程的扩展webpack配置 /** * @param {function} fn * (cfg: Object) => undefined */ if (api.hasWebpack === true) { api.extendWebpackPreloadElectronProcess((cfg, { isClient, isServer }, api) => { // 添加/删除/更改 cfg (Webpack 配置对象) }) } api.chainWebpackWebserver SSR webserver的链式webpack配置(包括来自/src-ssr/middlewares的SSR中间件)。 /** * @param {function} fn * (chain: ChainObject) => undefined */ if (api.hasWebpack === true) { api.chainWebpackWebserver ((chain, { isClient, isServer }, api) => { // 添加/删除/更改链(Webpack链对象) // isClient总是 "false",isServer总是 "true" }) } api.extendWebpackWebserver SSR webserver的扩展webpack配置(包括来自/src-ssr/middlewares的SSR中间件)。 /** * @param {function} fn * (cfg: Object) => undefined */ if (api.hasWebpack === true) { api.extendWebpackWebserver((cfg, { isClient, isServer }, api) => { // 添加/删除/更改 cfg (Webpack 配置对象) // isClient总是 "false",isServer总是 "true" }) } api.chainWebpackCustomSW 使用InjectManifest时,自定义service worker的链式webpack配置(/src-pwa/custom-service-worker.js的内容)。 /** * @param {function} fn * (cfg: ChainObject) => undefined */ if (api.hasWebpack === true) { api.chainWebpackCustomSW ((cfg, { isClient, isServer }, api) => { // 添加/删除/更改 cfg(Webpack链对象) }) } api.extendWebpackCustomSW 使用InjectManifest时,自定义service worker的扩展webpack配置(/src-pwa/custom-service-worker.js的内容)。 /** * @param {function} fn * (chain: Object) => undefined */ if (api.hasWebpack === true) { api.extendWebpackCustomSW((chain, { isClient, isServer }, api) => { // 添加/删除/更改链(Webpack配置对象)。 }) }
{ "url": "http://www.quasarchs.com/app-extensions/development-guide/index-api", "source_domain": "www.quasarchs.com", "snapshot_id": "CC-MAIN-2024-33", "warc_metadata": { "Content-Length": "299634", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:CV7N2DWHT64YBLHRI2EFCEJ55EGKQ52A", "WARC-Concurrent-To": "<urn:uuid:94a714c5-80e7-4ea5-919d-a1fa418a64b8>", "WARC-Date": "2024-08-09T17:55:24Z", "WARC-IP-Address": "116.62.16.230", "WARC-Identified-Payload-Type": "text/html", "WARC-Payload-Digest": "sha1:GAE3KJ4VMS3LFTUW3STNH75RY4FRWHXW", "WARC-Record-ID": "<urn:uuid:de88abaf-64e3-4ef0-a91f-28b0da66708c>", "WARC-Target-URI": "http://www.quasarchs.com/app-extensions/development-guide/index-api", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:04c941c3-b7bd-4c59-8e68-eca183469a6f>" }, "warc_info": "isPartOf: CC-MAIN-2024-33\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for August 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-201\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 10, 11, 144, 145, 156, 157, 191, 215, 217, 218, 226, 227, 292, 293, 329, 330, 392, 419, 448, 461, 466, 468, 469, 480, 481, 547, 548, 560, 561, 589, 590, 605, 606, 637, 638, 648, 649, 670, 671, 683, 684, 727, 728, 740, 741, 776, 777, 790, 824, 825, 843, 873, 874, 895, 949, 984, 985, 1007, 1039, 1040, 1062, 1094, 1095, 1121, 1155, 1156, 1183, 1220, 1221, 1249, 1286, 1287, 1298, 1299, 1326, 1327, 1346, 1347, 1383, 1384, 1420, 1421, 1468, 1469, 1473, 1495, 1523, 1527, 1568, 1581, 1609, 1667, 1669, 1676, 1730, 1732, 1733, 1748, 1749, 1782, 1783, 1831, 1832, 1836, 1858, 1897, 1940, 1944, 1979, 1998, 2000, 2042, 2061, 2063, 2064, 2081, 2082, 2119, 2120, 2124, 2142, 2145, 2170, 2200, 2204, 2235, 2247, 2249, 2250, 2272, 2273, 2287, 2288, 2292, 2314, 2353, 2357, 2407, 2416, 2427, 2453, 2454, 2475, 2476, 2495, 2496, 2500, 2524, 2569, 2573, 2612, 2640, 2654, 2657, 2670, 2709, 2739, 2769, 2796, 2800, 2836, 2866, 2896, 2900, 2903, 2904, 2915, 2916, 2955, 2995, 3018, 3097, 3098, 3130, 3148, 3240, 3263, 3293, 3299, 3300, 3329, 3405, 3410, 3412, 3413, 3417, 3418, 3490, 3491, 3511, 3512, 3587, 3588, 3592, 3623, 3647, 3710, 3714, 3767, 3780, 3781, 3802, 3843, 3857, 3860, 3861, 3885, 3886, 3938, 3939, 3943, 3967, 3999, 4023, 4027, 4052, 4069, 4115, 4117, 4118, 4158, 4159, 4272, 4273, 4275, 4298, 4311, 4316, 4322, 4324, 4325, 4329, 4330, 4371, 4372, 4394, 4395, 4422, 4423, 4427, 4451, 4455, 4479, 4480, 4502, 4503, 4531, 4532, 4536, 4559, 4563, 4587, 4597, 4600, 4601, 4625, 4626, 4675, 4676, 4680, 4703, 4707, 4733, 4743, 4746, 4747, 4761, 4762, 4809, 4810, 4841, 4842, 4846, 4870, 4909, 4913, 4954, 4964, 4967, 4968, 4981, 4982, 5047, 5048, 5079, 5080, 5084, 5108, 5147, 5151, 5191, 5209, 5212, 5213, 5229, 5230, 5297, 5298, 5329, 5330, 5334, 5358, 5397, 5401, 5444, 5462, 5465, 5466, 5481, 5482, 5564, 5565, 5596, 5597, 5601, 5625, 5664, 5668, 5710, 5720, 5723, 5724, 5738, 5739, 5811, 5812, 5843, 5844, 5848, 5872, 5892, 5916, 5955, 5984, 5988, 6019, 6029, 6032, 6033, 6051, 6052, 6071, 6072, 6076, 6100, 6179, 6183, 6211, 6277, 6314, 6319, 6321, 6322, 6349, 6350, 6354, 6378, 6423, 6427, 6455, 6508, 6537, 6583, 6588, 6590, 6591, 6618, 6619, 6623, 6647, 6692, 6696, 6724, 6777, 6806, 6852, 6857, 6859, 6860, 6890, 6891, 6895, 6919, 6964, 6968, 6996, 7052, 7081, 7127, 7132, 7134, 7135, 7161, 7162, 7166, 7190, 7235, 7239, 7267, 7319, 7348, 7394, 7399, 7401, 7402, 7427, 7428, 7432, 7456, 7501, 7505, 7533, 7584, 7613, 7659, 7664, 7666, 7667, 7688, 7689, 7706, 7707, 7719, 7720, 7724, 7748, 7829, 7833, 7864, 7925, 7954, 7959, 7961, 7962, 8009, 8010, 8028, 8029, 8041, 8042, 8046, 8070, 8144, 8148, 8179, 8239, 8274, 8279, 8281, 8282, 8318, 8319, 8343, 8344, 8348, 8372, 8411, 8415, 8446, 8526, 8556, 8561, 8563, 8564, 8601, 8602, 8626, 8627, 8631, 8655, 8687, 8691, 8722, 8801, 8836, 8841, 8843, 8844, 8883, 8884, 8910, 8911, 8915, 8939, 8978, 8982, 9013, 9096, 9126, 9131, 9133, 9134, 9174, 9175, 9201, 9202, 9206, 9230, 9262, 9266, 9297, 9379, 9414, 9419, 9421, 9422, 9448, 9449, 9509, 9510, 9514, 9538, 9577, 9581, 9612, 9683, 9712, 9756, 9761, 9763, 9764, 9791, 9792, 9852, 9853, 9857, 9881, 9913, 9917, 9948, 10017, 10052, 10096, 10101, 10103, 10104, 10129, 10130, 10217, 10218, 10222, 10246, 10283, 10287, 10318, 10386, 10418, 10423, 10425, 10426, 10452, 10453, 10540, 10541, 10545, 10569, 10603, 10607, 10638, 10708, 10739, 10744 ], "line_end_idx": [ 10, 11, 144, 145, 156, 157, 191, 215, 217, 218, 226, 227, 292, 293, 329, 330, 392, 419, 448, 461, 466, 468, 469, 480, 481, 547, 548, 560, 561, 589, 590, 605, 606, 637, 638, 648, 649, 670, 671, 683, 684, 727, 728, 740, 741, 776, 777, 790, 824, 825, 843, 873, 874, 895, 949, 984, 985, 1007, 1039, 1040, 1062, 1094, 1095, 1121, 1155, 1156, 1183, 1220, 1221, 1249, 1286, 1287, 1298, 1299, 1326, 1327, 1346, 1347, 1383, 1384, 1420, 1421, 1468, 1469, 1473, 1495, 1523, 1527, 1568, 1581, 1609, 1667, 1669, 1676, 1730, 1732, 1733, 1748, 1749, 1782, 1783, 1831, 1832, 1836, 1858, 1897, 1940, 1944, 1979, 1998, 2000, 2042, 2061, 2063, 2064, 2081, 2082, 2119, 2120, 2124, 2142, 2145, 2170, 2200, 2204, 2235, 2247, 2249, 2250, 2272, 2273, 2287, 2288, 2292, 2314, 2353, 2357, 2407, 2416, 2427, 2453, 2454, 2475, 2476, 2495, 2496, 2500, 2524, 2569, 2573, 2612, 2640, 2654, 2657, 2670, 2709, 2739, 2769, 2796, 2800, 2836, 2866, 2896, 2900, 2903, 2904, 2915, 2916, 2955, 2995, 3018, 3097, 3098, 3130, 3148, 3240, 3263, 3293, 3299, 3300, 3329, 3405, 3410, 3412, 3413, 3417, 3418, 3490, 3491, 3511, 3512, 3587, 3588, 3592, 3623, 3647, 3710, 3714, 3767, 3780, 3781, 3802, 3843, 3857, 3860, 3861, 3885, 3886, 3938, 3939, 3943, 3967, 3999, 4023, 4027, 4052, 4069, 4115, 4117, 4118, 4158, 4159, 4272, 4273, 4275, 4298, 4311, 4316, 4322, 4324, 4325, 4329, 4330, 4371, 4372, 4394, 4395, 4422, 4423, 4427, 4451, 4455, 4479, 4480, 4502, 4503, 4531, 4532, 4536, 4559, 4563, 4587, 4597, 4600, 4601, 4625, 4626, 4675, 4676, 4680, 4703, 4707, 4733, 4743, 4746, 4747, 4761, 4762, 4809, 4810, 4841, 4842, 4846, 4870, 4909, 4913, 4954, 4964, 4967, 4968, 4981, 4982, 5047, 5048, 5079, 5080, 5084, 5108, 5147, 5151, 5191, 5209, 5212, 5213, 5229, 5230, 5297, 5298, 5329, 5330, 5334, 5358, 5397, 5401, 5444, 5462, 5465, 5466, 5481, 5482, 5564, 5565, 5596, 5597, 5601, 5625, 5664, 5668, 5710, 5720, 5723, 5724, 5738, 5739, 5811, 5812, 5843, 5844, 5848, 5872, 5892, 5916, 5955, 5984, 5988, 6019, 6029, 6032, 6033, 6051, 6052, 6071, 6072, 6076, 6100, 6179, 6183, 6211, 6277, 6314, 6319, 6321, 6322, 6349, 6350, 6354, 6378, 6423, 6427, 6455, 6508, 6537, 6583, 6588, 6590, 6591, 6618, 6619, 6623, 6647, 6692, 6696, 6724, 6777, 6806, 6852, 6857, 6859, 6860, 6890, 6891, 6895, 6919, 6964, 6968, 6996, 7052, 7081, 7127, 7132, 7134, 7135, 7161, 7162, 7166, 7190, 7235, 7239, 7267, 7319, 7348, 7394, 7399, 7401, 7402, 7427, 7428, 7432, 7456, 7501, 7505, 7533, 7584, 7613, 7659, 7664, 7666, 7667, 7688, 7689, 7706, 7707, 7719, 7720, 7724, 7748, 7829, 7833, 7864, 7925, 7954, 7959, 7961, 7962, 8009, 8010, 8028, 8029, 8041, 8042, 8046, 8070, 8144, 8148, 8179, 8239, 8274, 8279, 8281, 8282, 8318, 8319, 8343, 8344, 8348, 8372, 8411, 8415, 8446, 8526, 8556, 8561, 8563, 8564, 8601, 8602, 8626, 8627, 8631, 8655, 8687, 8691, 8722, 8801, 8836, 8841, 8843, 8844, 8883, 8884, 8910, 8911, 8915, 8939, 8978, 8982, 9013, 9096, 9126, 9131, 9133, 9134, 9174, 9175, 9201, 9202, 9206, 9230, 9262, 9266, 9297, 9379, 9414, 9419, 9421, 9422, 9448, 9449, 9509, 9510, 9514, 9538, 9577, 9581, 9612, 9683, 9712, 9756, 9761, 9763, 9764, 9791, 9792, 9852, 9853, 9857, 9881, 9913, 9917, 9948, 10017, 10052, 10096, 10101, 10103, 10104, 10129, 10130, 10217, 10218, 10222, 10246, 10283, 10287, 10318, 10386, 10418, 10423, 10425, 10426, 10452, 10453, 10540, 10541, 10545, 10569, 10603, 10607, 10638, 10708, 10739, 10744, 10745 ] }
{ "red_pajama_v2": { "ccnet_original_length": 10745, "ccnet_original_nlines": 562, "rps_doc_curly_bracket": 0.022522099316120148, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.01980598084628582, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.012530320324003696, "rps_doc_frac_lines_end_with_ellipsis": 0.005328599829226732, "rps_doc_frac_no_alph_words": 0.6265157461166382, "rps_doc_frac_unique_words": 0.4283513128757477, "rps_doc_mean_word_length": 11.412942886352539, "rps_doc_num_sentences": 192, "rps_doc_symbol_to_word_ratio": 0.0016168099828064442, "rps_doc_unigram_entropy": 4.869215488433838, "rps_doc_word_count": 649, "rps_doc_frac_chars_dupe_10grams": 0.04050223156809807, "rps_doc_frac_chars_dupe_5grams": 0.2307276874780655, "rps_doc_frac_chars_dupe_6grams": 0.17321452498435974, "rps_doc_frac_chars_dupe_7grams": 0.17321452498435974, "rps_doc_frac_chars_dupe_8grams": 0.11759147047996521, "rps_doc_frac_chars_dupe_9grams": 0.10139057785272598, "rps_doc_frac_chars_top_2gram": 0.04036721959710121, "rps_doc_frac_chars_top_3gram": 0.04455244913697243, "rps_doc_frac_chars_top_4gram": 0.0378020815551281, "rps_doc_books_importance": -1339.737060546875, "rps_doc_books_importance_length_correction": -1339.737060546875, "rps_doc_openwebtext_importance": -701.158203125, "rps_doc_openwebtext_importance_length_correction": -701.158203125, "rps_doc_wikipedia_importance": -409.1741027832031, "rps_doc_wikipedia_importance_length_correction": -409.1741027832031 }, "fasttext": { "dclm": 0.9972161650657654, "english": 0.03270364925265312, "fineweb_edu_approx": 1.7961941957473755, "eai_general_math": 0.03516567125916481, "eai_open_web_math": 0.7835615277290344, "eai_web_code": 0.7914824485778809 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "005.452", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "3", "label": "Reference/Encyclopedic/Educational" }, "secondary": { "code": "4", "label": "Code/Software" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "23", "label": "Tutorial" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "3", "label": "Undergraduate Level" }, "secondary": { "code": "4", "label": "Graduate/Expert Level" } } }
672f1e42c33a7f9846924a2431ea77df
-2,773,320,969,835,990,000
source: libcaca/trunk/src/aafire.c @ 3565 Last change on this file since 3565 was 2961, checked in by Sam Hocevar, 14 years ago Fix compilation warnings on platforms without Imlib2. • Property svn:keywords set to Id File size: 9.0 KB Line  1/* 2 *  cacafire      fire demo for libcaca 3 *  Copyright (c) 2003 Sam Hocevar <sam@zoy.org> 4 *                1998, 1999, 2001 Jan Hubicka <hubicka@freesoft.cz> 5 *                All Rights Reserved 6 * 7 *  $Id: aafire.c 2961 2008-10-18 11:06:58Z sam $ 8 * 9 *  This program is free software; you can redistribute it and/or 10 *  modify it under the terms of the GNU Lesser General Public 11 *  License as published by the Free Software Foundation; either 12 *  version 2 of the License, or (at your option) any later version. 13 * 14 *  This program is distributed in the hope that it will be useful, 15 *  but WITHOUT ANY WARRANTY; without even the implied warranty of 16 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 17 *  Lesser General Public License for more details. 18 * 19 *  You should have received a copy of the GNU Lesser General Public 20 *  License along with this program; if not, write to the Free Software 21 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 22 *  02111-1307  USA 23 */ 24 25#ifdef LIBCACA 26#include "config.h" 27#if !defined(__KERNEL__) 28#   include <stdio.h> 29#   include <stdlib.h> 30#   include <string.h> 31#endif 32#include "caca.h" 33#else 34#include <stdio.h> 35#include "aalib.h" 36 37#define XSIZ aa_imgwidth(context) 38#define YSIZ (aa_imgheight(context)-4) 39#endif 40#define MAXTABLE (256*5) 41#ifdef LIBCACA 42static caca_canvas_t *cv; 43static caca_display_t *dp; 44static int XSIZ, YSIZ; 45static caca_dither_t *caca_dither; 46static char *bitmap; 47static int paused = 0; 48#else 49static aa_context *context; 50static aa_renderparams *params; 51static aa_palette palette; 52#endif 53static unsigned int table[MAXTABLE]; 54#ifdef LIBCACA 55static int const pal[] = 56#else 57__AA_CONST static int pal[] = 58#endif 59{ 60  0, 0, 0, 0, 0, 6, 0, 0, 6, 0, 0, 7, 0, 0, 8, 0, 0, 8, 0, 0, 9, 0, 0, 10, 612, 0, 10, 4, 0, 9, 6, 0, 9, 8, 0, 8, 10, 0, 7, 12, 0, 7, 14, 0, 6, 16, 0, 5, 62  18, 0, 5, 20, 0, 4, 22, 0, 4, 24, 0, 3, 26, 0, 2, 28, 0, 2, 30, 0, 1, 32, 0, 0, 63  32, 0, 0, 33, 0, 0, 34, 0, 0, 35, 0, 0, 36, 0, 0, 36, 0, 0, 37, 0, 0, 38, 0, 0, 64  39, 0, 0, 40, 0, 0, 40, 0, 0, 41, 0, 0, 42, 0, 0, 43, 0, 0, 44, 0, 0, 45, 0, 0, 65  46, 1, 0, 47, 1, 0, 48, 2, 0, 49, 2, 0, 50, 3, 0, 51, 3, 0, 52, 4, 0, 53, 4, 0, 66  54, 5, 0, 55, 5, 0, 56, 6, 0, 57, 6, 0, 58, 7, 0, 59, 7, 0, 60, 8, 0, 61, 8, 0, 67  63, 9, 0, 63, 9, 0, 63, 10, 0, 63, 10, 0, 63, 11, 0, 63, 11, 0, 63, 12, 0, 63, 12, 0, 68  63, 13, 0, 63, 13, 0, 63, 14, 0, 63, 14, 0, 63, 15, 0, 63, 15, 0, 63, 16, 0, 63, 16, 0, 69  63, 17, 0, 63, 17, 0, 63, 18, 0, 63, 18, 0, 63, 19, 0, 63, 19, 0, 63, 20, 0, 63, 20, 0, 70  63, 21, 0, 63, 21, 0, 63, 22, 0, 63, 22, 0, 63, 23, 0, 63, 24, 0, 63, 24, 0, 63, 25, 0, 71  63, 25, 0, 63, 26, 0, 63, 26, 0, 63, 27, 0, 63, 27, 0, 63, 28, 0, 63, 28, 0, 63, 29, 0, 72  63, 29, 0, 63, 30, 0, 63, 30, 0, 63, 31, 0, 63, 31, 0, 63, 32, 0, 63, 32, 0, 63, 33, 0, 73  63, 33, 0, 63, 34, 0, 63, 34, 0, 63, 35, 0, 63, 35, 0, 63, 36, 0, 63, 36, 0, 63, 37, 0, 74  63, 38, 0, 63, 38, 0, 63, 39, 0, 63, 39, 0, 63, 40, 0, 63, 40, 0, 63, 41, 0, 63, 41, 0, 75  63, 42, 0, 63, 42, 0, 63, 43, 0, 63, 43, 0, 63, 44, 0, 63, 44, 0, 63, 45, 0, 63, 45, 0, 76  63, 46, 0, 63, 46, 0, 63, 47, 0, 63, 47, 0, 63, 48, 0, 63, 48, 0, 63, 49, 0, 63, 49, 0, 77  63, 50, 0, 63, 50, 0, 63, 51, 0, 63, 52, 0, 63, 52, 0, 63, 52, 0, 63, 52, 0, 63, 52, 0, 78  63, 53, 0, 63, 53, 0, 63, 53, 0, 63, 53, 0, 63, 54, 0, 63, 54, 0, 63, 54, 0, 63, 54, 0, 79  63, 54, 0, 63, 55, 0, 63, 55, 0, 63, 55, 0, 63, 55, 0, 63, 56, 0, 63, 56, 0, 63, 56, 0, 80  63, 56, 0, 63, 57, 0, 63, 57, 0, 63, 57, 0, 63, 57, 0, 63, 57, 0, 63, 58, 0, 63, 58, 0, 81  63, 58, 0, 63, 58, 0, 63, 59, 0, 63, 59, 0, 63, 59, 0, 63, 59, 0, 63, 60, 0, 63, 60, 0, 82  63, 60, 0, 63, 60, 0, 63, 60, 0, 63, 61, 0, 63, 61, 0, 63, 61, 0, 63, 61, 0, 63, 62, 0, 83  63, 62, 0, 63, 62, 0, 63, 62, 0, 63, 63, 0, 63, 63, 1, 63, 63, 2, 63, 63, 3, 63, 63, 4, 84  63, 63, 5, 63, 63, 6, 63, 63, 7, 63, 63, 8, 63, 63, 9, 63, 63, 10, 63, 63, 10, 63, 63, 11, 85  63, 63, 12, 63, 63, 13, 63, 63, 14, 63, 63, 15, 63, 63, 16, 63, 63, 17, 63, 63, 18, 63, 63, 19, 86  63, 63, 20, 63, 63, 21, 63, 63, 21, 63, 63, 22, 63, 63, 23, 63, 63, 24, 63, 63, 25, 63, 63, 26, 87  63, 63, 27, 63, 63, 28, 63, 63, 29, 63, 63, 30, 63, 63, 31, 63, 63, 31, 63, 63, 32, 63, 63, 33, 88  63, 63, 34, 63, 63, 35, 63, 63, 36, 63, 63, 37, 63, 63, 38, 63, 63, 39, 63, 63, 40, 63, 63, 41, 89  63, 63, 42, 63, 63, 42, 63, 63, 43, 63, 63, 44, 63, 63, 45, 63, 63, 46, 63, 63, 47, 63, 63, 48, 90  63, 63, 49, 63, 63, 50, 63, 63, 51, 63, 63, 52, 63, 63, 52, 63, 63, 53, 63, 63, 54, 63, 63, 55, 91  63, 63, 56, 63, 63, 57, 63, 63, 58, 63, 63, 59, 63, 63, 60, 63, 63, 61, 63, 63, 62, 63, 63, 63}; 92 93 94static void 95initialize (void) 96{ 97  int i; 98#ifdef LIBCACA 99  uint32_t r[256], g[256], b[256], a[256]; 100#endif 101 102#ifdef LIBCACA 103  cv = caca_create_canvas(80, 32); 104  if (!cv) 105    { 106      printf ("Failed to initialize libcaca\n"); 107      exit (1); 108    } 109  dp = caca_create_display(cv); 110  if (!dp) 111    { 112      printf ("Failed to initialize libcaca\n"); 113      exit (1); 114    } 115  caca_set_display_time(dp, 10000); 116  XSIZ = caca_get_canvas_width(cv) * 2; 117  YSIZ = caca_get_canvas_height(cv) * 2 - 4; 118#else 119  context = aa_autoinit (&aa_defparams); 120  if (context == NULL) 121    { 122      printf ("Failed to initialize aalib\n"); 123      exit (1); 124    } 125  aa_autoinitkbd (context, 0); 126  params = aa_getrenderparams (); 127#endif 128 129  for (i = 0; i < 256; i++) 130#ifdef LIBCACA 131  { 132    r[i] = pal[i * 3] * 64; 133    g[i] = pal[i * 3 + 1] * 64; 134    b[i] = pal[i * 3 + 2] * 64; 135    a[i] = 0xfff; 136  } 137#else 138    aa_setpalette (palette, i, pal[i * 3] * 4, 139                   pal[i * 3 + 1] * 4, pal[i * 3 + 2] * 4); 140#endif 141 142#ifdef LIBCACA 143  caca_dither = caca_create_dither(8, XSIZ, YSIZ - 2, XSIZ, 0, 0, 0, 0); 144  caca_set_dither_palette(caca_dither, r, g, b, a); 145  bitmap = malloc(4 * caca_get_canvas_width(cv) 146                    * caca_get_canvas_height(cv)); 147  memset(bitmap, 0, 4 * caca_get_canvas_width(cv) 148                      * caca_get_canvas_height(cv)); 149#else 150  aa_hidecursor (context); 151#endif 152} 153static void 154uninitialize (void) 155{ 156#ifdef LIBCACA 157  caca_free_display(dp); 158  caca_free_canvas(cv); 159#else 160  aa_close (context); 161#endif 162  exit (0); 163} 164static void 165gentable (void) 166{ 167  unsigned int i, p2; 168  unsigned int minus = 800 / YSIZ; 169  if (minus == 0) 170    minus = 1; 171  for (i = 0; i < MAXTABLE; i++) 172    { 173      if (i > minus) 174        { 175          p2 = (i - minus) / 5; 176          table[i] = p2; 177        } 178      else 179        table[i] = 0; 180    } 181} 182 183#define MA 5 184static void 185firemain (void) 186{ 187  register unsigned int i; 188  unsigned char *p; 189#ifndef LIBCACA 190  char *bitmap = aa_image (context); 191#endif 192  i = 0; 193#define END (bitmap + XSIZ * YSIZ) 194  for (p = (unsigned char*)bitmap; 195       (char*)p <= (( char *) (END)); 196       p += 1) 197    { 198      *p = table[(*(p + XSIZ - 1) + *(p + XSIZ + 1) + *(p + XSIZ)) + 199                 (*(p + 2 * XSIZ - 1) + *(p + 2 * XSIZ + 1))]; 200    } 201} 202 203#define min(x,y) ((x)<(y)?(x):(y)) 204static void 205drawfire (void) 206{ 207  unsigned int i, last1, i1, i2; 208  static int loop = 0, sloop = 0; 209  static unsigned int height = 0; 210  register unsigned char *p; 211#ifndef LIBCACA 212  char *bitmap = aa_image (context); 213#else 214  if(paused) 215    goto _paused; 216#endif 217 218  height++; 219  loop--; 220  if (loop < 0) 221    loop = rand () % 3, sloop++;; 222  i1 = 1; 223  i2 = 4 * XSIZ + 1; 224  for (p = (unsigned char *) bitmap + XSIZ * (YSIZ + 0); 225       p < ((unsigned char *) bitmap + XSIZ * (YSIZ + 1)); 226       p++, i1 += 4, i2 -= 4) 227    { 228      last1 = rand () % min (i1, min (i2, height)); 229      i = rand () % 6; 230      for (; p < (unsigned char *) bitmap + XSIZ * (YSIZ + 1) && i != 0; 231           p++, i--, i1 += 4, i2 -= 4) 232        *p = last1, last1 += rand () % 6 - 2, *(p + XSIZ) = last1, last1 += 233          rand () % 6 - 2; 234      *(p + 2 * XSIZ) = last1, last1 += rand () % 6 - 2; 235    } 236  i = 0; 237  firemain (); 238#ifdef LIBCACA 239_paused: 240  caca_dither_bitmap(cv, 0, 0, caca_get_canvas_width(cv), 241                      caca_get_canvas_height(cv), caca_dither, bitmap); 242  caca_set_color_ansi(cv, CACA_WHITE, CACA_BLUE); 243  if (sloop < 100) 244    caca_put_str(cv, caca_get_canvas_width(cv) - 30, 245                  caca_get_canvas_height(cv) - 2, 246                  " -=[ Powered by libcaca ]=- "); 247  248  caca_refresh_display(dp); 249  /*XSIZ = caca_get_width() * 2; 250  YSIZ = caca_get_height() * 2 - 4;*/ 251#else 252  aa_renderpalette (context, palette, params, 0, 0, aa_scrwidth (context), 253                    aa_scrheight (context)); 254  aa_flush (context); 255#endif 256} 257static void 258game (void) 259{ 260#ifndef LIBCACA 261  int event; 262#endif 263  gentable (); 264#ifdef LIBCACA 265  for(;;) 266#else 267  while (!(event = aa_getevent (context, 0)) || event == AA_RESIZE) 268#endif 269    { 270#ifdef LIBCACA 271      caca_event_t ev; 272      if(caca_get_event(dp, CACA_EVENT_KEY_PRESS|CACA_EVENT_QUIT, &ev, 0)) 273        { 274          if (caca_get_event_type(&ev) & CACA_EVENT_QUIT) 275            return; 276          switch(caca_get_event_key_ch(&ev)) 277            { 278                case CACA_KEY_CTRL_C: 279                case CACA_KEY_CTRL_Z: 280                case CACA_KEY_ESCAPE: return; 281                case ' ': paused = !paused; 282            } 283        } 284#endif 285      drawfire (); 286    } 287} 288int 289main (int argc, char **argv) 290{ 291#ifndef LIBCACA 292  if (!aa_parseoptions (NULL, NULL, &argc, argv) || argc != 1) 293    { 294      printf ("%s", aa_help); 295      exit (1); 296    } 297#endif 298  initialize (); 299#ifndef LIBCACA 300  aa_resizehandler (context, (void *) aa_resize); 301#endif 302  game (); 303  uninitialize (); 304  return 1; 305} Note: See TracBrowser for help on using the repository browser.
{ "url": "https://caca.zoy.org/browser/libcaca/trunk/src/aafire.c?rev=3565&order=date&desc=1", "source_domain": "caca.zoy.org", "snapshot_id": "crawl=CC-MAIN-2022-27", "warc_metadata": { "Content-Length": "39532", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:FVTEWACJ6IGZW375NXCKVFBDKP7FHMDQ", "WARC-Concurrent-To": "<urn:uuid:950822c0-70a8-4ec0-beb4-4e3d36d6e875>", "WARC-Date": "2022-06-26T01:37:15Z", "WARC-IP-Address": "193.200.42.164", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:UVHH7HWHTKSQPGLLH6CFMGXNJWG53WN3", "WARC-Record-ID": "<urn:uuid:7d669731-e4d4-4eb9-80b1-ed30477bc8f8>", "WARC-Target-URI": "https://caca.zoy.org/browser/libcaca/trunk/src/aafire.c?rev=3565&order=date&desc=1", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:000bd315-42eb-47cc-92b8-da1b1aac6ed0>" }, "warc_info": "isPartOf: CC-MAIN-2022-27\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for June/July 2022\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-143\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 42, 43, 129, 130, 184, 185, 221, 239, 245, 249, 290, 340, 410, 449, 453, 504, 508, 575, 640, 707, 778, 783, 853, 922, 994, 1048, 1053, 1124, 1198, 1261, 1283, 1289, 1292, 1309, 1331, 1358, 1382, 1407, 1432, 1441, 1461, 1469, 1490, 1511, 1514, 1550, 1591, 1600, 1627, 1644, 1672, 1701, 1726, 1763, 1786, 1811, 1819, 1849, 1883, 1912, 1921, 1960, 1977, 2004, 2012, 2044, 2053, 2057, 2134, 2213, 2297, 2381, 2465, 2549, 2633, 2723, 2815, 2907, 2999, 3091, 3183, 3275, 3367, 3459, 3551, 3643, 3735, 3827, 3919, 4011, 4103, 4195, 4290, 4390, 4490, 4590, 4690, 4790, 4890, 4991, 4994, 4997, 5011, 5031, 5035, 5046, 5063, 5108, 5118, 5122, 5140, 5178, 5192, 5201, 5253, 5272, 5281, 5316, 5330, 5339, 5391, 5410, 5419, 5458, 5501, 5549, 5558, 5602, 5628, 5637, 5687, 5706, 5715, 5749, 5786, 5796, 5800, 5831, 5849, 5856, 5887, 5922, 5957, 5978, 5985, 5994, 6044, 6107, 6117, 6121, 6139, 6215, 6270, 6321, 6375, 6428, 6484, 6493, 6523, 6533, 6538, 6553, 6576, 6581, 6599, 6627, 6654, 6663, 6688, 6698, 6713, 6718, 6733, 6752, 6757, 6782, 6820, 6841, 6859, 6895, 6904, 6928, 6941, 6976, 7004, 7017, 7031, 7056, 7065, 7070, 7074, 7090, 7105, 7124, 7129, 7159, 7182, 7201, 7241, 7251, 7263, 7301, 7339, 7380, 7398, 7407, 7479, 7545, 7554, 7559, 7563, 7601, 7616, 7635, 7640, 7676, 7713, 7750, 7782, 7801, 7841, 7850, 7866, 7887, 7897, 7901, 7916, 7929, 7948, 7985, 7998, 8022, 8082, 8144, 8177, 8186, 8241, 8267, 8343, 8385, 8464, 8494, 8554, 8563, 8575, 8593, 8611, 8623, 8684, 8759, 8812, 8834, 8890, 8943, 8997, 9002, 9033, 9069, 9110, 9119, 9197, 9245, 9270, 9280, 9285, 9300, 9315, 9320, 9339, 9355, 9365, 9383, 9401, 9414, 9423, 9494, 9504, 9513, 9531, 9557, 9635, 9648, 9709, 9732, 9780, 9797, 9838, 9879, 9928, 9975, 9992, 10005, 10015, 10037, 10046, 10051, 10058, 10090, 10095, 10114, 10180, 10189, 10222, 10241, 10250, 10260, 10280, 10299, 10352, 10362, 10376, 10398, 10413, 10418 ], "line_end_idx": [ 42, 43, 129, 130, 184, 185, 221, 239, 245, 249, 290, 340, 410, 449, 453, 504, 508, 575, 640, 707, 778, 783, 853, 922, 994, 1048, 1053, 1124, 1198, 1261, 1283, 1289, 1292, 1309, 1331, 1358, 1382, 1407, 1432, 1441, 1461, 1469, 1490, 1511, 1514, 1550, 1591, 1600, 1627, 1644, 1672, 1701, 1726, 1763, 1786, 1811, 1819, 1849, 1883, 1912, 1921, 1960, 1977, 2004, 2012, 2044, 2053, 2057, 2134, 2213, 2297, 2381, 2465, 2549, 2633, 2723, 2815, 2907, 2999, 3091, 3183, 3275, 3367, 3459, 3551, 3643, 3735, 3827, 3919, 4011, 4103, 4195, 4290, 4390, 4490, 4590, 4690, 4790, 4890, 4991, 4994, 4997, 5011, 5031, 5035, 5046, 5063, 5108, 5118, 5122, 5140, 5178, 5192, 5201, 5253, 5272, 5281, 5316, 5330, 5339, 5391, 5410, 5419, 5458, 5501, 5549, 5558, 5602, 5628, 5637, 5687, 5706, 5715, 5749, 5786, 5796, 5800, 5831, 5849, 5856, 5887, 5922, 5957, 5978, 5985, 5994, 6044, 6107, 6117, 6121, 6139, 6215, 6270, 6321, 6375, 6428, 6484, 6493, 6523, 6533, 6538, 6553, 6576, 6581, 6599, 6627, 6654, 6663, 6688, 6698, 6713, 6718, 6733, 6752, 6757, 6782, 6820, 6841, 6859, 6895, 6904, 6928, 6941, 6976, 7004, 7017, 7031, 7056, 7065, 7070, 7074, 7090, 7105, 7124, 7129, 7159, 7182, 7201, 7241, 7251, 7263, 7301, 7339, 7380, 7398, 7407, 7479, 7545, 7554, 7559, 7563, 7601, 7616, 7635, 7640, 7676, 7713, 7750, 7782, 7801, 7841, 7850, 7866, 7887, 7897, 7901, 7916, 7929, 7948, 7985, 7998, 8022, 8082, 8144, 8177, 8186, 8241, 8267, 8343, 8385, 8464, 8494, 8554, 8563, 8575, 8593, 8611, 8623, 8684, 8759, 8812, 8834, 8890, 8943, 8997, 9002, 9033, 9069, 9110, 9119, 9197, 9245, 9270, 9280, 9285, 9300, 9315, 9320, 9339, 9355, 9365, 9383, 9401, 9414, 9423, 9494, 9504, 9513, 9531, 9557, 9635, 9648, 9709, 9732, 9780, 9797, 9838, 9879, 9928, 9975, 9992, 10005, 10015, 10037, 10046, 10051, 10058, 10090, 10095, 10114, 10180, 10189, 10222, 10241, 10250, 10260, 10280, 10299, 10352, 10362, 10376, 10398, 10413, 10418, 10481 ] }
{ "red_pajama_v2": { "ccnet_original_length": 10481, "ccnet_original_nlines": 314, "rps_doc_curly_bracket": 0.003816429991275072, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.053250961005687714, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.023536330088973045, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.7864077687263489, "rps_doc_frac_unique_words": 0.34512263536453247, "rps_doc_mean_word_length": 3.42897891998291, "rps_doc_num_sentences": 27, "rps_doc_symbol_to_word_ratio": 0.016769640147686005, "rps_doc_unigram_entropy": 5.007556438446045, "rps_doc_word_count": 1753, "rps_doc_frac_chars_dupe_10grams": 0.02711695060133934, "rps_doc_frac_chars_dupe_5grams": 0.14140741527080536, "rps_doc_frac_chars_dupe_6grams": 0.06238562986254692, "rps_doc_frac_chars_dupe_7grams": 0.05057394877076149, "rps_doc_frac_chars_dupe_8grams": 0.02711695060133934, "rps_doc_frac_chars_dupe_9grams": 0.02711695060133934, "rps_doc_frac_chars_top_2gram": 0.058392949402332306, "rps_doc_frac_chars_top_3gram": 0.0024954299442470074, "rps_doc_frac_chars_top_4gram": 0.004990850109606981, "rps_doc_books_importance": -1673.8935546875, "rps_doc_books_importance_length_correction": -1673.8935546875, "rps_doc_openwebtext_importance": -1277.16162109375, "rps_doc_openwebtext_importance_length_correction": -1277.16162109375, "rps_doc_wikipedia_importance": -921.6847534179688, "rps_doc_wikipedia_importance_length_correction": -921.6847534179688 }, "fasttext": { "dclm": 0.3834990859031677, "english": 0.24223656952381134, "fineweb_edu_approx": 1.7395634651184082, "eai_general_math": 0.07480853796005249, "eai_open_web_math": 0.38877731561660767, "eai_web_code": 0.9991934895515442 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.1", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.0151", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "2", "label": "Understand" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "-1", "label": "Abstain" } }, "extraction_artifacts": { "primary": { "code": "0", "label": "No Artifacts" }, "secondary": { "code": "3", "label": "Irrelevant Content" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "3", "label": "Academic Writing" } }, "reasoning_depth": { "primary": { "code": "4", "label": "Advanced Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df
-3,672,130,716,695,582,000
summaryrefslogtreecommitdiffstats Commit message (Collapse)AuthorAgeFilesLines * Revert "Trebuchet : Clean windows during bootup."staging/cm-12.1Rajesh Yengisetty2015-04-028-0/+0 | | | | | | This reverts commit 0a796c8767ab382db849e13b94069b265451f454. Change-Id: I350ca21f34166db7eaabef3c4c7cc3b4240c9b2e * Merge branch 'cm-12.0' of ↵Steve Kondik2015-04-0144-39/+427 |\ | | | | | | git://github.com/CyanogenMod/android_packages_apps_Trebuchet into cm-12.1 | * Trebuchet : Clean windows during bootup.Steve Ballmer2015-03-318-0/+0 | | | | | | | | Change-Id: I57cce3e5ad809d82964fe057ee4befec702135c5 | * Trebuchet: Fix bad ui state when backing twice quicklyLinus Lee2015-03-311-0/+8 | | | | | | | | | | | | | | | | If a user enters the widget add screen and quickly backs up twice, the widget panel stays around and captures touch, but the ui thinks it is in the homescreen. Change-Id: I52a920fd633f3ab690ca1c959fbc8935c2d0bb69 | * Automatic translation importMichael Bestas2015-03-3010-1/+18 | | | | | | | | Change-Id: Ieed7333d3acac4c2e3e130e242f50bb0ada05751 | * ProtectedApps: map items without componentNames by positionRaj Yengisetty2015-03-272-5/+28 | | | | | | | | | | | | | | | | | | | | | | Repro: - Add a contact widget to a folder - Open the hidden apps fragment - Attempt to remove an entry from the fragment - Observe: Force close Change-Id: I3ca2c62283af5232534b766d7579413c060a5403 (cherry picked from commit f963b11485ceef70bbce7a9a4b98415ac2672b5b) | * Protected Apps: fix insets so that views stay above navbarRaj Yengisetty2015-03-251-0/+10 | | | | | | | | Change-Id: I78b5a212b66aa31b22d72a65af40452dd114fc35 | * ProtectedApps: Fix protecting shortcuts with no ComponentNamesRaj Yengisetty2015-03-252-4/+10 | | | | | | | | | | | | | | | | | | | | Repro: - Create a shortcut using the contacts widget - Add to a folder and open app protection screen - Observe: Trebuchet force closes Change-Id: I76f6a8b1d024beb36fa804bb3a866913edc335c1 (cherry picked from commit d8bdb0eef3f1799e8b829bcf114f1c3573bce8d6) | * Automatic translation importMichael Bestas2015-03-2219-0/+144 | | | | | | | | Change-Id: I878deec6ddf8b1c668bf790c8934b0f7f9167dbf | * Trebuchet: protect update path for widgetpreviews dbRaj Yengisetty2015-03-181-1/+5 | | | | | | | | | | | | | | | | | | After the update path is called, calling getWritableDatabase always results in a SQLiteReadOnlyDatabaseException. Looks to be a Lollipop bug, protecting the code path till we have a better solution. Change-Id: Ic0487e2d588a341d42e046fb97e8f041622d6450 | * Trebuchet: disable search bar when there are no search activitiesRaj Yengisetty2015-03-175-19/+63 | | | | | | | | | | | | | | | | | | - On non-GMS devices, there are no Search apps which can support the search bar implementation. - Disable the search bar entirely if there is no search activity - Add a new utility method in SettingsProvider Change-Id: I3bcbceae4ceab308e4d797dad107e0a2ab72d673 | * Trebuchet: fix live settings bugRaj Yengisetty2015-03-161-2/+3 | | | | | | | | | | | | | | | | | | | | | | Repro: - On fresh boot, long press on workspace and open settings panel - Toggle a setting (e.g. Large icons) that triggers a grid refresh - Quickly close the panel and click into a workspace page - Observe sometimes the background of the workspace page is still outlined as if in Overview mode Change-Id: I89492aa9eed269dac18027fa43d1d86597370502 | * Automatic translation importMichael Bestas2015-03-1425-7/+138 | | | | | | | | Change-Id: I57cce8130d792d23764aa67d6e20985a71572f2a * | Trebuchet : Clean windows during bootup.Steve Ballmer2015-03-318-0/+0 |/ | | | | Change-Id: I57cce3e5ad809d82964fe057ee4befec702135c5 (cherry picked from commit aba5c809387d78b1ddf583a8a201c9cdfd1dd71b) * I'm Trebuchet, the cm launcherlinuxx2015-03-1211-1/+1 | | | | | Change-Id: I9b96a42cc3234f385f09469fdbf7b7c14bf19e39 Signed-off-by: linuxx <joey@cyanogenmoditalia.it> * App Drawer: respect drawer show/hide icon lablesRaj Yengisetty2015-03-101-0/+8 | | | | Change-Id: Id1d2b152dde3d1e3d89fca2e9e16bc2472f661bc * App Drawer: take dynamic grid updatesRaj Yengisetty2015-03-104-12/+15 | | | | | | - Also fix row length so icons aren't cut off when large icons are enabled Change-Id: Iae95dc2380abee211eeed72eae08cafa4ec354f7 * App drawer: respect protected appsRaj Yengisetty2015-03-091-0/+36 | | | | Change-Id: I67d0af84cc8cad3d3e788280e34a9c2a95ab76a7 * App Drawer: Disables specific settings for the paginated appHayden Schoen2015-03-063-9/+49 | | | | | | drawer while the vertical app drawer is selected Change-Id: I352bfd42f60d46c53ee74c4ecf6a6bb3f0b7ba90 * App Drawer: fix drawer visibility after cancelling widget dropRaj Yengisetty2015-03-061-5/+0 | | | | | | | | | | | Repro: - Open widgets - Try to add a widget with setup setp (cLock) - When setup activity is launched, press Home to cancel - Observe: legacy app dawer is visible on top of Workspace without a background Change-Id: I5e7d7d2166cc1cac193407ac9ec16643f52591ba * App Drawer: internationalizationRaj Yengisetty2015-03-066-36/+1073 | | | | Change-Id: Ib3976e0852aab4a2e78a90877c056ad3ecd3c448 * App Drawer: Add toggle functionality to change back to legacy app drawerRaj Yengisetty2015-03-067-10/+102 | | | | Change-Id: I4a78832188e27ae0b5a25b6a81ce000b6ffcd1f1 * App drawer smooth scrollingRaj Yengisetty2015-03-067-24/+11 | | | | | | Also fixes searchbar visibility when dragging icons from app drawer Change-Id: I418dc3210a95cc57c81979452def8240c27d2214 * Trebuchet: App Drawer - clean up open/close animationsRaj Yengisetty2015-03-0612-149/+232 | | | | Change-Id: Ia1bcaec9cf5bdcd9ca61137aa45f91819fb2e94d * Trebuchet: Implement new app drawer.Rajesh Yengisetty2015-03-0621-41/+1625 | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | commit 535c5e89c7484ae96f83af021487a8061f3e0b04 Author: Adnan <adnan@cyngn.com> Date: Tue Jul 22 17:21:09 2014 -0700 Trebuchet: Implement new app drawer. Change-Id: Ibf6152352520ece4dff201b8013378a1ad562894 commit d46c52032ef20d9f97409114e6efc34650245fb6 Author: Raj Yengisetty <rajesh@cyngn.com> Date: Fri Jul 25 09:13:38 2014 -0700 Fix: With the new App Drawer implementation AppsDrawerListAdapter should clone it's AppInfo ArrayList before removing elements from it, otherwise the AppsCustomizePagedView will not add any apps to it's instance variables and will never dispaly widgets. Repro: Long press on workspace to get to overview mode Click widgets button Observe no Widgets (empty page) Change-Id: I7574ae23dbf3298674585060d5da5e00a5852d46 commit b0c7e4fad041e492816a36e538a505983d996a75 Author: Adnan <adnan@cyngn.com> Date: Tue Jul 22 19:06:15 2014 -0700 Catapult: Allow elements to be draggable out of drawer. Change-Id: I711b42bad0fc6ae14399f3eb88ec60cd443f87d1 commit 00148d42288a7ee37e8aa05cccb121e9bcf6fbda Author: Danesh M <danesh@cyngn.com> Date: Wed Jul 23 10:37:19 2014 -0700 Catapult : Make flowlayout wrap_content Change-Id: I9db6d39274b71ee2750058fd65f4917701394ac0 commit 268e707d14be0c29448b9f5aee4f26a3180c75fd Author: Adnan <adnan@cyngn.com> Date: Wed Jul 23 13:27:06 2014 -0700 Catapult: Use recyclerview for side app drawer. Change-Id: Ie6f916792375f82a8f97a0369b98b813416216e8 commit efcbdc635e34511b73939639cbcf910728b1b3b2 Author: Adnan <adnan@cyngn.com> Date: Wed Jul 23 14:30:37 2014 -0700 Catapult: Handle app install and uninstall in drawer. Change-Id: Ia22876574e96b9ff0d4b4d93a853d7e92633376c commit 3fb7c6cb0b4bb9cfaf1d11c787df14c6767a72a9 Author: Danesh M <danesh@cyngn.com> Date: Thu Jul 24 10:19:57 2014 -0700 Catapult : Improve scroll performance Change-Id: I294beb9c9e1946724108bad2c0bca8839c5bf56b commit 85828036bd4af0a242f408ba18236b11920a0120 Author: Adnan <adnan@cyngn.com> Date: Thu Jul 24 10:46:58 2014 -0700 Catapult: Use setHasFixedSize on RecyclerView. Change-Id: Id06faa37d69f2d3ef533f829d991971ea2a32012 commit 4206cc348bb8aa788b0e4a0f2080deeb55a73d38 Author: Adnan <adnan@cyngn.com> Date: Thu Jul 24 10:49:15 2014 -0700 Catapult: Show App Info and Uninstall options on drag. Change-Id: Ica307eef4d2a086733f84704d129ac893f9bbb34 commit 283db64b47a5ec395e7ec07d5e34660c98cef91d Author: Adnan <adnan@cyngn.com> Date: Thu Jul 24 15:00:37 2014 -0700 Catapult: Properly handle install, remove, and update. Change-Id: I16138503bb5d31e999f293afc00e1adc2d574727 commit ca19c304fac9de8b97c0345b0c9a7cf3c3bdf155 Author: Adnan <adnan@cyngn.com> Date: Thu Jul 24 15:27:09 2014 -0700 Catapult: Ignore index 0 when added. Change-Id: Id00a41feb1813c419fda4425327024292d51e300 commit f595d415d3b8d9775d7448f1bbc4b542ea40c7a3 Author: Adnan <adnan@cyngn.com> Date: Thu Jul 24 15:51:32 2014 -0700 Catapult: Clean up after drag. Change-Id: I858c9aa5e30bc6ca13d4ca53397b769bb6b2b86b commit c337a69e43f213cacc0fe50a0d001f4cb3a5d9f4 Author: Adnan <adnan@cyngn.com> Date: Fri Jul 25 12:46:39 2014 -0700 Catapult: Fix app updates for new data structure. - Also fix line wrapping in class. Change-Id: I3c4f33d6e3e236952ea6d73f8402f32ac059f810 commit ef6b88c44f2c6c3372136773fa01821c4fc7ba62 Author: Danesh M <danesh@cyngn.com> Date: Thu Jul 24 23:26:41 2014 -0700 Catapult : Add scrubber Change-Id: Ied2e44e2d393bc5537f77c29a4b099da1e1f2a64 commit a96939b669f8adfad7bb633aa9acfa18fe72ff1e Author: Adnan <adnan@cyngn.com> Date: Mon Jul 28 11:01:37 2014 -0700 Catapult: Fix crashes for addition of next sections in list. Change-Id: I66d8e02523595655458d0f30d75ccfbe3b65e69d commit 48dd4872ba59499e7cea950fe4b1f8e4c6774a24 Author: Adnan <adnan@cyngn.com> Date: Mon Jul 28 11:59:20 2014 -0700 Catapult: Place all special or numerics in a single category. - Also implement AutoFitTextView for character resizing. Change-Id: Ida4e702b43dc934835021cbbf3e0b41d9cea0b16 commit 40ed85a3f518dcabfbf8533f534934e029cb3835 Author: Adnan <adnan@cyngn.com> Date: Mon Jul 28 13:22:14 2014 -0700 Catapult: Disable split touch events within drawer item. Change-Id: I990717140d5b420b9a658aede317206947e9fbce commit d76583a1a4e5dd0a5792ce6d39adc427934d7db9 Author: Adnan <adnan@cyngn.com> Date: Mon Jul 28 15:53:23 2014 -0700 Catapult: Add spacer to last item in list. Change-Id: Ia3f2d7d12c09886ab24e8976549518c1bb1a9a0b commit 467e9cb6428b33fd6846be8d30bb8dcfe127acdf Author: Adnan <adnan@cyngn.com> Date: Tue Jul 29 12:39:37 2014 -0700 Catapult: Group special characters together under section. Change-Id: Ic2508eb101e1604c9e1544bdc858c7487f426a44 commit 1f566b1b5b9bac71d0d79d07084f024ba67982e1 Author: Danesh M <danesh@cyngn.com> Date: Tue Jul 29 14:25:26 2014 -0700 Catapult : Fix scrubber - Make seekbar height of entire scrubber - Cancel viewproperty animator instead of Animation - Reduce scrubber animation duration - Ignore swipe events if in scrubber area Change-Id: I3a80b5bc392105bd1d5deff1defed8c083512029 commit b54ace6ee3ecca153f4c8fd2cda35366b205106f Author: Danesh M <danesh@cyngn.com> Date: Tue Jul 29 14:29:44 2014 -0700 Catapult : Check if appdrawer is null when intercepting Change-Id: I8d1b095acc8484d2ffb3f3ffc07608a639c9a3a3 commit 7a544638641e953aa2e75e6bc3f353906887440e Author: Adnan <adnan@cyngn.com> Date: Tue Jul 29 18:23:30 2014 -0700 Catapult: Use isLetter to fix locale issues in some languages. Change-Id: I253139ab3a93a9b48d3158f790e3975f776ce666 commit 96d1198ec28e5b858aa5cda268eecdf2335c6cf2 Author: Danesh Mondegarian <danesh@cyngn.com> Date: Fri Aug 8 23:30:15 2014 -0700 Catapult : Improve scrubber 9patch Change-Id: Ide249c0fe269d2f8966c753f6fdd9c1f673a0df9 commit 4920d0fdd94f7b0df6fccc3d16f5b98cbf4d19a2 Author: Danesh M <danesh@cyngn.com> Date: Fri Aug 8 15:44:20 2014 -0700 Catapult : Improve app drawer perf Change-Id: I78f699dbeac2618dceaa463940175e33ce685677 commit 10004f024b01029b2c137520407cefb5568b8c47 Author: Raj Yengisetty <rajesh@cyngn.com> Date: Thu Feb 26 11:42:17 2015 -0800 Remove scrubber swipe logic from Workspace Change-Id: I44d94a412ccdb60ce0f537fd6ddb71c2daffc906 Change-Id: Ibf6152352520ece4dff201b8013378a1ad562894 * Automatic translation importMichael Bestas2015-03-061-1/+1 | | | | Change-Id: I5c2d43a14e06c3ccc6297eff0950e061619d9b76 * Fix: Dynamic Grid resizing for custom valuesRaj Yengisetty2015-03-031-1/+12 | | | | | | | | | | | | Update the grid when the custom values are changed Repro: - Set custom grid to 7x7 - press home and observe grid is updated to 7x7 - Set custom grid to 2x3 - press home and observe that the grid isn't updated Change-Id: I8284eff08a96992b01b406ec1bff61f38d0ca683 * Automatic translation importMichael Bestas2015-02-285-3/+48 | | | | Change-Id: Iee67f7ef3d7e8e897b4f9d9aaabba65a1387a9d7 * Trebuchet: Live Settings - stop loader before reloading dynamic gridRaj Yengisetty2015-02-271-0/+1 | | | | Change-Id: Idcbbde7b7a5421ffffb5c130e2515e5305faddb8 * Revert "Adding manage apps shortcut to Settings panel"stable/cm-12.0-YNG1IRajesh Yengisetty2015-02-2013-56/+1 | | | | | | This reverts commit cc342519488d50d2f59f514940de6cf02bd53ab2. Change-Id: I8f5c593f93c4706127d2c0473f59abcd74776e47 * Automatic translation importMichael Bestas2015-02-188-3/+9 | | | | Change-Id: Ib5eeda694bee1014c2487391415daa6d4ed33ef0 * Fix potential NPE handling TransitionEffectsFragmentemancebo2015-02-171-15/+17 | | | | | | | | Instead of holding a reference to transition effects fragment and attempting to keep it in sync with what the fragment manager holds, just get the fragment from the manager each time. Change-Id: Ifd92725c1731cc6677d6d2a06226e070fbc093e3 * Remove CAF Chinese translationsMichael Bestas2015-02-101-3/+0 | | | | | | * They conflict with our imported ones from crowdin Change-Id: I6c256aab4562000cca8860683498618ce37985ac * Automatic translation importMichael Bestas2015-02-1089-212/+3744 | | | | Change-Id: I83039b635d95dc8999ffd9c13e28691ebb59dbb3 * Trebuchet: Catch SQLiteReadOnlyException.Adnan Begovic2015-02-101-0/+2 | | | | | | | | | | | | | | BUGDUMP-648580 android.database.sqlite.SQLiteReadOnlyDatabaseException: attempt to write a readonly database (code 1032) at android.database.sqlite.SQLiteConnection.nativeExecuteForChangedRowCount(Native Method) at android.database.sqlite.SQLiteConnection.executeForChangedRowCount(SQLiteConnection.java:736) at android.database.sqlite.SQLiteSession.executeForChangedRowCount(SQLiteSession.java:754) at android.database.sqlite.SQLiteStatement.executeUpdateDelete(SQLiteStatement.java:64) at android.database.sqlite.SQLiteDatabase.delete(SQLiteDatabase.java:1499) at com.android.launcher3.WidgetPreviewLoader.clearDb(WidgetPreviewLoader.java:379) ... Change-Id: I5e3cbd85a2fba84263b1e6df25f00f98b1ef55c0 * Filter apps for app drawer only after mApps is completely populated.Matt Garnes2015-02-091-4/+3 | | | | | | | | | | If mPreInstallConfig is set to true, apps will be added to mApps for display in the drawer after mFilteredApps is filtered from mApps. This results in applications being hidden from view that should not be. Filter mApps into mFilteredApps only after addPreInstallApps has been called. Change-Id: Ic426c5e530ffa61e0cbca211a6a32fcba38fc08b * Trebuchet : Update default workspaceDanesh M2015-02-033-136/+342 | | | | Change-Id: I14bde38a64d4f85196fb624226da20460e516ea1 * Trebuchet: ensure preview animation is released after exiting ↵emancebo2015-02-032-0/+13 | | | | | | | TransitionEffectsFragment Change-Id: Id6253a6162ee47dd1a46886026f09c3adbdc7027 (cherry picked from commit a426812f58b320c191ed8427d145966724949d67) * DynamicGrid: tuning the icon size for some deviceRaj Yengisetty2015-01-291-5/+5 | | | | Change-Id: I2cd5cdb8c7ab41edbc6baa80f04278a614aeac82 * Make workspace during preview largerlinus_lee2015-01-291-1/+1 | | | | | | | | | Initially looked at tying the size to be different based on the soft navigiation bar, but that turned out to be a lot larger, so sticking with a simple bump in the preview for now Change-Id: I12f769350f036178731b334d83c04f9facee5cb5 * Update Larger icons setting for better usabilityRaj Yengisetty2015-01-231-19/+19 | | | | Change-Id: I6e4f0411dc860c7312952275ebcea2b516ecd172 * Fix settings pane button alignment.Danny Baumann2015-01-2210-57/+25 | | | | | | | | The addition of the manage apps button caused unnecessary line wraps for some languages (e.g. DE), and the manage apps icon had a size different from the other icons in that pane. Change-Id: I3faaf32d9826a817250190517583764a2574bfb0 * Adding manage apps shortcut to Settings panelRaj Yengisetty2015-01-2013-3/+64 | | | | Change-Id: I02b454072258d57e82c825417941382ea7807e83 * Fix bug with toggling SearchBar off:Raj Yengisetty2015-01-191-1/+4 | | | | | | | | | Precondition, have Search Bar turned on. 1) Open Settings pannel 2) Toggle Search Bar to off 3) Press "home" to return to Launcher Change-Id: Idda7ed44ee0d6d172845d1447893280569147f7c * Disable voice button proxy when there is no voice searchRaj Yengisetty2015-01-161-2/+2 | | | | Change-Id: I54549b4c69cec5811ab261ac1213b9b4e67e8551 * Revert "Add default wallpaper to launcher"Rajesh Yengisetty2015-01-161-8/+0 | | | | | | This reverts commit d762349337161b4ecda6465f43fe841d3e4ece48. Change-Id: I2f003906f04a72868b6791ca53503df7dd32837a * Add default wallpaper to launcherhuiwan2015-01-131-0/+8 | | | | | | | - Add resource to wallpapers.xml to specify a default wallpaper in wallpaper picker. Change-Id: Ie8dd73de8f23a8963ab9b4f97a4bdcfc657d864b * Update workspace grid after toggling settings.Danny Baumann2015-01-102-5/+13 | | | | Change-Id: I851023e47fe12e434357962ee5f5b55b761da4c7 * Trebuchet: Remove unused stringsMichael Bestas2015-01-091-65/+10 | | | | Change-Id: I7ad2ad27bca77aaae654c678acdc7447125a20da * Shrink spacers in settings button panel.Danny Baumann2015-01-021-4/+4 | | | | | | | Previously there was not enough space for the button labels in some languages (e.g. German). Change-Id: I086908c0777e996ef37b0a3a4ea919f2d1c3f4cc
{ "url": "https://git.replicant.us/mirrors/LineageOS/android_packages_apps_Trebuchet/log/?h=staging/cm-12.1&showmsg=1", "source_domain": "git.replicant.us", "snapshot_id": "crawl=CC-MAIN-2020-50", "warc_metadata": { "Content-Length": "64187", "Content-Type": "application/http; msgtype=response", "WARC-Block-Digest": "sha1:CVSXOVXJDH44XRG36ZHNH5LYA6LYH2M5", "WARC-Concurrent-To": "<urn:uuid:ec857a3c-9ff3-4a8b-ba4c-15437569e1f6>", "WARC-Date": "2020-12-05T15:40:27Z", "WARC-IP-Address": "18.4.89.63", "WARC-Identified-Payload-Type": "application/xhtml+xml", "WARC-Payload-Digest": "sha1:KKTTELRNXB7KNUL6I6TD42OEFVAN33MZ", "WARC-Record-ID": "<urn:uuid:94efd595-d978-4702-9afb-13a057391df4>", "WARC-Target-URI": "https://git.replicant.us/mirrors/LineageOS/android_packages_apps_Trebuchet/log/?h=staging/cm-12.1&showmsg=1", "WARC-Truncated": null, "WARC-Type": "response", "WARC-Warcinfo-ID": "<urn:uuid:f2c98935-a552-4fbc-aaa3-ac2dbad45568>" }, "warc_info": "isPartOf: CC-MAIN-2020-50\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November/December 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-10.ec2.internal\r\nsoftware: Apache Nutch 1.17 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/" }
{ "line_start_idx": [ 0, 34, 79, 179, 306, 368, 457, 531, 600, 684, 929, 994, 1063, 1158, 1468, 1562, 1631, 1729, 2027, 2093, 2162, 2249, 2537, 2639, 2936, 3003, 3395, 3461, 3530, 3604, 3737, 3793, 3906, 3987, 4048, 4120, 4260, 4328, 4389, 4482, 4596, 4691, 4970, 5039, 5100, 5208, 5269, 5331, 5464, 5556, 5617, 5694, 12231, 12292, 12353, 12431, 12717, 12779, 12840, 12941, 13002, 13114, 13241, 13302, 13363, 13444, 13697, 13761, 13878, 13945, 14006, 14079, 14810, 14908, 15266, 15333, 15394, 15485, 15647, 15729, 15790, 15854, 16105, 16188, 16249, 16319, 16568, 16648, 16709, 16778, 16980, 17069, 17130, 17208, 17335, 17393, 17545, 17624, 17685, 17752, 17813, 17885 ], "line_end_idx": [ 34, 79, 179, 306, 368, 457, 531, 600, 684, 929, 994, 1063, 1158, 1468, 1562, 1631, 1729, 2027, 2093, 2162, 2249, 2537, 2639, 2936, 3003, 3395, 3461, 3530, 3604, 3737, 3793, 3906, 3987, 4048, 4120, 4260, 4328, 4389, 4482, 4596, 4691, 4970, 5039, 5100, 5208, 5269, 5331, 5464, 5556, 5617, 5694, 12231, 12292, 12353, 12431, 12717, 12779, 12840, 12941, 13002, 13114, 13241, 13302, 13363, 13444, 13697, 13761, 13878, 13945, 14006, 14079, 14810, 14908, 15266, 15333, 15394, 15485, 15647, 15729, 15790, 15854, 16105, 16188, 16249, 16319, 16568, 16648, 16709, 16778, 16980, 17069, 17130, 17208, 17335, 17393, 17545, 17624, 17685, 17752, 17813, 17885, 18044 ] }
{ "red_pajama_v2": { "ccnet_original_length": 18044, "ccnet_original_nlines": 101, "rps_doc_curly_bracket": 0, "rps_doc_ldnoobw_words": 0, "rps_doc_lorem_ipsum": 0, "rps_doc_stop_word_fraction": 0.1050431877374649, "rps_doc_ut1_blacklist": 0, "rps_doc_frac_all_caps_words": 0.0036221800837665796, "rps_doc_frac_lines_end_with_ellipsis": 0, "rps_doc_frac_no_alph_words": 0.5252159237861633, "rps_doc_frac_unique_words": 0.4186335504055023, "rps_doc_mean_word_length": 8.784472465515137, "rps_doc_num_sentences": 115, "rps_doc_symbol_to_word_ratio": 0.00027863000286743045, "rps_doc_unigram_entropy": 5.787709712982178, "rps_doc_word_count": 1610, "rps_doc_frac_chars_dupe_10grams": 0, "rps_doc_frac_chars_dupe_5grams": 0.08074665814638138, "rps_doc_frac_chars_dupe_6grams": 0.068867988884449, "rps_doc_frac_chars_dupe_7grams": 0.06405995786190033, "rps_doc_frac_chars_dupe_8grams": 0.025878529995679855, "rps_doc_frac_chars_dupe_9grams": 0, "rps_doc_frac_chars_top_2gram": 0.013575620017945766, "rps_doc_frac_chars_top_3gram": 0.024888640269637108, "rps_doc_frac_chars_top_4gram": 0.03167644888162613, "rps_doc_books_importance": -2213.893310546875, "rps_doc_books_importance_length_correction": -2213.893310546875, "rps_doc_openwebtext_importance": -1599.24560546875, "rps_doc_openwebtext_importance_length_correction": -1599.24560546875, "rps_doc_wikipedia_importance": -1176.7884521484375, "rps_doc_wikipedia_importance_length_correction": -1176.7884521484375 }, "fasttext": { "dclm": 1.0000100135803223, "english": 0.5680813789367676, "fineweb_edu_approx": 1.1159895658493042, "eai_general_math": 0.002435619942843914, "eai_open_web_math": 0.07982659339904785, "eai_web_code": 0.45676225423812866 } }
{ "free_decimal_correspondence": { "primary": { "code": "005.455", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computer programming" } }, "secondary": { "code": "004.02", "labels": { "level_1": "General works, books and libraries, information sciences", "level_2": "", "level_3": "Computers and Computer science" } } }, "bloom_cognitive_process": { "primary": { "code": "3", "label": "Apply" }, "secondary": { "code": "4", "label": "Analyze" } }, "bloom_knowledge_domain": { "primary": { "code": "3", "label": "Procedural" }, "secondary": { "code": "2", "label": "Conceptual" } }, "document_type_v1": { "primary": { "code": "4", "label": "Code/Software" }, "secondary": { "code": "3", "label": "Reference/Encyclopedic/Educational" } }, "extraction_artifacts": { "primary": { "code": "3", "label": "Irrelevant Content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "missing_content": { "primary": { "code": "0", "label": "No missing content" }, "secondary": { "code": "-1", "label": "Abstain" } }, "document_type_v2": { "primary": { "code": "8", "label": "Documentation" }, "secondary": { "code": "6", "label": "Content Listing" } }, "reasoning_depth": { "primary": { "code": "2", "label": "Basic Reasoning" }, "secondary": { "code": "3", "label": "Intermediate Reasoning" } }, "technical_correctness": { "primary": { "code": "4", "label": "Highly Correct" }, "secondary": { "code": "3", "label": "Mostly Correct" } }, "education_level": { "primary": { "code": "4", "label": "Graduate/Expert Level" }, "secondary": { "code": "3", "label": "Undergraduate Level" } } }
672f1e42c33a7f9846924a2431ea77df