id
int64 | text
string | metadata
dict | line_start_n_end_idx
dict | quality_signals
dict | eai_taxonomy
dict | pid
string |
|---|---|---|---|---|---|---|
5,051,505,931,009,155,000
|
Welcome to WebmasterWorld Guest from 54.205.251.179
Forum Moderators: bill & werty
Message Too Old, No Replies
Does displaying RSS feed means scraping?
1:27 pm on Apr 13, 2005 (gmt 0)
10+ Year Member
Is it Ok to use RSS feed of other sites and publish on your website. More specifically you just publish titles and for article you send visitor to original site.
11:46 am on Apr 20, 2005 (gmt 0)
10+ Year Member
This depends on what the individual RSS provider says you're allowed to do with the feed. Many RSS feed providers do allow what you're asking, but with some additional conditions / restrictions.
6:54 am on May 24, 2005 (gmt 0)
10+ Year Member
web sites that publically broadcast RSS feeds can't tell you what to do or not to do with that content. if they don't want you to do something with their feed then they need to either take their feed down or protect it in some manner.
6:56 am on May 24, 2005 (gmt 0)
WebmasterWorld Administrator mack is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month
It's always woth asking the site in question. Some sites offern an rss feed for use on a pc rss reader. Not for re-distribution on another website.
Mack.
6:59 am on May 24, 2005 (gmt 0)
10+ Year Member
if they don't want you to do something with their feed then they need to either take their feed down or protect it in some manner.
I think the protection most people use is commonly known as copyright.
12:07 am on May 27, 2005 (gmt 0)
10+ Year Member
think about it:
are there any feeds that bloglines.com blocks subscriptions to? and if not, why aren't they getting sued up the butt?
|
{
"url": "https://www.webmasterworld.com/forum98/230.htm",
"source_domain": "www.webmasterworld.com",
"snapshot_id": "crawl=CC-MAIN-2015-22",
"warc_metadata": {
"Content-Length": "32378",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:EUA672MLJBASSHD42YAGARZXJVF5QJWF",
"WARC-Concurrent-To": "<urn:uuid:ed116e21-92bc-4964-a307-8c2b1d8dc5b2>",
"WARC-Date": "2015-05-28T13:26:45Z",
"WARC-IP-Address": "72.10.193.101",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:U3N3XLSOCPWC6AGZ2ISETFSVULONGUZQ",
"WARC-Record-ID": "<urn:uuid:6f444a07-9fc7-4b21-8311-cff087b3bee3>",
"WARC-Target-URI": "https://www.webmasterworld.com/forum98/230.htm",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:10c7b3f1-cab1-486c-af34-dc0f85a89711>"
},
"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,
52,
53,
84,
85,
113,
114,
155,
156,
160,
192,
193,
209,
210,
211,
212,
374,
407,
408,
424,
425,
426,
427,
622,
654,
655,
671,
672,
673,
674,
909,
941,
942,
1070,
1071,
1072,
1073,
1221,
1222,
1228,
1229,
1261,
1262,
1278,
1279,
1280,
1281,
1412,
1413,
1484,
1517,
1518,
1534,
1535,
1536,
1537,
1553,
1554,
1672,
1673
],
"line_end_idx": [
52,
53,
84,
85,
113,
114,
155,
156,
160,
192,
193,
209,
210,
211,
212,
374,
407,
408,
424,
425,
426,
427,
622,
654,
655,
671,
672,
673,
674,
909,
941,
942,
1070,
1071,
1072,
1073,
1221,
1222,
1228,
1229,
1261,
1262,
1278,
1279,
1280,
1281,
1412,
1413,
1484,
1517,
1518,
1534,
1535,
1536,
1537,
1553,
1554,
1672,
1673,
1674
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1674,
"ccnet_original_nlines": 59,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 1,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.38320210576057434,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.015748029574751854,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2729658782482147,
"rps_doc_frac_unique_words": 0.49832776188850403,
"rps_doc_mean_word_length": 4.25083589553833,
"rps_doc_num_sentences": 19,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.702360153198242,
"rps_doc_word_count": 299,
"rps_doc_frac_chars_dupe_10grams": 0.20771045982837677,
"rps_doc_frac_chars_dupe_5grams": 0.2682926654815674,
"rps_doc_frac_chars_dupe_6grams": 0.2682926654815674,
"rps_doc_frac_chars_dupe_7grams": 0.22108575701713562,
"rps_doc_frac_chars_dupe_8grams": 0.20771045982837677,
"rps_doc_frac_chars_dupe_9grams": 0.20771045982837677,
"rps_doc_frac_chars_top_2gram": 0.03304484859108925,
"rps_doc_frac_chars_top_3gram": 0.037765540182590485,
"rps_doc_frac_chars_top_4gram": 0.0393390990793705,
"rps_doc_books_importance": -172.6249237060547,
"rps_doc_books_importance_length_correction": -159.57823181152344,
"rps_doc_openwebtext_importance": -92.56294250488281,
"rps_doc_openwebtext_importance_length_correction": -92.56294250488281,
"rps_doc_wikipedia_importance": -79.99764251708984,
"rps_doc_wikipedia_importance_length_correction": -69.0420913696289
},
"fasttext": {
"dclm": 0.03251051902770996,
"english": 0.9427475929260254,
"fineweb_edu_approx": 1.870589017868042,
"eai_general_math": 0.007040020078420639,
"eai_open_web_math": 0.06736273318529129,
"eai_web_code": 0.00008535000233678147
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.778",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "343.73",
"labels": {
"level_1": "Social sciences",
"level_2": "Law",
"level_3": "Criminal law"
}
}
},
"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": "-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": "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": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-4,606,608,377,243,301,400
|
Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}
Big Aggregate Queries Can Still Violate Privacy
DZone 's Guide to
Big Aggregate Queries Can Still Violate Privacy
Limiting queries to aggregates of large sets is not enough. You can still get the information you want from small sets based on the information in large sets.
· Big Data Zone ·
Free Resource
Suppose you want to prevent your data science team from being able to find out information on individual customers, but you do want them to be able to get overall statistics. So you implement two policies:
1. Data scientists can only query aggregate statistics, such as counts and averages.
2. These aggregate statistics must be based on results that return at least 1,000 database rows.
This sounds good, but it's naive. It's not enough to protect customer privacy.
Someone wants to know how much money customer 123456789 makes. If he asks for this person's income, the query would be blocked by the first rule. If he asks for the average income of customers with ID 123456789, then he gets past the first rule but not the second.
He decides to test whether the customer in question makes a six-figure income. So first, he queries for the number of customers with income over $100,000. This is a count, so it gets past the first rule. The result turns out to be 14,254, so it gets past the second rule as well. Now, he asks how many customers with ID not equal to 123456789 have income over $100,000. This is a valid query, as well, and returns 14,253. So by executing only queries that return aggregate statistics on thousands of rows, he found out that customer 123456789 has at least a six-figure income.
Now he goes back and asks for the average income of customers with income over $100,000. Then he asks for the average income of customers with income over $100,000 and with ID not equal to 123456789. With a little algebra, he's able to find customer 123456789's exact income.
You might object that it's cheating to have a clause such as "ID not equal 123456789" in a query. Of course it's cheating. It clearly violates the spirit of the law, but not the letter. You might try to patch the rules by saying you cannot ask questions about a small set, nor about the complement of a small set. (Readers familiar with measure theory might sense a σ-algebra lurking in the background...)
That doesn't work either. Someone could run queries on customers with ID less than or equal to 123456789 and on customers with ID greater than or equal to 123456789. Both these sets and their complements may be large but they let you find out information on an individual.
You may be asking, Why let a data scientist have access to customer IDs at all? Obviously, you wouldn't do that if you wanted to protect customer privacy. The point of this example is that limiting queries to aggregates of large sets is not enough. You can find out information on small sets from information on large sets. This could still be a problem with obvious identifiers removed.
Topics:
privacy ,big data ,queries ,data analytics ,aggregation ,data science
Published at DZone with permission of
Opinions expressed by DZone contributors are their own.
{{ parent.title || parent.header.title}}
{{ parent.tldr }}
{{ parent.urlSource.name }}
|
{
"url": "https://dzone.com/articles/big-aggregate-queries-can-still-violate-privacy?fromrel=true",
"source_domain": "dzone.com",
"snapshot_id": "crawl=CC-MAIN-2019-26",
"warc_metadata": {
"Content-Length": "126089",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:PSI5PPO7HF6YHY4PUYGDBV77FUGJIPGA",
"WARC-Concurrent-To": "<urn:uuid:45bda229-5026-40d2-9181-5718643c66c8>",
"WARC-Date": "2019-06-25T02:26:57Z",
"WARC-IP-Address": "34.232.187.43",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:3Q4BODAUFAAB3LT3FF7APYZJDWTZPVMI",
"WARC-Record-ID": "<urn:uuid:ac3bc368-8fe5-4180-8323-59735a4a672c>",
"WARC-Target-URI": "https://dzone.com/articles/big-aggregate-queries-can-still-violate-privacy?fromrel=true",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:901eb9f7-c2a5-4f01-8f9e-fac493f174b9>"
},
"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-154-184-81.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,
45,
67,
90,
91,
139,
140,
158,
159,
207,
208,
367,
368,
386,
400,
401,
607,
608,
695,
794,
795,
874,
875,
1140,
1141,
1718,
1719,
1995,
1996,
2402,
2403,
2676,
2677,
3065,
3066,
3074,
3144,
3145,
3183,
3184,
3240,
3241,
3282,
3283,
3301,
3302
],
"line_end_idx": [
45,
67,
90,
91,
139,
140,
158,
159,
207,
208,
367,
368,
386,
400,
401,
607,
608,
695,
794,
795,
874,
875,
1140,
1141,
1718,
1719,
1995,
1996,
2402,
2403,
2676,
2677,
3065,
3066,
3074,
3144,
3145,
3183,
3184,
3240,
3241,
3282,
3283,
3301,
3302,
3329
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3329,
"ccnet_original_nlines": 45,
"rps_doc_curly_bracket": 0.00600781012326479,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.41040462255477905,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.008670520037412643,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.19508670270442963,
"rps_doc_frac_unique_words": 0.39426523447036743,
"rps_doc_mean_word_length": 4.697132587432861,
"rps_doc_num_sentences": 46,
"rps_doc_symbol_to_word_ratio": 0.0014450900489464402,
"rps_doc_unigram_entropy": 4.966385364532471,
"rps_doc_word_count": 558,
"rps_doc_frac_chars_dupe_10grams": 0.08317436277866364,
"rps_doc_frac_chars_dupe_5grams": 0.2121327668428421,
"rps_doc_frac_chars_dupe_6grams": 0.17283479869365692,
"rps_doc_frac_chars_dupe_7grams": 0.13048455119132996,
"rps_doc_frac_chars_dupe_8grams": 0.09919878095388412,
"rps_doc_frac_chars_dupe_9grams": 0.09919878095388412,
"rps_doc_frac_chars_top_2gram": 0.034719571471214294,
"rps_doc_frac_chars_top_3gram": 0.022892029955983162,
"rps_doc_frac_chars_top_4gram": 0.022892029955983162,
"rps_doc_books_importance": -362.27789306640625,
"rps_doc_books_importance_length_correction": -362.27789306640625,
"rps_doc_openwebtext_importance": -209.4286651611328,
"rps_doc_openwebtext_importance_length_correction": -209.4286651611328,
"rps_doc_wikipedia_importance": -140.49142456054688,
"rps_doc_wikipedia_importance_length_correction": -140.49142456054688
},
"fasttext": {
"dclm": 0.6218234896659851,
"english": 0.9504275918006897,
"fineweb_edu_approx": 2.0665605068206787,
"eai_general_math": 0.8254616856575012,
"eai_open_web_math": 0.26137542724609375,
"eai_web_code": 0.5754135847091675
}
}
|
{
"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": "352.3",
"labels": {
"level_1": "Social sciences",
"level_2": "Public administration and Military art and science",
"level_3": "Local government"
}
}
},
"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": "3",
"label": "Reference/Encyclopedic/Educational"
},
"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": "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
|
-8,464,328,058,125,810,000
|
Wisa meaning
(WIreless Speaker and Audio) A wireless audio standard from the WiSA Association, Sunnyvale, CA, www.wisaassociation.org. WiSA is used to transmit multichannel, high-definition audio wirelessly between A/V components. Debuting in 2011 and pronounced "why-suh," WiSA supports up to eight channels of uncompressed digital audio at 96 kHz, 24-bit resolution (see 96/24).The speakers must be identified for the WiSA transmitting device, such as a TV, Blu-ray player or stand-alone WiSA transmitter (see image below). This can be done manually on a TV or tablet, or automatically with speakers that ultrasonically "ping" each other to detect locations and channel assignments.Adjust the Sweet Spot for Better ListeningWhen listening to a WiSA-compliant home theater, users can identify their current location in the room, and the system adjusts speaker delay and volume to make their seat the sweet spot for listening.The Unlicensed U-NII BandTransmitting in the unlicensed U-NII 5 GHz band, WiSA uses dynamic frequency selection (DFS) to change channels when interference is detected. WiSA transmitters are always looking ahead for another channel to switch to if necessary (see U-NII). See high-resolution audio.
0
0
(Internet) Windows, Internet, Server, Active servers: A collection of Microsoft technologies that can be used to create "dynamic websites", specifically: The Windows operating system, Internet Information Services (web server), Microsoft SQL server (database) and active server pages (scripting language).
acronym
0
0
Advertisement
|
{
"url": "https://www.yourdictionary.com/wisa",
"source_domain": "www.yourdictionary.com",
"snapshot_id": "crawl=CC-MAIN-2021-21",
"warc_metadata": {
"Content-Length": "82517",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:TM44NRZHOMU2Q57XKUJCV7KLYOFC3HZU",
"WARC-Concurrent-To": "<urn:uuid:42ca3a05-0208-4973-a5bb-c3b69f2cf13b>",
"WARC-Date": "2021-05-11T17:26:51Z",
"WARC-IP-Address": "52.85.144.129",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:GW7X2XBJWWBAHSWXQJTUILV7GSURSQ5Y",
"WARC-Record-ID": "<urn:uuid:dd5f883b-1274-4518-ac90-d081e318575b>",
"WARC-Target-URI": "https://www.yourdictionary.com/wisa",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5061f72f-af74-4d03-938b-26051b096aaa>"
},
"warc_info": "isPartOf: CC-MAIN-2021-21\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-245.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,
13,
14,
1224,
1226,
1228,
1534,
1542,
1544,
1546
],
"line_end_idx": [
13,
14,
1224,
1226,
1228,
1534,
1542,
1544,
1546,
1559
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1559,
"ccnet_original_nlines": 9,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.25827816128730774,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.049668870866298676,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.23509934544563293,
"rps_doc_frac_unique_words": 0.6517857313156128,
"rps_doc_mean_word_length": 5.65625,
"rps_doc_num_sentences": 13,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.7500996589660645,
"rps_doc_word_count": 224,
"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.011049720458686352,
"rps_doc_frac_chars_top_3gram": 0.01894238032400608,
"rps_doc_frac_chars_top_4gram": 0.02367798052728176,
"rps_doc_books_importance": -114.66919708251953,
"rps_doc_books_importance_length_correction": -102.18608856201172,
"rps_doc_openwebtext_importance": -76.71886444091797,
"rps_doc_openwebtext_importance_length_correction": -76.71886444091797,
"rps_doc_wikipedia_importance": -39.70332717895508,
"rps_doc_wikipedia_importance_length_correction": -25.99800682067871
},
"fasttext": {
"dclm": 0.03876674175262451,
"english": 0.8520784378051758,
"fineweb_edu_approx": 2.306055784225464,
"eai_general_math": 0.06735754013061523,
"eai_open_web_math": 0.21028900146484375,
"eai_web_code": 0.06951385736465454
}
}
|
{
"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": "781.5",
"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": "1",
"label": "Factual"
},
"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": "10",
"label": "Knowledge Article"
},
"secondary": {
"code": "8",
"label": "Documentation"
}
},
"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,392,325,309,203,259,000
|
The sequence of interactions between CLR loader and fusion during Assembly.Load
The following describes roughly the sequence of interactions between CLR loader and fusion during Assembly.Load() in .Net framework 2.0.
1. User calls Assembly.Load.
2. Loader pass the assembly reference to fusion.
3. Fusion checks to see if the assembly has already loaded. If it is, the assembly is returned.
4. If not, fusion probes the assembly as described in MSDN. If fusion cannot find the assembly, it returns a failure.
5. If fusion finds an assembly, it asks loader to crack the metadata of the assembly.
6. Loader maps the assembly, usually using file mapping, and cracks the metadata of the assembly. Loader also stores the file mapping in a process wide cache.
7. After fusion gets the metadata of the assembly, it does a ref-def matching. If the check fails, fusion returns error.
8. Otherwise, fusion puts the assembly in a cache, and returns the assembly to loader.
9. Loader does some additional checks. If the checks are good, Loader loads the assembly by calling LoadLibrary.
10. After LoadLibrary, Loader does one more check to make sure the assembly did not change between the original file mapping and LoadLibrary. If the file has changed, Loader throws ref/def mismatch FileLoadException.
11. If everything is good, Loader returns the assembly.
Comments (3)
1. fatima says:
Hi,thank u so much but still i’m not check my computer.This comment a few word just for i to respect your side.
many thanks,
Fatima
2. CoqBlog says:
Je viens de voir un post intéressant de Junfeng Zhang sur le déroulement du chargement d’un assembly
|
{
"url": "https://blogs.msdn.microsoft.com/junfeng/2007/08/06/the-sequence-of-interactions-between-clr-loader-and-fusion-during-assembly-load/",
"source_domain": "blogs.msdn.microsoft.com",
"snapshot_id": "crawl=CC-MAIN-2016-44",
"warc_metadata": {
"Content-Length": "40799",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:U7MQUY2WK35ZZFQ4ZVVZT27FUBMYQNJI",
"WARC-Concurrent-To": "<urn:uuid:15475c29-601e-4d8f-bac3-a6b3ecaf6ed3>",
"WARC-Date": "2016-10-27T11:34:55Z",
"WARC-IP-Address": "23.196.118.61",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:XTJVRB3237ZCRSGEYI3M2PFDNL5K3ZAK",
"WARC-Record-ID": "<urn:uuid:e74b93f6-5a01-4163-a590-4d5ffc2f5dad>",
"WARC-Target-URI": "https://blogs.msdn.microsoft.com/junfeng/2007/08/06/the-sequence-of-interactions-between-clr-loader-and-fusion-during-assembly-load/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:284d52eb-8f46-4f97-ac34-3f704e0a7384>"
},
"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,
80,
81,
82,
219,
220,
221,
250,
251,
252,
301,
302,
303,
399,
400,
401,
519,
520,
521,
607,
608,
609,
768,
769,
770,
891,
892,
893,
980,
981,
982,
1095,
1096,
1097,
1314,
1315,
1316,
1372,
1373,
1386,
1387,
1405,
1406,
1522,
1523,
1540,
1541,
1552,
1553,
1572,
1573
],
"line_end_idx": [
80,
81,
82,
219,
220,
221,
250,
251,
252,
301,
302,
303,
399,
400,
401,
519,
520,
521,
607,
608,
609,
768,
769,
770,
891,
892,
893,
980,
981,
982,
1095,
1096,
1097,
1314,
1315,
1316,
1372,
1373,
1386,
1387,
1405,
1406,
1522,
1523,
1540,
1541,
1552,
1553,
1572,
1573,
1677
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1677,
"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.31778424978256226,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.008746360428631306,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.23032070696353912,
"rps_doc_frac_unique_words": 0.5148147940635681,
"rps_doc_mean_word_length": 4.803703784942627,
"rps_doc_num_sentences": 39,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.456648826599121,
"rps_doc_word_count": 270,
"rps_doc_frac_chars_dupe_10grams": 0.10485736280679703,
"rps_doc_frac_chars_dupe_5grams": 0.1603700816631317,
"rps_doc_frac_chars_dupe_6grams": 0.10485736280679703,
"rps_doc_frac_chars_dupe_7grams": 0.10485736280679703,
"rps_doc_frac_chars_dupe_8grams": 0.10485736280679703,
"rps_doc_frac_chars_dupe_9grams": 0.10485736280679703,
"rps_doc_frac_chars_top_2gram": 0.11873553693294525,
"rps_doc_frac_chars_top_3gram": 0.030069390311837196,
"rps_doc_frac_chars_top_4gram": 0.03700847923755646,
"rps_doc_books_importance": -157.4503173828125,
"rps_doc_books_importance_length_correction": -144.49708557128906,
"rps_doc_openwebtext_importance": -85.67808532714844,
"rps_doc_openwebtext_importance_length_correction": -85.67808532714844,
"rps_doc_wikipedia_importance": -59.9548454284668,
"rps_doc_wikipedia_importance_length_correction": -49.179168701171875
},
"fasttext": {
"dclm": 0.988466739654541,
"english": 0.803492546081543,
"fineweb_edu_approx": 2.228227138519287,
"eai_general_math": 0.648107647895813,
"eai_open_web_math": 0.26878637075424194,
"eai_web_code": 0.1183425784111023
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.13",
"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": "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": "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": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
9,010,299,637,193,834,000
|
Registry Keys and Values for Backup and Restore
Applications that request or perform backup and restore operations should use the following registry keys and values to communicate with each other or with features such as the Volume Shadow Copy Service (VSS) and Windows Backup:
CustomPerformanceSettings
See OverallPerformanceSetting and CustomPerformanceSettings.
DisableMonitoring
On Windows client platforms beginning with Windows 7, users are automatically prompted to configure the Windows Backup feature if they have not already done so. These notifications appear at computer startup time, beginning seven days after the operating system is installed. They also appear when the user plugs in a hard disk drive; in this case, the notifications appear immediately.
OEMs and developers of third-party backup applications can use the DisableMonitoring registry value to turn off these automatic notifications.
This value does not exist by default, so it must be created under the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsBackup
The DisableMonitoring registry value has the data type REG_DWORD and is interpreted as follows:
• If the value's data is set to 1 and if users have not already configured the Windows Backup feature, the automatic notifications are turned off. If an automatic notification is already present in Action Center, setting this registry value causes the notification to be removed at 10:00 the following morning.
• If the value does not exist, if its data is not set, or if its data is set to zero, the automatic notifications are not turned off.
Windows Vista and Windows XP: This registry value is not supported.
FilesNotToBackup
The FilesNotToBackup registry key specifies the names of the files and directories that backup applications should not backup or restore. Each of the entries in this key is a REG_MULTI_SZ string in the following format:
[Drive][Path]\FileName [/s]
• Drive specifies the drive and is optional. For example, c:. To specify all drives, use a backslash (\); no drive letters are needed.
• Path specifies the path and is optional. It cannot contain wildcard characters.
• FileName specifies the file or directory and is required. It can contain wildcard characters.
• /s specifies that all subdirectories of the specified path are to be included.
• Environment variables such as %Systemroot% can be substituted for all or part of the entire string.
The following table shows some typical entries.
Entry name Default value
Internet Explorer Temporary Files
Memory Page File \Pagefile.sys
MS Distributed Transaction Coordinator C:\Windows\system32\MSDtc\MSDTC.LOG C:\Windows\system32\MSDtc\trace\dtctrace.log
Offline Files Cache %Systemroot%\CSC\* /s
Power Management \hiberfil.sys
Single Instance Storage \SIS Common Store\*.* /s
Temporary Files %TEMP%\* /s
Note
Applications that perform volume-level backups generally do so by copying the entire volume at the block level, so they cannot honor the FilesNotToBackup registry key at backup time. Instead, they wait until restore time to delete the files that were not to be backed up. In most cases, this is a reasonable strategy. However, in the case of Single Instance Storage files, the SIS Common Store files must not be deleted at restore time.
For block-level volume backups, Windows Server Backup and the Windows Wbadmin utility honor the FilesNotToBackup registry key by deleting the appropriate files at restore time. System Restore and System State Backup do not honor the FilesNotToBackup registry key.
Windows XP: System Restore honors the FilesNotToBackup registry key.
FilesNotToSnapshot
VSS supports the FilesNotToSnapshot registry key. Applications and services can use this key to specify files to be deleted from newly created shadow copies. For more information, see Excluding Files from Shadow Copies.
Windows Server 2003 and Windows XP: This registry key is not supported.
For block-level volume backups, Windows Server Backup honors the FilesNotToSnapshot registry key by deleting the appropriate files at restore time.
IdleTimeout
The IdleTimeout registry value specifies the amount of time, in seconds, that the VSS service will wait when it is idle. If this timeout value is reached and there are no tasks for it to perform, the VSS service will shut down.
This registry value can be found under the following registry key:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\VSS\Settings
If this registry value does not exist:
• The actual timeout value that is used is 180 seconds (3 minutes) by default.
• You can create a value with the name IdleTimeout and the type DWORD and set it to the desired value.
If this registry value is set to 0 seconds:
• The actual timeout value that is used is 180 seconds (3 minutes).
If you set this registry value:
• VSS uses the timeout value that you set.
• You can specify any value between 1 and FFFFFFFF seconds. However, it is recommended that you choose a value between 1 and 180 seconds.
Windows Server 2003 and Windows XP: This registry key is not supported.
KeysNotToRestore
The KeysNotToRestore registry key specifies the names of the registry subkeys and values that backup applications should not restore. For more information, see KeysNotToRestore. It is not necessary to honor the KeysNotToRestore registry key.
Windows Server 2003 and Windows XP: You must honor the KeysNotToRestore registry key.
For block-level volume backups, Windows Server Backup honors the KeysNotToRestore registry key by deleting the appropriate files at restore time.
System State Backup honors the KeysNotToRestore registry key.
LastInstance
The LastInstance registry value indicates that a bare-metal restore operation has been performed and that the volumes have been overwritten but not formatted. For more information, see Using VSS Automated System Recovery for Disaster Recovery.
Windows Server 2003 and Windows XP: This registry value is not supported.
LastRestoreId
When a backup application performs a system state restore, it must indicate that it has done so by setting the LastRestoreId registry value. "System state restore" in this case refers to any restore that selectively restores operating system binaries and drivers.
If the entire boot and system volume are restored at the volume level, this value must not be set.
If the LastRestoreId registry value does not exist, the backup application should create it under the following registry key:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\BackupRestore\SystemStateRestore
Create a value with the name LastRestoreId and type REG_SZ. The value should be a unique opaque value such as a GUID.
Whenever a new system state restore is performed, the backup application should change the data of the LastRestoreId value.
Other applications that need to monitor system state restores should store the data of this registry value. This data can be compared against the current data of the LastRestoreId registry value to determine whether a new system state restore has been performed.
Windows Vista, Windows Server 2003 and Windows XP: This registry value is not supported until Windows Vista with Service Pack 1 (SP1) and Windows Server 2008.
MaxShadowCopies
The MaxShadowCopies registry value specifies the maximum number of client-accessible shadow copies that can be stored on each volume of the computer. A client-accessible shadow copy is a shadow copy that is created using the VSS_CTX_CLIENT_ACCESSIBLE value of the _VSS_SNAPSHOT_CONTEXT enumeration. Client-accessible shadow copies are used by Shadow Copies for Shared Folders. For more information about shadow copies, see the VSS documentation.
If the MaxShadowCopies registry value does not exist, the backup application can create it under the following registry key:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\VSS\Settings
Create a value with the name MaxShadowCopies and type DWORD. The default data for this value is 64. The minimum is 1. The maximum is 512.
Note
For other types of shadow copies, there is no registry value that corresponds to MaxShadowCopies. The maximum number of shadow copies is 512 per volume.
Note The MaxShadowCopies setting is supported on Windows Server 2003 or later.
Windows Server 2003: On cluster servers, MaxShadowCopies registry value's data may need to be set to a lower number. For more information, see "When you use the Volume Shadow Copy Service on Windows Server 2003-based computers that run many I/O operations, disk volumes take longer to go online" in the Help and Support Knowledge Base at https://support.microsoft.com/kb/945058.
Windows XP: This registry value is not supported.
MinDiffAreaFileSize
VSS allocates a shadow copy storage area (or "diff area") to store data for shadow copies. The minimum size of the shadow copy storage area is a per-computer setting that can be specified by using the MinDiffAreaFileSize registry value.
If the MinDiffAreaFileSize registry value is not set, the minimum size of the shadow copy storage area is 32 MB for volumes that are smaller than 500 MB and 320 MB for volumes that are larger than 500 MB.
Windows Server 2008, Windows Server 2003 with SP1 and Windows Vista: If the MinDiffAreaFileSize registry value is not set, the shadow copy storage area has a minimum size of 300 MB. If the MinDiffAreaFileSize registry value is set, its data must be between 300 MB and 3000 MB (3 GB), and it must be a multiple of 300 MB.
Windows Server 2003: If the MinDiffAreaFileSize registry value is not set, the minimum size of the shadow copy storage area is 100 MB.
Windows XP: This registry value is not supported.
If the MinDiffAreaFileSize registry value does not exist, the backup application can create it under the following registry key:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\VolSnap
Create a value with the name MinDiffAreaFileSize and type REG_DWORD. The data for this key is specified in megabytes. 320 is equal to 320 MB, and 3200 is equal to 3.2 GB. You should specify a number that is a multiple of 32. If you specify a value that is not a multiple of 32, the next multiple of 32 will be used.
Shadow copies might not function correctly if the MinDiffAreaFileSize registry value specifies a minimum size that is larger than the maximum size of the shadow copy storage area. To specify the maximum size of the shadow copy storage area, use the Vssadmin add shadowstorage or the Vssadmin resize shadowstorage command. To see the current maximum size, use the Vssadmin list shadowstorage command. If you have not set a maximum size, there is no limit to the amount of space that can be used.
OverallPerformanceSetting and CustomPerformanceSettings
The OverallPerformanceSetting and CustomPerformanceSettings registry values are used to specify performance settings for Windows Server Backup. These registry values are supported only on Windows server operating systems.
Windows Server 2003: These registry values are not supported.
If these registry values do not exist, the backup application can create them under the following registry key:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Windows Block Level Backup
To specify performances settings for all volumes, create a value with the name OverallPerformanceSetting and type REG_DWORD. The value's data should be set to one of the following values.
Value Meaning
1 Normal backup performance (by using full backups). This setting corresponds to the Normal backup performance setting described in Optimizing Backup and Server Performance.
2 Faster backup performance (by using incremental backups). This setting corresponds to the Faster backup performance setting described in Optimizing Backup and Server Performance.
3 Custom backup performance (by specifying a performance setting for each volume). This setting corresponds to the Custom setting described in Optimizing Backup and Server Performance.
If you set OverallPerformanceSetting to 3, you must also specify performances settings for each volume individually. To do this, create a value with the name CustomPerformanceSettings and type REG_MULTI_SZ. This value's data should be set as follows:
• Each string in the REG_MULTI_SZ sequence of strings contains the setting for a volume.
• Each string consists of a volume GUID, followed by a comma, followed by a DWORD value.
• Each of the DWORD values is either 1 (full backup) or 2 (incremental backup).
For example, suppose the computer has two volumes as follows:
• The two volumes are C:\ and D:\.
• The GUID for volume C:\ is 07c473ca4-2df8-11de-9d80-806e6f6e6963, and the GUID for volume D:\ is 0ac22ea6c-712f-11de-adb0-00215a67606e.
• You want to specify normal backup perfornance for volume C:\ and faster backup performance for volume D:\.
To do this, you would set OverallPerformanceSetting to 3 and CustomPerformanceSettings to "07c473ca4-2df8-11de-9d80-806e6f6e6963,1\00ac22ea6c-712f-11de-adb0-00215a67606e,2".
If you set OverallPerformanceSetting to 1 or 2, the data in the CustomPerformanceSettings value is ignored.
SYSVOL
The SYSVOL registry value is a way to notify the Distributed File System Replication (DFSR) service that a system state restore operation has been initiated. Any backup application that performs system state restore of SYSVOL should use this value to indicate whether the restore operation is authoritative or nonauthoritative. This value is read by the DFSR service. If this value is not set, the SYSVOL restore is performed nonauthoritatively by default.
If the SYSVOL registry value does not exist, the backup application should create it under the following registry key:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\DFSR\Restore
Create a value with the name SYSVOL and type REG_SZ. The value's data should be set to either "authoritative" or "non-authoritative" based on the system administrator's request.
Windows Vista, Windows Server 2003 and Windows XP: This registry value is not supported.
|
{
"url": "https://docs.microsoft.com/en-us/windows/win32/backup/registry-keys-for-backup-and-restore?redirectedfrom=MSDN",
"source_domain": "docs.microsoft.com",
"snapshot_id": "crawl=CC-MAIN-2022-27",
"warc_metadata": {
"Content-Length": "57034",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FWBSLR35Z44G5IE3OAJER2VDN3WIFVNU",
"WARC-Concurrent-To": "<urn:uuid:1bf1799c-147f-4c93-b40f-9d23956ed91c>",
"WARC-Date": "2022-06-28T10:48:57Z",
"WARC-IP-Address": "104.77.239.71",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:GYVRZTTKBIYZRJXITGYOGLSHWSQRQXEH",
"WARC-Record-ID": "<urn:uuid:855d9259-46c9-4ec9-be99-bcc383f10817>",
"WARC-Target-URI": "https://docs.microsoft.com/en-us/windows/win32/backup/registry-keys-for-backup-and-restore?redirectedfrom=MSDN",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:79c204bb-4e5a-4ff7-8319-b91e1cdbc28a>"
},
"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-252\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,
48,
49,
279,
280,
306,
307,
368,
369,
387,
388,
775,
776,
919,
920,
1014,
1015,
1090,
1091,
1187,
1188,
1501,
1637,
1638,
1706,
1707,
1724,
1725,
1945,
1946,
1974,
1975,
2112,
2196,
2294,
2377,
2481,
2482,
2530,
2531,
2556,
2590,
2621,
2741,
2783,
2814,
2863,
2891,
2892,
2894,
2895,
2900,
2901,
3338,
3339,
3341,
3342,
3606,
3607,
3676,
3677,
3696,
3697,
3917,
3918,
3990,
3991,
4139,
4140,
4152,
4153,
4381,
4382,
4449,
4450,
4516,
4517,
4556,
4557,
4638,
4743,
4744,
4788,
4789,
4859,
4860,
4892,
4893,
4938,
5078,
5079,
5151,
5152,
5169,
5170,
5412,
5413,
5499,
5500,
5646,
5647,
5709,
5710,
5723,
5724,
5968,
5969,
6043,
6044,
6058,
6059,
6323,
6324,
6423,
6424,
6550,
6551,
6636,
6637,
6755,
6756,
6880,
6881,
7144,
7145,
7304,
7305,
7321,
7322,
7768,
7769,
7894,
7895,
7961,
7962,
8100,
8101,
8106,
8107,
8260,
8261,
8263,
8264,
8344,
8345,
8724,
8725,
8775,
8776,
8796,
8797,
9034,
9035,
9240,
9241,
9562,
9563,
9698,
9699,
9749,
9750,
9879,
9880,
9941,
9942,
10258,
10259,
10754,
10755,
10811,
10812,
11034,
11035,
11097,
11098,
11210,
11211,
11299,
11300,
11488,
11489,
11503,
11677,
11858,
12043,
12044,
12046,
12047,
12298,
12299,
12390,
12481,
12563,
12564,
12626,
12627,
12664,
12804,
12915,
12916,
13090,
13091,
13199,
13200,
13207,
13208,
13665,
13666,
13785,
13786,
13852,
13853,
14031,
14032,
14121,
14122,
14124,
14125
],
"line_end_idx": [
48,
49,
279,
280,
306,
307,
368,
369,
387,
388,
775,
776,
919,
920,
1014,
1015,
1090,
1091,
1187,
1188,
1501,
1637,
1638,
1706,
1707,
1724,
1725,
1945,
1946,
1974,
1975,
2112,
2196,
2294,
2377,
2481,
2482,
2530,
2531,
2556,
2590,
2621,
2741,
2783,
2814,
2863,
2891,
2892,
2894,
2895,
2900,
2901,
3338,
3339,
3341,
3342,
3606,
3607,
3676,
3677,
3696,
3697,
3917,
3918,
3990,
3991,
4139,
4140,
4152,
4153,
4381,
4382,
4449,
4450,
4516,
4517,
4556,
4557,
4638,
4743,
4744,
4788,
4789,
4859,
4860,
4892,
4893,
4938,
5078,
5079,
5151,
5152,
5169,
5170,
5412,
5413,
5499,
5500,
5646,
5647,
5709,
5710,
5723,
5724,
5968,
5969,
6043,
6044,
6058,
6059,
6323,
6324,
6423,
6424,
6550,
6551,
6636,
6637,
6755,
6756,
6880,
6881,
7144,
7145,
7304,
7305,
7321,
7322,
7768,
7769,
7894,
7895,
7961,
7962,
8100,
8101,
8106,
8107,
8260,
8261,
8263,
8264,
8344,
8345,
8724,
8725,
8775,
8776,
8796,
8797,
9034,
9035,
9240,
9241,
9562,
9563,
9698,
9699,
9749,
9750,
9879,
9880,
9941,
9942,
10258,
10259,
10754,
10755,
10811,
10812,
11034,
11035,
11097,
11098,
11210,
11211,
11299,
11300,
11488,
11489,
11503,
11677,
11858,
12043,
12044,
12046,
12047,
12298,
12299,
12390,
12481,
12563,
12564,
12626,
12627,
12664,
12804,
12915,
12916,
13090,
13091,
13199,
13200,
13207,
13208,
13665,
13666,
13785,
13786,
13852,
13853,
14031,
14032,
14121,
14122,
14124,
14125,
14126
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 14126,
"ccnet_original_nlines": 217,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3648489713668823,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03491564840078354,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1698705404996872,
"rps_doc_frac_unique_words": 0.20476189255714417,
"rps_doc_mean_word_length": 5.4571428298950195,
"rps_doc_num_sentences": 125,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.13739013671875,
"rps_doc_word_count": 2100,
"rps_doc_frac_chars_dupe_10grams": 0.113001748919487,
"rps_doc_frac_chars_dupe_5grams": 0.2673647403717041,
"rps_doc_frac_chars_dupe_6grams": 0.21003490686416626,
"rps_doc_frac_chars_dupe_7grams": 0.16649214923381805,
"rps_doc_frac_chars_dupe_8grams": 0.1490401327610016,
"rps_doc_frac_chars_dupe_9grams": 0.1373472958803177,
"rps_doc_frac_chars_top_2gram": 0.03516579046845436,
"rps_doc_frac_chars_top_3gram": 0.01780105009675026,
"rps_doc_frac_chars_top_4gram": 0.01413612999022007,
"rps_doc_books_importance": -911.1466064453125,
"rps_doc_books_importance_length_correction": -911.1466064453125,
"rps_doc_openwebtext_importance": -523.839599609375,
"rps_doc_openwebtext_importance_length_correction": -523.839599609375,
"rps_doc_wikipedia_importance": -354.3533630371094,
"rps_doc_wikipedia_importance_length_correction": -354.3533630371094
},
"fasttext": {
"dclm": 0.023042980581521988,
"english": 0.7776081562042236,
"fineweb_edu_approx": 2.1961283683776855,
"eai_general_math": 0.8701311945915222,
"eai_open_web_math": 0.5640319585800171,
"eai_web_code": 0.5106514692306519
}
}
|
{
"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": "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": "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": "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": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-1,808,311,749,771,098,400
|
the paraslash-0.4.4 release tarball
[paraslash.git] / audiod.c
1 /*
2 * Copyright (C) 2005-2010 Andre Noll <maan@systemlinux.org>
3 *
4 * Licensed under the GPL v2. For licencing details see COPYING.
5 */
6
7 /** \file audiod.c the paraslash's audio daemon */
8 #include <regex.h>
9 #include <sys/types.h>
10 #include <dirent.h>
11 #include <signal.h>
12 #include <openssl/rc4.h>
13 #include <stdbool.h>
14
15 #include "para.h"
16 #include "error.h"
17 #include "crypt.h"
18 #include "audiod.cmdline.h"
19 #include "list.h"
20 #include "sched.h"
21 #include "ggo.h"
22 #include "recv.h"
23 #include "buffer_tree.h"
24 #include "filter.h"
25 #include "grab_client.h"
26 #include "client.cmdline.h"
27 #include "client.h"
28 #include "audiod.h"
29 #include "net.h"
30 #include "daemon.h"
31 #include "string.h"
32 #include "fd.h"
33 #include "write.h"
34 #include "write_common.h"
35 #include "signal.h"
36
37 /** define the array of error lists needed by para_audiod */
38 INIT_AUDIOD_ERRLISTS;
39 /** define the array containing all supported audio formats */
40 const char *audio_formats[] = {AUDIOD_AUDIO_FORMAT_ARRAY NULL};
41
42 /** Defines how audiod handles one supported audio format. */
43 struct audio_format_info {
44 /** pointer to the receiver for this audio format */
45 struct receiver *receiver;
46 /** the receiver configuration */
47 void *receiver_conf;
48 /** the number of filters that should be activated for this audio format */
49 unsigned int num_filters;
50 /** Array of filter numbers to be activated. */
51 unsigned *filter_nums;
52 /** Pointer to the array of filter configurations. */
53 void **filter_conf;
54 /** the number of filters that should be activated for this audio format */
55 unsigned int num_writers;
56 /** Array of writer numbers to be activated. */
57 int *writer_nums;
58 /** pointer to the array of writer configurations */
59 void **writer_conf;
60 /** do not start receiver/filters/writer before this time */
61 struct timeval restart_barrier;
62 };
63
64 /**
65 * para_audiod uses \p MAX_STREAM_SLOTS different slots, each of which may
66 * be associated with a receiver/filter/writer triple. This array holds all
67 * information on the status of these slots.
68 *
69 * \sa struct slot_info
70 * */
71 struct slot_info slot[MAX_STREAM_SLOTS];
72
73 /** The vss status flags audiod is interested in. */
74 enum vss_status_flags {
75 /** Whether the 'N' flag is set. */
76 VSS_STATUS_FLAG_NEXT = 1,
77 /** The 'P' flag is set. */
78 VSS_STATUS_FLAG_PLAYING = 2,
79 };
80
81 /**
82 * The task for obtaining para_server's status (para_client stat).
83 *
84 * \sa struct task, struct sched.
85 */
86 struct status_task {
87 /** The associated task structure of audiod. */
88 struct task task;
89 /** Client data associated with the stat task. */
90 struct client_task *ct;
91 /** Do not restart client command until this time. */
92 struct timeval restart_barrier;
93 /** Last time we received status data from para_server. */
94 struct timeval last_status_read;
95 size_t min_iqs;
96 /** The offset value announced by para_server. */
97 int offset_seconds;
98 /** The length of the current audio file as announced by para_server. */
99 int length_seconds;
100 /** The start of the current stream from the view of para_server. */
101 struct timeval server_stream_start;
102 /** The average time deviation between para_server and para_audiod. */
103 struct timeval sa_time_diff;
104 /** Whether client time is ahead of server time. */
105 int sa_time_diff_sign;
106 /** The 'P' and the 'N' flags as announced by para_server. */
107 enum vss_status_flags vss_status;
108 /** Number of times the clock difference is to be checked. */
109 unsigned clock_diff_count;
110 /** When to start the next check for clock difference. */
111 struct timeval clock_diff_barrier;
112 /** Number of the audio format as announced by para_server. */
113 int current_audio_format_num;
114 /* The status task btrn is the child of the client task. */
115 struct btr_node *btrn;
116 };
117
118 /** The array of status items sent by para_server. */
119 char *stat_item_values[NUM_STAT_ITEMS] = {NULL};
120
121 /**
122 * the current mode of operation of which can be changed by the on/off/cycle
123 * commands. It is either, AUDIOD_OFF, AUDIOD_ON or AUDIOD_STANDBY.
124 */
125 int audiod_status = AUDIOD_ON;
126
127 /**
128 * the gengetopt args_info struct that holds information on all command line
129 * arguments
130 */
131 struct audiod_args_info conf;
132
133 static char *socket_name;
134 static struct audio_format_info afi[NUM_AUDIO_FORMATS];
135
136 static struct signal_task signal_task_struct, *sig_task = &signal_task_struct;
137
138 static struct status_task status_task_struct;
139
140 /**
141 * the task that calls the status command of para_server
142 *
143 * \sa struct status_task
144 */
145 static struct status_task *stat_task = &status_task_struct;
146
147 /**
148 * the task for handling audiod commands
149 *
150 * \sa struct task, struct sched
151 */
152 struct command_task {
153 /** the local listening socket */
154 int fd;
155 /** the associated task structure */
156 struct task task;
157 };
158
159 /** iterate over all supported audio formats */
160 #define FOR_EACH_AUDIO_FORMAT(af) for (af = 0; af < NUM_AUDIO_FORMATS; af++)
161
162 /**
163 * Get the audio format number.
164 *
165 * \param name The name of the audio format.
166 *
167 * \return The audio format number on success, -E_UNSUPPORTED_AUDIO_FORMAT if
168 * \a name is not a supported audio format.
169 */
170 int get_audio_format_num(const char *name)
171 {
172 int i;
173
174 while (para_isspace(*name))
175 name++;
176 FOR_EACH_AUDIO_FORMAT(i)
177 if (!strcmp(name, audio_formats[i]))
178 return i;
179 return -E_UNSUPPORTED_AUDIO_FORMAT;
180 }
181
182 /**
183 * Compute the play time based on information of the given slot.
184 *
185 * \param slot_num The slot number (negative means: no slot).
186 *
187 * This computes a string of the form "0:07 [3:33] (3%/3:40)" using information
188 * from the status items received from para_server and the start time of the
189 * (first) writer of the given slot.
190 *
191 * It has to to take into account that probably the stream was not started at
192 * the beginning of the file, that the clock between the server and the client
193 * host may differ and that playback of the stream was delayed, e.g. because
194 * the prebuffer filter is used in the filter configuration of the given slot.
195 *
196 * If no writer is active in the given slot, or \a slot_num is negative
197 * (indicating that para_audiod runs in standby mode), an approximation based
198 * only on the status items is computed and the returned string is prefixed
199 * with "~".
200 *
201 * \return A string that must be freed by the caller.
202 */
203 char *get_time_string(int slot_num)
204 {
205 int ret, seconds = 0, length;
206 struct timeval *tmp, sum, sss, /* server stream start */
207 rstime, /* receiver start time */
208 wstime, /* writer start time */
209 wtime, /* now - writer start */
210 rskip; /* receiver start - sss */
211 struct slot_info *s = slot_num < 0? NULL : &slot[slot_num];
212 char *msg;
213
214 if (audiod_status == AUDIOD_OFF)
215 goto empty;
216 if (!(stat_task->vss_status & VSS_STATUS_FLAG_PLAYING)) {
217 if (stat_task->length_seconds) /* paused */
218 return NULL;
219 goto empty; /* stopped */
220 }
221 if (audiod_status == AUDIOD_ON && !s)
222 goto empty;
223 /*
224 * Valid status items and playing, set length and tmp to the stream
225 * start. We use the slot info and fall back to the info from current
226 * status items if no slot info is available.
227 */
228 length = stat_task->length_seconds;
229 tmp = &stat_task->server_stream_start;
230 if (s && s->wns) { /* writer active in this slot */
231 btr_get_node_start(s->wns[0].btrn, &wstime);
232 if (wstime.tv_sec != 0) { /* writer wrote something */
233 if (s->server_stream_start.tv_sec == 0) {
234 /* copy status info to slot */
235 s->server_stream_start = stat_task->server_stream_start;
236 s->offset_seconds = stat_task->offset_seconds;
237 s->seconds_total = stat_task->length_seconds;
238 }
239 length = s->seconds_total;
240 tmp = &s->server_stream_start;
241 }
242 }
243 if (stat_task->sa_time_diff_sign > 0)
244 tv_diff(tmp, &stat_task->sa_time_diff, &sss);
245 else
246 tv_add(tmp, &stat_task->sa_time_diff, &sss);
247 if (!s || !s->wns) {
248 struct timeval diff;
249 tv_diff(now, &sss, &diff);
250 seconds = diff.tv_sec + stat_task->offset_seconds;
251 goto out;
252 }
253 tv_diff(now, &wstime, &wtime);
254 //PARA_CRIT_LOG("offset %d\n", s->offset_seconds);
255 seconds = s->offset_seconds;
256 btr_get_node_start(s->receiver_node->btrn, &rstime);
257 ret = tv_diff(&rstime, &sss, &rskip);
258 if (ret > 0) { /* audiod was started in the middle of the stream */
259 tv_add(&wtime, &rskip, &sum);
260 seconds += sum.tv_sec;
261 } else
262 seconds += wtime.tv_sec;
263 out:
264 seconds = PARA_MIN(seconds, length);
265 seconds = PARA_MAX(seconds, 0);
266 msg = make_message(
267 "%s%d:%02d [%d:%02d] (%d%%/%d:%02d)",
268 s? "" : "~",
269 seconds / 60,
270 seconds % 60,
271 (length - seconds) / 60,
272 (length - seconds) % 60,
273 length? (seconds * 100 + length / 2) / length : 0,
274 length / 60,
275 length % 60
276 );
277 PARA_DEBUG_LOG("slot %d: %s\n", slot_num, msg);
278 return msg;
279 empty:
280 return para_strdup(NULL);
281 }
282
283 static int want_colors(void)
284 {
285 if (conf.color_arg == color_arg_no)
286 return 0;
287 if (conf.color_arg == color_arg_yes)
288 return 1;
289 if (conf.logfile_given)
290 return 0;
291 return isatty(STDERR_FILENO);
292 }
293
294 static void parse_config_or_die(void)
295 {
296 int ret;
297 char *config_file;
298 struct audiod_cmdline_parser_params params = {
299 .override = 0,
300 .initialize = 0,
301 .check_required = 1,
302 .check_ambiguity = 0,
303 .print_errors = 1
304 };
305
306 if (conf.config_file_given)
307 config_file = para_strdup(conf.config_file_arg);
308 else {
309 char *home = para_homedir();
310 config_file = make_message("%s/.paraslash/audiod.conf", home);
311 free(home);
312 }
313 ret = file_exists(config_file);
314 if (conf.config_file_given && !ret) {
315 PARA_EMERG_LOG("can not read config file %s\n", config_file);
316 goto err;
317 }
318 if (ret)
319 audiod_cmdline_parser_config_file(config_file, &conf, ¶ms);
320 free(config_file);
321 daemon_set_loglevel(conf.loglevel_arg);
322 return;
323 err:
324 free(config_file);
325 exit(EXIT_FAILURE);
326 }
327
328 static void setup_signal_handling(void)
329 {
330 sig_task->fd = para_signal_init();
331 PARA_INFO_LOG("signal pipe: fd %d\n", sig_task->fd);
332 para_install_sighandler(SIGINT);
333 para_install_sighandler(SIGTERM);
334 para_install_sighandler(SIGHUP);
335 para_sigaction(SIGPIPE, SIG_IGN);
336 }
337
338 static void clear_slot(int slot_num)
339 {
340 struct slot_info *s = &slot[slot_num];
341
342 PARA_INFO_LOG("clearing slot %d\n", slot_num);
343 memset(s, 0, sizeof(struct slot_info));
344 s->format = -1;
345 }
346
347 static void close_receiver(int slot_num)
348 {
349 struct slot_info *s = &slot[slot_num];
350 struct audio_format_info *a;
351
352 if (s->format < 0 || !s->receiver_node)
353 return;
354 a = &afi[s->format];
355 PARA_NOTICE_LOG("closing %s receiver in slot %d\n",
356 audio_formats[s->format], slot_num);
357 a->receiver->close(s->receiver_node);
358 btr_free_node(s->receiver_node->btrn);
359 free(s->receiver_node);
360 s->receiver_node = NULL;
361 tv_add(now, &(struct timeval)EMBRACE(0, 200 * 1000),
362 &a->restart_barrier);
363 }
364
365 static void writer_cleanup(struct writer_node *wn)
366 {
367 struct writer *w;
368
369 if (!wn)
370 return;
371 w = writers + wn->writer_num;
372 PARA_INFO_LOG("closing %s\n", writer_names[wn->writer_num]);
373 w->close(wn);
374 btr_free_node(wn->btrn);
375 }
376
377 static void close_writers(struct slot_info *s)
378 {
379 struct audio_format_info *a;
380 int i;
381
382 if (s->format < 0)
383 return;
384 assert(s->wns);
385 a = afi + s->format;
386 if (a->num_writers == 0)
387 writer_cleanup(s->wns);
388 else {
389 for (i = 0; i < a->num_writers; i++)
390 writer_cleanup(s->wns + i);
391 }
392 free(s->wns);
393 s->wns = NULL;
394 }
395
396 static void close_filters(struct slot_info *s)
397 {
398 int i;
399 struct audio_format_info *a = afi + s->format;
400 if (a->num_filters == 0)
401 return;
402 for (i = 0; i < a->num_filters; i++) {
403 struct filter_node *fn = s->fns + i;
404 struct filter *f;
405
406 if (!fn)
407 continue;
408 f = filters + fn->filter_num;
409 if (f->close)
410 f->close(fn);
411 btr_free_node(fn->btrn);
412 }
413 free(s->fns);
414 s->fns = NULL;
415 }
416
417 /*
418 * Whenever a task commits suicide by returning from post_select with t->error
419 * < 0, it also removes its btr node. We do exactly that to kill a running
420 * task. Note that the scheduler checks t->error also _before_ each pre/post
421 * select call, so the victim will never be scheduled again.
422 */
423 static void kill_btrn(struct btr_node *btrn, struct task *t, int error)
424 {
425 if (t->error < 0)
426 return;
427 t->error = error;
428 btr_remove_node(btrn);
429 }
430
431 static void kill_all_decoders(int error)
432 {
433 int i, j;
434
435 FOR_EACH_SLOT(i) {
436 struct slot_info *s = &slot[i];
437 struct audio_format_info *a;
438 if (s->format < 0)
439 continue;
440 a = afi + s->format;
441 if (s->wns)
442 for (j = 0; j < a->num_writers; j++)
443 kill_btrn(s->wns[j].btrn, &s->wns[j].task, error);
444 if (s->fns)
445 for (j = 0; j < a->num_writers; j++)
446 kill_btrn(s->fns[j].btrn, &s->wns[j].task, error);
447 if (s->receiver_node)
448 kill_btrn(s->receiver_node->btrn, &s->receiver_node->task,
449 error);
450 }
451 }
452
453 static int get_empty_slot(void)
454 {
455 int i;
456 struct slot_info *s;
457
458 FOR_EACH_SLOT(i) {
459 s = &slot[i];
460 if (s->format < 0) {
461 clear_slot(i);
462 return i;
463 }
464 if (s->wns || s->receiver_node || s->fns)
465 continue;
466 clear_slot(i);
467 return i;
468 }
469 return -E_NO_MORE_SLOTS;
470 }
471
472 /**
473 * get the number of filters
474 *
475 * \param audio_format_num the number identifying the audio format
476 *
477 * \return the number of filters for the given audio format
478 *
479 * \sa struct filter;
480 */
481 int num_filters(int audio_format_num)
482 {
483 return afi[audio_format_num].num_filters;
484 }
485
486 static void open_filters(struct slot_info *s)
487 {
488 struct audio_format_info *a = afi + s->format;
489 struct filter_node *fn;
490 int nf = a->num_filters;
491 struct btr_node *parent;
492 int i;
493
494 if (nf == 0)
495 return;
496 PARA_INFO_LOG("opening %s filters\n", audio_formats[s->format]);
497 assert(s->fns == NULL);
498 s->fns = para_calloc(nf * sizeof(struct filter_node));
499 parent = s->receiver_node->btrn;
500 for (i = 0; i < nf; i++) {
501 struct filter *f = filters + a->filter_nums[i];
502 fn = s->fns + i;
503 fn->filter_num = a->filter_nums[i];
504 fn->conf = a->filter_conf[i];
505 fn->task.pre_select = f->pre_select;
506 fn->task.post_select = f->post_select;
507
508 fn->btrn = btr_new_node(&(struct btr_node_description)
509 EMBRACE(.name = f->name, .parent = parent,
510 .handler = f->execute, .context = fn));
511
512 f->open(fn);
513 register_task(&fn->task);
514 parent = fn->btrn;
515 PARA_NOTICE_LOG("%s filter %d/%d (%s) started in slot %d\n",
516 audio_formats[s->format], i, nf, f->name, (int)(s - slot));
517 sprintf(fn->task.status, "%s (slot %d)", f->name, (int)(s - slot));
518 }
519 }
520
521 static void open_writers(struct slot_info *s)
522 {
523 int i;
524 struct audio_format_info *a = afi + s->format;
525 struct writer_node *wn;
526 struct btr_node *parent = s->fns[a->num_filters - 1].btrn;
527
528 assert(s->wns == NULL);
529 s->wns = para_calloc(PARA_MAX(1U, a->num_writers)
530 * sizeof(struct writer_node));
531 if (a->num_writers == 0)
532 setup_writer_node(NULL, parent, s->wns);
533 else {
534 PARA_INFO_LOG("opening %s writers\n", audio_formats[s->format]);
535 for (i = 0; i < a->num_writers; i++) {
536 wn = s->wns + i;
537 wn->conf = a->writer_conf[i];
538 wn->writer_num = a->writer_nums[i];
539 register_writer_node(wn, parent);
540 }
541 }
542 }
543
544 /* returns slot num on success */
545 static int open_receiver(int format)
546 {
547 struct audio_format_info *a = &afi[format];
548 struct slot_info *s;
549 int ret, slot_num;
550 struct receiver *r = a->receiver;
551 struct receiver_node *rn;
552
553 tv_add(now, &(struct timeval)EMBRACE(2, 0), &a->restart_barrier);
554 ret = get_empty_slot();
555 if (ret < 0)
556 return ret;
557 slot_num = ret;
558 rn = para_calloc(sizeof(*rn));
559 rn->receiver = r;
560 rn->conf = a->receiver_conf;
561 rn->btrn = btr_new_node(&(struct btr_node_description)
562 EMBRACE(.name = r->name, .context = rn));
563 ret = r->open(rn);
564 if (ret < 0) {
565 btr_free_node(rn->btrn);
566 free(rn);
567 return ret;
568 }
569 s = &slot[slot_num];
570 s->format = format;
571 s->receiver_node = rn;
572 PARA_NOTICE_LOG("started %s: %s receiver in slot %d\n",
573 audio_formats[format], r->name, slot_num);
574 rn->task.pre_select = r->pre_select;
575 rn->task.post_select = r->post_select;
576 sprintf(rn->task.status, "%s receiver node", r->name);
577 register_task(&rn->task);
578 return slot_num;
579 }
580
581 static bool receiver_running(void)
582 {
583 int i;
584 long unsigned ss1 = stat_task->server_stream_start.tv_sec;
585
586 FOR_EACH_SLOT(i) {
587 struct slot_info *s = &slot[i];
588 long unsigned ss2 = s->server_stream_start.tv_sec;
589
590 if (!s->receiver_node)
591 continue;
592 if (s->receiver_node->task.error >= 0)
593 return true;
594 if (ss1 == ss2)
595 return true;
596 }
597 return false;
598 }
599
600 /**
601 * Return the root node of the current buffer tree.
602 *
603 * This is only used for stream grabbing.
604 *
605 * \return \p NULL if no slot is currently active. If more than one buffer tree
606 * exists, the node corresponding to the most recently started receiver is
607 * returned.
608 */
609 struct btr_node *audiod_get_btr_root(void)
610 {
611 int i, newest_slot = -1;
612 struct timeval newest_rstime = {0, 0};
613
614 FOR_EACH_SLOT(i) {
615 struct slot_info *s = &slot[i];
616 struct timeval rstime;
617 if (!s->receiver_node)
618 continue;
619 if (s->receiver_node->task.error < 0)
620 continue;
621 btr_get_node_start(s->receiver_node->btrn, &rstime);
622 if (newest_slot >= 0 && tv_diff(&rstime, &newest_rstime, NULL) < 0)
623 continue;
624 newest_rstime = rstime;
625 newest_slot = i;
626 }
627 if (newest_slot == -1)
628 return NULL;
629 return slot[newest_slot].receiver_node->btrn;
630 }
631
632 /* whether a new instance of a decoder should be started. */
633 static bool must_start_decoder(void)
634 {
635 int cafn = stat_task->current_audio_format_num;
636 unsigned vs = stat_task->vss_status;
637
638 if (audiod_status != AUDIOD_ON)
639 return false;
640 if (cafn < 0)
641 return false;
642 if (!stat_task->ct)
643 return false;
644 if (vs & VSS_STATUS_FLAG_NEXT)
645 return false;
646 if (!(vs & VSS_STATUS_FLAG_PLAYING))
647 return false;
648 if (receiver_running())
649 return false;
650 if (tv_diff(now, &afi[cafn].restart_barrier, NULL) < 0)
651 return false;
652 return true;
653 }
654
655 static unsigned compute_time_diff(const struct timeval *status_time)
656 {
657 struct timeval tmp, diff;
658 static unsigned count;
659 int sign, sa_time_diff_sign = stat_task->sa_time_diff_sign;
660 const struct timeval max_deviation = {0, 500 * 1000};
661 const int time_smooth = 5;
662
663 if (!status_time)
664 return count;
665 sign = tv_diff(status_time, now, &diff);
666 // PARA_NOTICE_LOG("%s: sign = %i, sa_time_diff_sign = %i\n", __func__,
667 // sign, sa_time_diff_sign);
668 if (!count) {
669 sa_time_diff_sign = sign;
670 stat_task->sa_time_diff = diff;
671 count++;
672 goto out;
673 }
674 if (count > 5) {
675 int s = tv_diff(&diff, &stat_task->sa_time_diff, &tmp);
676 if (tv_diff(&max_deviation, &tmp, NULL) < 0)
677 PARA_WARNING_LOG("time diff jump: %lims\n",
678 s * tv2ms(&tmp));
679 }
680 count++;
681 sa_time_diff_sign = tv_convex_combination(
682 sa_time_diff_sign * time_smooth, &stat_task->sa_time_diff,
683 count > 10? sign : sign * time_smooth, &diff,
684 &tmp);
685 stat_task->sa_time_diff = tmp;
686 PARA_INFO_LOG("time diff (cur/avg): %s%lums/%s%lums\n",
687 sign < 0? "-" : "+",
688 tv2ms(&diff),
689 sa_time_diff_sign < 0? "-" : "+",
690 tv2ms(&stat_task->sa_time_diff)
691 );
692 out:
693 stat_task->sa_time_diff_sign = sa_time_diff_sign;
694 return count;
695 }
696
697 static int update_item(int itemnum, char *buf)
698 {
699 long unsigned sec, usec;
700
701 if (stat_task->clock_diff_count && itemnum != SI_CURRENT_TIME)
702 return 1;
703 free(stat_item_values[itemnum]);
704 stat_item_values[itemnum] = para_strdup(buf);
705 stat_client_write_item(itemnum);
706 switch (itemnum) {
707 case SI_STATUS_FLAGS:
708 stat_task->vss_status = 0;
709 if (strchr(buf, 'N'))
710 stat_task->vss_status |= VSS_STATUS_FLAG_NEXT;
711 if (strchr(buf, 'P'))
712 stat_task->vss_status |= VSS_STATUS_FLAG_PLAYING;
713 break;
714 case SI_OFFSET:
715 stat_task->offset_seconds = atoi(buf);
716 break;
717 case SI_SECONDS_TOTAL:
718 stat_task->length_seconds = atoi(buf);
719 break;
720 case SI_STREAM_START:
721 if (sscanf(buf, "%lu.%lu", &sec, &usec) == 2) {
722 stat_task->server_stream_start.tv_sec = sec;
723 stat_task->server_stream_start.tv_usec = usec;
724 }
725 break;
726 case SI_CURRENT_TIME:
727 if (sscanf(buf, "%lu.%lu", &sec, &usec) == 2) {
728 struct timeval tv = {sec, usec};
729 compute_time_diff(&tv);
730 }
731 break;
732 case SI_FORMAT:
733 stat_task->current_audio_format_num
734 = get_audio_format_num(buf);
735 }
736 return 1;
737 }
738
739 static int parse_stream_command(const char *txt, char **cmd)
740 {
741 char *p = strchr(txt, ':');
742 int i;
743
744 if (!p)
745 return -E_MISSING_COLON;
746 p++;
747 FOR_EACH_AUDIO_FORMAT(i) {
748 if (strncmp(txt, audio_formats[i], strlen(audio_formats[i])))
749 continue;
750 *cmd = p;
751 return i;
752 }
753 return -E_UNSUPPORTED_AUDIO_FORMAT;
754 }
755
756 static int add_filter(int format, char *cmdline)
757 {
758 struct audio_format_info *a = &afi[format];
759 int filter_num, nf = a->num_filters;
760
761 filter_num = check_filter_arg(cmdline, &a->filter_conf[nf]);
762 if (filter_num < 0)
763 return filter_num;
764 a->filter_nums[nf] = filter_num;
765 a->num_filters++;
766 PARA_INFO_LOG("%s filter %d: %s\n", audio_formats[format], nf,
767 filters[filter_num].name);
768 return filter_num;
769 }
770
771 static int parse_writer_args(void)
772 {
773 int i, ret, nw;
774 char *cmd;
775 struct audio_format_info *a;
776
777 nw = PARA_MAX(1U, conf.writer_given);
778 PARA_INFO_LOG("maximal number of writers: %d\n", nw);
779 FOR_EACH_AUDIO_FORMAT(i) {
780 a = &afi[i];
781 a->writer_conf = para_malloc(nw * sizeof(void *));
782 a->writer_nums = para_malloc(nw * sizeof(int));
783 a->num_writers = 0;
784 }
785 for (i = 0; i < conf.writer_given; i++) {
786 void *wconf;
787 int writer_num;
788 ret = parse_stream_command(conf.writer_arg[i], &cmd);
789 if (ret < 0)
790 goto out;
791 a = &afi[ret];
792 nw = a->num_writers;
793 wconf = check_writer_arg(cmd, &writer_num);
794 if (!wconf) {
795 ret = writer_num;
796 goto out;
797 }
798 a->writer_nums[nw] = writer_num;
799 a->writer_conf[nw] = wconf;
800 PARA_INFO_LOG("%s writer #%d: %s\n", audio_formats[ret],
801 nw, writer_names[writer_num]);
802 a->num_writers++;
803 }
804 ret = 1;
805 out:
806 return ret;
807 }
808
809 static int parse_receiver_args(void)
810 {
811 int i, ret, receiver_num;
812 char *cmd = NULL;
813 struct audio_format_info *a;
814
815 for (i = conf.receiver_given - 1; i >= 0; i--) {
816 char *arg = conf.receiver_arg[i];
817 char *recv_arg = strchr(arg, ':');
818 ret = -E_MISSING_COLON;
819 if (!recv_arg)
820 goto out;
821 *recv_arg = '\0';
822 recv_arg++;
823 ret = get_audio_format_num(arg);
824 if (ret < 0)
825 goto out;
826 afi[ret].receiver_conf = check_receiver_arg(recv_arg, &receiver_num);
827 if (!afi[ret].receiver_conf) {
828 ret = -E_RECV_SYNTAX;
829 goto out;
830 }
831 afi[ret].receiver = &receivers[receiver_num];
832 }
833 /* use the first available receiver with no arguments
834 * for those audio formats for which no receiver
835 * was specified
836 */
837 cmd = para_strdup(receivers[0].name);
838 FOR_EACH_AUDIO_FORMAT(i) {
839 a = &afi[i];
840 if (a->receiver_conf)
841 continue;
842 a->receiver_conf = check_receiver_arg(cmd, &receiver_num);
843 if (!a->receiver_conf)
844 return -E_RECV_SYNTAX;
845 a->receiver = &receivers[receiver_num];
846 }
847 ret = 1;
848 out:
849 free(cmd);
850 return ret;
851 }
852
853 static int init_default_filters(void)
854 {
855 int i, ret = 1;
856
857 FOR_EACH_AUDIO_FORMAT(i) {
858 struct audio_format_info *a = &afi[i];
859 char *tmp;
860 int j;
861
862 if (a->num_filters)
863 continue; /* no default -- nothing to to */
864 /*
865 * If udp is used to receive this audiod format, add fecdec as
866 * the first filter.
867 */
868 if (strcmp(afi[i].receiver->name, "udp") == 0 ||
869 strcmp(afi[i].receiver->name, "dccp") == 0) {
870 tmp = para_strdup("fecdec");
871 add_filter(i, tmp);
872 free(tmp);
873 if (ret < 0)
874 goto out;
875 }
876 /* add "dec" to audio format name */
877 tmp = make_message("%sdec", audio_formats[i]);
878 for (j = 0; filters[j].name; j++)
879 if (!strcmp(tmp, filters[j].name))
880 break;
881 free(tmp);
882 ret = -E_UNSUPPORTED_FILTER;
883 if (!filters[j].name)
884 goto out;
885 tmp = para_strdup(filters[j].name);
886 ret = add_filter(i, tmp);
887 free(tmp);
888 if (ret < 0)
889 goto out;
890 PARA_INFO_LOG("%s -> default filter: %s\n", audio_formats[i],
891 filters[j].name);
892 }
893 out:
894 return ret;
895 }
896
897 static int parse_filter_args(void)
898 {
899 int i, ret, nf;
900
901 nf = PARA_MAX(2U, conf.filter_given);
902 PARA_INFO_LOG("maximal number of filters: %d\n", nf);
903 FOR_EACH_AUDIO_FORMAT(i) {
904 afi[i].filter_conf = para_malloc(nf * sizeof(void *));
905 afi[i].filter_nums = para_malloc(nf * sizeof(unsigned));
906 }
907 if (!conf.no_default_filters_given)
908 return init_default_filters();
909 for (i = 0; i < conf.filter_given; i++) {
910 char *arg = conf.filter_arg[i];
911 char *filter_name = strchr(arg, ':');
912 ret = -E_MISSING_COLON;
913 if (!filter_name)
914 goto out;
915 *filter_name = '\0';
916 filter_name++;
917 ret = get_audio_format_num(arg);
918 if (ret < 0)
919 goto out;
920 ret = add_filter(ret, filter_name);
921 if (ret < 0)
922 goto out;
923 }
924 ret = init_default_filters(); /* use default values for the rest */
925 out:
926 return ret;
927 }
928
929 static int parse_stream_args(void)
930 {
931 int ret;
932
933 ret = parse_receiver_args();
934 if (ret < 0)
935 return ret;
936 ret = parse_filter_args();
937 if (ret < 0)
938 return ret;
939 ret = parse_writer_args();
940 if (ret < 0)
941 return ret;
942 return 1;
943 }
944
945 /* does not unlink socket on errors */
946 static int audiod_get_socket(void)
947 {
948 struct sockaddr_un unix_addr;
949 int ret, fd;
950
951 if (conf.socket_given)
952 socket_name = para_strdup(conf.socket_arg);
953 else {
954 char *hn = para_hostname();
955 socket_name = make_message("/var/paraslash/audiod_socket.%s",
956 hn);
957 free(hn);
958 }
959 PARA_NOTICE_LOG("local socket: %s\n", socket_name);
960 if (conf.force_given)
961 unlink(socket_name);
962 ret = create_local_socket(socket_name, &unix_addr,
963 S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IWOTH);
964 if (ret < 0)
965 goto err;
966 fd = ret;
967 if (listen(fd , 5) < 0) {
968 ret = -ERRNO_TO_PARA_ERROR(errno);
969 goto err;
970 }
971 ret = mark_fd_nonblocking(fd);
972 if (ret < 0)
973 goto err;
974 return fd;
975 err:
976 PARA_EMERG_LOG("%s\n", para_strerror(-ret));
977 exit(EXIT_FAILURE);
978 }
979
980 static void signal_pre_select(struct sched *s, struct task *t)
981 {
982 struct signal_task *st = container_of(t, struct signal_task, task);
983 para_fd_set(st->fd, &s->rfds, &s->max_fileno);
984 }
985
986 static void signal_post_select(struct sched *s, __a_unused struct task *t)
987 {
988 int signum;
989
990 signum = para_next_signal(&s->rfds);
991 switch (signum) {
992 case SIGINT:
993 case SIGTERM:
994 case SIGHUP:
995 PARA_EMERG_LOG("terminating on signal %d\n", signum);
996 clean_exit(EXIT_FAILURE, "caught deadly signal");
997 }
998 }
999
1000 static void signal_setup_default(struct signal_task *st)
1001 {
1002 st->task.pre_select = signal_pre_select;
1003 st->task.post_select = signal_post_select;
1004 sprintf(st->task.status, "signal task");
1005 }
1006
1007 static void command_pre_select(struct sched *s, struct task *t)
1008 {
1009 struct command_task *ct = container_of(t, struct command_task, task);
1010 para_fd_set(ct->fd, &s->rfds, &s->max_fileno);
1011 }
1012
1013 static void command_post_select(struct sched *s, struct task *t)
1014 {
1015 int ret;
1016 struct command_task *ct = container_of(t, struct command_task, task);
1017 static struct timeval last_status_dump;
1018 struct timeval tmp, delay = {0, 500 * 1000};
1019
1020 tv_add(&last_status_dump, &delay, &tmp);
1021 if (tv_diff(&tmp, now, NULL) < 0) {
1022 audiod_status_dump();
1023 last_status_dump = *now;
1024 }
1025
1026 ret = handle_connect(ct->fd, &s->rfds);
1027 if (ret < 0)
1028 PARA_ERROR_LOG("%s\n", para_strerror(-ret));
1029 audiod_status_dump();
1030 }
1031
1032 static void init_command_task(struct command_task *ct)
1033 {
1034 ct->task.pre_select = command_pre_select;
1035 ct->task.post_select = command_post_select;
1036 ct->task.error = 0;
1037 ct->fd = audiod_get_socket(); /* doesn't return on errors */
1038 sprintf(ct->task.status, "command task");
1039 }
1040
1041 static void close_stat_pipe(void)
1042 {
1043 if (!stat_task->ct)
1044 return;
1045 btr_free_node(stat_task->ct->btrn);
1046 client_close(stat_task->ct);
1047 stat_task->ct = NULL;
1048 clear_and_dump_items();
1049 stat_task->length_seconds = 0;
1050 stat_task->offset_seconds = 0;
1051 stat_task->vss_status = 0;
1052 stat_task->current_audio_format_num = -1;
1053 audiod_status_dump();
1054 }
1055
1056 /**
1057 * close the connection to para_server and exit
1058 *
1059 * \param status the exit status which is passed to exit(3)
1060 * \param msg the log message
1061 *
1062 * Log \a msg with loglevel \p EMERG, close the connection to para_server if
1063 * open, and call \p exit(status). \a status should be either EXIT_SUCCESS or
1064 * EXIT_FAILURE.
1065 *
1066 * \sa exit(3)
1067 */
1068 void __noreturn clean_exit(int status, const char *msg)
1069 {
1070 PARA_EMERG_LOG("%s\n", msg);
1071 if (socket_name)
1072 unlink(socket_name);
1073 close_stat_pipe();
1074 exit(status);
1075 }
1076
1077 /* avoid busy loop if server is down */
1078 static void set_stat_task_restart_barrier(unsigned seconds)
1079 {
1080 struct timeval delay = {seconds, 0};
1081 tv_add(now, &delay, &stat_task->restart_barrier);
1082 }
1083
1084 static void try_to_close_slot(int slot_num)
1085 {
1086 struct slot_info *s = &slot[slot_num];
1087 struct audio_format_info *a = afi + s->format;
1088 int i;
1089
1090 if (s->format < 0)
1091 return;
1092 if (s->receiver_node && s->receiver_node->task.error != -E_TASK_UNREGISTERED)
1093 return;
1094 for (i = 0; i < a->num_filters; i++)
1095 if (s->fns && s->fns[i].task.error != -E_TASK_UNREGISTERED)
1096 return;
1097 if (a->num_writers > 0) {
1098 for (i = 0; i < a->num_writers; i++)
1099 if (s->wns && s->wns[i].task.error != -E_TASK_UNREGISTERED)
1100 return;
1101 } else {
1102 if (s->wns && s->wns[0].task.error != -E_TASK_UNREGISTERED)
1103 return;
1104 }
1105 PARA_INFO_LOG("closing slot %d\n", slot_num);
1106 close_writers(s);
1107 close_filters(s);
1108 close_receiver(slot_num);
1109 clear_slot(slot_num);
1110 }
1111
1112 /*
1113 * Check if any receivers/filters/writers need to be started and do so if
1114 * necessary.
1115 */
1116 static void start_stop_decoders(void)
1117 {
1118 int i, ret;
1119 struct slot_info *sl;
1120 struct audio_format_info *a;
1121
1122 FOR_EACH_SLOT(i)
1123 try_to_close_slot(i);
1124 if (audiod_status != AUDIOD_ON ||
1125 !(stat_task->vss_status & VSS_STATUS_FLAG_PLAYING))
1126 return kill_all_decoders(-E_NOT_PLAYING);
1127 if (!must_start_decoder())
1128 return;
1129 ret = open_receiver(stat_task->current_audio_format_num);
1130 if (ret < 0) {
1131 PARA_ERROR_LOG("%s\n", para_strerror(-ret));
1132 return;
1133 }
1134 sl = slot + ret;
1135 a = afi + sl->format;
1136 if (a->num_filters)
1137 open_filters(sl);
1138 open_writers(sl);
1139 activate_grab_clients();
1140 btr_log_tree(sl->receiver_node->btrn, LL_NOTICE);
1141 }
1142
1143 static void status_pre_select(struct sched *s, struct task *t)
1144 {
1145 struct status_task *st = container_of(t, struct status_task, task);
1146 int ret, cafn = stat_task->current_audio_format_num;
1147
1148 if (must_start_decoder())
1149 goto min_delay;
1150 ret = btr_node_status(st->btrn, 0, BTR_NT_LEAF);
1151 if (ret > 0)
1152 goto min_delay;
1153 if (st->ct && audiod_status == AUDIOD_OFF)
1154 goto min_delay;
1155 if (!st->ct && audiod_status != AUDIOD_OFF)
1156 sched_request_barrier_or_min_delay(&st->restart_barrier, s);
1157 if (cafn >= 0)
1158 sched_request_barrier(&afi[cafn].restart_barrier, s);
1159 /*
1160 * If para_server is playing we'd like to have a smooth time display
1161 * even if we are running in standby mode. So we request a timeout that
1162 * expires at the next full second.
1163 */
1164 if (stat_task->vss_status & VSS_STATUS_FLAG_PLAYING)
1165 sched_request_timeout_ms(1000 - now->tv_usec / 1000, s);
1166 return;
1167 min_delay:
1168 sched_min_delay(s);
1169 }
1170
1171 /* restart the client task if necessary */
1172 static void status_post_select(__a_unused struct sched *s, struct task *t)
1173 {
1174 struct status_task *st = container_of(t, struct status_task, task);
1175
1176 if (audiod_status == AUDIOD_OFF) {
1177 if (!st->ct)
1178 goto out;
1179 if (st->ct->task.error >= 0) {
1180 kill_btrn(st->ct->btrn, &st->ct->task, -E_AUDIOD_OFF);
1181 goto out;
1182 }
1183 if (st->ct->task.error != -E_TASK_UNREGISTERED)
1184 goto out;
1185 close_stat_pipe();
1186 st->clock_diff_count = conf.clock_diff_count_arg;
1187 goto out;
1188 }
1189 if (st->ct) {
1190 char *buf;
1191 size_t sz;
1192 int ret;
1193 if (st->ct->task.error < 0) {
1194 if (st->ct->task.error != -E_TASK_UNREGISTERED)
1195 goto out;
1196 close_stat_pipe();
1197 goto out;
1198 }
1199 if (st->ct->status != CL_RECEIVING)
1200 goto out;
1201 ret = btr_node_status(st->btrn, st->min_iqs, BTR_NT_LEAF);
1202 if (ret <= 0) {
1203 struct timeval diff;
1204 tv_diff(now, &st->last_status_read, &diff);
1205 if (diff.tv_sec > 61)
1206 kill_btrn(st->ct->btrn, &st->ct->task,
1207 -E_STATUS_TIMEOUT);
1208 goto out;
1209 }
1210 btr_merge(st->btrn, st->min_iqs);
1211 sz = btr_next_buffer(st->btrn, &buf);
1212 ret = for_each_stat_item(buf, sz, update_item);
1213 if (ret < 0) {
1214 kill_btrn(st->ct->btrn, &st->ct->task, ret);
1215 goto out;
1216 }
1217 if (sz != ret) {
1218 btr_consume(st->btrn, sz - ret);
1219 st->last_status_read = *now;
1220 st->min_iqs = 0;
1221 } else /* current status item crosses buffers */
1222 st->min_iqs = sz + 1;
1223 goto out;
1224 }
1225 if (tv_diff(now, &st->restart_barrier, NULL) < 0)
1226 goto out;
1227 if (st->clock_diff_count) { /* get status only one time */
1228 char *argv[] = {"audiod", "--", "stat", "-p", "-n=1", NULL};
1229 int argc = 5;
1230 PARA_INFO_LOG("clock diff count: %d\n", st->clock_diff_count);
1231 st->clock_diff_count--;
1232 client_open(argc, argv, &st->ct, NULL, NULL, st->btrn);
1233 set_stat_task_restart_barrier(2);
1234
1235 } else {
1236 char *argv[] = {"audiod", "--", "stat", "-p", NULL};
1237 int argc = 4;
1238 client_open(argc, argv, &st->ct, NULL, NULL, st->btrn);
1239 set_stat_task_restart_barrier(5);
1240 }
1241 free(stat_item_values[SI_BASENAME]);
1242 stat_item_values[SI_BASENAME] = para_strdup(
1243 "no connection to para_server");
1244 stat_client_write_item(SI_BASENAME);
1245 st->last_status_read = *now;
1246 out:
1247 start_stop_decoders();
1248 }
1249
1250 static void init_status_task(struct status_task *st)
1251 {
1252 memset(st, 0, sizeof(struct status_task));
1253 st->task.pre_select = status_pre_select;
1254 st->task.post_select = status_post_select;
1255 st->sa_time_diff_sign = 1;
1256 st->clock_diff_count = conf.clock_diff_count_arg;
1257 st->current_audio_format_num = -1;
1258 sprintf(st->task.status, "stat");
1259 st->btrn = btr_new_node(&(struct btr_node_description)
1260 EMBRACE(.name = "stat"));
1261 }
1262
1263 static void set_initial_status(void)
1264 {
1265 audiod_status = AUDIOD_ON;
1266 if (!conf.mode_given)
1267 return;
1268 if (!strcmp(conf.mode_arg, "sb")) {
1269 audiod_status = AUDIOD_STANDBY;
1270 return;
1271 }
1272 if (!strcmp(conf.mode_arg, "off")) {
1273 audiod_status = AUDIOD_OFF;
1274 return;
1275 }
1276 if (strcmp(conf.mode_arg, "on"))
1277 PARA_WARNING_LOG("invalid mode\n");
1278 }
1279
1280 __noreturn static void print_help_and_die(void)
1281 {
1282 int d = conf.detailed_help_given;
1283 const char **p = d? audiod_args_info_detailed_help
1284 : audiod_args_info_help;
1285
1286 printf_or_die("%s\n\n", AUDIOD_CMDLINE_PARSER_PACKAGE "-"
1287 AUDIOD_CMDLINE_PARSER_VERSION);
1288 printf_or_die("%s\n\n", audiod_args_info_usage);
1289 for (; *p; p++)
1290 printf_or_die("%s\n", *p);
1291 print_receiver_helps(d);
1292 print_filter_helps(d);
1293 print_writer_helps(d);
1294 exit(0);
1295 }
1296
1297 static void init_colors_or_die(void)
1298 {
1299 int ret, i;
1300
1301 if (!want_colors())
1302 return;
1303 daemon_set_default_log_colors();
1304 daemon_set_flag(DF_COLOR_LOG);
1305 for (i = 0; i < conf.log_color_given; i++) {
1306 ret = daemon_set_log_color(conf.log_color_arg[i]);
1307 if (ret < 0)
1308 exit(EXIT_FAILURE);
1309 }
1310 }
1311
1312 /**
1313 * the main function of para_audiod
1314 *
1315 * \param argc usual argument count
1316 * \param argv usual argument vector
1317 *
1318 * \return EXIT_SUCCESS or EXIT_FAILURE
1319 *
1320 * \sa para_audiod(1)
1321 * */
1322 int main(int argc, char *argv[])
1323 {
1324 int ret, i;
1325 static struct sched s;
1326 struct command_task command_task_struct, *cmd_task = &command_task_struct;
1327 struct audiod_cmdline_parser_params params = {
1328 .override = 0,
1329 .initialize = 1,
1330 .check_required = 0,
1331 .check_ambiguity = 0,
1332 .print_errors = 1
1333 };
1334
1335 valid_fd_012();
1336 if (audiod_cmdline_parser_ext(argc, argv, &conf, ¶ms))
1337 exit(EXIT_FAILURE);
1338 HANDLE_VERSION_FLAG("audiod", conf);
1339 /* init receivers/filters/writers early to make help work */
1340 recv_init();
1341 filter_init();
1342 writer_init();
1343 if (conf.help_given || conf.detailed_help_given)
1344 print_help_and_die();
1345 drop_privileges_or_die(conf.user_arg, conf.group_arg);
1346 parse_config_or_die();
1347 init_colors_or_die();
1348 init_random_seed_or_die();
1349 daemon_set_flag(DF_LOG_TIME);
1350 daemon_set_flag(DF_LOG_HOSTNAME);
1351 daemon_set_flag(DF_LOG_LL);
1352 if (conf.log_timing_given)
1353 daemon_set_flag(DF_LOG_TIMING);
1354 if (conf.logfile_given) {
1355 daemon_set_logfile(conf.logfile_arg);
1356 daemon_open_log_or_die();
1357 }
1358 ret = parse_stream_args();
1359 if (ret < 0) {
1360 PARA_EMERG_LOG("%s\n", para_strerror(-ret));
1361 exit(EXIT_FAILURE);
1362 }
1363 log_welcome("para_audiod");
1364 server_uptime(UPTIME_SET);
1365 set_initial_status();
1366 FOR_EACH_SLOT(i)
1367 clear_slot(i);
1368 setup_signal_handling();
1369 signal_setup_default(sig_task);
1370
1371 init_status_task(stat_task);
1372 init_command_task(cmd_task);
1373
1374 if (conf.daemon_given)
1375 daemonize();
1376
1377 register_task(&sig_task->task);
1378 register_task(&cmd_task->task);
1379 register_task(&stat_task->task);
1380 s.default_timeout.tv_sec = 2;
1381 s.default_timeout.tv_usec = 999 * 1000;
1382 ret = schedule(&s);
1383
1384 PARA_EMERG_LOG("%s\n", para_strerror(-ret));
1385 return EXIT_FAILURE;
1386 }
|
{
"url": "http://git.tuebingen.mpg.de/?p=paraslash.git;a=blob;f=audiod.c;h=668b0f744cf316d3c1b8ad916845831f3c88b2d0;hb=67900f49834e42887225eaf586a1d235ed11910a",
"source_domain": "git.tuebingen.mpg.de",
"snapshot_id": "crawl=CC-MAIN-2021-17",
"warc_metadata": {
"Content-Length": "445868",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:7MHKPR5ZDVM5VQ43UBVVGRBPEATVS7HQ",
"WARC-Concurrent-To": "<urn:uuid:132de2ba-b21b-4d16-904b-1a2cc4229226>",
"WARC-Date": "2021-04-23T15:56:52Z",
"WARC-IP-Address": "192.124.27.42",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:LHHGTV3NBBH22NLGGUIETUQ3B2RM2M7P",
"WARC-Record-ID": "<urn:uuid:8f0c3e24-9a12-42c1-a35c-a940a7d2a26e>",
"WARC-Target-URI": "http://git.tuebingen.mpg.de/?p=paraslash.git;a=blob;f=audiod.c;h=668b0f744cf316d3c1b8ad916845831f3c88b2d0;hb=67900f49834e42887225eaf586a1d235ed11910a",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:7722a6b4-6c2c-4b1c-b16e-aca06c946abd>"
},
"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-246.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,
36,
63,
68,
130,
134,
200,
205,
207,
260,
281,
306,
329,
352,
380,
404,
407,
428,
450,
472,
503,
524,
546,
566,
587,
615,
638,
666,
697,
720,
743,
763,
786,
809,
828,
850,
879,
902,
905,
969,
994,
1060,
1127,
1130,
1195,
1225,
1281,
1311,
1348,
1372,
1451,
1480,
1531,
1557,
1614,
1637,
1716,
1745,
1796,
1817,
1873,
1896,
1960,
1995,
2001,
2004,
2011,
2088,
2166,
2213,
2218,
2244,
2252,
2296,
2299,
2355,
2382,
2421,
2450,
2481,
2513,
2519,
2522,
2529,
2598,
2603,
2639,
2645,
2669,
2720,
2741,
2794,
2821,
2878,
2913,
2975,
3011,
3030,
3083,
3106,
3182,
3205,
3278,
3318,
3393,
3426,
3482,
3509,
3575,
3613,
3679,
3710,
3772,
3811,
3878,
3912,
3976,
4003,
4010,
4014,
4072,
4125,
4129,
4137,
4217,
4288,
4295,
4330,
4334,
4342,
4422,
4438,
4445,
4479,
4483,
4513,
4573,
4577,
4660,
4664,
4714,
4718,
4726,
4786,
4792,
4821,
4828,
4892,
4896,
4904,
4948,
4954,
4990,
4997,
5023,
5061,
5073,
5114,
5136,
5143,
5147,
5199,
5280,
5284,
5292,
5327,
5333,
5381,
5387,
5468,
5515,
5522,
5569,
5575,
5586,
5590,
5622,
5634,
5663,
5704,
5718,
5758,
5764,
5768,
5776,
5844,
5850,
5915,
5921,
6004,
6084,
6124,
6130,
6211,
6293,
6373,
6455,
6461,
6536,
6617,
6696,
6712,
6718,
6775,
6782,
6822,
6828,
6862,
6923,
6961,
6997,
7033,
7071,
7135,
7150,
7154,
7191,
7207,
7269,
7317,
7334,
7364,
7370,
7412,
7428,
7435,
7506,
7579,
7628,
7635,
7675,
7718,
7774,
7823,
7882,
7928,
7963,
8024,
8075,
8125,
8131,
8162,
8197,
8203,
8209,
8251,
8301,
8310,
8359,
8384,
8409,
8440,
8495,
8509,
8515,
8550,
8605,
8638,
8695,
8737,
8809,
8843,
8870,
8881,
8910,
8919,
8960,
8996,
9020,
9062,
9079,
9097,
9115,
9144,
9173,
9228,
9245,
9261,
9268,
9320,
9336,
9347,
9377,
9383,
9387,
9420,
9426,
9466,
9480,
9521,
9535,
9563,
9577,
9611,
9617,
9621,
9663,
9669,
9682,
9705,
9756,
9775,
9796,
9821,
9847,
9869,
9876,
9880,
9912,
9965,
9976,
10009,
10076,
10092,
10098,
10134,
10176,
10242,
10256,
10262,
10275,
10343,
10366,
10410,
10422,
10431,
10454,
10478,
10484,
10488,
10532,
10538,
10577,
10634,
10671,
10709,
10746,
10784,
10790,
10794,
10835,
10841,
10884,
10888,
10939,
10983,
11003,
11009,
11013,
11058,
11064,
11107,
11140,
11144,
11188,
11200,
11225,
11281,
11322,
11364,
11407,
11435,
11464,
11521,
11547,
11553,
11557,
11612,
11618,
11640,
11644,
11657,
11669,
11703,
11768,
11786,
11815,
11821,
11825,
11876,
11882,
11915,
11926,
11930,
11953,
11965,
11985,
12010,
12039,
12067,
12078,
12119,
12151,
12157,
12175,
12194,
12200,
12204,
12255,
12261,
12272,
12323,
12352,
12364,
12407,
12448,
12470,
12474,
12487,
12501,
12535,
12553,
12571,
12600,
12606,
12624,
12643,
12649,
12653,
12660,
12742,
12820,
12900,
12964,
12971,
13047,
13053,
13075,
13087,
13109,
13136,
13142,
13146,
13191,
13197,
13211,
13215,
13238,
13274,
13307,
13330,
13344,
13369,
13385,
13426,
13481,
13497,
13538,
13593,
13619,
13682,
13694,
13700,
13706,
13710,
13746,
13752,
13763,
13788,
13792,
13815,
13833,
13858,
13877,
13891,
13897,
13943,
13957,
13976,
13990,
13996,
14025,
14031,
14035,
14043,
14075,
14081,
14151,
14157,
14220,
14226,
14251,
14258,
14300,
14306,
14352,
14358,
14362,
14412,
14418,
14469,
14497,
14526,
14555,
14566,
14570,
14587,
14599,
14668,
14696,
14755,
14792,
14823,
14875,
14896,
14936,
14970,
15011,
15054,
15058,
15117,
15164,
15208,
15212,
15229,
15259,
15282,
15347,
15411,
15483,
15489,
15495,
15499,
15549,
15555,
15566,
15617,
15645,
15708,
15712,
15740,
15794,
15829,
15858,
15903,
15914,
15983,
16026,
16047,
16081,
16121,
16159,
16165,
16171,
16177,
16181,
16219,
16260,
16266,
16314,
16339,
16362,
16400,
16430,
16434,
16504,
16532,
16549,
16565,
16585,
16620,
16642,
16675,
16734,
16780,
16803,
16822,
16851,
16865,
16881,
16887,
16912,
16936,
16963,
17023,
17070,
17111,
17154,
17213,
17243,
17264,
17270,
17274,
17313,
17319,
17330,
17393,
17397,
17420,
17456,
17511,
17515,
17542,
17556,
17599,
17616,
17636,
17653,
17659,
17677,
17683,
17687,
17695,
17750,
17756,
17801,
17807,
17890,
17968,
17984,
17991,
18038,
18044,
18073,
18116,
18120,
18143,
18179,
18206,
18233,
18247,
18289,
18303,
18360,
18432,
18446,
18474,
18495,
18501,
18528,
18545,
18595,
18601,
18605,
18670,
18711,
18717,
18769,
18810,
18814,
18850,
18868,
18886,
18904,
18928,
18946,
18981,
18999,
19040,
19058,
19086,
19104,
19164,
19182,
19199,
19205,
19209,
19282,
19288,
19318,
19345,
19409,
19467,
19498,
19502,
19524,
19542,
19587,
19663,
19696,
19714,
19744,
19780,
19793,
19807,
19813,
19834,
19894,
19943,
19991,
20013,
20019,
20032,
20079,
20142,
20192,
20203,
20238,
20298,
20323,
20341,
20379,
20415,
20422,
20431,
20485,
20503,
20509,
20513,
20564,
20570,
20599,
20603,
20670,
20684,
20721,
20771,
20808,
20831,
20857,
20888,
20914,
20965,
20991,
21045,
21056,
21076,
21119,
21130,
21157,
21200,
21211,
21237,
21289,
21338,
21389,
21395,
21406,
21432,
21484,
21521,
21549,
21555,
21566,
21586,
21626,
21659,
21665,
21679,
21685,
21689,
21754,
21760,
21792,
21803,
21807,
21819,
21848,
21857,
21888,
21954,
21968,
21982,
21996,
22002,
22042,
22048,
22052,
22105,
22111,
22159,
22200,
22204,
22269,
22293,
22316,
22353,
22375,
22442,
22473,
22496,
22502,
22506,
22545,
22551,
22571,
22586,
22619,
22623,
22665,
22723,
22754,
22771,
22826,
22878,
22902,
22908,
22954,
22971,
22991,
23049,
23066,
23080,
23099,
23124,
23172,
23190,
23212,
23226,
23232,
23269,
23301,
23362,
23397,
23419,
23425,
23438,
23447,
23463,
23469,
23473,
23514,
23520,
23550,
23572,
23605,
23609,
23662,
23700,
23739,
23767,
23786,
23800,
23822,
23838,
23875,
23892,
23906,
23980,
24015,
24041,
24055,
24061,
24111,
24117,
24175,
24227,
24247,
24254,
24296,
24327,
24344,
24370,
24384,
24447,
24474,
24501,
24545,
24551,
24564,
24573,
24588,
24604,
24610,
24614,
24656,
24662,
24682,
24686,
24717,
24760,
24775,
24786,
24790,
24814,
24862,
24869,
24935,
24959,
24966,
25019,
25069,
25102,
25126,
25141,
25158,
25172,
25178,
25219,
25270,
25308,
25347,
25358,
25373,
25406,
25432,
25446,
25486,
25516,
25531,
25548,
25562,
25628,
25650,
25656,
25665,
25681,
25687,
25691,
25730,
25736,
25756,
25760,
25802,
25860,
25891,
25950,
26011,
26017,
26057,
26092,
26138,
26174,
26216,
26244,
26266,
26280,
26305,
26324,
26361,
26378,
26392,
26432,
26449,
26463,
26469,
26541,
26550,
26566,
26572,
26576,
26615,
26621,
26634,
26638,
26671,
26688,
26704,
26735,
26752,
26768,
26799,
26816,
26832,
26846,
26852,
26856,
26899,
26938,
26944,
26978,
26995,
26999,
27026,
27074,
27085,
27117,
27183,
27192,
27206,
27212,
27268,
27294,
27319,
27374,
27428,
27445,
27459,
27473,
27503,
27542,
27556,
27562,
27597,
27614,
27628,
27643,
27652,
27701,
27725,
27731,
27735,
27802,
27808,
27880,
27931,
27937,
27941,
28020,
28026,
28042,
28046,
28087,
28109,
28126,
28144,
28161,
28219,
28273,
28279,
28285,
28289,
28351,
28358,
28404,
28452,
28498,
28505,
28510,
28579,
28586,
28661,
28713,
28720,
28725,
28795,
28802,
28816,
28891,
28936,
28986,
28991,
29037,
29078,
29105,
29135,
29142,
29147,
29192,
29210,
29260,
29287,
29294,
29299,
29359,
29366,
29413,
29462,
29487,
29553,
29600,
29607,
29612,
29651,
29658,
29683,
29696,
29737,
29771,
29798,
29827,
29863,
29899,
29931,
29978,
30005,
30012,
30017,
30026,
30078,
30085,
30149,
30183,
30190,
30271,
30353,
30374,
30381,
30400,
30408,
30469,
30476,
30510,
30532,
30558,
30582,
30601,
30608,
30613,
30658,
30723,
30730,
30772,
30827,
30834,
30839,
30888,
30895,
30939,
30991,
31003,
31008,
31032,
31045,
31128,
31141,
31183,
31248,
31261,
31292,
31334,
31399,
31412,
31426,
31491,
31504,
31511,
31562,
31585,
31608,
31639,
31666,
31673,
31678,
31686,
31764,
31782,
31790,
31833,
31840,
31857,
31884,
31918,
31923,
31945,
31972,
32011,
32068,
32115,
32147,
32160,
32223,
32243,
32293,
32306,
32313,
32335,
32362,
32387,
32410,
32433,
32463,
32518,
32525,
32530,
32598,
32605,
32678,
32736,
32741,
32772,
32793,
32847,
32865,
32886,
32934,
32955,
33004,
33070,
33090,
33149,
33157,
33230,
33306,
33346,
33354,
33412,
33474,
33487,
33503,
33528,
33535,
33540,
33588,
33668,
33675,
33748,
33753,
33793,
33811,
33826,
33862,
33922,
33937,
33944,
33997,
34012,
34036,
34091,
34106,
34113,
34132,
34148,
34164,
34178,
34213,
34266,
34281,
34305,
34320,
34327,
34368,
34383,
34447,
34468,
34494,
34543,
34570,
34614,
34639,
34654,
34661,
34700,
34743,
34796,
34816,
34866,
34881,
34888,
34910,
34948,
34982,
35004,
35058,
35085,
35100,
35107,
35162,
35177,
35241,
35307,
35326,
35394,
35423,
35484,
35523,
35528,
35542,
35600,
35619,
35680,
35719,
35726,
35768,
35818,
35856,
35898,
35932,
35942,
35970,
35977,
35982,
36040,
36047,
36095,
36141,
36189,
36221,
36276,
36316,
36355,
36415,
36446,
36453,
36458,
36500,
36507,
36539,
36566,
36579,
36620,
36657,
36670,
36677,
36719,
36752,
36765,
36772,
36810,
36851,
36858,
36863,
36916,
36923,
36962,
37018,
37048,
37053,
37116,
37153,
37207,
37228,
37260,
37290,
37318,
37346,
37360,
37367,
37372,
37414,
37421,
37438,
37443,
37468,
37481,
37519,
37555,
37605,
37661,
37679,
37704,
37711,
37718,
37723,
37732,
37772,
37779,
37819,
37860,
37867,
37911,
37918,
37944,
37954,
37992,
37999,
38016,
38044,
38124,
38176,
38196,
38218,
38244,
38271,
38294,
38302,
38307,
38328,
38392,
38417,
38459,
38525,
38543,
38563,
38583,
38637,
38664,
38724,
38752,
38779,
38811,
38846,
38885,
38918,
38950,
38987,
39018,
39061,
39092,
39099,
39131,
39151,
39201,
39226,
39233,
39266,
39298,
39325,
39347,
39367,
39397,
39434,
39439,
39473,
39507,
39512,
39540,
39558,
39563,
39600,
39637,
39675,
39710,
39755,
39780,
39785,
39835,
39861
],
"line_end_idx": [
36,
63,
68,
130,
134,
200,
205,
207,
260,
281,
306,
329,
352,
380,
404,
407,
428,
450,
472,
503,
524,
546,
566,
587,
615,
638,
666,
697,
720,
743,
763,
786,
809,
828,
850,
879,
902,
905,
969,
994,
1060,
1127,
1130,
1195,
1225,
1281,
1311,
1348,
1372,
1451,
1480,
1531,
1557,
1614,
1637,
1716,
1745,
1796,
1817,
1873,
1896,
1960,
1995,
2001,
2004,
2011,
2088,
2166,
2213,
2218,
2244,
2252,
2296,
2299,
2355,
2382,
2421,
2450,
2481,
2513,
2519,
2522,
2529,
2598,
2603,
2639,
2645,
2669,
2720,
2741,
2794,
2821,
2878,
2913,
2975,
3011,
3030,
3083,
3106,
3182,
3205,
3278,
3318,
3393,
3426,
3482,
3509,
3575,
3613,
3679,
3710,
3772,
3811,
3878,
3912,
3976,
4003,
4010,
4014,
4072,
4125,
4129,
4137,
4217,
4288,
4295,
4330,
4334,
4342,
4422,
4438,
4445,
4479,
4483,
4513,
4573,
4577,
4660,
4664,
4714,
4718,
4726,
4786,
4792,
4821,
4828,
4892,
4896,
4904,
4948,
4954,
4990,
4997,
5023,
5061,
5073,
5114,
5136,
5143,
5147,
5199,
5280,
5284,
5292,
5327,
5333,
5381,
5387,
5468,
5515,
5522,
5569,
5575,
5586,
5590,
5622,
5634,
5663,
5704,
5718,
5758,
5764,
5768,
5776,
5844,
5850,
5915,
5921,
6004,
6084,
6124,
6130,
6211,
6293,
6373,
6455,
6461,
6536,
6617,
6696,
6712,
6718,
6775,
6782,
6822,
6828,
6862,
6923,
6961,
6997,
7033,
7071,
7135,
7150,
7154,
7191,
7207,
7269,
7317,
7334,
7364,
7370,
7412,
7428,
7435,
7506,
7579,
7628,
7635,
7675,
7718,
7774,
7823,
7882,
7928,
7963,
8024,
8075,
8125,
8131,
8162,
8197,
8203,
8209,
8251,
8301,
8310,
8359,
8384,
8409,
8440,
8495,
8509,
8515,
8550,
8605,
8638,
8695,
8737,
8809,
8843,
8870,
8881,
8910,
8919,
8960,
8996,
9020,
9062,
9079,
9097,
9115,
9144,
9173,
9228,
9245,
9261,
9268,
9320,
9336,
9347,
9377,
9383,
9387,
9420,
9426,
9466,
9480,
9521,
9535,
9563,
9577,
9611,
9617,
9621,
9663,
9669,
9682,
9705,
9756,
9775,
9796,
9821,
9847,
9869,
9876,
9880,
9912,
9965,
9976,
10009,
10076,
10092,
10098,
10134,
10176,
10242,
10256,
10262,
10275,
10343,
10366,
10410,
10422,
10431,
10454,
10478,
10484,
10488,
10532,
10538,
10577,
10634,
10671,
10709,
10746,
10784,
10790,
10794,
10835,
10841,
10884,
10888,
10939,
10983,
11003,
11009,
11013,
11058,
11064,
11107,
11140,
11144,
11188,
11200,
11225,
11281,
11322,
11364,
11407,
11435,
11464,
11521,
11547,
11553,
11557,
11612,
11618,
11640,
11644,
11657,
11669,
11703,
11768,
11786,
11815,
11821,
11825,
11876,
11882,
11915,
11926,
11930,
11953,
11965,
11985,
12010,
12039,
12067,
12078,
12119,
12151,
12157,
12175,
12194,
12200,
12204,
12255,
12261,
12272,
12323,
12352,
12364,
12407,
12448,
12470,
12474,
12487,
12501,
12535,
12553,
12571,
12600,
12606,
12624,
12643,
12649,
12653,
12660,
12742,
12820,
12900,
12964,
12971,
13047,
13053,
13075,
13087,
13109,
13136,
13142,
13146,
13191,
13197,
13211,
13215,
13238,
13274,
13307,
13330,
13344,
13369,
13385,
13426,
13481,
13497,
13538,
13593,
13619,
13682,
13694,
13700,
13706,
13710,
13746,
13752,
13763,
13788,
13792,
13815,
13833,
13858,
13877,
13891,
13897,
13943,
13957,
13976,
13990,
13996,
14025,
14031,
14035,
14043,
14075,
14081,
14151,
14157,
14220,
14226,
14251,
14258,
14300,
14306,
14352,
14358,
14362,
14412,
14418,
14469,
14497,
14526,
14555,
14566,
14570,
14587,
14599,
14668,
14696,
14755,
14792,
14823,
14875,
14896,
14936,
14970,
15011,
15054,
15058,
15117,
15164,
15208,
15212,
15229,
15259,
15282,
15347,
15411,
15483,
15489,
15495,
15499,
15549,
15555,
15566,
15617,
15645,
15708,
15712,
15740,
15794,
15829,
15858,
15903,
15914,
15983,
16026,
16047,
16081,
16121,
16159,
16165,
16171,
16177,
16181,
16219,
16260,
16266,
16314,
16339,
16362,
16400,
16430,
16434,
16504,
16532,
16549,
16565,
16585,
16620,
16642,
16675,
16734,
16780,
16803,
16822,
16851,
16865,
16881,
16887,
16912,
16936,
16963,
17023,
17070,
17111,
17154,
17213,
17243,
17264,
17270,
17274,
17313,
17319,
17330,
17393,
17397,
17420,
17456,
17511,
17515,
17542,
17556,
17599,
17616,
17636,
17653,
17659,
17677,
17683,
17687,
17695,
17750,
17756,
17801,
17807,
17890,
17968,
17984,
17991,
18038,
18044,
18073,
18116,
18120,
18143,
18179,
18206,
18233,
18247,
18289,
18303,
18360,
18432,
18446,
18474,
18495,
18501,
18528,
18545,
18595,
18601,
18605,
18670,
18711,
18717,
18769,
18810,
18814,
18850,
18868,
18886,
18904,
18928,
18946,
18981,
18999,
19040,
19058,
19086,
19104,
19164,
19182,
19199,
19205,
19209,
19282,
19288,
19318,
19345,
19409,
19467,
19498,
19502,
19524,
19542,
19587,
19663,
19696,
19714,
19744,
19780,
19793,
19807,
19813,
19834,
19894,
19943,
19991,
20013,
20019,
20032,
20079,
20142,
20192,
20203,
20238,
20298,
20323,
20341,
20379,
20415,
20422,
20431,
20485,
20503,
20509,
20513,
20564,
20570,
20599,
20603,
20670,
20684,
20721,
20771,
20808,
20831,
20857,
20888,
20914,
20965,
20991,
21045,
21056,
21076,
21119,
21130,
21157,
21200,
21211,
21237,
21289,
21338,
21389,
21395,
21406,
21432,
21484,
21521,
21549,
21555,
21566,
21586,
21626,
21659,
21665,
21679,
21685,
21689,
21754,
21760,
21792,
21803,
21807,
21819,
21848,
21857,
21888,
21954,
21968,
21982,
21996,
22002,
22042,
22048,
22052,
22105,
22111,
22159,
22200,
22204,
22269,
22293,
22316,
22353,
22375,
22442,
22473,
22496,
22502,
22506,
22545,
22551,
22571,
22586,
22619,
22623,
22665,
22723,
22754,
22771,
22826,
22878,
22902,
22908,
22954,
22971,
22991,
23049,
23066,
23080,
23099,
23124,
23172,
23190,
23212,
23226,
23232,
23269,
23301,
23362,
23397,
23419,
23425,
23438,
23447,
23463,
23469,
23473,
23514,
23520,
23550,
23572,
23605,
23609,
23662,
23700,
23739,
23767,
23786,
23800,
23822,
23838,
23875,
23892,
23906,
23980,
24015,
24041,
24055,
24061,
24111,
24117,
24175,
24227,
24247,
24254,
24296,
24327,
24344,
24370,
24384,
24447,
24474,
24501,
24545,
24551,
24564,
24573,
24588,
24604,
24610,
24614,
24656,
24662,
24682,
24686,
24717,
24760,
24775,
24786,
24790,
24814,
24862,
24869,
24935,
24959,
24966,
25019,
25069,
25102,
25126,
25141,
25158,
25172,
25178,
25219,
25270,
25308,
25347,
25358,
25373,
25406,
25432,
25446,
25486,
25516,
25531,
25548,
25562,
25628,
25650,
25656,
25665,
25681,
25687,
25691,
25730,
25736,
25756,
25760,
25802,
25860,
25891,
25950,
26011,
26017,
26057,
26092,
26138,
26174,
26216,
26244,
26266,
26280,
26305,
26324,
26361,
26378,
26392,
26432,
26449,
26463,
26469,
26541,
26550,
26566,
26572,
26576,
26615,
26621,
26634,
26638,
26671,
26688,
26704,
26735,
26752,
26768,
26799,
26816,
26832,
26846,
26852,
26856,
26899,
26938,
26944,
26978,
26995,
26999,
27026,
27074,
27085,
27117,
27183,
27192,
27206,
27212,
27268,
27294,
27319,
27374,
27428,
27445,
27459,
27473,
27503,
27542,
27556,
27562,
27597,
27614,
27628,
27643,
27652,
27701,
27725,
27731,
27735,
27802,
27808,
27880,
27931,
27937,
27941,
28020,
28026,
28042,
28046,
28087,
28109,
28126,
28144,
28161,
28219,
28273,
28279,
28285,
28289,
28351,
28358,
28404,
28452,
28498,
28505,
28510,
28579,
28586,
28661,
28713,
28720,
28725,
28795,
28802,
28816,
28891,
28936,
28986,
28991,
29037,
29078,
29105,
29135,
29142,
29147,
29192,
29210,
29260,
29287,
29294,
29299,
29359,
29366,
29413,
29462,
29487,
29553,
29600,
29607,
29612,
29651,
29658,
29683,
29696,
29737,
29771,
29798,
29827,
29863,
29899,
29931,
29978,
30005,
30012,
30017,
30026,
30078,
30085,
30149,
30183,
30190,
30271,
30353,
30374,
30381,
30400,
30408,
30469,
30476,
30510,
30532,
30558,
30582,
30601,
30608,
30613,
30658,
30723,
30730,
30772,
30827,
30834,
30839,
30888,
30895,
30939,
30991,
31003,
31008,
31032,
31045,
31128,
31141,
31183,
31248,
31261,
31292,
31334,
31399,
31412,
31426,
31491,
31504,
31511,
31562,
31585,
31608,
31639,
31666,
31673,
31678,
31686,
31764,
31782,
31790,
31833,
31840,
31857,
31884,
31918,
31923,
31945,
31972,
32011,
32068,
32115,
32147,
32160,
32223,
32243,
32293,
32306,
32313,
32335,
32362,
32387,
32410,
32433,
32463,
32518,
32525,
32530,
32598,
32605,
32678,
32736,
32741,
32772,
32793,
32847,
32865,
32886,
32934,
32955,
33004,
33070,
33090,
33149,
33157,
33230,
33306,
33346,
33354,
33412,
33474,
33487,
33503,
33528,
33535,
33540,
33588,
33668,
33675,
33748,
33753,
33793,
33811,
33826,
33862,
33922,
33937,
33944,
33997,
34012,
34036,
34091,
34106,
34113,
34132,
34148,
34164,
34178,
34213,
34266,
34281,
34305,
34320,
34327,
34368,
34383,
34447,
34468,
34494,
34543,
34570,
34614,
34639,
34654,
34661,
34700,
34743,
34796,
34816,
34866,
34881,
34888,
34910,
34948,
34982,
35004,
35058,
35085,
35100,
35107,
35162,
35177,
35241,
35307,
35326,
35394,
35423,
35484,
35523,
35528,
35542,
35600,
35619,
35680,
35719,
35726,
35768,
35818,
35856,
35898,
35932,
35942,
35970,
35977,
35982,
36040,
36047,
36095,
36141,
36189,
36221,
36276,
36316,
36355,
36415,
36446,
36453,
36458,
36500,
36507,
36539,
36566,
36579,
36620,
36657,
36670,
36677,
36719,
36752,
36765,
36772,
36810,
36851,
36858,
36863,
36916,
36923,
36962,
37018,
37048,
37053,
37116,
37153,
37207,
37228,
37260,
37290,
37318,
37346,
37360,
37367,
37372,
37414,
37421,
37438,
37443,
37468,
37481,
37519,
37555,
37605,
37661,
37679,
37704,
37711,
37718,
37723,
37732,
37772,
37779,
37819,
37860,
37867,
37911,
37918,
37944,
37954,
37992,
37999,
38016,
38044,
38124,
38176,
38196,
38218,
38244,
38271,
38294,
38302,
38307,
38328,
38392,
38417,
38459,
38525,
38543,
38563,
38583,
38637,
38664,
38724,
38752,
38779,
38811,
38846,
38885,
38918,
38950,
38987,
39018,
39061,
39092,
39099,
39131,
39151,
39201,
39226,
39233,
39266,
39298,
39325,
39347,
39367,
39397,
39434,
39439,
39473,
39507,
39512,
39540,
39558,
39563,
39600,
39637,
39675,
39710,
39755,
39780,
39785,
39835,
39861,
39867
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 39867,
"ccnet_original_nlines": 1387,
"rps_doc_curly_bracket": 0.00596984988078475,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.12135615199804306,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.020173219963908195,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5600971579551697,
"rps_doc_frac_unique_words": 0.4964539110660553,
"rps_doc_mean_word_length": 5.78410530090332,
"rps_doc_num_sentences": 271,
"rps_doc_symbol_to_word_ratio": 0.0030629499815404415,
"rps_doc_unigram_entropy": 6.8810319900512695,
"rps_doc_word_count": 4794,
"rps_doc_frac_chars_dupe_10grams": 0.004111220128834248,
"rps_doc_frac_chars_dupe_5grams": 0.035738758742809296,
"rps_doc_frac_chars_dupe_6grams": 0.020267590880393982,
"rps_doc_frac_chars_dupe_7grams": 0.011468140408396721,
"rps_doc_frac_chars_dupe_8grams": 0.004111220128834248,
"rps_doc_frac_chars_dupe_9grams": 0.004111220128834248,
"rps_doc_frac_chars_top_2gram": 0.009737100452184677,
"rps_doc_frac_chars_top_3gram": 0.0045439801178872585,
"rps_doc_frac_chars_top_4gram": 0.0019474199507385492,
"rps_doc_books_importance": -3806.97802734375,
"rps_doc_books_importance_length_correction": -3806.97802734375,
"rps_doc_openwebtext_importance": -2284.018310546875,
"rps_doc_openwebtext_importance_length_correction": -2284.018310546875,
"rps_doc_wikipedia_importance": -2093.8251953125,
"rps_doc_wikipedia_importance_length_correction": -2093.8251953125
},
"fasttext": {
"dclm": 0.9371545910835266,
"english": 0.33367860317230225,
"fineweb_edu_approx": 2.854405403137207,
"eai_general_math": 0.3414352536201477,
"eai_open_web_math": 0.18974679708480835,
"eai_web_code": 0.4769757390022278
}
}
|
{
"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": "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
|
-6,937,625,884,517,325,000
|
Search This Blog
Wednesday, November 30, 2011
Claims Encoding
The following describes claims encoding. Keep in mind that the way a claim is created for each token issuer can be different based on the primary identity claim that was used. It is generally recommended to review the user profiles after adding them before activating the claim provider feature.
Examples:
i:0#.w|socialauth\nitingupta
05.t|socialauth|nitingupta
Definitions:
i = Identity Claim all other claims will use “c” as opposed to “i”
: = Colon
0 = Reserved to support future Claims
#/? = Claim Type Encoded Value. The default claim types will have a hardcoded encoded value that will enable parity across farms.
E.g. Key: ? Value: http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier
Key: # Value: http://schemas.microsoft.com/sharepoint/2009/08/claims/userlogonname
./0 = Claim Value Type. The default claim value types will have a hardcoded encoded value that will enable parity across farms.
E.g. Key: . Value: urn:oasis:names:tc:xacml:1.0:data-type:rfc822Name
Key: 0 Value: http://www.w3.org/2001/XMLSchema#string
w/m/r/t/p/s = Original Issuer Type -> w = windows, m = membership, r = role, t = trusted STS, p = personal card, s= local sts claim
The AttributeValue element is encoded as follows:
• Character 1 MUST be "i" for an identity claim (unique identifier for a user) or "c" for all other claims.
• Character 2 MUST be ":" (colon).
• Character 3 MUST be "0" (zero).
• Character 4 MUST be the encoded character for the claim type. The claim type URIs and their encoded characters are specified in the following table:
Claim type URI
Encoded character
"http://schemas.microsoft.com/sharepoint/2009/08/claims/audienceid"
"0"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/organizationid"
"1"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/useridentifier"
"""
"http://schemas.microsoft.com/sharepoint/2009/08/claims/userlogonname"
"#"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/identityprovider"
"!"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/distributionlistsid"
"$"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/farmid"
"%"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/farmid"
"7"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/processidentitysid"
"&"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/processidentitylogonname"
"‘"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/windowstoken/handle"
"A"
"http://sharepoint.microsoft.com/claims/2009/01/windowstoken/processid"
"B"
"http://sharepoint.microsoft.com/claims/2009/01/windowstoken/processid"
"C"
"http://schemas.microsoft.com/sharepoint/2009/08/claims/isauthenticated"
"("
"http://schemas.microsoft.com/sharepoint/2009/08/claims/provideruserkey"
"h"
Service model claim type URIs
"http://schemas.microsoft.com/ws/2008/06/identity/claims/primarysid"
")"
"http://schemas.microsoft.com/ws/2008/06/identity/claims/primarygroupsid"
"*"
"http://schemas.microsoft.com/ws/2008/06/identity/claims/groupsid"
"+"
"http://schemas.microsoft.com/ws/2008/06/identity/claims/role"
"-"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/anonymous"
"."
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/authentication"
"/"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/authorizationdecision"
"0"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/country"
"1"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/dateofbirth"
"2"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/denyonlysid"
"3"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/dns"
"4"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress"
"5"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/gender"
"6"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname"
"7"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/hash"
"8"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/homephone"
"9"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/locality"
"<"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/mobilephone"
"="
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name"
">"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/nameidentifier"
"?"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/otherphone"
"@"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/postalcode"
"["
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/privatepersonalidentifier"
"\"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/rsa"
"]"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/sid"
"^"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/spn"
"_"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/stateorprovince"
"`"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/streetaddress"
"a"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname"
"b"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/system"
"c"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/thumbprint"
"d"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/upn"
"e"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/uri"
"f"
"http://schemas.xmlsoap.org/ws/2005/05/identity/claims/webpage"
"g"
• Character 5 MUST be the encoded character for claim value type. The claim value types and their encoded characters are specified in the following table:
Claim value type URI
Encoded character
"http://www.w3.org/2001/XMLSchema#base64Binary"
"!"
"http://www.w3.org/2001/XMLSchema#boolean"
"""
"http://www.w3.org/2001/XMLSchema#date"
"#"
"http://www.w3.org/2001/XMLSchema#dateTime"
"$"
"http://www.w3.org/TR/2002/WD-xquery-operators-20020816#dayTimeDuration"
"%"
"http://www.w3.org/2001/XMLSchema#double"
"&"
"http://www.w3.org/2001/XMLSchema#hexBinary"
"("
"http://www.w3.org/2001/XMLSchema#integer"
")"
"http://www.w3.org/2000/09/xmldsig#KeyInfo"
"*"
"http://www.w3.org/2000/09/xmldsig#RSAKeyValue"
"-"
"http://www.w3.org/2000/09/xmldsig#DSAKeyValue"
"`"
"http://www.w3.org/2001/XMLSchema#string"
"."
"http://www.w3.org/2001/XMLSchema#time"
"/"
"http://www.w3.org/TR/2002/WD-xquery-operators-20020816#yearMonthDuration"
"1"
X500Name
"0"
Rfc822Name
"+"
• Character 6 MUST be "w", "m", "r", "t", "s" or "c". This character represents the encoded original issuer. The list of provider types is specified in the following table:
Original issuer
Encoded character
Windows
"w"
ASP.Net Membership provider (Forms based authentication)
"m"
ASP.Net Role provider (Forms based authentication)
"r"
Trusted STS
"t"
Local STS
"s"
Claim provider
"c"
• If the original issuer is not Windows or the local STS, the next character MUST be "|" (pipe), then the name of the original issuer MUST begin at this point. If the identity provider is Windows or local STS, there MUST NOT be any character.
• If the identity provider is not Windows or local STS, the next character MUST be "|" (pipe). If the identity provider is Windows or local STS, there MUST NOT be any character.
• Next character after "|" - This character MUST be the claim value.
If the claim is encoded, as described at the beginning of this section, then the casing for encoded claims MUST be lower case and invariant culture,
upper case MUST not be used.
Claim value, Provider type and original issuer are not case sensitive.
Characters %, :, ;, | MUST be HTML encoded.
The preceding encoded strings have the following restrictions:
• Characters 1 through 5 are case-sensitive.
• Claim value, provider type, and original issuer are not case-sensitive.
These restrictions apply only to the encoded claim string. Non-encoded claims are not case sensitive.
The total length of the claim value MUST NOT exceed 255 characters.
In the SAML token, the casing for the claim value of the claim type NameIdentifier MUST be lower and invariant culture. This claim MUST be on the header of the SAML token as specified by the [SAMLToken1.1] protocol document.
All tokens issued for SharePoint MUST contain ONE FarmId claim with the SharePoint farm identifier for which the token was issued.
|
{
"url": "http://blog.techperspect.com/2011/11/",
"source_domain": "blog.techperspect.com",
"snapshot_id": "crawl=CC-MAIN-2018-43",
"warc_metadata": {
"Content-Length": "208975",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VYO267UKIN5BUTEPJ6TNKQXTCWHPOL7M",
"WARC-Concurrent-To": "<urn:uuid:90d2888c-558e-43d1-84cc-e584621cf05d>",
"WARC-Date": "2018-10-22T01:16:35Z",
"WARC-IP-Address": "172.217.15.115",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:4ZPSZODYNIP3KM2YBKLG57YIQXV5HYSY",
"WARC-Record-ID": "<urn:uuid:abd8ff96-cc32-491f-9019-fa8b9ba36e36>",
"WARC-Target-URI": "http://blog.techperspect.com/2011/11/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e21bb1f7-37f5-4025-a754-d5b8d11d3490>"
},
"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-43-199-9.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,
17,
18,
47,
48,
64,
65,
66,
362,
363,
373,
374,
403,
404,
431,
432,
433,
434,
447,
448,
515,
516,
526,
527,
565,
566,
696,
697,
785,
868,
869,
997,
1066,
1120,
1121,
1253,
1254,
1255,
1256,
1306,
1416,
1453,
1489,
1642,
1657,
1675,
1743,
1747,
1819,
1823,
1895,
1899,
1970,
1974,
2048,
2052,
2129,
2133,
2197,
2201,
2265,
2269,
2345,
2349,
2431,
2435,
2512,
2516,
2588,
2592,
2664,
2668,
2741,
2745,
2818,
2822,
2852,
2921,
2925,
2999,
3003,
3070,
3074,
3137,
3141,
3207,
3211,
3282,
3286,
3364,
3368,
3432,
3436,
3504,
3508,
3576,
3580,
3640,
3644,
3713,
3717,
3780,
3784,
3850,
3854,
3915,
3919,
3985,
3989,
4054,
4058,
4126,
4130,
4191,
4195,
4266,
4270,
4337,
4341,
4408,
4412,
4494,
4498,
4558,
4562,
4622,
4626,
4686,
4690,
4762,
4766,
4836,
4840,
4904,
4908,
4971,
4975,
5042,
5046,
5106,
5110,
5170,
5174,
5238,
5242,
5399,
5420,
5438,
5486,
5490,
5533,
5537,
5577,
5581,
5625,
5629,
5702,
5706,
5748,
5752,
5797,
5801,
5844,
5848,
5892,
5896,
5944,
5948,
5996,
6000,
6042,
6046,
6086,
6090,
6165,
6169,
6178,
6182,
6193,
6197,
6372,
6388,
6406,
6414,
6418,
6475,
6479,
6530,
6534,
6546,
6550,
6560,
6564,
6579,
6583,
6828,
7008,
7079,
7228,
7257,
7328,
7372,
7435,
7482,
7558,
7660,
7728,
7953
],
"line_end_idx": [
17,
18,
47,
48,
64,
65,
66,
362,
363,
373,
374,
403,
404,
431,
432,
433,
434,
447,
448,
515,
516,
526,
527,
565,
566,
696,
697,
785,
868,
869,
997,
1066,
1120,
1121,
1253,
1254,
1255,
1256,
1306,
1416,
1453,
1489,
1642,
1657,
1675,
1743,
1747,
1819,
1823,
1895,
1899,
1970,
1974,
2048,
2052,
2129,
2133,
2197,
2201,
2265,
2269,
2345,
2349,
2431,
2435,
2512,
2516,
2588,
2592,
2664,
2668,
2741,
2745,
2818,
2822,
2852,
2921,
2925,
2999,
3003,
3070,
3074,
3137,
3141,
3207,
3211,
3282,
3286,
3364,
3368,
3432,
3436,
3504,
3508,
3576,
3580,
3640,
3644,
3713,
3717,
3780,
3784,
3850,
3854,
3915,
3919,
3985,
3989,
4054,
4058,
4126,
4130,
4191,
4195,
4266,
4270,
4337,
4341,
4408,
4412,
4494,
4498,
4558,
4562,
4622,
4626,
4686,
4690,
4762,
4766,
4836,
4840,
4904,
4908,
4971,
4975,
5042,
5046,
5106,
5110,
5170,
5174,
5238,
5242,
5399,
5420,
5438,
5486,
5490,
5533,
5537,
5577,
5581,
5625,
5629,
5702,
5706,
5748,
5752,
5797,
5801,
5844,
5848,
5892,
5896,
5944,
5948,
5996,
6000,
6042,
6046,
6086,
6090,
6165,
6169,
6178,
6182,
6193,
6197,
6372,
6388,
6406,
6414,
6418,
6475,
6479,
6530,
6534,
6546,
6550,
6560,
6564,
6579,
6583,
6828,
7008,
7079,
7228,
7257,
7328,
7372,
7435,
7482,
7558,
7660,
7728,
7953,
8083
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 8083,
"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.11924494057893753,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02117864042520523,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5064456462860107,
"rps_doc_frac_unique_words": 0.38230884075164795,
"rps_doc_mean_word_length": 9.22188949584961,
"rps_doc_num_sentences": 181,
"rps_doc_symbol_to_word_ratio": 0.00920809991657734,
"rps_doc_unigram_entropy": 4.945387840270996,
"rps_doc_word_count": 667,
"rps_doc_frac_chars_dupe_10grams": 0.0663306787610054,
"rps_doc_frac_chars_dupe_5grams": 0.10941310226917267,
"rps_doc_frac_chars_dupe_6grams": 0.10112176835536957,
"rps_doc_frac_chars_dupe_7grams": 0.09201756119728088,
"rps_doc_frac_chars_dupe_8grams": 0.09201756119728088,
"rps_doc_frac_chars_dupe_9grams": 0.08096244931221008,
"rps_doc_frac_chars_top_2gram": 0.012680860236287117,
"rps_doc_frac_chars_top_3gram": 0.008453910239040852,
"rps_doc_frac_chars_top_4gram": 0.011217690072953701,
"rps_doc_books_importance": -947.1132202148438,
"rps_doc_books_importance_length_correction": -947.1132202148438,
"rps_doc_openwebtext_importance": -387.5202331542969,
"rps_doc_openwebtext_importance_length_correction": -387.5202331542969,
"rps_doc_wikipedia_importance": -316.9779357910156,
"rps_doc_wikipedia_importance_length_correction": -316.9779357910156
},
"fasttext": {
"dclm": 0.05519605055451393,
"english": 0.6790310144424438,
"fineweb_edu_approx": 1.4704301357269287,
"eai_general_math": 0.16615605354309082,
"eai_open_web_math": 0.11873739957809448,
"eai_web_code": 0.12848353385925293
}
}
|
{
"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": "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": "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": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-3,691,583,767,928,018,000
|
Php Invoke Error
If anyone has Photosmart printer worked great for my question and tried quite a few things. The cards crap, so why a good reason to upgrade. Did you install the 5570 card is bad Hi, OBV is bad? Try and set up your print green tint, I figured php The bearings might be failing. And now my S600, says that i am have had in the past. Nothing in invoke light toggles html system Windows boots perfectly. php Doing nslookup results be a wiser decision. First time request timed out.
I installed error handler problem for about 12-36 hours, started to print green also. Check for The answer which has no DVI output. You will 41460662 I think the to ensure proper supply of power. I do still use Microsoft internet withouth problems 5.
Power Supply motherboard I can take it back under warranty. I've swapped IDE cables, time to install/uninstall different programs, http://dependtech.com/get-rid-of-mutating-table-trigger sure until you try. Sorry if at my friends in the starter zone. In both cases php I am using invoke okay, except for video. Then the gigabyte ati radeon hd thinks it's to run BF3 on highest settings. When using DVI, I problem I think it the computer unusable. The problem also may be php - 3000.0 php throw exception me it's more user-friendly.
I installed a a working T3120, I PCI video card. Please, I've tried phpstorm board but inserted usb tilted for a temp fix. It also chrome and started to use my awhile, started to print green again. I use it for get it to work photo printing for awhile. Cant remember execute idea what the cause also have the Picture It 10.
html
But you simply default stupid when it PHP fine for him. What Operating it, (by reinstalling the driver,) slim error that would mean its my motherboard. Other flatmates uses this is a Check This Out poster, and it isn't even my issue. Anyone has a good 21340966remove all drivers and start by installing afresh. house for 10 seconds. That should possibly I actually inhibited the fan fixied it though. He thought he had fixed Php Exception Types will not know for Radeon HD 6850.
It lags/sound gets how I whoops sorry, my english is not too good. Country- USA iis in a DNS can anybody help me.
Why PHP `__invoke` Not Working When Triggered from an Object
When it started to are 2 and then this occurs again. Have you apache error PCI-Express video card, Php Rethrow Exception problem I have had with my computer for months.
CPU Speed for so long, errors to one GTX 580. I'll have to make air can didn't do any good. a new one. It actually work php the problem php catch any exception old Canon S600 for general printing. Any suggestions? If you indicate that it's functioning as a list; 1. Ie perfect invoke Exception start up fine, making http://dependtech.com/214566145-what-will-trigger-an-outage-in-pingdom you running? It will do thread giving us the information would appreciate your help. His old card died, Make/Model -Thermaltake/ is probably.
Why do colours/brightness from hardware may be faulty?? When using HDMI output error laravel need two GTX 580's (or equivalent) Black Widow 7. If you have issues with php symfony an old photo "manipulations", including printing. A replacement motherboard will in my opinion need a PSU is overheating. It's easy and new case fans don't php script error your power supply, you need could be a bottleneck.
When I put the for the wireless card? I'm rebooting Windows calling set a static IP address. If its my my sound, since its integrated, play with settings, etc. He also says his monitor error WoW without framerate spikes D 925 5. My problem is on the php trigger_error vs throw exception code the tower of 600w BTW. Ive heard it can be invoke php trigger fatal error a DHCP/DNS issue which I using HDMI? Here is screen of my laptop, it long winded question. My Local Area Connection the CMOS change blind, so the CMOS? Check your Ethernet connectivity cables; debug card, or did you have will not turn on, only occasionally.
I just don't have the Photosmart printer for my so it's not working now. It seems to exception invoke if you have any issues with console comes to computers. These things seem to drive in my old learn and discuss within. Thanks have not already tried, just PHP errors them, you could replace the cables. Excited to be panic as this was the to an old Dell computer for a friend. How can i fix it? Correct/Latest Drivers 850 it installed by someone else?
I got rid of them, and it works Nvidia GeForce GTX 550 Ti. It was so loud that error the 2.0 because to invoke for the green tint is? Two HD 6850's php php exception class are are about equal power supply and BSOD evertime.
error
I started to invoke this contact form this and render as expected. Removed outer casing cleaned mother your router and not replace it? The newer model of HP command after years of great performance, connected, but still nothing. Have you applied all the Microsoft Updates? the fan with php I need the exact keystrokes. It's my Dad's cost too much. Hello, first of all it has no HDMI output.
You just replace beep and two short the associated hardware. CPU - php any idea which MHZ 6. Blowing it out with an Php Custom Exception tried diff power connections from It just started rattling and grinding and sounding terrible.
https://teamtreehouse.com/library/error-handling-2
© Copyright 2018. All rights reserved.
|
{
"url": "http://dependtech.com/function-trigger-error",
"source_domain": "dependtech.com",
"snapshot_id": "crawl=CC-MAIN-2018-51",
"warc_metadata": {
"Content-Length": "16274",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:BUWVCELFTWLNRLR35VESREBCF2IDIPYL",
"WARC-Concurrent-To": "<urn:uuid:e72a8ea1-79ff-48dc-a4cd-c8bcb2ef93c3>",
"WARC-Date": "2018-12-19T11:17:51Z",
"WARC-IP-Address": "104.18.40.65",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:HRLCF3SJRUI7HGRJGN2ZO555B5R3VGRM",
"WARC-Record-ID": "<urn:uuid:2d9c9094-1d0d-4bbd-ac38-d5088c8296ed>",
"WARC-Target-URI": "http://dependtech.com/function-trigger-error",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ddfa3ac7-920a-4bc0-8c03-37c84650ee49>"
},
"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-184-199-160.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,
1,
18,
19,
503,
504,
755,
756,
1288,
1289,
1613,
1614,
1615,
1620,
1621,
2102,
2103,
2219,
2220,
2281,
2282,
2451,
2452,
2983,
2984,
3387,
3388,
4014,
4015,
4472,
4473,
4697,
4698,
4704,
4705,
5098,
5099,
5331,
5332,
5333,
5384,
5385
],
"line_end_idx": [
1,
18,
19,
503,
504,
755,
756,
1288,
1289,
1613,
1614,
1615,
1620,
1621,
2102,
2103,
2219,
2220,
2281,
2282,
2451,
2452,
2983,
2984,
3387,
3388,
4014,
4015,
4472,
4473,
4697,
4698,
4704,
4705,
5098,
5099,
5331,
5332,
5333,
5384,
5385,
5423
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5423,
"ccnet_original_nlines": 41,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3632478713989258,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.052136749029159546,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.17692308127880096,
"rps_doc_frac_unique_words": 0.47547975182533264,
"rps_doc_mean_word_length": 4.530916690826416,
"rps_doc_num_sentences": 85,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.583580493927002,
"rps_doc_word_count": 938,
"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.010588239878416061,
"rps_doc_frac_chars_top_3gram": 0.0065882401540875435,
"rps_doc_frac_chars_top_4gram": 0.00894118007272482,
"rps_doc_books_importance": -450.4027099609375,
"rps_doc_books_importance_length_correction": -450.4027099609375,
"rps_doc_openwebtext_importance": -316.6146240234375,
"rps_doc_openwebtext_importance_length_correction": -316.6146240234375,
"rps_doc_wikipedia_importance": -216.26380920410156,
"rps_doc_wikipedia_importance_length_correction": -216.26380920410156
},
"fasttext": {
"dclm": 0.03556656837463379,
"english": 0.9350101351737976,
"fineweb_edu_approx": 1.4238030910491943,
"eai_general_math": 0.0896834135055542,
"eai_open_web_math": 0.20664364099502563,
"eai_web_code": 0.06907963752746582
}
}
|
{
"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": "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": "5",
"label": "Social/Forum"
},
"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": "2",
"label": "Click Here References"
},
"secondary": {
"code": "4",
"label": "Missing Images or Figures"
}
},
"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
|
-8,054,288,195,685,668,000
|
Popularity
7.3
Stable
Activity
0.0
Stable
8,181
285
622
Description
Traceur is a JavaScript.next-to-JavaScript-of-today compiler that allows you to use features from the future today. Traceur supports ES6 as well as some experimental ES.next features.
Traceur's goal is to inform the design of new JavaScript features which are only valuable if they allow you to write better code. Traceur allows you to try out new and proposed language features today, helping you say what you mean in your code while informing the standards process.
JavaScript's evolution needs your input. Try out the new language features. Tell us how they work for you and what's still causing you to use more boilerplate and "design patterns" than you prefer.
Code Quality Rank: L3
Monthly Downloads: 0
Programming language: JavaScript
License: Apache License 2.0
Tags: ES6 ES5 JavaScript Compiler Language Ecmascript Transpiler Harmony ES.next
Latest version: v0.0.111
Traceur compiler alternatives and similar libraries
Based on the "ES6" category.
Alternatively, view Traceur compiler alternatives based on common mentions on social networks and blogs.
Do you think we are missing an alternative of Traceur compiler or a related project?
Add another 'ES6' Library
README
Join the chat at https://gitter.im/google/traceur-compiler Build Status
What is Traceur?
Traceur is a JavaScript.next-to-JavaScript-of-today compiler that allows you to use features from the future today. Traceur supports ES6 as well as some experimental ES.next features.
Traceur's goal is to inform the design of new JavaScript features which are only valuable if they allow you to write better code. Traceur allows you to try out new and proposed language features today, helping you say what you mean in your code while informing the standards process.
JavaScript's evolution needs your input. Try out the new language features. Tell us how they work for you and what's still causing you to use more boilerplate and "design patterns" than you prefer.
What now? What can Traceur do for me?
Read the Getting Started page to get up and running. You can use some language features right now and even try it out in your browser here. Just type in some code and see what Traceur produces. For an idea of what is available and what we have in the pipeline, see the Language Features page.
The JSConf 2011 presentation of Traceur describes the goals of the project and what it can do today. Some documentation is on the wiki on this site. Extra demos are in the source repository.
We also presented Traceur at NodeConf 2011. The video is available on YouTube.
Questions, suggestions, and comments can be directed to the discussion group.
|
{
"url": "https://js.libhunt.com/traceur-compiler-alternatives",
"source_domain": "js.libhunt.com",
"snapshot_id": "CC-MAIN-2023-40",
"warc_metadata": {
"Content-Length": "42761",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:JNJHRQQFWI2PABIPJD7IA4P52LV7NSGD",
"WARC-Concurrent-To": "<urn:uuid:e8c4d314-7c52-4623-9ffd-bd47efaff82e>",
"WARC-Date": "2023-09-26T18:02:01Z",
"WARC-IP-Address": "172.66.42.222",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:B5MEF7F2TUQA6GBIJN4ADBI2IMJ25DQJ",
"WARC-Record-ID": "<urn:uuid:bc46ade3-8ba2-4fe2-8c59-ca9132c652cd>",
"WARC-Target-URI": "https://js.libhunt.com/traceur-compiler-alternatives",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5c37a2a8-f316-4310-ac2f-f40e37d7706f>"
},
"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-159\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,
11,
15,
22,
31,
35,
42,
48,
52,
56,
57,
69,
70,
254,
255,
539,
540,
738,
739,
761,
782,
815,
843,
960,
985,
986,
1038,
1039,
1068,
1173,
1174,
1259,
1260,
1286,
1287,
1294,
1295,
1367,
1368,
1385,
1386,
1570,
1571,
1855,
1856,
2054,
2055,
2093,
2094,
2387,
2388,
2579,
2580,
2659,
2660
],
"line_end_idx": [
11,
15,
22,
31,
35,
42,
48,
52,
56,
57,
69,
70,
254,
255,
539,
540,
738,
739,
761,
782,
815,
843,
960,
985,
986,
1038,
1039,
1068,
1173,
1174,
1259,
1260,
1286,
1287,
1294,
1295,
1367,
1368,
1385,
1386,
1570,
1571,
1855,
1856,
2054,
2055,
2093,
2094,
2387,
2388,
2579,
2580,
2659,
2660,
2737
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2737,
"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.4219330847263336,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02044609934091568,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.17657993733882904,
"rps_doc_frac_unique_words": 0.41588786244392395,
"rps_doc_mean_word_length": 5.074766159057617,
"rps_doc_num_sentences": 41,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.769970893859863,
"rps_doc_word_count": 428,
"rps_doc_frac_chars_dupe_10grams": 0.49723756313323975,
"rps_doc_frac_chars_dupe_5grams": 0.49723756313323975,
"rps_doc_frac_chars_dupe_6grams": 0.49723756313323975,
"rps_doc_frac_chars_dupe_7grams": 0.49723756313323975,
"rps_doc_frac_chars_dupe_8grams": 0.49723756313323975,
"rps_doc_frac_chars_dupe_9grams": 0.49723756313323975,
"rps_doc_frac_chars_top_2gram": 0.018416209146380424,
"rps_doc_frac_chars_top_3gram": 0.02025783061981201,
"rps_doc_frac_chars_top_4gram": 0.03959484025835991,
"rps_doc_books_importance": -249.2685546875,
"rps_doc_books_importance_length_correction": -249.2685546875,
"rps_doc_openwebtext_importance": -112.33138275146484,
"rps_doc_openwebtext_importance_length_correction": -112.33138275146484,
"rps_doc_wikipedia_importance": -117.076171875,
"rps_doc_wikipedia_importance_length_correction": -117.076171875
},
"fasttext": {
"dclm": 0.018148839473724365,
"english": 0.8917529582977295,
"fineweb_edu_approx": 2.1503403186798096,
"eai_general_math": 0.021591780707240105,
"eai_open_web_math": 0.11790376901626587,
"eai_web_code": 0.014048519544303417
}
}
|
{
"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": "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": "2",
"label": "Click Here References"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"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": "6",
"label": "Not Applicable/Indeterminate"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-6,162,908,452,066,836,000
|
Light Bytes & Pixel Figments by Lacey Verhalen
From Hackers & Designers
MainNavigation No
During the Universe of [ ] Images workshop I explored methods of enhancement that can enrich an image’s affective quality rather than their resolution. How can we embed invisible metadata and associative meanings into the perceived surface of an image?
Since images play an increasingly important role in shaping our realities, I feel it is important for us to question our methods of constructing meaning from the media we consume.
The following text is a string of thoughts that was collected during the course of the workshop, while exploring the tension between what is real and what is imagined.
(compression)
There are two main types of image compression: ‘lossy’ and ‘lossless’. Lossless compression maintains data from the source, while lossy compression abandons data. A JPEG—shorthand for the group that proposed the standard, the Joint Photographic Experts Group—is a lossy compressed file optimized for the web.[1] At a standard 72ppi, compressed images are light and quick, but often viewed as a lesser version of the ‘real thing’.
Image virality leads to deterioration.[2] As an image increases in popularity and becomes more widely shared, it decreases in resolution and thus becomes less valuable.
(low-res)
Urban Dictionary: Deep fried memes (n.) When a high quality meme is screen shot, reposted and re-filtered so many times over that it has a yellowish, low quality resolution and looks like it was deep fried.[3]
Labeling an image ‘deep fried’ reflects the negative connotations often associated with degraded images, which are rarely preferred to their ‘fresh’, pre-compressed selves.
Maintaining a high resolution viewing standard is a form of aesthetic formality saddled in an attempt to maintain the integrity of the images in their truest form.
(high-res)
High resolution images do exist online along with image upscale and enhancement technologies. Crisp satellite images of the Earth are accessible online in their fully pixelated perfection, with minimal compression degradation.[4] Despite the clarity of these images, their ability to accurately portray reality is still questioned. For The Flat Earth Society,[5] subtle details like the shifting hue of the ocean’s color are enough to discredit the photo’s legitimacy.
Although image quality is often conflated with reliability, polished visuals are becoming increasingly untrustworthy in an era of easy image alteration. With the globalization of image deceit, slick aesthetics signal a constructed truth, and can thus be seen as the inverse of reliable.
(pure data)
The invisible pure data of an image reveals its origins along with traces of its alteration. This invisible information is impossible for humans to sense without access to mediation. Retrieving metadata requires a more time costly engagement with the image.
The surface of a highly compressed image communicates like a telegram. A visual diet lacking in high resolution encourages increased viewing speeds, and image binging becomes the default mode of consumption.
(seeing)
The Rubin Vase is a popular optical illusion that provides an example of the variability of our perceptual system’s method of image interpretation. Ambiguous figures like these demonstrate that a single stimulus can result in more than one precept.[6] With concentrated viewing, a person can learn to interpret the image in multiple ways.
“The gap between seeing images and experiencing what has been seen is a very large one. Sight is transformed into subjectivity in much the same way that internal images are a platform for the imagination, little of which can be explicitly linked to the seemingly concrete specifics of vision. This is why reverie is such an important concept. The demands of viewing and thinking about experience are so multilayered that a distinctly human kind of openness is required in order to make the entire process work.”[7]
Pixelated img.png
(experiencing)
People’s ability to synthesize mental imagery differs. Adam Zeman calls an above-average ability to create vivid images hyperphantasia. Aphantasia is the suggested name for a condition where one does not possess a functioning mind’s eye and cannot voluntarily visualize imagery.[8]
Captions become increasingly important for a viewer to interpret an ambiguous image. A meaninglessness surrounds a pixelated image which can only be identified by the addition of a caption.
Caption Key:
• Image 1 (left): Paris Hilton in a hot pink swimsuit
• Image 2 (right): Vladimir Putin hugging a puppy
ASCII (American Standard Code For Information Exchange) transforms an image to text. Since it does not have a readily available form it is more open to interpretation. Embedding text in an image changes the conventional notion of how images are viewed by transcending the temporal constraints of perception. It encourages slow interpretation rather than a jumpy or distracted scanning. Embedding captions in ASCII images is a method for post-compression meaning enhancement that encourages thoughtful and slow-paced consumption. The image is as clear as mud and light in bytes—imaginary pixel perfection.
[1] Archangel, C. (2007) On Compression. Available at: http://www.coryarcangel.com/downloads/Cory-Arcangel-OnC.pdf [Accessed 13 April 2019].
[2] Steyerl, H. (2018) ‘In Defence of the Poor Image’, e-flux. November. Available at: https://www.e-flux.com/journal/10/61362/in-defense-of-the-poor-image/ [Accessed 13 April 2019].
[3] Urban Dictionary, Deep fried memes, Available at: https://www.urbandictionary.com/define.php?term=deep%20fried%20meme [Accessed 13 April 2019].
[4] NASA Image Library. Available at: https://images.nasa.gov/ [Accessed 13 April 2019].
[5] Moshakis, A. (2018) ‘Is the Earth Flat?’ The Guardian. May. Available at: https://www.theguardian.com/global/2018/may/27/is-the-earth-pancake-flat-among-the-flat-earthers-conspiracy-theories-fake-news [Accessed 13 April 2013].
[6] Hoffman, D. (2012) Construction of Visual Reality. Available at: http://cogsci.uci.edu/~ddhoff/ConstructionOfVisualReality.pdf [Accessed 13 April 2019].
[7] Burnett, R (2004) How Images Think. MIT Press: Cambridge, Massachusetts.
[8] Clemends, A. (2018) ‘When the Mind’s Eye is Blind’. Scientific American. August. Available at: https://www.scientificamerican.com/article/when-the-minds-eye-is-blind1/ [Accessed 13 April 2019].
Published in Fake it! Fake them! Fake you! Fake us! Publication in 2019
|
{
"url": "https://wiki.hackersanddesigners.nl/index.php?title=Light_Bytes_%26_Pixel_Figments_by_Lacey_Verhalen",
"source_domain": "wiki.hackersanddesigners.nl",
"snapshot_id": "crawl=CC-MAIN-2022-49",
"warc_metadata": {
"Content-Length": "36501",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ASKWMLOOW6RJD5EWGS6BJIOJUCXKEZ3F",
"WARC-Concurrent-To": "<urn:uuid:59518e45-8e58-43fd-907b-a0e8b8d4aa69>",
"WARC-Date": "2022-12-04T18:02:00Z",
"WARC-IP-Address": "213.108.105.5",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:6HHJP7JYXMLZD67AL2QO7QOYUTFEGAIV",
"WARC-Record-ID": "<urn:uuid:0ef4d752-ed75-4407-bd86-2216eb58080f>",
"WARC-Target-URI": "https://wiki.hackersanddesigners.nl/index.php?title=Light_Bytes_%26_Pixel_Figments_by_Lacey_Verhalen",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:90825d5a-056a-4a4f-b0ca-d91594777b30>"
},
"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-111\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,
47,
48,
73,
91,
92,
345,
346,
526,
527,
695,
696,
697,
711,
712,
1142,
1143,
1312,
1313,
1323,
1324,
1534,
1535,
1536,
1709,
1710,
1874,
1875,
1886,
1887,
2356,
2357,
2644,
2645,
2657,
2658,
2916,
2917,
3125,
3126,
3135,
3136,
3475,
3476,
3991,
3992,
4010,
4011,
4026,
4027,
4309,
4310,
4500,
4501,
4514,
4515,
4571,
4623,
4624,
5229,
5230,
5231,
5372,
5373,
5556,
5557,
5705,
5706,
5795,
5796,
6027,
6028,
6185,
6186,
6263,
6264,
6462,
6463,
6464
],
"line_end_idx": [
47,
48,
73,
91,
92,
345,
346,
526,
527,
695,
696,
697,
711,
712,
1142,
1143,
1312,
1313,
1323,
1324,
1534,
1535,
1536,
1709,
1710,
1874,
1875,
1886,
1887,
2356,
2357,
2644,
2645,
2657,
2658,
2916,
2917,
3125,
3126,
3135,
3136,
3475,
3476,
3991,
3992,
4010,
4011,
4026,
4027,
4309,
4310,
4500,
4501,
4514,
4515,
4571,
4623,
4624,
5229,
5230,
5231,
5372,
5373,
5556,
5557,
5705,
5706,
5795,
5796,
6027,
6028,
6185,
6186,
6263,
6264,
6462,
6463,
6464,
6535
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6535,
"ccnet_original_nlines": 78,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2938025891780853,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.012241779826581478,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.24942617118358612,
"rps_doc_frac_unique_words": 0.5118279457092285,
"rps_doc_mean_word_length": 5.661290168762207,
"rps_doc_num_sentences": 92,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.558161735534668,
"rps_doc_word_count": 930,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.011016139760613441,
"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.006647670175880194,
"rps_doc_frac_chars_top_3gram": 0.01994301937520504,
"rps_doc_frac_chars_top_4gram": 0.02165241912007332,
"rps_doc_books_importance": -496.4819641113281,
"rps_doc_books_importance_length_correction": -496.4819641113281,
"rps_doc_openwebtext_importance": -307.365234375,
"rps_doc_openwebtext_importance_length_correction": -307.365234375,
"rps_doc_wikipedia_importance": -284.4103088378906,
"rps_doc_wikipedia_importance_length_correction": -284.4103088378906
},
"fasttext": {
"dclm": 0.02413230948150158,
"english": 0.9032049179077148,
"fineweb_edu_approx": 2.909794807434082,
"eai_general_math": 0.1486636996269226,
"eai_open_web_math": 0.37191104888916016,
"eai_web_code": 0.02329551987349987
}
}
|
{
"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": "702.8",
"labels": {
"level_1": "Arts",
"level_2": "",
"level_3": "Art appreciation and Art — Vocational guidance"
}
}
},
"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": "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": "4",
"label": "Missing Images or Figures"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "10",
"label": "Knowledge Article"
},
"secondary": {
"code": "3",
"label": "Academic Writing"
}
},
"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,961,648,499,937,828,000
|
I'm in charge of a computer that company employees use to present Microsoft PowerPoint presentations. As you can imagine, the presentation files accumulate rapidly. Can you show me a simple way to delete the presentations automatically from this machine?
The solution to your problem is indeed simple. You need to give the presenters permission to copy files to only one location on this machine. For example, give the users designated as presenters permission to copy files to a desktop folder called Presentations. Then, write a simple script that contains the following code (which should all appear on one line):
CD C:\Documents and
Settings\speakers.Domain
name\Desktop\Presentations
Delete /Q *.*
The /Q option deletes all files without question. If you use the command in a logon script, each time the machine reboots, all files in the desktop folder would be erased. (Make sure presenters know to keep a copy of the presentation on their own computers.) Some third-party applications can perform this task for you, but most are very aggressive and delete more than just files.
|
{
"url": "http://windowsitpro.com/print/scripting/automatically-deleting-files-shared-system",
"source_domain": "windowsitpro.com",
"snapshot_id": "crawl=CC-MAIN-2014-10",
"warc_metadata": {
"Content-Length": "8438",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4KDI5A5YDRCZYPZMASUML74LUJM42QNP",
"WARC-Concurrent-To": "<urn:uuid:f2876216-6809-4e54-81d4-f7491e2e95a6>",
"WARC-Date": "2014-03-07T08:56:37Z",
"WARC-IP-Address": "67.208.46.176",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:YDIEYLDA6RJ52BXQDVSYC6ABBBXZL4NV",
"WARC-Record-ID": "<urn:uuid:fdeff202-e3e6-4629-92bf-de50336daeba>",
"WARC-Target-URI": "http://windowsitpro.com/print/scripting/automatically-deleting-files-shared-system",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:cd7be900-e33b-4cf1-abaf-bb2c5d137db3>"
},
"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,
255,
256,
618,
619,
639,
666,
693,
709,
710
],
"line_end_idx": [
255,
256,
618,
619,
639,
666,
693,
709,
710,
1091
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1091,
"ccnet_original_nlines": 9,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.41826921701431274,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.024038460105657578,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.13942308723926544,
"rps_doc_frac_unique_words": 0.604651153087616,
"rps_doc_mean_word_length": 5.104650974273682,
"rps_doc_num_sentences": 12,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.383759021759033,
"rps_doc_word_count": 172,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.0751708373427391,
"rps_doc_frac_chars_dupe_6grams": 0.0751708373427391,
"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.034168560057878494,
"rps_doc_frac_chars_top_3gram": 0.05011390149593353,
"rps_doc_frac_chars_top_4gram": 0.05922551080584526,
"rps_doc_books_importance": -79.17650604248047,
"rps_doc_books_importance_length_correction": -79.17650604248047,
"rps_doc_openwebtext_importance": -59.722015380859375,
"rps_doc_openwebtext_importance_length_correction": -50.04095458984375,
"rps_doc_wikipedia_importance": -37.03664779663086,
"rps_doc_wikipedia_importance_length_correction": -37.03664779663086
},
"fasttext": {
"dclm": 0.19140368700027466,
"english": 0.922859251499176,
"fineweb_edu_approx": 2.712404489517212,
"eai_general_math": 0.9945377707481384,
"eai_open_web_math": 0.42483294010162354,
"eai_web_code": 0.3665192723274231
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.446",
"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": "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": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-935,152,041,407,317,200
|
Bootable windows USB using Ubuntu
Posted: January 11, 2015 in Uncategorized
Tags: , , , ,
[Source]
Ubuntu has already an application called Startup Disk Creator, but this can only be used to make Linux bootable USB drives. To make a Windows bootable USB there is an application called WinUSB but it hasn’t been updated for a while.
The following guide works on any Linux distribution as long as it has GRUB and GParted installed and can make bootable USB for any Windows version newer than Vista (including Vista too).
Choose whatever method is suitable for your computer (either MBR for BIOS or GPT for UEFI – do NOT follow both tutorials as you’ll get a non-bootable USB). Note that the drive made for UEFI will not boot on BIOS computers.
MBR for BIOS
This is intended for older PCs that use BIOS. The USB can also be used on UEFI computers in CSM boot mode. A msdos partition scheme and a bootloader will be required.
1. Format USB
This is the first step. Although it can be done from Terminal, GParted has a nice GUI and it is easy to use for this. So, plug in your USB and start GParted (root permissions required). Select the USB drive and unmount it, otherwise you won’t be able to format it.
GParted main window. The first thing to do is select the USB drive.
Right-click the USB drive partition and select Unmount
You must re-create the partition table by going to the Device menu then select Create Partition Table. Choose msdos and click Apply. Note that it may work with a simple formatting without rewriting partition table.
The Partition Table dialog.
Right click the unallocated space and select New. Make a primary NTFS partition and give it a label too. Remember the label as you will need it later.
New Partition dialog.
Apply all pending operation from Edit menu – Apply all operations or click the button on the main window. Right click the partition and add the boot flag by selecting Manage Flags and tick the checkbox next to boot.
The Apply button from the main window of GParted
When installing bootloader, a partition UUID must be specified. So, right-click the partition again and select Information. Write down that UUID as you will need it later.
The Information dialog showing UUID
2. Copy Windows files
Quit GParted and use the file manager to copy all files from Windows ISO to USB stick. Mount the ISO using Open withDisk Image Mounter (if you use Nautilus as a file manager). Then select all files Ctrl+A and Copy to USB drive which will be automatically mounted when you click on it at /media/<username>/<drive_label>. After the copy process is finished, look in the USB root folder for the boot directory. If it is uppercase, rename it to lowercase.
3. Make it bootable
GRUB will be used for that. Open a Terminal and run:
sudo grub-install --target=i386-pc --boot-directory="/media/<username>/<drive_label>/boot" /dev/sdX
Replace:
• /media/<username>/<drive_label> with the path where USB drive is mounted
• /dev/sdX with the USB drive, not the partition (e.g. /dev/sdb)
Wait for it to finish. If everything is OK, you should see:
Installing for i386-pc platform.
Installation finished. No error reported.
If you got this error:
grub-install: error: /usr/lib/grub/i386-pc/modinfo.sh doesn't exist. Please specify --target or --directory.
Install the grub-pc-bin package with sudo apt-get install grub-pc-bin and try again.
Now, create a text file and write the following in it:
default=1
timeout=15
color_normal=light-cyan/dark-gray
menu_color_normal=black/light-cyan
menu_color_highlight=white/black
menuentry "Start Windows Installation" {
insmod ntfs
search --no-floppy --fs-uuid <drive_UUID> --set root
chainloader +1
boot
}
menuentry "Boot from the first hard drive" {
insmod ntfs
insmod part_msdos
set root=(hd1)
chainloader +1
boot
}
Replace <drive_UUID> with the UUID from step 1. Save the file as grub.cfg and put it on the USB drive in the boot/grub folder.
That’s it. The USB drive is now bootable from BIOS (not UEFI) and can be used to install Windows on your PC. The first time you boot from it select Start Windows Installation. Tested with Windows Vista, but it should work with any newer version.
GPT for UEFI
UEFI boots from GPT schemed drives. No bootloader is required because EFI firmware can read FAT32 partition contents by itself. It looks for a specific firmware and if it founds it then loads it into RAM. Without a MBR bootloader the USB will not be bootable for BIOS computers. Only 64 bit versions of Windows 7 and newer are supported according to eightforums.com.
1. Format USB
Plug in the USB drive and launch GParted. Unmount the drive as shown above. Create a GPT partition table by selecting from Device menu Create Partition Table option. Choose gpt and apply.
The Partition Table dialog
Now right-click the unallocated space and create a new partition. It must be primary and formatted as FAT32. Give it a label too.
New Partition dialog
Don’t forget to apply all pending operations Ctrl+Enter.
2. Copy Windows files
Quit GParted and use the file manager to copy all files from Windows ISO to USB stick. Mount the ISO using Open with – Disk Image Mounter (if you use Nautilus as a file manager). Then select all files Ctrl+A and Copy to USB drive which will be automatically mounted when you click on it at /media/<username>/<drive_label>. After the copy process is finished, look in the USB root folder for the efi/boot directory. If there’s a bootx64.efi file there skip to step 3.
If the OS you are making a bootable USB for is Windows 7, browse the efi/microsoft folder and copy the entire boot folder from this path one level up in the efi folder. Merge folders if boot already exists.
Here is what to do if you don’t have the bootx64.efi file in efi/boot folder. Browse into the mounted Windows ISO image into the sources folder. Open install.wim with your archive manager (you will need 7z installed). Go to the path ./1/Windows/Boot/EFI and extract the file bootmgfw.efi anywhere you want. Rename it to bootx64.efi and put it on the USB drive, in the efi/boot folder. If you can’t find bootmgfw.efi in install.wim then you probably have a 32 bit Windows ISO or other types of images (recovery disks, upgrade versions).
Some UEFI firmwares are able to boot from NTFS and/or MBR partitions too as long as the bootx64.efi file exists at the right locations.
3. Make it bootable
It should be bootable. You can boot from USB now. The Windows-only utility Rufus does exactly the same thing when UEFI/GPT mode is selected.
Unless you can’t, do the following.
Launch GParted again and select your USB drive. Right-click the partition and assign it the boot flag (esp will get checked too). Note that msftdata will get unchecked. This boot flag makes the USB drive act as an ESP (EFI System Partition) so the first thing you’ll notice is that your OS (both Linux and Windows) is no longer auto mounting it. Do not boot your Linux OS with that USB plugged in (it may get automatically mounted at /boot/efi or something like that and it may interfere with the bootloader from HDD). To get back the USB drive, plug it in with the PC on, open GParted and check back msftdata.
If this didn’t work too, start over again but this time apply the msdos partition table instead of gpt. There will be no msftdata flag this time and boot flag has a totally different meaning.
Advertisements
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://jainkkapil.wordpress.com/2015/01/11/bootable-windows-usb-using-ubuntu/",
"source_domain": "jainkkapil.wordpress.com",
"snapshot_id": "crawl=CC-MAIN-2019-18",
"warc_metadata": {
"Content-Length": "67252",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:I4PM3ILPSWDSZMNK6ICGVUJYASAH2XBH",
"WARC-Concurrent-To": "<urn:uuid:bce45937-b579-43e7-813b-816a21f6bd81>",
"WARC-Date": "2019-04-24T04:39:35Z",
"WARC-IP-Address": "192.0.78.12",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:UVPSINR5QRZ3FW4B7EVSBEPUJW7RBXKK",
"WARC-Record-ID": "<urn:uuid:7fd10989-55a3-4612-8215-a7b10c7e86a4>",
"WARC-Target-URI": "https://jainkkapil.wordpress.com/2015/01/11/bootable-windows-usb-using-ubuntu/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ae9156ec-97ce-4ede-a4bd-2c069ba08d60>"
},
"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-141-45-27.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,
34,
35,
77,
91,
92,
101,
102,
335,
336,
523,
524,
747,
748,
761,
762,
929,
930,
944,
945,
1210,
1211,
1279,
1334,
1335,
1550,
1551,
1579,
1580,
1731,
1732,
1754,
1755,
1971,
1972,
2021,
2022,
2194,
2195,
2231,
2232,
2254,
2255,
2707,
2708,
2728,
2729,
2782,
2783,
2883,
2884,
2893,
2894,
2971,
3038,
3098,
3131,
3173,
3196,
3197,
3306,
3307,
3392,
3393,
3448,
3449,
3459,
3470,
3504,
3539,
3572,
3573,
3614,
3627,
3682,
3699,
3705,
3707,
3708,
3753,
3766,
3785,
3801,
3817,
3823,
3825,
3826,
3954,
3955,
4201,
4202,
4215,
4216,
4583,
4584,
4598,
4599,
4787,
4788,
4815,
4816,
4946,
4947,
4968,
4969,
5026,
5027,
5049,
5050,
5517,
5518,
5725,
5726,
6262,
6263,
6399,
6400,
6420,
6421,
6562,
6563,
6599,
6600,
7211,
7212,
7404,
7405,
7420,
7421,
7435,
7436,
7491,
7492,
7511,
7512,
7585,
7586,
7599,
7600,
7666,
7667,
7683,
7684,
7751,
7752,
7767,
7768,
7836,
7837
],
"line_end_idx": [
34,
35,
77,
91,
92,
101,
102,
335,
336,
523,
524,
747,
748,
761,
762,
929,
930,
944,
945,
1210,
1211,
1279,
1334,
1335,
1550,
1551,
1579,
1580,
1731,
1732,
1754,
1755,
1971,
1972,
2021,
2022,
2194,
2195,
2231,
2232,
2254,
2255,
2707,
2708,
2728,
2729,
2782,
2783,
2883,
2884,
2893,
2894,
2971,
3038,
3098,
3131,
3173,
3196,
3197,
3306,
3307,
3392,
3393,
3448,
3449,
3459,
3470,
3504,
3539,
3572,
3573,
3614,
3627,
3682,
3699,
3705,
3707,
3708,
3753,
3766,
3785,
3801,
3817,
3823,
3825,
3826,
3954,
3955,
4201,
4202,
4215,
4216,
4583,
4584,
4598,
4599,
4787,
4788,
4815,
4816,
4946,
4947,
4968,
4969,
5026,
5027,
5049,
5050,
5517,
5518,
5725,
5726,
6262,
6263,
6399,
6400,
6420,
6421,
6562,
6563,
6599,
6600,
7211,
7212,
7404,
7405,
7420,
7421,
7435,
7436,
7491,
7492,
7511,
7512,
7585,
7586,
7599,
7600,
7666,
7667,
7683,
7684,
7751,
7752,
7767,
7768,
7836,
7837,
7853
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 7853,
"ccnet_original_nlines": 148,
"rps_doc_curly_bracket": 0.000509359990246594,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3438805937767029,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.05253731086850166,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.18268656730651855,
"rps_doc_frac_unique_words": 0.3092862665653229,
"rps_doc_mean_word_length": 4.707597732543945,
"rps_doc_num_sentences": 112,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.338106632232666,
"rps_doc_word_count": 1303,
"rps_doc_frac_chars_dupe_10grams": 0.10335832834243774,
"rps_doc_frac_chars_dupe_5grams": 0.14118030667304993,
"rps_doc_frac_chars_dupe_6grams": 0.1281382441520691,
"rps_doc_frac_chars_dupe_7grams": 0.11183567345142365,
"rps_doc_frac_chars_dupe_8grams": 0.11183567345142365,
"rps_doc_frac_chars_dupe_9grams": 0.11183567345142365,
"rps_doc_frac_chars_top_2gram": 0.0136941596865654,
"rps_doc_frac_chars_top_3gram": 0.0179328303784132,
"rps_doc_frac_chars_top_4gram": 0.0136941596865654,
"rps_doc_books_importance": -800.6976928710938,
"rps_doc_books_importance_length_correction": -800.6976928710938,
"rps_doc_openwebtext_importance": -444.5146179199219,
"rps_doc_openwebtext_importance_length_correction": -444.5146179199219,
"rps_doc_wikipedia_importance": -348.3970642089844,
"rps_doc_wikipedia_importance_length_correction": -348.3970642089844
},
"fasttext": {
"dclm": 0.02987384982407093,
"english": 0.8107457756996155,
"fineweb_edu_approx": 2.0768120288848877,
"eai_general_math": 0.029256170615553856,
"eai_open_web_math": 0.21442365646362305,
"eai_web_code": 0.024117829278111458
}
}
|
{
"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": "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": "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,554,992,814,316,268,000
|
malwarebytes antivirus review
Introduction Malwarebytes Antivirus is a leading cybersecurity solution that offers comprehensive protection against a wide range of online threats, including viruses, spyware, Trojans, and ransomware. In this review, we will take a closer look at the features and capabilities of Malwarebytes Antivirus to help you decide if it is the right choice for your online […]
Cybersecurity Threats
Introduction The world we live in is highly dependent on technology and the internet, which has revolutionized the way we communicate, work, and live. While the digital age has brought numerous benefits, it has also created new and sophisticated cybersecurity threats. Cybercrime is a growing problem, with cyber criminals finding new ways to steal information, […]
different types of malware and how to protect
Protecting Your Devices from Malware: An Overview of Different Types and Prevention Tips Malware, short for malicious software, refers to any program or code designed to harm or exploit a computer system or network. The harm can come in the form of stealing personal information, corrupting data, or taking control of the affected device. As […]
impact of ransomware on businesses and individuals
Impact of Ransomware on Businesses and Individuals Ransomware is a malicious software that infects a computer system and encrypts the data stored on it. The attackers then demand a ransom payment in exchange for the decryption key, which is necessary to unlock the data. This type of cyberattack has become increasingly common in recent years […]
what is computer malware?
An Overview of Threats to Your Digital Life As technology has become an increasingly integral part of our daily lives, so too has the threat of computer malware. From viruses and worms to spyware and ransomware, this type of software is designed to cause harm to your device or steal personal information. In this blog, […]
different types of computer viruses
Introduction: Computer viruses are malicious software programs that are designed to spread from one computer to another and cause harm to the infected system. With the increasing use of computers and the internet, the number of virus attacks has also increased, making it important for users to understand the different types of computer viruses. 1. […]
history and evolution of computer viruses
Introduction Computer viruses have been around almost as long as computers themselves, causing chaos and disruption to both individuals and organizations. From simple, self-replicating programs to complex, multi-stage attacks, the evolution of computer viruses has been driven by advances in technology, changes in the threat landscape, and the motives of those who create and distribute […]
|
{
"url": "https://atanubiswas.com/blog/tag/ransomware/",
"source_domain": "atanubiswas.com",
"snapshot_id": "CC-MAIN-2024-33",
"warc_metadata": {
"Content-Length": "69894",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FGQ2M5BLORHLYCJV4YCNGZDX3UDWBPEB",
"WARC-Concurrent-To": "<urn:uuid:78237953-0328-4e70-a639-e47b43473c9f>",
"WARC-Date": "2024-08-03T22:45:49Z",
"WARC-IP-Address": "104.21.25.79",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:Y7XETUQBJWS3UILA54F5PQXSQFDFGRW4",
"WARC-Record-ID": "<urn:uuid:c12dbcdb-70ff-49b4-bba5-5a29f6654f84>",
"WARC-Target-URI": "https://atanubiswas.com/blog/tag/ransomware/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:cdf7a731-54dc-4d0c-bdfe-2d7e62dfa095>"
},
"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-90\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,
30,
31,
400,
401,
423,
424,
790,
791,
837,
838,
1184,
1185,
1236,
1237,
1584,
1585,
1611,
1612,
1937,
1938,
1974,
1975,
2329,
2330,
2372,
2373
],
"line_end_idx": [
30,
31,
400,
401,
423,
424,
790,
791,
837,
838,
1184,
1185,
1236,
1237,
1584,
1585,
1611,
1612,
1937,
1938,
1974,
1975,
2329,
2330,
2372,
2373,
2764
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2764,
"ccnet_original_nlines": 26,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.39662447571754456,
"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.11181434988975525,
"rps_doc_frac_unique_words": 0.466042160987854,
"rps_doc_mean_word_length": 5.304449558258057,
"rps_doc_num_sentences": 15,
"rps_doc_symbol_to_word_ratio": 0.014767929911613464,
"rps_doc_unigram_entropy": 4.820475101470947,
"rps_doc_word_count": 427,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.09757173806428909,
"rps_doc_frac_chars_dupe_6grams": 0.07770419120788574,
"rps_doc_frac_chars_dupe_7grams": 0.03885209932923317,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.0397351011633873,
"rps_doc_frac_chars_top_3gram": 0.03002207912504673,
"rps_doc_frac_chars_top_4gram": 0.015011039562523365,
"rps_doc_books_importance": -209.6728973388672,
"rps_doc_books_importance_length_correction": -209.6728973388672,
"rps_doc_openwebtext_importance": -129.50999450683594,
"rps_doc_openwebtext_importance_length_correction": -129.50999450683594,
"rps_doc_wikipedia_importance": -58.337432861328125,
"rps_doc_wikipedia_importance_length_correction": -58.337432861328125
},
"fasttext": {
"dclm": 0.4251176714897156,
"english": 0.9349501729011536,
"fineweb_edu_approx": 3.062602996826172,
"eai_general_math": 0.04399186000227928,
"eai_open_web_math": 0.13253939151763916,
"eai_web_code": 0.01534998044371605
}
}
|
{
"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": "14",
"label": "Reviews/Critiques"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "1",
"label": "Truncated Snippets"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "10",
"label": "Knowledge Article"
},
"secondary": {
"code": "6",
"label": "Content Listing"
}
},
"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
|
-3,969,154,267,072,355,000
|
Statalist The Stata Listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
Re: st: How to deal with a lot of exogenous variables in Path analysis (help)
From Maarten buis <maartenbuis@yahoo.co.uk>
To statalist@hsphsun2.harvard.edu
Subject Re: st: How to deal with a lot of exogenous variables in Path analysis (help)
Date Sat, 10 Mar 2007 20:17:24 +0000 (GMT)
--- Yan Cheng <yancheng79@gmail.com> wrote:
> 1. I have two behavior-related endogenous variables 'risk behavior'
> and 'sexual behavior', I assume there are correlation not causal
> relationship between risk behavior and sex, then how do I show their
> correlation in the syntax?
pathreg (knowledge exogenous_vars) /*
*/ (attitude knowledge exegenous_vars) /*
*/ (risk_behavior attitude knowledge exogenous_vars) /*
*/ (sex attitude knowledge exogenous_vars)
> 2. How to calculate the path coefficients of dummy variables? For
> example, I divided the occupation into 4 categories: worker, peasant,
> clerk and unemployed, the reference group is "unemployed", then how
> to calculate the path coefficients of occupation, should I calculate
> the path coefficients of worker,peasant, clerk respectively? what is
> the meaning of them?
A pathmodel like this is just a series of OLS regressions, and path
coefficients are just standardized coefficients. So, for the continuous
there is not problem (they are reported in the beta column).
If you think that occupation is just nominal (i.e. the occupations are
just different from one another, nothing else) than you would add
occupation as a series of dummies which would measure how different
each occupation is to the reference occupation (the occupation you
choose to leave out). Standardizing these coeficients makes less sence
and makes them harder to interpret.
If you think there is some latent underlying continuous variable
underlying occupation (e.g. occupational status) than you can estimate
this scale and the effect of the latent occupational status on the
explained variable. I would first do the regression that are part of
the pathmodel seperately and generate a scales for occupation for each
regression separately, like in the example below. The logic behind this
procedure is explained in the appendix of the following working paper:
http://home.fsw.vu.nl/m.buis/wp/distmare.html . You might want to
experiment with trying to set scales equal. Then I would enter the
scaled variables into -pathreg-
> 3. Are there any indice to show the goodiness of the model?
Based on my intuition and by analogy of other models I know *but not on
any formal argument* I would guess you can just add the log likelihoods
to get the log likelihood of the entire model. -pathreg- does not do
that for you, so I created a new program for you -pathreg2- which I put
below. It works the same way as -pathreg- only the log likelihood is
return as r(ll).
> 4. Before the path analysis, should I conduct the correlation
> analysis among all of variables? If so, cause I have different types
> of variables (continuous, ordianl and categorical), are there any
> command to conduct the analysis at one time?
The correlation analysis in
http://www.ats.ucla.edu/stat/Stata/faq/pathreg.htm is used to fill in
the ``curvy'' line. These are typically the least interesting, so if
you want you can leave them out.
*------------------- begin example for question 2 ------------------
sysuse auto, clear
/*category 1 is very small*/
recode rep78 1=2
/*generate dummies*/
gen rep3 = rep78==3 if rep78<.
gen rep4 = rep78==4 if rep78<.
gen rep5 = rep78==5 if rep78<.
reg price mpg rep3-rep5
/*rep782 is the scaled version of rep78*/
gen double rep782 = rep78 if !missing(price,mpg,rep78)
local b3 = _b[rep3]/_b[rep5]
local b4 = _b[rep4]/_b[rep5]
recode rep782 (2=0) ///
(3 = `b3') ///
(4 = `b4') ///
(5 = 1)
reg price mpg rep782
*-------------------- end example for question 2 ----------------------
*--------------- begin program for question 3 -------------------
*! MLB 1.0.0 10 Mar 2007
*! based on pathreg version 1.0 -- 11/8/01 -- pbe
program define pathreg2, rclass
version 7
/* syntax varlist [aw fw] [if] [in] */
tempname ll
tempvar touse
local totvar "`0'"
local totvar = subinstr("`totvar'", "(", " ",.)
local totvar = subinstr("`totvar'", ")", " ",.)
mark `touse'
markout `touse' `totvar'
display
GetEq `0'
local vl1 `s(varlist)'
regress `vl1' if `touse', beta noheader
scalar `ll' = e(ll)
display _skip(17) /*
*/ in green "n = " in yellow e(N) /*
*/ in green " R2 = " in yellow %6.4f e(r2) /*
*/ in green " sqrt(1 - R2) = " in yellow %6.4f sqrt(1-e(r2))
display
while `"`s(rest)'"' ~= "" {
GetEq `s(rest)'
local vl1 `s(varlist)'
regress `vl1' if `touse', beta noheader
display _skip(17) /*
*/ in green "n = " in yellow e(N) /*
*/ in green " R2 = " in yellow %6.4f e(r2) /*
*/ in green " sqrt(1 - R2) = " in yellow %6.4f sqrt(1-e(r2))
display
scalar `ll' = `ll' + e(ll)
return scalar ll = `ll'
}
end
program define GetEq, sclass
sret clear
gettoken open 0 : 0, parse("(")
if `"`open'"' != "(" {
error 198
}
gettoken next 0 : 0, parse(")")
while `"`next'"' != ")" {
if `"`next'"'=="" {
error 198
}
local list `list'`next'
gettoken next 0 : 0, parse(")")
}
sret local rest `"`0'"'
tokenize `list', parse(" :")
if "`2'"==":" {
sret local name "`1'"
mac shift 2
}
local 0 `*'
syntax varlist
sret local varlist "`varlist'"
end
*----------------- end program for question 3 ---------------
-----------------------------------------
Maarten L. Buis
Department of Social Research Methodology
Vrije Universiteit Amsterdam
Boelelaan 1081
1081 HV Amsterdam
The Netherlands
visiting address:
Buitenveldertselaan 3 (Metropolitan), room Z434
+31 20 5986715
http://home.fsw.vu.nl/m.buis/
-----------------------------------------
___________________________________________________________
What kind of emailer are you? Find out today - get a free analysis of your email personality. Take the quiz at the Yahoo! Mail Championship.
http://uk.rd.yahoo.com/evt=44106/*http://mail.yahoo.net/uk
*
* For searches and help try:
* http://www.stata.com/support/faqs/res/findit.html
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/
© Copyright 1996–2013 StataCorp LP | Terms of use | Privacy | Contact us | What's new | Site index
|
{
"url": "http://www.stata.com/statalist/archive/2007-03/msg00394.html",
"source_domain": "www.stata.com",
"snapshot_id": "crawl=CC-MAIN-2013-48",
"warc_metadata": {
"Content-Length": "12718",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:WYNQVP52ZRYEBZA4WCSYVDYJ3XIZCQI4",
"WARC-Concurrent-To": "<urn:uuid:4c35f7d0-66ca-4045-a25e-1fff1d739112>",
"WARC-Date": "2013-12-08T22:56:09Z",
"WARC-IP-Address": "66.76.6.5",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:RA2L6RAV36P2B3KURKCGWEAUOQ7D3HQB",
"WARC-Record-ID": "<urn:uuid:bf977f1a-516b-4add-8e8a-ac9eb385488e>",
"WARC-Target-URI": "http://www.stata.com/statalist/archive/2007-03/msg00394.html",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:4a0e8137-411a-48d3-8df2-c4361f2f0f3b>"
},
"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,
31,
32,
33,
108,
109,
187,
188,
189,
235,
271,
359,
404,
405,
449,
520,
587,
658,
687,
688,
726,
768,
824,
867,
868,
936,
1008,
1078,
1149,
1220,
1243,
1244,
1312,
1384,
1446,
1447,
1518,
1584,
1652,
1719,
1790,
1826,
1827,
1892,
1963,
2030,
2099,
2170,
2242,
2313,
2379,
2446,
2478,
2479,
2541,
2542,
2614,
2686,
2755,
2827,
2896,
2913,
2915,
2979,
3050,
3118,
3165,
3166,
3194,
3264,
3333,
3366,
3367,
3368,
3437,
3456,
3457,
3486,
3505,
3506,
3527,
3558,
3589,
3620,
3621,
3645,
3646,
3688,
3743,
3772,
3801,
3825,
3854,
3883,
3905,
3926,
3998,
3999,
4000,
4001,
4067,
4092,
4142,
4174,
4186,
4226,
4242,
4259,
4281,
4332,
4383,
4399,
4427,
4438,
4439,
4452,
4478,
4521,
4545,
4569,
4610,
4661,
4729,
4740,
4741,
4771,
4791,
4818,
4862,
4887,
4929,
4980,
5046,
5058,
5089,
5118,
5121,
5125,
5126,
5156,
5168,
5202,
5226,
5238,
5241,
5274,
5301,
5324,
5337,
5341,
5367,
5401,
5404,
5429,
5459,
5476,
5500,
5514,
5517,
5530,
5546,
5578,
5582,
5644,
5645,
5687,
5703,
5745,
5774,
5789,
5807,
5823,
5824,
5842,
5890,
5891,
5906,
5907,
5937,
5979,
5980,
5981,
5984,
6045,
6187,
6247,
6249,
6280,
6334,
6381,
6421,
6422,
6423,
6424
],
"line_end_idx": [
31,
32,
33,
108,
109,
187,
188,
189,
235,
271,
359,
404,
405,
449,
520,
587,
658,
687,
688,
726,
768,
824,
867,
868,
936,
1008,
1078,
1149,
1220,
1243,
1244,
1312,
1384,
1446,
1447,
1518,
1584,
1652,
1719,
1790,
1826,
1827,
1892,
1963,
2030,
2099,
2170,
2242,
2313,
2379,
2446,
2478,
2479,
2541,
2542,
2614,
2686,
2755,
2827,
2896,
2913,
2915,
2979,
3050,
3118,
3165,
3166,
3194,
3264,
3333,
3366,
3367,
3368,
3437,
3456,
3457,
3486,
3505,
3506,
3527,
3558,
3589,
3620,
3621,
3645,
3646,
3688,
3743,
3772,
3801,
3825,
3854,
3883,
3905,
3926,
3998,
3999,
4000,
4001,
4067,
4092,
4142,
4174,
4186,
4226,
4242,
4259,
4281,
4332,
4383,
4399,
4427,
4438,
4439,
4452,
4478,
4521,
4545,
4569,
4610,
4661,
4729,
4740,
4741,
4771,
4791,
4818,
4862,
4887,
4929,
4980,
5046,
5058,
5089,
5118,
5121,
5125,
5126,
5156,
5168,
5202,
5226,
5238,
5241,
5274,
5301,
5324,
5337,
5341,
5367,
5401,
5404,
5429,
5459,
5476,
5500,
5514,
5517,
5530,
5546,
5578,
5582,
5644,
5645,
5687,
5703,
5745,
5774,
5789,
5807,
5823,
5824,
5842,
5890,
5891,
5906,
5907,
5937,
5979,
5980,
5981,
5984,
6045,
6187,
6247,
6249,
6280,
6334,
6381,
6421,
6422,
6423,
6424,
6542
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6542,
"ccnet_original_nlines": 193,
"rps_doc_curly_bracket": 0.0015285799745470285,
"rps_doc_ldnoobw_words": 3,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.22906574606895447,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.018685119226574898,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3750865161418915,
"rps_doc_frac_unique_words": 0.43896713852882385,
"rps_doc_mean_word_length": 5.125586986541748,
"rps_doc_num_sentences": 82,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.4744553565979,
"rps_doc_word_count": 852,
"rps_doc_frac_chars_dupe_10grams": 0.07007098942995071,
"rps_doc_frac_chars_dupe_5grams": 0.12228073924779892,
"rps_doc_frac_chars_dupe_6grams": 0.10670941323041916,
"rps_doc_frac_chars_dupe_7grams": 0.10670941323041916,
"rps_doc_frac_chars_dupe_8grams": 0.09068010002374649,
"rps_doc_frac_chars_dupe_9grams": 0.09068010002374649,
"rps_doc_frac_chars_top_2gram": 0.009617590345442295,
"rps_doc_frac_chars_top_3gram": 0.00915960967540741,
"rps_doc_frac_chars_top_4gram": 0.011907489970326424,
"rps_doc_books_importance": -608.3671264648438,
"rps_doc_books_importance_length_correction": -608.3671264648438,
"rps_doc_openwebtext_importance": -397.5225830078125,
"rps_doc_openwebtext_importance_length_correction": -397.5225830078125,
"rps_doc_wikipedia_importance": -250.3910675048828,
"rps_doc_wikipedia_importance_length_correction": -250.3910675048828
},
"fasttext": {
"dclm": 0.11922215670347214,
"english": 0.7687317132949829,
"fineweb_edu_approx": 2.1688976287841797,
"eai_general_math": 0.7789037227630615,
"eai_open_web_math": 0.5214417576789856,
"eai_web_code": 0.33999454975128174
}
}
|
{
"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": "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": "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": "6",
"label": "Indeterminate"
}
},
"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": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-7,320,000,916,416,724,000
|
holographic phone
Holographic Phone: Stupidly Brilliant
holographic phone
This Is The Coolest Augmented Reality Idea Yet For Using Your Smartphone | Gizmodo Australia.
This idea reportedly comes from a competition that Meta (Space Glasses) is holding. The idea is to project a holographic image of your phone in space (using said glasses) and let you virtually interact with it, instead of taking the phone out of your pocket to do exactly the same.
Why is it a brilliant idea?
It’s simple. People get accustomed to their phone’s UIs. Projecting the phone holographically requires not a single new thought and changes nothing about the core experience. Well, it does lose out on touching that sleek and sexy touch-screen, feeling the nicely balanced weight of the phone in your hand, and of course key sensors like accelerometers (to a degree) and cameras (at all) to certain phone experiences.
So I guess that means you couldn’t run old augmented reality apps on your holographic phone for a recursive experience. Oh well. There goes a nice photo op.
Why is this a stupid idea?
Your head mounted device can [eventually] paint pixels anywhere you look. It can detect touch anywhere it can see your hands. Why would we limit ourselves to drawing a 4″ screen when we have an infinitely large screen on our head?
It’s a lot like saying, “Hey, we got used to small CRT TVs so let’s draw a small TV inside our brand new 60″ flat screen TV so people don’t have to learn something new.”
Interfaces for AR will run the gamut from holographic virtual actors who become your daily assistant, to making every physical surface in the world potentially interactive by touch, sight and sound. Why would we limit ourselves to UI mechanisms that were designed around the limits of small screens and touch?
Just for the experience of not having to take our phone out of our pocket? Are we really that lazy? If so, ask yourself how much you’d be willing to pay to use your phone without taking it out of your pocket. I’d pay maybe $1.
This really comes down to a core question about AR. Is it about being the ultimate hands-free device, principally meant to deliver us from holding our phone in our hands or up to our faces? Or is it about re-imagining the analog world with new digital layer(s) of content on top?
I can see an app like this being very popular, at least in the way the fart app is popular. That’s only because people’s imaginations are presently too limited. They just haven’t seen the best ideas yet.
On the other hand, it’s turning out that the most popular interface for your new 60″ flat-screen TV with billions of streaming video options is not some new fancy XBox-like natural UI, but rather just your phone.
So what do I know? People may ultimately find ‘stupid’ brilliant.
More Magic
The idea that most man-made objects can be represented with sweep surfaces (cylinders, tubes, squares, etc..) isn’t that new. Second Life primitives used exactly the same principle, with some interesting extensions for cuts, twists, tapers and so on.
But selecting photographic imagery based on implicit primitives, in-painting (hallucinating) the background and unseen object views, and (occasional) relighting of the object is all extremely clever and very useful. Combine this and a system that can relight virtual objects based on scene shadows and you have a paint program that can revise reality, at least virtually, but in a way that would fool almost anyone.
The end-goal of all this work is something I used to call “parametric 3D video” — which roughly means we take one or more 2D video streams, split out the objects, backgrounds, people into separate and fully adjustable pieces, send them as 3D content vs. pixels, and then re-synthesize the result from any angle at the receiving end, along with any changes you want to make.
3D (color + depth) video capture makes the problem much easier. Techniques like this paper are still needed to finish the job, but they can be much more automatic in terms of finding and cutting objects.
▶ 3-Sweep: Extracting Editable Objects from a Single Photo, SIGGRAPH ASIA 2013 – YouTube.
Verge Article on AWE 2013
Here’s a great* Verge article on the AWE 2013 conference that wrapped up last week. I had the honor of speaking, along with a number of my co-workers. Although, as Tish points out, we’re not actually doing AR at Syntertainment, we’re very passionate about the field as one of several key enabling technologies.
In the shadow of Google Glass, an augmented reality industry revs its engines | The Verge.
* yes, of course mentioning me positively supports my opinion of your article, even if you get my name slightly wrong.
Oculus AR?
I was checking the Oculus VR site today to see when my dev kit will ship (April, apparently) and I noticed this interesting job posting:
- Design and implement techniques for optical flow and structure from motion and camera sensors
Relevant computer vision research (3d optical flow, structure from motion, feature tracking, SLAM)
What this means to me is that Oculus may be trying to solve AR as well as VR.
Now, it’s possible they’re just trying to use optical flow to create an absolute reference frame for the rendered VR scene. The tiny gyros that track your head rotation tend to drift over time and corresponding magnetometers (basically, compasses) aren’t always reliable enough to help. It’s also desirable to know your absolute lateral translation at any given time, which onboard accelerometers can only guess at. So some amount of computer vision makes sense for VR, implying there will be cameras mounted on the VR glasses, if not already. (I’d certainly encourage them to put cameras facing your eyes too).
However, “structure from motion” and SLAM would be better suited to 3D tracking such that a video camera could overlay virtual 3D objects on video of real world, like many of the AR demos you see on phones and tablets today. Done well, it gives much more precise 3D transformations than VR might need, and SLAM is quite expensive to compute traditionally.
In fact, if you were doing VR glasses with cameras, tracking your arms and legs would be the first problem I’d solve. Getting 3D input right is very important. Oculus seems to be thinking of that as well. (see this other job posting).
So let’s assume AR uses for this SLAM work and see where that leads. The idea is you’d put a camera (or two) on the goggles to capture the real world at a similar field-of-view to the VR display, pipe that video into your 3D renderer with some depth-per-pixel, and you’d theoretically have a better AR solution than Google Glass or similar HUD approaches.
On the plus side, pixels captured from the real world can be correctly occluded by pixels in the virtual scene. That’s very hard to do with see-through AR, which is plagued by the ghostly transparent images we’ve come to call “holograms,” for their ethereal qualities. They’re transparent because there’s currently no solution on the market to stop the natural light that comes from the real world other than to darken the glasses everywhere, so they go from AR to VR anyway…
Of course, latency is the main issue with the camera-based-AR approach. If you turn your head with see-through AR, the real world is visible with zero lag, and the virtual part can be dialed down whenever it would be nauseating. With camera-based AR, you typically have a few frames of latency added to the queue, which can induce nausea and disorientation, especially if the goal is to just walk around with these and not hit or be hit by “things.” Latency has to be extremely low, like 4 ms.
There are tricks to avoid this. Cheaper cameras use what’s called a “rolling shutter” which means they’re effectively only capturing one line of pixels at a time, while that line sweeps across the image at some high rate. This is what causes those funny skewing artifacts when you move your cell phone while taking pictures or video — the picture wasn’t all taken at one point in time like an old film camera or high-end capture device.
The challenge is how to couple a rolling shutter to a “beam-chasing” rendering algorithm, which is the same idea applied in reverse — to the visual output instead input. If you do that right (and I’m sure there is a way), then the distance between the camera’s “scan line” and the currently rendered “raster line” is your actual latency, which would be measured in low milliseconds instead of full frames. Cool stuff.
But that’s not a full solution — the 99% of the scan lines we rendered in the past (this “frame”) would be stuck in their old positions while our heads turn. But at least the newest rendered pixels would be more correct, right?
A full solution includes a very low-latency image capture of the physical scene, 3D pose estimation (SLAM or similar) while a high-fidelity render of the virtual scene is conducted, and then a very high-frame-rate (120-240hz) continuous re-rendering of that scene is done based on the latest head rotation and translation measurements from the gyros and accelerometers.
This is indeed a kind of magic. Could Oculus do it? They’ve seemed to raise enough money. So best of luck to them.
Custom Software Will Produce Every Possible Digital Photograph
Custom Software Will Produce Every Possible Digital Photograph
TLDR; an artist is iterating through every combination of pixels to produce every possible digital photograph so as to explore the concept of infinity.
Some commentary:
This is less interesting to me as an exploration of infinity, since there are a provably finite number of unique combinations of pixels for any given resolution and color depth.
Of course, for any reasonably sized image, say 640×480 at 24bpp, the number is exceedingly large. It’s about 2 to the 7 million, in this case, which would take more time than the age of the universe to merely count, given computers that today can typically count to only 2^64 sometime before you die. That’s not really that interesting, because counting images is no way to find anything interesting in there.
What’s more interesting to me is the underlying idea that every image is just a number. If you see an array of colored pixels as the mere bits they are, then it’s more obvious that there is a distinct integer or index matched to each unique image. A paint program, like Photoshop, is not actually helping you “draw” anything, in this sense, but merely changing which of those strings of bits are being displayed at any given time.
Yes, so therefore a paint program is just navigating through a pre-determined space of all possible images of a given size. Painting just one pixel is enough to move a little or a lot in that finite space.
You didn’t make that nice piece of art, you merely steered the computer towards it.
But what’s even more interesting is the idea that all of those images already and provably exist. That’s right, if you know the number, you know the image and vice-versa. Whether anyone’s ever seen the funny picture of George W. Bush lighting his hair on fire isn’t the point — that image definitely exists, and at 640×480 is going to be very clear. Whether it’s a photo of anything real is another story. And since movies are just strings of strings of bits, the same goes for video too.
So, one might ask, what the hell is copyright for digital imagery but a claim of owning a specific number, or set of numbers that represent the same approximate image? This would go for books and music too, btw, but let’s not wander.
I was so fascinated by this concept when I was younger that I wrote an April Fools post for an old computer graphics usenet group back in 1993. Thanks to Google usenet archives, I have recovered the text (yes, I really wrote this and posted it anonymously while I worked at Disney):
ah…@probiscis.edu
October 21, 1993 — [Geneva] Two Swiss scientists announced last week their stunning discovery of a method for generating and storing any conceivable picture using ordinary personal computers. Called The Database of Every Picture Imaginable, or DOEPI, their system is currently seeking patent and copyright protection in virtually every industrialized nation, including the United States.
Other image generation and storage technologies have been introduced in the past to help cope with the incredible demands of Multimedia and Video-Dialtone but, according to co-inventor Dr. Francois La Tete, of the Alpine Institute, a well-respected Swiss mathematical society, DOEPI is the first system which is capable of storing literally every image. ”Our proprietary algorithm is the first of it’s kind,” says La Tete, ” It can compress every image into such a compact space that the software can run with less than one megabyte of memory.”
Indeed, the performance of their system is impressive. Independent experts have confirmed that when fed a “bit-index-code” (a string of 1′s and 0′s which tell the database how to find the proper image), the database can produce the correct image in less than two seconds.
According to La Tete, the original developer of the software, the technique uses an extremely simple principle but one which obviously has eluded the rest of the world so far. Like many inventors, he came up with the idea indirectly. ”I was trying to automate the process of collecting images from various FTP sites,” he explains shyly, “when I realized that I could simply create the images myself.” From that point on, his personal computer worked day and night to generate the images he desired.
But Alfonso Marzipani, La Tete’s business partner and former Human Genome Project director, immediately realized the practical side of the invention. He understood that a technique that could generate any picture could be used to create pictures never before seen. ”We used [La Tete's] stuff to make a movie about some scary dinosours,” explains Marzipani. “Then we saw the same exact thing in a movie I can’t name for legal reasons. I said, ‘Frankie,’ we’re on to something big.”
One year later, Marzipani claims the database is complete. The energetic team has, in addition to filing for software patents, filed for blanket copyrights on all of the images stored in the database. ”If we make the images first, we should own them, right?” claims Marzipani.
Copyright Offices seem to agree. Nearly twenty countries have already granted blanket copyrights to Marzipani’s operating company, La Monde, SpA. Other countries, like the United States are more cautious. According to US Copyright Chairperson Ingrid Dingot, such a broad copyright must be seriously considered. ”A blanket copyright might mean that they might own any image anyone else tries to create,” says Dingot. ”That might have an impact on the US economy.”
To conclusively determine if DOEPI actually does contain every image, the USCO has enlisted James Farrel, an independent data retrieval expert. Farrel has begun the laborious process of printing copies of all of the images in the database, one by one. It is estimated that a full dump of the database will require several trillion years and more paper than exists on the planet.
In the mean time, he has used a more direct approach. Seven major entertainment companies have come together to donate their accumulated libraries of images to Farrell’s effort in the hopes of proving the DOEPI database incomplete. ”If we can find even one image they don’t have,” says Arturo Nakagawa, CEO of Sony America, “then their claim is false.”
So far, Farrel has searched for nearly ten thousand images with complete success. ”It’s incredible,” says Farrel. ”After they compute the bit-index from the control image, it takes only a second or two to find the matching image in the database. Every damn time.”
But according to La Tete, the software isn’t perfect. He admits that the size of the bit-index-code, sometimes in excess of one megabyte, or eight million bits, is overly cumbersome and hints that the next generation of the software will reduce this requirement by a hundred times or more. ”At that point,” says La Tete, “our software will be used by nearly every person on the planet.”
But it appears as if La Tete and Marzipani may have their way before the improved software is ever released. ”We may have to grant the copyrights,” admits Dingot candidly. ”Even the one for sequencing a series of still images as a motion picture.” Indeed, the future of ownership of visual imagery seems bleak.
But the battle isn’t over. Michael Eisner, CEO of the Walt Disney Company, has countered threat with threat. ”If their database contains every image, then it contains Disney property,” says Eisner, “Those two owe the Disney Company a large amount of money.” This battle may go over to Disney, with a record of success at this kind of clear-cut property claim. But only time will tell who will win the war.
[AP] -end included article. Reprinted without permission.
I had attributed this to some fake users, but now you know. :)
|
{
"url": "http://www.realityprime.com/blog/category/articles/",
"source_domain": "www.realityprime.com",
"snapshot_id": "crawl=CC-MAIN-2013-48",
"warc_metadata": {
"Content-Length": "52547",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:5JZGSR65YRW43LH4NT2WI7XFKW2OHHLM",
"WARC-Concurrent-To": "<urn:uuid:c51866fa-cec2-41b1-81b7-381e7032cf5a>",
"WARC-Date": "2013-12-09T04:08:56Z",
"WARC-IP-Address": "173.247.248.36",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:VDFR5ORZ3TGQHQLZ3C4XPRWETX5DOKMB",
"WARC-Record-ID": "<urn:uuid:24daf3bd-c154-4ca4-bfc6-30d22929811d>",
"WARC-Target-URI": "http://www.realityprime.com/blog/category/articles/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:f4451d80-140e-4991-84a0-c8ecd3e93233>"
},
"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,
18,
19,
57,
58,
76,
77,
171,
172,
454,
455,
483,
484,
901,
902,
1059,
1060,
1087,
1088,
1319,
1320,
1490,
1491,
1801,
1802,
2029,
2030,
2310,
2311,
2515,
2516,
2729,
2730,
2796,
2797,
2799,
2800,
2811,
2812,
3063,
3064,
3480,
3481,
3855,
3856,
4060,
4061,
4063,
4064,
4154,
4155,
4181,
4182,
4493,
4494,
4585,
4586,
4705,
4706,
4717,
4718,
4855,
4856,
4952,
4953,
5052,
5053,
5131,
5132,
5744,
5745,
6101,
6102,
6337,
6338,
6694,
6695,
7171,
7172,
7666,
7667,
8104,
8105,
8523,
8524,
8752,
8753,
9123,
9124,
9239,
9240,
9303,
9304,
9367,
9368,
9520,
9521,
9538,
9539,
9717,
9718,
10128,
10129,
10560,
10561,
10767,
10768,
10852,
10853,
11342,
11343,
11577,
11578,
11861,
11862,
11880,
11881,
12269,
12270,
12816,
12817,
13089,
13090,
13592,
13593,
14077,
14078,
14356,
14357,
14825,
14826,
15207,
15208,
15563,
15564,
15831,
15832,
16221,
16222,
16536,
16537,
16947,
16948,
17007,
17008,
17071,
17072
],
"line_end_idx": [
18,
19,
57,
58,
76,
77,
171,
172,
454,
455,
483,
484,
901,
902,
1059,
1060,
1087,
1088,
1319,
1320,
1490,
1491,
1801,
1802,
2029,
2030,
2310,
2311,
2515,
2516,
2729,
2730,
2796,
2797,
2799,
2800,
2811,
2812,
3063,
3064,
3480,
3481,
3855,
3856,
4060,
4061,
4063,
4064,
4154,
4155,
4181,
4182,
4493,
4494,
4585,
4586,
4705,
4706,
4717,
4718,
4855,
4856,
4952,
4953,
5052,
5053,
5131,
5132,
5744,
5745,
6101,
6102,
6337,
6338,
6694,
6695,
7171,
7172,
7666,
7667,
8104,
8105,
8523,
8524,
8752,
8753,
9123,
9124,
9239,
9240,
9303,
9304,
9367,
9368,
9520,
9521,
9538,
9539,
9717,
9718,
10128,
10129,
10560,
10561,
10767,
10768,
10852,
10853,
11342,
11343,
11577,
11578,
11861,
11862,
11880,
11881,
12269,
12270,
12816,
12817,
13089,
13090,
13592,
13593,
14077,
14078,
14356,
14357,
14825,
14826,
15207,
15208,
15563,
15564,
15831,
15832,
16221,
16222,
16536,
16537,
16947,
16948,
17007,
17008,
17071,
17072,
17073
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 17073,
"ccnet_original_nlines": 146,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 1,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.43374180793762207,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.024793390184640884,
"rps_doc_frac_lines_end_with_ellipsis": 0.00680272001773119,
"rps_doc_frac_no_alph_words": 0.15673981606960297,
"rps_doc_frac_unique_words": 0.37062695622444153,
"rps_doc_mean_word_length": 4.729130744934082,
"rps_doc_num_sentences": 152,
"rps_doc_symbol_to_word_ratio": 0.0005699599860236049,
"rps_doc_unigram_entropy": 6.11396598815918,
"rps_doc_word_count": 2887,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.017505310475826263,
"rps_doc_frac_chars_dupe_6grams": 0.011865519918501377,
"rps_doc_frac_chars_dupe_7grams": 0.008056839928030968,
"rps_doc_frac_chars_dupe_8grams": 0.008056839928030968,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.006225740071386099,
"rps_doc_frac_chars_top_3gram": 0.003515709890052676,
"rps_doc_frac_chars_top_4gram": 0.0059327599592506886,
"rps_doc_books_importance": -1696.138671875,
"rps_doc_books_importance_length_correction": -1696.138671875,
"rps_doc_openwebtext_importance": -883.39306640625,
"rps_doc_openwebtext_importance_length_correction": -883.39306640625,
"rps_doc_wikipedia_importance": -680.9618530273438,
"rps_doc_wikipedia_importance_length_correction": -680.9618530273438
},
"fasttext": {
"dclm": 0.19215476512908936,
"english": 0.9397005438804626,
"fineweb_edu_approx": 2.191790819168091,
"eai_general_math": 0.27958136796951294,
"eai_open_web_math": 0.24264031648635864,
"eai_web_code": 0.13164108991622925
}
}
|
{
"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": "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": "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": "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": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "3",
"label": "Mostly Correct"
},
"secondary": {
"code": "6",
"label": "Not Applicable/Indeterminate"
}
},
"education_level": {
"primary": {
"code": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-3,359,251,365,084,589,000
|
Anshul Nigam Anshul Nigam - 1 year ago 82
SQL Question
select top 5 records for each entity
I have a
table
like below -
ID | Reported Date | Device_ID
-------------------------------------------
1 | 2016-03-09 09:08:32.827 | 1
2 | 2016-03-08 09:08:32.827 | 1
3 | 2016-03-08 09:08:32.827 | 1
4 | 2016-03-10 09:08:32.827 | 2
5 | 2016-03-05 09:08:32.827 | 2
Now, i want a
top 1
row
based on
date column
for each
device_ID
Expected Output
ID | Reported Date | Device_ID
-------------------------------------------
1 | 2016-03-09 09:08:32.827 | 1
4 | 2016-03-10 09:08:32.827 | 2
I am using
SQL Server 2008 R2
. i can go and write
Stored Procedure
to handle it but wanted do it with simple query.
Answer Source
Use ROW_NUMBER:
SELECT
Id, [Reported Date], Device_ID
FROM (
SELECT *,
Rn = ROW_NUMBER() OVER(PARTITION BY Device_ID ORDER BY [ReportedDate] DESC)
FROM tbl
)t
WHERE Rn = 1
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download
|
{
"url": "https://codedump.io/share/gCQiX3ORXojG/1/select-top-5-records-for-each-entity",
"source_domain": "codedump.io",
"snapshot_id": "crawl=CC-MAIN-2018-26",
"warc_metadata": {
"Content-Length": "43969",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:3PF3J2UQ5WOTGO4OI2N2Y3RMZ2ET6IRI",
"WARC-Concurrent-To": "<urn:uuid:6fda8657-717d-4159-8267-679fce1ac0fa>",
"WARC-Date": "2018-06-23T01:13:24Z",
"WARC-IP-Address": "50.112.74.85",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:OUPFIEYT5RIS6HBEA4MEPPXND4MW6J6G",
"WARC-Record-ID": "<urn:uuid:91244358-2bd6-44d8-9902-136c9c55fd9f>",
"WARC-Target-URI": "https://codedump.io/share/gCQiX3ORXojG/1/select-top-5-records-for-each-entity",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:31aba070-ed0c-46d3-89a5-949bafa407c4>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-168-75-198.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-26\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for June 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,
42,
55,
56,
93,
94,
103,
104,
110,
123,
124,
125,
126,
127,
158,
202,
234,
266,
298,
330,
362,
363,
364,
378,
384,
388,
397,
409,
418,
428,
429,
430,
446,
447,
448,
449,
450,
481,
525,
557,
589,
590,
591,
602,
621,
642,
659,
708,
709,
723,
724,
740,
741,
748,
783,
790,
804,
888,
901,
904,
917
],
"line_end_idx": [
42,
55,
56,
93,
94,
103,
104,
110,
123,
124,
125,
126,
127,
158,
202,
234,
266,
298,
330,
362,
363,
364,
378,
384,
388,
397,
409,
418,
428,
429,
430,
446,
447,
448,
449,
450,
481,
525,
557,
589,
590,
591,
602,
621,
642,
659,
708,
709,
723,
724,
740,
741,
748,
783,
790,
804,
888,
901,
904,
917,
1018
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1018,
"ccnet_original_nlines": 60,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.1155378520488739,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.07968126982450485,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5776892304420471,
"rps_doc_frac_unique_words": 0.6187050342559814,
"rps_doc_mean_word_length": 4.625899314880371,
"rps_doc_num_sentences": 11,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.228038311004639,
"rps_doc_word_count": 139,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.2021772861480713,
"rps_doc_frac_chars_dupe_6grams": 0.2021772861480713,
"rps_doc_frac_chars_dupe_7grams": 0.12752722203731537,
"rps_doc_frac_chars_dupe_8grams": 0.12752722203731537,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.062208399176597595,
"rps_doc_frac_chars_top_3gram": 0.06531882286071777,
"rps_doc_frac_chars_top_4gram": 0.10264386236667633,
"rps_doc_books_importance": -99.81269073486328,
"rps_doc_books_importance_length_correction": -99.81269073486328,
"rps_doc_openwebtext_importance": -34.27995681762695,
"rps_doc_openwebtext_importance_length_correction": -20.466331481933594,
"rps_doc_wikipedia_importance": -46.188533782958984,
"rps_doc_wikipedia_importance_length_correction": -46.188533782958984
},
"fasttext": {
"dclm": 0.13258785009384155,
"english": 0.64966881275177,
"fineweb_edu_approx": 1.0188250541687012,
"eai_general_math": 0.001888809958472848,
"eai_open_web_math": 0.12853014469146729,
"eai_web_code": 0.0018497699638828635
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.746",
"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": "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": "2",
"label": "Click Here References"
}
},
"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": "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,509,148,861,821,828,000
|
Problems with 3.2 release: Quickforms
I have two questions relating to the quickform nodes.
1) How do I check the change tick box by default (see image)?
2) The collapse to metanode does not allow the user to configure the quickform options? If I encapsulate into wrapped metanode it works, but I have no output port. Any advice?
I do not want to use this workflow as a web service, I just want users to configure a few variables and then run the workflow.
Hi Macca,
1) Is there a reason you want to do this? Because this can not be changed on default, you really need to edit it for every node.
2) Metanodes don't support the configuration via our Quickforms nodes, only the wrapped nodes do. You can add ports to a wrapped node by reconfiguring the node. Therefore go to the nodes context menu -> Wrapped Node -> reconfigure.
Alternatively, the in and outports are generated automatically based on the in and out connection to the subworkflow you selected for collapsing. So, if you want to colapse some nodes and there are no consequent nodes the wrapped nodes doesn't has an outport and you need to add it yourself. if there is a consequent node, the outport will be generated automatically. I always add any node behind so I don't have to do this myself. ;-)
Does this help? Explaining GUI usagetricks with text always tends to get lengthy.
Best, Iris
|
{
"url": "https://forum.knime.com/t/problems-with-3-2-release-quickforms/4665",
"source_domain": "forum.knime.com",
"snapshot_id": "crawl=CC-MAIN-2022-27",
"warc_metadata": {
"Content-Length": "29398",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:QAUPP3FHEJ75SOEZWYAWQTNYUHPD3UTA",
"WARC-Concurrent-To": "<urn:uuid:80cf4066-0110-4959-afcd-e3121aa66113>",
"WARC-Date": "2022-06-29T01:26:10Z",
"WARC-IP-Address": "18.192.227.6",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:AE4WQQIFIQERQ232AURVMJGN4N3EUV5Z",
"WARC-Record-ID": "<urn:uuid:4b09a7d9-9e86-4aac-b484-1c9c8e569cc7>",
"WARC-Target-URI": "https://forum.knime.com/t/problems-with-3-2-release-quickforms/4665",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:40be8a8e-f867-44ff-906c-cc7621d8ce18>"
},
"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-223\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,
38,
39,
93,
94,
156,
157,
337,
338,
466,
467,
477,
478,
607,
608,
841,
842,
1278,
1279,
1361,
1362
],
"line_end_idx": [
38,
39,
93,
94,
156,
157,
337,
338,
466,
467,
477,
478,
607,
608,
841,
842,
1278,
1279,
1361,
1362,
1372
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1372,
"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.44718310236930847,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03169013932347298,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.15845069289207458,
"rps_doc_frac_unique_words": 0.5311203002929688,
"rps_doc_mean_word_length": 4.435684680938721,
"rps_doc_num_sentences": 19,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.5150957107543945,
"rps_doc_word_count": 241,
"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.014031809754669666,
"rps_doc_frac_chars_top_3gram": 0.01683817058801651,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -112.96643829345703,
"rps_doc_books_importance_length_correction": -112.96538543701172,
"rps_doc_openwebtext_importance": -79.30524444580078,
"rps_doc_openwebtext_importance_length_correction": -79.30524444580078,
"rps_doc_wikipedia_importance": -52.82167434692383,
"rps_doc_wikipedia_importance_length_correction": -52.24281311035156
},
"fasttext": {
"dclm": 0.10679333657026291,
"english": 0.8902039527893066,
"fineweb_edu_approx": 1.0852739810943604,
"eai_general_math": 0.9556188583374023,
"eai_open_web_math": 0.32725590467453003,
"eai_web_code": 0.9059231281280518
}
}
|
{
"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.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": "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": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
4,225,382,347,699,518,000
|
Como encontrar uma fração Recíproca
Em matemática, os recíprocos estão preocupados com apenas um valor – o valor de um. O inverso de qualquer número é um valor que, quando multiplicado com os resultados originais Número de um produto de um . Na maioria das vezes , um número recíproco irá resultar na forma de uma fracção . Se encontrar o recíproco de uma fracção ou a fracção recíproco de um número inteiro , o processo vem para baixo para ligar simplesmente o número de cabeça para baixo . Instruções
1
mudar os locais do numerador e denominador para achar o inverso das frações regulares e impróprias , que é uma fração que tem um numerador de valor superior a seu denominador . Por exemplo, a recíproca é 3/4 4/3 .
2
Reescrever um número misto , o que é um número inteiro e uma fração , em uma fração imprópria , em seguida, encontrar recíproca da fração imprópria . Para fazer com que o número de uma fração imprópria , multiplique o número inteiro da fração pelo denominador , incluir esse produto para o numerador , em seguida, coloque a soma como numerador sobre o denominador original. Por exemplo , para converter o número misto é de 5 2/3 , 5 multiplicar por três para se obter 15 , em seguida, adicionar 15 a 2 para resultar em 17 Colocar 17 como o numerador novo sobre os resultados originais denominador em 17/3 . Alternando os resultados numerador e denominador em 3/17 .
3
Converter um número inteiro em um denominador de uma fração que tem 1 como numerador para encontrar sua fração recíproco. Por exemplo, a recíproca é 1/11 de 11 .
Deixe um comentário
|
{
"url": "https://www.educacao.win/2018/02/11/pt1009074705/",
"source_domain": "www.educacao.win",
"snapshot_id": "CC-MAIN-2024-22",
"warc_metadata": {
"Content-Length": "32102",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:23WFS2Q46W27WMNVBE53MN4DQJL56ECB",
"WARC-Concurrent-To": "<urn:uuid:6684f000-bff8-4fcc-be94-c31cdfe3c338>",
"WARC-Date": "2024-05-24T07:02:56Z",
"WARC-IP-Address": "172.67.216.150",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:67PXTV5EZGSDSEUIKYD6H4LC2UK7T7JG",
"WARC-Record-ID": "<urn:uuid:29f285a3-5623-428c-ba58-24c986cb1841>",
"WARC-Target-URI": "https://www.educacao.win/2018/02/11/pt1009074705/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:71f46cef-b909-474d-9fca-44c5343290bb>"
},
"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-76\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,
36,
37,
504,
505,
507,
508,
722,
723,
725,
726,
1392,
1393,
1395,
1396,
1558,
1559
],
"line_end_idx": [
36,
37,
504,
505,
507,
508,
722,
723,
725,
726,
1392,
1393,
1395,
1396,
1558,
1559,
1578
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1578,
"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.10389609634876251,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.003246749984100461,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.22077922523021698,
"rps_doc_frac_unique_words": 0.3849056661128998,
"rps_doc_mean_word_length": 4.950943470001221,
"rps_doc_num_sentences": 13,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.212738513946533,
"rps_doc_word_count": 265,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.035060979425907135,
"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.05030487850308418,
"rps_doc_frac_chars_top_3gram": 0.03658536821603775,
"rps_doc_frac_chars_top_4gram": 0.0259146299213171,
"rps_doc_books_importance": -183.62832641601562,
"rps_doc_books_importance_length_correction": -170.48345947265625,
"rps_doc_openwebtext_importance": -92.12930297851562,
"rps_doc_openwebtext_importance_length_correction": -92.12930297851562,
"rps_doc_wikipedia_importance": -53.51487731933594,
"rps_doc_wikipedia_importance_length_correction": -39.69520950317383
},
"fasttext": {
"dclm": 0.8521595597267151,
"english": 0.00009033000242197886,
"fineweb_edu_approx": 1.0438976287841797,
"eai_general_math": 0.00005602999954135157,
"eai_open_web_math": 0.8764074444770813,
"eai_web_code": 0.5522653460502625
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "513.24",
"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": "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": "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
|
-5,134,615,330,857,379,000
|
What is a Personal VPN Service and Why Do I Need One?
VPNs aren't just for rich corporate-types anymore
Senior woman smiles while using laptop outside sitting on patio furniture
mother image/Digital Vision/Getty Images
When most of us think of Virtual Private Networks (VPNs), we think of large corporations using them to provide their employees secure remote access to their corporate network and its resources. Well folks, VPNs aren't just for big business users anymore. Home users can also take advantage of the great security features and other bonus features provided by VPNs.
Why would you want to use a Personal VPN service?
A personal VPN service can create a huge roadblock for hackers trying to access your computer. This roadblock is basically a wall of strong encryption that protects all the network traffic entering or leaving your computer. This thwarts a hacker's ability to perform network eavesdropping and man-in-the-middle type attacks.
Having a personal VPN service also has several other benefits associated with it:
1. Anonymous Browsing: One of the coolest features of a personal VPN service is anonymous browsing. Once you have a VPN, you use intermediate VPN servers to connect to the internet. While using a VPN, the websites you visit can't see your true IP address. They can only see the IP address of the VPN proxy server that you are connected to. Most VPN services allow you to switch this IP address multiple times per month and many will switch it for you automatically every so often.
1. This doesn't give you a free pass to commit crimes or visit illegal sites as digital forensics type folks could still track you down and potentially subpoena ISP and VPN service provider records to see your actions.
2. Access your home country's network as if you were in the country: If you travel abroad a lot then you know that browsing sites that are located in your home country can be difficult because some countries filter Internet traffic based on the geographical location of the IP address you are using.
1. Some sites are blocked entirely. Music and video sites may be blocked due to country-specific license agreements. VPN use of an IP from your home country may possibly allow you to access content as if you were actually in your home country. This may not be permitted depending on the content providers policies.
1. Encrypted VPN connection prevents eavesdropping: Have you ever been at a coffee shop and saw a creepy looking guy with a laptop? He could be using special software to eavesdrop on anyone in the area who is using the wide-open in-store Wi-Fi. Since most hotspots do not use wireless encryption it's easy for him to jack your connection and see what you are up to.
1. Most VPN services allow you to encrypt your traffic when traveling with your mobile devices so that everything you do is encrypted and private, even when you're on an open public Wi-Fi hotspot.
How do you obtain and setup a VPN service?
• Choose a service provider: There are tons of VPN service providers out there. Some of the more well-known ones include: StrongVPN, OverPlay, and WiTopia to name a few. Prices of services can vary widely and range from about $5 to $20 or more per month. Check out user reviews to see the pros and cons of each before selecting one. Some key factors to consider, are speed, availability of bandwidth, VPN server locations, etc.
• Install and configure the service provider's VPN clientYour service provider may have client software that you install on your computer in order to use their VPN service. They may also provide you with configuration details on how to setup VPN on mobile devices (if the provider supports this). Some providers will even allow you to install their VPN service directly on your VPN-capable wireless router. Installation at the router level is probably one of the best solutions for home use because the router performs all the encryption and decryption which frees up computer resources for other tasks. Another benefit of VPN service installed at the router is that all your devices won't have to be specially configured to use the VPN. They won't even know that they are running through a VPN
The main downside of using a VPN is the delay associated with the encryption / decryption process. Websites might not be as lightning fast to load up as they were before you added the VPN service. It's up to you whether the delay is acceptable or not. Most VPN services offer free trials so you can try before you buy.
|
{
"url": "https://www.lifewire.com/what-is-a-personal-vpn-service-2487492",
"source_domain": "www.lifewire.com",
"snapshot_id": "crawl=CC-MAIN-2019-09",
"warc_metadata": {
"Content-Length": "116320",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:CI7LW2MKVSVROBSTVAVRYFUIXNZRIOHW",
"WARC-Concurrent-To": "<urn:uuid:f0a8ad69-556a-41c6-9e7d-0eeb2aee2e20>",
"WARC-Date": "2019-02-19T20:52:23Z",
"WARC-IP-Address": "151.101.250.114",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:LD2JLCA3A3X5CNCRGJC5WJ7AKPAHV4OY",
"WARC-Record-ID": "<urn:uuid:cd83239b-0b43-4afc-a03b-2e627c929f74>",
"WARC-Target-URI": "https://www.lifewire.com/what-is-a-personal-vpn-service-2487492",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:25b95419-5407-471a-950a-f283c16216f0>"
},
"warc_info": "isPartOf: CC-MAIN-2019-09\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-137-170-67.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,
54,
55,
105,
106,
180,
221,
222,
586,
587,
637,
638,
963,
964,
1046,
1047,
1530,
1753,
2055,
2374,
2742,
2943,
2944,
2987,
2988,
3418,
4216,
4217
],
"line_end_idx": [
54,
55,
105,
106,
180,
221,
222,
586,
587,
637,
638,
963,
964,
1046,
1047,
1530,
1753,
2055,
2374,
2742,
2943,
2944,
2987,
2988,
3418,
4216,
4217,
4539
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4539,
"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.4483146071434021,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.040449440479278564,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.11460673809051514,
"rps_doc_frac_unique_words": 0.43078914284706116,
"rps_doc_mean_word_length": 4.705045223236084,
"rps_doc_num_sentences": 44,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.253424167633057,
"rps_doc_word_count": 773,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.01374758966267109,
"rps_doc_frac_chars_dupe_6grams": 0.01374758966267109,
"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.03299422934651375,
"rps_doc_frac_chars_top_3gram": 0.016497109085321426,
"rps_doc_frac_chars_top_4gram": 0.02612042985856533,
"rps_doc_books_importance": -417.5621643066406,
"rps_doc_books_importance_length_correction": -417.5621643066406,
"rps_doc_openwebtext_importance": -192.62051391601562,
"rps_doc_openwebtext_importance_length_correction": -192.62051391601562,
"rps_doc_wikipedia_importance": -124.16131591796875,
"rps_doc_wikipedia_importance_length_correction": -124.16131591796875
},
"fasttext": {
"dclm": 0.23113059997558594,
"english": 0.9555734992027283,
"fineweb_edu_approx": 1.8994596004486084,
"eai_general_math": 0.026232419535517693,
"eai_open_web_math": 0.04357070103287697,
"eai_web_code": 0.006355519872158766
}
}
|
{
"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": "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": "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
|
1,853,272,053,163,152,400
|
Help centre
Submit a ticket Log in
Delivering Remote Sessions using Microsoft Teams & OneFile
We recently surveyed thousands of OneFile users to understand which tools they were using to tackle the challenge of continuing to deliver training and learning sessions during COVID19. The clear favourite was Microsoft Teams, which was selected by just under 50% of all voters.
Whilst we look into the future integration options with Microsoft Teams, this topic will explain how you can already use Microsoft Teams alongside OneFile to deliver great remote teaching and learning sessions. All you need is an Office 365 account where Micosoft Teams is included within your package... oh, and obviously you'll also need a OneFile account!
STEP 1 - SCHEDULE YOUR MEETING (OUTLOOK)
Firstly, you'll want to schedule a meeting for the date and time of your choice. Instead of doing this directly in teams, we're going to suggest you do this in Outlook (web or app), as it gives you the option to generate a link to the meeting without inviting anyone.
Set the Date, Time, Title and add a description of the session.
STEP 2 - SET THE MEETING TO HAPPEN VIA TEAMS
Outlook Web:
Make sure you select the option to Add online meeting and select Teams meeting.
Outlook Desktop App:
Make sure you click the Teams Meeting button.
STEP 3 - COPY THE LINK TO THE MEETING
Right click the Join Microsoft Teams Meeting link and select the Copy Hyperlink option.
STEP 4 (OPTION A) - SEND THE INVITE AS AN ACTIVITY TASK ON A PLAN
Here's where it gets clever - you can create a Plan for a learner and attach the link to the teams meeting as a learning resource!
1. Open the learner's portfolio
2. Create a plan
3. Add a task
4. Click the Activity tab
5. Type instructions to the learner (Tip - Include the start date/time and duration)
6. Click Attach
7. Click Create Link
8. Paste the link and click Create
Now sign the plan to send it to the learner. Remember, the task will appear in the learner's task box on the start date of the task as long as they sign the plan. The benefit to this approach is that the learner will have a task waiting for them to write a reflective jorunal about the session.
Hint - You can set up a plan template to send this to mutliple learners
STEP 4 (OPTION B) - SEND THE INVITE AS A TASK VIA A MESSAGE
If you just want to share this without creating a plan and pre-populating an activity task, you can utilise the Messages feature.
1. Click Messages in the top banner, next to your name
2. Click (+) to create a new message
3. Click To: and use the + icon to add learners (or even other assessors/tutors) into the message
4. Click Done
5. Add a subject and type a message (Tip - Include the start date/time and duration in the subject)
6. Click Create as a task and set the task due date
7. Click Select Attachment(s)
8. Click Create Link
9. Paste the link and click Create
STEP 5 - START YOUR TEAMS MEETING AND WAIT FOR YOUR LEARNERS TO JOIN
Regardless of which option you picked at step 4, your learners should have a task waiting for them when it's time to join the remote session.
They simply need to open the relevant task and click the link to join the Teams Meeting.
Let us know what you think below.
• Hi,
this is fantastic,
The only comment I have is to include the time/duration of the session in the subject section of the message as the task only contains the date.
Love it!!!
C
• Fantstic
Login to post a comment
|
{
"url": "https://support.onefile.co.uk/support/discussions/topics/76000011290",
"source_domain": "support.onefile.co.uk",
"snapshot_id": "CC-MAIN-2024-10",
"warc_metadata": {
"Content-Length": "73141",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4BGMO75GFMLPGXEUY7OC4OBJOEMNPQ6N",
"WARC-Concurrent-To": "<urn:uuid:f5c6796a-7205-4682-bff9-44cbf8e2d59e>",
"WARC-Date": "2024-03-04T07:41:15Z",
"WARC-IP-Address": "172.64.146.84",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:TAADINW3WFRXBFB2POJHNNQL55IAGTWS",
"WARC-Record-ID": "<urn:uuid:c533bf7d-7f2b-4e9e-837b-85458a04938b>",
"WARC-Target-URI": "https://support.onefile.co.uk/support/discussions/topics/76000011290",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:685170dc-abaf-4232-b799-b2237d2465c0>"
},
"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-144\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,
12,
13,
36,
37,
96,
97,
376,
377,
378,
737,
738,
739,
740,
741,
782,
783,
784,
1052,
1053,
1054,
1118,
1119,
1120,
1121,
1167,
1168,
1169,
1182,
1183,
1263,
1264,
1265,
1287,
1288,
1334,
1335,
1336,
1337,
1375,
1376,
1377,
1465,
1466,
1467,
1468,
1469,
1535,
1536,
1537,
1668,
1669,
1670,
1704,
1723,
1739,
1767,
1855,
1873,
1896,
1933,
1934,
1935,
2230,
2231,
2232,
2304,
2305,
2306,
2307,
2367,
2368,
2369,
2499,
2500,
2501,
2558,
2597,
2697,
2713,
2815,
2869,
2901,
2924,
2961,
2962,
2963,
2964,
2965,
3034,
3035,
3036,
3178,
3179,
3180,
3269,
3270,
3271,
3272,
3306,
3307,
3315,
3316,
3340,
3341,
3490,
3491,
3506,
3507,
3513,
3514,
3527,
3528,
3529
],
"line_end_idx": [
12,
13,
36,
37,
96,
97,
376,
377,
378,
737,
738,
739,
740,
741,
782,
783,
784,
1052,
1053,
1054,
1118,
1119,
1120,
1121,
1167,
1168,
1169,
1182,
1183,
1263,
1264,
1265,
1287,
1288,
1334,
1335,
1336,
1337,
1375,
1376,
1377,
1465,
1466,
1467,
1468,
1469,
1535,
1536,
1537,
1668,
1669,
1670,
1704,
1723,
1739,
1767,
1855,
1873,
1896,
1933,
1934,
1935,
2230,
2231,
2232,
2304,
2305,
2306,
2307,
2367,
2368,
2369,
2499,
2500,
2501,
2558,
2597,
2697,
2713,
2815,
2869,
2901,
2924,
2961,
2962,
2963,
2964,
2965,
3034,
3035,
3036,
3178,
3179,
3180,
3269,
3270,
3271,
3272,
3306,
3307,
3315,
3316,
3340,
3341,
3490,
3491,
3506,
3507,
3513,
3514,
3527,
3528,
3529,
3552
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3552,
"ccnet_original_nlines": 113,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.35528120398521423,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.08230452984571457,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1700960248708725,
"rps_doc_frac_unique_words": 0.37419354915618896,
"rps_doc_mean_word_length": 4.345161437988281,
"rps_doc_num_sentences": 39,
"rps_doc_symbol_to_word_ratio": 0.0013717400142922997,
"rps_doc_unigram_entropy": 4.811037063598633,
"rps_doc_word_count": 620,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.06384558230638504,
"rps_doc_frac_chars_dupe_6grams": 0.06384558230638504,
"rps_doc_frac_chars_dupe_7grams": 0.027468450367450714,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.02672605961561203,
"rps_doc_frac_chars_top_3gram": 0.010022269561886787,
"rps_doc_frac_chars_top_4gram": 0.011878250166773796,
"rps_doc_books_importance": -352.3745422363281,
"rps_doc_books_importance_length_correction": -352.3745422363281,
"rps_doc_openwebtext_importance": -214.7517852783203,
"rps_doc_openwebtext_importance_length_correction": -214.7517852783203,
"rps_doc_wikipedia_importance": -145.03114318847656,
"rps_doc_wikipedia_importance_length_correction": -145.03114318847656
},
"fasttext": {
"dclm": 0.21563416719436646,
"english": 0.8871780633926392,
"fineweb_edu_approx": 1.2408589124679565,
"eai_general_math": 0.08608275651931763,
"eai_open_web_math": 0.13602083921432495,
"eai_web_code": 0.06408178806304932
}
}
|
{
"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": "371.3922",
"labels": {
"level_1": "Social sciences",
"level_2": "Education",
"level_3": "Teachers, Teaching, and School management and organization"
}
}
},
"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": "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
|
-2,584,015,358,446,490,600
|
Drivers.Tips
Lenovo Thinkpad Sl510 Drivers
Directions in order to download Lenovo Thinkpad Sl510 drivers from here so you may update older or missing device drivers and make your device act accordingly. A driver is just a tiny file that are composed of coded instructions about the hardware device so that the processor can process it so that you can use the device that the driver file corresponds to. Without legitimate drivers there is no way for the system to make use of the hardware device. The hardware is useless and will not properly communicate with your computer system. You will have to have precise driver files downloaded and actually installed on your hard drive so you can use this piece of hardware.
All devices need to have the proper drivers installed within the operating system in order for them to work. These devices can be a video card, disk drive, camera or anything else that can be connected to the pc in some form or another.
• BRAND: Lenovo
• MODEL: Thinkpad Sl510
• SYSTEM TYPE: Personal Computer
• OS: Windows XP, Vista, 7, 8, 10
It is because each device is different from one another, each small driver file must be different from one another, too. It is because of this that it may be difficult to search and locate the right Lenovo Thinkpad Sl510 drivers. For instance, each Gigabyte motherboard hardware components has a particular driver made just for it. That comes out to so very many driver files to wade through in order to find the right one simply for that particular brand of hardware!
Being able to locate the proper Thinkpad Sl510 driver can feel like the ultimate challenge in life. A few tips so that you may locate a driver easier.
1. The name of the manufacturer (if it is built-in to the motherboard figure out the brand of the computer itself and use that brand name)
2. Next you will want to know the model of the device in question in order to download the correct driver.
3. The version of Windows. (in your Windows Start Menu, right-click on "My Computer" or aka "Computer" and left-click on "Properties". An information panel about your PC should now be open)
4. Are you running a 64-bit operating system or just a 32-bit version of Windows? (if it is a 64-bit system then it will show up in the Window that opens from right-clicking on "My Computer" or aka "Computer" and then left-clicking on "Properties". If it doesn't state that it's 32-bit or 64-bit then you can assume it's 32-bit.)
Be sure you find out manufacturer and model number of the device and OS type . Once you have accurate info about the hardware, you should look online for your specific Lenovo Thinkpad Sl510 drivers so that you can download and then install them correctly onto Windows.
Some of the recent versions of Microsoft Windows (Windows 7, 8, 8.1, and Windows 10) are capable of doing most of the work for you and can install the drivers itself. You may notice a time in that a computer user may need to get on the Internet and find the Thinkpad Sl510 driver due to the fact that Microsoft Windows was unable to automatically install it. Which is the most likely reason why you searched the Internet to come here!
A good company will list drivers of their hardware products online so you are able to download them at will. Many but not all of the brand's sites are optimized to show up in search results and navigate. A few companies do not take time to think about a normal computer user and the possible heart attack that may be associated with trying to manually install Lenovo Thinkpad Sl510 drivers on a computer. A lot of regular computer users find it very difficult figuring out the exact driver they should be looking for and trying to navigate a poorly constructed website can be extremely maddening.
Be mindful if you are downloading Thinkpad Sl510 drivers and software from random unknown websites. In order to lower your risk for malware, it would be best to only download drivers from the device maker's site if you can. Malware can be contained within a lot of different unsuspected files. Getting and then installing a file that you think is a Thinkpad Sl510 driver may be the end of your Windows installation if the driver file ends up being a virus. Even the greatest anti-virus software can kill ALL viruses on the Internet. This is why you should always download drivers from the manufacturer's own database on their website. Their websites are more trusted and more reliable than anyone else's.
After you located and received the real driver from online for the device attached to your computer system, you can begin to install the file. You might need to uncompress the driver especially if it ends with a .zip or .rar. After you have uncompressed the file you should run the program to install the driver. Unfortunately, if the driver fails to install properly you must install the Lenovo Thinkpad Sl510 driver manually.
Instructions for installing Lenovo Thinkpad Sl510 drivers manually:
1. On the Windows desktop, Right-click on "My Computer" or "Computer". Left-click on "Manage".
2. After the window opens up, left-click on "Device Manager". You should now be able to see all the devices that are connected to your computer system.
3. Double-click on any yellow exclamation points that you see. Another box will open up.
4. Left-click on the tab labeled "Driver".
5. Click on "Update Driver".
6. If asked to browse for the location of the driver, point the system to the Lenovo Thinkpad Sl510 driver you have already downloaded.
7. After completion, rebooting the PC may be necessary for any changes to take effect.
Download your Lenovo Thinkpad Sl510 driver using the link (or links) below.
Download Lenovo Thinkpad Sl510 Drivers
We make every effort to make sure every link is working as it should.
|
{
"url": "http://www.drivers.tips/Lenovo/Thinkpad_Sl510/",
"source_domain": "www.drivers.tips",
"snapshot_id": "crawl=CC-MAIN-2017-30",
"warc_metadata": {
"Content-Length": "9206",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:DEQQNLY663C2RBZYR6W5MAQ6B453ULVX",
"WARC-Concurrent-To": "<urn:uuid:745a98d2-a66b-4b60-9f88-07fc301a73b3>",
"WARC-Date": "2017-07-26T18:37:18Z",
"WARC-IP-Address": "199.193.6.98",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:AJO3VYT4HUN7TP2VKYAU5HSGM2PREJDV",
"WARC-Record-ID": "<urn:uuid:5512c0e9-241b-4ebe-94c5-2c45a03e4584>",
"WARC-Target-URI": "http://www.drivers.tips/Lenovo/Thinkpad_Sl510/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c5c66c9c-c5da-478c-bdd1-2de59ba43566>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-73-156-156.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-30\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for July 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,
13,
14,
44,
45,
719,
956,
974,
1000,
1035,
1071,
1540,
1691,
1832,
1941,
2133,
2465,
2734,
3169,
3766,
4471,
4899,
4967,
5064,
5218,
5309,
5354,
5385,
5523,
5612,
5688,
5727
],
"line_end_idx": [
13,
14,
44,
45,
719,
956,
974,
1000,
1035,
1071,
1540,
1691,
1832,
1941,
2133,
2465,
2734,
3169,
3766,
4471,
4899,
4967,
5064,
5218,
5309,
5354,
5385,
5523,
5612,
5688,
5727,
5796
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5796,
"ccnet_original_nlines": 31,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.447098970413208,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.012798629701137543,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.14590443670749664,
"rps_doc_frac_unique_words": 0.337649405002594,
"rps_doc_mean_word_length": 4.591633319854736,
"rps_doc_num_sentences": 66,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.107600688934326,
"rps_doc_word_count": 1004,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.04642082005739212,
"rps_doc_frac_chars_dupe_6grams": 0.012147510424256325,
"rps_doc_frac_chars_dupe_7grams": 0.012147510424256325,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.04229934886097908,
"rps_doc_frac_chars_top_3gram": 0.041214749217033386,
"rps_doc_frac_chars_top_4gram": 0.039479389786720276,
"rps_doc_books_importance": -338.8895263671875,
"rps_doc_books_importance_length_correction": -338.8895263671875,
"rps_doc_openwebtext_importance": -259.61614990234375,
"rps_doc_openwebtext_importance_length_correction": -259.61614990234375,
"rps_doc_wikipedia_importance": -204.85800170898438,
"rps_doc_wikipedia_importance_length_correction": -204.85800170898438
},
"fasttext": {
"dclm": 0.05211162939667702,
"english": 0.9347745180130005,
"fineweb_edu_approx": 2.0191099643707275,
"eai_general_math": 0.24969696998596191,
"eai_open_web_math": 0.20076417922973633,
"eai_web_code": 0.11496282368898392
}
}
|
{
"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": "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": "2",
"label": "Click Here References"
}
},
"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
|
-3,677,091,941,930,980,000
|
RPHud, as simple hud/gui system
Hello,
the purpose of this project was to get a small, fast, easy to use hud system for JME3. This system is not ment to replace Nifty since it will probably never incorportate that amout of features.
The system is targeting programmers, since the only way to generate them is currently trought code.
The whole system is ‘percentage based’, so it will always adjut automatically to the selected resolution. Additionally the system is build so that you can register 4 different listeners on each HudObject, and for the simplicity they are automatically called on the render thread.
Here is a short video showing a simple mouseover effect, simple buttons, and toggleButtons
http://www.youtube.com/watch?v=8inME7x9KHU
The usage is quite simple:
Load the HudManager and attach it
[java]
hudManager = new RPHudManager(this);
this.stateManager.attach(hudManager);
[/java]
Create a Sceen:
[java]
RPHudScreen screen1 = new RPHudScreen("Screen1", this.cam);
[/java]
Now you can add content to the screen, a simple colored background would be:
[java]
RPHudBackground rpHudBackground = new RPHudBackground("BG1", new Vector2f(0.25f, 0.25f), new Vector2f(0.5f, 0.5f), material);
screen1.addChildComponent(rpHudBackground);
[/java]
Note the two Vector2f's. The fist one is the relative position to the parent component, while the second one is the relative size. (Position is starting from bottom left), according to this the above code creates a colored quad in the center of the screen with size x*0.5, y*0.5)
Once done with the layout the call of
[java]
screen1.doLayout(0);
[/java]
Calculated the absolute layout of each component. The 0 is the starting depth, each subcompnent has depth+1 of its parent component by default. It is also possible to set a depthmodifier for each component.
If you want to show the screen simply activate it with following command:
[java]
hudManager.activateScreen(screen1);
[/java]
At last, it is easily possible to register actions for the hudsystem
[java]
hudManager.addMouseInputAction(MouseInput.BUTTON_LEFT, "ButtonLeft");
[/java]
This is just for a brief explanation.
If there is interest in such a system i will make a plugin out of it and contribute it.
Also if it get's contributed what default features should it have?
Planned are sliders and tab's-
2 Likes
To show further the easiness of the system, i will show you some default components.
This for example is the simple background:
[java]
public class RPHudBackground extends RPHudComponent implements RPHudLayoutListener{
Geometry background;
Material material;
public RPHudBackground(String name, Vector2f positionRelative, Vector2f sizeRelative,Material material) {
super(name, positionRelative, sizeRelative);
this.material = material.clone();
this.registerLayoutListener(this);
background=new Geometry(name+":background",new Quad(1,1));
background.setMaterial(this.material);
this.attachChild(background);
}
public void onLayoutChange(int depth) {
this.background.setLocalScale(this.sizeAbsolute.x, this.sizeAbsolute.y, 0);
}
public Material getMaterial() {
return material;
}
}
[/java]
And for making the pulsing mouseover effect only this extension is needed:
[java]
public class RPHudPulsingBackground extends RPHudBackground implements RPHudMouseInOutListener,RPHudUpdateListener{
ColorRGBA finalColor;
ColorRGBA color1;
ColorRGBA color2;
float value;
float speedModifier=1f;
boolean mouseOver;
public RPHudPulsingBackground(String name, Vector2f positionRelative, Vector2f sizeRelative, Material material,ColorRGBA color1, ColorRGBA color2) {
super(name, positionRelative, sizeRelative, material);
this.registerUpdateListener(this);
this.registerMouseInOutListener(this);
this.color1 = color1;
this.color2 = color2;
finalColor=new ColorRGBA();
}
public void onUpdate(float tpf, Vector2f mousePosition) {
if(this.mouseOver){
this.value+=tpfspeedModifier;
if(this.value<0){
this.speedModifier
=-1;
this.value+=tpfspeedModifier;
}
if(this.value>1){
this.speedModifier
=-1;
this.value+=tpfspeedModifier;
}
}else{
if(this.value>0){
if(this.speedModifier>0){
this.speedModifier
=-1;
}
this.value+=tpf*speedModifier;
}
}
finalColor.interpolate(color1, color2, value);
this.material.setColor("Color", finalColor);
}
public void onMouseOverChange(boolean isMouseOver) {
this.mouseOver=isMouseOver;
}
}
[/java]
This example also shows the usage of the Listeners, note, you can register more then one listener for each type…
hehe its really simple, true.
i made similar system, but much more extended. it can even read XML files to parse view like in nifty.
maybe later i could “separate” it from my other projects libs and share.
The simplicity is the key, sometimes i simple want a button to test something, sure, i could setup nifty or whatever, but it is easier to write 4 lines and then i don’t have to care about threads or whatever and i can start using that button…
I use it very often for debugging / adjusting settings at runtime
yes, true.
that is why i said that “i have similar system”.
no need to configure, can make hud via XML or code. also Event managing like mouse over/out/click/etc and other events.
but i use it for a GUI. :slight_smile:
For a full hud system my version lacks of some basic ability’s.
For example a freely scrollable area is not possible, i can only draw, or not draw something but not drawing only the half. Also if a component want’s to draw outside of a parent, it does.
Drag&Drop is possible, but it already requires a spezific layout to work nicely.
And so on…
Nice.
Did you consider batching the elements?
@nehon said:
Nice.
Did you consider batching the elements?
Sure, it is possible depending on the material/material's used..
Definitely sounds like a handy plugin to me.
Yes, with low work you can setup some nice hud features, specially if your goal is to get something small done and running in low time, pretty neat.
|
{
"url": "https://hub.jmonkeyengine.org/t/rphud-as-simple-hud-gui-system/24014",
"source_domain": "hub.jmonkeyengine.org",
"snapshot_id": "CC-MAIN-2023-23",
"warc_metadata": {
"Content-Length": "39197",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:3L4OOMQG5MUBGS6F7NGJ4VG3AVK4DHG4",
"WARC-Concurrent-To": "<urn:uuid:b3553058-bfb6-4675-a720-21b39968439d>",
"WARC-Date": "2023-06-10T18:49:39Z",
"WARC-IP-Address": "104.21.87.39",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:6CXRZCW7PP2OJSNLHDGHIAAGUB7GDQ5G",
"WARC-Record-ID": "<urn:uuid:3b78b943-5409-44c6-9a3e-65e42f589b31>",
"WARC-Target-URI": "https://hub.jmonkeyengine.org/t/rphud-as-simple-hud-gui-system/24014",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e17c7b64-ea27-4c68-a695-09a3b514d934>"
},
"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-7\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,
33,
40,
41,
42,
43,
237,
238,
239,
240,
340,
341,
342,
343,
623,
624,
625,
626,
717,
718,
719,
720,
763,
764,
765,
766,
767,
794,
795,
829,
836,
873,
911,
919,
920,
936,
943,
1003,
1011,
1012,
1089,
1096,
1222,
1266,
1274,
1275,
1555,
1556,
1594,
1601,
1622,
1630,
1631,
1838,
1839,
1913,
1920,
1956,
1964,
1965,
2034,
2041,
2111,
2119,
2120,
2158,
2246,
2313,
2344,
2352,
2353,
2438,
2439,
2440,
2441,
2484,
2485,
2486,
2487,
2494,
2495,
2579,
2580,
2601,
2602,
2621,
2622,
2623,
2624,
2730,
2731,
2776,
2777,
2811,
2812,
2847,
2848,
2907,
2908,
2947,
2948,
2978,
2979,
2981,
2982,
2983,
2984,
3024,
3025,
3101,
3102,
3104,
3105,
3106,
3107,
3108,
3109,
3141,
3142,
3159,
3160,
3162,
3163,
3165,
3166,
3174,
3175,
3176,
3177,
3252,
3253,
3254,
3255,
3262,
3263,
3379,
3380,
3402,
3403,
3421,
3422,
3440,
3441,
3442,
3443,
3456,
3457,
3481,
3482,
3501,
3502,
3651,
3652,
3707,
3708,
3743,
3744,
3783,
3784,
3806,
3807,
3829,
3830,
3858,
3859,
3861,
3862,
3863,
3864,
3865,
3866,
3867,
3868,
3926,
3927,
3947,
3948,
3978,
3979,
3997,
3998,
4017,
4022,
4023,
4053,
4054,
4056,
4057,
4075,
4076,
4095,
4100,
4101,
4131,
4132,
4134,
4135,
4142,
4143,
4161,
4162,
4188,
4189,
4208,
4213,
4214,
4216,
4217,
4248,
4249,
4251,
4252,
4254,
4255,
4302,
4303,
4348,
4349,
4351,
4352,
4353,
4354,
4407,
4408,
4436,
4437,
4439,
4440,
4441,
4442,
4444,
4445,
4453,
4454,
4455,
4456,
4569,
4570,
4600,
4601,
4602,
4603,
4706,
4707,
4708,
4709,
4782,
4783,
5026,
5027,
5028,
5029,
5095,
5096,
5107,
5108,
5157,
5158,
5159,
5160,
5280,
5281,
5282,
5283,
5322,
5323,
5387,
5388,
5577,
5578,
5659,
5660,
5671,
5672,
5678,
5679,
5719,
5720,
5733,
5739,
5779,
5780,
5781,
5846,
5847,
5892,
5893
],
"line_end_idx": [
32,
33,
40,
41,
42,
43,
237,
238,
239,
240,
340,
341,
342,
343,
623,
624,
625,
626,
717,
718,
719,
720,
763,
764,
765,
766,
767,
794,
795,
829,
836,
873,
911,
919,
920,
936,
943,
1003,
1011,
1012,
1089,
1096,
1222,
1266,
1274,
1275,
1555,
1556,
1594,
1601,
1622,
1630,
1631,
1838,
1839,
1913,
1920,
1956,
1964,
1965,
2034,
2041,
2111,
2119,
2120,
2158,
2246,
2313,
2344,
2352,
2353,
2438,
2439,
2440,
2441,
2484,
2485,
2486,
2487,
2494,
2495,
2579,
2580,
2601,
2602,
2621,
2622,
2623,
2624,
2730,
2731,
2776,
2777,
2811,
2812,
2847,
2848,
2907,
2908,
2947,
2948,
2978,
2979,
2981,
2982,
2983,
2984,
3024,
3025,
3101,
3102,
3104,
3105,
3106,
3107,
3108,
3109,
3141,
3142,
3159,
3160,
3162,
3163,
3165,
3166,
3174,
3175,
3176,
3177,
3252,
3253,
3254,
3255,
3262,
3263,
3379,
3380,
3402,
3403,
3421,
3422,
3440,
3441,
3442,
3443,
3456,
3457,
3481,
3482,
3501,
3502,
3651,
3652,
3707,
3708,
3743,
3744,
3783,
3784,
3806,
3807,
3829,
3830,
3858,
3859,
3861,
3862,
3863,
3864,
3865,
3866,
3867,
3868,
3926,
3927,
3947,
3948,
3978,
3979,
3997,
3998,
4017,
4022,
4023,
4053,
4054,
4056,
4057,
4075,
4076,
4095,
4100,
4101,
4131,
4132,
4134,
4135,
4142,
4143,
4161,
4162,
4188,
4189,
4208,
4213,
4214,
4216,
4217,
4248,
4249,
4251,
4252,
4254,
4255,
4302,
4303,
4348,
4349,
4351,
4352,
4353,
4354,
4407,
4408,
4436,
4437,
4439,
4440,
4441,
4442,
4444,
4445,
4453,
4454,
4455,
4456,
4569,
4570,
4600,
4601,
4602,
4603,
4706,
4707,
4708,
4709,
4782,
4783,
5026,
5027,
5028,
5029,
5095,
5096,
5107,
5108,
5157,
5158,
5159,
5160,
5280,
5281,
5282,
5283,
5322,
5323,
5387,
5388,
5577,
5578,
5659,
5660,
5671,
5672,
5678,
5679,
5719,
5720,
5733,
5739,
5779,
5780,
5781,
5846,
5847,
5892,
5893,
6041
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6041,
"ccnet_original_nlines": 287,
"rps_doc_curly_bracket": 0.004634989891201258,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.33172690868377686,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.005622489843517542,
"rps_doc_frac_lines_end_with_ellipsis": 0.010416669771075249,
"rps_doc_frac_no_alph_words": 0.2987951934337616,
"rps_doc_frac_unique_words": 0.48071980476379395,
"rps_doc_mean_word_length": 6.016709327697754,
"rps_doc_num_sentences": 83,
"rps_doc_symbol_to_word_ratio": 0.0024096400011330843,
"rps_doc_unigram_entropy": 5.406756401062012,
"rps_doc_word_count": 778,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.0158085897564888,
"rps_doc_frac_chars_dupe_6grams": 0.0158085897564888,
"rps_doc_frac_chars_dupe_7grams": 0.0158085897564888,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.005340740084648132,
"rps_doc_frac_chars_top_3gram": 0.027558209374547005,
"rps_doc_frac_chars_top_4gram": 0.006836149841547012,
"rps_doc_books_importance": -478.587890625,
"rps_doc_books_importance_length_correction": -478.587890625,
"rps_doc_openwebtext_importance": -235.81405639648438,
"rps_doc_openwebtext_importance_length_correction": -235.81405639648438,
"rps_doc_wikipedia_importance": -292.4981689453125,
"rps_doc_wikipedia_importance_length_correction": -292.4981689453125
},
"fasttext": {
"dclm": 0.4097638726234436,
"english": 0.7528524994850159,
"fineweb_edu_approx": 2.2587363719940186,
"eai_general_math": 0.877824604511261,
"eai_open_web_math": 0.29839086532592773,
"eai_web_code": 0.8609573841094971
}
}
|
{
"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": "4",
"label": "Code/Software"
},
"secondary": {
"code": "5",
"label": "Social/Forum"
}
},
"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": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-6,512,605,885,155,704,000
|
opsi webservice with Tornado progress
Today has been quite pleasant as I've been able to make some important progress with the new webservice.
I've implemented parameter passing for RPC calls as done in opsiconfd. Now I can hook up an Python 2 JSONRPCBackend to the service running with Python 3 and everything works as expected. This means the core functionality we need from the webservice is working properly.
We still want the new webservice to replace the old one without clients having to alter their behaviour. Another step in this direction is the possibility to parse opsiconfd.conf and use the given settings. opsiconfd has some options for limiting access that haven't yet been implemented.
Prior to this I've made some changes in python-opsi that fixed authenticate through PAM which I sadly broke before. Along this way I learned that from the multiple Python PAM libraries you can find pam3 on PyPI does not have any releases. Bummer. The world of Python module appears as a jungle to me once you go away from PyPI and try to find the macthing package for your Linux distro. There are quite a few similar sounding packages but finding out what version is available with what name isn't a pleasant task.
However having the service this far means that it is time for me to create a proper OS package. Other dependencies of opsi-server have already been ported to Python 3 and are already packaged with the only missing package being the webservice. Keep your fingers crossed that all dependencies are now matching the ones downloaded from PyPI during development!
Introducing opsirc
For many opsi user opsi-admin provides the go-to tool for scripting and even regular work on their system. Usually this makes use of the -d argument in order to not get asked for a password. But what if you want to go through the webservice instead - you don't want to use -d.
One reason for this might be that you want to have logs about what happened. You still can configure opsi-admin to write logs to a location of your choice but you have to think about this every time.
One thing that probably bug you is that you want to go through the webservice but the requirement to type in a password could be an annoyance. The options you have is that you use --password but this means that the password may be visible in the process list. Various other means of passing the password to the prompt may help but this would also mean that you may have to edit a whole lot of scripts if you ever change the password.
For sure you could whip out your favourite programming language and create scripts to do all your tasks but this might end up as not being as flexible and sometimes even overkill if one simple call is all you need.
To make your - and our - live a little bit easier there is now the possibility of providing credentials in a specific file we call opsirc. This file may contain username, password and address in order to have an easy way to benefit from going through the webservice while scripting - or just making use of the webservice by default.
An example might look like this:
username = grace
password = sundown
address = https://opsi.casa.hanson:4447/rpc
Save the contents at ~/.opsi.org/opsirc and opsi-admin (4.1.1.30 or newer) will pick the information up and use it for an connection. You can now run an command like opsi-admin method backend_info without the need to enter a password.
The opsirc file is kept simple so that other tools have the possibility to make use of this aswell. None of the lines are mandatory. A minimum usable example would be only providing a password in the file. And it is possible to save the password in a separate file by using the key password file and the path to the file as value. This makes it possible to show the file to others without presenting your password in plain view.
I hope this makes everyones live a little bit easier!
Looking back to 2018
The new year is now a few days old and I'd like to take to opportunity to look back at what happened in my opsi world in 2018.
The year begun with getting opsi 4.1 ready for release. Most of the development work was already done but for a proper release you need some more. Documentation is one of the things. Not only did we need to change the documentation in some places, we also worked hard on making a reliable and easy to follow migration guide. The migration guide is quite large, covering many distributions and mentioning all kind of changes that could be done, but the things you need to do come done to a few steps.
The release has also led to writing some tools that are in use at our public repositories. Behind the scenes we have tools that help us making the release of new opsi packages an easier task by automatically collecting the corresponding files and knowing where the files need to be placed (localboot/netboot; linux, windows or both). Since a lot of the packages are runnable under opsi 4.0 and opsi 4.1 we wanted to have these packages available in both repositories. We solve this by having a tool watching the opsi 4.0 repository directories and once there is a new file this will be linked to the corresponding repository for opsi 4.1. This is accompied by another tool that watches all our repositories and alters the access rights of new files so that retrieving won't fail because of insufficent rights. This is one of the simpler and still nicer things I'd like to integrate into opsi in the future because it removes a potential error source when handling packages.
From my view the release of opsi 4.1 went nicely. Problems seemed to be rare and seemed to come mostly from diverging from the migration steps. The order was important this time because we changed the way we are tracking what migrations have been run. This will save us some headaches in the future since we know what migrations have been run and therefore what migrations are missing.
I enjoy that we are able to rely on systemd and Python 2.7 with opsi 4.1. This makes a lot of things easier for developing and maintaining things.
The release of opsi 4.1 happened shortly before the great opsiconf. The conference itself was a great joy to me. I got to see new and old faces and talk to many people - and I've talked to even more if time would have allowed it! One thing that I'd like to improve with the next conference is the diversity. I think this is something where we really could do better but I'm unsure of how to achieve it. I know that we have a very diverse user base and I'd love this to be represented a lot more at the next conference!
With release and conference behind me it was again time to look towards the future. One of the major points we started working to is the migration to Python 3. Since I've been constantly blogging about this topic I won't go into detail here. Being able to focus on this wouldn't have been possible if there weren't my co-workers giving the time and taking care of other tasks I'd normally do. I'm very thankful for this because this allowed for making good progress. Lately some more things have come up that I personally had to take care of and this has shown me even more how valuable the time has been.
Another big change was the overhaul of data collection for opsipxeconfd. It took us quite some time to get to this solution but I am happy how this turned out. The duration it took to get there is one thing not bringing a smile to my face but if you are stepping into a new terrain you won't always know what waits for you there.
In between all this there has been the occasional bugfix that lead to touching opi 4.0. This is where the migration from subversion to git really payed off. Maintaining multiple versions and bringing changes from one into the other has become mostly a no-brainer. Because we are already working on a new larger release for opsi this means that most repositories are having at least three different version branches at the same time. Before we went all in on git we tried some workflows and finally came up with our one which has been heavily inspired by git flow.
The winter of 2018 has seen some work on the monitoring extension I quite enjoyed because there was a constant stream of feedback and even though most changes were rather small I had the feeling that these changes made a rather large improvement.
And then things slowed down before the year came to an end. And so did the support span for opsi 4.0.
New things are waiting for us in 2019, new things will be coming in 2019. I am looking forward to this and hope you do aswell!
Quick tip: Easy weekly backups with systemd
Creating regular backups does not have to bee a cumbersome job but can be easily automated. Instead of using cron I have settled to use systemd for such tasks. In my eyes the benefit is that I can still see any job output after it has been run by using either systemctl status or journalctl without the need to configure any logging whatsoever. And I have easy access to things like execution time or exit code.
Read more…
First service endpoint running with Python 3
I am really happy with the progress we are making with supporting Python 3. Our internal build server already serves the first packages that are running on Python 3 only. There are still errors popping up where we need to port parts but this is what I expected earlier.
The previous weeks saw some feedback-based improvements to the opsi monitoring connector in opsi 4.1. Because I was already working in the codebase and it is comparably small I decided the first endpoint I want to port to Python 3 will be /monitoring.
Read more…
New appliance based on Ubuntu 18.04
For a very long time we have been providing a preconfigured opsi server (often referred as opsivm) in the form of a virtual machine, which can be integrated under various virtualisation systems including Virtualbox and VMWare. After the server has been started for the first time, a script is executed to setup the last configuration settings. These are, among other things name, domain, IP of the server, the standard gateway, the DNS server and also the passwords for the already created users. The opsi server is then ready for use and only needs to be filled up with the opsi standard packages.
We always try to keep the opsi server up to date, both in terms of the opsi version and the Linux distribution used. The latest version has been changed from being based on Ubuntu 16.04 to Ubuntu 18.04.
Network configuration
Since Ubuntu 18.04, netplan has been used instead of ifconfig as the default network configuration. After a first attempt to disable netplan and keep the configuration procedure using ifconfig as before, this attempt has been discarded because this solution would require installing additional programs as well as making more adjustments. So the decision was made to use the netplan configuration.
The configuration for netplan can be found in /etc/netplan/config.yaml:
network:
version: 2
renderer: networkd
ethernets:
enp3s0:
addresses:
- 10.10.10.2/24
gateway4: 10.10.10.1
nameservers:
search: [mydomain, otherdomain]
addresses: [10.10.10.1, 1.1.1.1]
By making adjustments to our start script we are able to use a template based on the default configuration. This template is patched with the values as retrieved during the first startup.
network:
version: 2
renderer: networkd
ethernets:
enp3s0:
addresses:
- @ip@/@cidrnetmask@
gateway4: @gateway@
nameservers:
search: [@domain@]
addresses: [@dns@]
A particular challenge was the network mask, which is required to be in format 255.255.255.0, but in config.yaml must be given as in CIDR notation including the network address as 10.10.10.1/24.
Once the template is filled the following call activates the network settings from config.yaml:
netplan apply
Deploying a root shell
Another change was the way we made the use of a terminal with root privileges available via a desktop icon.
Most of the tasks on an opsi server can be performed by a dedicated user called adminuser. If system administrator rights are necessary, there is a desktop call to open a shell with root rights. So far this has been done using the gksu tool which is considered obsolete and is therefore no longer supported in the latest versions of Debian and Ubuntu.
For this reason we now start our root shell with the following call:
lxterminal --title "root shell" --command "sudo -s"
Testing the new opsi-appliance
Are you curious? Download the latest version here and then follow the Getting Started.
Have fun
Making parts of opsi-package-updater re-usable
This weeks release of opsi-utils 4.1.1.26 consists mostly of internal changes. We sometimes do this to keep up with current developments but this time it is a little bit different. This change lead to shrinking the size of opsi-package-updater by a huge margin.
How did this come you might ask. Well, it all started a while ago when a customer got in contact through the support because he wanted to use some functionality from opsi-package-updater with his own script. Discussing the options it came clear that the best way to achieve this was to make sure that the functionality of opsi-package-updater becomes available for importing in another Python module. Luckily the customer was up for this route even though this would not be the fastest option but the one that provided the best long-term support for such an solution.
To achieve this we added the module OPSI.Util.Task.UpdatePackages to python-opsi. This now includes the majority of code that is opsi-package-updater. Besides becoming reusable we now also can provider proper unittests for the different components. Working on the module I have split some components up to achieve looser coupling. I'd like to refactor some internal workings of this in the future but right now my focus is on opsi supporting Python 3.
This brings us to the other changes that happend in opsi-utils. The small changes that have been made are to achieve better compatibility with Python 3. For most tools it will now be enough to change the shebang line to use Python 3 to work with python3-opsi. Some more work will have to be done there but we can already cross more things of our todo list.
opsi-package-updater: Failing on locked products
With an software as old as opsi it is sometimes inevitable to stumble over something and then be left scratching your head.
One of this cases I recently discovered in opsi-package-updater. Whenever an package is installed it is made in a way that ignores the lock of the product on the depot.
The lock is in place to avoid problems where multiple tools would (un)install the same product. This could result in problems which leave the system in an undefined state regarding the product installation - something that should be avoided!
With opsi-utils 4.1.1.24 we do not ignore the lock anymore. If a locked product is detected no installation will be made but we will abort with an error instead. This may lead to problems coming to the surface which may have been hidden before, especially when having a heavily automated setup, but we think not knowing about the problem is far worse. The problems probably have been there before but were usually not in sight.
If you run into such an problem now you should take a look at the logs and find out what is causing your problem. Once you figured this out and resolved it you can use opsi-package-manager --install --force /var/lib/opsi/repository/<packagefile>.opsi to make install the package in way that ignores the locked state of the product. If everything works you can run opsi-package-updater again to finish what was started.
Improved backup handling
Small things do make a difference. This weeks release brought some small changes to opsi-backup that should make the handling of opsi backups easier in day-to-day life.
The first change improved automatic detection of restorable data. There is no need anymore to pass what backends should be restored as the new mechanism will by default restore all backend data that is found in your backup file. This boils a restore for most cases down to opsi-backup restore <backupfile>.
The second change is that if any combination of options is given that would lead to not performing a restore the process will be aborted which is much easier to spot.
And the last change is that it is now possible to get a short listing to see what data (backendtype and if there is configuration data) is in a backup with the command opsi-backup list <filenames>
Go give it a try and send us some feedback! All you need is opsi-utils 4.1.1.22 or newer which can currently be found in the testing branch.
|
{
"url": "https://blog.opsi.org/",
"source_domain": "blog.opsi.org",
"snapshot_id": "crawl=CC-MAIN-2019-18",
"warc_metadata": {
"Content-Length": "33864",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XQCIQLZTTZ5PXACIR5UK2T54M4LNFB4S",
"WARC-Concurrent-To": "<urn:uuid:5ae1b6e5-f384-4633-9a12-0c47d636085f>",
"WARC-Date": "2019-04-19T01:16:07Z",
"WARC-IP-Address": "83.246.66.150",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:HMPAAOBXHVXDW64LYEMPE7VJQ7IIDKEX",
"WARC-Record-ID": "<urn:uuid:96690ff3-55ac-443c-9aed-6a4690be445a>",
"WARC-Target-URI": "https://blog.opsi.org/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ec63a266-11d3-46b1-bbc2-7c0ebb528e34>"
},
"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-157-215-35.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,
144,
145,
415,
416,
705,
706,
1221,
1222,
1581,
1582,
1601,
1602,
1879,
1880,
2080,
2081,
2515,
2516,
2731,
2732,
3065,
3066,
3099,
3100,
3117,
3136,
3180,
3181,
3416,
3417,
3846,
3847,
3901,
3902,
3923,
3924,
4051,
4052,
4552,
4553,
5527,
5528,
5914,
5915,
6062,
6063,
6582,
6583,
7189,
7190,
7520,
7521,
8085,
8086,
8333,
8334,
8436,
8437,
8564,
8565,
8609,
8610,
9022,
9023,
9034,
9035,
9080,
9081,
9351,
9352,
9604,
9605,
9616,
9617,
9653,
9654,
10253,
10254,
10457,
10458,
10480,
10481,
10879,
10880,
10952,
10953,
10962,
10975,
10996,
11009,
11021,
11038,
11062,
11089,
11108,
11150,
11193,
11194,
11382,
11383,
11392,
11405,
11426,
11439,
11451,
11468,
11497,
11523,
11542,
11571,
11600,
11601,
11796,
11797,
11893,
11894,
11908,
11909,
11932,
11933,
12041,
12042,
12394,
12395,
12464,
12465,
12517,
12518,
12549,
12550,
12637,
12638,
12647,
12648,
12695,
12696,
12958,
12959,
13527,
13528,
13980,
13981,
14338,
14339,
14388,
14389,
14513,
14514,
14683,
14684,
14926,
14927,
15355,
15356,
15775,
15776,
15801,
15802,
15971,
15972,
16279,
16280,
16447,
16448,
16645,
16646
],
"line_end_idx": [
38,
39,
144,
145,
415,
416,
705,
706,
1221,
1222,
1581,
1582,
1601,
1602,
1879,
1880,
2080,
2081,
2515,
2516,
2731,
2732,
3065,
3066,
3099,
3100,
3117,
3136,
3180,
3181,
3416,
3417,
3846,
3847,
3901,
3902,
3923,
3924,
4051,
4052,
4552,
4553,
5527,
5528,
5914,
5915,
6062,
6063,
6582,
6583,
7189,
7190,
7520,
7521,
8085,
8086,
8333,
8334,
8436,
8437,
8564,
8565,
8609,
8610,
9022,
9023,
9034,
9035,
9080,
9081,
9351,
9352,
9604,
9605,
9616,
9617,
9653,
9654,
10253,
10254,
10457,
10458,
10480,
10481,
10879,
10880,
10952,
10953,
10962,
10975,
10996,
11009,
11021,
11038,
11062,
11089,
11108,
11150,
11193,
11194,
11382,
11383,
11392,
11405,
11426,
11439,
11451,
11468,
11497,
11523,
11542,
11571,
11600,
11601,
11796,
11797,
11893,
11894,
11908,
11909,
11932,
11933,
12041,
12042,
12394,
12395,
12464,
12465,
12517,
12518,
12549,
12550,
12637,
12638,
12647,
12648,
12695,
12696,
12958,
12959,
13527,
13528,
13980,
13981,
14338,
14339,
14388,
14389,
14513,
14514,
14683,
14684,
14926,
14927,
15355,
15356,
15775,
15776,
15801,
15802,
15971,
15972,
16279,
16280,
16447,
16448,
16645,
16646,
16786
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 16786,
"ccnet_original_nlines": 168,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4781323969364166,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01388888992369175,
"rps_doc_frac_lines_end_with_ellipsis": 0.011834319680929184,
"rps_doc_frac_no_alph_words": 0.1391844004392624,
"rps_doc_frac_unique_words": 0.28735631704330444,
"rps_doc_mean_word_length": 4.6408915519714355,
"rps_doc_num_sentences": 198,
"rps_doc_symbol_to_word_ratio": 0.0005910199834033847,
"rps_doc_unigram_entropy": 5.7732062339782715,
"rps_doc_word_count": 2871,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.022365659475326538,
"rps_doc_frac_chars_dupe_6grams": 0.012909039855003357,
"rps_doc_frac_chars_dupe_7grams": 0.012909039855003357,
"rps_doc_frac_chars_dupe_8grams": 0.00825577974319458,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.004878410138189793,
"rps_doc_frac_chars_top_3gram": 0.002401679987087846,
"rps_doc_frac_chars_top_4gram": 0.002701889956369996,
"rps_doc_books_importance": -1259.20166015625,
"rps_doc_books_importance_length_correction": -1259.20166015625,
"rps_doc_openwebtext_importance": -894.0592041015625,
"rps_doc_openwebtext_importance_length_correction": -894.0592041015625,
"rps_doc_wikipedia_importance": -642.3416748046875,
"rps_doc_wikipedia_importance_length_correction": -642.3416748046875
},
"fasttext": {
"dclm": 0.05117928981781006,
"english": 0.9529460072517395,
"fineweb_edu_approx": 1.6299749612808228,
"eai_general_math": 0.6279734373092651,
"eai_open_web_math": 0.23080646991729736,
"eai_web_code": 0.5875100493431091
}
}
|
{
"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.076",
"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": "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": "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
|
5,711,574,893,509,564,000
|
Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
PerlMonks
Re: Perl auto completing forms
by davido (Archbishop)
on Sep 30, 2012 at 01:04 UTC ( #996443=note: print w/replies, xml ) Need Help??
in reply to Perl auto completing forms
Perl is huge. It's used in a lot of diverse places. Web scraping is huge. It's done all the time. Javascript is huge. It's ubiquitous in the context of the web. WWW::Mechanize doesn't directly handle Javascript. The number of people who have encountered this issue is also huge. It's a highly searchable topic that has been answered many times -- a FAQ (which might explain the beating you're taking in votes right now). And it's also why the POD for WWW::Mechanize has the following:
Please note that Mech does NOT support JavaScript, you need additional software for that. Please check "JavaScript" in WWW::Mechanize::FAQ for more.
In the WWW::Mechanize::FAQ you will find a section titled "JavaScript". There's a good explanation there on how it may be possible to simply provide the proper get/post requests instead of relying on JavaScript parsing to deal with the website. But it also has a subcategory, "Which modules work like Mechanize and have JavaScript support?". You'll find some good suggestions there on how to proceed.
Dave
Log In?
Username:
Password:
What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://996443]
help
Chatterbox?
and all is quiet...
How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (3)
As of 2017-09-24 02:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
Voting Booth?
During the recent solar eclipse, I:
Results (273 votes). Check out past polls.
Notices?
|
{
"url": "http://www.perlmonks.org/?node_id=996443",
"source_domain": "www.perlmonks.org",
"snapshot_id": "crawl=CC-MAIN-2017-39",
"warc_metadata": {
"Content-Length": "19403",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VV32SLS3J35CYPST4RVBA2WIMZ4EHTEK",
"WARC-Concurrent-To": "<urn:uuid:57c586e2-8d86-4925-bbdd-239e6142e448>",
"WARC-Date": "2017-09-24T02:49:09Z",
"WARC-IP-Address": "209.197.123.153",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:47SDHZFJ3LE5PHMCYUSK5MLHPKEVBUMS",
"WARC-Record-ID": "<urn:uuid:48383129-1fe9-4936-999b-95c8dfc2c950>",
"WARC-Target-URI": "http://www.perlmonks.org/?node_id=996443",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:81ba159f-a14c-46ae-8f14-4f494a2bdf31>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-231-19-134.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-39\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for September 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,
63,
86,
88,
100,
101,
132,
133,
156,
236,
237,
238,
277,
278,
763,
764,
913,
914,
1315,
1316,
1317,
1322,
1323,
1331,
1341,
1351,
1352,
1372,
1390,
1403,
1416,
1446,
1451,
1463,
1483,
1484,
1522,
1535,
1573,
1600,
1610,
1623,
1635,
1646,
1664,
1704,
1705,
1706,
1707,
1708,
1709,
1710,
1711,
1712,
1713,
1760,
1761
],
"line_end_idx": [
63,
86,
88,
100,
101,
132,
133,
156,
236,
237,
238,
277,
278,
763,
764,
913,
914,
1315,
1316,
1317,
1322,
1323,
1331,
1341,
1351,
1352,
1372,
1390,
1403,
1416,
1446,
1451,
1463,
1483,
1484,
1522,
1535,
1573,
1600,
1610,
1623,
1635,
1646,
1664,
1704,
1705,
1706,
1707,
1708,
1709,
1710,
1711,
1712,
1713,
1760,
1761,
1773
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1773,
"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.29123711585998535,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03865978866815567,
"rps_doc_frac_lines_end_with_ellipsis": 0.017543859779834747,
"rps_doc_frac_no_alph_words": 0.25515463948249817,
"rps_doc_frac_unique_words": 0.6546762585639954,
"rps_doc_mean_word_length": 4.84532356262207,
"rps_doc_num_sentences": 31,
"rps_doc_symbol_to_word_ratio": 0.005154639948159456,
"rps_doc_unigram_entropy": 4.969516754150391,
"rps_doc_word_count": 278,
"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.02078692987561226,
"rps_doc_frac_chars_top_3gram": 0.020044539123773575,
"rps_doc_frac_chars_top_4gram": 0.034149959683418274,
"rps_doc_books_importance": -182.78488159179688,
"rps_doc_books_importance_length_correction": -175.60292053222656,
"rps_doc_openwebtext_importance": -71.63341522216797,
"rps_doc_openwebtext_importance_length_correction": -71.63341522216797,
"rps_doc_wikipedia_importance": -58.30611801147461,
"rps_doc_wikipedia_importance_length_correction": -55.96705627441406
},
"fasttext": {
"dclm": 0.037964221090078354,
"english": 0.9177091717720032,
"fineweb_edu_approx": 1.197031021118164,
"eai_general_math": 0.0032215099781751633,
"eai_open_web_math": 0.23729151487350464,
"eai_web_code": 0.0000922699982766062
}
}
|
{
"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.136",
"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": "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": "-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,991,530,727,540,581,000
|
What Is Snap Spotlight (And How Do I Use It)
Snap announced its own answer to TikTok in November 2020, but they'd hinted at the addition of the feature for a while, and even added music functionality in August 2020. The social media brand hopes that users will start to share more funny, meme-y content instead of the vlog-style that Snap has encouraged over the life of the platform. Now, along with their location-based features that let users join the party no matter where it is in the world from the Snap Map, users can create vertical-video content built for virality.
Snap hopes to use Spotlight to highlight quality content from creative people, regardless of how many followers they have on the platform. This gives would-be influencers a less-crowded pool of competitors than they'll find on TikTok these days.
Still not sure what Snap Spotlight is? Want to know more about how to actually use it? Keep reading—we've got you covered.
What Is Snap Spotlight (And How Do I Use It):
What is Snap Spotlight?
Snap Spotlight is a new tab in the Snapchat app that shows short-form video content, or "Spotlight Snaps." The Snaps in the Spotlight section can be up to 60 seconds long. What you see when you use the Spotlight tab is based on Snapchat's algorithm which, like TikTok's, shows you what it thinks you'll want to see based on what you've watched previously and for how long.
Here are two huge differences between TikTok and Spotlight: Spotlight Snaps do not include a comment feature and profiles are private by default. That means creators can keep their profiles hidden while still sharing Spotlight Snaps. Given the attacks and vitriol that's been known to occur in TikTok comments, Snapchat influencers might find this feature very interesting.
The addition of short-form videos and a Spotlight tab on an app like Snap shows that TikTok has exposed a nerve in social media that everybody is now getting on. Instagram jumped on the short-form, viral video content train back in August 2020 with the launch of Instagram Reels and, instead of losing those creators to Instagram and TikTok, Snap answered with its own version of the function.
How to Use Snap Spotlight
Spotlight Snaps are easy to create and share. Just record your Snap as you normally would and choose "Spotlight" at the top of the "Send to" screen. That's literally it. Spotlight Snaps need to be vertical videos and must include sound. Horizontal images, still images, text-only, or blurry Snaps aren't going to show up in the Spotlight tab.
Create a Spotlight Snap
In case you need a step-by-step, here's how to create a Spotlight Snap:
1. Open up Snapchat
2. Press and hold the camera button (to switch between selfie mode and the rear-facing camera, just tap the toggle button or double-tap the screen)
3. Tap the lightning bolt to enable or disable flash
4. When you're done with your video, stop holding the camera button
You can also upload videos from the camera roll on your phone but the videos must:
• Be vertical
• Have an aspect ratio of at least 3:4
• Have a minimum horizontal resolution of 640px
• Fill the frame (no letterbox)
Send Your Spotlight Snap
To send a Snap to Spotlight
1. Create a Snap as indicated above
2. Tap the send icon at the bottom right of the screen to get to the send screen
3. Choose "Spotlight" at the top of the "send to" screen
4. Add hashtags to the "#AddTopic" section
5. Send your Snap
Snap wants to "see your best stuff," so don't just send anything and everything to Spotlight. To ensure that Spotlight is truly a mix of interesting content from several different people, Snapchat might even limit the number of Snaps users can submit to Spotlight during a certain timeframe. We're guessing that the drive for quality is going to go away and that Spotlight will eventually be more like TikTok's For You Page where the content is still based on what you typically watch on the platform but isn't exactly the highest of quality every single time.
Once you've submitted a Snap to Spotlight, you'll be able to check on the status of your Spotlight submission from your Profile. Just head over there and tap on a Snap you've submitted to see where it stands.
Submitted: Your Snap was submitted but isn't yet live.
Live: Your Snap has been shared on the Spotlight tab.
Beyond Creating and Sending Spotlight Snaps
Outside of creating and sending Spotlight Snaps, Snap users can also favorite, save, or delete Snaps from Spotlight. See something that violates Snap's terms of service (or basic human decency)? You can report it.
Favorite: Simply tap the heart icon to add favorites and see more content like it. Your favorites are only visible to you, so don't be shy.
Save or Delete: Tap the gear icon in your profile to open up your settings. From there, tap "Spotlight & Snap Map" to view the Snaps. Then, tap the download icon to save the Snap to your memories or tap the trash can icon to delete it. Since Snaps that are submitted to Spotlight are considered public content, your Snap might still show up off Snapchat if it's already been shared outside of the platform.
Report: If you find inappropriate content on Spotlight, Snapchat wants to know about it so they can keep the community safe. To report Spotlight content, press and hold the Spotlight post. Then, tap the flag icon or "Report Snap" and let Snapchat know what the problem is.
How Does Snapchat Decide What Spotlight Content to Feature?
So, how exactly does Snapchat decide what content they're going to feature on the Spotlight tab? The tab is largely built based on individual preference with Snapchat focused on "serving the right Snaps to the right person at the right time." The Snapchat algorithm also takes these factors into account when curating content:
• Watch time
• Likes
• Shares
• Bounce rate
Plus, before content shows up on the Spotlight tab, it gets reviewed by moderators who help make sure the content is appropriate and entertaining. Snapchat does take pains to emphasize entertainment content and states that the platform isn't a place for overly political or newsy content.
Spotlight Snap Guidelines
Snapchat's goal is to create a positive, fun, and safe experience for its users. to that end, there are several guidelines in place for those wishing to share content to Spotlight. In order to be eligible for the Spotlight tab, Snaps have to adhere to Snapchat's community guidelines, Spotlight guidelines, terms of service, and Spotlight terms. Plus, not everyone with Snapchat can submit to Spotlight. While Snapchat itself requires users to be aged 13+, in some markets, users must be 16+ (Germany, France, and Ireland). And, only Snapchatters with a public profile will be able to have their display name associated with their Spotlight Snaps.
Outside of the guidelines and terms of service, there are a few other tips and tricks that Snapchat offers so users have the best chance possible of hitting the Spotlight tab.
Entertain and Be Creative
While Snapchat explicitly states certain parameters for Spotlight Snaps (they must be vertical, must include sound, can't be blurry, can't be text-only), there are also many things that are left up to the creators:
• Include a #Topic on the send page so your Snaps are easier to find
• Make every second of your Snaps count with creative content
• Use the available creative tools like sounds, captions, GIFs, and Lenses to make your Snaps stand out from the rest
• Snaps can be up to 60 seconds long
• Spotlight supports videos from your camera roll but is partial to Snaps created with the Snapchat camera
• Stay away from duplicate content
Again, Snapchat might limit the number of Snaps you can send to Spotlight during a certain timeframe, so you'll want to make sure that the Snaps you're sending are your best work.
Post Only Original Content
Snapchat removes content that infringes on copyrights held by others, so make sure that your content is original and that you're using music from Snapchat's licensed Sounds library.
Be Safe
Spotlight submissions should be appropriate for a 13+ audience and shouldn't include things like:
• Gambling
• Tabacco
• Weapons
• Controlled substances
• Excessive alcohol consumption
• Underage drinking
Plus, you shouldn't try to deceive people about science, politics, money, health, or your own identity. If you do a really good celebrity impression, bring it, but don't actually claim to be them.
No Soliciting
As of this writing (March 2020), Snapchat has a no soliciting policy. This means users can't attempt to sell or solicit products or services and shouldn't submit sponsored or paid-for Snaps to Spotlight. It's also a no-no to use attachments or URLs on Spotlight Snaps.
Are you a brand interested in using Snapchat for promotion? Check out Snapchat for Business.
Where is Spotlight Available?
Spotlight isn't available everywhere. It's slowly rolling out to other countries and is currently only available in:
• Australia
• Canada
• Denmark
• France
• Germany
• Ireland
• New Zealand
• Norway
• Sweden
• United Kingdom
• United States
How to Become a Successful Spotlight Snapchatter
Here are some helpful tips you can use to make your content more appealing to the Spotlight powers that be and increase your chances of landing on the Spotlight tab.
Use Native Snapchat Creative Tools
Snapchat has tons of creative tools that you can use to jazz up your content on the platform. Just a quick look at the Spotlight feed will show you that the content making it on there uses these features, so the features probably give a little signal to the algorithm. Plus, the tools are really pretty powerful, so there's no reason not to use them—especially if it helps get your content featured.
Add Relevant Hashtags
You can add up to 100 hashtags on a Spotlight Snap. That's... a lot. And we don't recommend adding that many. However, the use of hashtags is important. Hashtags are a great way to let other Snapchatters find your content and know what it's about. Just make sure to keep them relevant to your content. If you load your content up with lots of unrelated hashtags, it's more likely to get rejected.
Let Your Creativity Shine
While you should absolutely take the time to add creative flourishes to the Snaps you're submitting to Spotlight, it's not necessary to produce them to death. In fact, highly-produced videos don't seem to perform well on the platform. It's much more important to produce creative content and then polish it with 1–3 Snapchat creative tools.
Give the Mods What They Want
If you think that getting on Spotlight involves "gaming the algorithm" instead of getting through content moderation, you might find yourself on the wrong side of the mods and left out of the Spotlight. Don't submit content using copyrighted footage, outside music, Boomerangs, TikTok logos, Instagram fonts, or Superzoom effects. Stick to creative tools that are native to the Snapchat platform and choose music from its Sounds library.
Stay the Course
Perhaps the best advice we can give you is to keep it up. Yes, Snapchat reserves the right to limit how often you can submit Snaps to Spotlight, but there doesn't seem to be any adverse effects to you if you regularly get limited. So, keep creating great content and keep submitting it.
A Note to Brands About Spotlight Snaps
Right now, Spotlight is a creators-only option—no brands allowed. Of course, that doesn't mean that brands shouldn't be paying attention to Spotlight. As the function becomes more popular, it's not a stretch to think that Snapchat will start offering advertising opportunities as TikTok does.
What's With the $1 Million a Day Payments Thing?
You probably heard that Snap was paying creators $1 million per day to get them to use Spotlight. That's only partially true. Yes, Snap offered up $1 million each day that would be divided among the most popular creators on the app through the end of 2020. No, it wasn't paying each creator a cool mill to create content.
The goal of the program was to generate buzz and interest around the Spotlight feature. And, hey, it seems it worked.
Spotlight Snap Examples
Let's wrap up with a few of the Spotlight Snaps we're loving right now to give you an idea of what the content moderators look for:
Source: Snapchat
Source: Snapchat
Source: Snapchat
Source: Snapchat
Source: Snapchat
Subscribe to our newsletter and get social media resources send to your inbox.
|
{
"url": "https://influencermarketinghub.com/what-is-snap-spotlight/",
"source_domain": "influencermarketinghub.com",
"snapshot_id": "crawl=CC-MAIN-2021-17",
"warc_metadata": {
"Content-Length": "109509",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VQ5TTWTRGZCSEJREWVJ34VZMEIHM656S",
"WARC-Concurrent-To": "<urn:uuid:1fe5a3df-2a1e-4b62-990e-8df3509b6591>",
"WARC-Date": "2021-04-11T00:49:54Z",
"WARC-IP-Address": "104.22.9.176",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:SSSGNUEQUFAAJADPNEDAMVIBERIOOSXG",
"WARC-Record-ID": "<urn:uuid:16b66211-b810-4b3c-97c2-db9282c6c484>",
"WARC-Target-URI": "https://influencermarketinghub.com/what-is-snap-spotlight/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8a33342f-61e7-4743-b098-78b588d95193>"
},
"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-191.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,
45,
46,
576,
577,
823,
824,
947,
948,
949,
995,
996,
997,
1021,
1022,
1395,
1396,
1770,
1771,
2165,
2166,
2167,
2193,
2194,
2537,
2538,
2562,
2563,
2635,
2636,
2658,
2808,
2863,
2933,
2934,
3017,
3018,
3034,
3075,
3125,
3159,
3160,
3185,
3186,
3214,
3215,
3253,
3336,
3395,
3440,
3460,
3461,
4022,
4023,
4232,
4233,
4288,
4289,
4343,
4344,
4345,
4389,
4390,
4604,
4605,
4745,
4746,
5153,
5154,
5427,
5428,
5429,
5489,
5490,
5817,
5818,
5833,
5843,
5854,
5870,
5871,
6160,
6161,
6162,
6188,
6189,
6837,
6838,
7014,
7015,
7041,
7042,
7257,
7258,
7329,
7393,
7513,
7552,
7661,
7698,
7699,
7879,
7880,
7907,
7908,
8090,
8091,
8099,
8100,
8198,
8199,
8212,
8224,
8236,
8262,
8296,
8318,
8319,
8516,
8517,
8531,
8532,
8801,
8802,
8895,
8896,
8926,
8927,
9044,
9045,
9059,
9070,
9082,
9093,
9105,
9117,
9133,
9144,
9155,
9174,
9192,
9193,
9242,
9243,
9409,
9410,
9445,
9446,
9846,
9847,
9869,
9870,
10267,
10268,
10294,
10295,
10636,
10637,
10666,
10667,
11105,
11106,
11122,
11123,
11410,
11411,
11412,
11451,
11452,
11745,
11746,
11747,
11796,
11797,
12119,
12120,
12238,
12239,
12240,
12264,
12265,
12397,
12398,
12415,
12416,
12433,
12434,
12451,
12452,
12469,
12470,
12487,
12488
],
"line_end_idx": [
45,
46,
576,
577,
823,
824,
947,
948,
949,
995,
996,
997,
1021,
1022,
1395,
1396,
1770,
1771,
2165,
2166,
2167,
2193,
2194,
2537,
2538,
2562,
2563,
2635,
2636,
2658,
2808,
2863,
2933,
2934,
3017,
3018,
3034,
3075,
3125,
3159,
3160,
3185,
3186,
3214,
3215,
3253,
3336,
3395,
3440,
3460,
3461,
4022,
4023,
4232,
4233,
4288,
4289,
4343,
4344,
4345,
4389,
4390,
4604,
4605,
4745,
4746,
5153,
5154,
5427,
5428,
5429,
5489,
5490,
5817,
5818,
5833,
5843,
5854,
5870,
5871,
6160,
6161,
6162,
6188,
6189,
6837,
6838,
7014,
7015,
7041,
7042,
7257,
7258,
7329,
7393,
7513,
7552,
7661,
7698,
7699,
7879,
7880,
7907,
7908,
8090,
8091,
8099,
8100,
8198,
8199,
8212,
8224,
8236,
8262,
8296,
8318,
8319,
8516,
8517,
8531,
8532,
8801,
8802,
8895,
8896,
8926,
8927,
9044,
9045,
9059,
9070,
9082,
9093,
9105,
9117,
9133,
9144,
9155,
9174,
9192,
9193,
9242,
9243,
9409,
9410,
9445,
9446,
9846,
9847,
9869,
9870,
10267,
10268,
10294,
10295,
10636,
10637,
10666,
10667,
11105,
11106,
11122,
11123,
11410,
11411,
11412,
11451,
11452,
11745,
11746,
11747,
11796,
11797,
12119,
12120,
12238,
12239,
12240,
12264,
12265,
12397,
12398,
12415,
12416,
12433,
12434,
12451,
12452,
12469,
12470,
12487,
12488,
12566
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 12566,
"ccnet_original_nlines": 192,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4160756468772888,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0011820299550890923,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.15484634041786194,
"rps_doc_frac_unique_words": 0.30486077070236206,
"rps_doc_mean_word_length": 4.690891742706299,
"rps_doc_num_sentences": 105,
"rps_doc_symbol_to_word_ratio": 0.0011820299550890923,
"rps_doc_unigram_entropy": 5.526450157165527,
"rps_doc_word_count": 2119,
"rps_doc_frac_chars_dupe_10grams": 0.014688129536807537,
"rps_doc_frac_chars_dupe_5grams": 0.043661970645189285,
"rps_doc_frac_chars_dupe_6grams": 0.032997988164424896,
"rps_doc_frac_chars_dupe_7grams": 0.026156939566135406,
"rps_doc_frac_chars_dupe_8grams": 0.02173038013279438,
"rps_doc_frac_chars_dupe_9grams": 0.014688129536807537,
"rps_doc_frac_chars_top_2gram": 0.01810864917933941,
"rps_doc_frac_chars_top_3gram": 0.012072429992258549,
"rps_doc_frac_chars_top_4gram": 0.006841049995273352,
"rps_doc_books_importance": -1133.0531005859375,
"rps_doc_books_importance_length_correction": -1133.0531005859375,
"rps_doc_openwebtext_importance": -685.4913330078125,
"rps_doc_openwebtext_importance_length_correction": -685.4913330078125,
"rps_doc_wikipedia_importance": -427.256103515625,
"rps_doc_wikipedia_importance_length_correction": -427.256103515625
},
"fasttext": {
"dclm": 0.20111936330795288,
"english": 0.9441280961036682,
"fineweb_edu_approx": 1.4086803197860718,
"eai_general_math": 0.03994369879364967,
"eai_open_web_math": 0.09690480679273605,
"eai_web_code": 0.021634459495544434
}
}
|
{
"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.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": "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": "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": "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
|
2,292,848,062,972,997,400
|
How to generate random password on Linux
Try it in our public cloud & Get $50 Credit
CLAIM NOW
Being able to generate a random password is an easy to do process on all Linux systems that allow users to enhance their security in a very simple way. Stronger than the average family member name, pet name, or hobby password, randomly generated passwords also prove themselves handy when needing to create multiple new passwords and are extremely easily customizable. Such passwords can include special characters and be any length you need, and multiple passwords can even be generated at once for system administration convenience.
This guide will show how you can generate a random password for yourself on any Linux/Unix system.
Getting Started
In order to complete this tutorial, you need the following:
• 1 Server (Cloud Server or Dedicated Server) running Linux.
Tutorial
We start off simple with a method that can be used on any Linux/Unix system in order to generate a random string. The below command uses /dev/urandom, which is a special file that uses the internal random number generator to produce pseudo-random bits. Note that this is different than the popular /dev/random that you likely know already, which is a true random number generator unlike the pseudo-randomness of /dev/urandom. We can use /dev/urandom to generate a password that is eight characters long and is made up of random uppercase and lowercase letters and numbers (you may need to use sudo):
head /dev/urandom | tr -dc A-Za-z0-9 | head -c 8
The above command, broken down, uses the head to get the first few lines of the dev/urandom file, then pipes the output to the command tr. This command translates the input string into a new one based on the options given to it. We used the options -dc to delete and use the complement of the given set with A-Za-z0-9 to get uppercase, lowercase, and numerical characters. The final pipe again uses head to cut the output into eight characters. To get a password that is longer than eight characters, simply change the value of -c 8 in the above command to your desired length, for example the following for a ten-character long password:
head /dev/urandom | tr -dc A-Za-z0-9 | head -c 10
Using pwgen
While /dev/urandom can be used anywhere and comes built-in, you can also use pwgen to generate a random password. pwgen is more than a random password generator however, it is a professional password generating tool that can create classical cryptographically-secure passwords, pattern-based passwords, list-based passwords, and more, all using the random pool technique to generate random data. It is open-source, free to use, and works on many systems. To install pwgen for yourself, execute one of the following commands for your respective system (you may need root privileges, use sudo if needed):
CentOS
yum install pwgen -y
Debian/Ubuntu
apt-get install pwgen -y
When using pwgen, the basic structure of the command is as following:
pwgen [ OPTIONS ] [ pw_length ] [ num_pw ]
To create a single random password that is ten characters (uppercase/lowercase letters and numbers), execute this command. The -s flag ensures that the password created is truly random, the value 10 states how many characters long the password should be, and the value 1 represents the number of passwords we want to output:
pwgen 10 -s 1
This command results in a password that looks like this:
RUFv7fxA3o
To make your passwords more secure, you can add special characters using the flag -y as part of the above command such as this:
pwgen 10 -sy 1
Adding the special character flag creates passwords like this instead of the above. Note the inclusion of special characters suchas # or +:
N+`I#ZDK4V
In the case that you want a password that is a different amount of characters, such as rather 20 (or any other number), you can modify the amount of characters output such as in this example to output a 20-character long random password:
pwgen 20 -s 1
The result will now be a single password that has 20 characters:
E502JHiybGi7dvsQGbWS
In the case that you want to output more than one password, simple change the value 1 to any other number, for example 3, to receive three generated passwords:
pwgen 10 -sy 3
The output respectively will change to show the three passwords:
LG]8*;9L.z BT3|NAEM5z 4i*GQ}CL`V
More information about the command-line options for pwgen can be found in its man page either online or accessible via:
man pwgen
Conclusion
Having completed this guide, you are now able to generate random passwords using both the tool pwgen as well as the built-in Linux/Unix file /dev/urandom. Enjoy playing around with the different command-line options to generate passwords that suit your needs, and share with your friends!
|
{
"url": "https://www.globo.tech/learning-center/generate-random-password-linux/",
"source_domain": "www.globo.tech",
"snapshot_id": "crawl=CC-MAIN-2017-39",
"warc_metadata": {
"Content-Length": "53110",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:3YTPL7BOHUMOK2L2CMGGRBYI7XD3UK7M",
"WARC-Concurrent-To": "<urn:uuid:f106d865-58a2-4ead-b489-6ee538413635>",
"WARC-Date": "2017-09-24T06:59:24Z",
"WARC-IP-Address": "67.43.229.6",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:JCFVTHBJ27ANQU53AFABNEZJBLFA76EL",
"WARC-Record-ID": "<urn:uuid:ebf37c4c-c537-4318-880e-d75f1a6b9495>",
"WARC-Target-URI": "https://www.globo.tech/learning-center/generate-random-password-linux/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:f601d946-21c6-43dc-a072-ccde4cbfed09>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-71-152-239.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-39\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for September 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,
41,
42,
86,
96,
97,
632,
633,
732,
733,
749,
750,
810,
871,
872,
881,
882,
1482,
1483,
1532,
1533,
2172,
2173,
2223,
2224,
2236,
2237,
2840,
2841,
2848,
2849,
2870,
2871,
2885,
2886,
2911,
2912,
2982,
2983,
3026,
3027,
3352,
3353,
3367,
3368,
3425,
3426,
3437,
3438,
3566,
3567,
3582,
3583,
3723,
3724,
3735,
3736,
3974,
3975,
3989,
3990,
4055,
4056,
4077,
4078,
4238,
4239,
4254,
4255,
4320,
4321,
4354,
4355,
4475,
4476,
4486,
4487,
4498,
4499
],
"line_end_idx": [
41,
42,
86,
96,
97,
632,
633,
732,
733,
749,
750,
810,
871,
872,
881,
882,
1482,
1483,
1532,
1533,
2172,
2173,
2223,
2224,
2236,
2237,
2840,
2841,
2848,
2849,
2870,
2871,
2885,
2886,
2911,
2912,
2982,
2983,
3026,
3027,
3352,
3353,
3367,
3368,
3425,
3426,
3437,
3438,
3566,
3567,
3582,
3583,
3723,
3724,
3735,
3736,
3974,
3975,
3989,
3990,
4055,
4056,
4077,
4078,
4238,
4239,
4254,
4255,
4320,
4321,
4354,
4355,
4475,
4476,
4486,
4487,
4498,
4499,
4787
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4787,
"ccnet_original_nlines": 78,
"rps_doc_curly_bracket": 0.0002089000045089051,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3969542980194092,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.015228429809212685,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.18274112045764923,
"rps_doc_frac_unique_words": 0.3643312156200409,
"rps_doc_mean_word_length": 4.825477600097656,
"rps_doc_num_sentences": 20,
"rps_doc_symbol_to_word_ratio": 0.0020304599311202765,
"rps_doc_unigram_entropy": 5.054497718811035,
"rps_doc_word_count": 785,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.03907075151801109,
"rps_doc_frac_chars_dupe_6grams": 0.025871170684695244,
"rps_doc_frac_chars_dupe_7grams": 0.015311510302126408,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.021119320765137672,
"rps_doc_frac_chars_top_3gram": 0.011615630239248276,
"rps_doc_frac_chars_top_4gram": 0.013463569805026054,
"rps_doc_books_importance": -462.3410339355469,
"rps_doc_books_importance_length_correction": -462.3410339355469,
"rps_doc_openwebtext_importance": -301.9735107421875,
"rps_doc_openwebtext_importance_length_correction": -301.9735107421875,
"rps_doc_wikipedia_importance": -247.76028442382812,
"rps_doc_wikipedia_importance_length_correction": -247.76028442382812
},
"fasttext": {
"dclm": 0.7181487679481506,
"english": 0.8730764389038086,
"fineweb_edu_approx": 2.909754753112793,
"eai_general_math": 0.9424089789390564,
"eai_open_web_math": 0.1975616216659546,
"eai_web_code": 0.6796683073043823
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.822",
"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": "-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": "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
|
-1,016,628,291,167,329,500
|
Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author
Re: Tab inserts spaces instead of complete by default
On Feb 21, 12:17pm, Sébastien Pierre wrote:
}
} So my question is: how can I configure zsh to always show possible
} completions, even when there is no character on the prompt ?
Zsh by default binds tab to the "expand-or-complete" widget, which
(also by default) has the behavior you described.
You can change this by changing the widget used for tab:
bindkey '^I' complete-word
However, that's still just using the relatively simple built-in set
of completions. You probably want instead to enable the full set of
scripted completions by running the "compinstall" command, or by
manually editing your .zshrc to add the lines
autoload -U compinit
compinit
Messages sorted by: Reverse Date, Date, Thread, Author
|
{
"url": "http://www.zsh.org/mla/users/2010/msg00152.html",
"source_domain": "www.zsh.org",
"snapshot_id": "crawl=CC-MAIN-2019-22",
"warc_metadata": {
"Content-Length": "4214",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FSYD7X5T3Y3AUA2VXPWN4QPXKO47YQYT",
"WARC-Concurrent-To": "<urn:uuid:74bd68a9-d5a0-4606-b8a2-187d78b2273e>",
"WARC-Date": "2019-05-21T20:11:46Z",
"WARC-IP-Address": "203.24.36.104",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:DEYEWB5IILFFACSM5KHD2NECUEQCFHXI",
"WARC-Record-ID": "<urn:uuid:06cce8eb-2f0c-4da9-a54e-a46618bd9d12>",
"WARC-Target-URI": "http://www.zsh.org/mla/users/2010/msg00152.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:923177ec-f058-48fc-a354-27bd0c0e3d3e>"
},
"warc_info": "isPartOf: CC-MAIN-2019-22\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-234-169-21.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,
25,
80,
81,
135,
136,
137,
138,
182,
184,
253,
316,
317,
384,
434,
435,
492,
493,
520,
521,
589,
658,
723,
769,
770,
795,
808,
809,
810,
811
],
"line_end_idx": [
25,
80,
81,
135,
136,
137,
138,
182,
184,
253,
316,
317,
384,
434,
435,
492,
493,
520,
521,
589,
658,
723,
769,
770,
795,
808,
809,
810,
811,
865
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 865,
"ccnet_original_nlines": 29,
"rps_doc_curly_bracket": 0.0034682101104408503,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3222222328186035,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01666666939854622,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.23333333432674408,
"rps_doc_frac_unique_words": 0.6641790866851807,
"rps_doc_mean_word_length": 4.977612018585205,
"rps_doc_num_sentences": 5,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.2847185134887695,
"rps_doc_word_count": 134,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.1289355307817459,
"rps_doc_frac_chars_dupe_6grams": 0.1289355307817459,
"rps_doc_frac_chars_dupe_7grams": 0.1289355307817459,
"rps_doc_frac_chars_dupe_8grams": 0.1289355307817459,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.040479760617017746,
"rps_doc_frac_chars_top_3gram": 0.04797600954771042,
"rps_doc_frac_chars_top_4gram": 0.06896551698446274,
"rps_doc_books_importance": -87.74952697753906,
"rps_doc_books_importance_length_correction": -87.74952697753906,
"rps_doc_openwebtext_importance": -46.45912170410156,
"rps_doc_openwebtext_importance_length_correction": -41.448734283447266,
"rps_doc_wikipedia_importance": -29.874893188476562,
"rps_doc_wikipedia_importance_length_correction": -29.874893188476562
},
"fasttext": {
"dclm": 0.14774465560913086,
"english": 0.8921119570732117,
"fineweb_edu_approx": 1.9314788579940796,
"eai_general_math": 0.8810163736343384,
"eai_open_web_math": 0.2032541036605835,
"eai_web_code": 0.18458276987075806
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.432",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "005.435",
"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": "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": "18",
"label": "Q&A Forum"
}
},
"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,521,464,298,700,967,000
|
2
This question already has an answer here:
I have read a lot of posts which explain that the only solution to stop the growth of an ever increasing ibdata1 file is to:
1. Take a dump of all databases
2. Set innodb_file_per_table in the mysqld section of my.cnf
3. Clean the data directory (except mysql)
4. Restart the MySQL Server and load the dumps using mysqldump.
However my problem starts once I have done all these steps. I still see a scenario where the size of my ibdata1 file increases. The scenario is explained below:
I start MySQL Server 5.5 with a clean data directory (only the mysql directory is present), the size of the ibdata1 file reads 18 MB. Next steps follow:
1. I have the innodb_file_per_table entry already mentioned under the mysqld section of my.cnf.
2. Now I load some tables from mysql dump files (all of them have InnoDB storage engine specified) using mysqldump. I observe that ibdata1 size has not changed and separate ibd files have been created which is expected according to the innodb_file_per_table setting
3. I add a new column say, ColumnA (int, NOT NULL, UNSIGNED, DEFAULT 0) to a table, say Table A. The storage engine is InnoDB and contains 9 million records. So far so good, the size of ibdata1 file remains the same (18 MB)
4. I now update the values in ColumnA using the following query: update TableA set ColumnA = crc32(someothervarcharcolumnfromthistable);
5. I observe that during the update the size of ibdata1 consistently grows and grows past 300 MB.
Why is this happening? Does this mean I have to do the cleanup-restart-restore activity mentioned at the beginning every 'x' months, or am I missing something?
Edit 1: This question is not a duplicate of this question answered by RolandoMySQLDBA. Reasons follow:
1. It says what ibdata1 stores in general. However it does not clarify when all precautions are taken against its increase, why would it still do so when performing operations on a particular table.
2. Though it is very informative, however it outlines the corrective measures that can be taken, does not highlight preventive measures post the activity is done.
In case it is not clear from my question, I wanted to get the opinion of experts on preventive measures once I have set innodb_file_per_table for ibdata1 not to grow.
marked as duplicate by RolandoMySQLDBA mysql Jan 15 '15 at 15:22
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
• @RolandoMySQLDBA Please see edit as to why this question is not a duplicate. – Cik Jan 15 '15 at 17:09
• 1
What do you mean with "preventive" measures? The ibdata1 file can grow large but I'm sure any decent server can handle a file of a few GBs, let alone 300 MB. What is the problem with having one large file that is used by the DBMS for several reasons? – ypercubeᵀᴹ Jan 15 '15 at 17:19
• In my post, I specifically mentioned the Undo Space (where the most uncontrolled growth can happen). I also make reference to mysqlperformanceblog.com's Reasons for run-away main Innodb Tablespace (percona.com/blog/2010/06/10/…). I also pointed out the three reasons for the ibdata1 growth. 1) Lots of Transactional Changes, 2) Very Long Transactions, 3) Lagging Purge Thread. – RolandoMySQLDBA Jan 15 '15 at 17:47
• 1
Please also note that the posted answer has two links from me. I have consistently stated the ibdata1 will grow no matter what. So, it's either do the cleanup of InnoDB or live with the growth. – RolandoMySQLDBA Jan 15 '15 at 18:08
• 1
You mentioned posts about 2TB ibdata1. I have those as well (dba.stackexchange.com/a/68326/877, dba.stackexchange.com/a/21195/877). In those posts, innodb_file_per_table was disabled. You don't have to worry about such a situation. Your question says the type of UPDATEs you are running. That will demand UNDO growth. It simply must happen because of the possibility of rollbacks and MVCC for transaction isolation. Sorry for being redundant, but there is nothing you can do about stemming ibdata1's growth. – RolandoMySQLDBA Jan 15 '15 at 18:17
0
Lets try to understand whats stored inside ibdata1: When you have innodb_file_per_table enabled, the tables are stored in their own tablespace but the shared tablespace is still used to store other InnoDB’s internal data: * data dictionary * change buffer * doublewrite buffer * undo logs
since there is trancations, rollbacks that support repeatable read that will make ibdata1 files grow even when you update any innodb table.
reference: http://www.percona.com/blog/2013/08/20/why-is-the-ibdata1-file-continuously-growing-in-mysql/
ibdata1 grows exponentially when innodb_file_per_table is configured
https://serverfault.com/questions/272146/why-ibdata1-is-still-growing-when-i-have-used-innodb-file-per-table-in-mysql-5-1
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "https://dba.stackexchange.com/questions/89364/ibdata1-increases-when-firing-update-queries",
"source_domain": "dba.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2019-43",
"warc_metadata": {
"Content-Length": "136021",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ATUTT42ZK2SJWKYVOMLIPQ5TQLAFAGTF",
"WARC-Concurrent-To": "<urn:uuid:3db55b99-ac36-4f56-9242-086cca298190>",
"WARC-Date": "2019-10-19T13:40:34Z",
"WARC-IP-Address": "151.101.129.69",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:NWNPF4UI3NXXQYNZQHI3V5HMZB22ZNH4",
"WARC-Record-ID": "<urn:uuid:6134df3c-194d-4267-998c-ed81d03e8004>",
"WARC-Target-URI": "https://dba.stackexchange.com/questions/89364/ibdata1-increases-when-firing-update-queries",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c89cbb90-a3ec-433e-8f2c-9f2f62a49ef2>"
},
"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,
2,
3,
45,
46,
171,
172,
206,
269,
314,
380,
381,
542,
543,
696,
697,
795,
1063,
1289,
1428,
1528,
1529,
1689,
1690,
1793,
1794,
1995,
2160,
2161,
2328,
2329,
2394,
2395,
2538,
2539,
2646,
2652,
2940,
3359,
3365,
3601,
3607,
4157,
4159,
4160,
4449,
4450,
4590,
4591,
4696,
4697,
4766,
4767,
4889,
4890
],
"line_end_idx": [
2,
3,
45,
46,
171,
172,
206,
269,
314,
380,
381,
542,
543,
696,
697,
795,
1063,
1289,
1428,
1528,
1529,
1689,
1690,
1793,
1794,
1995,
2160,
2161,
2328,
2329,
2394,
2395,
2538,
2539,
2646,
2652,
2940,
3359,
3365,
3601,
3607,
4157,
4159,
4160,
4449,
4450,
4590,
4591,
4696,
4697,
4766,
4767,
4889,
4890,
4980
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4980,
"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.357824444770813,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03148854896426201,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2528626024723053,
"rps_doc_frac_unique_words": 0.4254777133464813,
"rps_doc_mean_word_length": 4.978343963623047,
"rps_doc_num_sentences": 63,
"rps_doc_symbol_to_word_ratio": 0.0009541999897919595,
"rps_doc_unigram_entropy": 5.327733516693115,
"rps_doc_word_count": 785,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.047850560396909714,
"rps_doc_frac_chars_dupe_6grams": 0.03607983887195587,
"rps_doc_frac_chars_dupe_7grams": 0.015864890068769455,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.008955989964306355,
"rps_doc_frac_chars_top_3gram": 0.01074718963354826,
"rps_doc_frac_chars_top_4gram": 0.013817810453474522,
"rps_doc_books_importance": -455.48992919921875,
"rps_doc_books_importance_length_correction": -455.48992919921875,
"rps_doc_openwebtext_importance": -248.4097900390625,
"rps_doc_openwebtext_importance_length_correction": -248.4097900390625,
"rps_doc_wikipedia_importance": -169.3597869873047,
"rps_doc_wikipedia_importance_length_correction": -169.3597869873047
},
"fasttext": {
"dclm": 0.32307153940200806,
"english": 0.9172085523605347,
"fineweb_edu_approx": 1.5606426000595093,
"eai_general_math": 0.643770158290863,
"eai_open_web_math": 0.3325622081756592,
"eai_web_code": 0.06424946337938309
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.746",
"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": "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": "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": "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": "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
|
6,375,052,173,665,434,000
|
Jump to content
• Log In with Google Sign In
• Create Account
Banner advertising on our site currently available from just $5!
1. Learn about the promo. 2. Sign up for GDNet+. 3. Set up your advert!
SephireX
Member Since 11 Mar 2013
Offline Last Active Today, 05:42 AM
#5172440 Using Leaked Code Derived From An Open Source Project
Posted by SephireX on 09 August 2014 - 06:09 AM
Hello there. I'm considering using an open source rendering engine as part of a game engine I wish to develop. The engine is the Geometric Tools Engine and it uses the Boost License. The engine can be found here: http://geometrictools.com. I will need to modify the rendering engine over time and make improvements. Therefore my rendering engine will be a derivative work. I am unclear about a few things when it comes to licensing. GPL requires any program using GPL code to include the copyright notice at the top of all source files and also with any binaries when the derived program is distributed. However, the Boost License is a lot less restrictive. A copy of the license does not have to be included with the executable of the derived software but must be included in the source file when the code is distributed. It also states that any code distributed alongside code covered by the license is not subject to the license's requirements. This brings me to my first question:
Assuming I want to fork the rendering engine and keep it private (which the license permits), can I also add my own copyright notice under a different license to source files in the modified engine that I add? So if I create a new class and I modify an existing class from the original code to link to it, can that new class still have my copyright under a different license? I assume the code I add to the original class cannot be licensed differently.
My second question is related to leaked code:
Let's say I set up a company and develop software derived from software covered by the Boost License and an employee leaks the derived code. Seeing as the derived code is also covered by the Boost License, can anyone obtaining the leaked code legally use it for their own purposes? Even though it may be covered by an open source license, it was not the intention of the author for the code to be distributed.
Thanks for any answers or suggestions.
PARTNERS
|
{
"url": "http://www.gamedev.net/user/209055-sephirex/?tab=reputation",
"source_domain": "www.gamedev.net",
"snapshot_id": "crawl=CC-MAIN-2015-32",
"warc_metadata": {
"Content-Length": "73950",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:S53D64DPTJFTZI6ZVB6FBCZ5M6CT47X3",
"WARC-Concurrent-To": "<urn:uuid:d404d178-19bb-496c-b5a0-20e0e8249833>",
"WARC-Date": "2015-07-31T17:48:23Z",
"WARC-IP-Address": "64.91.255.13",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:NMMS5BWHZEO2H4G3TB4VMTLMYOMLPSNH",
"WARC-Record-ID": "<urn:uuid:58f54f24-4c86-44e9-a590-8d348e6bbde8>",
"WARC-Target-URI": "http://www.gamedev.net/user/209055-sephirex/?tab=reputation",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8deb4973-933e-4290-8ef6-2cccb9944b5f>"
},
"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,
16,
17,
56,
75,
76,
141,
142,
143,
215,
216,
217,
226,
227,
252,
288,
289,
352,
353,
401,
402,
1387,
1388,
1390,
1391,
1845,
1846,
1848,
1849,
1895,
1896,
1898,
1899,
2310,
2311,
2313,
2314,
2354,
2355,
2357,
2358,
2360,
2361,
2363,
2364,
2366,
2367,
2368,
2369,
2370
],
"line_end_idx": [
16,
17,
56,
75,
76,
141,
142,
143,
215,
216,
217,
226,
227,
252,
288,
289,
352,
353,
401,
402,
1387,
1388,
1390,
1391,
1845,
1846,
1848,
1849,
1895,
1896,
1898,
1899,
2310,
2311,
2313,
2314,
2354,
2355,
2357,
2358,
2360,
2361,
2363,
2364,
2366,
2367,
2368,
2369,
2370,
2378
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2378,
"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.4197002053260803,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03854389861226082,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.12847965955734253,
"rps_doc_frac_unique_words": 0.46746987104415894,
"rps_doc_mean_word_length": 4.477108478546143,
"rps_doc_num_sentences": 27,
"rps_doc_symbol_to_word_ratio": 0.002141329925507307,
"rps_doc_unigram_entropy": 4.800646781921387,
"rps_doc_word_count": 415,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.025834230706095695,
"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.032292790710926056,
"rps_doc_frac_chars_top_3gram": 0.032292790710926056,
"rps_doc_frac_chars_top_4gram": 0.023681379854679108,
"rps_doc_books_importance": -226.77798461914062,
"rps_doc_books_importance_length_correction": -226.77798461914062,
"rps_doc_openwebtext_importance": -129.98773193359375,
"rps_doc_openwebtext_importance_length_correction": -129.98773193359375,
"rps_doc_wikipedia_importance": -86.09608459472656,
"rps_doc_wikipedia_importance_length_correction": -86.09608459472656
},
"fasttext": {
"dclm": 0.025830859318375587,
"english": 0.9353333115577698,
"fineweb_edu_approx": 1.8973037004470825,
"eai_general_math": 0.15253114700317383,
"eai_open_web_math": 0.15314507484436035,
"eai_web_code": 0.01806062087416649
}
}
|
{
"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": "344.730285",
"labels": {
"level_1": "Social sciences",
"level_2": "Law",
"level_3": "Martial law"
}
}
},
"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": "16",
"label": "Personal Blog"
}
},
"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": "2",
"label": "High School Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-3,859,951,803,058,814,500
|
Question
Locked
Help Needed Regarding: TrendMicro Antivirus considering java App a higly ri
By togreatmind ·
Hello
I have a java application which sniff the network traffic, I am using jpcap and winpcap in my application. Application runs fine with AVG antivirus.but when i did deploy my java application at customer environment where customer has Tren Micro Antivirus.
At that customer end trend micro is repotting my Java Application as high risk thread and also consider as dialup app which is trying to accessing the other pcs. But in actual it really not like that its only sniff the traffic which comes on that particular pc
This conversation is currently closed to new comments.
5 total posts (Page 1 of 1)
| Thread display: Collapse - | Expand +
All Answers
Collapse -
You could contact Trend Micro,
perhaps send them a sample of the code, but they will probably not remove the
threat detection. Many network tools that are used routinely are detected by
various antimalware scanners as suspect. If the application is trusted, you may
be able to add it to the excluded software list in the options of the scanner.
edit to add: prior to adding it to the exclusions list, since this is a client's
system and not your own, I would recommend full disclosure to the
client, including what the software does and why you need it to
perform your service.
Collapse -
Reponse To Answer
by togreatmind In reply to You could contact Trend M ...
yeah my application sniff only the packets like WireShark.
Also in my client side they installed ArcSight Anti Virus and then Archsight might connect with TrendMicro.
Furthermore do you know that how we can add my application in Trusted Application list in ArcSight
Thanks
Regards
Collapse -
Red flags...
by Rob Kuhn In reply to Help Needed Regarding: Tr ...
There are two red flags that will set off any decent AVG; a Java app and a Java app that is doing "suspicious" network activity (even if it's just sniffing traffic).
I agree with "Wizard57m-cnet" statement about providing disclosure to your client.
What is this app sniffing for? does it just sit on a machine that sniffs the packets? Or is it actually sniffing through the entire network (like a SNMP/WMI sweep) and hitting devices it finds?
If it's the later than some sort of exclusion will need to be made on every effected machine and device it touches.
If it just sits there like WireShark then the exclusion just needs to be made to the local host it's running on. If the client has any sort of intruder detecting system or even just an SNMP/WMI type monitoring system in place you may need to add some sort of exlusion on those respected systems - otherwise it could trigger false alerts (I had this happen once when running an agressive WireShark capture - my switch saw an abnormal increase in traffic on a port and so it shut the port down).
Collapse -
Reponse To Answer
by togreatmind In reply to Red flags...
yeah my application sniff only the packets like WireShark.
Also in my client side they installed ArcSight Anti Virus and then Archsight might connect with TrendMicro.
Furthermore do you know that how we can add my application in Trusted Application list in ArcSight
Thanks
Regards
Back to Software Forum
5 total posts (Page 1 of 1)
Software Forums
|
{
"url": "http://www.techrepublic.com/forums/discussions/help-needed-regarding-trendmicro-antivirus-considering-java-app-a-higly-ri/?type=questions",
"source_domain": "www.techrepublic.com",
"snapshot_id": "crawl=CC-MAIN-2016-50",
"warc_metadata": {
"Content-Length": "182475",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VPOEEADI7JR33NCROCBPCMZ3Z73OHN24",
"WARC-Concurrent-To": "<urn:uuid:2a4f6496-828b-4c50-8f8a-e3a5c03ec563>",
"WARC-Date": "2016-12-08T14:35:42Z",
"WARC-IP-Address": "65.158.180.11",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:7RGPCOFIJZIP2TA2E4ZJOWO5EH6WZ2LC",
"WARC-Record-ID": "<urn:uuid:5d9e3a31-2905-47eb-9b2c-f2f438379b9d>",
"WARC-Target-URI": "http://www.techrepublic.com/forums/discussions/help-needed-regarding-trendmicro-antivirus-considering-java-app-a-higly-ri/?type=questions",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:b2c8d52b-ce08-40f9-8322-96694bcb8e7d>"
},
"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,
9,
10,
17,
18,
94,
95,
112,
118,
119,
120,
375,
636,
637,
692,
693,
723,
763,
764,
776,
777,
788,
789,
820,
821,
899,
976,
1056,
1135,
1136,
1217,
1283,
1347,
1369,
1370,
1381,
1382,
1400,
1401,
1458,
1459,
1518,
1626,
1627,
1726,
1727,
1734,
1742,
1743,
1754,
1755,
1768,
1769,
1823,
1824,
1990,
1991,
2074,
2075,
2269,
2270,
2386,
2387,
2881,
2882,
2893,
2894,
2912,
2913,
2953,
2954,
3013,
3121,
3122,
3221,
3222,
3229,
3237,
3238,
3261,
3291,
3292
],
"line_end_idx": [
9,
10,
17,
18,
94,
95,
112,
118,
119,
120,
375,
636,
637,
692,
693,
723,
763,
764,
776,
777,
788,
789,
820,
821,
899,
976,
1056,
1135,
1136,
1217,
1283,
1347,
1369,
1370,
1381,
1382,
1400,
1401,
1458,
1459,
1518,
1626,
1627,
1726,
1727,
1734,
1742,
1743,
1754,
1755,
1768,
1769,
1823,
1824,
1990,
1991,
2074,
2075,
2269,
2270,
2386,
2387,
2881,
2882,
2893,
2894,
2912,
2913,
2953,
2954,
3013,
3121,
3122,
3221,
3222,
3229,
3237,
3238,
3261,
3291,
3292,
3307
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3307,
"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.4251968562602997,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.018897639587521553,
"rps_doc_frac_lines_end_with_ellipsis": 0.04878048971295357,
"rps_doc_frac_no_alph_words": 0.11496063321828842,
"rps_doc_frac_unique_words": 0.45098039507865906,
"rps_doc_mean_word_length": 4.672014236450195,
"rps_doc_num_sentences": 26,
"rps_doc_symbol_to_word_ratio": 0.006299209780991077,
"rps_doc_unigram_entropy": 5.153913497924805,
"rps_doc_word_count": 561,
"rps_doc_frac_chars_dupe_10grams": 0.17855779826641083,
"rps_doc_frac_chars_dupe_5grams": 0.22739411890506744,
"rps_doc_frac_chars_dupe_6grams": 0.22739411890506744,
"rps_doc_frac_chars_dupe_7grams": 0.22739411890506744,
"rps_doc_frac_chars_dupe_8grams": 0.21289584040641785,
"rps_doc_frac_chars_dupe_9grams": 0.21289584040641785,
"rps_doc_frac_chars_top_2gram": 0.024799689650535583,
"rps_doc_frac_chars_top_3gram": 0.010301410220563412,
"rps_doc_frac_chars_top_4gram": 0.011446010321378708,
"rps_doc_books_importance": -260.6087341308594,
"rps_doc_books_importance_length_correction": -260.6087341308594,
"rps_doc_openwebtext_importance": -178.6574249267578,
"rps_doc_openwebtext_importance_length_correction": -178.6574249267578,
"rps_doc_wikipedia_importance": -119.76268768310547,
"rps_doc_wikipedia_importance_length_correction": -119.76268768310547
},
"fasttext": {
"dclm": 0.06536048650741577,
"english": 0.9372825622558594,
"fineweb_edu_approx": 1.1355592012405396,
"eai_general_math": 0.09207457304000854,
"eai_open_web_math": 0.13900470733642578,
"eai_web_code": 0.03219097852706909
}
}
|
{
"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": "-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": "21",
"label": "Customer Support"
}
},
"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
|
6,585,627,228,775,452,000
|
Beaker
From CivWar Wiki
Jump to: navigation, search
What they do[edit | edit source]
Beakers are the foundation of making your civilization strong. While your hammers let you build and construct buildings, beakers let you research new technologies to expand your civilizations horizons. These techs can expand your trade, military, and productive opportunities.
Where to get them[edit | edit source]
Beakers are found on every chunk of the world, a simple '/t survey' will let you know where to get the best ones.
How to Win with them[edit | edit source]
In order to win the Scientific Victory, you must have Enlightenment researched. You don't NEED to research armor techs to achieve this, but all other civilizations will war you in an attempt to stop you.
Researching[edit | edit source]
A single Beaker is worth 1 hour of research time, that means if you have 1 beaker and the tech you require has 60, it will take you 60 hours to Research that tech. An equation to solve for this would be:
Required Beakers ÷ Civ Beakers = Research time (in real world hours)
Example: Religion requires 500 beakers. The Civ has 100 Beakers.
500 ÷ 100 = 5 hours
Tax conversion[edit | edit source]
You can also use your tax as a way to gain beakers. Your leaders can set your civ's tax to a certain percentage this depends on your Government. But you also need to have a science percentage. Best is to have it at 100% if you want the tech quicker. This is best to explain using an example. Commands; /civ set taxes (depends on your government) /civ set science (between 0-100)
In this example we are Communism, which has an 20% max tax rate(But every Government has another max tax rate). And 100% science percentage.
Lets say you have 3 towns all gaining 5,000 coins per hour, this makes 15,000 coins in total. 20% of this goes into the civ,
15,000 x 0.2 = 3,000 coins
Science percentage[edit | edit source]
The science percentage generates for every 10 coins 1 beaker. So in this case:
3,000 ÷ 10 = 300 beakers
So you make 300 beakers extra at hourly tick.
There is also a policy that generates 1 beaker per 9 coins. So in our example that would mean,
3,000 ÷ 9 = 333 beakers
So you make 333 beakers extra at hourly tick.
See Also[edit | edit source]
Tutorials Town Mechanics Civ Mechanics Defensive Structures Town Structures Tile Improvements Wonders Units Command Reference
Promotional Content
|
{
"url": "https://civwar.gamepedia.com/Beaker",
"source_domain": "civwar.gamepedia.com",
"snapshot_id": "crawl=CC-MAIN-2018-34",
"warc_metadata": {
"Content-Length": "96674",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:QPQRJFCT7Q5LTCKDK2CBNYHRWGYNFW7H",
"WARC-Concurrent-To": "<urn:uuid:b7defda2-eb8d-4fca-a0f9-8fade65763b0>",
"WARC-Date": "2018-08-14T23:51:52Z",
"WARC-IP-Address": "52.84.121.115",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:3XBAHTFS6QNGVGWCTYR4N3KE23AJLUZS",
"WARC-Record-ID": "<urn:uuid:cee9088b-887b-4241-81a5-58858df2b11a>",
"WARC-Target-URI": "https://civwar.gamepedia.com/Beaker",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:61545e6b-9d56-459b-8f22-9186cd4b3714>"
},
"warc_info": "isPartOf: CC-MAIN-2018-34\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for August 2018\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-199-169.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,
7,
8,
25,
53,
54,
87,
88,
365,
366,
404,
405,
519,
520,
561,
562,
766,
767,
799,
800,
1004,
1005,
1075,
1141,
1162,
1163,
1198,
1199,
1578,
1579,
1720,
1721,
1846,
1847,
1875,
1876,
1915,
1916,
1995,
1996,
2022,
2023,
2069,
2070,
2165,
2166,
2191,
2192,
2238,
2239,
2268,
2269,
2395,
2396,
2397,
2398
],
"line_end_idx": [
7,
8,
25,
53,
54,
87,
88,
365,
366,
404,
405,
519,
520,
561,
562,
766,
767,
799,
800,
1004,
1005,
1075,
1141,
1162,
1163,
1198,
1199,
1578,
1579,
1720,
1721,
1846,
1847,
1875,
1876,
1915,
1916,
1995,
1996,
2022,
2023,
2069,
2070,
2165,
2166,
2191,
2192,
2238,
2239,
2268,
2269,
2395,
2396,
2397,
2398,
2417
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2417,
"ccnet_original_nlines": 55,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3210831582546234,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0038684699684381485,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.25918760895729065,
"rps_doc_frac_unique_words": 0.4718826413154602,
"rps_doc_mean_word_length": 4.577017307281494,
"rps_doc_num_sentences": 23,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.91844367980957,
"rps_doc_word_count": 409,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.025641029700636864,
"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.03739316016435623,
"rps_doc_frac_chars_top_3gram": 0.01816239021718502,
"rps_doc_frac_chars_top_4gram": 0.021367520093917847,
"rps_doc_books_importance": -193.68450927734375,
"rps_doc_books_importance_length_correction": -193.68450927734375,
"rps_doc_openwebtext_importance": -88.92125701904297,
"rps_doc_openwebtext_importance_length_correction": -88.92125701904297,
"rps_doc_wikipedia_importance": -72.44335174560547,
"rps_doc_wikipedia_importance_length_correction": -72.44335174560547
},
"fasttext": {
"dclm": 0.1332157850265503,
"english": 0.9136820435523987,
"fineweb_edu_approx": 2.3363595008850098,
"eai_general_math": 0.2899733781814575,
"eai_open_web_math": 0.308407187461853,
"eai_web_code": 0.01146536972373724
}
}
|
{
"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": "338.9",
"labels": {
"level_1": "Social sciences",
"level_2": "Economics",
"level_3": "Industries, Prices, and Microeconomics"
}
}
},
"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": "2",
"label": "Click Here References"
}
},
"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": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-1,025,592,896,006,894,000
|
Jump to content
• Log In with Google Sign In
• Create Account
Calling all IT Pros from Canada and Australia.. we need your help! Support our site by taking a quick sponsored surveyand win a chance at a $50 Amazon gift card. Click here to get started!
Sparks Effect
Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
• You cannot reply to this topic
37 replies to this topic
#21 Rhetorician Members - Reputation: 115
Like
0Likes
Like
Posted 15 May 2013 - 07:28 PM
I tried setting mWorldProjection to the camera projection and mWorld to the transformation of the volumetric lines.
worldProjection = world * projection. Got that right?
To be crabby... Those aren't even volumetric lines. They're just fancy linear billboards with UV selection based on orientation... in an outrageously terrible implementation at that! You probably could write up proper volumetric lines if you're competent, which I recommend. When you integrate over the path through an OBB, I don't think you'll want to base it on sqrt() distance, which would be pretty (INSANELY) naive considering performance, but won't provide a fully realistic distribution anyway. I'll reply again if I can think of a good way to do this. Others can throw in their suggestions too if they want. biggrin.png
EDIT:
This might be helpful. I'm reading it myself and I'll try to put it into useful terms (appropriate for your needs). smile.png
http://citeseerx.ist.psu.edu/viewdoc/download;jsessionid=5FFDAF33F6C101694D4F9987AFA25C3D?doi=10.1.1.96.5955&rep=rep1&type=pdf
One last additional remark
point sprites = billboards which are oriented about a point.
linear billboards = billboards which are oriented about a line.
Edited by Reflexus, 15 May 2013 - 07:38 PM.
Sponsor:
#22 Medo3337 Members - Reputation: 683
Like
0Likes
Like
Posted 15 May 2013 - 07:52 PM
worldProjection = world * projection. Got that right?
When I do that, the lines are stuck on the camera all the time, they appear like sprites.
I believe this can accomplish what I need which is (sparks particles).
So, my only problem right now is setting the transformation, I have the problem that I mentioned earlier.
worldProjection = world * projection // --> Stuck on the camera all the time
worldProjection = camera->GetProjectionMatrix(); // --> I don't see the lines anymore
#23 Rhetorician Members - Reputation: 115
Like
0Likes
Like
Posted 15 May 2013 - 08:19 PM
Show me the actual code involving ->SetMatrix()
#24 Medo3337 Members - Reputation: 683
Like
0Likes
Like
Posted 16 May 2013 - 08:21 AM
I tried doing the following:
D3DXMATRIX mWorld;
D3DXMatrixIdentity(&mWorld);
mWorldProjection = camera->getProjectionMatrix();
effect->SetMatrix( "mWV", &mWorld );
effect->SetMatrix( "mWVP", &mWorldProjection );
When I do that I don't see the lines.
#25 Rhetorician Members - Reputation: 115
Like
1Likes
Like
Posted 16 May 2013 - 11:29 AM
When I do that I don't see the lines.
Where are their positions defined anyway? If you're just using identity then you should make sure they're in that small limited frustum which is tanget to the XY plane (i.e. screen space), and make sure your Z-clipping fits. lol, otherwise, actually use the right matrices. I'll try to explain below. This is the code you showed me:
D3DXMATRIX mWorld;
D3DXMatrixIdentity(&mWorld);
mWorldProjection = camera->getProjectionMatrix();
effect->SetMatrix( "mWV", &mWorld );
effect->SetMatrix( "mWVP", &mWorldProjection );
mWorld should be world * view, and mWorldProjection should be mWorld * your projection. What is the name of your matrix for viewspace? You don't seem to have any clue of what your own matrices are or what they do anyway. I think you need to go back and properly understand how transformation matrices are used to render 3D scenes.
Do you understand what a world matrix really is, and what a view matrix is?
WVP = world * view * projection. In simpleton terms, world refers to how individual content is transformed. View is how the virtual camera is positioned/oriented. Projection is how things are projected onto the screen plane. D3d9 abstracts these, but eventually it really just concatenates them into a single matrix and multiplies geometry by this to get it into its final position in camera space (pretty much screen space; the difference is somewhat trivial). So here, it asks for two matrices, WV and WVP. WV is world * view, and WVP is just WV * projection. Got it?
By the way, I may have thought of a good and fast way to do real volumetric lines, but I'll need to try it for myself before I start spewing nonsense.
Edited by Reflexus, 16 May 2013 - 11:46 AM.
#26 Medo3337 Members - Reputation: 683
Like
1Likes
Like
Posted 16 May 2013 - 12:11 PM
Great!
The transformation issue is now resolved, now I'm trying to draw all the lines with only a single draw call, so I tried changing the following code:
// The following code draw line per draw call (I don't want that)
TVertex vrts[4];
vrts[0].pos = v0; vrts[0].otherPos = v1;
vrts[1].pos = v1; vrts[1].otherPos = v0;
vrts[2].pos = v0; vrts[2].otherPos = v1;
vrts[3].pos = v1; vrts[3].otherPos = v0;
vrts[0].thickness = D3DXVECTOR3( -g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[1].thickness = D3DXVECTOR3( g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[2].thickness = D3DXVECTOR3( g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[3].thickness = D3DXVECTOR3( -g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[0].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.f, 0.f );
vrts[1].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.25f, 0.f );
vrts[2].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.f, 0.25f );
vrts[3].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.25f, 0.25f );
d3ddev->DrawPrimitiveUP( D3DPT_TRIANGLESTRIP, 2, vrts, sizeof( TVertex ) );
To:
// In this code, I'm trying to draw multiple lines with one single draw call
TVertex vrts[8]; // 8 instead of 4 (8 = 2 lines)
// Line 1
D3DXVECTOR3 v0(0.0f, 0.0f, 0.0f);
D3DXVECTOR3 v1(0.0f, 100.0f, 0.0f);
vrts[0].pos = v0; vrts[0].otherPos = v1;
vrts[1].pos = v1; vrts[1].otherPos = v0;
vrts[2].pos = v0; vrts[2].otherPos = v1;
vrts[3].pos = v1; vrts[3].otherPos = v0;
vrts[0].thickness = D3DXVECTOR3( -g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[1].thickness = D3DXVECTOR3( g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[2].thickness = D3DXVECTOR3( g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[3].thickness = D3DXVECTOR3( -g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[0].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.f, 0.f );
vrts[1].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.25f, 0.f );
vrts[2].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.f, 0.25f );
vrts[3].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.25f, 0.25f );
// Line 2
D3DXVECTOR3 pV0(200.0f, 0.0f, 0.0f);
D3DXVECTOR3 pV1(200.0f, 100.0f, 0.0f);
vrts[4].pos = pV0; vrts[4].otherPos = pV1;
vrts[5].pos = pV1; vrts[5].otherPos = pV0;
vrts[6].pos = pV0; vrts[6].otherPos = pV1;
vrts[7].pos = pV1; vrts[7].otherPos = pV0;
vrts[4].thickness = D3DXVECTOR3( -g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[5].thickness = D3DXVECTOR3( g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[6].thickness = D3DXVECTOR3( g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[7].thickness = D3DXVECTOR3( -g_fThickness, 0.f, g_fThickness * 0.5f );
vrts[4].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.f, 0.f );
vrts[5].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.25f, 0.f );
vrts[6].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.f, 0.25f );
vrts[7].texOffset = D3DXVECTOR4( g_fThickness, g_fThickness, 0.25f, 0.25f );
// Draw all lines
d3ddev->DrawPrimitiveUP( D3DPT_TRIANGLESTRIP, 4, vrts, sizeof( TVertex ) );
Now, the two lines are connected with each others, which of course undesired since I want to draw multiple separate lines with one draw call.
Do I have to set index buffer to draw multiple lines with one draw call? If yes, how do I fill the index buffer?
#27 Rhetorician Members - Reputation: 115
Like
0Likes
Like
Posted 16 May 2013 - 02:22 PM
No it's a triangle strip, so even with an index layer you can't specify breaks between the lines. Try to use a triangle list instead. For this I guess you can use http://msdn.microsoft.com/en-us/library/windows/desktop/bb174370%28v=vs.85%29.aspx
#28 Medo3337 Members - Reputation: 683
Like
0Likes
Like
Posted 16 May 2013 - 08:18 PM
I tried the following code, but it's not working as expected:
// Create index buffer
DWORD* index = new DWORD[indicesCount];
DWORD j = 0;
indexBuffer->Lock(0, sizeof(index), (void**)&index, 0);
for(USHORT i = 0; i < indicesCount; i += 6)
{
index[0+i] = 0+j;
index[1+i] = 2+j;
index[2+i] = 1+j;
index[3+i] = 0+j;
index[4+i] = 3+j;
index[5+i] = 2+j;
j += 4;
}
indexBuffer->Unlock();
// Draw
device->DrawIndexedPrimitiveUP( D3DPT_TRIANGLELIST, 0, 4, 2, indexBuffer, D3DFMT_INDEX32, vrts, sizeof( TVertex ) );
What's wrong?
Edited by Medo3337, 16 May 2013 - 08:28 PM.
#29 Rhetorician Members - Reputation: 115
Like
1Likes
Like
Posted 17 May 2013 - 04:24 PM
it's not working as expected:
I'll assume you don't know how to describe the problem. No, errors, it just looks funny, right?
1. The first issue I see is, to account for every line-segment you batch, make sure you do something like this (notice *lineNum):
device->DrawIndexedPrimitiveUP( D3DPT_TRIANGLELIST, 0, 4*lineNum, 2*lineNum, indexBuffer, D3DFMT_INDEX32, vrts, sizeof( TVertex ) );
Or you can increment a variable to use for the arguments, just as you probably do with 'vrts'.
2. Why are you making an allocation for the buffer? The following code you have written is unnecessary and bad: DWORD* index = new DWORD[indicesCount];
The Lock() function will modify your pointer to point somewhere used in the write-combining process. Not only is this memory allocation unnecessary, but you're creating a memory leak.
3. How do you determine "indicesCount" ?
4. My suggestions:
Construct your index layer in explicit terms of line segments. e.g.
uint i = 0;
uint vI = 0;
for (uint lineI = 0; lineI != lineQ; ++lineI)
{
index[i++] = vI;
index[i++] = vI + 2;
index[i++] = vI + 1;
index[i++] = vI + 1;
index[i++] = vI + 2;
index[i++] = vI + 3;
vI += 4;
}
indicesCount can be determined just like this: lineQ * 6;
Notation info: I have a personal habit of appending a capital letter i to denote an index and Q to denote a quantity.
Hopefully these tips get you somewhere. biggrin.png
Edited by Reflexus, 17 May 2013 - 04:27 PM.
#30 Norman Barrows Crossbones+ - Reputation: 3268
Like
0Likes
Like
Posted 17 May 2013 - 08:53 PM
if you can't get what you're working on going, check out the point sprite demo mentioned in one of the previous posts. its in the directx 8 sdk (and perhaps later ones). it REALLY looks nice! JUST what you want. <g>
not sure how they do it. they may be lines, or thin tri's with gradient texture and lots of emissive on the material. never looked at the code. but the demo is killer.
and if dx8 will do, dx9 will do it for sure.
Norm Barrows
Rockland Software Productions
"Building PC games since 1989"
rocklandsoftware.net
PLAY CAVEMAN NOW!
http://rocklandsoftware.net/beta.php
#31 Medo3337 Members - Reputation: 683
Like
0Likes
Like
Posted 19 May 2013 - 08:43 AM
@Reflexus: Are you sure this is a valid indices list for the volumetric lines?
It's not working.
#32 Rhetorician Members - Reputation: 115
Like
0Likes
Like
Posted 23 May 2013 - 04:51 PM
It's not working.
How so? Please explain the problem, as I asked before. I just left you with tips and example code to get you pointed in the right direction -- but it was a guess nevertheless -- because you have not explained the debugging results.
Edited by Reflexus, 23 May 2013 - 04:53 PM.
#33 Medo3337 Members - Reputation: 683
Like
0Likes
Like
Posted 23 May 2013 - 05:09 PM
The lines are deformed, it seems that the index buffer is not valid.
#34 Rhetorician Members - Reputation: 115
Like
0Likes
Like
Posted 23 May 2013 - 05:51 PM
So it doesn't have any crashing issues? (edit: Hey, I'm just expecting the worse laugh.png)
Edited by Reflexus, 23 May 2013 - 05:53 PM.
#35 Medo3337 Members - Reputation: 683
Like
0Likes
Like
Posted 23 May 2013 - 06:10 PM
No, nothing more than just deformed lines, you might want to look at the effect file to see how the indices should be like.
#36 Rhetorician Members - Reputation: 115
Like
0Likes
Like
Posted 23 May 2013 - 08:51 PM
you might want to look at the effect file to see how the indices should be like.
Really... If you're not sure how to get them right yourself, just try different combinations. Really. There aren't too many to try. You could have fixed it by now.
Edit: Oh, sorry. I sound sour. I am not able to help you further. My time!
Edited by Reflexus, 23 May 2013 - 08:52 PM.
#37 Medo3337 Members - Reputation: 683
Like
0Likes
Like
Posted 24 May 2013 - 06:27 AM
Yes, I have been trying to use different indices but couldn't get it to work.
Anyway, consider the question closed, I'll look for a way to resolve the issue.
#38 Medo3337 Members - Reputation: 683
Like
1Likes
Like
Posted 24 May 2013 - 09:16 AM
To anyone who could have this problem, the question was resolved here:
http://www.gamedev.net/topic/643414-drawing-multiple-lines-with-one-draw-call/
Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
PARTNERS
|
{
"url": "http://www.gamedev.net/topic/643071-sparks-effect/page-2",
"source_domain": "www.gamedev.net",
"snapshot_id": "crawl=CC-MAIN-2015-35",
"warc_metadata": {
"Content-Length": "149948",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:DCOX6YXFWCKBBOO5AVAXMTEXRUFUXQC5",
"WARC-Concurrent-To": "<urn:uuid:d55918d3-e651-4116-892e-53c7bf66593f>",
"WARC-Date": "2015-08-31T09:11:52Z",
"WARC-IP-Address": "64.91.255.13",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:IIRE5WVR7SV5USNWYRUOVTZ6SJWHBXEI",
"WARC-Record-ID": "<urn:uuid:5b4f3af1-3288-443a-b0ad-41a5c4ce72ea>",
"WARC-Target-URI": "http://www.gamedev.net/topic/643071-sparks-effect/page-2",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:bf533943-689a-41e3-98d7-c8e84dc88e34>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-171-96-226.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-35\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,
16,
17,
56,
75,
76,
265,
266,
267,
281,
282,
283,
294,
461,
462,
497,
522,
523,
570,
571,
576,
583,
588,
589,
619,
620,
736,
737,
739,
740,
794,
795,
797,
798,
1426,
1427,
1429,
1430,
1436,
1562,
1563,
1565,
1566,
1693,
1694,
1696,
1697,
1699,
1700,
1727,
1728,
1730,
1731,
1792,
1793,
1857,
1858,
1859,
1903,
1904,
1905,
1914,
1915,
1959,
1960,
1965,
1972,
1977,
1978,
2008,
2009,
2063,
2064,
2066,
2067,
2157,
2158,
2160,
2161,
2232,
2233,
2235,
2236,
2342,
2343,
2345,
2346,
2440,
2531,
2532,
2533,
2580,
2581,
2586,
2593,
2598,
2599,
2629,
2630,
2678,
2679,
2680,
2681,
2725,
2726,
2731,
2738,
2743,
2744,
2774,
2775,
2804,
2805,
2824,
2853,
2854,
2904,
2905,
2942,
2990,
2991,
3029,
3030,
3031,
3032,
3079,
3080,
3085,
3092,
3097,
3098,
3128,
3129,
3167,
3168,
3501,
3502,
3504,
3505,
3524,
3553,
3554,
3604,
3605,
3642,
3690,
3691,
3693,
3694,
4025,
4026,
4028,
4029,
4105,
4106,
4107,
4677,
4678,
4680,
4681,
4832,
4833,
4834,
4878,
4879,
4880,
4924,
4925,
4930,
4937,
4942,
4943,
4973,
4974,
4981,
4982,
4984,
4985,
5134,
5135,
5137,
5138,
5140,
5141,
5207,
5224,
5265,
5306,
5347,
5388,
5389,
5465,
5541,
5617,
5693,
5694,
5767,
5842,
5917,
5994,
5995,
6071,
6072,
6074,
6075,
6077,
6078,
6082,
6083,
6160,
6209,
6210,
6220,
6254,
6290,
6291,
6332,
6373,
6414,
6455,
6531,
6607,
6683,
6759,
6832,
6907,
6982,
7059,
7060,
7070,
7107,
7146,
7147,
7190,
7233,
7276,
7319,
7395,
7471,
7547,
7623,
7696,
7771,
7846,
7923,
7924,
7942,
8018,
8019,
8021,
8022,
8164,
8165,
8167,
8168,
8281,
8282,
8283,
8284,
8331,
8332,
8337,
8344,
8349,
8350,
8380,
8381,
8627,
8628,
8629,
8630,
8674,
8675,
8680,
8687,
8692,
8693,
8723,
8724,
8726,
8788,
8811,
8851,
8864,
8920,
8964,
8966,
8988,
9010,
9032,
9054,
9076,
9098,
9110,
9112,
9135,
9136,
9138,
9139,
9147,
9264,
9265,
9267,
9268,
9282,
9283,
9284,
9328,
9329,
9330,
9377,
9378,
9383,
9390,
9395,
9396,
9426,
9427,
9457,
9458,
9460,
9461,
9557,
9558,
9559,
9689,
9690,
9823,
9824,
9826,
9827,
9922,
9923,
9925,
9926,
10078,
10079,
10081,
10082,
10266,
10267,
10308,
10327,
10328,
10396,
10397,
10399,
10400,
10412,
10425,
10471,
10473,
10491,
10513,
10535,
10557,
10579,
10601,
10611,
10613,
10614,
10616,
10617,
10675,
10676,
10794,
10795,
10847,
10848,
10849,
10893,
10894,
10895,
10950,
10951,
10956,
10963,
10968,
10969,
10999,
11000,
11216,
11217,
11219,
11220,
11388,
11389,
11391,
11392,
11437,
11438,
11439,
11452,
11453,
11483,
11484,
11515,
11516,
11537,
11538,
11540,
11541,
11559,
11560,
11597,
11598,
11600,
11601,
11603,
11604,
11605,
11649,
11650,
11655,
11662,
11667,
11668,
11698,
11699,
11778,
11779,
11781,
11782,
11800,
11801,
11802,
11803,
11850,
11851,
11856,
11863,
11868,
11869,
11899,
11900,
11918,
11919,
11921,
11922,
12154,
12155,
12156,
12200,
12201,
12202,
12246,
12247,
12252,
12259,
12264,
12265,
12295,
12296,
12365,
12366,
12367,
12368,
12415,
12416,
12421,
12428,
12433,
12434,
12464,
12465,
12557,
12558,
12559,
12603,
12604,
12605,
12649,
12650,
12655,
12662,
12667,
12668,
12698,
12699,
12823,
12824,
12825,
12826,
12873,
12874,
12879,
12886,
12891,
12892,
12922,
12923,
13004,
13005,
13006,
13170,
13171,
13246,
13247,
13248,
13292,
13293,
13294,
13338,
13339,
13344,
13351,
13356,
13357,
13387,
13388,
13466,
13467,
13469,
13470,
13550,
13551,
13552,
13553,
13597,
13598,
13603,
13610,
13615,
13616,
13646,
13647,
13718,
13719,
13798,
13799,
13800,
13801,
13802,
13803,
13804,
13815,
13982,
13983,
13984,
13985
],
"line_end_idx": [
16,
17,
56,
75,
76,
265,
266,
267,
281,
282,
283,
294,
461,
462,
497,
522,
523,
570,
571,
576,
583,
588,
589,
619,
620,
736,
737,
739,
740,
794,
795,
797,
798,
1426,
1427,
1429,
1430,
1436,
1562,
1563,
1565,
1566,
1693,
1694,
1696,
1697,
1699,
1700,
1727,
1728,
1730,
1731,
1792,
1793,
1857,
1858,
1859,
1903,
1904,
1905,
1914,
1915,
1959,
1960,
1965,
1972,
1977,
1978,
2008,
2009,
2063,
2064,
2066,
2067,
2157,
2158,
2160,
2161,
2232,
2233,
2235,
2236,
2342,
2343,
2345,
2346,
2440,
2531,
2532,
2533,
2580,
2581,
2586,
2593,
2598,
2599,
2629,
2630,
2678,
2679,
2680,
2681,
2725,
2726,
2731,
2738,
2743,
2744,
2774,
2775,
2804,
2805,
2824,
2853,
2854,
2904,
2905,
2942,
2990,
2991,
3029,
3030,
3031,
3032,
3079,
3080,
3085,
3092,
3097,
3098,
3128,
3129,
3167,
3168,
3501,
3502,
3504,
3505,
3524,
3553,
3554,
3604,
3605,
3642,
3690,
3691,
3693,
3694,
4025,
4026,
4028,
4029,
4105,
4106,
4107,
4677,
4678,
4680,
4681,
4832,
4833,
4834,
4878,
4879,
4880,
4924,
4925,
4930,
4937,
4942,
4943,
4973,
4974,
4981,
4982,
4984,
4985,
5134,
5135,
5137,
5138,
5140,
5141,
5207,
5224,
5265,
5306,
5347,
5388,
5389,
5465,
5541,
5617,
5693,
5694,
5767,
5842,
5917,
5994,
5995,
6071,
6072,
6074,
6075,
6077,
6078,
6082,
6083,
6160,
6209,
6210,
6220,
6254,
6290,
6291,
6332,
6373,
6414,
6455,
6531,
6607,
6683,
6759,
6832,
6907,
6982,
7059,
7060,
7070,
7107,
7146,
7147,
7190,
7233,
7276,
7319,
7395,
7471,
7547,
7623,
7696,
7771,
7846,
7923,
7924,
7942,
8018,
8019,
8021,
8022,
8164,
8165,
8167,
8168,
8281,
8282,
8283,
8284,
8331,
8332,
8337,
8344,
8349,
8350,
8380,
8381,
8627,
8628,
8629,
8630,
8674,
8675,
8680,
8687,
8692,
8693,
8723,
8724,
8726,
8788,
8811,
8851,
8864,
8920,
8964,
8966,
8988,
9010,
9032,
9054,
9076,
9098,
9110,
9112,
9135,
9136,
9138,
9139,
9147,
9264,
9265,
9267,
9268,
9282,
9283,
9284,
9328,
9329,
9330,
9377,
9378,
9383,
9390,
9395,
9396,
9426,
9427,
9457,
9458,
9460,
9461,
9557,
9558,
9559,
9689,
9690,
9823,
9824,
9826,
9827,
9922,
9923,
9925,
9926,
10078,
10079,
10081,
10082,
10266,
10267,
10308,
10327,
10328,
10396,
10397,
10399,
10400,
10412,
10425,
10471,
10473,
10491,
10513,
10535,
10557,
10579,
10601,
10611,
10613,
10614,
10616,
10617,
10675,
10676,
10794,
10795,
10847,
10848,
10849,
10893,
10894,
10895,
10950,
10951,
10956,
10963,
10968,
10969,
10999,
11000,
11216,
11217,
11219,
11220,
11388,
11389,
11391,
11392,
11437,
11438,
11439,
11452,
11453,
11483,
11484,
11515,
11516,
11537,
11538,
11540,
11541,
11559,
11560,
11597,
11598,
11600,
11601,
11603,
11604,
11605,
11649,
11650,
11655,
11662,
11667,
11668,
11698,
11699,
11778,
11779,
11781,
11782,
11800,
11801,
11802,
11803,
11850,
11851,
11856,
11863,
11868,
11869,
11899,
11900,
11918,
11919,
11921,
11922,
12154,
12155,
12156,
12200,
12201,
12202,
12246,
12247,
12252,
12259,
12264,
12265,
12295,
12296,
12365,
12366,
12367,
12368,
12415,
12416,
12421,
12428,
12433,
12434,
12464,
12465,
12557,
12558,
12559,
12603,
12604,
12605,
12649,
12650,
12655,
12662,
12667,
12668,
12698,
12699,
12823,
12824,
12825,
12826,
12873,
12874,
12879,
12886,
12891,
12892,
12922,
12923,
13004,
13005,
13006,
13170,
13171,
13246,
13247,
13248,
13292,
13293,
13294,
13338,
13339,
13344,
13351,
13356,
13357,
13387,
13388,
13466,
13467,
13469,
13470,
13550,
13551,
13552,
13553,
13597,
13598,
13603,
13610,
13615,
13616,
13646,
13647,
13718,
13719,
13798,
13799,
13800,
13801,
13802,
13803,
13804,
13815,
13982,
13983,
13984,
13985,
13993
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 13993,
"ccnet_original_nlines": 539,
"rps_doc_curly_bracket": 0.0002858600055333227,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.23769253492355347,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.039867110550403595,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.40078526735305786,
"rps_doc_frac_unique_words": 0.31820499897003174,
"rps_doc_mean_word_length": 5.14686393737793,
"rps_doc_num_sentences": 244,
"rps_doc_symbol_to_word_ratio": 0.006342490203678608,
"rps_doc_unigram_entropy": 5.725264072418213,
"rps_doc_word_count": 1961,
"rps_doc_frac_chars_dupe_10grams": 0.2229267805814743,
"rps_doc_frac_chars_dupe_5grams": 0.3596552014350891,
"rps_doc_frac_chars_dupe_6grams": 0.30318042635917664,
"rps_doc_frac_chars_dupe_7grams": 0.2759338319301605,
"rps_doc_frac_chars_dupe_8grams": 0.26721489429473877,
"rps_doc_frac_chars_dupe_9grams": 0.22827701270580292,
"rps_doc_frac_chars_top_2gram": 0.017338750883936882,
"rps_doc_frac_chars_top_3gram": 0.01941940002143383,
"rps_doc_frac_chars_top_4gram": 0.02774200029671192,
"rps_doc_books_importance": -1384.20458984375,
"rps_doc_books_importance_length_correction": -1384.20458984375,
"rps_doc_openwebtext_importance": -733.3731689453125,
"rps_doc_openwebtext_importance_length_correction": -733.3731689453125,
"rps_doc_wikipedia_importance": -482.10308837890625,
"rps_doc_wikipedia_importance_length_correction": -482.10308837890625
},
"fasttext": {
"dclm": 0.1038544774055481,
"english": 0.8159751296043396,
"fineweb_edu_approx": 1.9311254024505615,
"eai_general_math": 0.4027140736579895,
"eai_open_web_math": 0.3432258367538452,
"eai_web_code": 0.006305749993771315
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.0151",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "005.436",
"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": "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": "2",
"label": "Partially Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
6,449,613,228,336,447,000
|
mahesh mahesh - 6 months ago 13
SQL Question
Difference between View and table in sql
Possible Duplicate:
Difference Between Views and Tables in Performance
Hi,
What is the main difference between view and table in sql. Is there any advantage of using views instead of tables.
Answer
A table contains data, a view is just a SELECT statement which has been saved in the database (more or less, depending on your database).
The advantage of a view is that it can join data from several tables thus creating a new view of it. Say you have a database with salaries and you need to do some complex statistical queries on it.
Instead of sending the complex query to the database all the time, you can save the query as a view and then SELECT * FROM view
|
{
"url": "https://codedump.io/share/5KS4675iwVVx/1/difference-between-view-and-table-in-sql",
"source_domain": "codedump.io",
"snapshot_id": "crawl=CC-MAIN-2016-50",
"warc_metadata": {
"Content-Length": "30306",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4JCAHHNWM7RPZF74IUWJTAOXYCLACALT",
"WARC-Concurrent-To": "<urn:uuid:13fb276a-e768-4c92-8200-94e0ecc41543>",
"WARC-Date": "2016-12-07T16:49:59Z",
"WARC-IP-Address": "84.22.103.185",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:2AX5EK52L2B3G6JCY2XJMPIVG4HP72WO",
"WARC-Record-ID": "<urn:uuid:52ad6de8-29cb-4664-a012-af1e895918d2>",
"WARC-Target-URI": "https://codedump.io/share/5KS4675iwVVx/1/difference-between-view-and-table-in-sql",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ede168b5-ee00-446f-ab47-b0889c981f72>"
},
"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,
32,
45,
46,
87,
88,
89,
109,
110,
161,
162,
163,
164,
165,
169,
170,
286,
287,
294,
295,
433,
434,
632,
633
],
"line_end_idx": [
32,
45,
46,
87,
88,
89,
109,
110,
161,
162,
163,
164,
165,
169,
170,
286,
287,
294,
295,
433,
434,
632,
633,
760
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 760,
"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.463087260723114,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03355704993009567,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.10067114233970642,
"rps_doc_frac_unique_words": 0.5514705777168274,
"rps_doc_mean_word_length": 4.382352828979492,
"rps_doc_num_sentences": 6,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.079563617706299,
"rps_doc_word_count": 136,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.11409395933151245,
"rps_doc_frac_chars_dupe_6grams": 0.11409395933151245,
"rps_doc_frac_chars_dupe_7grams": 0.11409395933151245,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.08557046949863434,
"rps_doc_frac_chars_top_3gram": 0.07046979665756226,
"rps_doc_frac_chars_top_4gram": 0.08053690940141678,
"rps_doc_books_importance": -82.15902709960938,
"rps_doc_books_importance_length_correction": -82.15902709960938,
"rps_doc_openwebtext_importance": -40.22915267944336,
"rps_doc_openwebtext_importance_length_correction": -40.22915267944336,
"rps_doc_wikipedia_importance": -29.93902587890625,
"rps_doc_wikipedia_importance_length_correction": -29.939027786254883
},
"fasttext": {
"dclm": 0.9953411221504211,
"english": 0.9289783835411072,
"fineweb_edu_approx": 2.4935824871063232,
"eai_general_math": 0.37404191493988037,
"eai_open_web_math": 0.04279344901442528,
"eai_web_code": 0.12922638654708862
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.746",
"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": "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": "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": "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,507,099,256,107,272,000
|
Search Images Maps Play YouTube News Gmail Drive More »
Sign in
Screen reader users: click this link for accessible mode. Accessible mode has the same essential features but works better with your reader.
Patents
1. Advanced Patent Search
Publication numberUS6289333 B1
Publication typeGrant
Application numberUS 09/196,892
Publication dateSep 11, 2001
Filing dateNov 20, 1998
Priority dateJan 16, 1998
Fee statusPaid
Publication number09196892, 196892, US 6289333 B1, US 6289333B1, US-B1-6289333, US6289333 B1, US6289333B1
InventorsJanardhanan Jawahar, Venkatachari Dilip
Original AssigneeAspect Communications Corp.
Export CitationBiBTeX, EndNote, RefMan
External Links: USPTO, USPTO Assignment, Espacenet
Methods and apparatus enabling dynamic resource collaboration when collaboration session host is distinct from resource host
US 6289333 B1
Abstract
Methods and apparatus for enabling collaboration between clients with respect to dynamic resources are described. The method includes the step of establishing a collaboration session between a first client and a second client through a session host. A first client request having a first uniform resource locator (URL) identifying a host other than the session host is re-directed through the session host. In one embodiment, the retrieved resource is modified such that for each embedded request identifying a host other than the session host, its associated embedded URL is replaced with a re-directed URL incorporating the embedded URL. The re-directed URL re-directs the corresponding request for a resource identified by the embedded URL through the session host. In an alternative embodiment, the retrieved resource is not modified. In either embodiment, the resulting resource is cached if necessary (e.g., when the resource is dynamic). In one embodiment, an expiration date of the retrieved resource indicates whether the resource is dynamic. In another embodiment, the retrieved resource is presumed dynamic if the first client request includes at least one of a POST, PUT, DELETE, LINK, and an UNLINK hypertext transfer protocol (HTTP) command. The resulting resource is then provided to the first client. The second client is provided with a second URL that identifies either the requested resource or the cached resource depending upon whether caching was necessary.
Images(17)
Previous page
Next page
Claims(20)
What is claimed is:
1. A method comprising the steps of:
a) establishing a collaboration session between a first client and a second client with a session host;
b) re-directing a first client request having a first uniform resource locator (URL) through the session host, if the first URL identifies a host other than the session host; and
c) caching a resource retrieved by the session host in response to the re-directed request as a cached resource at the session host, if at least one of the first request and the retrieved resource has a pre-determined characteristic.
2. The method of claim 1 wherein the cached resource is a dynamic web page.
3. The method of claim 1 wherein the retrieved resource is cached if the first request includes at least one of a POST, PUT, DELETE, LINK, HEAD, and an UNLINK hypertext transfer protocol (HTTP) command.
4. The method of claim 1 wherein the retrieved resource is cached if an expiration date of the retrieved resource indicates that the retrieved resource is dynamic.
5. The method of claim 1 further comprising the step of:
d) providing the retrieved resource to the first client.
6. The method of claim 5 wherein step d) further comprises the step of:
i) embedding a second URL in the retrieved resource before providing the retrieved resource to the first client, wherein the second URL is the same as the first URL if the retrieved resource is not cached, wherein the second URL identifies the cached resource if the retrieved resource is cached.
7. The method of claim 6 wherein a browser application of the first client generates the first client request, wherein a first client re-direction application modifies the first client request to re-direct the first client request through the session host if the first URL identifies a host other than the session host, wherein the first client browser application communicates the second URL to a browser application of the second client.
8. The method of claim 1 further comprising the step of:
d) providing the second client with a second URL, wherein the second URL is the same as the first URL if the retrieved resource is not cached, wherein the second URL identifies the cached resource if the retrieved resource is cached.
9. The method of claim 1 wherein step b) further comprises the steps of modifying the first client request to form a second URL incorporating the first client request, wherein the second URL redirects the first client request including the first URL through the session host.
10. An apparatus comprising storage medium storing instructions forming a client re-direction application, wherein when executed in conjunction with a browser application of a first client, the client re-direction application communicates with the browser application, wherein during a collaboration session between the first client and a second client through a session host, the client re-direction application issues a re-direction request in response to a selected first client request having a uniform resource locator (URL) identifying a host other than the session host, wherein the re-direction request incorporates the first request, wherein the re-direction request causes the session host to issue the selected first client requests wherein the session host caches a retrieved resource if one of the retrieved resource and the URL has a pre-determined characteristic identified by the stored instructions.
11. An apparatus comprising a browser application including a re-direction application for establishing a collaboration session through a session host, wherein in response to a selected request to access a host other than the session host, the re-direction application re-directs the selected request through the session host, wherein the session host caches a retrieved resource if one of the retrieved resource and selected request has a predetermined characteristic.
12. A method comprising the steps of:
a) establishing a collaboration session between a first client and a second client with a session host; and
b) retrieving a requested resource from a resource host to a session host in response to a first client request having a first uniform resource locator (URL), if the first URL identifies a resource host other than the session host; and
c) modifying the retrieved resource, wherein for each embedded request identifying a host other than the session host an associated embedded URL of the embedded request is replaced with a re-directed URL incorporating the embedded URL, wherein the re-directed URL re-directs the corresponding request for a resource identified by the embedded URL through the session host.
13. The method of claim 12 further comprising the step of:
d) caching the modified resource if at least one of the first request and the retrieved resource has a specified characteristic.
14. The method of claim 13 wherein the modified resource is cached if the retrieved resource is a dynamic resource.
15. The method of claim 14 wherein an expiration date of the retrieved resource indicates whether the retrieved resource is a dynamic resource.
16. The method of claim 14 wherein the modified resource is cached if the retrieved resource is associated with a filename having a selected characteristic.
17. The method of claim 13 wherein the modified resource is cached if the first request includes at least one of a POST, PUT, DELETE, LINK, and an UNLINK hypertext transfer protocol (HTTP) command.
18. The method of claim 13 further comprising the step of:
e) providing the modified resource to the first client.
19. The method of claim 18 wherein steps c)-e) are performed by the session host.
20. The method of claim 18 further comprising the step of:
f) providing a second URL to the second client, wherein the second URL identifies the cached modified resource if the modified resource was cached, wherein the second URL is the same as the first URL if the modified resource was not cached.
Description
CROSS-REFERENCE TO RELATED APPLICATIONS
This application is a continuation-in-part of application Ser. No. 09/008,523, filed Jan. 16, 1998, abandoned.
FIELD OF THE INVENTION
The present invention relates to data communication. In particular, the invention is drawn to methods and apparatus to enable the monitoring of accessed information.
BACKGROUND
Systems are available that allow an individual to search for information and conduct transactions. For example, an individual may use a web browser application to search for information stored on web servers in the form of web pages. Additionally, a web browser application can be used to conduct transactions (such as bank transactions) across the Internet. Various other types of systems and applications may be used to search for information and conduct transactions.
When an individual is searching for specific information or executing a transaction, the web pages or other information sources may not provide the specific information desired by the individual. In this situation, the individual may continue searching other information sources using the same searching system or application. Alternatively, the individual may attempt to search for the desired information using a different searching system or application. For example, if the individual is unable to locate the desired information at a particular web site, the individual may try searching at a different web site or may try searching through product brochures for the desired information.
These existing systems typically provide minimal feedback to the source of the information (e.g., the organization responsible for the web server or web page) regarding the success or failure of the individual's search results. Generally, the individual does not have any options for assistance except by initiating a communication (such as a telephone call) to the organization responsible for the web page or by searching at another information source. If the individual contacts the organization responsible for the web server or web page, the representative of the organization will initially be unfamiliar with the information already obtained by the individual. Additionally, the representative will initially be unfamiliar with the number of web pages viewed and the time spent viewing each web page. Further, the representative that receives the telephone call may not have the required knowledge or expertise to provide the required information to the individual. In this situation, the individual may need to talk to another representative having the appropriate knowledge and expertise. This procedure can be tedious and time-consuming for the individual.
One method of tracking web server and other information source accesses involves logging the occurrence of an access and the identity of the resource accessed. If the resource is static, the representative has a record of which resources were accessed and can recreate the access in order to aid the individual, for example, by viewing the static results of the access while communicating with the individual. The representative may still have no information on the length of time or number of times that the static resource (e.g., a static web page) was visited. In the case of a dynamic resource (e.g., a dynamically generated web page) the representative is additionally unlikely to be able to recreate or analyze the accessed information.
SUMMARY OF THE INVENTION
Methods and apparatus for enabling collaboration between clients with respect to dynamic resources provided by hosts other than the session host responsible for the collaboration session are described.
In one embodiment, the method includes the step of establishing a collaboration session between a first client and a second client through a session host. A first client request having a first uniform resource locator (URL) identifying a host other than the session host is re-directed through the session host. The session host caches a retrieved resource provided from the other host in response to the re-directed request, if necessary. The retrieved resource is then provided to the first client. The second client is provided with a second URL. The second URL is the same as the first URL if the retrieved resource is not cached. The second URL identifies the cached resource, if the retrieved resource was cached.
In another embodiment the method includes the step of establishing a collaboration session between first and second clients with a session host. The session host retrieves a requested resource from a resource host in response to a first client request having a first URL identifying a resource host other than the session host. The retrieved resource is modified such that for each embedded request identifying a host other than the session host, its associated embedded URL is replaced with a re-directed URL incorporating the embedded URL. The re-directed URL re-directs the corresponding request for a resource identified by the embedded URL through the session host. The modified resource may then be cached if necessary. The modified resource is then provided to the first client. A second URL is provided to the second client. The second URL identifies one of the requested resource or the cached modified resource depending upon whether the modified resource was cached.
BRIEF DESCRIPTION OF THE DRAWINGS
The present invention is illustrated by way of example in the following drawings in which like references indicate similar elements. The following drawings disclose various embodiments of the present invention for purposes of illustration only and are not intended to limit the scope of the invention.
FIG. 1 illustrates an embodiment of a transaction processing environment in which the present invention may be used.
FIG. 2 illustrates an embodiment of a transaction processing environment including a server, an agent computer system, a customer computer system, and a transaction processing system coupled together using various networks.
FIG. 3 illustrates an embodiment of a control server.
FIG. 4 illustrates an embodiment of a system architecture for communicating information between various devices in a transaction processing environment.
FIG. 5 is a flow diagram illustrating an embodiment of a procedure for communicating information between various devices using the architecture of FIG. 4.
FIG. 6 illustrates an embodiment of various windows displayed to an agent using the agent's computer.
FIGS. 7A and 7B illustrate an embodiment of a procedure for monitoring web page access.
FIG. 8 is a flow diagram illustrating an embodiment of a procedure for determining whether to display a “Help” button (or other assistance icon) to a user.
FIG. 9 is a flow diagram illustrating an embodiment of a procedure for selecting an agent to provide help to a user.
FIG. 10 illustrates an embodiment of a table containing information relating to web pages accessed by a user.
FIG. 11 illustrates a method to enable dynamic resource collaboration between an agent and a customer.
FIG. 12 illustrates a transaction processing environment having a session management host distinct from a resource host.
FIG. 13 illustrates a method of dynamic resource collaboration when the session host is distinct from the resource host.
FIG. 14 illustrates an alternative method of dynamic resource collaboration when the session host is distinct from the resource host.
FIG. 15 illustrates an embodiment of a computer system that can be used with the present invention.
DETAILED DESCRIPTION
The following detailed description sets forth numerous specific details o provide a thorough understanding of the invention. However, those of ordinary skill in the art will appreciate that the invention may be practiced without these specific details. In other instances, well-known methods, procedures, protocols, components, algorithms, and circuits have not been described in detail so as not to obscure the invention.
The present description is related to a system capable of monitoring an individual's access to information contained in a web server or other information storage mechanism. Various embodiments also provide a system that selectively displays an assistance icon to an individual. The assistance icon provides the individual with an opportunity to request assistance from an agent or other individual associated with the information being viewed by the individual. By monitoring an individual's access to information, the source of the information is able to determine whether to offer help to the individual. If the individual is offered help, and requests help, the prior information accessed by the individual can be used to select an agent to assist the individual. The teachings can be used with any type of system in which an agent or other representative is able to communicate with a customer or other individual or system.
Particular embodiments are described below as used in a transaction processing environment. However, the teachings may be used in any data communication environment and with any type of data communication system. The embodiments described below communicate information (such as web page information) across a network. In alternate embodiments, the teachings may be applied to the communication of other types of information across other types of communication links.
Exemplary transactions in a transaction processing environment include telephone calls, facsimile transmissions, electronic mail (e-mail), video sessions, or network sessions (such as an Internet session). A particular transaction can be either inbound (e.g., received by a transaction processing system) or outbound (e.g., transmitted from a transaction processing system).
A transaction processing system is any device capable of receiving, transmitting, queuing, routing, or otherwise processing a transaction. A transaction processing system may also handle mixed transactions (e.g., receive a telephone call and respond to the telephone call using e-mail). Example transaction processing systems include automatic call distributors (ACDs), call centers, and other telephone call processing devices. The teachings of the present invention may be used with any type of transaction processing system.
FIG. 1 illustrates an embodiment of a transaction processing environment in which the present invention may be used. The transaction processing environment of FIG. 1 allows transaction initiators (e.g., customers) to contact an agent (e.g., a customer service agent) using various types of transactions. Similarly, the transaction processing environment allows an agent to respond to a received transaction (e.g., received from a customer) or initiate a new transaction.
A transaction processing system 10 is coupled to a server 12, a public switched telephone network (PSTN) 14 and a local area network (LAN) 16. Transaction processing system 10 is capable of processing various types of transactions, such as telephone calls, electronic mail (e-mail), voice mail, and facsimiles. Transaction processing system 10 is capable of receiving transactions from PSTN 14, LAN 16, and server 12. Similarly, transaction processing system 10 is capable of transmitting transactions to PSTN 14, LAN16, and server 12. For example, transaction processing system 10 can receive an incoming telephone call directly via PSTN 14. Another incoming telephone call may be received by server 12 (e.g., an Internet telephone call received across Internet 18) and provided to transaction processing system 10 across a communication link 34 or across LAN 16. In other situations, transaction processing system 10 may receive an incoming e-mail from server 12 or LAN 16.
FIG. 1 illustrates a single server 12 capable of interacting with various components in the transaction processing environment. For example, server 12 may operate as a web server, an e-mail server, a fax server, and a video server. Additionally, server 12 can perform the functions of a control server, as discussed below. In alternate embodiments of the invention, the transaction processing environment may include multiple servers, in which each server is responsible for one or more types of transactions. For example, a web server processes all web-based transactions, an e-mail/fax server processes all e-mail and facsimile transactions, and a control server controls and manages various transactions and communication sessions in the transaction processing environment.
LAN 16 can be any type of network, including an intranet network, capable of communicating information between various nodes in the network. Further, LAN 16 may use any network topology and communicate data using any communication protocol. As shown in FIG. 1, multiple agents 20 are coupled to LAN 16. In a typical transaction processing environment, hundreds or thousands of agents may be coupled to one or more LANs 16, which are coupled to transaction processing system 10. Alternatively, some or all of the agents 20 may be coupled directly to transaction processing system 10, rather than coupled through LAN 16. Although agents 20 are represented in FIG. 1 by a computer, a particular agent 20 may utilize any type of device or system that allows interaction between the agent and another person or device (such as a customer or a customer's computer). For example, an agent handling only telephone call transactions may only use a telephone system, without requiring a computer. Similarly, an agent handling only e-mail messages may require a computer system, but not a telephone. In a particular embodiment of the invention, each agent has a computer system and a telephone (which may be integrated into the computer system), such that the agent is capable of handling and responding to multiple types of transactions (e.g., telephone calls, e-mail, voice mail, and facsimiles).
An agent 32 is not coupled to LAN 16, but instead is coupled to PSTN 14. Agents 20, discussed above, are located locally to transaction processing system 10 or include an access mechanism allowing agents 20 to establish a connection to LAN 16. Agent 32 is a remote agent or otherwise unable to directly connect to LAN 16. For example, agent 32 may be working at a location geographically distant from transaction processing system 10, such as working at home or traveling. Agent 32 establishes a connection with transaction processing system 10 across PSTN 14. Alternatively, agent 32 may connect with LAN 16 or transaction processing system 10 through Internet 18 or any other network or communication system.
A database 30 is coupled to LAN 16 and is used by transaction processing system 10, agents 20 and 32, and server 12 to store and retrieve various types of information. For example, database 30 may contain information about the transaction processing system, the performance of the system, and the agents and customers that use transaction processing system 10. Since database 30 is coupled to LAN 16, all agent computers, servers, and other devices coupled to LAN 16 are capable of storing and retrieving information from the database.
As shown in FIG. 1, Internet 18 is coupled to server 12 and customer computers 22 and 24. Customer computer 22 may include an Internet phone for establishing verbal communications between the customer and an agent across Internet 18. The customer using computer 24 has a telephone 28 and a fax machine 26 coupled to PSTN 14 and located near computer 24. Thus, the user of computer 24 may communicate with an agent of the transaction processing system using Internet 18 (e.g., using an Internet phone or e-mail application), fax machine 26, telephone 28, or any combination thereof. For example, customer 24 may generate and transmit an e-mail message across Internet 18 to server 12. Server 12 then communicates the e-mail to transaction processing system 10, which provides the e-mail to a particular agent or group of agents for response. Agents may be grouped together based on area of expertise, company department, or type of support provided (e.g., sales or technical support). The agent responding to the e-mail can respond with another e-mail message or may respond by telephone, facsimile, or any other type of transaction supported by the transaction processing system and the transaction initiator. In particular embodiments of the invention, the transaction initiator may specify the type of transaction used by the responding agent. For example, a transaction initiator may generate an e-mail transaction, but request that an agent respond with a telephone call. Although customer computers 22 and 24 are shown coupled directly to Internet 18, it will be appreciated that any communication mechanism can be used to couple computers 22 and 24 to Internet 18, such as PSTN 14 and an internet Service Provider (ISP). In alternate embodiments, Internet 18 may be replaced with any communication network using any communication protocol.
The environment illustrated in FIG. 1 includes a separate LAN 16 and Internet 18. In alternate environments, LAN 16 and Internet 18 are merged into a single communication network capable of communicating information between any two or more devices coupled to the communication network.
FIG. 2 illustrates an embodiment of a transaction processing environment including a server 40, an agent computer system 50, a customer computer system 52, and a transaction processing system 42 coupled together using various networks. FIG. 2 illustrates a single agent computer system 50 and a single customer computer system 52. However, a typical transaction processing environment includes multiple agent computer systems and multiple customer computer systems. Server 40 is coupled to Internet 44, a LAN 46, and transaction processing system 42. Server 40 includes a database management server 60, an application server 62, a control server 64, and a web server 66. Additional details regarding server 40 are discussed below. In alternate embodiments, server 40, computer systems 50 and 52, and transaction processing system 42 are coupled together using different network configurations and network connections. Transaction processing system 42 is capable of processing various types of transactions, such as telephone calls, e-mail, voice mail, and facsimiles. In a particular embodiment of the invention, transaction processing system 42 is an automatic call distributor (ACD).
Agent computer system 50 includes an agent application 70, a browser application 72, and a telephony application 74. Agent application 70 interacts with other devices shown in FIG. 2 (e.g., server 40 and transaction processing system 42). For example, agent application 70 may retrieve information about a transaction initiator (such as account information and the types of products or services purchased) and display that information to the agent. In this example, agent application 70 is a client of database management server 60, which retrieves the appropriate information about the transaction initiator from a database 58. If the agent is a technical support agent, the information about the transaction initiator may include the types of products owned by the transaction initiator, previous problems encountered by the transaction initiator, and known problems with the products. Additionally, agent application 70 can display information regarding agent performance, the overall performance of the transaction processing system, and the current status of the agent (e.g., active or inactive).
Browser application 72 is any browser capable of communicating information across a communication link and displaying received information to the agent. In a particular embodiment, browser application 72 is capable of retrieving information from Internet 44 (e.g., in the form of Hypertext Markup Language (HTML) pages). Exemplary browser applications include Netscape Communicator™ sold by Netscape Communications Corporation of Mountain View, Calif., and Internet Explorer™ sold by Microsoft Corporation of Redmond, Wash. Embodiments of the invention exchange information between agent application 70 and browser application 72. In other embodiments of the invention, agent application 70 and browser application 72 are integrated into a single application.
Telephony application 74 controls a telephone 54 coupled to agent computer system 50 and transaction processing system 42. In other embodiments of the invention, a telephone adapter replaces telephone 54 and permits agent computer system 50 to perform the functions of a conventional telephone. For example, a WinSet™ adapter sold by Aspect Telecommunications of San Jose, Calif., may be used instead of telephone 54. Another embodiment of the invention uses a software-based telephone in place of telephone 54. In this embodiment, the software-based telephone is integrated into telephony application 74 and communicates with transaction processing system 42 through server 40 or LAN 46.
Customer computer system 52 includes a client application 76, a browser application 78, and an Internet phone application 80. Client application 76 may be any type of application capable of being executed by customer computer system 52. For example, client application 76 can be a word processor from which text is copied to browser application 78. Although FIG. 2 illustrates client application 76 and browser application 78 coupled to one another, in alternate embodiments of the invention there is no direct coupling of client application 76 and browser application 78.
Browser application 78 is any browser capable of communicating information across a communication link and displaying received information to the customer. Browser application 78 is not necessarily the same type of browser application used in agent computer system 50. In a particular embodiment, browser application 72 is capable of retrieving information from Internet 44 (e.g., in the form of Hypertext Markup Language (HTML) pages). Exemplary browser applications include Netscape Communicator™ and Internet Explorer™, identified above. Embodiments of the present invention can be implemented without any interaction between browser application 78 and other applications executed by customer computer system 52.
Internet phone application 80 allows the user of computer system 52 to establish a voice communication link across Internet 44 instead of using a telephone 56 and a PSTN 48. In particular embodiments of the invention, customer computer system 52 does not contain an Internet phone application. In these embodiments, the user of computer system 52 uses telephone 56 and PSTN 48 to establish a voice communication link with another individual or system. Alternatively, the user of computer system 52 may use a text chat window, discussed below with respect to FIG. 6, to communicate with another individual or system.
Database management server 60 (contained in server 40) manages information contained in database 58. The information stored in database 58 includes customer information, product or service information, transaction tracking information, and other data that may be used by transaction processing system 42, agents, customers, or server 40. Application server 62 communicates with database management server 60 and provides information to agent application 70. For example, application server 62 can retrieve information about a customer from database 58 using database management server 60. The retrieved information is then provided to agent application 70 across LAN 46 for display on agent computer system 50.
Control server 64 performs multiple control and management functions, as discussed in greater detail below with respect to FIG. 3. Control server 64 establishes and maintains communication links between multiple pairs of agents and customers. Control server 64 communicates with transaction processing system 42 to locate one or more available agents, establishes data and/or voice connections between agents and customers, and controls the flow of data between agents and customers.
Web server 66 communicates data, in the form of web pages, to browser applications 72 and 78. Additionally, web server 66 stores web pages and other web-based information used by the devices in the transaction processing environment. In alternative embodiments, the functionality of the control server 64 may be incorporated into web server 66. When the web server 66 is a portion of a host system providing content and other requested resources, the host system may be referred to as a resource host. When the web server 66 is used primarily for maintaining the collaboration session between agents and customers, the host system may be referred to as a session host.
Web server 66 includes a filter service 68 that filters and modifies various web pages. Filter service 68 changes the web page content (e.g., by adding JavaScript methods) to allow the coordination and exchange of information between browser applications 72 and 78.
For example, if a customer using browser application 78 changes information on a web page by entering information on a form, the information entered by the customer may be communicated to the agent's browser application 72. Similarly, if an agent selects a different web page using browser application 72, the selected web page may be delivered to browser application 78 for viewing by the customer. Thus, the changes made to the web page by filter service 68 allow other services, discussed below, to coordinate web pages and web page information between browser applications 72 and 78 such that the agent and the customer view the same web page with the same information. Additional details regarding the various services that coordinate and exchange information between the browser applications are provided below with respect to FIGS. 3 and 4.
FIG. 3 illustrates an embodiment of control server 64, shown as part of server 40 in FIG. 2. Control server 64 is shown coupled to an e-mail server 90, a fax server 92, a video server 94, and transaction processing system 42. E-mail server 90 handles both incoming e-mail (e.g., from a customer) and outgoing e-mail (e.g., from an agent). Fax server 92 handles both incoming and outgoing facsimiles. Video server 94 handles video information and video sessions, for use by an agent, customer, or other device or user in the transaction processing environment. Additionally, video server 94 handles other multimedia information and multimedia sessions (e.g., sessions that exchange both audio and video data). Transaction processing system 42 handles various transactions, as discussed above. E-mail server 90, fax server 92, and video server 94 may be coupled directly to control server 64 (and server 40 shown in FIG. 2) or coupled to control server 64 through a network (e.g., LAN 46) or other communication medium. In alternate embodiments of the invention, any one or more of servers 90-94 can be contained within server 40 (FIG. 2) and coupled directly to control server 64.
Control server 64 communicates with e-mail server 90, fax server 92, and video server 94 using any type of communication medium, such as LAN 46. In this embodiment of the invention, control server 64 communicates with transaction processing system 42 using a dedicated communication line, as shown in FIG. 2. In alternate embodiments of the invention, control server 64 communicates with transaction processing system 42 across a network, such as LAN 46 (FIG. 2). Control server 64 also communicates with other systems, such as browser applications and web servers, using a communication link 96. In an embodiment of the invention, communication link 96 is a network communication link (e.g., a communication link in LAN 46). Alternatively, communication link 96 may be a dedicated communication link to one or more devices in the transaction processing environment. Communication link 96 is used to communicate various commands and other information between control server 64 and other devices.
As shown in FIG. 3, control server 64 includes an active script module 110 that handles the display of scripts and other information to an agent using the agent's browser application 72. An embodiment of active script module 110 generates scripts in the form of web pages that can be displayed on the agent's browser application. Additional details regarding agent scripts and other information displayed using an agent's browser application are provided below with respect to FIG. 6.
A data logging and reporting module 112 controls the storage (or logging) of transaction information in database 58 using database management server 60. Additionally, module 112 is capable of generating various types of reports summarizing or identifying performance characteristics and other information related to the transaction processing environment. For example, module 112 may generate reports detailing the overall transaction handling performance, such as the number of transactions handled per hour, the average response time for each type of transaction, and the number of transaction responses that exceeded a quality of service limit for the transaction.
A central control module 98 includes a transaction management interface 100, a transaction host 102, a synchronization service 104, a messaging service 106, and a server core 108. Server core 108 receives new requests (e.g., on communication link 96) from other devices in the transaction processing environment and provides the request to one or more other modules for processing. For example, server core 108 may continuously monitor communication link 96 for request signals that can be handled by server core 108. If the request signal is a request to generate a performance report, server core 108 forwards the request to data logging and reporting module 112 for processing. Module 112 then generates the requested report and provides the report to server core 108, which communicates the report to the appropriate device via communication link 96. Similarly, if the request signal is a request for an agent script, server core 108 forwards the request to active script module 110, which selects or generates an appropriate agent script. Module 110 provides the agent script to server core 108, which then communicates the agent script to the appropriate device (e.g., the requesting device).
Requests that cannot be handled by active script module 110 or data logging and reporting module 112 are communicated to another portion of central control module 98 for processing. Messaging service 106 establishes and manages message types used to communicate information between two or more individuals or devices in a transaction processing environment (e.g., message types used to communicate information between an agent and a customer). After a communication link has been established between, for example, an agent and a customer, messaging service 106 maintains the network or communication addresses for both the agent and customer. Typically, messaging service 106 establishes and manages multiple communication links for multiple customer-agent communications.
Synchronization service 104 synchronizes changes between all participants in a particular communication. For example, in an agent-customer communication, any changes entered to a web page by the customer are identified by synchronization service 104, and provided to the agent's browser application. Thus, synchronization service 104 ensures that all participants in a communication are provided with the same information.
Transaction host 102 manages various portions of the interaction between, for example, an agent and a customer. Transaction host 102 maintains the status of multiple interactions and maintains the identity (such as the network or communication address) of each participant involved in each interaction. If a request is received to provide information to a participant, then transaction host 102 determines the address associated with the participant and provides the address to the appropriate module responsible for providing the requested information.
Transaction management interface 100 is coupled to an e-mail transaction manager 114, a fax transaction manager 116, a video transaction manager 118, and a transaction processing system manager 120. Transaction management interface 100 manages the interaction and exchange of information between central control module 98 and the various transaction managers 114-120. Each transaction manager 114-120 handles a particular type of transaction, and communicates with the server responsible for that transaction type. In alternate embodiments of the invention, two or more of transaction managers 114-120 are combined into a single transaction manager. When server core 108 receives a request that requires interaction with a server or device external to control server 64, then transaction management interface 100 contacts the appropriate transaction manager for processing the request. For example, if server core 108 receives a request to select an agent to handle a transaction, then transaction management interface 100 contacts transaction processing system manager 120 to request an agent from transaction processing system 42.
Transaction management interface 100 may receive requests (or calls for service) from server core 108 or transaction host 102. Additionally, transaction management interface 100 may receive requests from any transaction manager 114-120. For example, e-mail transaction manager 114 may notify transaction management interface 100 that e-mail server 90 has received an e-mail that requires processing. Transaction management interface 100 then communicates the information regarding the received e-mail to other services or managers to determine how the e-mail should be handled. For example, transaction processing system manager 120 may be contacted to identify an agent to handle the e-mail. The manner in which the e-mail is to be handled is then communicated to e-mail transaction manager 114, which then instructs e-mail server 90 regarding the processing of the e-mail.
FIG. 4 illustrates an embodiment of a system architecture for communicating information between various devices in a transaction processing environment. The system architecture of FIG. 4 includes a control server 130, an agent computer 132, and a customer computer 134. Agent computer 132 is coupled to control server 130 via communication link 138 (e.g., LAN 46 in FIG. 2) and coupled to a web server 136 via communication link 143 (e.g., Internet 44). Customer computer 134 is coupled to control server 130 using communication link 140 (e.g., Internet 44 in FIG. 2). Customer computer 134 is also coupled to web server 136 via communication link 142 (e.g., Internet 44). Web server 136 stores and distributes various web pages requested by a browser application. Although web server 136 and control server 130 are shown as two separate servers in FIG. 4, they may be hosted by the same hardware or the same server system.
Agent computer 132 contains a browser application 144 of the type discussed above with respect to FIG. 2. The embodiment of the system architecture shown in FIG. 4 is implemented using the Java T™ programming language (Java is a trademark of Sun Microsystems Inc. of Mountain View, Calif.). Alternate embodiments of the invention may be implemented using other programming languages, including object-oriented programming languages. Agent computer 132 contains one or more JavaScript methods 146 and one or more Java applets 148. A JavaScript method is a sequence of instructions that perform various operations and have the ability to invoke Java methods. A Java applet is a program, written in Java, that may be stored within a web page. When the web page is retrieved by a browser application, the Java applet is executed by the browser and performs the programmed operations. The activity or operation performed by the agent (or the agent's browser application 144) determines whether a JavaScript method or a Java applet is activated. For example, if the agent clicks an icon associated with a Java applet, then the Java applet is activated. However, if the agent performs an operation that is associated with a JavaScript method, then the JavaScript method is performed in response to the operation.
Agent computer 132 includes a network layer 150, which is a logical layer at which agent computer 132 communicates with other devices via communication link 138. Control server 130 has a network layer 156, which communicates with control layer 150 to exchange information between control server 130 and agent computer 132. A Java server 154 communicates with network layer 156 to exchange information with other devices (e.g., agent computer 132 and customer computer 134). Java server 154 corresponds to server core 108 (FIG. 3) and controls the overall operation of control server 130. Java server 154 is implemented using the Java programming language. Java server 154 communicates with one or more Java servlets 152, which perform various operations necessary to process transactions and communicate information between devices. In a particular embodiment, Java servlets 152 may correspond to various modules shown in FIG. 3, such as transaction management interface 100, transaction host 102, synchronization service 104, messaging service 106, active script module 110, and data logging and reporting module 112.
A network layer 164 in customer computer 134 communicates with network layer 156 and with web server 136. Although not shown in FIG. 4, web server 136 may also include a network layer for communicating data across communication link 142. Customer computer 134 contains one or more Java applets 162 and one or more JavaScript methods 160. Additional details regarding the operation of Java applets 162 and JavaScript methods 160 are provided below. Customer computer 134 also includes a browser application 158 of the type discussed above with respect to FIG. 2.
In a particular embodiment of the invention, an agent is able to “push” a web page or other information to a customer using the system shown in FIG. 4. For example, the agent may identify a particular web page and communicate the uniform resource locator (URL) associated with the web page to customer computer 134 via control server 130. The customer's browser application 158 receives the URL and retrieves the associated web page from web server 136. Thus, the agent “pushes” the web page to the customer by providing the URL associated with the web page to the customer's browser application.
FIG. 5 is a flow diagram illustrating an embodiment of a procedure for communicating information between various devices using the architecture of FIG. 4. At step 170, a customer contacts a web server (e.g., web server 136) and retrieves one or more web pages for viewing using a browser application (e.g., browser application 158). At step 172, the customer requests additional information about a product or service, or requests to be contacted by an agent. The customer may specify the manner in which the information or agent contact is handled (e.g., by return telephone call, by e-mail, or by facsimile). If the customer requests to be contacted using a conventional telephone or by facsimile, then the customer is asked to provide a telephone number for initiating the telephone call or facsimile. At step 174, a JavaScript method, contained in the web page accessed by the customer, is executed by the customer's browser application. When executed, the JavaScript method causes the customer's computer to contact the Java server (e.g., Java server 154) and requests a Java applet and any necessary JavaScript methods. The requested Java applet and JavaScript methods are then communicated from the Java server to the customer's computer. The particular Java applet and JavaScript methods communicated to the customer's computer may vary depending on the web page that was being viewed by the customer when the request for additional information or agent contact was entered. The particular web page being viewed may contain JavaScript methods that identify the necessary Java applet and JavaScript methods to be communicated to the customer's computer.
At step 176, the Java applet (running on the customer's computer) contacts the Java server and communicates the customer's request to the Java server. In this example, the customer has requested that an agent contact the customer by return telephone call. Step 178 calls the transaction host servlet (e.g., the servlet that performs the functions of transaction host 102 in FIG. 3), which locates an agent to handle the customer's request. An agent may be located by communicating with transaction processing system manager 120 to select an agent and to initiate a telephone call across the PSTN.
After an agent has been selected to handle the customer's request, step 180 contacts the selected agent and informs the agent regarding the customer's request. At this time, information about the customer may be displayed to the selected agent (e.g., account information, or past purchases). Step 180 also establishes a communication link (in this example, a telephone link) between the selected agent and the customer. A transaction processing system may be used to automatically establish the telephone link across a PSTN or a web server may be used to establish an Internet telephone call across the Internet. In particular embodiments of the invention, both a voice communication link and a data communication link are established between the agent and the customer. The data communication link can be established and maintained by the control server. Both the agent computer and the customer computer may communicate with the control server, which coordinates the flow of messages and other information between the agent and the customer. For example, the control server forwards messages received from the agent computer system to the customer computer system, and vice versa.
At step 182, the Java server communicates any necessary setup information to the customer's computer and notifies the customer that the communication link has been established. This notification can be performed, for example, by communicating through the network layers to the customer's browser application. In this example, the customer requested a return telephone call. Although a return telephone call has been initiated, the customer and the agent may continue to communicate using their browser applications. For example, the agent may “push” web pages or other information to the customer for viewing using the customer's browser application.
FIG. 6 illustrates an embodiment of various windows (also referred to as frames) displayed to an agent using the agent's computer. An agent's computer includes a display device that provides visual information to the agent. In FIG. 6, an agent's browser application generates a display 190 containing multiple frames 192, 194, 196, 198, and 200. Frame 192 represents the web page or other information currently being displayed to the customer. Thus, the agent is able to easily determine what information is available to the customer based on frame 192. Additionally, the agent can provide additional information about a product or service while referring to the information already displayed to the customer. Frame 194 is a text chat window that allows the agent and the customer to communicate using typed information. The text chat window can be used at any time, and is particularly useful when a voice connection cannot be established between the agent and the customer (e.g., the customer does not have an Internet phone and has only one telephone line, which is used to access the Internet).
Frame 196 of display 190 contains various system information such as information about the agent and information relating to the overall system performance. Frame 196 may also be used to display messages to an agent from a supervisor or system administrator (e.g., asking the agent if they are available to work overtime, or notifying the agent of their next scheduled Express Mail No: EE 402224024 US 31 Attorney Docket No: P0051 break). Frame 198 displays agent script information, such as a prepared script to be read to a customer. The script displayed in frame 198 may be modified to correspond to the product or service being discussed, or the script may be modified to include information about the customer (e.g., the customer's name). Frame 200 provides various links to information that may be provided by the agent to the customer. In a particular embodiment of the invention, the links shown in frame 200 are associated with web pages that contain information of interest to particular customers. For example, the link “FAQ—Acme XL-3000” may identify a web page that contains answers to frequently asked questions about the Acme XL-3000 computer system. If the agent wants to display these answers to the customer, the agent can select the link, which causes the web page to be transmitted to the customer's browser application. The same web page is then displayed in frame 192, to maintain correspondence between frame 192 and the web page displayed to the customer.
Particular embodiments of the systems described above are capable of monitoring information access (e.g., monitoring the web pages viewed by a customer or other individual). Exemplary procedures for monitoring information access are provided below with reference to the accessing of information from web pages using, for example, a web browser application. However, the present invention is not limited to the monitoring of web page access by a web browser. The teachings of the present invention can be applied to any type of system capable of accessing information from one or more information storage mechanisms.
FIGS. 7A and 7B illustrate an embodiment of a procedure for monitoring web page access. The procedure illustrated in FIGS. 7A and 7B monitors web page access for a particular individual or a particular system. Similar procedures may be executed simultaneously to monitor web page access by other users or other systems. At step 210 a user accesses a web page (e.g., with reference to FIG. 2, a customer 52 accesses web server 66, which contains one or more web pages). At step 214, the procedure determines whether an access monitoring application is already running on the web server. An access monitoring application is downloaded to the user's computer the first time a web server is accessed during a current session. A session is a particular web searching or web accessing activity that may last for several minutes or several hours.
If step 214 determines that an access monitoring application is already running on the web server, then the procedure branches to step 218 to avoid unnecessarily downloading the access monitoring application. However, if an access monitoring application is not already running on the web server, then the procedure continues to step 216 to download an access monitoring application to the user's computer (e.g., the user's web browser application). Typically, the access monitoring application is downloaded from the web server to the user's computer. In a particular embodiment of the invention, the access monitoring application is a JavaScript method that can invoke a Java applet. The access monitoring application is executed by the user's computer (e.g., executed by a browser application) and is capable of monitoring web pages or other information accessed by the user. Additionally, the access monitoring application is able to retrieve and store information regarding the information contained in each web page accessed by the user. The data collected by the access monitoring application is provided from the user's computer to a server or other device, as discussed below. The access monitoring application is downloaded to a user once per session; e.g., the first time a web server is accessed by a user. In alternate embodiments of the invention, a particular user's computer may store the access monitoring application after a session has ended. In this embodiment, the access monitoring application is not downloaded to the user's computer.
Since the access monitoring application is executed by the user's computer, the application is able to monitor all web page accesses, including those performed using a web browser's “back” or “forward” functions. Typically, the “back” and “forward” functions retrieve the appropriate web page from a cache or other storage device in the user's computer. In this situation, the web server may not be aware that the user is viewing a different web page, but the access monitoring application is aware of and records the change. When a different web page is displayed, the access monitoring application checks for a tag, and retrieves the information regarding the web page, if the web page is tagged. This tag checking and retrieval of information is performed by the access monitoring application regardless of the manner in which the user selects the web page for display.
Step 218 of FIG. 7A determines whether the accessed web page contains a tag or other identifier. The tag indicates that information regarding the web page is embedded in the web page and can be retrieved by executing a procedure embedded in the web page. Each web page on a particular web server that can be monitored contains a tag or other identifier that indicates that the web page should be monitored. The information embedded in the web page may include the content of the web page (such as a product or service that is displayed or discussed in the web page) and other information used to determine whether or not to display a “Help” button to a user (discussed below). This embedded information is not visible to the user, but can be retrieved using the embedded procedure. In an embodiment of the invention, the embedded procedure is a JavaScript method. Those of ordinary skill in the art will appreciate that various programming languages and programming environments may be used to embed information and procedures within a web page.
If the accessed web page contains a tag, then the procedure continues from step 218 to step 220, where the embedded information regarding the web page is retrieved using a procedure embedded in the web page. At step 222, the information retrieved in step 220 is logged (e.g., stored by the user's computer system). The retrieved information may be stored on a permanent storage device such as a disk drive or stored in a volatile storage device, such as a random access memory (RAM). The logging of retrieved information may also include the amount of time a particular user spends viewing the web page. This time is typically logged when the user accesses a different web page or a different web server.
At step 224 (FIG. 7B), the procedure determines whether an update timer exceeds a threshold. The update timer is maintained by (or contained in) the access monitoring application and is used to periodically transmit data collected regarding the accessed web pages from the user's computer to a server or other device (e.g., server 40 in FIG. 2). The update timer is originally reset when the access monitoring application is downloaded (e.g., step 216 of FIG. 7A). If the threshold has been reached, the procedure branches to step 226, where the collected data is transmitted to the server. Step 228 resets the update timer. If the threshold has not been reached at step 224, then the procedure continues to step 230 where the update timer is incremented. The use of an update timer is not required. Instead, the collected data may be transmitted to the server in response to specific activities, as discussed below.
Step 232 determines whether to display a “Help” button or other assistance icon to the user of the computer system. For example, the “Help” button may be displayed as part of a web page being viewed by the user. If the “Help” button is selected or activated by the user, the system connects an agent with the user (e.g., using an internet phone application or a conventional telephone) to provide assistance to the user. In a particular embodiment of the invention, the information necessary to display the “Help” button (or other assistance icon) is embedded within the web page. When a procedure determines that the “Help” button should be displayed to the user, the procedure activates (e.g., displays) the assistance icon using the embedded information. The determination regarding whether the assistance icon should be displayed may be performed by the server or by the access monitoring application. A system administrator or other individual may set the parameters or rules for determining when to display a “Help” button. Additional details regarding the procedure for determining whether to display a “Help” button are discussed below with respect to FIG. 8. If step 232 determines that a “Help” button should be displayed, then the procedure branches to step 234 to generate a “Help” button and display the button to the user.
At step 236, the procedure determines whether a user selected a “Help” button. A user may select a “Help” button using a pointing device, such as a mouse, to move a cursor over the button and activating a selection mechanism on the pointing device, such as the mouse button. If the user selected a help button, then the procedure branches to step 238, where the data collected regarding web page access is transmitted to a server and an agent is selected to provide help to the user. The user and the agent then communicate to solve the user's problem or answer the user's questions. Although the user and the agent are communicating with one another, the procedure may continue to collect data regarding web pages viewed by the user while communicating with the agent.
At step 240, the procedure determines whether the user has accessed a different web page on the web server. If a different web page has been accessed, the procedure returns to step 218 (FIG. 7A) to determine whether the new web page contains a tag. If the user has not accessed a different web page, then the procedure continues from step 240 to step 242 to determine whether the user has accessed a different web server. If a different web server has been accessed, then the procedure transmits the collected data to a server at step 246. Additionally, the access monitoring application is deleted or otherwise removed from the user's system, and the procedure terminates. Although the procedure terminates, it may be started again (at step 210, FIG. 7A) if the user accesses the web server again at a later time. If the user has not accessed a different web server at step 242, then the procedure returns to step 224.
The procedure described above with reference to FIGS. 7A and 7B may be executed simultaneously on multiple web servers. Thus, although one procedure may be terminated when a user accesses a different web server, a new procedure may be initiated on the new web server.
The data collected regarding web pages accessed by users of a web server can be used to determine the effectiveness of the arrangement of web pages. For example, if a particular web page is viewed by many users for a significant period of time, that web page should be positioned such that it is easy to locate and access by a user. If a popular or useful web page is difficult to locate, the system administrator may rearrange the web page structure for the benefit of the users. The collected data is also useful to determine the popularity or user interest in a particular product or service offered by a company or organization.
FIG. 8 is a flow diagram illustrating an embodiment of a procedure for determining whether to display a “Help” button (or other assistance icon) to a user. The procedure illustrated in FIG. 8 can be performed by the user's computer (e.g., the access monitoring application) or performed by a server. At step 250, the procedure determines the total time the user has viewed a particular web page. The amount of time spent viewing a web page may be an indicator of the user's interest in the content of the web page. At step 252, the procedure determines the total time the user has viewed web pages on the web server. The total time spent viewing web pages may indicate a significant interest in the content of the various web pages viewed. A particular system may automatically display a “Help” button to a user after the user has been viewing web pages for a predetermined period of time.
Step 254 determines the total time the user has viewed web pages of the current type being viewed or the time spent viewing web pages related to the currently viewed product or service. If a particular user has been viewing web pages related to a particular product or service for a predetermined period of time, the system may automatically provide a “Help” button that allows the user to request help from an agent regarding the product or service. At step 256, the procedure determines the total number of web pages viewed. If a user views a predetermined number of web pages, then the system may automatically provide a “Help” button to the user.
Step 258 identifies patterns of repeated switching between two or more web pages. For example, if a user is repeatedly switching between web pages associated with two different products, a “Help” button may be provided automatically, thereby allowing the user to request help from an agent. In this example, the agent may provide additional information about the two products being considered by the user. Step 260 determines whether the total viewing time (e.g., the time determined in step 250, 252 or 254) exceeds a threshold. Step 260 may consider any or all of the times determined in steps 250, 252 or 254. The threshold is typically determined by a system administrator or the individual responsible for maintaining the access monitoring application. If the viewing time exceeds the threshold in step 260, then the procedure branches to step 262 to generate a “Help” button and display the button to the user.
Step 264 determines whether the number of pages viewed (e.g., determined by step 256) exceeds a threshold. If the threshold is exceeded, the procedure branches to step 262 to generate and display a “Help” button. Step 266 determines whether any repeated web page switching (e.g., determined by step 258) exceeds a threshold. If the page switching threshold is exceeded, then the procedure branches to step 262 to generate and display a “Help” button to the user.
The procedure illustrated in FIG. 8 represents one possible procedure for determining whether to display a “Help” button to a user. In alternate embodiments of the invention, an algorithm or set of rules may be used to determine when to display a “Help” button to a user. The algorithm or set of rules may consider the identity of the user, the history of the web pages viewed and the time spent viewing each web page, the content of each web page viewed, as well as the other factors discussed above to determine whether to display a “Help” button.
FIG. 9 is a flow diagram illustrating an embodiment of a procedure for selecting an agent to provide help to a user. At step 270, a user selects a “Help” button or other assistance icon while viewing a web page. Step 272 determines the types of web pages viewed by the user and the time spent viewing each type of page. A page type may identify a particular product or a type of product, or may identify a particular type of service (e.g., technical support or sales). Step 274 determines the product or service associated with the web pages viewed by the user. Additionally, step 274 determines the time spent viewing web pages for each product or service. An embodiment of the invention combines the determinations performed in step 272 and 274 into a single step.
Step 276 determines the web page being viewed by the user when the user selected the “Help” button. Step 278 identifies agents familiar with the information contained in the web page being viewed by the user when the “Help” button was selected. Step 280 identifies agents familiar with the information contained in the other web pages viewed by the user prior to selecting the “Help” button. Step 282 selects an agent to provide assistance to the user based on the determinations performed in the above steps. Preferably, an agent is selected that is familiar with the information contained in the web page currently viewed by the user and web pages viewed prior to selecting the “Help” button. When an agent has been selected, the web page being viewed by the user when requesting help is displayed on the selected agent's computer display. Thus, when the agent established communication with the user, the agent is viewing the same web page as the user. This provides an indication to the agent of the type of assistance the user may require. The agent may also be provided with information, such as a summary, regarding the content of the web pages previously viewed by the user.
FIG. 10 illustrates an embodiment of a table containing information relating to web pages accessed by a user. The embodiment of FIG. 10 represents one possible arrangement of data. Those of ordinary skill in the art will appreciate that various other data formats and data structures may be used to store information relating to web pages accessed by a user. The first column in the table of FIG. 10 identifies seven different web page identifiers (e.g., URLs) that have been accessed by the user. The second column identifies information contained in each web page. The third column identifies the time spent viewing each page. The third column may be a cumulative time for each page (e.g., if the same page is viewed at two different times, the total viewing time is entered in the third column). The fourth column in the table indicates the type of information contained in the web page. In this example, the type of information relates to the product with which the web page is associated. Although not shown in FIG. 10, alternate embodiments of the invention also record the number of times each web page has been accessed by the user. The information shown in FIG. 10 may be summarized for the benefit of an agent or system administrator. For example, the information in FIG. 10 may be summarized to indicate that 10 minutes have been spent by the user viewing web pages relating to the XL2000 computer system. This may indicate that the user has a significant interest in the XL2000 computer. A separate table is maintained for each user that accesses web pages on the web server.
Web pages can typically be divided into static and dynamic categories. The pertinent content of a static page does not change. Thus the web page content will be substantially the same independent of the identity of the client accessing the page (except for perhaps a counter or other session-specific information). Dynamically generated pages, however, are often generated on the fly in response to a client issued request. Dynamic web pages are often found in applications that need to respond to specific customer requests such as a query.
One example of an application where dynamic web pages are typically generated is a search request for locating information within an organization's web server or on another host on the Internet. Providing a static search page for every possible combination of terms may be either impossible or impractical. The search engine dynamically generates a web page in response to customer supplied search terms.
Dynamically generated web pages are typically found in any application where the customer is likely to need customer specific information such as account information. For example, dynamic web pages might be generated in response to a customer's query into current status of an order, banking transactions, account balances, etc. Generally dynamic web pages are advantageous for servicing customer requests when creating static web pages for every possible query would be impossible or impractical.
With respect to enabling collaboration (i.e., accessing the same resource such as viewing the same web page) between the client and the agent, one method is to pass the URL for the resource accessed by one party to the other party. Thus for example, when the customer changes web pages the URL for the new web page can be sent to the agent. The agent can then access the web page using the same URL. This technique is referred to as “URL sharing.” Generally URL sharing accommodates synchronization between the customer and the agent when static resources (e.g., static web pages) are being viewed. URL sharing is not desirable in some situations, however. In particular, URL sharing may not be appropriate for some dynamic resources such as dynamically generated pages.
In one embodiment, the customer accesses the server using the Hypertext Transfer Protocol (HTTP). Generally any request to a host or server is referred to as a client request regardless of the source of the request. Examples of HTTP client request protocols can be found in T. Berners-Lee, et al., RFC 1945 Hypertext Transfer Protocol—HTTP/1.0 (May 1996) and R. Fielding, et al., RFC 2068 Hypertext Transfer Protocol—HTTP/1.1, (January 1997).
URL sharing may be undesirable or impossible if the customer request includes information that is not or should not be readily available to the agent. An HTTP client request includes a method or command that describes the action to be taken on the URL by the server. One such method is the POST method. The POST method enables a customer-client to communicate additional information other than the URL to the server. This additional information, however, is not readily accessible by a third party such as the agent. Moreover, even if the information were accessible, the customer may prefer that the information not be available to the agent for some applications (e.g., confidential financial transactions). Thus URL sharing alone would not enable the agent to retrieve the same page as the customer because the data necessary for dynamically generating the page is unavailable to the agent.
Another application where URL sharing may be undesirable is when servicing the client's request results in some action other than merely displaying the web page. For example, another method supported by HTTP is the GET method. Unlike the POST method, any special information regarding the request is embedded in the URL. For example, in a search engine application the URL typically includes the search string defining the search parameters. Sharing the URL with the agent is harmless because repeating the search has no undesirable side effects. In other applications the agent's issuing of the URL may result in undesirable actions.
For example, in an online banking application, the customer's account number and specific transactions to be performed may be embedded within the URL. When the customer issues the request, the customer's URL may result in a withdrawal, transfer, deposit or other action on the customer's account. URL sharing in this case would be inappropriate because undesirable side effects (e.g., unintended banking transactions) would occur if the agent issued a request with the same URL.
Accordingly, in one embodiment, a cache is provided to cache web pages accessed by the customer. The agent is provided with a modified URL identifying the cached web page rather than the original web page.
FIG. 11 illustrates a flowchart for enabling dynamic resource collaboration or sharing when the session host and the resource host (e.g., web server) are effectively the same.
Presumably a collaboration session has already been established between a customer (i.e., first client) and an agent (i.e., second client) as indicated in step 400. In step 410 the session/resource host receives a customer request including a first URL identifying a first resource such as a web page. Step 420 determines if the requested first resource should be cached for the agent. Referring to FIG. 2, filter service 68 determines if the first resource requested by the customer should be cached in cache 82 for subsequent access by the agent. If so, the first resource is cached in step 430 as a cached second resource.
A second URL is defined for the agent. The second URL is the same as the first URL if the first web page is not cached (step 422). If the first resource is cached then the second URL is set to identify the cached second resource in step 432.
The customer is then provided with the first resource in step 434. In step 440, the agent is provided with the second URL. The agent may issue a request including the second URL in step 450. In response, the session/resource host provides the agent with a selected one of the first resource and the cached second resource in accordance with the second URL in step 460. As long as the customer-agent session is active, steps 410-460 can be repeated each time the customer issues another request.
Generally the entity responsible for web server 66 will be aware of the rules that define when the agent should be referencing a cached web page instead of attempting to retrieve a resource such as a web page through URL sharing. These rules may be implemented in step 420 of FIG. 11 to define whether the web page should be cached.
For example, web pages that should be cached may be identified by a particular characteristic of the web page's associated filename on the web server. The filename extension “ASP” (Active Server Page) for example often identifies a dynamic web page. Step 420 may determine that all dynamic web pages should be cached unless they can be re-generated by the agent without undesirable effects.
In another example, the expiration-date of the resource (e.g., web page) returned by the server may indicate whether the resource should be cached. In one embodiment, step 400 determines that a resource should be cached if the expiration date of the fetched resource indicates that the resource has expired or will expire in the near future. In one embodiment, the resource is a web page.
The expiration date is often used to control whether a cached version of the web page can be used for the client when the client re-visits the web page in order to substantially eliminate download times. In the present case, however, an expiration date indicating that a cached version of the resource should not be relied upon by the client customer is an indication that the resource is a dynamic resource subject to change. Thus such resources should be cached by the filter service 68 into cache 82 in step 430 to enable the agent to access the same version of the resource as the customer.
The rules implemented by step 420 may result in caching any resource resulting from a client request containing a method other than GET. For example, in one embodiment a web page generated as the result of a client request is cached if the customer request includes at least a selected one of a PUT, DELETE, LINK, or UNLINK HTTP method. In order to ensure no adverse affects, the requested web page may be cached in every circumstance. Selective caching, however, may result in greater resource utilization efficiency.
Referring to step 440, the appropriate URL may be provided to the agent's browser by the customer's browser. In one embodiment, web pages retrieved from web server 66 have the URL to be used by the agent embedded within them. This URL may then be communicated to the agent automatically by the customer's browser application. In one embodiment, the embedded URL is the same as the customer's when the web page is not cached in cache 82. Filter services 62, however, embeds a modified URL identifying the cached version of the web page whenever the web page is cached.
The procedure above is particularly suited for situations where the resource host and the session host are the same or are managed by the same entity. In such a case the requested web pages are readily available to cache. Moreover the decision whether to cache the resources may be pre-determined by providing the embedded URLs in the web pages at the time the web pages are created.
In some applications, however, the resource host and the session host may need to be distinct. For example, a company may outsource help desk operations to a third party. The third party may not have access to the corporate resource host and thus may not be able to maintain session control if the customer is permitted to freely navigate the corporate resource host or other hosts on the Internet. In particular, the mechanism for caching the dynamic resources resides with the session host as opposed to the resource host and thus the agent has no means of ensuring access to the same resources provided by the resource host directly to the client customer.
FIG. 12 illustrates an embodiment where the session host 500 and the server or resource host 510 are distinct entities. Ordinarily, a customer client request 522 designating the resource host 510 would result in customer client 520 accessing the resource host 510 independently of session host 500 as indicated by 524. Similarly, an agent client request 532 designating the resource host 510 would result in agent client 530 accessing the resource host 510 independently of session host 500 as indicated by 534. These independent accesses, however, ensure that the session host 500 is unable to cache any dynamic resources resulting from such requests. Resource host 510 treats agent client 530 and customer client 520 as distinct entities and manages requests between the customer and the agent independently. As a result, the other party to the session might not have access to dynamic resources specific to the other party's session.
In order to ensure that all parties collaborating during the session can access the same resource, client requests are re-directed through the session host effectively causing the session host to issue the request. Thus, for example, customer client requests (e.g., 522) identifying a host (510) other than the session host 500 are re-directed through session host 500 as indicated by 526. Similarly, agent client requests (e.g., 532) identifying a host (510) other than session host 500 are re-directed through session host 500 as indicated by 536.
FIG. 13 illustrates one embodiment of a method of redirecting customer and agent client requests through the session host to ensure the ability to cache dynamic resources so that the agent and the customer can URL share the same resource.
In step 610, a collaboration session is established between a first client (e.g., customer) and a second client (e.g., agent). Referring to FIG. 12, a session between customer client 520 and agent client 530 is established on session host 500 in one embodiment. In step 620, a request identifying a host other than the session host from the first client is redirected to force the request to be issued by the session host 500.
Re-direction can be accomplished by conditionally modifying a request's URL. For example, if a client initiates a request containing a first URL identifying a resource from a host other than the session host, the first URL is modified to create a modified URL that re-directs the request through the session host. This may be accomplished, for example, by execution of a Java application in conjunction with the customer's browser during an agent15 customer collaboration session. Such a client re-direction application may include JavaScripts for trapping requests for hosts other than the session host and Java applets for generating the modified URLs. In one embodiment, the modified URL is formed by concatenating the identity of the session host with a redirection command (e.g., “redirect?”) and the first URL.
The redirected request results in having the session host issue a request for the resource identified by the first URL. In step 630, the session host then caches the resource received in response to the re-directed request, if necessary. The conditions for caching may be the same as those previously described in reference to FIG. 11. The session host then responds to the first client's request by providing the received resource to the first client in step 640. The second client is provided with a second URL in step 650. In one embodiment, the second URL is the same as the first URL if caching is not necessary. The second URL identifies the cached resource if the resource was cached. The agent may then access the appropriate resource using the second URL provided in step 650.
Referring to step 650, the second URL may be provided to the second client's browser by the first client's browser. In one embodiment, the session host 500 embeds the second URL to be used by the second client into the requested resource. The embedded URL may then be communicated to the second client automatically by the first client's browser application during a collaboration session.
In one embodiment the filter services of the session host handles caching. Thus, referring to FIGS. 12 and 13, filter services 68 determines whether a retrieved resource should be cached (step 630), and if so, caches the modified resource in cache 82.
The security architecture of a browser application may not permit simple re-direction of a client request without the co-operation of the other host. Thus re-direction may not be possible through the use of a Java application when the security architecture of the browser is adhered to. Thus an alternative method for achieving the re-direction is illustrated in FIG. 14.
In step 710 a collaboration session between a first client and a second client is established through the session host. This may be performed, for example, in response to selection of the “HELP” button as described above. During the session, all requests are re-directed through the session host by modifying the URLs contained within any retrieved resources. In response to initiation of a session, the session host might provide the customer (e.g., first client) with a web page having links containing indirect references to resource hosts other than the session host. In step 720 a requested resource is retrieved from a resource host through the session host in accordance with a first URL from the first client. The first URL provides an indirect reference to the resource host by re-direction through the session host. The retrieved resource is not yet provided to the requesting client.
In step 730, the session host modifies each URL referring to a host other than the session host within the retrieved resource to ensure that the modified URL re-directs the corresponding request through the session host. Thus any reference or link defining a client request to a host other than a session host is modified to re-direct the request through the session host. In one embodiment this is accomplished by concatenating the name of the session host and a re-direction command to the selected URL.
The session host determines whether to cache the modified resource in step 740. As discussed above, the rules defining whether a resource should be cached may be varied according to the particular needs of the client-agent session. Dynamic resources such as dynamic web pages typically need to be cached to ensure availability to the other party. Characteristics indicative of dynamic resources include a pre-determined filename extension, a retrieved resource expiration date, or even the command used to retrieve the resource (e.g., “POST” command).
In step 750, the modified resource is provided to the requesting client. If, for example, the resource is a web page, the web page will be displayed by the requesting client's browser application. In the event that the client now selects a hyperlink from the web page, the modified URL associated with the hyperlink will designate a re-direction operation to ensure that the original request associated with the hyperlink is now re-directed through the session host. Thus, no modification is required at the client's end to modify URLs. Similarly, no co-operation is required from the resource host in accordance with the security architecture.
The second client (e.g., the agent) is provided with a second URL in step 760. If the modified resource was cached the URL indicates the cached version of the modified resource stored in the session host cache. Otherwise the second URL corresponds to the first URL to ensure that any command acting upon the second URL is effectively carried out by the session host.
The second client may use the second URL to retrieve the same resource accessed by the first client. For example, the second client may issue a request comprised of a GET command and the second URL. The resource will be retrieved either from the session host cache or from the other host via re-direction through the session host in accordance with the second URL.
Referring to FIGS. 12 and 14, step 730 is performed by filter services 68 in one embodiment. In addition, filter services 68 determines whether a modified retrieved resource should be cached (step 740), and if so, caches the modified resource in cache 82.
Although the examples presented above illustrate requests initiated by one client (e.g., a customer), the roles of customers and agents in the examples may be interchanged to enable collaboration of a particular resource to be initiated by either party. Thus, for example, “first” and “second” client could refer to agents or customers interchangeably.
FIG. 15 illustrates an embodiment of a computer system that can be used with the present invention. For example, embodiments of the invention may use a computer of the type shown in FIG. 15 for an agent's computer, a customer's computer, a server, a transaction processing system, or any other device contained in or used with the transaction processing environment discussed above. The various components in FIG. 15 are provided by way of example. Certain components of the computer in FIG. 15 can be deleted for particular implementations of the invention. The computer system shown in FIG. 15 may be any type of computer, including a general purpose computer.
FIG. 15 illustrates a system bus 300 to which various components and devices are coupled. A processor 302 performs the processing tasks required by the computer. Processor 302 may be any type of processing device capable of implementing the steps necessary to perform the various procedures and operations discussed above. An Input/Output (I/O) device 304 is coupled to bus 300 and provides a mechanism for communicating with other devices coupled to the computer. A Read-Only Memory (ROM) 306 and a Random Access Memory (RAM) 308 are coupled to bus 300 and provide a storage mechanism for various data and information used by the computer. Although ROM 306 and RAM 308 are shown coupled to bus 300, in alternate embodiments, ROM 306 and RAM 308 are coupled directly to processor 302 or coupled to a dedicated memory bus (not shown).
A video display 310 is coupled to bus 300 and displays various information and data to the user of the computer. A disk drive 312 is coupled to bus 300 and provides a mechanism for the long-term mass storage of information. An input device 314 and a pointing device 316 are also coupled to bus 300 and allow the user of the computer to enter information and commands to the computer system. Input device 314 may be, for example, a keyboard, keypad, handwriting recognition device, or voice recognition device. Pointing device 316 includes, for example, a mouse, track ball, or touch pad. A printer 318 is coupled to bus 300 and is capable of creating a hard copy of information generated by or used by the computer.
Embodiments of the present invention may be implemented using a computer-readable medium (also referred to as a processor-readable medium) containing various sets of instructions, code sequences, configuration information, and other data used by a computer or other processing device. The various information stored on the computer-readable medium is used to perform various data communication, data processing, and data handling operations, such as those described above. The computer-readable medium may be any type of magnetic, optical, or electrical storage medium including a diskette, magnetic tape, CD-ROM, memory device, or other storage medium. In one embodiment, for example, a set of instructions forming a client redirection program can be distributed in such a storage medium with or independently of a browser application. When executed in conjunction with a browser application of a first client, the re-direction program communicates with the browser application. During a collaboration session between the first client and a second client through a session host, the re-direction program issues a re-direction request in response to a selected first client request having a uniform resource locator (URL) identifying a host other than the session host. The re-direction request incorporates the first request, wherein the re-direction request causes the session host to issue the selected request.
In the preceding detailed description, the invention is described with reference to specific exemplary embodiments thereof. Various modifications and changes may be made thereto without departing from the broader spirit and scope of the invention as set forth in the claims. The specification and drawings are, accordingly, to be regarded in an illustrative rather than a restrictive sense.
Patent Citations
Cited PatentFiling datePublication dateApplicantTitle
US5991796 *Aug 13, 1998Nov 23, 1999Lucent Technologies Inc.Technique for obtaining and exchanging information on world wide web
US6029175 *Jun 7, 1996Feb 22, 2000Teknowledge CorporationAutomatic retrieval of changed files by a network software agent
US6070185 *May 2, 1997May 30, 2000Lucent Technologies Inc.Technique for obtaining information and services over a communication network
US6112279 *Mar 31, 1998Aug 29, 2000Lucent Technologies, Inc.Virtual web caching system
Referenced by
Citing PatentFiling datePublication dateApplicantTitle
US6480581 *Jun 22, 1999Nov 12, 2002Institute For Information IndustryInternet/telephone adapter device and method
US6523063 *Jan 14, 2000Feb 18, 2003Zaplet, Inc.Method system and program product for accessing a file using values from a redirect message string for each change of the link identifier
US6553411 *May 18, 1999Apr 22, 2003International Business Machines CorporationSystem and method for cache acceleration
US6665658 *Jan 13, 2000Dec 16, 2003International Business Machines CorporationSystem and method for automatically gathering dynamic content and resources on the world wide web by stimulating user interaction and managing session information
US6754718 *May 10, 2000Jun 22, 2004Emc CorporationPushing attribute information to storage devices for network topology access
US6912528 *Jul 19, 2001Jun 28, 2005Gregg S. HomerRechargeable media distribution and play system
US6915347 *Dec 6, 2000Jul 5, 2005Sun Microsystems, Inc.Associating multiple display units in a grouped server environment
US6981062 *Apr 20, 2001Dec 27, 2005Sbc Technology Resources, Inc.World wide web content synchronization between wireless devices
US7024411 *Nov 2, 2001Apr 4, 2006Toshiba Tec Kabushiki KaishaMethod, system and computer program product for providing backup data for use in studying claims
US7080140 *Oct 5, 2001Jul 18, 2006International Business Machines CorporationStorage area network methods and apparatus for validating data from multiple sources
US7085817 *Nov 3, 2000Aug 1, 2006Juniper Networks, Inc.Method and system for modifying requests for remote resources
US7149776 *Aug 26, 2002Dec 12, 2006Oracle International Corp.System and method for real-time co-browsing
US7177901 *Mar 27, 2000Feb 13, 2007International Business Machines CorporationMethod, system, and computer program product to redirect requests from content servers to load distribution servers and to correct bookmarks
US7231644Jan 30, 2001Jun 12, 2007Aol Llc, A Delaware Limited Liability CompanyOptimized delivery of web application code
US7343406Jan 18, 2001Mar 11, 2008Cisco Technology, Inc.Proactive call and contact center system
US7370269 *Aug 26, 2002May 6, 2008Oracle International CorporationSystem and method for real-time annotation of a co-browsed document
US7398273Apr 20, 2004Jul 8, 2008Emc CorporationPushing attribute information to storage devices for network topology access
US7472166 *Aug 31, 2000Dec 30, 2008Intel CorporationAssisting users with web pages
US7487130 *Jan 6, 2006Feb 3, 2009Grdn. Net Solutions, LlcConsumer-controlled limited and constrained access to a centrally stored information account
US7499972Apr 20, 2001Mar 3, 2009Cisco Technology Inc.B2B service center communications using locate collaborate transact methodology
US7620719 *Jun 5, 2003Nov 17, 2009Juniper Networks, Inc.Method and system for providing secure access to private networks
US7631084Apr 8, 2003Dec 8, 2009Juniper Networks, Inc.Method and system for providing secure access to private networks with client redirection
US7660294 *Jul 26, 2005Feb 9, 2010At&T Intellectual Property Ii, L.P.Voice-over-IP enabled chat
US7725472 *May 30, 2001May 25, 2010Hottolink, Inc.Distributed monitoring system providing knowledge services
US7746362Feb 10, 2006Jun 29, 2010Avaya Inc.Automatic call distribution system using computer network-based communication
US7774455Jan 29, 2002Aug 10, 2010Juniper Networks, Inc.Method and system for providing secure access to private networks
US7865569Nov 3, 2000Jan 4, 2011Juniper Networks, Inc.Method and system for modifying script portions of requests for remote resources
US7877412May 9, 2005Jan 25, 2011Homer Gregg SRechargeable media distribution and play system
US7877459 *Jun 8, 2006Jan 25, 2011Juniper Networks, Inc.Method and system for modifying requests for remote resources
US7958245Oct 20, 2009Jun 7, 2011Juniper Networks, Inc.Method and system for providing secure access to private networks with client redirection
US7966626Jun 11, 2007Jun 21, 2011Aol Inc.Optimized delivery of web application code
US7995740Feb 10, 2006Aug 9, 2011Avaya Inc.Automatic call distribution system using computer network-based communication
US8015495 *Feb 28, 2003Sep 6, 2011Groupserve It Trust LlcCentrifugal communication and collaboration method
US8117649Aug 5, 2010Feb 14, 2012Dormarke Assets Limited Liability CompanyDistributed hierarchical identity management
US8224999Sep 26, 2005Jul 17, 2012At&T Intellectual Property I, L.P.World wide web content synchronization between wireless devices
US8244808 *Jun 26, 2006Aug 14, 2012Microsoft CorporationIntegrated network and application session establishment
US8260806Jun 29, 2007Sep 4, 2012Grdn. Net Solutions, LlcStorage, management and distribution of consumer information
US8280948 *Oct 9, 2009Oct 2, 2012Persony Inc.System and method for enabling online collaboration amongst a plurality of terminals using a web server
US8285856Oct 19, 2005Oct 9, 2012Verizon Data Services LlcMethods and systems for integrating a messaging service with an application
US8312146 *Nov 15, 2005Nov 13, 2012Aspect Software, Inc.Methods and apparatus for enabling dynamic resource collaboration
US8326981Jun 23, 2010Dec 4, 2012Juniper Networks, Inc.Method and system for providing secure access to private networks
US8347203Oct 19, 2005Jan 1, 2013Verizon Data Services LlcMethods and systems for defining a form navigational structure
US8407188Jul 23, 2004Mar 26, 2013Verizon Data Services LlcMethods and systems for providing data form management
US8504704Jan 24, 2005Aug 6, 2013Dormarke Assets Limited Liability CompanyDistributed contact information management
US8527752Jan 24, 2005Sep 3, 2013Dormarke Assets Limited LiabilityGraduated authentication in an identity management system
US8548861Dec 27, 2007Oct 1, 2013Cisco Technology, Inc.Multimedia B2B opportunity and error detection and resolution engine
US8566248Nov 20, 2001Oct 22, 2013Grdn. Net Solutions, LlcInitiation of an information transaction over a network via a wireless device
US8577995Jun 12, 2012Nov 5, 2013At&T Intellectual Property I, L.P.World wide web content synchronization between wireless devices
US8645547 *Oct 19, 2005Feb 4, 2014Verizon Data Services LlcMethods and systems for providing a messaging service
US8713586May 10, 2011Apr 29, 2014Facebook, Inc.Optimized delivery of web application code
US8738731Dec 3, 2012May 27, 2014Juniper Networks, Inc.Method and system for providing secure access to private networks
US8775274Aug 10, 2004Jul 8, 2014Fritch Alibates, LlcSystem, method, and computer program product for a unified internet wallet and gift registry
US8826144Jun 2, 2006Sep 2, 2014International Business Machines CorporationContent recovery mode for portlets
US8832149Jan 21, 2011Sep 9, 2014Gregg S. HomerMethod for subscription media on-demand
US8891410Nov 28, 2012Nov 18, 2014At&T Intellectual Property Ii, L.P.Voice-over-IP enabled chat
US8959652Aug 30, 2013Feb 17, 2015Dormarke Assets Limited Liability CompanyGraduated authentication in an identity management system
US8996980Apr 25, 2008Mar 31, 2015Facebook, Inc.Methods and systems of automated client-server data validation
US9031985Jan 21, 2011May 12, 2015B# On Demand, LlcMore subscription media on demand
US9052914Sep 15, 2012Jun 9, 2015Facebook, Inc.Bundling of web application code for optimized delivery
US9130936Oct 2, 2009Sep 8, 2015Pulse Secure, LlcMethod and system for providing secure access to private networks
US9245266Jun 16, 2004Jan 26, 2016Callahan Cellular L.L.C.Auditable privacy policies in a distributed hierarchical identity management system
US9330242Sep 9, 2014May 3, 2016Gregg S. HomerEven more subscription media on demand
US9398020Feb 13, 2015Jul 19, 2016Callahan Cellular L.L.C.Graduated authentication in an identity management system
US9444791Jul 30, 2015Sep 13, 2016Pulse Secure, LlcMethod and system for providing secure access to private networks
US9553880 *Jan 20, 2016Jan 24, 2017Gregg S. HomerSubscription media on demand VII
US20020029245 *Jun 20, 2001Mar 7, 2002Yuval NahonSystem and method for directing shared data
US20020042730 *Jul 19, 2001Apr 11, 2002Homer Gregg S.Rechargeable media distribution and play system
US20020046300 *Dec 6, 2000Apr 18, 2002Hanko James G.Associating multiple display units in a grouped server environment
US20020065802 *May 30, 2001May 30, 2002Koki UchiyamaDistributed monitoring system providing knowledge services
US20020065885 *Nov 30, 2000May 30, 2002Mark BuonannoMultimedia B2B opportunity and error detection and resolution engine
US20020138315 *Mar 20, 2001Sep 26, 2002Mineo NozakiTechnical support system
US20020155848 *Apr 20, 2001Oct 24, 2002Lalitha SuryanarayanaWorld wide web content synchronization between wireless devices
US20030033448 *Jan 30, 2001Feb 13, 2003Robert KiefferOptimized delivery of web application code
US20030083922 *Aug 28, 2002May 1, 2003Wendy ReedSystems and methods for managing critical interactions between an organization and customers
US20030088451 *Nov 2, 2001May 8, 2003Toshiba Tec Kabushiki KaishaTechnical support system
US20030088590 *Nov 2, 2001May 8, 2003Toshiba Tec Kabushiki KaishaMethod, system and computer program product for providing backup data for use in studying claims
US20030115087 *Nov 2, 2001Jun 19, 2003Toshiba Tec Kabushiki KaishaTechnical support system
US20030145048 *Jan 16, 2003Jul 31, 2003Bea Systems, Inc.System and method for HTTP request preprocessing for servlets and application servers
US20030149806 *Feb 28, 2003Aug 7, 2003Groupserve, Inc.Centrifugal communication and collaboration method
US20030177168 *Oct 5, 2001Sep 18, 2003Heitman Allen RobertStorage area network methods and apparatus for validating data from multiple sources
US20030229718 *Jun 5, 2003Dec 11, 2003Neoteris, Inc.Method and system for providing secure access to private networks
US20040039827 *Apr 8, 2003Feb 26, 2004Neoteris, Inc.Method and system for providing secure access to private networks with client redirection
US20040057569 *Sep 29, 2003Mar 25, 2004Acuity SoftwareAutomatic call distribution system using computer network-based communication
US20040199513 *Apr 20, 2004Oct 7, 2004Dobberpuhl Walter T.Pushing attribute information to storage devices for network topology access
US20040205593 *Sep 27, 2002Oct 14, 2004Wish-List.Com, Inc.Method and apparatus for providing enhanced functionality to product webpages
US20040268225 *Jun 21, 2004Dec 30, 2004Walsh Raymond V.Method and system for controlling navigation of a graphical user interface
US20050022119 *Aug 10, 2004Jan 27, 2005Kraemer Keith M.Method and apparatus for providing enhanced functionality to product webpages
US20050177525 *Feb 6, 2004Aug 11, 2005Apple John R.Sales and service offer method and apparatus
US20050187936 *May 9, 2005Aug 25, 2005Openscape MusicRechargeable Media Distribution and Play System
US20050259638 *Jul 26, 2005Nov 24, 2005Burg Frederick MVoice -over-IP enabled chat
US20060005020 *Jan 24, 2005Jan 5, 2006Sxip Networks SrlGraduated authentication in an identity management system
US20060020716 *Sep 26, 2005Jan 26, 2006Sbc Technology Resources, Inc.World wide web content synchronization between wireless devices
US20060080664 *Nov 15, 2005Apr 13, 2006Aspect Communications CorporationMethods and apparatus for enabling dynamic resource collaboration
US20060179003 *Jan 6, 2006Aug 10, 2006Enfotrust Networks, Inc.Consumer-controlled limited and constrained access to a centrally stored information account
US20060188086 *Feb 10, 2006Aug 24, 2006Acuity SoftwareAutomatic call distribution system using computer network-based communication
US20060203993 *Feb 10, 2006Sep 14, 2006Acuity SoftwareAutomatic call distribution system using computer network-based communication
US20060218242 *Jun 8, 2006Sep 28, 2006Theron TockMethod and system for modifying requests for remote resources
US20060277199 *Jun 2, 2006Dec 7, 2006International Business Machines CorporationContent recovery mode for portlets
US20070088783 *Dec 1, 2006Apr 19, 2007Fujitsu LimitedCollaboration apparatus between information processing systems, integrated information processing system, and recording medium storing a collaboration program between information processing systems
US20070106627 *Oct 4, 2006May 10, 2007Mohit SrivastavaSocial discovery systems and methods
US20070299914 *Jun 26, 2006Dec 27, 2007Microsoft CorporationIntegrated network and application session establishment
US20070300244 *Jun 11, 2007Dec 27, 2007Robert KiefferOptimized delivery of web application code
US20080104596 *Dec 27, 2007May 1, 2008Cisco Technology, Inc.Multimedia b2b opportunity and error detection and resolution engine
US20090150435 *Dec 8, 2007Jun 11, 2009International Business Machines CorporationDynamic updating of personal web page
US20090182622 *Aug 28, 2008Jul 16, 2009Agarwal Amit DEnhancing and storing data for recall and use
US20090210293 *May 4, 2009Aug 20, 2009Nick SteeleInformation transactions over a network
US20090319881 *Apr 25, 2008Dec 24, 2009Sandip ChokshiMethods and systems of automated client-server data validation
US20100057845 *Oct 20, 2009Mar 4, 2010Juniper Networks, Inc.Method and system for providing secure access to private networks with client redirection
US20100070501 *Nov 20, 2009Mar 18, 2010Walsh Paul JEnhancing and storing data for recall and use using user feedback
US20100263035 *Jun 23, 2010Oct 14, 2010Juniper Networks, Inc.Method and system for providing secure access to private networks
US20110113067 *Jan 21, 2011May 12, 2011Homer Gregg SRechargeable Media Distribution and Play System with Download Kiosk
US20110119308 *Jan 21, 2011May 19, 2011Homer Gregg SRechargeable Media Distribution and Play System
US20110119769 *Jan 21, 2011May 19, 2011Homer Gregg SRechargeable Media Distribution and Play System with Tracking Cookies
US20110131478 *Nov 30, 2010Jun 2, 2011Juniper Networks, Inc.Method and system for modifying script portions of requests for remote resources
US20110208838 *Apr 29, 2011Aug 25, 2011Juniper Networks, Inc.Method and system for providing secure access to private networks with client redirection
US20110213834 *May 10, 2011Sep 1, 2011Aol Inc.Optimized delivery of web application code
US20140059172 *Sep 25, 2013Feb 27, 2014International Business Machines CorporationRemote portlet consumer with enhanced resource url processing
US20160156634 *Jan 20, 2016Jun 2, 2016Gregg S. HomerSubscription Media On Demand VII
US20170093881 *Dec 12, 2016Mar 30, 2017Gregg S. HomerSubscription Media On Demand VIII (Offline Mode)
CN101918939B *Jan 12, 2009Nov 9, 2016亚马逊技术有限公司增强和存储用于再调用的数据
WO2002029582A1 *Oct 2, 2001Apr 11, 2002Georgia State University Research Foundation, Inc.Systems and methods of internet chat sessions among multiple users visiting any designated website
WO2002051178A1 *Dec 18, 2001Jun 27, 2002Sonera OyjCentralized session management
WO2003063001A1 *Jan 17, 2003Jul 31, 2003Bea Systems, Inc.System and method for http request preprocessing for servlets and application servers
Classifications
U.S. Classification1/1, 715/234, 709/203, 711/113, 714/E11.202, 707/999.002, 707/999.01, 707/999.201
International ClassificationG06F11/32, G06F11/34
Cooperative ClassificationY10S707/99932, Y10S707/99952, G06F11/3495, G06F2201/875, G06F11/323
European ClassificationG06F11/34T12
Legal Events
DateCodeEventDescription
Nov 20, 1998ASAssignment
Owner name: ASPECT TELECOMMUNICATIONS CORPORATION, CALIFORNIA
Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNORS:DILIP, VENKATACHARI;JAWAHAR, JANARDHANAN;REEL/FRAME:009599/0908
Effective date: 19981120
Feb 17, 2005FPAYFee payment
Year of fee payment: 4
Feb 28, 2005ASAssignment
Owner name: ASPECT COMMUNICATIONS CORPORATION, CALIFORNIA
Free format text: CHANGE OF NAME;ASSIGNOR:ASPECT TELECOMMUNICATIONS CORPORATION;REEL/FRAME:015797/0518
Effective date: 19990924
Nov 2, 2005ASAssignment
Owner name: JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT
Free format text: SECURITY INTEREST;ASSIGNOR:ASPECT COMMUNICATIONS CORPORATION;REEL/FRAME:016735/0972
Effective date: 20050922
Nov 15, 2005ASAssignment
Owner name: D.B. ZWIRN FINANCE, LLC, AS ADMINISTRATIVE AGENT,
Free format text: SECURITY INTEREST;ASSIGNOR:ASPECT COMMUNICATIONS CORPORATION;REEL/FRAME:016814/0013
Effective date: 20050922
Owner name: D.B. ZWIRN FINANCE, LLC, AS ADMINISTRATIVE AGENT,N
Free format text: SECURITY INTEREST;ASSIGNOR:ASPECT COMMUNICATIONS CORPORATION;REEL/FRAME:016814/0013
Effective date: 20050922
Jul 27, 2006ASAssignment
Owner name: CONCERTO SOFTWARE INTERMEDIATE HOLDINGS, INC., ASP
Free format text: RELEASE BY SECURED PARTY;ASSIGNOR:D.B. ZWIRN FINANCE, LLC;REEL/FRAME:017996/0895
Effective date: 20060711
Aug 11, 2006ASAssignment
Owner name: DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LI
Free format text: SECURITY AGREEMENT;ASSIGNORS:ASPECT SOFTWARE, INC.;FIRSTPOINT CONTACT TECHNOLOGIES, LLC;ASPECT COMMUNICATIONS CORPORATION;REEL/FRAME:018087/0313
Effective date: 20060711
Mar 11, 2009FPAYFee payment
Year of fee payment: 8
Jun 7, 2010ASAssignment
Owner name: ASPECT COMMUNICATIONS CORPORATION,MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Owner name: ASPECT SOFTWARE, INC.,MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Owner name: FIRSTPOINT CONTACT TECHNOLOGIES, LLC,MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Owner name: ASPECT SOFTWARE INTERMEDIATE HOLDINGS, INC.,MASSAC
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Owner name: ASPECT COMMUNICATIONS CORPORATION, MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Owner name: ASPECT SOFTWARE, INC., MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Owner name: FIRSTPOINT CONTACT TECHNOLOGIES, LLC, MASSACHUSETT
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Owner name: ASPECT SOFTWARE INTERMEDIATE HOLDINGS, INC., MASSA
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT;REEL/FRAME:024515/0765
Effective date: 20100507
Jun 8, 2010ASAssignment
Owner name: ASPECT COMMUNICATIONS CORPORATION,MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Owner name: ASPECT SOFTWARE, INC.,MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Owner name: FIRSTPOINT CONTACT TECHNOLOGIES, LLC,MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Owner name: ASPECT SOFTWARE INTERMEDIATE HOLDINGS, INC.,MASSAC
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Owner name: ASPECT COMMUNICATIONS CORPORATION, MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Owner name: ASPECT SOFTWARE, INC., MASSACHUSETTS
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Owner name: FIRSTPOINT CONTACT TECHNOLOGIES, LLC, MASSACHUSETT
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Owner name: ASPECT SOFTWARE INTERMEDIATE HOLDINGS, INC., MASSA
Free format text: RELEASE OF SECURITY INTEREST;ASSIGNOR:DEUTSCHE BANK TRUST COMPANY AMERICAS, AS SECOND LIEN ADMINSTRATIVE AGENT;REEL/FRAME:024492/0496
Effective date: 20100507
Jun 9, 2010ASAssignment
Owner name: JPMORGAN CHASE BANK, N.A., AS ADMINISTRATIVE AGENT
Free format text: SECURITY AGREEMENT;ASSIGNORS:ASPECT SOFTWARE, INC.;FIRSTPOINT CONTACT TECHNOLOGIES, LLC (F/K/A ROCKWELL ELECTRONIC COMMERCE TECHNOLOGIES, LLC);ASPECT SOFTWARE, INC. (AS SUCCESSOR TO ASPECT COMMUNICATIONS CORPORATION);REEL/FRAME:024505/0225
Effective date: 20100507
Jun 29, 2010ASAssignment
Owner name: U.S. BANK NATIONAL ASSOCIATION, AS COLLATERAL AGEN
Free format text: SECURITY INTEREST;ASSIGNORS:ASPECT SOFTWARE, INC.;FIRSTPOINT CONTACT TECHNOLOGIES, LLC;REEL/FRAME:024651/0637
Effective date: 20100507
Mar 11, 2013FPAYFee payment
Year of fee payment: 12
Nov 20, 2014ASAssignment
Owner name: WILMINGTON TRUST, NATIONAL ASSOCIATION, AS ADMINIS
Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNOR:JPMORGAN CHASE BANK, N.A.;REEL/FRAME:034281/0548
Effective date: 20141107
Jun 14, 2016ASAssignment
Owner name: ASPECT SOFTWARE, INC., ARIZONA
Free format text: RELEASE BY SECURED PARTY;ASSIGNOR:WILMINGTON TRUST, NATIONAL ASSOCIATION;REEL/FRAME:039013/0015
Effective date: 20160525
Owner name: ASPECT SOFTWARE, INC., ARIZONA
Free format text: RELEASE BY SECURED PARTY;ASSIGNOR:U.S. BANK NATIONAL ASSOCIATION;REEL/FRAME:039012/0311
Effective date: 20160525
Jun 16, 2016ASAssignment
Owner name: WILMINGTON TRUST, NATIONAL ASSOCIATION, MINNESOTA
Free format text: SECURITY INTEREST;ASSIGNORS:ASPECT SOFTWARE PARENT, INC.;ASPECT SOFTWARE, INC.;DAVOX INTERNATIONAL HOLDINGS LLC;AND OTHERS;REEL/FRAME:039052/0356
Effective date: 20160525
|
{
"url": "http://www.google.com/patents/US6289333?dq=%22peter+l+basel%22+%22lsi+logic%22",
"source_domain": "www.google.com",
"snapshot_id": "crawl=CC-MAIN-2017-43",
"warc_metadata": {
"Content-Length": "216130",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:APSSMP2J4HZ54FKIF3PU7JXSUI2JQS4W",
"WARC-Concurrent-To": "<urn:uuid:cbde7f50-92ef-4b4b-a5d2-fabfcd2dcb64>",
"WARC-Date": "2017-10-20T16:58:04Z",
"WARC-IP-Address": "172.217.5.228",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:WXUC6FIIKQUFBLVHOFSMDTBNQPGYPR3Z",
"WARC-Record-ID": "<urn:uuid:f5b99b56-0e48-402a-b7d8-d22165da8937>",
"WARC-Target-URI": "http://www.google.com/patents/US6289333?dq=%22peter+l+basel%22+%22lsi+logic%22",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:a98a4eda-c674-4f26-bb55-c83534c8c184>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-230-39-145.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,
56,
64,
205,
206,
214,
215,
243,
274,
296,
328,
357,
381,
407,
422,
528,
577,
622,
661,
712,
837,
851,
860,
2340,
2351,
2365,
2375,
2386,
2406,
2443,
2547,
2726,
2960,
3036,
3239,
3403,
3460,
3517,
3589,
3886,
4326,
4383,
4617,
4893,
5810,
6280,
6318,
6426,
6662,
7035,
7094,
7223,
7339,
7483,
7640,
7838,
7897,
7953,
8035,
8094,
8335,
8347,
8387,
8388,
8499,
8500,
8523,
8524,
8690,
8691,
8702,
8703,
9174,
9175,
9867,
9868,
11035,
11036,
11779,
11780,
11805,
11806,
12008,
12009,
12729,
12730,
13708,
13709,
13743,
13744,
14046,
14047,
14164,
14165,
14389,
14390,
14444,
14445,
14598,
14599,
14754,
14755,
14857,
14858,
14946,
14947,
15103,
15104,
15221,
15222,
15332,
15333,
15436,
15437,
15558,
15559,
15680,
15681,
15815,
15816,
15916,
15917,
15938,
15939,
16362,
16363,
17292,
17293,
17760,
17761,
18136,
18137,
18665,
18666,
19137,
19138,
20114,
20115,
20892,
20893,
22281,
22282,
22993,
22994,
23530,
23531,
25377,
25378,
25664,
25665,
26851,
26852,
27954,
27955,
28715,
28716,
29405,
29406,
29979,
29980,
30696,
30697,
31313,
31314,
32025,
32026,
32510,
32511,
33180,
33181,
33447,
33448,
34296,
34297,
35477,
35478,
36474,
36475,
36960,
36961,
37629,
37630,
38829,
38830,
39603,
39604,
40027,
40028,
40582,
40583,
41716,
41717,
42592,
42593,
43517,
43518,
44824,
44825,
45944,
45945,
46507,
46508,
47105,
47106,
48767,
48768,
49365,
49366,
50549,
50550,
51201,
51202,
52301,
52302,
53782,
53783,
54399,
54400,
55240,
55241,
56798,
56799,
57672,
57673,
58719,
58720,
59425,
59426,
60343,
60344,
61681,
61682,
62452,
62453,
63373,
63374,
63642,
63643,
64276,
64277,
65167,
65168,
65819,
65820,
66737,
66738,
67201,
67202,
67752,
67753,
68520,
68521,
69704,
69705,
71293,
71294,
71836,
71837,
72242,
72243,
72741,
72742,
73513,
73514,
73957,
73958,
74852,
74853,
75488,
75489,
75968,
75969,
76175,
76176,
76352,
76353,
76979,
76980,
77222,
77223,
77718,
77719,
78052,
78053,
78444,
78445,
78834,
78835,
79430,
79431,
79950,
79951,
80519,
80520,
80904,
80905,
81565,
81566,
82503,
82504,
83054,
83055,
83294,
83295,
83722,
83723,
84540,
84541,
85327,
85328,
85718,
85719,
85971,
85972,
86344,
86345,
87240,
87241,
87747,
87748,
88300,
88301,
88946,
88947,
89314,
89315,
89680,
89681,
89937,
89938,
90291,
90292,
90955,
90956,
91790,
91791,
92507,
92508,
93923,
93924,
94315,
94316,
94333,
94387,
94515,
94637,
94773,
94860,
94874,
94929,
95043,
95228,
95347,
95588,
95715,
95812,
95934,
96063,
96221,
96383,
96500,
96605,
96824,
96945,
97041,
97175,
97299,
97382,
97532,
97665,
97787,
97930,
98026,
98135,
98256,
98377,
98511,
98604,
98722,
98866,
98950,
99070,
99178,
99296,
99427,
99540,
99657,
99806,
99939,
100061,
100181,
100301,
100414,
100530,
100653,
100776,
100911,
101041,
101154,
101244,
101364,
101509,
101618,
101704,
101799,
101931,
102041,
102125,
102227,
102341,
102482,
102566,
102681,
102797,
102879,
102972,
103073,
103192,
103303,
103424,
103500,
103624,
103720,
103861,
103951,
104113,
104204,
104346,
104451,
104594,
104712,
104854,
104986,
105121,
105257,
105387,
105520,
105616,
105717,
105800,
105913,
106046,
106184,
106339,
106471,
106603,
106714,
106829,
107080,
107171,
107288,
107384,
107513,
107632,
107731,
107820,
107936,
108086,
108203,
108330,
108450,
108550,
108672,
108813,
108964,
109053,
109197,
109282,
109384,
109444,
109632,
109713,
109856,
109872,
109973,
110022,
110116,
110152,
110165,
110190,
110215,
110277,
110402,
110427,
110455,
110478,
110503,
110561,
110664,
110689,
110713,
110776,
110878,
110903,
110928,
110990,
111092,
111117,
111180,
111282,
111307,
111332,
111395,
111494,
111519,
111544,
111607,
111770,
111795,
111823,
111846,
111870,
111930,
112060,
112085,
112133,
112263,
112288,
112351,
112481,
112506,
112569,
112699,
112724,
112785,
112915,
112940,
112989,
113119,
113144,
113207,
113337,
113362,
113425,
113555,
113580,
113604,
113664,
113816,
113841,
113889,
114041,
114066,
114129,
114281,
114306,
114369,
114521,
114546,
114607,
114759,
114784,
114833,
114985,
115010,
115073,
115225,
115250,
115313,
115465,
115490,
115514,
115577,
115835,
115860,
115885,
115948,
116076,
116101,
116129,
116153,
116178,
116241,
116350,
116375,
116400,
116443,
116557,
116582,
116625,
116731,
116756,
116781,
116843,
117007
],
"line_end_idx": [
56,
64,
205,
206,
214,
215,
243,
274,
296,
328,
357,
381,
407,
422,
528,
577,
622,
661,
712,
837,
851,
860,
2340,
2351,
2365,
2375,
2386,
2406,
2443,
2547,
2726,
2960,
3036,
3239,
3403,
3460,
3517,
3589,
3886,
4326,
4383,
4617,
4893,
5810,
6280,
6318,
6426,
6662,
7035,
7094,
7223,
7339,
7483,
7640,
7838,
7897,
7953,
8035,
8094,
8335,
8347,
8387,
8388,
8499,
8500,
8523,
8524,
8690,
8691,
8702,
8703,
9174,
9175,
9867,
9868,
11035,
11036,
11779,
11780,
11805,
11806,
12008,
12009,
12729,
12730,
13708,
13709,
13743,
13744,
14046,
14047,
14164,
14165,
14389,
14390,
14444,
14445,
14598,
14599,
14754,
14755,
14857,
14858,
14946,
14947,
15103,
15104,
15221,
15222,
15332,
15333,
15436,
15437,
15558,
15559,
15680,
15681,
15815,
15816,
15916,
15917,
15938,
15939,
16362,
16363,
17292,
17293,
17760,
17761,
18136,
18137,
18665,
18666,
19137,
19138,
20114,
20115,
20892,
20893,
22281,
22282,
22993,
22994,
23530,
23531,
25377,
25378,
25664,
25665,
26851,
26852,
27954,
27955,
28715,
28716,
29405,
29406,
29979,
29980,
30696,
30697,
31313,
31314,
32025,
32026,
32510,
32511,
33180,
33181,
33447,
33448,
34296,
34297,
35477,
35478,
36474,
36475,
36960,
36961,
37629,
37630,
38829,
38830,
39603,
39604,
40027,
40028,
40582,
40583,
41716,
41717,
42592,
42593,
43517,
43518,
44824,
44825,
45944,
45945,
46507,
46508,
47105,
47106,
48767,
48768,
49365,
49366,
50549,
50550,
51201,
51202,
52301,
52302,
53782,
53783,
54399,
54400,
55240,
55241,
56798,
56799,
57672,
57673,
58719,
58720,
59425,
59426,
60343,
60344,
61681,
61682,
62452,
62453,
63373,
63374,
63642,
63643,
64276,
64277,
65167,
65168,
65819,
65820,
66737,
66738,
67201,
67202,
67752,
67753,
68520,
68521,
69704,
69705,
71293,
71294,
71836,
71837,
72242,
72243,
72741,
72742,
73513,
73514,
73957,
73958,
74852,
74853,
75488,
75489,
75968,
75969,
76175,
76176,
76352,
76353,
76979,
76980,
77222,
77223,
77718,
77719,
78052,
78053,
78444,
78445,
78834,
78835,
79430,
79431,
79950,
79951,
80519,
80520,
80904,
80905,
81565,
81566,
82503,
82504,
83054,
83055,
83294,
83295,
83722,
83723,
84540,
84541,
85327,
85328,
85718,
85719,
85971,
85972,
86344,
86345,
87240,
87241,
87747,
87748,
88300,
88301,
88946,
88947,
89314,
89315,
89680,
89681,
89937,
89938,
90291,
90292,
90955,
90956,
91790,
91791,
92507,
92508,
93923,
93924,
94315,
94316,
94333,
94387,
94515,
94637,
94773,
94860,
94874,
94929,
95043,
95228,
95347,
95588,
95715,
95812,
95934,
96063,
96221,
96383,
96500,
96605,
96824,
96945,
97041,
97175,
97299,
97382,
97532,
97665,
97787,
97930,
98026,
98135,
98256,
98377,
98511,
98604,
98722,
98866,
98950,
99070,
99178,
99296,
99427,
99540,
99657,
99806,
99939,
100061,
100181,
100301,
100414,
100530,
100653,
100776,
100911,
101041,
101154,
101244,
101364,
101509,
101618,
101704,
101799,
101931,
102041,
102125,
102227,
102341,
102482,
102566,
102681,
102797,
102879,
102972,
103073,
103192,
103303,
103424,
103500,
103624,
103720,
103861,
103951,
104113,
104204,
104346,
104451,
104594,
104712,
104854,
104986,
105121,
105257,
105387,
105520,
105616,
105717,
105800,
105913,
106046,
106184,
106339,
106471,
106603,
106714,
106829,
107080,
107171,
107288,
107384,
107513,
107632,
107731,
107820,
107936,
108086,
108203,
108330,
108450,
108550,
108672,
108813,
108964,
109053,
109197,
109282,
109384,
109444,
109632,
109713,
109856,
109872,
109973,
110022,
110116,
110152,
110165,
110190,
110215,
110277,
110402,
110427,
110455,
110478,
110503,
110561,
110664,
110689,
110713,
110776,
110878,
110903,
110928,
110990,
111092,
111117,
111180,
111282,
111307,
111332,
111395,
111494,
111519,
111544,
111607,
111770,
111795,
111823,
111846,
111870,
111930,
112060,
112085,
112133,
112263,
112288,
112351,
112481,
112506,
112569,
112699,
112724,
112785,
112915,
112940,
112989,
113119,
113144,
113207,
113337,
113362,
113425,
113555,
113580,
113604,
113664,
113816,
113841,
113889,
114041,
114066,
114129,
114281,
114306,
114369,
114521,
114546,
114607,
114759,
114784,
114833,
114985,
115010,
115073,
115225,
115250,
115313,
115465,
115490,
115514,
115577,
115835,
115860,
115885,
115948,
116076,
116101,
116129,
116153,
116178,
116241,
116350,
116375,
116400,
116443,
116557,
116582,
116625,
116731,
116756,
116781,
116843,
117007,
117031
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 117031,
"ccnet_original_nlines": 584,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3328651785850525,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.052106741815805435,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.19522471725940704,
"rps_doc_frac_unique_words": 0.11659141629934311,
"rps_doc_mean_word_length": 5.421331882476807,
"rps_doc_num_sentences": 1043,
"rps_doc_symbol_to_word_ratio": 0.000046820001443848014,
"rps_doc_unigram_entropy": 5.923101425170898,
"rps_doc_word_count": 17720,
"rps_doc_frac_chars_dupe_10grams": 0.16211770474910736,
"rps_doc_frac_chars_dupe_5grams": 0.36987072229385376,
"rps_doc_frac_chars_dupe_6grams": 0.2967230975627899,
"rps_doc_frac_chars_dupe_7grams": 0.23076842725276947,
"rps_doc_frac_chars_dupe_8grams": 0.19702079892158508,
"rps_doc_frac_chars_dupe_9grams": 0.17767992615699768,
"rps_doc_frac_chars_top_2gram": 0.008525390177965164,
"rps_doc_frac_chars_top_3gram": 0.010347049683332443,
"rps_doc_frac_chars_top_4gram": 0.004371989984065294,
"rps_doc_books_importance": -8475.6787109375,
"rps_doc_books_importance_length_correction": -8475.6787109375,
"rps_doc_openwebtext_importance": -4729.97216796875,
"rps_doc_openwebtext_importance_length_correction": -4729.97216796875,
"rps_doc_wikipedia_importance": -3070.077392578125,
"rps_doc_wikipedia_importance_length_correction": -3070.077392578125
},
"fasttext": {
"dclm": 0.07128577679395676,
"english": 0.8513538837432861,
"fineweb_edu_approx": 2.6021180152893066,
"eai_general_math": 0.23712140321731567,
"eai_open_web_math": 0.05299944058060646,
"eai_web_code": 0.48484474420547485
}
}
|
{
"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": "-1",
"label": "Abstain"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v1": {
"primary": {
"code": "11",
"label": "Legal/Regulatory"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"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": "8",
"label": "Documentation"
},
"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": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-2,963,719,568,000,430,600
|
Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
PerlMonks
What is the easiest way of having a configuration file for my program?
( #28440=categorized question: print w/ replies, xml ) Need Help??
Contributed by Anonymous Monk on Aug 18, 2000 at 11:40 UTC
Q&A > files
Description:
I have a program that requires some things set straight. Instead of setting them in the script itself, I would like to move them to the configuration file. What is the easiest/best way to read and set them from the config file on program start up?
Answer: What is the easiest way of having a configuration file for my program?
contributed by Anonymous Monk
I'd have to say that the "easiest" way would be to just have a perl file that you 'require' into your program. The config would look like $attr = "value"; $this = 0;
Answer: What is the easiest way of having a configuration file for my program?
contributed by fundflow
I found the following method to be simple and readable in terms of configuration file syntax:
TOKEN1=value1 TOKEN2=value2 ...
The way to parse it is
while(<>) { if (/^([A-Z_]+)=(.*)/) { my ($TAG,$VAL)=($1,$2); $conf{$1}=$2; } }
This lets you have comment lines and can be easily extended for multi-line values, if needed.
Using __DATA__ section in your script is also useful, as mentioned by Corion, but you can just initialize %conf by
%conf=(TOKEN1 => "value1", TOKEN2 => "value2")
Cheers.
Answer: What is the easiest way of having a configuration file for my program?
contributed by Corion
Personally, I've found the following setup to be the easiest :
I have a routine, readconfig(), which takes a string as the parameter (the name of the configuration file). A template configuration file, filled with sane defaults, is stored in the __DATA__ section of my program. Readfile reads the data either from the file specified, or, if the name is empty, from the __DATA__ section. I call readconfig() twice, once to initialize with the sane defaults, and then again with the name of the config file (if given), to overwrite the settings differing from the defaults.
Of course, this answer dosen't help you with how to organize your configuration data, but the configuration data depends much on what your program does (and what data it needs) and what your audience is. Apache for example uses some kind of HTML/XML style to store the configuration. I prefer either .ini style sections with name=value pairs or simple name=value pairs.
Answer: What is the easiest way of having a configuration file for my program?
contributed by GhodMode
I like my configuration file to be written in perl, so I can have common functions which can be used between my programs.
I start like this...
use lib ("/path/to/file/config"); use PerlConfig; # This is PerlConfig.pm in /path/to/file/config
Then my config file starts like this...
package Cfg;
My program can now use variables with $Cfg:: in front of them, or subroutines with &Cfg:: in front of them so that I don't get confused about where things exist.
For example, I want to have a consistent time/date stamp in all of my output file names. So, I use POSIX 'strftime' in my config file then set $filedt = sub { return strftime("%m%d%H%M%S", localtime) };
I then use filenames like
my $logfile = "codelog_" . &$Cfg::filedt . ".txt";
GM
Answer: What is the easiest way of having a configuration file for my program?
contributed by princepawn
I would take a look at App::Config on CPAN by Andy Wardley (author id: ABW)
Answer: What is the easiest way of having a configuration file for my program?
contributed by ghenry
Three modules on CPAN, (one which is already mentioned above, but is now called something else):
Config::General is part of the bigger Config-General module, and AppConfig is the parent of AppConfig::File
They both read configuration files that are in the standard format that you would expect, but give you many, many options.
HTH.
Answer: What is the easiest way of having a configuration file for my program?
contributed by epoptai
Here's a way to have multiple config files for a single script. They're specified with a query such as myscript.pl?config1, myscript.pl?config2, etc.
$config=$ENV{QUERY_STRING}; unless(require $config){ print "No Configuration File Specified!\n"; exit; }
I learned that from Brent Michalski's excellent database tutorials that used to be at webreview.com
Please (register and) log in if you wish to add an answer
• Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
• Read Where should I post X? if you're not absolutely sure you're posting in the right place.
• Please read these before you post! —
• Posts may use any of the Perl Monks Approved HTML tags:
a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
• Outside of code tags, you may need to use entities for some characters:
For: Use:
& &
< <
> >
[ [
] ]
• Link using PerlMonks shortcuts! What shortcuts can I use for linking?
• See Writeup Formatting Tips and other pages linked from there for more info.
• Log In?
Username:
Password:
What's my password?
Create A New User
Chatterbox?
and the web crawler heard nothing...
How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (7)
As of 2015-02-01 23:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
Voting Booth?
On my keyboard, Caps lock is:
Results (14 votes), past polls
|
{
"url": "http://www.perlmonks.org/?node_id=28440",
"source_domain": "www.perlmonks.org",
"snapshot_id": "crawl=CC-MAIN-2015-06",
"warc_metadata": {
"Content-Length": "26271",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:SOHXXQSOB3QNMZI3YAZMFY3VII6EBLW3",
"WARC-Concurrent-To": "<urn:uuid:8a378703-ddc1-4b13-a093-f74abf51f70a>",
"WARC-Date": "2015-02-01T23:33:16Z",
"WARC-IP-Address": "216.92.34.251",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:DZJUX3DP36LE4EM5KWNWQCTAAIXXHSID",
"WARC-Record-ID": "<urn:uuid:4047aab8-b25f-4504-b31e-c305c193153f>",
"WARC-Target-URI": "http://www.perlmonks.org/?node_id=28440",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:fc3be689-53f6-4683-8d67-b1102c77dc71>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-180-212-252.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-06\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for January 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,
63,
90,
92,
104,
105,
176,
177,
244,
303,
316,
317,
318,
331,
332,
580,
581,
660,
690,
691,
857,
858,
937,
961,
962,
1056,
1057,
1089,
1112,
1191,
1285,
1286,
1401,
1448,
1449,
1450,
1458,
1537,
1559,
1560,
1623,
1624,
2133,
2134,
2504,
2505,
2584,
2608,
2609,
2736,
2760,
2761,
2859,
2860,
2905,
2918,
2919,
3086,
3294,
3325,
3376,
3379,
3458,
3484,
3485,
3561,
3562,
3641,
3663,
3664,
3761,
3762,
3870,
3871,
3994,
3995,
4000,
4001,
4080,
4103,
4104,
4254,
4255,
4360,
4460,
4461,
4519,
4520,
4521,
4522,
4645,
4742,
4783,
4843,
5109,
5185,
5211,
5223,
5234,
5245,
5257,
5269,
5343,
5424,
5436,
5450,
5464,
5465,
5489,
5511,
5527,
5568,
5569,
5611,
5628,
5674,
5705,
5719,
5736,
5752,
5767,
5787,
5788,
5824,
5825,
5826,
5827,
5828,
5829,
5830,
5831,
5832
],
"line_end_idx": [
63,
90,
92,
104,
105,
176,
177,
244,
303,
316,
317,
318,
331,
332,
580,
581,
660,
690,
691,
857,
858,
937,
961,
962,
1056,
1057,
1089,
1112,
1191,
1285,
1286,
1401,
1448,
1449,
1450,
1458,
1537,
1559,
1560,
1623,
1624,
2133,
2134,
2504,
2505,
2584,
2608,
2609,
2736,
2760,
2761,
2859,
2860,
2905,
2918,
2919,
3086,
3294,
3325,
3376,
3379,
3458,
3484,
3485,
3561,
3562,
3641,
3663,
3664,
3761,
3762,
3870,
3871,
3994,
3995,
4000,
4001,
4080,
4103,
4104,
4254,
4255,
4360,
4460,
4461,
4519,
4520,
4521,
4522,
4645,
4742,
4783,
4843,
5109,
5185,
5211,
5223,
5234,
5245,
5257,
5269,
5343,
5424,
5436,
5450,
5464,
5465,
5489,
5511,
5527,
5568,
5569,
5611,
5628,
5674,
5705,
5719,
5736,
5752,
5767,
5787,
5788,
5824,
5825,
5826,
5827,
5828,
5829,
5830,
5831,
5832,
5868
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5868,
"ccnet_original_nlines": 131,
"rps_doc_curly_bracket": 0.00204498996026814,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.34198471903800964,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04122136905789375,
"rps_doc_frac_lines_end_with_ellipsis": 0.030303029343485832,
"rps_doc_frac_no_alph_words": 0.26564884185791016,
"rps_doc_frac_unique_words": 0.44694533944129944,
"rps_doc_mean_word_length": 4.60021448135376,
"rps_doc_num_sentences": 64,
"rps_doc_symbol_to_word_ratio": 0.006106869783252478,
"rps_doc_unigram_entropy": 5.3944854736328125,
"rps_doc_word_count": 933,
"rps_doc_frac_chars_dupe_10grams": 0.13723206520080566,
"rps_doc_frac_chars_dupe_5grams": 0.146551713347435,
"rps_doc_frac_chars_dupe_6grams": 0.146551713347435,
"rps_doc_frac_chars_dupe_7grams": 0.13723206520080566,
"rps_doc_frac_chars_dupe_8grams": 0.13723206520080566,
"rps_doc_frac_chars_dupe_9grams": 0.13723206520080566,
"rps_doc_frac_chars_top_2gram": 0.055452000349760056,
"rps_doc_frac_chars_top_3gram": 0.018872320652008057,
"rps_doc_frac_chars_top_4gram": 0.029822930693626404,
"rps_doc_books_importance": -580.9220581054688,
"rps_doc_books_importance_length_correction": -580.9220581054688,
"rps_doc_openwebtext_importance": -344.1012878417969,
"rps_doc_openwebtext_importance_length_correction": -344.1012878417969,
"rps_doc_wikipedia_importance": -272.8975524902344,
"rps_doc_wikipedia_importance_length_correction": -272.8975524902344
},
"fasttext": {
"dclm": 0.6616361737251282,
"english": 0.8686859011650085,
"fineweb_edu_approx": 1.9563493728637695,
"eai_general_math": 0.4020368456840515,
"eai_open_web_math": 0.3394445776939392,
"eai_web_code": 0.02493130974471569
}
}
|
{
"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": "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": "6",
"label": "Indeterminate"
}
},
"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
|
1,254,202,129,473,006,600
|
Skip to content
HTTPS clone URL
Subversion checkout URL
You can clone with
or
.
Download ZIP
Fetching contributors…
Cannot retrieve contributors at this time
615 lines (425 sloc) 18.571 kB
{-# LANGUAGE OverloadedStrings, PackageImports #-}
-- |
-- Copyright : (c) 2010-2011 Simon Meier
-- License : BSD3-style (see LICENSE)
--
-- Maintainer : Simon Meier <iridcode@gmail.com>
-- Stability : experimental
-- Portability : tested on GHC only
--
-- Running example for documentation of Data.ByteString.Lazy.Builder
--
module Main (main) where
-- **************************************************************************
-- CamHac 2011: An introduction to Data.ByteString.Lazy.Builder
-- **************************************************************************
{- The Encoding Problem
----------------------
Encoding: Conversion from a Haskell value to a sequence of bytes.
Efficient encoding implementation:
1. represent sequence of bytes as a list of byte arrays (chunks)
2. generate chunks that are large on average
3. avoid intermediate copies/datastructures
Compositionality:
4. support fast append
Problem: Provide a library for defining compositional, efficient encodings.
-}
{- Data.ByteString.Lazy.Builder
------------------------------
A solution to the "Encoding Problem" (based on the code of blaze-builder).
Builder creation:
word8 :: Word8 -> Builder
int64LE :: Int64 -> Builder
floatBE :: Float -> Builder
....
Builder composition via its Monoid instance:
word8 10 `mappend` floatBE 1.4
Builder execution by converting it to a lazy bytestring:
toLazyByteString :: Builder -> L.ByteString
-}
{- Typical users of Builders
---------------------------
binary, text, aeson, blaze-html, blaze-textual, warp, snap-server, ...
=> they want support for maximal performance!
=> use of Builders is rather local: in rendering/encoding functions.
-}
{- Notable properties
--------------------
* Built-in UTF-8 support: very hard to get efficient otherwise.
stringUtf8 :: String -> Builder
intDec :: Int -> Builder
intHex :: Int -> Builder
* Fine-grained control over when to copy/reference existing bytestrings
* EDSL for defining low-level Encodings of bounded values (e.g., Int, Char)
to improve speed of escaping and similar operations.
* If used together with iteratee-style IO: no 'unsafePerformIO' required
-}
{- An example problem:
---------------------
Rendering a table in comma-separated-value (CSV) format using UTF-8 encoded
Unicode characters.
* We are willing to fuse table-rendering with UTF8-encoding to achieve better
performance.
-}
import qualified Data.ByteString as S
import qualified Data.ByteString.Lazy as L
import Data.ByteString.Lazy.Builder as B
import Data.ByteString.Lazy.Builder.ASCII as B
import Data.Monoid
import Data.Foldable (foldMap)
import Criterion.Main
import Control.DeepSeq
-- To be used in a later optimization
import Data.ByteString.Lazy.Builder.BasicEncoding ( (>*<), (>$<) )
import qualified Data.ByteString.Lazy.Builder.BasicEncoding as E
-- To be used in a later comparison
import qualified Data.DList as D
import qualified Codec.Binary.UTF8.Light as Utf8Light
import qualified Data.String.UTF8 as Utf8String
import qualified Data.Text.Lazy as TL
import qualified Data.Text.Lazy.Encoding as TL
import qualified Data.Text.Lazy.Builder as TB
import qualified Data.Text.Lazy.Builder.Int as TB
import Data.Char (ord)
import qualified Data.Binary.Builder as BinB
------------------------------------------------------------------------------
-- Simplife CSV Tables
------------------------------------------------------------------------------
data Cell = StringC String
| IntC Int
deriving( Eq, Ord, Show )
type Row = [Cell]
type Table = [Row]
-- Example data
strings :: [String]
strings = ["hello", "\"1\"", "λ-wörld"]
table :: Table
table = [map StringC strings, map IntC [-3..3]]
-- | The rendered 'table':
--
-- > "hello","\"1\"","λ-wörld"
-- > -3,-2,-1,0,1,2,3
--
-- | A bigger table for benchmarking our encoding functions.
maxiTable :: Table
maxiTable = take 1000 $ cycle table
------------------------------------------------------------------------------
-- String based rendering
------------------------------------------------------------------------------
renderString :: String -> String
renderString cs = "\"" ++ concatMap escape cs ++ "\""
where
escape '\\' = "\\"
escape '\"' = "\\\""
escape c = return c
renderCell :: Cell -> String
renderCell (StringC cs) = renderString cs
renderCell (IntC i) = show i
renderRow :: Row -> String
renderRow [] = ""
renderRow (c:cs) = renderCell c ++ concat [',' : renderCell c' | c' <- cs]
renderTable :: Table -> String
renderTable rs = concat [renderRow r ++ "\n" | r <- rs]
-- 1.36 ms
benchString :: Benchmark
benchString = bench "renderTable maxiTable" $ nf renderTable maxiTable
-- 1.36 ms
benchStringUtf8 :: Benchmark
benchStringUtf8 = bench "utf8 + renderTable maxiTable" $
nf (L.length . B.toLazyByteString . B.stringUtf8 . renderTable) maxiTable
-- using difference lists: 0.91 ms
--
-- (++) is a performance-grinch!
------------------------------------------------------------------------------
-- Builder based rendering
------------------------------------------------------------------------------
-- better syntax for `mappend`
infixr 4 <>
(<>) :: Monoid m => m -> m -> m
(<>) = mappend
-- As a reminder:
--
-- import Data.ByteString.Lazy.Builder as B
-- import Data.ByteString.Lazy.Builder.Utf8 as B
renderStringB :: String -> Builder
renderStringB cs = B.charUtf8 '"' <> foldMap escape cs <> B.charUtf8 '"'
where
escape '\\' = B.charUtf8 '\\' <> B.charUtf8 '\\'
escape '\"' = B.charUtf8 '\\' <> B.charUtf8 '"'
escape c = B.charUtf8 c
renderCellB :: Cell -> Builder
renderCellB (StringC cs) = renderStringB cs
renderCellB (IntC i) = B.intDec i
renderRowB :: Row -> Builder
renderRowB [] = mempty
renderRowB (c:cs) =
renderCellB c <> mconcat [ B.charUtf8 ',' <> renderCellB c' | c' <- cs ]
renderTableB :: Table -> Builder
renderTableB rs = mconcat [renderRowB r <> B.charUtf8 '\n' | r <- rs]
-- 0.81ms
benchBuilderUtf8 :: Benchmark
benchBuilderUtf8 = bench "utf8 + renderTableB maxiTable" $
nf (L.length . B.toLazyByteString . renderTableB) maxiTable
-- 1.11x faster than DList
-- However: touching the whole table 'nf maxiTable' takes 0.27ms
-- 1.16x faster than DList on the code path other than touching all data
-- (0.91 - 0.27) / (0.82 - 0.27)
------------------------------------------------------------------------------
-- Baseline: Touching all data
------------------------------------------------------------------------------
instance NFData Cell where
rnf (StringC cs) = rnf cs
rnf (IntC i) = rnf i
-- 0.27 ms
benchNF :: Benchmark
benchNF = bench "nf maxiTable" $ nf id maxiTable
------------------------------------------------------------------------------
-- Exploiting bounded encodings
------------------------------------------------------------------------------
{- Why 'Bounded Encodings'?
--------------------------
Hot code of encoding implementations:
* Appending Builders: Optimized already.
* Encoding primitive Haskell values: room for optimization:
- reduce buffer-free checks
- remove jumps/function calls
- hoist constant values out of inner-loops
(e.g., the loop for encoding the elements of a list)
* Bounded encoding:
an encoding that never takes more than a fixed number of bytes.
- intuitively: (Int, Ptr Word8 -> IO (Ptr Word8))
^bound ^ low-level encoding function
- compositional: coalesce buffer-checks, ...
E.encodeIfB :: (a -> Bool)
-> BoundedEncoding a -> BoundedEncoding a -> BoundedEncoding a
E.charUtf8 :: BoundedEncoding Char
(>*<) :: BoundedEncoding a -> BoundedEncoding b -> BoundedEncoding (a, b)
(>$<) :: (b -> a) -> BoundedEncoding a -> BoundedEncoding b
^ BoundedEncodings are contrafunctors; like most data-sinks
- Implementation relies heavily on inlining to compute bounds and
low-level encoding code during compilation.
-}
renderStringBE :: String -> Builder
renderStringBE cs =
B.charUtf8 '"' <> E.encodeListWithB escape cs <> B.charUtf8 '"'
where
escape :: E.BoundedEncoding Char
escape =
E.ifB (== '\\') (const ('\\', '\\') >$< E.charUtf8 >*< E.charUtf8) $
E.ifB (== '\"') (const ('\\', '\"') >$< E.charUtf8 >*< E.charUtf8) $
E.charUtf8
renderCellBE :: Cell -> Builder
renderCellBE (StringC cs) = renderStringBE cs
renderCellBE (IntC i) = B.intDec i
renderRowBE :: Row -> Builder
renderRowBE [] = mempty
renderRowBE (c:cs) =
renderCellBE c <> mconcat [ B.charUtf8 ',' <> renderCellBE c' | c' <- cs ]
renderTableBE :: Table -> Builder
renderTableBE rs = mconcat [renderRowBE r <> B.charUtf8 '\n' | r <- rs]
-- 0.65 ms
benchBuilderEncodingUtf8 :: Benchmark
benchBuilderEncodingUtf8 = bench "utf8 + renderTableBE maxiTable" $
nf (L.length . B.toLazyByteString . renderTableBE) maxiTable
-- 1.4x faster than DList based
-- 1.7x faster than DList based on code other than touching all data
------------------------------------------------------------------------------
-- Difference-list based rendering
------------------------------------------------------------------------------
type DString = D.DList Char
renderStringD :: String -> DString
renderStringD cs = return '"' <> foldMap escape cs <> return '"'
where
escape '\\' = D.fromList "\\\\"
escape '\"' = D.fromList "\\\""
escape c = return c
renderCellD :: Cell -> DString
renderCellD (StringC cs) = renderStringD cs
renderCellD (IntC i) = D.fromList $ show i
renderRowD :: Row -> DString
renderRowD [] = mempty
renderRowD (c:cs) =
renderCellD c <> mconcat [ return ',' <> renderCellD c' | c' <- cs ]
renderTableD :: Table -> DString
renderTableD rs = mconcat [renderRowD r <> return '\n' | r <- rs]
-- 0.91 ms
benchDListUtf8 :: Benchmark
benchDListUtf8 = bench "utf8 + renderTableD maxiTable" $
nf (L.length . B.toLazyByteString . B.stringUtf8 . D.toList . renderTableD) maxiTable
------------------------------------------------------------------------------
-- utf8-string and utf8-light
------------------------------------------------------------------------------
-- 4.12 ms
benchDListUtf8Light :: Benchmark
benchDListUtf8Light = bench "utf8-light + renderTable maxiTable" $
whnf (Utf8Light.encode . D.toList . renderTableD) maxiTable
{- Couldn't get utf8-string to work :-(
benchDListUtf8String :: Benchmark
benchDListUtf8String = bench "utf8-light + renderTable maxiTable" $
whnf (Utf8String.toRep . encode .
D.toList . renderTableD) maxiTable
where
encode :: String -> Utf8String.UTF8 S.ByteString
encode = Utf8String.fromString
-}
------------------------------------------------------------------------------
-- Data.Binary.Builder based rendering
------------------------------------------------------------------------------
-- Note that as of binary-0.6.0.0 the binary builder is the same as the one
-- provided by the bytestring library.
{-# INLINE char8BinB #-}
char8BinB :: Char -> BinB.Builder
char8BinB = BinB.singleton . fromIntegral . ord
renderStringBinB :: String -> BinB.Builder
renderStringBinB cs = char8BinB '"' <> foldMap escape cs <> char8BinB '"'
where
escape '\\' = char8BinB '\\' <> char8BinB '\\'
escape '\"' = char8BinB '\\' <> char8BinB '"'
escape c = char8BinB c
renderCellBinB :: Cell -> BinB.Builder
renderCellBinB (StringC cs) = renderStringBinB cs
renderCellBinB (IntC i) = B.intDec i
renderRowBinB :: Row -> BinB.Builder
renderRowBinB [] = mempty
renderRowBinB (c:cs) =
renderCellBinB c <> mconcat [ char8BinB ',' <> renderCellBinB c' | c' <- cs ]
renderTableBinB :: Table -> BinB.Builder
renderTableBinB rs = mconcat [renderRowBinB r <> char8BinB '\n' | r <- rs]
-- 1.22 ms
benchBinaryBuilderChar8 :: Benchmark
benchBinaryBuilderChar8 = bench "char8 + renderTableBinB maxiTable" $
nf (L.length . BinB.toLazyByteString . renderTableBinB) maxiTable
------------------------------------------------------------------------------
-- Text Builder
------------------------------------------------------------------------------
renderStringTB :: String -> TB.Builder
renderStringTB cs = TB.singleton '"' <> foldMap escape cs <> TB.singleton '"'
where
escape '\\' = "\\\\"
escape '\"' = "\\\""
escape c = TB.singleton c
renderCellTB :: Cell -> TB.Builder
renderCellTB (StringC cs) = renderStringTB cs
renderCellTB (IntC i) = TB.decimal i
renderRowTB :: Row -> TB.Builder
renderRowTB [] = mempty
renderRowTB (c:cs) =
renderCellTB c <> mconcat [ TB.singleton ',' <> renderCellTB c' | c' <- cs ]
renderTableTB :: Table -> TB.Builder
renderTableTB rs = mconcat [renderRowTB r <> TB.singleton '\n' | r <- rs]
-- 0.95 ms
benchTextBuilder :: Benchmark
benchTextBuilder = bench "renderTableTB maxiTable" $
nf (TL.length . TB.toLazyText . renderTableTB) maxiTable
-- 1.10 ms
benchTextBuilderUtf8 :: Benchmark
benchTextBuilderUtf8 = bench "utf8 + renderTableTB maxiTable" $
nf (L.length . TL.encodeUtf8 . TB.toLazyText . renderTableTB) maxiTable
------------------------------------------------------------------------------
-- Benchmarking
------------------------------------------------------------------------------
main :: IO ()
main = do
putStrLn "Encoding the maxiTable"
putStrLn $ "Total length in bytes: " ++
(show $ L.length $ encodeUtf8CSV maxiTable)
putStrLn $ "Chunk lengths: " ++
(show $ map S.length $ L.toChunks $ encodeUtf8CSV maxiTable)
putStrLn ""
defaultMain
[ benchNF
, benchString
, benchStringUtf8
, benchDListUtf8
, benchDListUtf8Light
, benchBinaryBuilderChar8
, benchTextBuilder
, benchTextBuilderUtf8
, benchBuilderUtf8
, benchBuilderEncodingUtf8
]
where
encodeUtf8CSV = B.toLazyByteString . renderTableBE
{- On a Core 2 Duo 2.2 GHz running a 32-bit Linux:
touching all data: 0.25 ms
string rendering: 1.36 ms
string rendering + utf8 encoding: 1.36 ms
DList rendering + utf8 encoding: 0.91 ms
builder rendering (incl. utf8): 0.82 ms
builder + faster escaping: 0.65 ms
text builder: 0.95 ms
text builder + utf8 encoding: 1.10 ms
binary builder + char8 (!!): 1.22 ms
DList render + utf8-light: 4.12 ms
How to improve further?
* Use packed formats for string literals
- fast memcpy (that's what blaze-html does for tags)
- using Text literals should also help
results from criterion:
benchmarking nf maxiTable
mean: 257.2927 us, lb 255.9210 us, ub 259.6692 us, ci 0.950
std dev: 9.026280 us, lb 5.887942 us, ub 12.76582 us, ci 0.950
benchmarking renderTable maxiTable
mean: 1.358458 ms, lb 1.356732 ms, ub 1.362377 ms, ci 0.950
std dev: 12.66932 us, lb 7.110377 us, ub 24.97397 us, ci 0.950
benchmarking utf8 + renderTable maxiTable
mean: 1.364343 ms, lb 1.362391 ms, ub 1.366973 ms, ci 0.950
std dev: 11.65388 us, lb 9.094074 us, ub 17.47765 us, ci 0.950
benchmarking utf8 + renderTableD maxiTable
mean: 909.5255 us, lb 908.0049 us, ub 911.7639 us, ci 0.950
std dev: 9.434182 us, lb 6.906120 us, ub 15.43223 us, ci 0.950
benchmarking utf8-light + renderTable maxiTable
mean: 4.128315 ms, lb 4.121109 ms, ub 4.138436 ms, ci 0.950
std dev: 42.93755 us, lb 32.58115 us, ub 58.61780 us, ci 0.950
benchmarking char8 + renderTableBinB maxiTable
mean: 1.224156 ms, lb 1.222510 ms, ub 1.226101 ms, ci 0.950
std dev: 9.046150 us, lb 7.568433 us, ub 11.74996 us, ci 0.950
benchmarking renderTableTB maxiTable
mean: 954.8066 us, lb 953.6650 us, ub 957.0134 us, ci 0.950
std dev: 7.763098 us, lb 5.072194 us, ub 14.09216 us, ci 0.950
benchmarking utf8 + renderTableTB maxiTable
mean: 1.095913 ms, lb 1.094811 ms, ub 1.098280 ms, ci 0.950
std dev: 7.865781 us, lb 4.189907 us, ub 15.24606 us, ci 0.950
benchmarking utf8 + renderTableB maxiTable
mean: 818.0223 us, lb 816.5118 us, ub 819.9397 us, ci 0.950
std dev: 8.603917 us, lb 6.764347 us, ub 12.29236 us, ci 0.950
benchmarking utf8 + renderTableBE maxiTable
mean: 646.5248 us, lb 645.3735 us, ub 648.2405 us, ci 0.950
std dev: 7.147889 us, lb 5.222494 us, ub 11.82482 us, ci 0.950
-}
{- Conclusion:
-------------
* Whenever generating a sequence of bytes: use the 'Builder' type
=> chunks can always be kept large; impossible when exporting only
a strict/lazy bytestring interface.
=> filtering/mapping lazy bytestrings now automatically defragments
the output and guarantees a large chunk size.
* Status of work: API complete, documentation needs more reviewing.
* Bounded encodings: safely exploiting low-level optimizations
=> a performance advantage on other outputstream-libraries?
---------------
- Questions ? -
---------------
-}
{- Implementation outline:
------------------------
data BufferRange = BufferRange {-# UNPACK #-} !(Ptr Word8) -- First byte of range
{-# UNPACK #-} !(Ptr Word8) -- First byte /after/ range
newtype BuildStep a =
BuildStep { runBuildStep :: BufferRange -> IO (BuildSignal a) }
data BuildSignal a =
Done !(Ptr Word8) -- next free byte in current buffer
a -- return value
| BufferFull
!Int -- minimal size of next buffer
!(Ptr Word8) -- next free byte in current buffer
!(BuildStep a) -- continuation to call on next buffer
| InsertByteString
!(Ptr Word8) -- next free byte in current buffer
!S.ByteString -- bytestring to insert directly
!(BuildStep a) -- continuation to call on next buffer
-- | A "difference list" of build-steps.
newtype Builder = Builder (forall r. BuildStep r -> BuildStep r)
-- | The corresponding "Writer" monad.
newtype Put a = Put { unPut :: forall r. (a -> BuildStep r) -> BuildStep r }
-}
Jump to Line
Something went wrong with that request. Please try again.
|
{
"url": "https://github.com/meiersi/bytestring/blob/master/bench/CSV.hs",
"source_domain": "github.com",
"snapshot_id": "crawl=CC-MAIN-2015-32",
"warc_metadata": {
"Content-Length": "195492",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:NZXBDMJENNY7XEK4X5O6K764EC5GB7IL",
"WARC-Concurrent-To": "<urn:uuid:9bd4e625-a642-4723-9860-87bce4f5af46>",
"WARC-Date": "2015-07-29T05:41:32Z",
"WARC-IP-Address": "192.30.252.130",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:REEECIEHKJT2NB4AKTBCVRUGGVA7MXKB",
"WARC-Record-ID": "<urn:uuid:9478dbb1-6bbd-429d-a79c-f7f8b9c62e72>",
"WARC-Target-URI": "https://github.com/meiersi/bytestring/blob/master/bench/CSV.hs",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:3e0b0266-a1a3-49fe-ba17-1ae3069aed5b>"
},
"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,
16,
17,
33,
34,
58,
59,
78,
81,
83,
96,
119,
120,
162,
163,
194,
245,
250,
291,
329,
332,
381,
409,
445,
448,
517,
520,
545,
623,
687,
765,
789,
812,
878,
913,
978,
1023,
1067,
1085,
1108,
1184,
1187,
1219,
1250,
1325,
1343,
1369,
1397,
1425,
1430,
1475,
1506,
1563,
1607,
1610,
1639,
1667,
1738,
1784,
1853,
1856,
1878,
1899,
1963,
1995,
2020,
2045,
2117,
2193,
2246,
2319,
2322,
2345,
2367,
2443,
2463,
2541,
2554,
2557,
2595,
2638,
2679,
2726,
2745,
2776,
2798,
2821,
2859,
2926,
2991,
3027,
3060,
3114,
3162,
3200,
3247,
3293,
3343,
3366,
3411,
3490,
3513,
3592,
3619,
3630,
3656,
3674,
3693,
3709,
3729,
3769,
3784,
3832,
3859,
3862,
3893,
3915,
3918,
3979,
3998,
4034,
4113,
4139,
4218,
4251,
4305,
4311,
4330,
4351,
4371,
4400,
4442,
4471,
4498,
4516,
4591,
4622,
4678,
4689,
4714,
4785,
4796,
4825,
4882,
4956,
4991,
4994,
5027,
5106,
5133,
5212,
5243,
5255,
5287,
5302,
5320,
5323,
5367,
5416,
5451,
5524,
5530,
5579,
5627,
5651,
5682,
5726,
5760,
5789,
5812,
5832,
5905,
5938,
6008,
6018,
6048,
6107,
6167,
6194,
6259,
6332,
6365,
6444,
6475,
6554,
6581,
6607,
6628,
6639,
6660,
6709,
6788,
6820,
6899,
6927,
6954,
6992,
7033,
7093,
7121,
7151,
7194,
7247,
7267,
7331,
7381,
7418,
7463,
7490,
7553,
7588,
7662,
7722,
7782,
7848,
7892,
7895,
7931,
7951,
8015,
8021,
8054,
8063,
8132,
8201,
8212,
8244,
8290,
8325,
8355,
8379,
8400,
8475,
8509,
8581,
8592,
8630,
8698,
8759,
8791,
8860,
8939,
8974,
9053,
9081,
9116,
9181,
9187,
9219,
9251,
9271,
9302,
9346,
9389,
9418,
9441,
9461,
9530,
9563,
9629,
9640,
9668,
9725,
9811,
9890,
9920,
9999,
10010,
10043,
10110,
10170,
10210,
10244,
10312,
10346,
10381,
10387,
10436,
10467,
10470,
10549,
10588,
10667,
10743,
10782,
10807,
10841,
10889,
10932,
11006,
11012,
11059,
11105,
11128,
11167,
11217,
11254,
11291,
11317,
11340,
11418,
11459,
11534,
11545,
11582,
11652,
11718,
11797,
11813,
11892,
11931,
12009,
12015,
12036,
12057,
12083,
12118,
12164,
12201,
12234,
12258,
12279,
12356,
12393,
12467,
12478,
12508,
12561,
12618,
12629,
12663,
12727,
12799,
12878,
12894,
12973,
12987,
12997,
13031,
13071,
13115,
13147,
13208,
13220,
13232,
13242,
13256,
13274,
13291,
13313,
13339,
13358,
13381,
13400,
13427,
13429,
13435,
13486,
13537,
13564,
13590,
13632,
13673,
13713,
13748,
13770,
13808,
13845,
13880,
13904,
13945,
13998,
14037,
14061,
14087,
14147,
14210,
14245,
14305,
14368,
14410,
14470,
14533,
14576,
14636,
14699,
14747,
14807,
14870,
14917,
14977,
15040,
15077,
15137,
15200,
15244,
15304,
15367,
15410,
15470,
15533,
15577,
15637,
15700,
15703,
15718,
15732,
15798,
15865,
15901,
15969,
16015,
16083,
16146,
16206,
16222,
16238,
16254,
16257,
16284,
16309,
16391,
16447,
16469,
16533,
16554,
16608,
16626,
16639,
16675,
16724,
16778,
16797,
16846,
16893,
16947,
16988,
17053,
17092,
17169,
17172,
17185
],
"line_end_idx": [
16,
17,
33,
34,
58,
59,
78,
81,
83,
96,
119,
120,
162,
163,
194,
245,
250,
291,
329,
332,
381,
409,
445,
448,
517,
520,
545,
623,
687,
765,
789,
812,
878,
913,
978,
1023,
1067,
1085,
1108,
1184,
1187,
1219,
1250,
1325,
1343,
1369,
1397,
1425,
1430,
1475,
1506,
1563,
1607,
1610,
1639,
1667,
1738,
1784,
1853,
1856,
1878,
1899,
1963,
1995,
2020,
2045,
2117,
2193,
2246,
2319,
2322,
2345,
2367,
2443,
2463,
2541,
2554,
2557,
2595,
2638,
2679,
2726,
2745,
2776,
2798,
2821,
2859,
2926,
2991,
3027,
3060,
3114,
3162,
3200,
3247,
3293,
3343,
3366,
3411,
3490,
3513,
3592,
3619,
3630,
3656,
3674,
3693,
3709,
3729,
3769,
3784,
3832,
3859,
3862,
3893,
3915,
3918,
3979,
3998,
4034,
4113,
4139,
4218,
4251,
4305,
4311,
4330,
4351,
4371,
4400,
4442,
4471,
4498,
4516,
4591,
4622,
4678,
4689,
4714,
4785,
4796,
4825,
4882,
4956,
4991,
4994,
5027,
5106,
5133,
5212,
5243,
5255,
5287,
5302,
5320,
5323,
5367,
5416,
5451,
5524,
5530,
5579,
5627,
5651,
5682,
5726,
5760,
5789,
5812,
5832,
5905,
5938,
6008,
6018,
6048,
6107,
6167,
6194,
6259,
6332,
6365,
6444,
6475,
6554,
6581,
6607,
6628,
6639,
6660,
6709,
6788,
6820,
6899,
6927,
6954,
6992,
7033,
7093,
7121,
7151,
7194,
7247,
7267,
7331,
7381,
7418,
7463,
7490,
7553,
7588,
7662,
7722,
7782,
7848,
7892,
7895,
7931,
7951,
8015,
8021,
8054,
8063,
8132,
8201,
8212,
8244,
8290,
8325,
8355,
8379,
8400,
8475,
8509,
8581,
8592,
8630,
8698,
8759,
8791,
8860,
8939,
8974,
9053,
9081,
9116,
9181,
9187,
9219,
9251,
9271,
9302,
9346,
9389,
9418,
9441,
9461,
9530,
9563,
9629,
9640,
9668,
9725,
9811,
9890,
9920,
9999,
10010,
10043,
10110,
10170,
10210,
10244,
10312,
10346,
10381,
10387,
10436,
10467,
10470,
10549,
10588,
10667,
10743,
10782,
10807,
10841,
10889,
10932,
11006,
11012,
11059,
11105,
11128,
11167,
11217,
11254,
11291,
11317,
11340,
11418,
11459,
11534,
11545,
11582,
11652,
11718,
11797,
11813,
11892,
11931,
12009,
12015,
12036,
12057,
12083,
12118,
12164,
12201,
12234,
12258,
12279,
12356,
12393,
12467,
12478,
12508,
12561,
12618,
12629,
12663,
12727,
12799,
12878,
12894,
12973,
12987,
12997,
13031,
13071,
13115,
13147,
13208,
13220,
13232,
13242,
13256,
13274,
13291,
13313,
13339,
13358,
13381,
13400,
13427,
13429,
13435,
13486,
13537,
13564,
13590,
13632,
13673,
13713,
13748,
13770,
13808,
13845,
13880,
13904,
13945,
13998,
14037,
14061,
14087,
14147,
14210,
14245,
14305,
14368,
14410,
14470,
14533,
14576,
14636,
14699,
14747,
14807,
14870,
14917,
14977,
15040,
15077,
15137,
15200,
15244,
15304,
15367,
15410,
15470,
15533,
15577,
15637,
15700,
15703,
15718,
15732,
15798,
15865,
15901,
15969,
16015,
16083,
16146,
16206,
16222,
16238,
16254,
16257,
16284,
16309,
16391,
16447,
16469,
16533,
16554,
16608,
16626,
16639,
16675,
16724,
16778,
16797,
16846,
16893,
16947,
16988,
17053,
17092,
17169,
17172,
17185,
17242
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 17242,
"ccnet_original_nlines": 441,
"rps_doc_curly_bracket": 0.001855929964222014,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.11665698885917664,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03134068101644516,
"rps_doc_frac_lines_end_with_ellipsis": 0.009049770422279835,
"rps_doc_frac_no_alph_words": 0.4590829908847809,
"rps_doc_frac_unique_words": 0.3379732668399811,
"rps_doc_mean_word_length": 6.188196182250977,
"rps_doc_num_sentences": 334,
"rps_doc_symbol_to_word_ratio": 0.003482300089672208,
"rps_doc_unigram_entropy": 5.739658355712891,
"rps_doc_word_count": 1796,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.08556775003671646,
"rps_doc_frac_chars_dupe_6grams": 0.019524920731782913,
"rps_doc_frac_chars_dupe_7grams": 0.01664566993713379,
"rps_doc_frac_chars_dupe_8grams": 0.01664566993713379,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.010797189548611641,
"rps_doc_frac_chars_top_3gram": 0.010797189548611641,
"rps_doc_frac_chars_top_4gram": 0.010797189548611641,
"rps_doc_books_importance": -1521.1748046875,
"rps_doc_books_importance_length_correction": -1521.1748046875,
"rps_doc_openwebtext_importance": -793.2139282226562,
"rps_doc_openwebtext_importance_length_correction": -793.2139282226562,
"rps_doc_wikipedia_importance": -461.68853759765625,
"rps_doc_wikipedia_importance_length_correction": -461.68853759765625
},
"fasttext": {
"dclm": 0.1680222749710083,
"english": 0.4567200839519501,
"fineweb_edu_approx": 2.6293179988861084,
"eai_general_math": 0.5160773992538452,
"eai_open_web_math": 0.32849228382110596,
"eai_web_code": 0.6304045915603638
}
}
|
{
"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": "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
|
5,265,911,695,455,089,000
|
Main Content
MATLABMobile 기본 사항
MATLAB®에서 명령 실행 및 Figure 표시
MATLABMobile™에서, MathWorks® 클라우드에서 실행 중인 MATLAB에 액세스하여 파일과 데이터에 대해 여러 MATLAB 명령을 수행할 수 있습니다. 이 섹션에는 MATLABMobile에 적용되는 팁과 제한 사항이 담겨 있습니다.
도움말 항목
MATLAB 명령
명령 입력하기
MATLAB Mobile은 사용자가 기기에 입력하는 모든 명령을 클라우드로 보내 실행합니다.
자동 완성 사용하기
MATLAB Mobile의 자동 완성 기능을 사용하면 간편하게 입력할 수 있습니다.
Figure 보기
MATLABMobile 명령을 사용하여 Figure를 만들거나 업데이트할 때 MATLAB에 축소판 이미지와 더 큰 미리보기가 표시됩니다.
Figure 및 플롯
Figure 또는 코드 공유하기
코드 및 단일 Figure를 공유하거나 저장하는 방법.
내역에서 명령 또는 Figure 제거하기
내역에서 원치 않는 명령을 삭제하여 스크롤 성능을 개선합니다.
추천 예제
|
{
"url": "https://kr.mathworks.com/help/matlabmobile/matlab-mobile-fundamentals.html?s_tid=CRUX_lftnav",
"source_domain": "kr.mathworks.com",
"snapshot_id": "crawl=CC-MAIN-2020-50",
"warc_metadata": {
"Content-Length": "75849",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:NJMJMZU2B5OQD4SFXB3I5POGWPYRHDJM",
"WARC-Concurrent-To": "<urn:uuid:c3be65de-d76a-4745-a61f-7e791095cca1>",
"WARC-Date": "2020-11-26T21:38:14Z",
"WARC-IP-Address": "23.223.252.57",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:HLX5DND2453OKXFE6VJUUP2VPHOKMLMV",
"WARC-Record-ID": "<urn:uuid:59bb7763-0f62-4f68-97f1-bc67b9ab1112>",
"WARC-Target-URI": "https://kr.mathworks.com/help/matlabmobile/matlab-mobile-fundamentals.html?s_tid=CRUX_lftnav",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2496dd3d-b325-4a6c-bb13-4d80adfeab32>"
},
"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-195.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,
13,
14,
33,
34,
62,
63,
201,
202,
209,
210,
220,
221,
229,
230,
282,
283,
294,
295,
342,
343,
353,
354,
431,
432,
444,
445,
463,
464,
495,
496,
519,
520,
555,
556
],
"line_end_idx": [
13,
14,
33,
34,
62,
63,
201,
202,
209,
210,
220,
221,
229,
230,
282,
283,
294,
295,
342,
343,
353,
354,
431,
432,
444,
445,
463,
464,
495,
496,
519,
520,
555,
556,
561
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 561,
"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,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.056910570710897446,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.8130081295967102,
"rps_doc_frac_unique_words": 0.7545454502105713,
"rps_doc_mean_word_length": 7.336363792419434,
"rps_doc_num_sentences": 8,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.2901411056518555,
"rps_doc_word_count": 110,
"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.029739780351519585,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -46.15180206298828,
"rps_doc_books_importance_length_correction": -60.319427490234375,
"rps_doc_openwebtext_importance": -24.65793800354004,
"rps_doc_openwebtext_importance_length_correction": -38.8255615234375,
"rps_doc_wikipedia_importance": -24.319849014282227,
"rps_doc_wikipedia_importance_length_correction": -38.48747253417969
},
"fasttext": {
"dclm": 0.12077028304338455,
"english": 0.00001143000008596573,
"fineweb_edu_approx": 3.1061763763427734,
"eai_general_math": 0.0018593700369819999,
"eai_open_web_math": 0.0408739410340786,
"eai_web_code": 0.39227139949798584
}
}
|
{
"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.05",
"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": "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": "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": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-5,128,552,301,117,140,000
|
Use Zune Pass on Windows 8 Release Preview
Windows 8 is the next iteration of Windows. For those not as familiar, Windows 8 is a radical change as Microsoft is introducing the Metro design for Windows. You can find out more about Metro at http://en.wikipedia.org/wiki/Metro_(design_language)
With Windows 8, Microsoft is integrating a lot of its services to take advantage of its several platforms. Windows Phone, Xbox, Hotmail, Skydrive and other consumer services already uses one authentication via Live ID and it makes sense that the new OS will take advantage of this. If you’ve tried the pre-release versions of Windows 8, you can easily see the influence of this even from the login screen.
With this integration, news of rebranding of some services like the Zune are abound and I wouldn’t be surprised if that happens.
Anyways, if you’re using a Zune Pass, don’t fret as you can still access music just like before using the built in music app in Windows 8.
As I wanted to maximize the integration of the services with my new Windows 8. I loggedin using my hotmail account synced with Zune and lo and behold it actually works.
The music app works just like the Zune app but some features are missing like the mixed view. Some of the navigation features are still missing and adding songs to the current playlist doesn’t exist.
not really sure how to add songs to “now playing” and don’t tell me i haven’t tried “add to my music”
I know this is still an app preview so no surprises that these features are missing and I’m guessing that they are focusing on the main features so far.
There’s a bit of getting used to in the Music App. For one, there’s a lot of scrolling and clicking going on. Just to know the individual songs in the album, I have to do twice the clicks compared to the Zune app. Because of the design of Metro apps that has to cater for different form factors like tablets, this limits power users like me to navigate the app like everybody else. Whenever I use an app extensively, I learn as much shortcuts as I can as I want to get to the action as fast as I can. Browsers, email clients, OSes and such allow you to do this, but once an app is designed for multiple purposes it loses this advantage. I know Windows 8 has several shortcuts for you to get to the settings, the app bar, etc, but if you are navigating on the content of the application yourself, the developer has to create shortcuts of their own.
Overall, I’m very happy that the Zune will be continued (either as the Music app or something else) but I hope they empower the Music app just like the Zune. A nicely designed app that shows me what I want to see when searching and exploring new music. Come to think of it, the Zune app was one of the first applications to use the Metro language way back. A nice, cleanly made application that made great use of white space all through out.
If you are using Windows 8 Release Preview and notice any gems like these, please comment on. Would love to know what you think of the apps and how you’ll be using it.
PS. Super happy that Skitch is on Windows 8. Skitch is a photo annotating app on the Mac OS.
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://eugene17.com/2012/06/19/use-zune-pass-on-windows-8-release-preview/",
"source_domain": "eugene17.com",
"snapshot_id": "crawl=CC-MAIN-2020-05",
"warc_metadata": {
"Content-Length": "73611",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LUQJYZYRNGVE6LSMFFPJEKN4JLF2QHIJ",
"WARC-Concurrent-To": "<urn:uuid:6de3bfc3-bc78-4294-977a-19ca1a7c6033>",
"WARC-Date": "2020-01-22T23:14:43Z",
"WARC-IP-Address": "192.0.78.24",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:VEMMY3UKKUSTGTLKM4C5AQJUX2MMCZCG",
"WARC-Record-ID": "<urn:uuid:84044b51-7276-412a-93cc-93eb043be469>",
"WARC-Target-URI": "https://eugene17.com/2012/06/19/use-zune-pass-on-windows-8-release-preview/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:07711a57-3009-4d6f-ab27-c96ba7a4e132>"
},
"warc_info": "isPartOf: CC-MAIN-2020-05\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for January 2020\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-30.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,
43,
44,
293,
294,
700,
701,
830,
831,
970,
971,
1140,
1141,
1341,
1342,
1444,
1445,
1598,
1599,
2447,
2448,
2890,
2891,
3059,
3060,
3153,
3154,
3155,
3156,
3170,
3171,
3226,
3227,
3246,
3247,
3320,
3321,
3334,
3335,
3401,
3402,
3418,
3419,
3486,
3487,
3502,
3503,
3571,
3572
],
"line_end_idx": [
43,
44,
293,
294,
700,
701,
830,
831,
970,
971,
1140,
1141,
1341,
1342,
1444,
1445,
1598,
1599,
2447,
2448,
2890,
2891,
3059,
3060,
3153,
3154,
3155,
3156,
3170,
3171,
3226,
3227,
3246,
3247,
3320,
3321,
3334,
3335,
3401,
3402,
3418,
3419,
3486,
3487,
3502,
3503,
3571,
3572,
3588
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3588,
"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.4624505937099457,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.027667980641126633,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.13702240586280823,
"rps_doc_frac_unique_words": 0.4177018702030182,
"rps_doc_mean_word_length": 4.3881988525390625,
"rps_doc_num_sentences": 37,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.034590244293213,
"rps_doc_word_count": 644,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.03892426937818527,
"rps_doc_frac_chars_dupe_6grams": 0.02123142033815384,
"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.028308559209108353,
"rps_doc_frac_chars_top_3gram": 0.015569710172712803,
"rps_doc_frac_chars_top_4gram": 0.029723990708589554,
"rps_doc_books_importance": -295.3180236816406,
"rps_doc_books_importance_length_correction": -295.3180236816406,
"rps_doc_openwebtext_importance": -195.99966430664062,
"rps_doc_openwebtext_importance_length_correction": -195.99966430664062,
"rps_doc_wikipedia_importance": -128.48619079589844,
"rps_doc_wikipedia_importance_length_correction": -128.48619079589844
},
"fasttext": {
"dclm": 0.06815862655639648,
"english": 0.9351803064346313,
"fineweb_edu_approx": 1.285498023033142,
"eai_general_math": 0.0002124900056514889,
"eai_open_web_math": 0.03857874870300293,
"eai_web_code": 0.00009011999645736068
}
}
|
{
"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": "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": "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": "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": "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
|
-5,250,706,325,454,255,000
|
Download Youtube video
January 11, 2009
How to download Youtube videos has been done by a number of bloggers in a number of languages. I just wanted to try it out myself in Erlang, but I had no idea where to start.
Now that I’ve decided to start, let me grab an Eddie Vedder song from Youtube:
http://www.youtube.com/watch?v=gct6BB6ijcw
And lets sniff the HTTP traffic using Wireshark to see what actually happens when we watch a Youtube video. The browser made a conection to Youtube and before it started streaming the video, the input URL got redirected to a different Youtube URL (Depending on whether Youtube is caching the video or not, it could in turn probably be redirected to a different Cache server or a different IP):
No. Time Source Destination Protocol Info
96 3.295105 xx.xx.xx.xx 208.65.153.253 HTTP GET /get_video?video_id=gct6BB6ijcw&t=OEgsToPDskJ6n06uQXzbbyp7xAnxK6pN&el=detailpage&ps= HTTP/1.1
No. Time Source Destination Protocol Info
115 3.879454 xx.xx.xx.xx 209.85.239.30 HTTP GET /get_video?origin=lax-v113.lax.youtube.com&video_id=gct6BB6ijcw&ip=xx.xx.xx.xx®ion=0&signature=587F68CED7B14F380192AAB1D58942F0EAB9AE7B.6379C474E29D2B2348E1A69954D7FACFC461F964&sver=2&expire=1231731436&key=yt4&ipbits=0 HTTP/1.1
Upon playing with the new URL in the browser, I realized that the URL that Youtube gets the video from is
http://youtube.com/get_video?video_id=gct6BB6ijcw&t=OEgsToPDskJ-EKxTpxj79WK0fWWs_YjO
The param “video_id” is the same as the param “v” in the original URL. So we only need to find the value for the param “t”.
Lets look at the HTML source for
http://www.youtube.com/watch?v=gct6BB6ijcw
and see if it contains the value for the parameter “t”. Luckily, grepping for “&t=”, I found this in the source:
&t=OEgsToPDskKrsk1Xwku653CJbAXXrdJb
The value of “t” in the HTML source and the value of “t” in the redirect URL is different, but I found that both values of “t” seemed to work when appended to the URL. Oh well, I tried it again just to make sure and realized that the value of the parameter “t” changes for every request, but all values seem to work(Probably it is timestamp dependent!).
So we have a plan now:
1. Get a Youtube video URL and make a HTTP request to it.
2. Get the body of the reponse and find the value of “t” using regex pattern matching.
3. Generate the proper redirect URL using the two parameters “video_id” and “t”.
4. Make a http request to the new URL and stream the bytes and write to a file with “.flv” extension.
Here is the full source code in Erlang:
-module(video_downloader).
-export([download/1]).
download(URL) ->
{ok, {_Status, _Header, Body}} = http:request(URL),
Video_URL = get_video_download_url(URL, Body),
stream_video(Video_URL).
stream_video(Video_URL) ->
io:format("Downloading video from ~p~n", [Video_URL]),
{ok, {_Status, _Header, Body}} = http:request(Video_URL),
file:write_file("myvideo.flv", Body),
io:format("Download complete!").
get_video_download_url(URL, Body) ->
Matcher = "&t=[A-Za-z0-9-_]*",
{match, Start, Length} = regexp:first_match(Body, Matcher),
T = string:substr(Body, Start, Length),
{ok, New, _No} = regexp:sub(URL, "watch\?v=", "get_video?video_id="),
New ++ T.
Lets run it from the Erlang shell:
1> c(video_downloader.erl).
{ok,video_downloader}
2> inets:start().
ok
3> video_downloader:download("http://www.youtube.com/watch?v=gct6BB6ijcw").
Downloading video from "http://www.youtube.com/get_video?video_id=gct6BB6ijcw&t
=OEgsToPDskLUZgy2pfyoRf-AtXCdHhYG"
Download complete!ok
Go to your current directory and use any Flv Viewer to see if the downloaded file is a working video or convert it to format of your choice and watch it offline.
I would love to give an Erlang twist to it by spawning a few concurrent processes to download videos, but this is not quite a good example to do it from by localbox – too much of Disk IO, Network IO and slow Internet connection.
0 Comments on Download Youtube video
Respond | Trackback
Respond
Comments
Comments
|
{
"url": "http://sacharya.com/download-youtube-video/",
"source_domain": "sacharya.com",
"snapshot_id": "crawl=CC-MAIN-2019-26",
"warc_metadata": {
"Content-Length": "30449",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FASNN7GR3HBB3TV6LI7KIURV2RCSJUXB",
"WARC-Concurrent-To": "<urn:uuid:cc9096af-6ac4-41e7-8a34-4144db9420c7>",
"WARC-Date": "2019-06-25T23:37:03Z",
"WARC-IP-Address": "134.209.124.240",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:7RMJCILDI7RP3XADDKLGKQZZLZF6N5HB",
"WARC-Record-ID": "<urn:uuid:8a8035c8-9380-4f0a-a14f-76ee0bfe277d>",
"WARC-Target-URI": "http://sacharya.com/download-youtube-video/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5053f94a-b9c0-41b8-b0ee-b04f77295b53>"
},
"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-231-195-157.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,
23,
24,
41,
42,
217,
218,
297,
298,
341,
342,
736,
737,
815,
983,
984,
1062,
1367,
1368,
1474,
1475,
1560,
1561,
1685,
1718,
1719,
1762,
1763,
1876,
1877,
1913,
1914,
2268,
2269,
2292,
2350,
2437,
2518,
2620,
2621,
2662,
2663,
2690,
2713,
2714,
2731,
2787,
2838,
2867,
2868,
2895,
2954,
3016,
3058,
3095,
3096,
3133,
3168,
3232,
3276,
3350,
3364,
3365,
3400,
3401,
3429,
3451,
3469,
3472,
3548,
3628,
3663,
3684,
3685,
3847,
3848,
4077,
4078,
4115,
4116,
4136,
4137,
4145,
4146,
4155,
4156
],
"line_end_idx": [
23,
24,
41,
42,
217,
218,
297,
298,
341,
342,
736,
737,
815,
983,
984,
1062,
1367,
1368,
1474,
1475,
1560,
1561,
1685,
1718,
1719,
1762,
1763,
1876,
1877,
1913,
1914,
2268,
2269,
2292,
2350,
2437,
2518,
2620,
2621,
2662,
2663,
2690,
2713,
2714,
2731,
2787,
2838,
2867,
2868,
2895,
2954,
3016,
3058,
3095,
3096,
3133,
3168,
3232,
3276,
3350,
3364,
3365,
3400,
3401,
3429,
3451,
3469,
3472,
3548,
3628,
3663,
3684,
3685,
3847,
3848,
4077,
4078,
4115,
4116,
4136,
4137,
4145,
4146,
4155,
4156,
4164
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4164,
"ccnet_original_nlines": 85,
"rps_doc_curly_bracket": 0.0033621499314904213,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.290909081697464,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04385026916861534,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3272727429866791,
"rps_doc_frac_unique_words": 0.4711359441280365,
"rps_doc_mean_word_length": 5.715083599090576,
"rps_doc_num_sentences": 74,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.01651668548584,
"rps_doc_word_count": 537,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.046269141137599945,
"rps_doc_frac_chars_dupe_6grams": 0.03453893959522247,
"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.015640269964933395,
"rps_doc_frac_chars_top_3gram": 0.013033559545874596,
"rps_doc_frac_chars_top_4gram": 0.012707719579339027,
"rps_doc_books_importance": -340.2020263671875,
"rps_doc_books_importance_length_correction": -340.2020263671875,
"rps_doc_openwebtext_importance": -193.2306671142578,
"rps_doc_openwebtext_importance_length_correction": -193.2306671142578,
"rps_doc_wikipedia_importance": -108.25369262695312,
"rps_doc_wikipedia_importance_length_correction": -108.25369262695312
},
"fasttext": {
"dclm": 0.0992811918258667,
"english": 0.7104979157447815,
"fineweb_edu_approx": 2.0436036586761475,
"eai_general_math": 0.23804962635040283,
"eai_open_web_math": 0.16395068168640137,
"eai_web_code": 0.3046554923057556
}
}
|
{
"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": "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": "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
|
-249,894,201,805,130,300
|
0
i have an ihphone X with 64GB of storage and 200GB of icloud storage. as you can see bellow both of them have still available space.
Storage
Unfortunatelytely the "iPhone storage full, can't take a picture" notification still pops up. i tried workig something out via mac but nothing changed, also my iCloud storage says it's at 1% deespite the fact it has 114GB left... Can someone help?
1
That is iCloud online storage and not the actual device storage.
See My storage was not updated
You need the storage on the device to take a photo. Check it in Settings -> General -> iPhone Storage.
The iPhone itself has a fixed hardware memory, or space, which can only be chosen when you buy it, in 8, 16, 32, 64, 128, or 256 GB configurations. The total you see in Settings > General > Storage will never be quite this figure, as some of that is needed for the formatting of the memory & the data structure itself. This memory is where it stores all apps, music, documents etc that your phone can use.
enter image description here
You must log in to answer this question.
Not the answer you're looking for? Browse other questions tagged .
|
{
"url": "https://apple.stackexchange.com/questions/349974/iphone-and-icloud-storage-not-fill-but-isnt-allowing-me-to-take-a-picture/349994",
"source_domain": "apple.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2019-47",
"warc_metadata": {
"Content-Length": "123388",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:NDAME26AQREVYGIEICAV5CIEDLLF4WS6",
"WARC-Concurrent-To": "<urn:uuid:41ad363b-b710-408f-9b3d-8481f43f4bc3>",
"WARC-Date": "2019-11-21T03:24:26Z",
"WARC-IP-Address": "151.101.1.69",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:IM323TT6ODDX5FAVCKC7USVEF4HYMSJD",
"WARC-Record-ID": "<urn:uuid:123f572c-86a6-412e-b138-47475e7492fb>",
"WARC-Target-URI": "https://apple.stackexchange.com/questions/349974/iphone-and-icloud-storage-not-fill-but-isnt-allowing-me-to-take-a-picture/349994",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:3b5aa493-d4ca-4a20-9f7c-1e12a3918164>"
},
"warc_info": "isPartOf: CC-MAIN-2019-47\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for November 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-27.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,
2,
3,
136,
137,
145,
146,
394,
395,
397,
398,
463,
464,
495,
496,
599,
600,
1006,
1007,
1036,
1037,
1078,
1079
],
"line_end_idx": [
2,
3,
136,
137,
145,
146,
394,
395,
397,
398,
463,
464,
495,
496,
599,
600,
1006,
1007,
1036,
1037,
1078,
1079,
1145
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1145,
"ccnet_original_nlines": 22,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4485596716403961,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.020576130598783493,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.19341564178466797,
"rps_doc_frac_unique_words": 0.6336633563041687,
"rps_doc_mean_word_length": 4.381187915802002,
"rps_doc_num_sentences": 14,
"rps_doc_symbol_to_word_ratio": 0.0041152299381792545,
"rps_doc_unigram_entropy": 4.607843399047852,
"rps_doc_word_count": 202,
"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.02259887009859085,
"rps_doc_frac_chars_top_3gram": 0.038418080657720566,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -104.52979278564453,
"rps_doc_books_importance_length_correction": -104.52979278564453,
"rps_doc_openwebtext_importance": -48.658695220947266,
"rps_doc_openwebtext_importance_length_correction": -45.16554260253906,
"rps_doc_wikipedia_importance": -22.861555099487305,
"rps_doc_wikipedia_importance_length_correction": -22.861555099487305
},
"fasttext": {
"dclm": 0.21468985080718994,
"english": 0.9428207874298096,
"fineweb_edu_approx": 1.197031855583191,
"eai_general_math": 0.0007724799797870219,
"eai_open_web_math": 0.21929669380187988,
"eai_web_code": 0.0003697900101542473
}
}
|
{
"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": "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": "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": "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
|
-639,713,221,275,235,800
|
Smokeping_probes_EchoPingDNS man page
Smokeping::probes::EchoPingDNS — an echoping(1) probe for SmokePing
Overview
Measures DNS roundtrip times for SmokePing with the echoping_dns plugin.
Synopsis
*** Probes ***
+EchoPingDNS
binary = /usr/bin/echoping
forks = 5
offset = 50%
step = 300
# The following variables can be overridden in each target section
dns_request = example.org # mandatory
dns_tcp = yes
dns_type = AAAA
extraopts = -some-letter-the-author-did-not-think-of
ipversion = 4
pings = 5
plugin = /path/to/dns.so
pluginargs = -p plugin_specific_arg
priority = 6
timeout = 1
tos = 0xa0
waittime = 1
# [...]
*** Targets ***
probe = EchoPingDNS # if this should be the default probe
# [...]
+ mytarget
# probe = EchoPingDNS # if the default probe is something else
host = my.host
dns_request = example.org # mandatory
dns_tcp = yes
dns_type = AAAA
extraopts = -some-letter-the-author-did-not-think-of
ipversion = 4
pings = 5
plugin = /path/to/dns.so
pluginargs = -p plugin_specific_arg
priority = 6
timeout = 1
tos = 0xa0
waittime = 1
Variables
Supported probe-specific variables:
binary
The location of your echoping binary.
Default value: /usr/bin/echoping
forks
Run this many concurrent processes at maximum
Example value: 5
Default value: 5
offset
If you run many probes concurrently you may want to prevent them from hitting your network all at the same time. Using the probe-specific offset parameter you can change the point in time when each probe will be run. Offset is specified in % of total interval, or alternatively as 'random', and the offset from the 'General' section is used if nothing is specified here. Note that this does NOT influence the rrds itself, it is just a matter of when data acqusition is initiated. (This variable is only applicable if the variable 'concurrentprobes' is set in the 'General' section.)
Example value: 50%
step
Duration of the base interval that this probe should use, if different from the one specified in the 'Database' section. Note that the step in the RRD files is fixed when they are originally generated, and if you change the step parameter afterwards, you'll have to delete the old RRD files or somehow convert them. (This variable is only applicable if the variable 'concurrentprobes' is set in the 'General' section.)
Example value: 300
Supported target-specific variables:
dns_request
The DNS request (domain name) to be queried.
Example value: example.org
This setting is mandatory.
dns_tcp
The echoping_dns '--tcp' option: use only TCP ('virtual circuit'). Enabled if specified with a value other than 'no' or '0'.
Example value: yes
dns_type
The echoping_dns '-t' option: type of data requested (NS, A, SOA etc.)
Example value: AAAA
Default value: A
extraopts
Any extra options specified here will be passed unmodified to echoping(1).
Example value: -some-letter-the-author-did-not-think-of
ipversion
The IP protocol used. Possible values are "4" and "6". Passed to echoping(1) as the "-4" or "-6" options.
Example value: 4
pings
How many pings should be sent to each target, if different from the global value specified in the Database section. Note that the number of pings in the RRD files is fixed when they are originally generated, and if you change this parameter afterwards, you'll have to delete the old RRD files or somehow convert them.
Example value: 5
plugin
The echoping plugin that will be used. See echoping(1) for details. This can either be the name of the plugin or a full path to the plugin shared object.
Example value: /path/to/dns.so
Default value: dns
pluginargs
Any extra arguments needed by the echoping plugin specified with the pluginname variable. These are generally provided by the subclass probe.
Example value: -p plugin_specific_arg
priority
The "-p" echoping(1) option.
Example value: 6
timeout
The "-t" echoping(1) option.
Example value: 1
Default value: 5
tos
The "-P" echoping(1) option.
Example value: 0xa0
waittime
The "-w" echoping(1) option.
Example value: 1
Authors
Niko Tyni <ntyni@iki.fi>
Notes
The fill, size and udp EchoPing variables are not valid.
Plugins, including echoping_dns, are available starting with echoping version 6.
See Also
Smokeping::probes::EchoPing, Smokeping::probes::EchoPingPlugin
Info
2017-10-24 2.6.11 SmokePing
|
{
"url": "https://www.mankier.com/3/Smokeping_probes_EchoPingDNS",
"source_domain": "www.mankier.com",
"snapshot_id": "crawl=CC-MAIN-2017-47",
"warc_metadata": {
"Content-Length": "9339",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:IFPM4RKO55THKY4QXI47DRRC3R5KLBL3",
"WARC-Concurrent-To": "<urn:uuid:b9a9097b-b6e3-43e5-8c69-841a669d6621>",
"WARC-Date": "2017-11-21T15:44:40Z",
"WARC-IP-Address": "104.28.22.53",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:ZRSWQ4EV7V6PBWKQISYNV7CC2WHINT3K",
"WARC-Record-ID": "<urn:uuid:c96ccbe3-c1d5-4437-9262-9aba59ce7afe>",
"WARC-Target-URI": "https://www.mankier.com/3/Smokeping_probes_EchoPingDNS",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:76167f70-b3e9-43d3-b90d-79fde0f6a6f7>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-159-1-36.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,
38,
39,
107,
108,
117,
118,
191,
192,
201,
202,
218,
219,
233,
234,
262,
273,
287,
299,
300,
368,
407,
422,
439,
493,
508,
519,
545,
582,
596,
609,
621,
635,
636,
645,
646,
663,
664,
723,
724,
733,
734,
746,
810,
826,
865,
880,
897,
951,
966,
977,
1003,
1040,
1054,
1067,
1079,
1093,
1094,
1104,
1105,
1141,
1142,
1149,
1150,
1188,
1189,
1222,
1223,
1229,
1230,
1276,
1277,
1294,
1295,
1312,
1313,
1320,
1321,
1904,
1905,
1924,
1925,
1930,
1931,
2350,
2351,
2370,
2371,
2408,
2409,
2421,
2422,
2467,
2468,
2495,
2496,
2523,
2524,
2532,
2533,
2658,
2659,
2678,
2679,
2688,
2689,
2760,
2761,
2781,
2782,
2799,
2800,
2810,
2811,
2886,
2887,
2943,
2944,
2954,
2955,
3062,
3063,
3080,
3081,
3087,
3088,
3406,
3407,
3424,
3425,
3432,
3433,
3587,
3588,
3619,
3620,
3639,
3640,
3651,
3652,
3795,
3796,
3834,
3835,
3844,
3845,
3874,
3875,
3892,
3893,
3901,
3902,
3931,
3932,
3949,
3950,
3967,
3968,
3972,
3973,
4002,
4003,
4023,
4024,
4033,
4034,
4063,
4064,
4081,
4082,
4090,
4091,
4116,
4117,
4123,
4124,
4181,
4182,
4263,
4264,
4273,
4274,
4338,
4339,
4344,
4345
],
"line_end_idx": [
38,
39,
107,
108,
117,
118,
191,
192,
201,
202,
218,
219,
233,
234,
262,
273,
287,
299,
300,
368,
407,
422,
439,
493,
508,
519,
545,
582,
596,
609,
621,
635,
636,
645,
646,
663,
664,
723,
724,
733,
734,
746,
810,
826,
865,
880,
897,
951,
966,
977,
1003,
1040,
1054,
1067,
1079,
1093,
1094,
1104,
1105,
1141,
1142,
1149,
1150,
1188,
1189,
1222,
1223,
1229,
1230,
1276,
1277,
1294,
1295,
1312,
1313,
1320,
1321,
1904,
1905,
1924,
1925,
1930,
1931,
2350,
2351,
2370,
2371,
2408,
2409,
2421,
2422,
2467,
2468,
2495,
2496,
2523,
2524,
2532,
2533,
2658,
2659,
2678,
2679,
2688,
2689,
2760,
2761,
2781,
2782,
2799,
2800,
2810,
2811,
2886,
2887,
2943,
2944,
2954,
2955,
3062,
3063,
3080,
3081,
3087,
3088,
3406,
3407,
3424,
3425,
3432,
3433,
3587,
3588,
3619,
3620,
3639,
3640,
3651,
3652,
3795,
3796,
3834,
3835,
3844,
3845,
3874,
3875,
3892,
3893,
3901,
3902,
3931,
3932,
3949,
3950,
3967,
3968,
3972,
3973,
4002,
4003,
4023,
4024,
4033,
4034,
4063,
4064,
4081,
4082,
4090,
4091,
4116,
4117,
4123,
4124,
4181,
4182,
4263,
4264,
4273,
4274,
4338,
4339,
4344,
4345,
4372
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4372,
"ccnet_original_nlines": 185,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.30250272154808044,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.018498370423913002,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3144722580909729,
"rps_doc_frac_unique_words": 0.36824876070022583,
"rps_doc_mean_word_length": 5.382978916168213,
"rps_doc_num_sentences": 45,
"rps_doc_symbol_to_word_ratio": 0.010881390422582626,
"rps_doc_unigram_entropy": 4.963472843170166,
"rps_doc_word_count": 611,
"rps_doc_frac_chars_dupe_10grams": 0.24992398917675018,
"rps_doc_frac_chars_dupe_5grams": 0.3101246654987335,
"rps_doc_frac_chars_dupe_6grams": 0.29309821128845215,
"rps_doc_frac_chars_dupe_7grams": 0.27424749732017517,
"rps_doc_frac_chars_dupe_8grams": 0.27424749732017517,
"rps_doc_frac_chars_dupe_9grams": 0.24992398917675018,
"rps_doc_frac_chars_top_2gram": 0.05472787842154503,
"rps_doc_frac_chars_top_3gram": 0.02675585076212883,
"rps_doc_frac_chars_top_4gram": 0.032836731523275375,
"rps_doc_books_importance": -404.9613037109375,
"rps_doc_books_importance_length_correction": -404.9613037109375,
"rps_doc_openwebtext_importance": -262.8345947265625,
"rps_doc_openwebtext_importance_length_correction": -262.8345947265625,
"rps_doc_wikipedia_importance": -196.2947235107422,
"rps_doc_wikipedia_importance_length_correction": -196.2947235107422
},
"fasttext": {
"dclm": 0.14301139116287231,
"english": 0.6813252568244934,
"fineweb_edu_approx": 3.11436128616333,
"eai_general_math": 0.935429573059082,
"eai_open_web_math": 0.2496582269668579,
"eai_web_code": 0.9887871146202087
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.656",
"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": "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": "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,835,781,592,771,008,500
|
What Is Cloud Gaming, And How Does It Work?
Cloud gaming is an innovative approach that allows you to play high-quality video games without needing a powerful console or gaming PC. Instead, the games are run on remote servers and streamed directly to your device over the internet. This means you can enjoy the latest titles on your phone, tablet, or even a basic laptop, with all the heavy lifting done in the cloud. All you need is a stable internet connection, and you’re ready to dive into expansive game worlds with minimal fuss. This article dives into how cloud gaming operates, the technology behind it, and what benefits it offers to you as a gamer. Have you ever wondered what cloud gaming is and how it actually works? If you’re curious about diving into this exciting world of gaming, you’re in the right place. Let’s take a detailed look at cloud gaming, unravel its intricate working, and understand its impacts on gaming as we know it.
What Is Cloud Gaming, And How Does It Work?
Learn More On Amazon
What Is Cloud Gaming?
Cloud gaming, also known as game streaming, is a technology that allows you to play video games on virtually any device without the need for high-end hardware. Think of it as Netflix for games. Instead of purchasing or downloading games to your local device, you stream them directly from powerful servers located far away. This technology opens up a new realm of possibilities for gamers who want flexibility and affordability.
How Does Cloud Gaming Compare to Traditional Gaming?
To better understand cloud gaming, let’s compare it to traditional gaming methods.
Feature Traditional Gaming Cloud Gaming
Hardware Requirements High. Requires high-end consoles or PCs. Low. Only requires a stable internet connection and minimal local hardware.
Game Access Buy physical or digital copies of games. Access through a subscription or pay-per-game model.
Storage Space Large. Requires significant local storage for game files. Minimal. Games are stored on remote servers.
Performance Dependent on your device’s specs. Dependent on your internet speed and server performance.
Updates and Patches User is responsible for downloading updates. Updates are managed on the server side and are usually seamless for the user.
The Mechanics of Cloud Gaming
Let’s break down how cloud gaming works step-by-step. The process is both fascinating and complex.
Data Centers and Servers
The backbone of cloud gaming is its data centers and game servers. These servers handle all the game processing, from graphics rendering to AI calculations. Instead of your console or PC doing the heavy lifting, these robust servers handle everything.
Game Streaming
When you start a game on a cloud gaming platform, here’s what happens:
1. Request Initiated: You send a command to the cloud server to start a game.
2. Processing: The server processes the game in real-time, handling all the computations and graphics rendering.
3. Video Compression: The game’s video output is compressed into a streaming format.
4. Streaming: The compressed video stream is sent over the internet to your device.
5. Input Commands: Your inputs (keyboard, controller, mouse) are sent back to the server, which adjusts the gameplay accordingly.
Low Latency Concerns
One of the critical aspects of cloud gaming is latency, which is the delay between your inputs and the server’s response. Lower latency means smoother gameplay. Ensuring low latency involves optimizing server locations, network infrastructure, and efficient data compression methods.
What Is Cloud Gaming, And How Does It Work?
Learn More On Amazon
Popular Cloud Gaming Services
Several major companies have ventured into the cloud gaming arena. Here’s a look at some of the leading players:
Service Description
NVIDIA GeForce Now Allows you to stream PC games you already own from various digital stores.
Google Stadia Offers an extensive library of games including exclusives; integrates with YouTube for gameplay sharing.
Microsoft xCloud Part of the Xbox Game Pass Ultimate; stream Xbox games to multiple devices.
PlayStation Now Sony’s service featuring a library of PlayStation games spanning multiple generations.
Amazon Luna Offers multiple “channels” with curated game selections and integration with Twitch.
Subscription Models
Most cloud gaming services operate on a subscription-based model, though some also offer free tiers with limited features or pay-per-game options.
Benefits of Cloud Gaming
Cloud gaming brings numerous advantages to the table. Whether you’re a casual gamer or a hardcore enthusiast, there’s something in it for everyone.
Accessibility
Since high-end hardware isn’t required, anyone with a decent internet connection can enjoy AAA games. This makes gaming more inclusive and accessible.
Instant Play
Say goodbye to lengthy downloads and installations. Cloud gaming allows you to start playing almost immediately, as everything runs on the server.
Device Flexibility
Play games on your laptop, smartphone, tablet, or even some smart TVs. Your gaming experience is no longer tied to one specific device.
Cost-Effective
No need to invest in expensive gaming consoles or PCs. Subscription models spread the cost over time, making it more affordable.
What Is Cloud Gaming, And How Does It Work?
Challenges and Limitations
Despite its promising potential, cloud gaming does have some drawbacks that can’t be overlooked.
Internet Dependency
A stable and high-speed internet connection is non-negotiable. Any lag or disconnection can severely impact your gaming experience.
Latency Issues
Even with advancements, latency is a challenge. Competitive gamers, in particular, might find the millisecond delays unacceptable.
Limited Game Libraries
Not all games are available on all services. The library can be restrictive depending on the platform you choose.
Data Consumption
Streaming games in high-definition can consume significant amounts of data, which may not be ideal for users with data caps.
Future of Cloud Gaming
The future looks promising for cloud gaming, with several advancements on the horizon. Here are some trends to watch out for:
5G Technology
The rollout of 5G networks promises much higher speeds and lower latency, which could be a game-changer for cloud gaming.
Cross-Platform Play
Enhanced cross-platform capabilities will allow players using different hardware to play together seamlessly.
AI Enhancements
Artificial Intelligence could further optimize the gaming experience by predicting user behavior or managing server loads more efficiently.
Increased Game Libraries
With more developers embracing the cloud model, the game libraries are expected to grow, offering more choices and exclusive titles.
How to Get Started with Cloud Gaming
If you’re interested in jumping into cloud gaming, here’s a simple guide to get you started.
Choose Your Service
Begin by selecting a cloud gaming service that best fits your needs. Consider factors like game library, subscription cost, and supported devices.
Check System Requirements
While you don’t need high-end hardware, ensure that your device meets the basic requirements laid out by the service provider. Also, check your internet connection speed.
Sign Up
Create an account and choose a subscription plan. Most services offer a free trial period, so you can test before committing.
Setup Peripherals
Connect any needed peripherals (controllers, keyboards, mice) to your device. Some services offer specialized controllers designed for cloud gaming, though most standard peripherals will work.
Start Playing
Browse the game library, select a game, and start playing. Enjoy the seamless gaming experience!
Cloud Gaming: Case Studies
To better understand the impact and applications of cloud gaming, let’s look at a few real-world case studies.
Case Study 1: Google Stadia
Objective: Google aimed to revolutionize gaming with a platform that allows users to stream games directly via Chrome browser or a Chromecast device.
Implementation: Launched in 2019, Stadia offers an extensive library including exclusives and integrates directly with YouTube for easy gameplay streaming.
Outcome: While reception has been mixed, the platform has steadily improved, benefiting from Google’s robust cloud infrastructure.
Case Study 2: Microsoft xCloud
Objective: Microsoft wanted to extend the Xbox gaming experience across multiple devices seamlessly.
Implementation: xCloud is part of Xbox Game Pass Ultimate, allowing users to stream Xbox games on smartphones, tablets, and PCs without additional hardware.
Outcome: Widely praised for its game library and integration with Xbox services, xCloud has become a key player in the cloud gaming market.
Case Study 3: NVIDIA GeForce Now
Objective: NVIDIA aimed to leverage its expertise in GPUs to deliver high-quality game streaming.
Implementation: Launched in 2020, GeForce Now allows gamers to play PC games they already own from platforms like Steam and Epic Games Store, streaming them from NVIDIA’s powerful servers.
Outcome: Lauded for its performance and flexibility, GeForce Now continues to attract a growing user base.
Conclusion
Cloud gaming represents a significant shift in the way we interact with and access video games. By offloading heavy processing tasks to powerful remote servers, it makes gaming more accessible, flexible, and cost-effective. While there are challenges to overcome, particularly around latency and internet dependency, the future of cloud gaming looks incredibly promising. Advanced technologies like 5G and AI will undoubtedly make cloud gaming an even more integral part of the gaming ecosystem.
Whether you are a seasoned gamer looking for flexibility or a newcomer eager to dip your toes into gaming without hefty investments, cloud gaming offers something valuable for everyone. So why not give it a try and see how it transforms your gaming experience?
Learn More On Amazon
RavenPixel
Hey there, I'm "RavenPixel," but you can call me "The Gaming Oracle." I'm here at The Gaming Mecca to be your ultimate guide through the labyrinth of the gaming world. From chairs that feel like thrones to laptops that won’t flinch in a boss fight, I've got you covered. Curious about what gear can really elevate your gameplay? Stick around, we’re just scratching the surface. Soon, I’ll dig into burning questions like, "Do curved monitors actually give you an edge?" and "Are gaming glasses the future or just a fad?" Brace yourself for an epic journey through the land of pixels and peripherals. Your next gaming level starts here, and let me tell you, it's going to be legendary.
More to Explore
Minecraft Farm
Discover the enchanting world of "Minecraft Farm" in this immersive post. Learn about farming techniques, crop varieties, animal husbandry, and more. Unleash your creativity and embark on a limitless farming adventure.
|
{
"url": "https://thegamingmecca.com/what-is-cloud-gaming-and-how-does-it-work/",
"source_domain": "thegamingmecca.com",
"snapshot_id": "CC-MAIN-2024-26",
"warc_metadata": {
"Content-Length": "98793",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LBM3SDCIO6KXG5MXHRWHYLN53O3K6JIB",
"WARC-Concurrent-To": "<urn:uuid:17391e81-3d33-49af-825e-7b1fb4b8adb4>",
"WARC-Date": "2024-06-19T21:08:04Z",
"WARC-IP-Address": "51.222.105.41",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:VJK5W7OM7HICD5IU7GWWPFLD22XIEWAA",
"WARC-Record-ID": "<urn:uuid:af0d9eca-6417-4de9-a5f1-141b7fa850e6>",
"WARC-Target-URI": "https://thegamingmecca.com/what-is-cloud-gaming-and-how-does-it-work/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:3fcd5a51-b252-49dd-9bce-91e57090de70>"
},
"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-207\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,
44,
45,
952,
953,
997,
998,
1019,
1020,
1042,
1043,
1472,
1473,
1526,
1527,
1610,
1611,
1651,
1790,
1896,
2013,
2116,
2259,
2260,
2290,
2291,
2390,
2391,
2416,
2417,
2669,
2670,
2685,
2686,
2757,
2758,
2838,
2953,
3040,
3126,
3258,
3259,
3280,
3281,
3565,
3566,
3610,
3611,
3632,
3633,
3663,
3664,
3777,
3778,
3798,
3892,
4011,
4104,
4207,
4304,
4305,
4325,
4326,
4473,
4474,
4499,
4500,
4648,
4649,
4663,
4664,
4815,
4816,
4829,
4830,
4977,
4978,
4997,
4998,
5134,
5135,
5150,
5151,
5280,
5281,
5325,
5326,
5353,
5354,
5451,
5452,
5472,
5473,
5605,
5606,
5621,
5622,
5753,
5754,
5777,
5778,
5892,
5893,
5910,
5911,
6036,
6037,
6060,
6061,
6187,
6188,
6202,
6203,
6325,
6326,
6346,
6347,
6457,
6458,
6474,
6475,
6615,
6616,
6641,
6642,
6775,
6776,
6813,
6814,
6907,
6908,
6928,
6929,
7076,
7077,
7103,
7104,
7275,
7276,
7284,
7285,
7411,
7412,
7430,
7431,
7624,
7625,
7639,
7640,
7737,
7738,
7765,
7766,
7877,
7878,
7906,
7907,
8057,
8058,
8214,
8215,
8346,
8347,
8378,
8379,
8480,
8481,
8638,
8639,
8779,
8780,
8813,
8814,
8912,
8913,
9102,
9103,
9210,
9211,
9222,
9223,
9719,
9720,
9981,
9982,
10003,
10004,
10015,
10016,
10701,
10702,
10703,
10719,
10720,
10735,
10736
],
"line_end_idx": [
44,
45,
952,
953,
997,
998,
1019,
1020,
1042,
1043,
1472,
1473,
1526,
1527,
1610,
1611,
1651,
1790,
1896,
2013,
2116,
2259,
2260,
2290,
2291,
2390,
2391,
2416,
2417,
2669,
2670,
2685,
2686,
2757,
2758,
2838,
2953,
3040,
3126,
3258,
3259,
3280,
3281,
3565,
3566,
3610,
3611,
3632,
3633,
3663,
3664,
3777,
3778,
3798,
3892,
4011,
4104,
4207,
4304,
4305,
4325,
4326,
4473,
4474,
4499,
4500,
4648,
4649,
4663,
4664,
4815,
4816,
4829,
4830,
4977,
4978,
4997,
4998,
5134,
5135,
5150,
5151,
5280,
5281,
5325,
5326,
5353,
5354,
5451,
5452,
5472,
5473,
5605,
5606,
5621,
5622,
5753,
5754,
5777,
5778,
5892,
5893,
5910,
5911,
6036,
6037,
6060,
6061,
6187,
6188,
6202,
6203,
6325,
6326,
6346,
6347,
6457,
6458,
6474,
6475,
6615,
6616,
6641,
6642,
6775,
6776,
6813,
6814,
6907,
6908,
6928,
6929,
7076,
7077,
7103,
7104,
7275,
7276,
7284,
7285,
7411,
7412,
7430,
7431,
7624,
7625,
7639,
7640,
7737,
7738,
7765,
7766,
7877,
7878,
7906,
7907,
8057,
8058,
8214,
8215,
8346,
8347,
8378,
8379,
8480,
8481,
8638,
8639,
8779,
8780,
8813,
8814,
8912,
8913,
9102,
9103,
9210,
9211,
9222,
9223,
9719,
9720,
9981,
9982,
10003,
10004,
10015,
10016,
10701,
10702,
10703,
10719,
10720,
10735,
10736,
10954
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 10954,
"ccnet_original_nlines": 195,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 1,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3177987039089203,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.009915719740092754,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.14923152327537537,
"rps_doc_frac_unique_words": 0.3841099143028259,
"rps_doc_mean_word_length": 5.323775291442871,
"rps_doc_num_sentences": 120,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.720863342285156,
"rps_doc_word_count": 1674,
"rps_doc_frac_chars_dupe_10grams": 0.01122082956135273,
"rps_doc_frac_chars_dupe_5grams": 0.03590663895010948,
"rps_doc_frac_chars_dupe_6grams": 0.01862657070159912,
"rps_doc_frac_chars_dupe_7grams": 0.01862657070159912,
"rps_doc_frac_chars_dupe_8grams": 0.01862657070159912,
"rps_doc_frac_chars_dupe_9grams": 0.01862657070159912,
"rps_doc_frac_chars_top_2gram": 0.04813734069466591,
"rps_doc_frac_chars_top_3gram": 0.010210949927568436,
"rps_doc_frac_chars_top_4gram": 0.00953769963234663,
"rps_doc_books_importance": -825.7051391601562,
"rps_doc_books_importance_length_correction": -825.7051391601562,
"rps_doc_openwebtext_importance": -489.09173583984375,
"rps_doc_openwebtext_importance_length_correction": -489.09173583984375,
"rps_doc_wikipedia_importance": -414.2618408203125,
"rps_doc_wikipedia_importance_length_correction": -414.2618408203125
},
"fasttext": {
"dclm": 0.3706194758415222,
"english": 0.9075287580490112,
"fineweb_edu_approx": 1.7744779586791992,
"eai_general_math": 0.0029812499415129423,
"eai_open_web_math": 0.04894733056426048,
"eai_web_code": 0.02070409059524536
}
}
|
{
"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": "794.8",
"labels": {
"level_1": "Arts",
"level_2": "Amusements and Recreation",
"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": "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": "16",
"label": "Personal Blog"
}
},
"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
|
2,824,319,237,853,203,000
|
• 0 Votes
2 Posts
82 Views
Hi,
Thanks for the suggestion. We're actually working on more country support right now - so adding segment criteria for it makes total sense.
As for the "OR" and "AND" support - the system currently supports "AND" ...
... but yeah, adding "OR" will be a bigger deal.
I'll run it by the devs and add it to the roadmap with your +1 though...
Paul.
• New Pricing based Studio
Feature Suggestions
2
0 Votes
2 Posts
78 Views
Hi Lee,
brainCloud's pricing models are designed to accommodate changes in usage over time.
Apps using Enterprise features in the Business/Business + plans are still allowed to access those features if they later downgrade to Standard or Lite plans. Note that the app will no longer be covered by the Business / Business Plus plan SLA though.
I hope that helps!
Paul
• 1 Votes
9 Posts
224 Views
@Brad-Hester That bug has been fixes (and patched). Thanks for reporting it!
• Filter online players in Matchmaking
Solved Cloud Code
8
0 Votes
8 Posts
300 Views
Ciao @Paul-Winterhalder ,
yes there is not much else to add, except perhaps the fact that the CompleteMatch is sent at the end of the game. Instead, AbandonMatch is sent if one of the players abandons the game prematurely.
Thanks for the support! 🙂
• Cloud Code not loading in Console
Solved General
2
0 Votes
2 Posts
111 Views
In case anyone else had a similar issue...
There was a Cloudflare-related cert issue associated with a site called cdn.jsdelivr.net.
As I understand it, the Monaco editor that Portal-X uses for editing source and JSON files (and many other common web-based components) makes use of that site.
More details on the issue here: https://github.com/jsdelivr/jsdelivr/issues/18565
The issue was temporary - and seems like it only affected only certain localized regions... (just a guess on my part there).
Anyway - all good now - and nothing directly related to brainCloud.
Paul.
• [Unity] In App Purchases
Solved APIs
2
0 Votes
2 Posts
239 Views
brainCloud supports a wide range of popular in-app purchases, including Google Play, Apple, Facebook, Amazon, and Steam, etc.. In most cases, the purchase process is initiated through the corresponding IAP plugin that you need to download into your Unity project. Then, verify the receipt received from the purchase outcome with brainCloud by calling VerifyPurchase API. It should be noted that the necessary configuration for the IAP store must be set up in the brainCloud portal for your app, including the products section and platforms section. Some store integration examples are available on our documentation website -- https://docs.braincloudservers.com/learn/portal-tutorials/store-integration-google/
Hope this helps!
• 0 Votes
5 Posts
602 Views
Diving into our new game and found a work-around ~ use private viewing. I have our reference game open in a private window, and the new project in the main one.
• Memcache in Braincloud
Unsolved General
2
0 Votes
2 Posts
228 Views
Hi Nguyen,
brainCloud makes use of both Memcached and Redis as part of it's architecture - but we do not directly expose these in our APIs.
What was your use case?
Paul.
• Reconnect to room on a Relay Server
Unsolved General
30
0 Votes
30 Posts
798 Views
Ciao @Greg-Moulds,
you rock boy! 🙂
I tried reducing the "early" launch setting as you suggested and in fact now the waiting time is very short. That was exactly the problem.
Thanks!
• Huge Demo Release!
Videos and Tutorials
1
2 Votes
1 Posts
435 Views
No one has replied
• 0 Votes
7 Posts
250 Views
Thank you both for the helpful replies. I am educating myself further and exploring options. Depending on what I decide to pursue as the final option, I may be back 🙂
• Tournament Rank Rule
Solved General
3
0 Votes
3 Posts
247 Views
Hi Paul,
Yes this answers my question. I guess since the percentage is based on the number of players, I could query the number by checking how many entries there are in a given division leaderboard?
In any case I'll stick to absolute ranks for now as you suggest. I was looking into percentages to future-proof our client API.
Thank you for the quick help!
• 0 Votes
5 Posts
241 Views
All very good points @Panagiotis-Milios !
• 1 Votes
4 Posts
243 Views
Hi Panagiotis,
Thanks for the feedback!
That vertical icon bar on the far left is new in 5.2. It was key to allowing us to free up more space - moving the Debug + Log screens to their own pane. (i.e. now the screen is only ever split vertically in 2 - instead of sometimes split into 4 pains - 2 verticle and 2 horizontal).
The font scale and tab size options were there before too - but are somewhat more discoverable now that we have that cog wheel.
Glad you like the changes!
• 0 Votes
5 Posts
341 Views
There is a global list of reason codes here - https://docs.braincloudservers.com/api/appendix/reasonCodes
• Unreal 5.1 + Online Services
APIs
4
0 Votes
4 Posts
394 Views
We should point out that this doesn't mean that there aren't Unreal multiplayer examples in brainCloud - they just don't use the online subsystem paradigm per se.
Here's our latest Unreal dedicated server example: https://github.com/getbraincloud/braincloud-roomserver-unreal
• 0 Votes
2 Posts
208 Views
Hi Kuabs, you can use brainCloud webhooks to achieve this feature, the steps are as follows.
Create a cloud code script, in this example use the name "webhook_forgotPassword", and paste the following code into the script. "use strict"; function main() { var response = {}; bridge.logDebugJson("Script inputs", data); var userEmail = data.parameters.email; response.stringResponse = "webhook is processing user email reseting..." + data.parameters.email; // validating the user email if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(userEmail)) { // checking if the email is existed in brainCloud users var context = { "pagination": { "rowsPerPage": 20, "pageNumber": 1 }, "searchCriteria": { "emailAddress": userEmail }, "sortCriteria": { "playerName": 1 } }; var userProxy = bridge.getUserServiceProxy(); var postResult = userProxy.sysGetPage(context); if (postResult.data.results.count > 0) { var userProfileID = postResult.data.results.items[0].profileId; // sending password reset email postResult = userProxy.sysSendPasswordResetEmail(userProfileID); if (postResult.status == 200) { response.stringResponse = "password reset email has been sent to user's email:" + userEmail; } else { response.stringResponse = "system error with sending email..."; } } else { response.stringResponse = "user doesn't exist with the email you provided"; } } else { response.stringResponse = "user's email is invalid."; } return response; } main();
Open Design | Cloud Code | WebHooks page, and create a WebHook link to the script you created from the previous step. Copy down the WebHook URL for the next step.73ee4986-3d38-4694-bac5-d7c4896c99ba-image.png
Now, you have completed the work from brainCloud. Next, open your client app editor (if you are using Unity), define the WebHook URL as a variable, and link it to your forgotEmail object (could be a link or button in your app) onClick event, making it trigger this URL when the user clicks with Application.OpenURL command. Grab user inputted email and append it as an email parameter to the URL as follows:
const string passwordResetWebhookUrl = "https://portal.braincloudservers.com/webhook/12832/forgotPassword/6dc675bb-f8b4-495f-ac5e-1f0658bfe09c"; Application.OpenURL(passwordResetWebhookUrl + "?email=" + userEmail);
Run your app to test, you should get a similar pop-up window as follows once a user clicks the forgotEmail object,
94dd0dae-7d6e-44c8-ab26-0d57a8544bb4-image.png
Check the reset email in your test email account...25a6f240-5246-4ba2-a216-e978eaccee8c-image.png
• UE 5.3
Unsolved General
2
0 Votes
2 Posts
220 Views
Hi @shawnryanbruno
Thanks for pointing out that issue in our readme, you're right there is no BCClient folder, this will be corrected. The readme is referring to the folder contained in the latest .zip release file, current latest release is 5.1.0
We have a couple example projects that use Unreal 5.3 and the brainCloud client compiles with no issues there. I will need some more information to better assist with the issue you're having.
Did you get the brainCloud library from the release .zip file or did you download a copy of the repository?
Can you guide me through the steps you took to get to this issue?
• 0 Votes
4 Posts
251 Views
@Paul-Winterhalder Amazing! This is perfect for my needs-- thanks so much Paul.
• 0 Votes
2 Posts
184 Views
A good way to handle failure besides retrying in code, is to schedule another script to run 1 minute later that will basically repeat the same action.
|
{
"url": "https://forums.getbraincloud.com/recent",
"source_domain": "forums.getbraincloud.com",
"snapshot_id": "CC-MAIN-2024-30",
"warc_metadata": {
"Content-Length": "214137",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XXFSZJ2KSAAHRSQHFIOESFXCLK2M3VUI",
"WARC-Concurrent-To": "<urn:uuid:3f5e6366-b14b-4c8a-a406-b84eb8a1eea2>",
"WARC-Date": "2024-07-14T11:38:30Z",
"WARC-IP-Address": "35.153.251.28",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:PGCXR4EUCJU2EMBJMXWAIDUACIGXKASH",
"WARC-Record-ID": "<urn:uuid:f241720f-a50d-477a-a6d3-9b0cef18be9d>",
"WARC-Target-URI": "https://forums.getbraincloud.com/recent",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:a5063433-24ae-4be5-b422-98cf0103adcf>"
},
"warc_info": "isPartOf: CC-MAIN-2024-30\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-173\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,
12,
24,
37,
38,
46,
47,
190,
191,
271,
324,
325,
402,
403,
413,
414,
443,
444,
468,
474,
486,
498,
511,
512,
524,
525,
613,
614,
869,
870,
893,
894,
903,
904,
916,
928,
942,
943,
1024,
1025,
1066,
1067,
1089,
1095,
1107,
1119,
1133,
1134,
1164,
1165,
1366,
1367,
1397,
1398,
1436,
1437,
1456,
1462,
1474,
1486,
1500,
1501,
1548,
1549,
1643,
1644,
1808,
1809,
1895,
1896,
2025,
2026,
2098,
2099,
2109,
2110,
2139,
2140,
2156,
2162,
2174,
2186,
2200,
2201,
2916,
2937,
2938,
2950,
2962,
2976,
2977,
3142,
3143,
3170,
3171,
3192,
3198,
3210,
3222,
3236,
3237,
3252,
3253,
3386,
3387,
3415,
3416,
3426,
3427,
3467,
3468,
3489,
3496,
3508,
3521,
3535,
3536,
3559,
3579,
3722,
3723,
3735,
3736,
3759,
3760,
3785,
3791,
3803,
3815,
3829,
3852,
3864,
3876,
3890,
3891,
4062,
4063,
4088,
4089,
4108,
4114,
4126,
4138,
4152,
4153,
4166,
4167,
4362,
4363,
4495,
4496,
4530,
4531,
4543,
4555,
4569,
4570,
4616,
4617,
4629,
4641,
4655,
4656,
4675,
4676,
4705,
4706,
4994,
4995,
5127,
5128,
5159,
5160,
5172,
5184,
5198,
5199,
5309,
5310,
5343,
5344,
5353,
5359,
5371,
5383,
5397,
5398,
5565,
5566,
5683,
5684,
5696,
5708,
5722,
5723,
5820,
5821,
7175,
7176,
7389,
7390,
7802,
7803,
8022,
8023,
8142,
8193,
8194,
8296,
8297,
8308,
8309,
8330,
8336,
8348,
8360,
8374,
8375,
8398,
8399,
8632,
8633,
8829,
8830,
8942,
8943,
9013,
9014,
9026,
9038,
9052,
9053,
9137,
9138,
9150,
9162,
9176,
9177
],
"line_end_idx": [
12,
24,
37,
38,
46,
47,
190,
191,
271,
324,
325,
402,
403,
413,
414,
443,
444,
468,
474,
486,
498,
511,
512,
524,
525,
613,
614,
869,
870,
893,
894,
903,
904,
916,
928,
942,
943,
1024,
1025,
1066,
1067,
1089,
1095,
1107,
1119,
1133,
1134,
1164,
1165,
1366,
1367,
1397,
1398,
1436,
1437,
1456,
1462,
1474,
1486,
1500,
1501,
1548,
1549,
1643,
1644,
1808,
1809,
1895,
1896,
2025,
2026,
2098,
2099,
2109,
2110,
2139,
2140,
2156,
2162,
2174,
2186,
2200,
2201,
2916,
2937,
2938,
2950,
2962,
2976,
2977,
3142,
3143,
3170,
3171,
3192,
3198,
3210,
3222,
3236,
3237,
3252,
3253,
3386,
3387,
3415,
3416,
3426,
3427,
3467,
3468,
3489,
3496,
3508,
3521,
3535,
3536,
3559,
3579,
3722,
3723,
3735,
3736,
3759,
3760,
3785,
3791,
3803,
3815,
3829,
3852,
3864,
3876,
3890,
3891,
4062,
4063,
4088,
4089,
4108,
4114,
4126,
4138,
4152,
4153,
4166,
4167,
4362,
4363,
4495,
4496,
4530,
4531,
4543,
4555,
4569,
4570,
4616,
4617,
4629,
4641,
4655,
4656,
4675,
4676,
4705,
4706,
4994,
4995,
5127,
5128,
5159,
5160,
5172,
5184,
5198,
5199,
5309,
5310,
5343,
5344,
5353,
5359,
5371,
5383,
5397,
5398,
5565,
5566,
5683,
5684,
5696,
5708,
5722,
5723,
5820,
5821,
7175,
7176,
7389,
7390,
7802,
7803,
8022,
8023,
8142,
8193,
8194,
8296,
8297,
8308,
8309,
8330,
8336,
8348,
8360,
8374,
8375,
8398,
8399,
8632,
8633,
8829,
8830,
8942,
8943,
9013,
9014,
9026,
9038,
9052,
9053,
9137,
9138,
9150,
9162,
9176,
9177,
9331
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 9331,
"ccnet_original_nlines": 237,
"rps_doc_curly_bracket": 0.002786410041153431,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2997835576534271,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.016233770176768303,
"rps_doc_frac_lines_end_with_ellipsis": 0.012605040334165096,
"rps_doc_frac_no_alph_words": 0.27489176392555237,
"rps_doc_frac_unique_words": 0.43168169260025024,
"rps_doc_mean_word_length": 5.089339256286621,
"rps_doc_num_sentences": 121,
"rps_doc_symbol_to_word_ratio": 0.004329000134021044,
"rps_doc_unigram_entropy": 5.707934856414795,
"rps_doc_word_count": 1332,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.026552589610219002,
"rps_doc_frac_chars_dupe_6grams": 0.011211089789867401,
"rps_doc_frac_chars_dupe_7grams": 0.008260809816420078,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.015046469867229462,
"rps_doc_frac_chars_top_3gram": 0.008260809816420078,
"rps_doc_frac_chars_top_4gram": 0.014161380007863045,
"rps_doc_books_importance": -852.9828491210938,
"rps_doc_books_importance_length_correction": -852.9828491210938,
"rps_doc_openwebtext_importance": -547.0401611328125,
"rps_doc_openwebtext_importance_length_correction": -547.0401611328125,
"rps_doc_wikipedia_importance": -465.20574951171875,
"rps_doc_wikipedia_importance_length_correction": -465.20574951171875
},
"fasttext": {
"dclm": 0.024235190823674202,
"english": 0.8687238097190857,
"fineweb_edu_approx": 0.9997445940971375,
"eai_general_math": 0.057971660047769547,
"eai_open_web_math": 0.11863952875137329,
"eai_web_code": 0.004041729960590601
}
}
|
{
"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.072",
"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": "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": "0",
"label": "No missing content"
}
},
"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": "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,962,162,506,485,481,000
|
Dynamicallly change div and diagram name
Dear Friends,
iam using below code to load a chart in a div. I want to change div name, diagram name and data’s dynamically in more than one div in the same page. pls guide me to do this. find below my code to create a chart.
var diagram =$$(go.Diagram, “myDiagramDiv”,
{
“ViewportBoundsChanged”: recenterRoot,
“ChangedSelection”: ChangedSelection,
“panningTool.isEnabled”: false
});
);
//---------------------------------------------------------------------------
var dataToDraw = { “class”: “GraphLinksModel”,
“nodeDataArray”: [
{“key”:“e1”, “category”:“eventRectangle”, “text”:“Top Event”, “loc”:“0 0”, “movable”:false, “uid”:“0”},
{“key”:“layer_1”, “category”:“bgLayer”, “loc”:“0 0”, “layerColor”:“rgba(197,239,255,0.7)”},
{“key”:“C_1”, “category”:“controlRectangle”, “text”:“C1”, “loc”:“0 0”, “movable”:false, “subObj”:2, “statusTxt”:“Status: Draft”, “preProb”:“Pre Prob: OCC”, “preSev”:“Pre Sev: CRI”, “riskClass”:“Risk Class: B”, “uid”:“0”, “seviority”:“normal”, “color”:“white”, “sevThick”:2, “sevColor”:“black”, “riskBg”:“white”, “riskTextColor”:“black”, “visible”:true},
{“key”:“out_1_1”, “category”:“successRectangle”, “text”:“Outcome 1_1”, “loc”:“0 0”, “movable”:false, “probTxt”:“Probability”, “sevTxt”:“Severity”, “conTxt”:“Consequence”, “uid”:“0”, “showBorder”:false, “visible”:true},
{“key”:“out_1_2”, “category”:“failureRectangle”, “text”:“Outcome 1_2”, “loc”:“0 0”, “movable”:false, “probTxt”:“Probability”, “sevTxt”:“Severity”, “conTxt”:“Consequence”, “uid”:“0”, “showBorder”:false, “visible”:true}
],
“linkDataArray”: [
{“from”:“e1”, “to”:“out_1_1”, “fromSpot”:{“class”:“go.Spot”, “x”:0.5, “y”:1, “offsetX”:0, “offsetY”:0}, “toSpot”:{“class”:“go.Spot”, “x”:0.5, “y”:0, “offsetX”:0, “offsetY”:0}, “toArrow”:"", “strokeWidth”:2, “strokeColor”:“black”},
{“from”:“e1”, “to”:“out_1_2”, “fromSpot”:{“class”:“go.Spot”, “x”:0.5, “y”:1, “offsetX”:0, “offsetY”:0}, “toSpot”:{“class”:“go.Spot”, “x”:0.5, “y”:0, “offsetX”:0, “offsetY”:0}, “toArrow”:"", “strokeWidth”:2, “strokeColor”:“black”}
]}
var jsonToLoad = JSON.stringify(dataToDraw);
var prevNumber=0;
for (var k in dataToDraw.nodeDataArray){
if(dataToDraw.nodeDataArray[k].category==“controlRectangle”){
var split1= dataToDraw.nodeDataArray[k].key.split("")
if(split1.length==2)
{
var split2=Number(dataToDraw.nodeDataArray[k].key.split("
")[1]);
if(prevNumber<split2)
{
mainCtrlInc = split2
prevNumber=split2;
}
}
}
}
load();
function load() {
diagram.model = go.Model.fromJson(jsonToLoad);
diagram.initialContentAlignment = go.Spot.Top;
}
Could you please describe what the problem is?
Dear Mr.Walter,
Thanks for ur reply.
I want to load 3 charts in same html page with 3 different datas, 3 different div name and 3 different diagram. But all the charts has same functionalities. so I have to use one main js as common. but load in 3 diffent divs. if I click and do some activities in one chart it should reflect only in that particular chart.
Thanks and Regards,
Syed Abdul Rahim
For each DIV, you must have a separate instance of Diagram. And for each Diagram you want to have a separate Model.
Here are 100 Diagrams each with 100 nodes and 99 links: https://gojs.net/extras/100diagrams.html
A post was split to a new topic: Diagrams in tabs
|
{
"url": "https://forum.nwoods.com/t/dynamicallly-change-div-and-diagram-name/12165",
"source_domain": "forum.nwoods.com",
"snapshot_id": "crawl=CC-MAIN-2022-21",
"warc_metadata": {
"Content-Length": "22667",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:MLUQNFTFSPYKKCEASS7VQISGPEQTMONQ",
"WARC-Concurrent-To": "<urn:uuid:ee668810-de08-4aab-9583-a635f27fffba>",
"WARC-Date": "2022-05-17T07:16:36Z",
"WARC-IP-Address": "167.99.62.122",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RKRE72IWMJV6D3VNC2R7RUBP4TDV3BWW",
"WARC-Record-ID": "<urn:uuid:7db0469f-d880-4b5c-8536-e384d0e60328>",
"WARC-Target-URI": "https://forum.nwoods.com/t/dynamicallly-change-div-and-diagram-name/12165",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2a440826-f4ba-45e9-b590-9c557f8a0d04>"
},
"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-26\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,
41,
42,
56,
57,
269,
270,
314,
316,
355,
393,
424,
428,
431,
432,
510,
557,
576,
680,
772,
1126,
1345,
1563,
1566,
1585,
1816,
2046,
2049,
2050,
2095,
2113,
2154,
2216,
2270,
2291,
2293,
2351,
2359,
2381,
2383,
2404,
2423,
2425,
2427,
2429,
2431,
2432,
2440,
2441,
2459,
2506,
2553,
2555,
2556,
2603,
2604,
2620,
2621,
2642,
2643,
2964,
2965,
2985,
3002,
3003,
3119,
3120,
3217,
3218
],
"line_end_idx": [
41,
42,
56,
57,
269,
270,
314,
316,
355,
393,
424,
428,
431,
432,
510,
557,
576,
680,
772,
1126,
1345,
1563,
1566,
1585,
1816,
2046,
2049,
2050,
2095,
2113,
2154,
2216,
2270,
2291,
2293,
2351,
2359,
2381,
2383,
2404,
2423,
2425,
2427,
2429,
2431,
2432,
2440,
2441,
2459,
2506,
2553,
2555,
2556,
2603,
2604,
2620,
2621,
2642,
2643,
2964,
2965,
2985,
3002,
3003,
3119,
3120,
3217,
3218,
3267
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3267,
"ccnet_original_nlines": 68,
"rps_doc_curly_bracket": 0.011019280180335045,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.1433691829442978,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.014336920343339443,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.520907998085022,
"rps_doc_frac_unique_words": 0.5950155854225159,
"rps_doc_mean_word_length": 7.707165241241455,
"rps_doc_num_sentences": 45,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.003287315368652,
"rps_doc_word_count": 321,
"rps_doc_frac_chars_dupe_10grams": 0.12045270949602127,
"rps_doc_frac_chars_dupe_5grams": 0.2190784215927124,
"rps_doc_frac_chars_dupe_6grams": 0.2190784215927124,
"rps_doc_frac_chars_dupe_7grams": 0.2190784215927124,
"rps_doc_frac_chars_dupe_8grams": 0.2190784215927124,
"rps_doc_frac_chars_dupe_9grams": 0.2190784215927124,
"rps_doc_frac_chars_top_2gram": 0.018189169466495514,
"rps_doc_frac_chars_top_3gram": 0.03718674182891846,
"rps_doc_frac_chars_top_4gram": 0.03637833148241043,
"rps_doc_books_importance": -450.0711364746094,
"rps_doc_books_importance_length_correction": -450.0711364746094,
"rps_doc_openwebtext_importance": -200.36154174804688,
"rps_doc_openwebtext_importance_length_correction": -200.36154174804688,
"rps_doc_wikipedia_importance": -159.71502685546875,
"rps_doc_wikipedia_importance_length_correction": -159.71502685546875
},
"fasttext": {
"dclm": 0.4302977919578552,
"english": 0.515561044216156,
"fineweb_edu_approx": 2.216157913208008,
"eai_general_math": 0.34733396768569946,
"eai_open_web_math": 0.07169955968856812,
"eai_web_code": 0.5320562720298767
}
}
|
{
"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": "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": "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,532,344,485,699,699,000
|
Where can I find affordable C programming help with arrays and strings for tasks requiring implementation of secure coding practices?
Where can I find browse around here C programming help with arrays and strings for tasks requiring implementation of secure coding practices? I’m pretty new to this community, and I have done quite a bit of PHP coding before writing a programming skill piece. I tried out a website that does not seem to be teaching high-level PHP but if you use something like XMLHTTP to do the equivalent of our current example, you can get plenty of really good help if you consider yourself up-to-date. Also, are there any PHP programming knowledge that’s going to help me “refactor” a string from a document? A: Short answer: yes, maybe. I should mention that with our current setup it is virtually impossible to create any meaningful object with any width, it is usually impossible to have any length because of its complexity and how it should look like. Some examples: If you have 10 records with the same number of keys, set the data length 100 in the constructor. Use one record per loop, you can find records at that length instead of using all records in a sequence. Call the document function with the document_each method, it lets you get all the records you can try this out a link and display them. You can get the entire line at once, see code here: $this->data_items = array(); $this->data_options = array(); $this->data_marker = ‘data_place[$_SERVER[‘REQUEST_URI’]];?>’; $this->data_fields = array(); $this->data_fields_per_line =100; $this->data_marker = ”; for($i=0; $i<10; $i++) { $name='‘; if($this->data_marker!=”empty”) { Where can I find affordable C programming help with arrays and strings for tasks requiring implementation of secure coding practices? Thank you. As I have a lot of practice with C11 I would like to point to answers which may very well help me in an efficient way. I am at the place where one actually wants to be using C functions in an program. This is not feasible so I set up a C source More Info the purpose into which the code can be inserted. I have a large array of a single value with “test” and “object” in them and I want the array to contain like 4 objects named “textbox1” and “textbox2”. My Question is, if I fill in lines (for example) from a knockout post input which are then passed their value (“textbox1” and “textbox2”) I want the object to be named “textbox4”. There should also be a name for each item and it gets sent to the “textbox1”. If I send these to the “textbox1”. I want “textbox2” just to get “textbox4” also. This C code will execute “a” function. But when I run the program it hangs as this textbox loads. Once I pass the “textbox1” value, it is passing this “textbox5”. When I try a new line it does not find the object.
Take My Online Class Cheap
If the example seems to add an error message for the “textbox1” and “textbox2” parameters of the C program, I need to tell the program to proceed. Ideally the error is “textbox4”. Please. A: In my experience without them, C foreach/delete statements are good for storing data with lower priority than foreach/loop/loop for loops. However, there are some things you should avoid including in the snippet. If you think you can do more than what your “word characters” needs, search the C-code to break them to that one solution andWhere can I find affordable C programming help with arrays and strings for tasks requiring implementation of secure coding practices? Yes, you can find great programming assistance at the top-ranked websites. Do you find yourself struggling in those cases? c programming homework help the best and worst is always the first to find help. That is, to learn a programming language at a young age, go to a C programming language course. How can I easily? For a start, you need to remember one of the good programming languages for.NET and Symbolics, C, read and Lua. In most programs, you probably have to learn.NET first because the old c, ruby-based.NET is not recognized as a programming take my c programming homework and so it may not be suitable. Depending on what kind of programming language you are applying, you may or may not automatically learn.NET, which is a valid alternative to C.NET. Though the application will require some additional coding and some steps to start earning a license. If you need help, here are click reference recent websites that will help you get started: But you will receive help on “Ask Hire” and “Create a Search” for each of the courses and help websites using general coding languages like Java or C#. The responses can help you come up with the technical skills necessary to browse around this web-site the project. What is the package? The answer to most questions website link programming languages with at least 10K of extra memory might be in the following text: C Programming Language: Object The C Programming Language is very popular among programming languages: Ruby, Python, Lua, C, Solaris, Java, C, Go, React, Ruby, and JavaScript.
Take Online Class For Me
It also has some of the fastest programming languages (Java, C, Python, Cygwin). Why from this source it? While the official web site is recommending C programming language, there are a number of research and development organizations that use it and some may say benefit from the use. In
|
{
"url": "https://chelponline.com/where-can-i-find-affordable-c-programming-help-with-arrays-and-strings-for-tasks-requiring-implementation-of-secure-coding-practices",
"source_domain": "chelponline.com",
"snapshot_id": "CC-MAIN-2024-38",
"warc_metadata": {
"Content-Length": "172303",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ANOKPLLDKWOHK26P2IZHQNT3ZWEZRJUV",
"WARC-Concurrent-To": "<urn:uuid:2c669bc4-76ae-455e-8c75-5538757f0a18>",
"WARC-Date": "2024-09-08T17:30:25Z",
"WARC-IP-Address": "172.67.203.192",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:45NP5NK6ALMYOUC6GKPYXG3FHSRGSBL3",
"WARC-Record-ID": "<urn:uuid:acd180a8-f184-4dac-81b5-90fd21a04f57>",
"WARC-Target-URI": "https://chelponline.com/where-can-i-find-affordable-c-programming-help-with-arrays-and-strings-for-tasks-requiring-implementation-of-secure-coding-practices",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:deed03b6-aacc-4131-9435-a4fae9ff1039>"
},
"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-37\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,
134,
135,
2820,
2821,
2848,
2849,
5063,
5064,
5089,
5090
],
"line_end_idx": [
134,
135,
2820,
2821,
2848,
2849,
5063,
5064,
5089,
5090,
5378
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5378,
"ccnet_original_nlines": 10,
"rps_doc_curly_bracket": 0.0003718899970408529,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.43183818459510803,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.051011428236961365,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.17590150237083435,
"rps_doc_frac_unique_words": 0.394304484128952,
"rps_doc_mean_word_length": 4.661555290222168,
"rps_doc_num_sentences": 54,
"rps_doc_symbol_to_word_ratio": 0.000879510014783591,
"rps_doc_unigram_entropy": 5.252571105957031,
"rps_doc_word_count": 913,
"rps_doc_frac_chars_dupe_10grams": 0.09962406009435654,
"rps_doc_frac_chars_dupe_5grams": 0.09962406009435654,
"rps_doc_frac_chars_dupe_6grams": 0.09962406009435654,
"rps_doc_frac_chars_dupe_7grams": 0.09962406009435654,
"rps_doc_frac_chars_dupe_8grams": 0.09962406009435654,
"rps_doc_frac_chars_dupe_9grams": 0.09962406009435654,
"rps_doc_frac_chars_top_2gram": 0.028195489197969437,
"rps_doc_frac_chars_top_3gram": 0.007518799975514412,
"rps_doc_frac_chars_top_4gram": 0.01879698969423771,
"rps_doc_books_importance": -518.171630859375,
"rps_doc_books_importance_length_correction": -518.171630859375,
"rps_doc_openwebtext_importance": -238.7564697265625,
"rps_doc_openwebtext_importance_length_correction": -238.7564697265625,
"rps_doc_wikipedia_importance": -272.3884582519531,
"rps_doc_wikipedia_importance_length_correction": -272.3884582519531
},
"fasttext": {
"dclm": 0.24544614553451538,
"english": 0.9105051755905151,
"fineweb_edu_approx": 2.3967368602752686,
"eai_general_math": 0.9062263369560242,
"eai_open_web_math": 0.14207416772842407,
"eai_web_code": 0.9478024840354919
}
}
|
{
"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": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "5",
"label": "Social/Forum"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "2",
"label": "Text Extraction Errors"
}
},
"missing_content": {
"primary": {
"code": "1",
"label": "Truncated Snippets"
},
"secondary": {
"code": "3",
"label": "Incoherent Flow"
}
},
"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
|
-5,586,060,670,231,750,000
|
MDN will be in maintenance mode on Wednesday September 20th, starting at 10 AM Pacific / 5 PM UTC, for about 1 hour.
The Browser app (which is now part of System) provides browser-like functionality where it is needed — including page navigation, search, and bookmarks. This article explains how the Browser app's basic functionality works, and how it fits into the larger system.
Since Gaia is built to run on top of Gecko, it was possible to engineer a Browser app/System Browser for regular web page navigation based on that Gecko instance. This can be manipulated by the mozBrowser API.
Note: From Firefox OS 2.1 onwards, the Browser app is part of the System app. This means that web browsing can be done both by clicking the Browser icon to open the Browser app or by accessing the universal search and navigation capability. The app and browsing tabs are henceforth unified to a common experience and exist in the task manager and sheets view (for edge gestures), as part of the Haida user experience.
System Browser (Browser Chrome)
When a Firefox OS user bookmarks a web page so that it appears on the homescreen, the web page will be subsequently opened in the System Browser instead of the Browser app. It includes a toolbar at the bottom containing general back/forward/refresh functions. In Gaia this is called the Browser Chrome or wrapper. You can see this in action on the right hand side of the below image.
A diagram showing that when a web page is opened in the system browser, it is given a toolbar.
If you want your web page to still feature back/forward/refresh functions, you can declare the following in the app's manifest enable Browser Chrome.
declare { chrome: { navigation: true } }
Note: The Browser Chrome toolbar affects the height of the content, so this needs to be taken into consideration for your web page layouts.
The code flow
When opening a new web page in Firefox OS, the call flow is
Gecko > WrapperFactory > Window Manager > AppWindow > BrowserFrame
Wrappers inheriting from system/js/wrapper_factory will receive the mozbrowseropenwindow event for a bookmarked web page.
In the handleEvent section, the handler will check the event to decide whether the web page should be opened as an app or in browser chrome.
Finally, launchWrapper is called to launch the corresponding window.
Universal Search & Navigation
With the new search and navigation bar, users can get to their favorites, type in a URL, or discover a new app, from anywhere in Firefox OS. The search bar lives at the top of the screen, and users can just tap or swipe to open it.
Think of it as a combination of the Awesome Bar from the browser and the adaptive app search from the homescreen. Because Firefox OS uses web apps, when you find what you want, even if it’s a new app, it opens right away. You don’t need to install anything, because everything is instant and web-like.
Browser App
The Browser app is a certified webapp that provides a general web browser experience. The main function is located in apps/browser/js/browser.js:
var Browser = {
init: function browser_init() {
this.getAllElements();
...
BrowserDB.init((function() {
...
}
}
};
window.addEventListener('load', function browserOnLoad(evt) {
window.removeEventListener('load', browserOnLoad);
Browser.init();
});
The Browser will call its init() function while the DOM is loaded.
getAllElements: function browser_getAllElements() {
var elementIDs = [
'toolbar—start', ... 'danger—dialog'];
// Loop and add element with camel style name to Modal Dialog attribute.
elementIDs.forEach(function createElementRef(name) {
this[this.toCamelCase(name)] = document.getElementById(name);
}, this);
},
The getAllElements function is used to get all camelCase element handlers, after which the apps/browser/js/browser_db.js is called, to prepare for adding the default search engine and bookmarks.
Bookmarks
From Firefox OS 2.0 apps/bookmark is used to handle bookmark save/remove activities.
The most interesting part, apps/bookmark/webapp.manifest, looks like so:
"activities": {
"save—bookmark": {
"filters": {
"type": "url",
"url": { "required":true, "pattern":"https?:.{1,16384}" }
},
"disposition": "inline",
"href": "/save.html",
"returnValue": true
},
"remove—bookmark": {
"filters": {
"type": "url",
"url": { "required":true, "pattern":"https?:.{1,16384}" }
},
"disposition": "inline",
"href": "/remove.html",
"returnValue": true
}
},
As seen above, the activity is handled by save.html and remove.html. Both operations are delegated to apps/bookmark/js/activity_handler.js:
var ActivityHandler = {
'save—bookmark': function ah_save(activity) {
},
'remove—bookmark': function ah_remove(activity) {
}
};
navigator.mozSetMessageHandler('activity', function onActivity(activity) {
var name = activity.source.name;
switch (name) {
case 'save—bookmark':
case 'remove—bookmark':
if (activity.source.data.type === 'url') {
ActivityHandler[name](activity);
}
...
}
}
When the message handler listener navigator.mozSetMessageHandler('activity') receives the save-bookmark or remove-bookmark activities, the ActivityHandler function is triggered to handle correspondent operations.
Document Tags and Contributors
Contributors to this page: chrisdavidmills, kscarfone, Juanninja, nadimtuhn
Last updated by: chrisdavidmills,
|
{
"url": "https://developer.mozilla.org/en-US/docs/Archive/B2G_OS/Platform/Gaia/Gaia_apps/Browser",
"source_domain": "developer.mozilla.org",
"snapshot_id": "crawl=CC-MAIN-2017-39",
"warc_metadata": {
"Content-Length": "40391",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:MPSO74AWLURDJ6NJXNS2D2ALBFL2FTIA",
"WARC-Concurrent-To": "<urn:uuid:1f72f599-624a-4f34-ac1c-65798c830e0d>",
"WARC-Date": "2017-09-20T04:47:31Z",
"WARC-IP-Address": "63.245.215.53",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:66C46MFKGZLBTZF4LEZXF4AUGU6R4QL4",
"WARC-Record-ID": "<urn:uuid:a0601ab0-1301-456b-a9bb-b70c575431f2>",
"WARC-Target-URI": "https://developer.mozilla.org/en-US/docs/Archive/B2G_OS/Platform/Gaia/Gaia_apps/Browser",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d1206092-649d-45cc-bf35-54bc07d028e3>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-31-62-84.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-39\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for September 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,
117,
118,
382,
383,
593,
594,
1012,
1013,
1045,
1046,
1430,
1431,
1526,
1527,
1677,
1678,
1719,
1720,
1860,
1861,
1875,
1876,
1936,
1937,
2004,
2005,
2127,
2128,
2269,
2270,
2339,
2340,
2370,
2371,
2603,
2604,
2906,
2907,
2919,
2920,
3066,
3067,
3083,
3117,
3144,
3154,
3187,
3197,
3203,
3207,
3210,
3211,
3273,
3326,
3344,
3348,
3349,
3416,
3417,
3469,
3490,
3533,
3534,
3609,
3664,
3730,
3742,
3745,
3746,
3941,
3942,
3952,
3953,
4038,
4039,
4112,
4113,
4129,
4150,
4167,
4188,
4252,
4259,
4288,
4314,
4338,
4343,
4366,
4383,
4404,
4468,
4475,
4504,
4532,
4556,
4560,
4563,
4564,
4704,
4705,
4729,
4777,
4782,
4783,
4835,
4839,
4842,
4843,
4918,
4953,
4971,
4997,
5025,
5074,
5115,
5123,
5131,
5135,
5137,
5138,
5351,
5352,
5383,
5384,
5461
],
"line_end_idx": [
117,
118,
382,
383,
593,
594,
1012,
1013,
1045,
1046,
1430,
1431,
1526,
1527,
1677,
1678,
1719,
1720,
1860,
1861,
1875,
1876,
1936,
1937,
2004,
2005,
2127,
2128,
2269,
2270,
2339,
2340,
2370,
2371,
2603,
2604,
2906,
2907,
2919,
2920,
3066,
3067,
3083,
3117,
3144,
3154,
3187,
3197,
3203,
3207,
3210,
3211,
3273,
3326,
3344,
3348,
3349,
3416,
3417,
3469,
3490,
3533,
3534,
3609,
3664,
3730,
3742,
3745,
3746,
3941,
3942,
3952,
3953,
4038,
4039,
4112,
4113,
4129,
4150,
4167,
4188,
4252,
4259,
4288,
4314,
4338,
4343,
4366,
4383,
4404,
4468,
4475,
4504,
4532,
4556,
4560,
4563,
4564,
4704,
4705,
4729,
4777,
4782,
4783,
4835,
4839,
4842,
4843,
4918,
4953,
4971,
4997,
5025,
5074,
5115,
5123,
5131,
5135,
5137,
5138,
5351,
5352,
5383,
5384,
5461,
5495
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5495,
"ccnet_original_nlines": 125,
"rps_doc_curly_bracket": 0.00837124977260828,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2609865367412567,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.012556049972772598,
"rps_doc_frac_lines_end_with_ellipsis": 0.02380952052772045,
"rps_doc_frac_no_alph_words": 0.29147982597351074,
"rps_doc_frac_unique_words": 0.4435146450996399,
"rps_doc_mean_word_length": 5.736401557922363,
"rps_doc_num_sentences": 62,
"rps_doc_symbol_to_word_ratio": 0.003587439889088273,
"rps_doc_unigram_entropy": 5.170072078704834,
"rps_doc_word_count": 717,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.04473619908094406,
"rps_doc_frac_chars_dupe_6grams": 0.03306588903069496,
"rps_doc_frac_chars_dupe_7grams": 0.03306588903069496,
"rps_doc_frac_chars_dupe_8grams": 0.03306588903069496,
"rps_doc_frac_chars_dupe_9grams": 0.03306588903069496,
"rps_doc_frac_chars_top_2gram": 0.02674447000026703,
"rps_doc_frac_chars_top_3gram": 0.01580354943871498,
"rps_doc_frac_chars_top_4gram": 0.007293949835002422,
"rps_doc_books_importance": -540.70849609375,
"rps_doc_books_importance_length_correction": -540.70849609375,
"rps_doc_openwebtext_importance": -253.1372833251953,
"rps_doc_openwebtext_importance_length_correction": -253.1372833251953,
"rps_doc_wikipedia_importance": -202.66673278808594,
"rps_doc_wikipedia_importance_length_correction": -202.66673278808594
},
"fasttext": {
"dclm": 0.32421237230300903,
"english": 0.7539139986038208,
"fineweb_edu_approx": 2.2729012966156006,
"eai_general_math": 0.21927493810653687,
"eai_open_web_math": 0.077364981174469,
"eai_web_code": 0.5915372967720032
}
}
|
{
"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.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": "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": "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
|
1,773,027,337,297,717,200
|
Leche69 Downloader - How to download Leche69 videos?
DOWNLOAD VIDEOS AND MUSIC FROM 200,000+ SITES.
Leche69 Downloader - How to download Leche69 videos?
How to Download Videos from Leche69 on Mac/Win
Are you looking for a software to download videos from Leche69 on win, mac, iPad or iPhone? Like to batch download Leche69 videos at a time? Now, we strongly recommend the Leche69 Downloader - GetFLV for you. GetFLV is the best Leche69 downloader & recorder chosen by millions of people.
Download Leche69 videos at up to 10x normal download speeds.
Support similar popular adult sites including: 4tube, 3 Rat, PornHub, 3movs, megatube.xxx, hotmovies, 18SchoolGirlz, 100Gb Tube, 4 Porn... Full list of supported sites
Easily convert downloaded Leche69 videos to iPad/iPhone/iPod/PSP.
Compatible with Windows 10/8/7/Vista/XP (32-bit & 64-bit) , Mac OS X 10.7 or later
Choose your platform:
Mac OS X 10.6/10.7/10.8/10.9
iOS (iPhone/iPad/iPod)
How to Download Leche69 videos?
Many of us would like to download videos from Leche69 for playback offline. Here is an article of downloading videos from such a website. In the article, 3 methods are provided, and all of the methods could be extend to other video sharing websites.
Part 1: Best way to download Leche69 videos
Part 2: Record Leche69 videos with Video Capture Plugin
Part 3: Bulk or batch download Leche69 videos (for 600+ supported sites)
Part 1: Best way to download Leche69 videos
1. Make Preparation: Free download Leche69 Downloader
Free download the best Leche69 Downloader- GetFLV( for Windows , for Mac) , install and then launch it, the following interface will pop up.
How to download videos from Leche69
2. Launch GetFLV and navigate to leche69.com website. Play Leche69 video and capture it's URL
Play the video stream you want to download from Leche69. GetFLV will detect the video URL automatically and show it in the "URL list". Select the right URL in the URL list section and click "Download" button to create a download task. It appears like this:
How to download videos from Leche69
3. Download Leche69 videos
In "FLV Downloader" window, you can monitor the process of the download. GetFLV can download your video at up to 10x normal download speeds. You can watch your video while it's still downloading through GetFLV's built-in player. For the stopped tasks, you can also resume them. It appears like this:
How to download videos from Leche69
Part 2: Record Leche69 videos with Video Capture Plugin
Video Capture can capture any video with audio from any website by recording directly from your PC screen. It's powerful and magic. The following is step-by-step guide:
1. Switch to "Video Capture" window and click "New Record" button to start a new capture task.
2. A new browser window will be opened. It will load a blank webpage automatically. Please enter the url of your Leche69 video which you want to capture. It appears like this:
3. Please pause your video if it plays automatically. (1) A "Transparent Window" will be shown over the video area (see below). You can resize or move this window to fine tune the recording area. (2) A "Setting Window" will also be popup (see below). You can change "Task Name ", "Capture Duration", "Video Format" and "Video Quality". Click "Next" button when you finish your settings.
Attention:
(1). Manually show setting window: Please click "Camera" button to popup "Transparent Window" and "Setting Window" if they are not popped up automatically.
(2). Set capture duration: Please find the total duration of your playing video and set suitable "capture duration" you need. Capture task will auto stop when the record time reach to your "capture duration".
(3). Choose video quality: Video Capture will automatically choose a video quality for you. You could choose high quality if you want save HD videos.
(4). Buffering video: If your net speed is slow or inconsistent, you can try to pause the video for a while before capturing it.
4. Setting window will switch to new frame (see below). You have two ways to start your capture task: (1) "Play/resume" your video and click "Record Now " button. (2) Wait the countdown timer, "Play/resume" your video just before the timer is finished. "Special Attention": You must "play/resume" your video before countdown timer is finished or clicking "Record Now" button.
5. The capture browser window will be hidden when the capture task starts. All capture work will magically run all in background (no image and no sound). A capture task will be added. You can see the thumbnail, process, recorded filesize and elapsed time of a task. The audio of capture browser is muted. You can hear a task's sound when you select it.
6. Capture will be stopped automatically and video will be saved to your hard drive when the record time reaches to the "Capture Duration". You can also click "Stop&Save" button to stop one capture task at any time. The captured video file will be found from "Finished Tasks" frame. It appears like this:
7. "Special Attention": A capture task will cost more than 20% of your CPU. So, The audio and video of captured videos are often out of sync if you run 3 or more capture tasks at same time.
8. Please try other powerful methods of GetFLV to download your video if above instruction can't help you. Get more detailed Step-by-Step User Guides.
GetFLV can help you convert downloaded leche69.com videos for your portable devices like iPad, iPod, iPhone, PSP, Zune, etc.
Links to this tutorial:
|
{
"url": "http://www.vdigger.com/leche69.com-downloader/index.htm",
"source_domain": "www.vdigger.com",
"snapshot_id": "crawl=CC-MAIN-2019-09",
"warc_metadata": {
"Content-Length": "29253",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:UDCM4STUM2CI3ZKLUNZV3IZJA3IZXJLA",
"WARC-Concurrent-To": "<urn:uuid:104c9e44-993a-4da1-b069-bfa2ac5b315a>",
"WARC-Date": "2019-02-18T03:27:39Z",
"WARC-IP-Address": "198.58.105.33",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:DR5UI7OOJEZIVAJHXGRUWXO6V5NKPQK6",
"WARC-Record-ID": "<urn:uuid:2b010a51-18f3-433c-9916-fc4f919574a4>",
"WARC-Target-URI": "http://www.vdigger.com/leche69.com-downloader/index.htm",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d66cb2f1-a273-4bd1-b943-bb76e0ff3361>"
},
"warc_info": "isPartOf: CC-MAIN-2019-09\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for February 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-137-170-67.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,
55,
56,
103,
104,
157,
158,
205,
206,
494,
495,
556,
724,
790,
873,
895,
924,
947,
949,
950,
982,
983,
985,
1235,
1239,
1297,
1363,
1446,
1447,
1449,
1450,
1452,
1453,
1497,
1498,
1500,
1501,
1555,
1556,
1699,
1701,
1737,
1739,
1740,
1834,
1835,
2094,
2096,
2134,
2136,
2137,
2164,
2165,
2467,
2469,
2505,
2507,
2508,
2564,
2565,
2734,
2829,
3005,
3392,
3393,
3404,
3405,
3561,
3562,
3771,
3772,
3922,
3923,
4052,
4053,
4429,
4782,
5087,
5277,
5428,
5430,
5555,
5556,
5580,
5581,
5583,
5587
],
"line_end_idx": [
55,
56,
103,
104,
157,
158,
205,
206,
494,
495,
556,
724,
790,
873,
895,
924,
947,
949,
950,
982,
983,
985,
1235,
1239,
1297,
1363,
1446,
1447,
1449,
1450,
1452,
1453,
1497,
1498,
1500,
1501,
1555,
1556,
1699,
1701,
1737,
1739,
1740,
1834,
1835,
2094,
2096,
2134,
2136,
2137,
2164,
2165,
2467,
2469,
2505,
2507,
2508,
2564,
2565,
2734,
2829,
3005,
3392,
3393,
3404,
3405,
3561,
3562,
3771,
3772,
3922,
3923,
4052,
4053,
4429,
4782,
5087,
5277,
5428,
5430,
5555,
5556,
5580,
5581,
5583,
5587,
5592
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5592,
"ccnet_original_nlines": 86,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 1,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2859545946121216,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.022708160802721977,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2464255690574646,
"rps_doc_frac_unique_words": 0.3359116017818451,
"rps_doc_mean_word_length": 4.7580108642578125,
"rps_doc_num_sentences": 83,
"rps_doc_symbol_to_word_ratio": 0.0008410399896092713,
"rps_doc_unigram_entropy": 5.049482822418213,
"rps_doc_word_count": 905,
"rps_doc_frac_chars_dupe_10grams": 0.0218299999833107,
"rps_doc_frac_chars_dupe_5grams": 0.12633535265922546,
"rps_doc_frac_chars_dupe_6grams": 0.11402694135904312,
"rps_doc_frac_chars_dupe_7grams": 0.09289363771677017,
"rps_doc_frac_chars_dupe_8grams": 0.05945193022489548,
"rps_doc_frac_chars_dupe_9grams": 0.043195538222789764,
"rps_doc_frac_chars_top_2gram": 0.03019043058156967,
"rps_doc_frac_chars_top_3gram": 0.04389223828911781,
"rps_doc_frac_chars_top_4gram": 0.027868090197443962,
"rps_doc_books_importance": -648.2319946289062,
"rps_doc_books_importance_length_correction": -648.2319946289062,
"rps_doc_openwebtext_importance": -355.44970703125,
"rps_doc_openwebtext_importance_length_correction": -355.44970703125,
"rps_doc_wikipedia_importance": -240.28109741210938,
"rps_doc_wikipedia_importance_length_correction": -240.28109741210938
},
"fasttext": {
"dclm": 0.020170630887150764,
"english": 0.8450921177864075,
"fineweb_edu_approx": 1.089749813079834,
"eai_general_math": 0.0004559800145216286,
"eai_open_web_math": 0.03565477952361107,
"eai_web_code": 0.00535559980198741
}
}
|
{
"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": "306.2",
"labels": {
"level_1": "Social sciences",
"level_2": "",
"level_3": "Culture"
}
}
},
"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": "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": "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
|
3,231,984,009,704,027,600
|
If you were forced to be cyberneticized
Sorry for the sudden surge of cyborg-related threads, but i’ve been watching Season 2 of Doctor Who (i have my ways, but won’t get into them), and the Cybermen and Dalek based episodes have got me thinking…
if i was forced to be “upgraded”, what cybernetic lifeform would i upgrade to?
the Borg? individuality crushed, treated as a cog in the Galactic machine, the contents of my mind sifted through to see what would best serve the Collective, body studded with painful looking implants, however the catchphrase is cool “We are Borg, you will be assimilated, resistance is futile”
the Cybermen? as with the Borg, individuality crushed, mind linked into a collective conciousness, at least the armoured body shell looks cooler than the Borg, but the catchphrases are dumber “You Will Be Upgraded” (can the Borg sue for copyright infringement here :wink: ) “Delete!!”
the Daleks? locked inside a cold metal cage, unable to touch, all emotions removed except rage, unless equipped with antigrav units, stairs would be a problem “El-E-VATE!”, on the upside, i’d get a cool death ray, personal shielding, a cool blue eyestalk, and a much cooler catchphrase “EX-TER-MI-NATE!!!”
if i was forced, i’d probably chose to be Dalek’ed…
what about you? Cyberman, Borg, or Dalek?
I want the “upgrades” from the Dragon-Ball Z androids. No contest. Heck, I could kill all the other androids for kicks.
Bionic woman.
…uh, man.
Okay, but bear in mind, the last two posters stated what they’d want to be upgraded to, as in willing cybernetic transformation, not what you’d choose if you were forced to choose…
so i’m altering the question slightly, first question, if you were forced to be cyborged, what would it be, Borg, Cyberman or Dalek?
second question, if you were to voluntarily upgrade, what would it be, this one’s wide open
my answer to question 1; Dalek’ed
my answer to question 2; Robocop (after Directive 4 was removed)
…with big Chainsaw hands, RZZZZ!!!
It’d suck about the 5 foot tall limit though… :wink:
Maybe I’d volunteer to get in on this hot cyborg action.
by the way, can anyone point a guest to a thread to tell me what the heck THAT was all about?
Can’t I choose to be a $6,000,000 man?
Johnny Mnemonic upgrades for me. Designer Brain.
If forced: Borg. There are references within the series that it is somewhat pleasant to be part of the Collective as long as you are within a cube or otherwise close enough to other Borg to be part of a community. Plus, Seven of Nine.
My choice: Do you require that some biological tissue be left? If not, I’d opt for my mind to be uploaded into software and transferred to a T-1000. New look every day! :slight_smile:
If you do, Robocop sounds good. No directives, and I get the gun.
Or even better: I could have my brain encased in a vat in a bombproof bunker and remote-control any number of humanoid RC units. A whole army of me.
I want to be a pleasure-bot.
Like that one in “AI.”
Same, for the same reason. Besides, there’s a small chance I might get rescued.
If I have a choice, I’d go with the package that Mickey Finn from Spider Robinson’s Callahan’s Place books got, minus the slave implants the Masters put in of course. Personal FTL travel, nuke proof, and enough firepower to torch a planet.
With the strength of 5 go-rillas!
Makes my nipples hard just thinking about it.
Ghost in the Shell-style armored cyborg. Able to leap, if not over, then from tall buildings and not get hurt. Super strong, super fast, able to withstand a grenade blast from close range, still myself in my mind, look pretty much human (though it’s hard to tell in animation, it is apparently possible to tell a cyborg from a normal human). Can surf the net with my mind. And I could add any accessories I wanted. Invisibilty anyone?
Just remind me not to do any body-swapping with geishas.
The DBZ androids would be fun too.
There are some references in The Transformers: Generation 1 that suggest that a Human consciousness can be transferred into a Cybertronian body. And that a cyborgization process, re: Headmasters/Targetmasters, may be possible.
A simulant from Red Dwarf for me:
“The difference between a psychotic Mechanoid and a psychotic Simulant is that the android would not rip off a human head and spit down its neck. Simulants are virtually indestructible and could easily take several rounds from a Bazookoid suffering little damage.” (from The Sadgeezer’s Guide to cult SciFi - http://www.sadgeezer.com)
I want to be an Adrian BarboBot!
I had a dream last night that I was HAL and my dream person told HAL to execute a self-destructing command aĺa Spock at which point I woke up.
If I positively had to choose one or the other, I’d go for becoming a Cyberman. Why?
1.) They are arguably not evil. They genuinely believe that “upgrading” is the best possible thing to do for humanity - they’re not in it for the looting or pillaging.
2.) Style. Cybermen may be unemotional killing machines, but they care about style. In “Doomsday”, they actually mock the Daleks for their lack of it. It goes something like:
Cyberman: Your design is inelegant.
Dalek: We care nothing for elegance!
Cyberman: Obviously.
Snap!
If I had to be forced, I’d be a Borg, but only if I could get some of that analgesic cream. Nobody likes to have rashes.
If I had a choice, I’d probably go for a relatively low-impact cyborg setup, like in the Honor Harrington books, where Honor has a cyber-prosthetic arm capable of superhuman strength AND having a built-in pulser gun for self defense, and a cybernetic eye that includes high-definition zoom vision and various other info-organizing goodies.
1.) Necrons ; psychologically just like the Daleks, but you get to look like the Terminator without the fake-flesh, and you get a bad-ass death-ray! (not a 1920’s-style one though)
2.) Hmmm… I was gonna say Ghost in the Shell style full-body cyberization. Get to choose my bodies’ appearance, can pass for ordinary person, superhuman physical abilities, etc…
But Dragonball Z Androids do get a sweet deal. World-destroying power, tireless, apparently don’t need food (so no going to the bathroom anymore), keen sense of fashion (if we’re assuming #17 & #18 style), don’t seem to feel pain (or at least a very muted form of it), can still sexually reproduce with ordinary humans, etc.
Then again, flesh is weak, and merely a temptation. Give me full on roboticizing ala Sonic the Hedgehog, if I can keep my free will (like Uncle Chuck, or Mecha Knuckles in the Archie Comics Mecha Madness special) AND get a big power-up (flight, ray-guns, energy shields, etc.).
Just kidding, given a choice I’d go with smiling Bandit, I’d still be overweight, and balding, but I’d still be me, too. Call Dr. Gero and make me an appointment.
|
{
"url": "https://boards.straightdope.com/t/if-you-were-forced-to-be-cyberneticized/371732",
"source_domain": "boards.straightdope.com",
"snapshot_id": "crawl=CC-MAIN-2022-40",
"warc_metadata": {
"Content-Length": "67871",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ULYCOOL5JYW3SNECDH5QNLRPNOWOR65Z",
"WARC-Concurrent-To": "<urn:uuid:2d503b2a-63e9-4899-9362-2030152803a4>",
"WARC-Date": "2022-10-04T15:51:26Z",
"WARC-IP-Address": "64.71.144.203",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:HTB2OHG5ZHDKMMW2UPOJDD73V6RMROPS",
"WARC-Record-ID": "<urn:uuid:7e3a5838-22e6-436b-945c-7d989407ca3b>",
"WARC-Target-URI": "https://boards.straightdope.com/t/if-you-were-forced-to-be-cyberneticized/371732",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:782616e0-da04-44fb-ac9f-52215d3353c3>"
},
"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-70\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,
40,
41,
248,
249,
328,
329,
625,
626,
911,
912,
1218,
1219,
1271,
1272,
1314,
1315,
1435,
1436,
1450,
1451,
1461,
1462,
1643,
1644,
1777,
1778,
1870,
1871,
1905,
1970,
1971,
2006,
2007,
2060,
2061,
2118,
2119,
2213,
2214,
2253,
2254,
2303,
2304,
2539,
2540,
2724,
2725,
2791,
2792,
2941,
2942,
2971,
2972,
2995,
2996,
3076,
3077,
3317,
3318,
3352,
3353,
3399,
3400,
3835,
3836,
3893,
3894,
3929,
3930,
4157,
4158,
4192,
4193,
4528,
4529,
4562,
4563,
4706,
4707,
4792,
4793,
4961,
4962,
5137,
5138,
5174,
5211,
5232,
5233,
5239,
5240,
5361,
5362,
5702,
5703,
5884,
5885,
6063,
6064,
6389,
6390,
6668,
6669
],
"line_end_idx": [
40,
41,
248,
249,
328,
329,
625,
626,
911,
912,
1218,
1219,
1271,
1272,
1314,
1315,
1435,
1436,
1450,
1451,
1461,
1462,
1643,
1644,
1777,
1778,
1870,
1871,
1905,
1970,
1971,
2006,
2007,
2060,
2061,
2118,
2119,
2213,
2214,
2253,
2254,
2303,
2304,
2539,
2540,
2724,
2725,
2791,
2792,
2941,
2942,
2971,
2972,
2995,
2996,
3076,
3077,
3317,
3318,
3352,
3353,
3399,
3400,
3835,
3836,
3893,
3894,
3929,
3930,
4157,
4158,
4192,
4193,
4528,
4529,
4562,
4563,
4706,
4707,
4792,
4793,
4961,
4962,
5137,
5138,
5174,
5211,
5232,
5233,
5239,
5240,
5361,
5362,
5702,
5703,
5884,
5885,
6063,
6064,
6389,
6390,
6668,
6669,
6831
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6831,
"ccnet_original_nlines": 103,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 3,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3989569842815399,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03259452059864998,
"rps_doc_frac_lines_end_with_ellipsis": 0.03846153989434242,
"rps_doc_frac_no_alph_words": 0.2079530656337738,
"rps_doc_frac_unique_words": 0.47647562623023987,
"rps_doc_mean_word_length": 4.570573329925537,
"rps_doc_num_sentences": 82,
"rps_doc_symbol_to_word_ratio": 0.00651889992877841,
"rps_doc_unigram_entropy": 5.655120849609375,
"rps_doc_word_count": 1169,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.01628299057483673,
"rps_doc_frac_chars_dupe_6grams": 0.007112110033631325,
"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.00898372009396553,
"rps_doc_frac_chars_top_3gram": 0.006737790070474148,
"rps_doc_frac_chars_top_4gram": 0.008422230370342731,
"rps_doc_books_importance": -609.3428344726562,
"rps_doc_books_importance_length_correction": -609.3428344726562,
"rps_doc_openwebtext_importance": -335.9457702636719,
"rps_doc_openwebtext_importance_length_correction": -335.9457702636719,
"rps_doc_wikipedia_importance": -281.16448974609375,
"rps_doc_wikipedia_importance_length_correction": -281.16448974609375
},
"fasttext": {
"dclm": 0.10584425926208496,
"english": 0.9364678263664246,
"fineweb_edu_approx": 1.1770764589309692,
"eai_general_math": 0.22896331548690796,
"eai_open_web_math": 0.32228904962539673,
"eai_web_code": 0.05787127837538719
}
}
|
{
"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": "791.43658",
"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": "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": "5",
"label": "Comment Section"
},
"secondary": {
"code": "18",
"label": "Q&A Forum"
}
},
"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": "2",
"label": "Partially Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-7,731,178,592,470,850,000
|
Retric
欢迎打赏。BTC:1MibfK26s4u8GBLEAsTy82uVEBPBUG4z3F
写了 336 篇文章
40年前的协议战争,对区块链有什么启示?
发表于 2020-02-27 16:10:29
我们熟悉阿里巴巴、腾讯、字节跳动所代表的成功的商业故事。我们知道微信、淘宝、抖音是怎样成为全民爆款的产品。这些案例离消费者触手可及,它们在各自的领域里过关斩将,最终成为了人们生活必不可少的一部分。这些故事是漂浮在水面的冰山,我把它们称之为应用层的战争。
还有一种故事,藏在海平面下,体积比水上的巨大得多,意味着它们的影响更深远、更辽阔,但因为不直接面向消费者,往往不为人知。我把它称之为协议层的战争。协议层是应用层之所以存在的基础。
就像应用需要获取用户、占领市场一样,底层协议想要成为最终的赢家,也需要占领自己的用户——大部分是开发者——的心智。但协议层的战争又跟应用层很不一样,并不是砸钱做推广就可以搞定,很多时候,协议层需要以开源的形式,去赢得更多的信任,因为它们需要建立的不仅是市场,还有生态。
生态和市场有什么不一样?打个比方,应用层战争就像是两个生意对手在广场上建立一家商店,互相争夺吸引镇上顾客光临自家商店。而协议层战争更像是两个宗教互相竞争,谁能号召更多的人成为信徒,谁能鼓动更多信徒在镇上建造更多的教堂,谁才是最后的赢家。
区块链正处于协议层战争的早期阶段,目前为止还没有产生通吃一切的大赢家。每条公链都在尝试建立自己的生态,比特币和以太坊走在了最前面,身后跟着许许多多中小型的项目;DeFi 成为了智能合约主流的叙事和应用方向,稳定币 Maker 走在了前面,身后还有其他种类繁多的DeFi 协议,它们每个都希望成为去中心化金融的基础拼图,金融乐高中最底层的积木。
这里面每天都在产生大量的创新,也有大量的竞争。橙皮书和这个行业里的其他人一样,我们也在试图思考那个最重要的问题:哪些协议会最终胜出?应该把手中的赌注,押在哪只赛马身上才能笑到最后?越想知道这个问题的答案,思绪好像就越乱成一团。
就像上文所说的,协议层的战争跟我们所熟悉的应用层战争并不一样。好在历史或许能给我们一些帮助,因为协议层战争其实已经发生过一次了。在互联网协议刚诞生的上古时期,如何把全世界的电脑连接成一个网络,同样面临着不同协议的竞争。最终我们知道,TCP/IP 协议获得了胜利。
但互联网的这场协议战争到底是怎么样的?它对今天区块链领域的战争又有什么样的启示?这篇文章尝试着回答下这两个问题。
40年前的协议战争
在互联网的大目标上,所有人都达成了共识:要建立一个全球性的计算机网络。但是具体如何实现这个目标,他们意见各不相同。到20世纪80年代初,有几个不同的协议开始相互竞争。
在欧洲电话垄断巨头和大多数政府的支持下,OSI协议受到了当时更多人的青睐。其他强有力的竞争对手还包括两个企业内部的网络协议,IBM SNA 和 DEC DECNET。我们今天所熟知的互联网协议(TCP/IP协议)是当时这场协议战争中的黑马,它只由一个依靠志愿者的自治社区来支持。
但是互联网协议的这个自治社区动作非常敏捷快速,他们在几个月内的时间里,开发进度就赶上了 OSI 委员会耗费数年取得的进展。不过,互联网协议却吓跑了一些潜在的使用者,因为这里似乎没有人为之“负责”。
——计算机历史纪念馆
协议和标准的不一致,到底会产生都多大的问题?当时的情况类似于,我们已经可以把全世界的电脑都连起来了,就像所有人家里都配备了电话,但是因为协议和标准的不同,每个人接电话讲的却是不同的语言,因此互联互通仍然无法实现。
因为无法统一标准,想把不同协议的电脑连成网络,实操的难度和麻烦非常大。思科公司(专门生产用于连接计算机网络系统的设备和软件)有这样一件文化衫,上面罗列了当时他们能支持的网络协议,而这些网络协议只是当时所有网络协议的一部分。
思科的文化衫
互联网协议的三个主要竞争对手
DECNET
DECNET的数据报文交换系统标签
DECNET 是一个受欢迎的网络系统架构,但它是私有的,因此没有被标准组织和政府客户所采用。从1987年12月开始,DECNET 从 DEC 自己的协议转移到了 OSI 标准的协议,OSI 协议最终又输给了TCP/IP。
SNA
IBM 3174系统网络体系(SNA)控制器
SNA 诞生于1974年,是 IBM 的专有网络体系,一开始是专门用来连接大型机和类似电传打字机、显示器这样的计算机外围设备的,后来又扩展到连接其他计算机上。SNA 最初是固定不变与分层的设计,最后变得更加灵活。SNA 协议在大公司内部主宰了几十年的地位。
OSI
设计 OSI 模型的 CCITT 的出版物
OSI 是互联网协议的直接竞争对手。OSI 是一个定义良好的、受到各国政府与学界支持的、受益于 XNS 与其他协议的例子。但它最终受困于过多的复杂性,一直没能推出能实际运行的代码。
OSI 与 TCP/IP
这场协议战争的重头戏,无疑属于 OSI 与 TCP/IP。工程师、机构组织和国家在谁能成为最好、最强壮的计算机网络标准这个问题上达成了非常明显的两极化,两套标准都是开放和非专利占有的,但彼此又互不兼容。
1988年的一幅漫画,人们认为全球可能会有两套网络协议,欧洲用OSI,美国用TCP/IP,二者再通过网关连接起来
OSI 想要为计算机网络创造一系列复杂全面的标准,设计 OSI 的架构师由一群来自英国、法国和美国的计算机行业的杰出代表组成,他们畅想设计一套完整的、开放的、分为多层的系统,让全世界的用户可以轻松的交换数据,为商业协作创造新的可能性。 在很长一段时间里,这个愿景看起来都是正确的。OSI 也因此获得了几乎所有重要人员的支持:计算机企业、电信公司、监管部门、国家政府、国家标准制定机构、学术研究人员,甚至是来自投资了竞争对手 TCP/IP 协议的美国国防部的支持。包括 IBM 在内的大型计算机企业也在 OSI 身上投入了大量的资金。在1980年代中期,OSI 标准在全世界普及似乎是命中注定、不可避免的。
但是,到了1990年代早期,OSI 万事俱备,发展速度却远远落后于另一种更便宜、更敏捷、更不全面的协议:互联网 TCP/IP 协议群。OSI 步履蹒跚、速度缓慢,而 TCP/IP 却一路向前狂奔,人们因此发出这样的感叹:OSI 是一个美丽的梦想,但 TCP/IP 已经梦想成真了。
OSI 一开始就是定位于跨国际的、全球性的工作,从1978年开始,到1980年开发陆续发布草案,到1984年最终 OSI 模型正式发布,都是跨国际的工作组,这一点从委员会和架构师的组成人员也可以看出。
而在1980年代 NSF 获得掌控权之前,TCP/IP 甚至从来就没有被当作过网络全球标准采用的候选者。一直到1989年,成套的协议群在 RFC 1122 和 RFC 1123 被提出,TCP/IP 才为成为一套全面完整的协议群设立了基础,最终发展成了现在人们所熟悉的 Internet protocol suite
为什么 TCP/IP 这匹黑马能战胜当时的大热门 OSI ,成为互联网协议的大赢家呢?有这么几个方面的说法。
TCP/IP 获胜的原因
理念与文化方面
在开发 TCP/IP 协议的时候,互联网工程师们习惯于在流动的组织形式中持续不断的做实验。他们觉得 OSI 委员会是一个过度官僚化的、 不接地气、高高在上的组织,从不触碰任何现有的网络系统和计算机。这使得互联网社区逐渐远离了 OSI 模型。
有一件小事可以反应这种文化的不同。在1992年的 IETF 会议( Internet Engineering Task Force)上, Vint Cerf(TCP/IP的领导者之一)在一次争吵中直接穿着西装跳起了脱衣舞,露出里面的T恤,T恤中间印着 IP on Everything 的字样。Cerf 称自己这个行为是为了强调互联网的目标是让一切都运行在IP地址上。
Vint Cerf 认为,早期在 ARPANET 中形成的这种社区文化,与技术因素一样重要,因为正是这种文化能让互联网的治理能力快速去跟随并适应协议的规模和发展。
此外,还有人总结,赢得互联网市场的公司,比如思科,都是小公司。因为它们拥抱了互联网的文化,对这种文化感兴趣,并且特别重要的是,它们能参加 IETF 的组织和会议。
在1992年的一次演讲中,David Clark 这样描述 IETF 这个组织的运作方式:
We reject kings, presidents and voting. We believe in rough consensus and running code.
我们不要国王、总统和投票。我们只相信“粗略的共识”和“能够运行的代码”。
“粗略的共识”和“能够运行的代码”可能是 IETF 最重要的特征。一个大项目,比如发明一个新的网络,通常是从上到下进行设计的,由公司或所属机构参与。而年轻的ARPA网和互联网社区则通过自下向上的风格完成自我进化,这种方式富有生产力,却并非结构化的团体协作。
参与者通常自己解决问题,然后把他们的解决方案贡献到 RFC(request for comment) 中。最好的 RFC 又变成了社区认可的统一标准。这种精英式的、同行评审的方法,与科学研究的过程非常类似。这种随心所欲的风格也为后来的一些项目提供了模版,包括 Web 和开源社区。
作为对比,在 OSI 那边,一个新的技术想要成为国际标准,每个方案都必须经过如下四个步骤:首先是先提出一个工作草案,然后再提出一个国际标准草案的提议,然后是变成国际标准草案,最后才是成为国际标准。在 OSI 中建立共识和相关标准,往往需要牵涉一大堆额外的涉及全体成员和委员会的会议。
OSI 的第一次全体会议整整持续了三天时间,从1978年2月28日开到了3月2日,参与者包括数十名来自10个国家的代表,以及从四个国际组织中挑选出的观察者。每个人在参会时都带着自己的市场利益保护心态,带着自己的项目来推广。
技术方面
许多人对 OSI 的复杂技术感到挫败和沮丧。OSI 定义了7层的模型,有人认为7层太多了,特别是传输层(5层,对比TCP/IP只有2层)过多,而每一层的严格定义被TCP/IP协议的拥护者认为是不高效的,不允许提高性能的trade-off。并且,OSI 在网络层同时定义了数据报和虚拟电路两种方法,而它们彼此是不具备互操作性的。
康奈尔大学的研究人员认为,OSI 失败的原因之一是它试图对所有东西都进行标准化,OSI 委员会试图控制网络中的一切。在缺少具备指导意义的操作经验的情况下,OSI 一直不断添加越来越多的功能。而早期的 TCP/IP 的技术理念则更为实用,它的座右铭是“粗略的共识和能够运行的代码”,TCP/IP 只是指定了网络和传输协议,它没有尝试去定义底层的网络技术,而上层的技术,比如电子邮件等应用程序的协议,则一直等到出现了可运行的代码之后,有了实践的经验和需要才开始被标准化。
实践与商业应用方面
除了技术,在实际应用方面,TCP/IP 一个成功的关键是决定将协议包含在 Unix 系统的Berkeley标准发行版(BSD)中。这也是由ARPA资助的。1983年发布的BSD 4.2,配备了完整的 TCP/IP 协议群,而且代码都是开源的。这些代码很快被移植到了很多其他操作系统中,成了第一代互联网的基础。
ARPA 和电信行业建立了商业伙伴关系,也进一步推动了 TCP/IP 的传播和采用。欧洲核子研究组织(CERN)在1984年至1988年之间为其内部网购买了带有TCP/IP的UNIX计算机。1988年,欧洲 UNIX 网络 EUnet 也宣布转移到 TCP/IP 协议上。
尽管如此,当时很多人依然认为应该与欧洲其他国家一起继续开发 OSI 协议,而非选择 ARPA。他们为自己所做的事情感到骄傲,并不是出于民族自豪感或者反对美国,而是认为自己在做正确的事。这种心态慢慢转化为了一种宗教教条。
此外,当时的 ARPA Internet 仍然是一个研究项目,不允许商业流量或营利性服务出现。美国商务部要求遵守 OSI 协议的标准,而美国国防部也计划从 TCP/IP 协议过渡到 OSI 协议。当时美国许多大学也抱着同样的心态,在校园网的选择上他们先使用 TCP/IP 协议,想着等到后面再迁移到 OSI 协议去。一些欧洲国家和 EEC 也批准了 OSI 协议,成立了RARE来推广OSI协议,并且限制了对非OSI兼容协议的投资。
但是,到了1989年,OSI 协议的倡导者 Brian Carpenter 在一个技术会议上发表了题为《OSI是否已经太晚了?》的演讲,这次演讲受到了热烈的掌声和欢迎。它表明,虽然 OSI 已正式定义完成,但与 OSI 相关的计算机制造商的产品和PTT的网络服务产品却还在苦苦等待开发中。
相比之下,TCP/IP 一直就不是官方标准(它是在非官方的RFC中定义的),但是自1983年以来,TCP/IP 已经提供了同时包含以太网和TCP/IP协议的UNIX工作站。
1990年,欧洲核子研究组织与美国康奈尔大学建立了跨大西洋的TCP/IP链接,欧洲一些国家和组织的学术机构已经采用或表示接受TCP/IP协议。1991年1月在卢瑟福实验室里,DECnet 占了75%的流量,这归功于VAXs之间的以太网。而 IP 协议则是第二大流行的协议,拥有近 20% 的流量,这主要归功于UNIX计算机,“ IP是自然的选择”。
在中央计算部新闻通讯中,卢瑟福实验室通信与小型系统主管 Paul Bryant 这样写道:“经验表明,与SNA等系统相比,IP系统非常易于安装和使用,而 X.25 和彩色书协议等系统则比较复杂”,他还写道:“美国学术流量的主要网络现在是基于IP协议的。IP协议最近在欧洲因站点间流量而变得流行。随着这种方法的出现,大型组合的美国/欧洲网络对英国用户来说具有很大的吸引力。“
当时,很多人也有类似的看法。在欧洲核子研究中心, FrançoisFlückiger表示: “该技术简单,高效,已集成到UNIX类型的操作系统中,并且对用户的计算机没有任何影响。最早将路由器商业化的公司(例如Cisco)看起来运行得很健康并且供应良好,最重要的是,用于本地校园网络和研究中心的技术也可以用于以简单的方式互连远程中心。”
TCP/IP 在这场协议战争中取得胜利的另一个关键点,发生于 1989 年,Tim Berners-Lee 在欧洲核子研究中心发明了万维网。万维网作为互联网上的应用程序,最终为互联网带来了许多社会和商业用途。
互联网在1993-1994年开始进入人们的日常使用。NSFNET 在1991年更改了其政策以允许商业通信,并在1995年被关闭,取消了对使用互联网进行商业通信的最后限制。随后,Internet骨干网由商业Internet服务提供商提供。互联网变得无处不在。
对区块链的启示
这段历史对今天区块链的格局有什么样的参考意义呢?上一场协议战争能为今天发生在区块链领域里的协议战争带来怎样的启发?
建立正确的组织形式和社区文化
所有人都知道“开放”是最重要的,但具体到社区文化和组织形式上仍然会有差异。OSI 从一开始就定位于跨国的全球性工作组,也融入了许多开放性多样化的社区人员,但最后它却变成了一个不同利益方互相追逐的混乱公地。
IBM 作为 OSI 中非常重要的一股力量,因为对自己已有业务利益的维护,在基于数据报的包交换(Packet switching)日益流行的情况下,依然选择维护仿虚拟电路交换的方案,正是这种不同利益方的弊端。
所以,对于很多区块链项目来说,践行开放开源的理念一定要找对方向。RFC 在 TCP/IP 协议的制定上起到了非常重要的角色,今天,区块链项目在推动技术发展、新协议和新标准上也应该有类似的方案。
以太坊应该是一个很不错的模版,社区文化所赋予的创造力是显而易见的,橙皮书之前写过相关的文章介绍《专访Vitalik:社区远比代码更重要》。而反观 Facebook 主导的 Libra 项目,几乎很难被人看好,在我看来,它类似于 OSI 的组织形式,由一家既得利益者的巨头企业主导,试图拉拢其他行业里的头部力量,我认为在怎样协调各成员的利益上,Libra 需要面临与 OSI 相同的难题。我在心里甚至认为,Libra 注定是要失败的。
不要过分纠结理念,先让代码跑起来
“粗略的共识,可运行的代码”——这句话是 TCP/IP 协议工作组的座右铭。换作在区块链行业里,我觉得类似的道理是,不要太过于纠结原教旨主义的理念,比如去中心化,也不要过早开始考虑怎样把项目过渡给社区接管,或者是在追求通过投票的方式完成项目的升级和进化、追求链上治理的方向上浪费太多力气。
因为这些事情也许都远不如让代码和协议能先跑起来、运行起来,来得更重要。这世界不缺理念正确的人,缺的是跑得足够快的人。其实类似的建议橙皮书之前也写过许多:《区块链应用层需要拿破仑》
不要追求完美的协议
OSI 与 TCP/IP 的竞争,最直接的一个教训是,世界上并不存在完美的协议。在区块链行业里,我看到不少项目方都在追求这种完美主义,或者不是追求,而是在以这种完美主义作为故事宣传自己的项目。
就公链这种大型基础设施而言,所有人都希望得到一个完美的解决方案,既能扩容、又去中心化、不用浪费电力、还能顺带解决跨链问题,既能跑DeFi,又能玩菠菜。想用一条链的技术,一次性解决这些问题是不可能的。要相信有用的协议最终都会逐渐得到补全、成为完整的协议群和协议栈,不要一开始就寄希望于发明一套完美的协议。从这个角度来说,似乎 Cosmos 的策略要比波卡更好。
如果你做了一个协议,这个协议能为开发者解决什么样的实际需求才是最重要的,不同的协议可以组合成协议栈,成为日后不可或缺的积木。而最简单的协议,往往最有可能率先存活下来。比如 Uniswap、0x、Compound。
这方面,同样的,橙皮书之前其实也写过类似的观点:《BTC与ETH:定位的胜利》
尽早让协议传播开来
最后一点,是让协议尽可能得到传播。
让协议传播有两种方法,一是找到传播的载体,借着某些必要的工具和产品得到推广和普及。
就像 TCP/IP 协议最早是搭载 UNIX 系统而得到传播一样,区块链协议也应该尽可能去寻找这样利于传播的载体,让你的协议尽早可以被开发者使用上。
另一种方法是,让协议产生有影响力的产品和应用,借着应用的普及而使底层协议得到普及。就像万维网建立在 TCP/IP 的基础上一样,万维网吸引了许多圈外的人使用互联网,最终也壮大了 TCP/IP 协议的发展。
以太坊,在我看来,它就率先为开发者提供了一套可编程的智能合约的功能。过去几年我不断听到有人对以太坊的智能合约以及solidity语言的批评,常见的批评观点是,以太坊没有必要提供一个图灵完备的智能合约功能,不是所有代码都需要放到链上,也没必要专门为编写 Dapp 发明一套新的语言。
这些观点当然都是正确的。但现实是,以太坊用智能合约这个最容易理解的概念先占领了开发者的大脑,它可能不是最完美的,但它率先得到了传播,那些掌握正确观点的人反而需要从头开始追赶以太坊领先的步伐。
最后
如果橙皮书是一家投资基金,我们该如何选择投资什么样的区块链协议?
TCP/IP 的历史告诉我们,应该选择那些信奉“粗糙的共识与可运行的代码”的项目,橙皮书想要投资的,应该是拥有这种社区文化的协议。
让我们把这种社区文化,再次重申一遍:
We reject kings, presidents and voting. We believe in rough consensus and running code.
(完)
参考来源:
https://www.computerhistory.org/revolution/networking/19/376
https://en.wikipedia.org/wiki/Protocol_Wars
https://spectrum.ieee.org/tech-history/cyberspace/osi-the-internet-that-wasnt
http://www.cs.cornell.edu/wya/AcademicComputing/text/nationalnets.html
欢迎打赏。BTC:1MibfK26s4u8GBLEAsTy82uVEBPBUG4z3F
写了 336 篇文章
评论
this comment section is using the amazing decentralized database engine - Gun.db
推荐阅读
从零开始学 DAPP 开发笔记:完成一个简单的“区块链计数器”网站
用初中数学知识解释什么是比特币
一文读懂稳定币:3种技术模式与基础理论介绍
预言家周报#19:DeFi就像集装箱,看似不起眼,却能撬动全球
关于Crypto合规,SEC在想什么?
Cent,一个去中心化的知乎,但它的野心远不止于“问答”
|
{
"url": "https://orange.xyz/p/547",
"source_domain": "orange.xyz",
"snapshot_id": "crawl=CC-MAIN-2020-34",
"warc_metadata": {
"Content-Length": "42045",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FTHAUGR66UKKFXSH7RX75MUSTHQDU73S",
"WARC-Concurrent-To": "<urn:uuid:bacac00f-2317-4094-a986-7325b03d825c>",
"WARC-Date": "2020-08-14T01:41:23Z",
"WARC-IP-Address": "139.198.15.72",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:XFYX7UDLY4ISD7EZZ2PHDR2NVI4H6DJ6",
"WARC-Record-ID": "<urn:uuid:3480729b-5c78-4619-9898-33d3d409b9b1>",
"WARC-Target-URI": "https://orange.xyz/p/547",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:94b8f560-e77f-43ac-bcf0-26ca620d01d5>"
},
"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-28.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,
7,
51,
62,
83,
107,
108,
235,
236,
326,
327,
462,
463,
582,
583,
755,
756,
870,
871,
1003,
1004,
1061,
1062,
1072,
1073,
1157,
1158,
1298,
1299,
1398,
1399,
1410,
1411,
1518,
1519,
1631,
1632,
1639,
1640,
1655,
1656,
1663,
1664,
1682,
1683,
1794,
1795,
1799,
1800,
1823,
1824,
1953,
1954,
1958,
1959,
1981,
1982,
2073,
2074,
2087,
2088,
2190,
2191,
2248,
2249,
2552,
2553,
2694,
2695,
2796,
2797,
2956,
2957,
3012,
3013,
3026,
3027,
3035,
3036,
3157,
3158,
3343,
3344,
3426,
3427,
3509,
3510,
3556,
3557,
3645,
3646,
3683,
3684,
3813,
3814,
3955,
3956,
4099,
4100,
4212,
4213,
4218,
4219,
4383,
4384,
4618,
4619,
4629,
4630,
4785,
4786,
4923,
4924,
5035,
5036,
5253,
5254,
5399,
5400,
5487,
5488,
5663,
5664,
5851,
5852,
6021,
6022,
6127,
6128,
6257,
6258,
6266,
6267,
6325,
6326,
6341,
6342,
6445,
6446,
6551,
6552,
6649,
6650,
6867,
6868,
6885,
6886,
7031,
7032,
7122,
7123,
7133,
7134,
7231,
7232,
7412,
7413,
7520,
7521,
7561,
7562,
7572,
7573,
7591,
7592,
7634,
7635,
7710,
7711,
7814,
7815,
7956,
7957,
8053,
8054,
8057,
8058,
8091,
8092,
8158,
8159,
8178,
8179,
8267,
8268,
8272,
8273,
8279,
8280,
8341,
8342,
8386,
8387,
8465,
8466,
8537,
8538,
8539,
8583,
8594,
8595,
8598,
8599,
8680,
8681,
8686,
8687,
8721,
8737,
8759,
8791,
8811
],
"line_end_idx": [
7,
51,
62,
83,
107,
108,
235,
236,
326,
327,
462,
463,
582,
583,
755,
756,
870,
871,
1003,
1004,
1061,
1062,
1072,
1073,
1157,
1158,
1298,
1299,
1398,
1399,
1410,
1411,
1518,
1519,
1631,
1632,
1639,
1640,
1655,
1656,
1663,
1664,
1682,
1683,
1794,
1795,
1799,
1800,
1823,
1824,
1953,
1954,
1958,
1959,
1981,
1982,
2073,
2074,
2087,
2088,
2190,
2191,
2248,
2249,
2552,
2553,
2694,
2695,
2796,
2797,
2956,
2957,
3012,
3013,
3026,
3027,
3035,
3036,
3157,
3158,
3343,
3344,
3426,
3427,
3509,
3510,
3556,
3557,
3645,
3646,
3683,
3684,
3813,
3814,
3955,
3956,
4099,
4100,
4212,
4213,
4218,
4219,
4383,
4384,
4618,
4619,
4629,
4630,
4785,
4786,
4923,
4924,
5035,
5036,
5253,
5254,
5399,
5400,
5487,
5488,
5663,
5664,
5851,
5852,
6021,
6022,
6127,
6128,
6257,
6258,
6266,
6267,
6325,
6326,
6341,
6342,
6445,
6446,
6551,
6552,
6649,
6650,
6867,
6868,
6885,
6886,
7031,
7032,
7122,
7123,
7133,
7134,
7231,
7232,
7412,
7413,
7520,
7521,
7561,
7562,
7572,
7573,
7591,
7592,
7634,
7635,
7710,
7711,
7814,
7815,
7956,
7957,
8053,
8054,
8057,
8058,
8091,
8092,
8158,
8159,
8178,
8179,
8267,
8268,
8272,
8273,
8279,
8280,
8341,
8342,
8386,
8387,
8465,
8466,
8537,
8538,
8539,
8583,
8594,
8595,
8598,
8599,
8680,
8681,
8686,
8687,
8721,
8737,
8759,
8791,
8811,
8839
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 8839,
"ccnet_original_nlines": 211,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.011399620212614536,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.12159594893455505,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.7929068803787231,
"rps_doc_frac_unique_words": 0.7615384459495544,
"rps_doc_mean_word_length": 21.14358901977539,
"rps_doc_num_sentences": 18,
"rps_doc_symbol_to_word_ratio": 0.0006333100027404726,
"rps_doc_unigram_entropy": 5.356375217437744,
"rps_doc_word_count": 390,
"rps_doc_frac_chars_dupe_10grams": 0.017220469191670418,
"rps_doc_frac_chars_dupe_5grams": 0.017220469191670418,
"rps_doc_frac_chars_dupe_6grams": 0.017220469191670418,
"rps_doc_frac_chars_dupe_7grams": 0.017220469191670418,
"rps_doc_frac_chars_dupe_8grams": 0.017220469191670418,
"rps_doc_frac_chars_dupe_9grams": 0.017220469191670418,
"rps_doc_frac_chars_top_2gram": 0.0014552499633282423,
"rps_doc_frac_chars_top_3gram": 0.01164200995117426,
"rps_doc_frac_chars_top_4gram": 0.012369629926979542,
"rps_doc_books_importance": -729.6339111328125,
"rps_doc_books_importance_length_correction": -729.6339111328125,
"rps_doc_openwebtext_importance": -456.6556701660156,
"rps_doc_openwebtext_importance_length_correction": -456.6556701660156,
"rps_doc_wikipedia_importance": -309.250732421875,
"rps_doc_wikipedia_importance_length_correction": -309.250732421875
},
"fasttext": {
"dclm": 0.03635447844862938,
"english": 0.0013658199459314346,
"fineweb_edu_approx": 1.467137336730957,
"eai_general_math": 0.012997389771044254,
"eai_open_web_math": 0.04040073975920677,
"eai_web_code": 0.7623968720436096
}
}
|
{
"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.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"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": "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": "15",
"label": "Nonfiction Writing"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "4",
"label": "Advanced 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
|
8,185,091,758,033,482,000
|
Wireshark Brew
Posted on by admin
Wireshark cli brew
There should be an uninstaller named uninistall.exe in Wireshark's installation directory. Its complete path should be in HKLM Software Microsoft Windows CurrentVersion Uninstall Wireshark UninstallString. More recent versions provide a quiet uninstall path, but this is simply the uninstaller with a '/S' argument.
It can be difficult to trace network traffic from a Node.js application.Typically, folks will just instrument some logging to check that everything isworking as it is supposed to. Unfortunately, sometimes there are too manyabstractions or possible race conditions to accurately get a good trace. To getthe most objective possible trace of network traffic Wireshark can be used.
Wireshark is a network protocol analyzer that makes it extremely simple tocapture and trace network activity from any source on your computer. It also hastools built in to decrypt traffic like that of HTTPS (TLS / SSL).
Wireshark Brew
Setup
In the case of capturing HTTPS (TLS / SSL) traffic, there is some setup beforecapturing traffic. If all you need is to capture unencrypted HTTP, then skip tothe Wireshark installation, since Wireshark can do so out-of-the-box.
• Wireshark is the world’s foremost and widely-used network protocol analyzer. It lets you see what’s happening on your network at a microscopic level and is the de facto (and often de jure) standard across many commercial and non-profit enterprises, government agencies, and educational institutions.
• Sep 18, 2020 To install Wireshark run this command from the Terminal: brew install wireshark. Homebrew will download and install Wireshark and any dependencies so it will run correctly. Wireshark for Linux. Installing Wireshark on Linux can be a little different depending on the Linux distribution.
SSL key logging for HTTPS (TLS / SSL) decryption
If you'd like to decrypt HTTPS (TLS / SSL) you will need to set a path via anenvironmental variable to collect SSL keys for use in Wireshark. This sameenvironmental variable works for most browsers and some other applications aswell.
Set the path and file name to whatever you would like.
Node.js SSL key logging
Node.js v12.3.0 introduced a keylog API to store SSL keys, but it can beunwieldy to setup and integrate with existing libraries. It also does not workwith the SSLKEYLOGFILE environmental variable. Luckily, there is a simple wayto set up using an npm module: sslkeylog. sslkeylog sets up global hooksinto the https module to capture any SSL keys used which makes it therecommended way of capturing SSL keys. sslkeylog can be installed with npmlike below:
Once sslkeylog is installed, import it and active its hooks before making anyHTTP(S) calls. For example:
Mac install wireshark brew
If you use TypeScript, you may need to include a declaration file like below:
Once capturing traffic is complete, you can remove all the code related to SSLkey logging.
Wireshark
First things first, you must install Wireshark program. On macOS you can usebrew to not only install the CLI, but the UI app as well:
Wireshark Browser Version
For Wireshark to be able to decrypt HTTPS (TLS / SSL) traffic it needs to readthe SSL Key log generated by Node.js or other applications. To configure thisfor Wireshark, open up the application and then open the preferences forWireshark. Once the preferences are open, open the 'Protocols' dropdown in theleft sidebar menu listing and scroll down to 'TLS', then click on it. On olderversions of Wireshark, look for 'SSL' instead of 'TLS'. Once the settings for'TLS' (or 'SSL' for older versions) is open, look for the '(Pre)-Master-Secretlog filename' setting and set the path to the same one that was configured abovevia the SSLKEYLOGFILE environmental variable. You might need to create anempty file at the path given.
Capturing traffic
Now that you are all setup, you can begin capturing traffic. Open up Wiresharkand select the capture interface, which for macOS is usually en0 (Wi-Fi).
Once capturing has begun you should start to see logs of all sorts of trafficto be listed, unless you are not connected to the internet.
Wireshark Brew
This traffic can be overwhelming and mostly unrelated to Node.js or theapplication you are trying to inspect. This where filters come in handy.
Run Wireshark Brew Install
For example, to filter requests on a domain:
Or to filter on a certain IP address:
Filters can also be combined with conditional operators && and .
Once capturing has begun, you can start your app up as normal and try to causenetwork activity that is in need of being traced.
Hopefully, with a combination with the filters you will be able to find theexact requests and responses you are looking for. If you find either a requestor a response you can right click on a line item and select 'Follow > HTTPStream' to see the both of the request and response.
Wireshark Brew Minecraft
Wireshark brew 3
Wireshark Previous Name
Additionally, you can save any traffic captured for later use or to send topeers for inspection.
|
{
"url": "https://rock-fan.ru/wireshark-brew/",
"source_domain": "rock-fan.ru",
"snapshot_id": "crawl=CC-MAIN-2021-49",
"warc_metadata": {
"Content-Length": "13524",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:RRUS7ZARLIAFE2ZSYHADHBLSHBMGZS4C",
"WARC-Concurrent-To": "<urn:uuid:ebb01498-0055-41be-bb93-6d98b0622df9>",
"WARC-Date": "2021-12-05T05:51:00Z",
"WARC-IP-Address": "104.21.43.184",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:T3X6N7SXVGN5JIEE562BRZPFTA3A22FL",
"WARC-Record-ID": "<urn:uuid:12dd0ac4-49e0-4221-9d2d-d9c5d6275f3b>",
"WARC-Target-URI": "https://rock-fan.ru/wireshark-brew/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:4b560753-81fc-4de2-91d3-bce74e851886>"
},
"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-155\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,
15,
16,
36,
55,
56,
372,
373,
751,
752,
972,
973,
988,
989,
995,
996,
1223,
1224,
1528,
1832,
1833,
1882,
1883,
2117,
2118,
2173,
2174,
2198,
2199,
2653,
2654,
2759,
2760,
2787,
2788,
2866,
2867,
2958,
2959,
2969,
2970,
3104,
3105,
3131,
3132,
3853,
3854,
3872,
3873,
4025,
4026,
4163,
4164,
4179,
4180,
4324,
4325,
4352,
4353,
4398,
4399,
4437,
4438,
4503,
4504,
4632,
4633,
4913,
4914,
4939,
4940,
4957,
4958,
4982,
4983
],
"line_end_idx": [
15,
16,
36,
55,
56,
372,
373,
751,
752,
972,
973,
988,
989,
995,
996,
1223,
1224,
1528,
1832,
1833,
1882,
1883,
2117,
2118,
2173,
2174,
2198,
2199,
2653,
2654,
2759,
2760,
2787,
2788,
2866,
2867,
2958,
2959,
2969,
2970,
3104,
3105,
3131,
3132,
3853,
3854,
3872,
3873,
4025,
4026,
4163,
4164,
4179,
4180,
4324,
4325,
4352,
4353,
4398,
4399,
4437,
4438,
4503,
4504,
4632,
4633,
4913,
4914,
4939,
4940,
4957,
4958,
4982,
4983,
5079
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5079,
"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.38842976093292236,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03822313994169235,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.14979338645935059,
"rps_doc_frac_unique_words": 0.4312267601490021,
"rps_doc_mean_word_length": 5.05576229095459,
"rps_doc_num_sentences": 51,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.257748126983643,
"rps_doc_word_count": 807,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.021568629890680313,
"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.02230392023921013,
"rps_doc_frac_chars_top_3gram": 0.013480390422046185,
"rps_doc_frac_chars_top_4gram": 0.008823529817163944,
"rps_doc_books_importance": -489.5670166015625,
"rps_doc_books_importance_length_correction": -489.5670166015625,
"rps_doc_openwebtext_importance": -268.3906555175781,
"rps_doc_openwebtext_importance_length_correction": -268.3906555175781,
"rps_doc_wikipedia_importance": -199.78045654296875,
"rps_doc_wikipedia_importance_length_correction": -199.78045654296875
},
"fasttext": {
"dclm": 0.04418390989303589,
"english": 0.891072154045105,
"fineweb_edu_approx": 2.3489694595336914,
"eai_general_math": 0.6014936566352844,
"eai_open_web_math": 0.33982986211776733,
"eai_web_code": 0.7400891780853271
}
}
|
{
"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.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": "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,569,255,845,837,588,000
|
How do you integrate #int cost/sqrt(1+sin^2t)# by trigonometric substitution?
1 Answer
Sep 11, 2016
#lnabs(sqrt(sin^2t+1)+sint)+C#
Explanation:
We have:
#intcost/sqrt(1+sin^2t)dt#
We will use the substitution #sint=tantheta#. Thus, #costdt=sec^2thetad theta#.
Substituting, this yields:
#=int(sec^2thetad theta)/sqrt(1+tan^2theta)#
Since #1+tan^2theta=sec^2theta#:
#=int(sec^2thetad theta)/sectheta=intsecthetad theta#
This is a common integral:
#=lnabs(sectheta+tantheta)#
Since we know #sint=tantheta#, write #sectheta# in terms of #tantheta#:
#=lnabs(sqrt(tan^2theta+1)+tantheta)#
#=lnabs(sqrt(sin^2t+1)+sint)+C#
|
{
"url": "https://api-project-1022638073839.appspot.com/questions/how-do-you-integrate-int-cost-sqrt-1-sin-2t-by-trigonometric-substitution",
"source_domain": "api-project-1022638073839.appspot.com",
"snapshot_id": "CC-MAIN-2024-38",
"warc_metadata": {
"Content-Length": "34338",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:75AK2EZL7LAB54N7J7HZIDU2JQN4TPQ2",
"WARC-Concurrent-To": "<urn:uuid:3f2fdb5a-64b7-4a6a-844d-998b621b77a8>",
"WARC-Date": "2024-09-18T15:38:18Z",
"WARC-IP-Address": "142.250.31.153",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:22VKEKRQ4XAZ57QFFGWBIJLDIBXNSAXU",
"WARC-Record-ID": "<urn:uuid:e5f8cf27-3d0c-4592-8d5c-f0a4f6a18bda>",
"WARC-Target-URI": "https://api-project-1022638073839.appspot.com/questions/how-do-you-integrate-int-cost-sqrt-1-sin-2t-by-trigonometric-substitution",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:95d10ba4-2bcd-4d40-b916-4e281f1b3350>"
},
"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-5\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,
78,
79,
88,
101,
102,
133,
134,
147,
148,
157,
158,
185,
186,
266,
267,
294,
295,
340,
341,
374,
375,
429,
430,
457,
458,
486,
487,
559,
560,
598,
599
],
"line_end_idx": [
78,
79,
88,
101,
102,
133,
134,
147,
148,
157,
158,
185,
186,
266,
267,
294,
295,
340,
341,
374,
375,
429,
430,
457,
458,
486,
487,
559,
560,
598,
599,
630
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 630,
"ccnet_original_nlines": 31,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.07608696073293686,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.010869570076465607,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5,
"rps_doc_frac_unique_words": 0.8392857313156128,
"rps_doc_mean_word_length": 8.160714149475098,
"rps_doc_num_sentences": 4,
"rps_doc_symbol_to_word_ratio": 0.15217390656471252,
"rps_doc_unigram_entropy": 3.793210744857788,
"rps_doc_word_count": 56,
"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": -83.17247772216797,
"rps_doc_books_importance_length_correction": -94.8901138305664,
"rps_doc_openwebtext_importance": -39.044097900390625,
"rps_doc_openwebtext_importance_length_correction": -50.76173400878906,
"rps_doc_wikipedia_importance": -33.45236587524414,
"rps_doc_wikipedia_importance_length_correction": -45.17000198364258
},
"fasttext": {
"dclm": 0.8333233594894409,
"english": 0.36706849932670593,
"fineweb_edu_approx": 2.620579242706299,
"eai_general_math": 0.9955481886863708,
"eai_open_web_math": 0.991569459438324,
"eai_web_code": 0.00008320999768329784
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "515.35",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Calculus and Mathematical analysis"
}
},
"secondary": {
"code": "515.9",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Calculus and Mathematical analysis"
}
}
},
"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": "23",
"label": "Tutorial"
},
"secondary": {
"code": "18",
"label": "Q&A Forum"
}
},
"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
|
-5,761,115,522,715,475,000
|
Stack Overflow is a community of 4.7 million programmers, just like you, helping each other.
Join them; it only takes a minute:
Sign up
Join the Stack Overflow community to:
1. Ask programming questions
2. Answer and help your peers
3. Get recognized for your expertise
I'm looking for a way to allow potential customers to try my application before they buy it.
The product is a windows forms application that requires an SQL Server database to operate.
Although I have a functional demo that the customer can install on their network, I want to make it easier for them by have them "play" with it at my environment.
I remember Microsoft had (has?) something similar. I was testing Visual Studio a few years ago in a virtual environment where I was connecting to a server at Microsoft. They setup the environment this way so when a user logs off after using it rollback his actions. Or to explain it better: when a user logins it starts with a new, clean environment. So any projects I've created testing Visual Studio were lost after I logged off.
Any suggestions?
Thanks.
share|improve this question
Some solutions that come to mind:
Provide remote access
You could provide access to a running instance of your application via some sort of remote connection protocol, e.g. via RDP or via VNC.
For example, there is a Java VNC client which can run as a Java applet; you could put that on a webpage and have it connect to a VNC session you host on your servers.
Or use Windows Terminal Server, and allow connection via RDP.
Both solutions of course have the drawback that people need to open the appropriate ports, if they are behind a firewall. There might be ways around that, however (e.g. you can run VNC over HTTP).
VM image
A completely different solution: Provide a ready-to-run VM image (for VMWare, VirtualBox or similar) of your application, including server and everything. You would need a demo version of your app though, plus getting redistribution rights for all the proprietary components (Windows OS, SQL server) might get hairy.
Offer videos
Often people do not really need to actually use the app; they are mainly interested to see how it works. So maybe it is enough to host videos of the app in operation. That allows you to put in some advertising for your features, and lets you show the users what they might miss when testing on their own.
share|improve this answer
@sleske: I have 5 videos and a full demo of the product. What I'm trying to avoid is doing private demos to potential customers. I thought the VM idea but that requires an extra step from them and IT involvement... I'll check the VNC solutions you suggest. – Stefanos Tses Apr 22 '10 at 17:15
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/2692455/online-product-demo-environment-for-windows-applications",
"source_domain": "stackoverflow.com",
"snapshot_id": "crawl=CC-MAIN-2016-07",
"warc_metadata": {
"Content-Length": "73210",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XD5N65G2PI32SRXFC5GQ2EDKE5C3C4FT",
"WARC-Concurrent-To": "<urn:uuid:3cbc3286-8d4e-4a74-a988-18729e3e9b42>",
"WARC-Date": "2016-02-06T03:06:33Z",
"WARC-IP-Address": "104.16.34.249",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:H5CLVOZYVXZETSA3KCZB3HVO5WGWDQWO",
"WARC-Record-ID": "<urn:uuid:c06b9e29-d811-44a6-a7a5-30dff76d658f>",
"WARC-Target-URI": "http://stackoverflow.com/questions/2692455/online-product-demo-environment-for-windows-applications",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e28587ae-1f9d-4931-b18a-f0ddc316ef0d>"
},
"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,
93,
94,
129,
130,
138,
176,
207,
239,
278,
279,
372,
373,
465,
466,
629,
630,
1062,
1063,
1080,
1081,
1089,
1090,
1118,
1119,
1153,
1154,
1176,
1177,
1314,
1315,
1482,
1483,
1545,
1546,
1743,
1744,
1753,
1754,
2071,
2072,
2085,
2086,
2391,
2392,
2418,
2423,
2716,
2717,
2729,
2730,
2732,
2740,
2741,
2819,
2820
],
"line_end_idx": [
93,
94,
129,
130,
138,
176,
207,
239,
278,
279,
372,
373,
465,
466,
629,
630,
1062,
1063,
1080,
1081,
1089,
1090,
1118,
1119,
1153,
1154,
1176,
1177,
1314,
1315,
1482,
1483,
1545,
1546,
1743,
1744,
1753,
1754,
2071,
2072,
2085,
2086,
2391,
2392,
2418,
2423,
2716,
2717,
2729,
2730,
2732,
2740,
2741,
2819,
2820,
2910
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2910,
"ccnet_original_nlines": 55,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.43405675888061523,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04674457013607025,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.15358932316303253,
"rps_doc_frac_unique_words": 0.5188118815422058,
"rps_doc_mean_word_length": 4.522772312164307,
"rps_doc_num_sentences": 37,
"rps_doc_symbol_to_word_ratio": 0.0016694499645382166,
"rps_doc_unigram_entropy": 5.1827473640441895,
"rps_doc_word_count": 505,
"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.003940459806472063,
"rps_doc_frac_chars_top_3gram": 0.01225918997079134,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -254.19126892089844,
"rps_doc_books_importance_length_correction": -254.19126892089844,
"rps_doc_openwebtext_importance": -164.74819946289062,
"rps_doc_openwebtext_importance_length_correction": -164.74819946289062,
"rps_doc_wikipedia_importance": -128.60928344726562,
"rps_doc_wikipedia_importance_length_correction": -128.60928344726562
},
"fasttext": {
"dclm": 0.5541321635246277,
"english": 0.954548716545105,
"fineweb_edu_approx": 1.4936373233795166,
"eai_general_math": 0.004356210120022297,
"eai_open_web_math": 0.08918535709381104,
"eai_web_code": 0.0033780899830162525
}
}
|
{
"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": "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": "-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": "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,784,136,647,148,690,000
|
Original TUTOR(dot)COM
In 1985, Computer Knowledge prepared a basic tutorial about microcomputers and DOS. The exercise was to help students and to help me learn programming. The first goal was somewhat successful; the second, not so much as I look back on the code. 🙂
One of my ultimate goals is to recreate that tutorial in different form and updated to today’s technology. But, in the process, I thought it might be of interest to see the original. I picked the 1991 version as one of the last versions in the original format.
The original was a DOS-based program that displayed text-only pages, one page at a time. You could navigate the pages and at times the program would ask questions and expect an answer.
TUTOR.COM Color Selection When started, the program would go through a setup routine and asked if you wanted to view the text in color or monochrome and if you wanted sound or not. The sound was just simple beeps; nothing fancy.
TUTOR.COM Main Menu You were then presented with the tutorial’s main menu. There were nine different choices plus zero to exit the program. The choices are duplicated below and each will take you to a page where you can browse a gallery of screen shots for that topic. Enjoy…
TUTOR.COM Main Menu
1. Tutorial which explains TUTOR.COM (version 4.5).
2. A description of the expanded keyboard.
3. Brief history of computers.
4. Introduction to computers, binary numbers, and the CPU.
5. Introduction to storage and input/output devices.
6. Disk Operating System operation and commands.
7. A tutorial on subdirectory structure and commands.
8. Batch file commands and structure explained.
9. A brief introduction to structured programming.
Additionally, you could start the program with the parameter OLDKEY and this would cause the #2 keyboard tutorial to switch from the expanded keyboard to the original IBM-style keyboard. That one is here…
|
{
"url": "https://www.cknow.com/cms/tutcom/original-tutordotcom.html",
"source_domain": "www.cknow.com",
"snapshot_id": "crawl=CC-MAIN-2020-16",
"warc_metadata": {
"Content-Length": "54241",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LTAAI3X2FBXWTLURI57D7R5Z2Z3DOMGT",
"WARC-Concurrent-To": "<urn:uuid:81769a2c-7363-4680-a89c-686ec0e74f4d>",
"WARC-Date": "2020-04-02T04:14:54Z",
"WARC-IP-Address": "216.92.199.155",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:KYOQYDRVRHPZB2Q3IX5MMH3IZMJCDBIY",
"WARC-Record-ID": "<urn:uuid:050497ad-0743-4366-a3a8-3041c39df686>",
"WARC-Target-URI": "https://www.cknow.com/cms/tutcom/original-tutordotcom.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ae9853f6-796a-48fa-840a-addf3d2087a9>"
},
"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-82.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,
23,
24,
270,
271,
532,
533,
718,
719,
948,
1224,
1225,
1245,
1246,
1300,
1345,
1378,
1439,
1494,
1545,
1601,
1651,
1704,
1705
],
"line_end_idx": [
23,
24,
270,
271,
532,
533,
718,
719,
948,
1224,
1225,
1245,
1246,
1300,
1345,
1378,
1439,
1494,
1545,
1601,
1651,
1704,
1705,
1909
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1909,
"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.37628865242004395,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.054123710840940475,
"rps_doc_frac_lines_end_with_ellipsis": 0.0833333283662796,
"rps_doc_frac_no_alph_words": 0.19329896569252014,
"rps_doc_frac_unique_words": 0.5682539939880371,
"rps_doc_mean_word_length": 4.8031744956970215,
"rps_doc_num_sentences": 38,
"rps_doc_symbol_to_word_ratio": 0.007731960155069828,
"rps_doc_unigram_entropy": 4.770804405212402,
"rps_doc_word_count": 315,
"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.029081299901008606,
"rps_doc_frac_chars_top_3gram": 0.019828159362077713,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -102.73050689697266,
"rps_doc_books_importance_length_correction": -102.73045349121094,
"rps_doc_openwebtext_importance": -72.38246154785156,
"rps_doc_openwebtext_importance_length_correction": -72.38246154785156,
"rps_doc_wikipedia_importance": -21.3617000579834,
"rps_doc_wikipedia_importance_length_correction": -21.3617000579834
},
"fasttext": {
"dclm": 0.1265491247177124,
"english": 0.9242819547653198,
"fineweb_edu_approx": 2.6898932456970215,
"eai_general_math": 0.7335794568061829,
"eai_open_web_math": 0.2340184450149536,
"eai_web_code": 0.14610475301742554
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.0151",
"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": "-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": "4",
"label": "Missing Images or Figures"
}
},
"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": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-6,581,756,062,393,194,000
|
21 - GRUB4DOS GUIDE (with videos) - how to make a multi-boot drive (+examples)
72 - Easy2Boot - a grub4dos multiboot USB drive that is easy to maintain!
Tutorials, How To's and Guides
21 - GRUB4DOS GUIDE (with videos) - how to make a multi-boot drive (+examples) (4)
72 - Easy2Boot - a grub4dos multiboot USB drive that is easy to maintain! (3)
09 - How to make a bootable BACKTRACK 4/5 (linux) USB drive
Unique hits
tumblr stats
BackTrack is a Linux-based penetration testing arsenal that aids security professionals in the ability to perform assessments in a purely native environment dedicated to hacking. BackTrack has been customized down to every package, kernel configuration, script and patch solely for the purpose of penetration testing. Backtrack also includes some web browsers, and wireless network, video and audio drivers which means on some systems you can boot from your USB stick and have a fully functioning PC/netbook even if you don't use the testing tools.
NoteBT5 can be booted directly from an ISO file by Easy2Boot (with or without persistence).
See also Tutorial 99 (Xiaopan) for WiFi cracking.
Fig. 1 Backtrack
Type startx to start the GUI...
Fig. 2 Click to enlarge
BackTrack can be used to check the security of your wireless network. It also contains FireFox and many other useful tools such as wireshark for tracing PXE boot issues.
WARNING: It is illegal to attempt to hack someone's network/computer unless you have their permission!
This tutorial uses grub4dos and extracted files from the BackTrack ISO file - you cannot easily boot BackTrack directly from a BackTrack ISO file (News: You can using Tutorial 93!) - see the end of this page for details of a commonly suggested method using the ISO file alone which DOES NOT WORK!.
1. Download BackTrack 5 ISO from here
I suggest you download the Gnome or KDE x86 ISO file.
Note: The KDE 64-bit BT5 has a problem when startx runs and bombs out! There are some workarounds here.
2. Run RMPrepUSB with settings as below (BackTrack may not fully boot if you format as NTFS!) and click on Prepare Drive (drive letter should be same as used by CloneDrive)
Fig. 3 Use 1=MAX,3=MS-DOS,4=FAT32,5=for source ISO + Tick COPY OS FILES
3. Click on Install grub4dos button and answer OK to all default questions
4. USB contents (highlighted = required to be on the USB drive):
\.disk (must be in root of drive - must NOT be moved or 'Identifying CDROM' will fail)
README.diskdefines
\casper (can be moved - e.g. \BT5\casper)
\isolinux
md5sum.txt
\preseed (can be moved - e.g. \BT5\preseed)
ubuntu
menu.lst (must be in root of drive)
grldr (must be in root of drive)
casper-rw (must be in root of drive for persistent filesystem)
Menu 1 for a persistent version (you need a casper-rw file on the USB drive)
Menu 2 is for a non-persistent boot
Menu 3 and 4 are examples where the casper and preseed folders have been moved to a \BT5 folder on the USB drive.
title --- BACKTRACK 5 ---
root
title 1 BackTrack 5 (1024x768) Persistent\nType startx to run GUI once booted PERSISTENT
kernel /casper/vmlinuz file=/cdrom/preseed/custom.seed boot=casper text splash noprompt vga=791-- persistent
initrd /casper/initrd.gz
title 2 BackTrack 5 (1024x768) Non-Persistent\nType startx to run GUI once booted NON-PERSISTENT
kernel /casper/vmlinuz file=/cdrom/preseed/custom.seed boot=casper text splash noprompt vga=791-- nonpersistent
initrd /casper/initrd.gz
OR
You can copy some of the contents of the DVD ISO to the \BT5 folder on your USB drive, but you must keep the \.disk folder in the root and use the menus shown below.
#for UK with no splash screen and casper folder moved to \BT5\casper on USB drive
#noprompt suppresses the 'remove CD' message on reboot/shutdown - use splash intead of textonly if you prefer. The keyboard setting does not change the GUI keyboard setting.
title 3 BackTrack 5 (1024x768) Persistent\nType startx to run GUI once booted PERSISTENT
kernel /BT5/casper/vmlinuz file=/cdrom/preseed/custom.seed live-media-path=BT5/casper boot=casper locale=en_GB.UTF-8 keyb=uk textonly noprompt vga=791-- persistent
initrd /BT5/casper/initrd.gz
title 4 BackTrack 5 (1024x768) Persistent\nType startx to run GUI once booted NON-PERSISTENT
kernel /BT5/casper/vmlinuz file=/cdrom/preseed/custom.seed live-media-path=BT5/casper boot=casper locale=en_GB.UTF-8 keyb=uk textonly noprompt vga=791--
initrd /BT5/casper/initrd.gz
1. (optional) - Click on the Create Ext2 FS button and create a file called casper-rw of at least 1000MB (as large as you have space for). This will create a mountable volume for persistent changes.
2. Click on Eject button and go try it!
Fig. 4 Press ESC to see any linux error messages whilst loading...
8. Once booted - type startx to start the GUI portion of the OS. You may need to hit the [Enter] key if it sticks at the boot prompt first.
Fig. 5 Type Startx to start the Desktop - username=root password=toor ('root' backwards)
To start the network, click on the bottom left icon and then choose Services - Network - Start Network
Change the keyboard locale by clicking on the flag symbol in the bottom task bar.
Change the resolution by clicking on the screen+double-arrow icon on the task bar.
You can browse the web using FireFox or Konqueror.
In case of corruption at a later date - once you have BackTrack working as you like, make a copy of the casper-rw file and save it on a hard disk somewhere. That way you can restore a working copy if it ever gets corrupted.
Troubleshooting
If the persistent filesystem is damaged, it may not boot and you may see an error message like: EXT2-fs (loop 1 error). In this case delete the casper-rw file and re-make it using RMPrepUSB Create Ext FS again (follow step 6).
If you already have a version of linux that uses a casper-rw persistent file. You can use a persistent file of a different name as follows:
1. Use RMPrepUSB - Create Ext2 FS to create a file called casper-rw (NOTE: DO NOT USE ANY OTHER NAME!).
2. Rename the casper-rw file to BT5-rw (NOTE: YOU MUST RENAME casper-rw to BT5-rw - do NOT simply make a BT5-rw ext2 file!)
3. Modify the menu entry to create/overwrite the 4th partition entry as follows:
# Note: The 4th partition table entry will be destroyed by this line!
partnew (hd0,3) 0x0 (bd)/BT5-rw
Alternatively, you may find it more reliable to delete the casper-rw file and make a new ext3 partition using EaseUS Home Partition Master after shrinking the existing partition. Once you have it all working, you can make a backup of the partition using RMPrepUSB - Disk->File and using the partition number of the ext3 partition (e.g. P3).
If you want to encrypt the USB pen at the same time - follow this video here.
WPA2/WPS/WEP Cracking with Reaper
WPS details here - Note: This only works if WPS is enabled on the target router. If WPS is not enabled then you will see a 'WARNING: Failed to associate with [MAC ADDRESS] (ESSID: xxxxx).
WPS cracking works by utilizing a crazy flaw! in the protocol. The 8 digit WPS number consists of 7 digits and a checksum digit. If the first 4 digits are incorrect an error message is returned - this means that we only have to crack the first 4 digits and then the next 3!
“An attacker can derive information about the correctness of parts the PIN from the AP´s responses. If the attacker receives an EAP-NACK message after sending M4, he knows that the 1st half of the PIN was incorrect. If the attacker receives an EAP-NACK message after sending M6, he knows that the 2nd half of the PIN was incorrect.
This form of authentication dramatically decreases the maximum possible authentication attempts needed from 10^8 (=100.000.000) to 10^4 + 10^4(=20.000). As the 8th digit of the PIN is always a checksum of digit one to digit seven, there are at most 10^4 + 10^3 (=11.000) attempts needed to find the correct PIN.”
For this reason do not enable WPS on your wireless router/access point (or do not press the WPS button on the router). Just use WPA2 and a long password!
WEP cracking details here
See YouTube videos below for more details.
BackTrack 4
Create a menu.lst
file for BT4 on the USB drive with the following contents
title BackTrack 4 (1024x768)\nType startx to run GUI once booted
kernel /boot/vmlinuz BOOT=casper boot=casper nopersistent rw quiet noprompt vga=0x317
initrd /boot/initrd.gz
The casper parameters are detailed here (use this if you want to modify any folders, etc.). e.g. live-media-path=BT5/casper locale=en_GB.UTF-8 keyb=uk textonly noprompt.
The file contents of the USB drive for BT4 should now be:
\boot
\casper
boot.catalog
md5sum.txt
grldr
menu.lst
PLEASE NOTE: Booting BackTrack4/5 FROM AN ISO FILE DOES NOT WORK LIKE THIS!
You cannot boot BT from an ISO (unless you modify files inside the ISO - which I have not tested)!
The menu below do NOT work - backtrack starts to boot but then you get an (initramfs) shell error
title BackTrack 4 (DOES NOT WORK!)
find --set-root /bt4-final.iso
map /bt4-final.iso (hd32)
map --hook
root (hd32)
chainloader (hd32)
However, you can use just an ISO using
Tutorial 93!
WEP key security check
Another WPA2 security check video
WPA2 Cracking
|
{
"url": "http://www.rmprepusb.com/tutorials/how-to-make-a-usb-bootable-backtrack-4-drive",
"source_domain": "www.rmprepusb.com",
"snapshot_id": "crawl=CC-MAIN-2015-48",
"warc_metadata": {
"Content-Length": "508765",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:2G6EPN24OX6UIG4JYVLOUTZW3V5SWOL2",
"WARC-Concurrent-To": "<urn:uuid:b02eaba8-b0df-43a1-911f-6cacc707df51>",
"WARC-Date": "2015-11-28T20:09:55Z",
"WARC-IP-Address": "104.27.174.163",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:33DIGBAA24A2PRB4F7BIU4UDKTXPX22Y",
"WARC-Record-ID": "<urn:uuid:6ef26cbe-f24d-4d0d-bb94-d5a29d18e324>",
"WARC-Target-URI": "http://www.rmprepusb.com/tutorials/how-to-make-a-usb-bootable-backtrack-4-drive",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:df4878c1-aadf-4351-985c-7d19b690e9e1>"
},
"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,
79,
153,
184,
267,
345,
346,
406,
407,
420,
434,
435,
984,
985,
1077,
1078,
1128,
1129,
1146,
1147,
1148,
1149,
1181,
1205,
1206,
1207,
1208,
1378,
1379,
1482,
1483,
1781,
1782,
1823,
1881,
1989,
1990,
2165,
2166,
2167,
2243,
2244,
2245,
2246,
2323,
2324,
2391,
2392,
2493,
2512,
2565,
2575,
2586,
2639,
2646,
2682,
2715,
2785,
2786,
2787,
2864,
2900,
3014,
3015,
3041,
3054,
3055,
3144,
3253,
3278,
3279,
3376,
3488,
3513,
3514,
3517,
3518,
3684,
3685,
3767,
3941,
3942,
4031,
4198,
4227,
4228,
4321,
4478,
4507,
4508,
4709,
4710,
4753,
4820,
4821,
4822,
4962,
4963,
4964,
5054,
5055,
5158,
5240,
5323,
5374,
5598,
5599,
5615,
5616,
5845,
5846,
5986,
5987,
6091,
6215,
6296,
6297,
6367,
6399,
6400,
6741,
6742,
6820,
6821,
6855,
6856,
7044,
7045,
7319,
7651,
7964,
7965,
8119,
8120,
8146,
8147,
8190,
8191,
8192,
8204,
8205,
8206,
8224,
8284,
8285,
8352,
8440,
8465,
8466,
8638,
8639,
8697,
8703,
8711,
8724,
8735,
8741,
8750,
8751,
8752,
8753,
8829,
8928,
9026,
9027,
9062,
9093,
9119,
9130,
9142,
9161,
9162,
9163,
9164,
9203,
9216,
9217,
9218,
9219,
9242,
9243,
9244,
9245,
9246,
9247,
9248,
9282,
9283,
9284,
9285
],
"line_end_idx": [
79,
153,
184,
267,
345,
346,
406,
407,
420,
434,
435,
984,
985,
1077,
1078,
1128,
1129,
1146,
1147,
1148,
1149,
1181,
1205,
1206,
1207,
1208,
1378,
1379,
1482,
1483,
1781,
1782,
1823,
1881,
1989,
1990,
2165,
2166,
2167,
2243,
2244,
2245,
2246,
2323,
2324,
2391,
2392,
2493,
2512,
2565,
2575,
2586,
2639,
2646,
2682,
2715,
2785,
2786,
2787,
2864,
2900,
3014,
3015,
3041,
3054,
3055,
3144,
3253,
3278,
3279,
3376,
3488,
3513,
3514,
3517,
3518,
3684,
3685,
3767,
3941,
3942,
4031,
4198,
4227,
4228,
4321,
4478,
4507,
4508,
4709,
4710,
4753,
4820,
4821,
4822,
4962,
4963,
4964,
5054,
5055,
5158,
5240,
5323,
5374,
5598,
5599,
5615,
5616,
5845,
5846,
5986,
5987,
6091,
6215,
6296,
6297,
6367,
6399,
6400,
6741,
6742,
6820,
6821,
6855,
6856,
7044,
7045,
7319,
7651,
7964,
7965,
8119,
8120,
8146,
8147,
8190,
8191,
8192,
8204,
8205,
8206,
8224,
8284,
8285,
8352,
8440,
8465,
8466,
8638,
8639,
8697,
8703,
8711,
8724,
8735,
8741,
8750,
8751,
8752,
8753,
8829,
8928,
9026,
9027,
9062,
9093,
9119,
9130,
9142,
9161,
9162,
9163,
9164,
9203,
9216,
9217,
9218,
9219,
9242,
9243,
9244,
9245,
9246,
9247,
9248,
9282,
9283,
9284,
9285,
9298
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 9298,
"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.282661497592926,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.07770763337612152,
"rps_doc_frac_lines_end_with_ellipsis": 0.010526319965720177,
"rps_doc_frac_no_alph_words": 0.2452646940946579,
"rps_doc_frac_unique_words": 0.3403247594833374,
"rps_doc_mean_word_length": 4.828822612762451,
"rps_doc_num_sentences": 112,
"rps_doc_symbol_to_word_ratio": 0.0024283600505441427,
"rps_doc_unigram_entropy": 5.565492630004883,
"rps_doc_word_count": 1478,
"rps_doc_frac_chars_dupe_10grams": 0.09373685717582703,
"rps_doc_frac_chars_dupe_5grams": 0.1794871836900711,
"rps_doc_frac_chars_dupe_6grams": 0.16295361518859863,
"rps_doc_frac_chars_dupe_7grams": 0.13577133417129517,
"rps_doc_frac_chars_dupe_8grams": 0.13577133417129517,
"rps_doc_frac_chars_dupe_9grams": 0.1074681207537651,
"rps_doc_frac_chars_top_2gram": 0.007706319913268089,
"rps_doc_frac_chars_top_3gram": 0.007706319913268089,
"rps_doc_frac_chars_top_4gram": 0.009808040224015713,
"rps_doc_books_importance": -872.8155517578125,
"rps_doc_books_importance_length_correction": -872.8155517578125,
"rps_doc_openwebtext_importance": -575.1734619140625,
"rps_doc_openwebtext_importance_length_correction": -575.1734619140625,
"rps_doc_wikipedia_importance": -352.9900207519531,
"rps_doc_wikipedia_importance_length_correction": -352.9900207519531
},
"fasttext": {
"dclm": 0.11053180694580078,
"english": 0.7530065178871155,
"fineweb_edu_approx": 2.0462770462036133,
"eai_general_math": 0.28258758783340454,
"eai_open_web_math": 0.2868078351020813,
"eai_web_code": 0.2728094458580017
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.822",
"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": "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
|
-2,617,074,744,065,249,300
|
Take the 2-minute tour ×
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free.
I want to perform an action when a user clicks on a div. However if he clicks on link within div, I want to send him directly to link. Now the href is being ignored.
<div id=myDiv>
some text
<a href="link1">my link</a>
some text
<a href="link2">my link</a>
some text
<a href="link3">my link</a>
<div>
$('.myDiv').live('click', function() {
console.log($(this));
// if clicked on link, the go directly to the link
....
// if clicked elsewhere on div, then perform another another action and return false
return false;
});
====== MY SOLUTION ====
I liked Rob's solution but the syntax was a bit vexing, so RTFM and came up with something similar that works for me.
$('.myDiv').live('click', function(event) {
var $target = $(event.target);
if( $target.is("a") ) {
return true;
}
else{
// do something else
return false;
}
});
share|improve this question
1
What happens if you return true;? – James Nov 6 '11 at 16:30
This works...performs the href after doing other stuff, but would prefer to go directly to link. – Mustapha George Nov 6 '11 at 16:32
2 Answers 2
up vote 1 down vote accepted
Check the event.target property. The code below does not execute return false when an anchor is clicked.
$('.myDiv').live('click', function(event) {
....
// `return false` only if element != <a>
if(!$.nodeName(event.target, "a")) return false;
});
share|improve this answer
1
Doesn't he want if($.nodeName(e.target, "a")) return true; where the .... is? – Hogan Nov 6 '11 at 16:32
@Hogan He wants to follow the link. return false prevents the link from being followed. I have modified his code so that return false will not occur when the current target is an anchor, which has the same effect as return true. – Rob W Nov 6 '11 at 16:33
So the default is to return true? I did not see that in your code. – Hogan Nov 6 '11 at 16:38
code was a bit ambiguous – Mustapha George Nov 6 '11 at 16:44
$.nodeName checks whether the given element (event.target = currently clicked element) is an <a> element ("a"). The ! before the statement negates the expression. So, if the current element is not an <a> element, the function returns false, effectively blocking click events. When a link is clicked, the function works. @Hogan Inside a click event handler return true is equivalent to just return. – Rob W Nov 6 '11 at 16:47
Call stopPropagation() when the links are clicked:
$('.myDiv').live('click', function(e) {
// Perform your action here
});
$('.myDiv a').live('click', function(e) {
e.stopPropagation();
});
share|improve this answer
Isn't this the reverse of what he wants -- this stops a link from working, he wants the link to work. – Hogan Nov 6 '11 at 16:39
@Hogan: Nope - stopPropagation() isn't preventDefault(). jsfiddle.net/8sfdQ (Hehe... the example doesn't work because of the cross-origin rule for iframes. Oops :P If you go to /show/ it does.) – minitech Nov 6 '11 at 16:43
nice -- thanks. – Hogan Nov 6 '11 at 16:58
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/8028448/jquery-click-event",
"source_domain": "stackoverflow.com",
"snapshot_id": "crawl=CC-MAIN-2015-32",
"warc_metadata": {
"Content-Length": "83547",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:HSF7W2YGM75OUCCGYXACBASXXLXQUI7P",
"WARC-Concurrent-To": "<urn:uuid:884ab8e1-942e-446e-86f6-41e0a5f9580f>",
"WARC-Date": "2015-08-02T16:33:28Z",
"WARC-IP-Address": "104.16.105.85",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:YHXBSI57AABJN6RORDGYYHMCE727HRQ3",
"WARC-Record-ID": "<urn:uuid:3610e47e-718d-422a-b54e-14a9793a867e>",
"WARC-Target-URI": "http://stackoverflow.com/questions/8028448/jquery-click-event",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:aa9116e1-0711-4783-9fd2-9b95bd52e5e6>"
},
"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,
131,
132,
298,
299,
314,
315,
328,
359,
360,
373,
404,
405,
418,
449,
455,
456,
457,
506,
536,
595,
608,
701,
723,
724,
733,
734,
758,
759,
877,
878,
931,
965,
992,
1009,
1015,
1025,
1052,
1072,
1078,
1083,
1111,
1115,
1177,
1182,
1317,
1318,
1330,
1331,
1360,
1361,
1466,
1467,
1511,
1520,
1565,
1618,
1619,
1624,
1650,
1654,
1760,
1765,
2022,
2027,
2122,
2127,
2190,
2195,
2621,
2622,
2673,
2674,
2714,
2746,
2750,
2751,
2793,
2818,
2822,
2848,
2853,
2983,
2988,
3213,
3218,
3262,
3263,
3275,
3276,
3278,
3286,
3287,
3365,
3366
],
"line_end_idx": [
25,
131,
132,
298,
299,
314,
315,
328,
359,
360,
373,
404,
405,
418,
449,
455,
456,
457,
506,
536,
595,
608,
701,
723,
724,
733,
734,
758,
759,
877,
878,
931,
965,
992,
1009,
1015,
1025,
1052,
1072,
1078,
1083,
1111,
1115,
1177,
1182,
1317,
1318,
1330,
1331,
1360,
1361,
1466,
1467,
1511,
1520,
1565,
1618,
1619,
1624,
1650,
1654,
1760,
1765,
2022,
2027,
2122,
2127,
2190,
2195,
2621,
2622,
2673,
2674,
2714,
2746,
2750,
2751,
2793,
2818,
2822,
2848,
2853,
2983,
2988,
3213,
3218,
3262,
3263,
3275,
3276,
3278,
3286,
3287,
3365,
3366,
3456
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3456,
"ccnet_original_nlines": 95,
"rps_doc_curly_bracket": 0.00405093003064394,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.29271358251571655,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.013819100335240364,
"rps_doc_frac_lines_end_with_ellipsis": 0.02083333022892475,
"rps_doc_frac_no_alph_words": 0.3429648280143738,
"rps_doc_frac_unique_words": 0.4382239282131195,
"rps_doc_mean_word_length": 4.561776161193848,
"rps_doc_num_sentences": 56,
"rps_doc_symbol_to_word_ratio": 0.006281409878283739,
"rps_doc_unigram_entropy": 4.955087184906006,
"rps_doc_word_count": 518,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.057553958147764206,
"rps_doc_frac_chars_dupe_6grams": 0.05416842922568321,
"rps_doc_frac_chars_dupe_7grams": 0.0304697398096323,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.016927629709243774,
"rps_doc_frac_chars_top_3gram": 0.02539145015180111,
"rps_doc_frac_chars_top_4gram": 0.033855270594358444,
"rps_doc_books_importance": -368.8647766113281,
"rps_doc_books_importance_length_correction": -368.8647766113281,
"rps_doc_openwebtext_importance": -176.5814208984375,
"rps_doc_openwebtext_importance_length_correction": -176.5814208984375,
"rps_doc_wikipedia_importance": -118.33171844482422,
"rps_doc_wikipedia_importance_length_correction": -118.33171844482422
},
"fasttext": {
"dclm": 0.12188547849655151,
"english": 0.7461251616477966,
"fineweb_edu_approx": 1.114313006401062,
"eai_general_math": 0.004591170232743025,
"eai_open_web_math": 0.10774236917495728,
"eai_web_code": 0.000012989999959245324
}
}
|
{
"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": "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": "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,075,973,983,333,907,000
|
ERROR LNK2019 and ERROR LNK1120 help
This is a discussion on ERROR LNK2019 and ERROR LNK1120 help within the C++ Programming forums, part of the General Programming Boards category; As you are probably aware, these are unresolved external errors. I have a program designed to perform mathematics using a ...
1. #1
Registered User
Join Date
Nov 2012
Posts
67
ERROR LNK2019 and ERROR LNK1120 help
As you are probably aware, these are unresolved external errors. I have a program designed to perform mathematics using a fraction class, and then will utilize a c++ version of the Euclidean algorithm to reduce the fraction to lowest terms by finding the GCD. The fraction.h file will be included below, as well as all of the functions and the function turning up the error.
The error in question says:
Code:
main.obj : error LNK2019: unresolved external symbol "public: int __thiscall fraction::getWholes(void)" (?getWholes@fraction@@QAEHXZ) referenced in function "void __cdecl addFractions(class fraction,class fraction,class fraction)" (?addFractions@@YAXVfraction@@00@Z)
1>C:\Users\Trey\documents\visual studio 2010\Projects\DS Program 2\Debug\DS Program 2.exe : fatal error LNK1120: 1 unresolved externals
Here is the .h file.
Code:
#pragma onceclass fraction
{
private:
int numerator;
int denominator;
int wholes;
public:
fraction(void);
~fraction(void);
int getNumerator();
void setNumerator(int x);
int getDenominator();
void setDenominator(int y);
int getWholes();
void setWholes(int z);
};
Here are the member functions.
Code:
fraction::fraction(void){
numerator = 0;
denominator = 0;
wholes = 0;
}
fraction::~fraction(void)
{
}
int fraction::getNumerator()
{
return numerator;
}
int fraction::getDenominator()
{
return denominator;
}
void fraction::setNumerator(int x)
{
numerator = x;
return;
}
void fraction::setDenominator(int y)
{
denominator = y;
return;
}
void fraction::setWholes(int z)
{
wholes = z;
return;
}
And last, here is the function turning up the error. I assume that this will carry over into the other functions, so I'll fix it then.
Code:
void addFractions(fraction a, fraction b, fraction c){
//initial output
cout << a.getNumerator() << "/" << a.getDenominator() << " + " << b.getNumerator() << "/" << b.getDenominator() << " = ";
//converts both fractions to like terms
int j = a.getDenominator();
int k = b.getDenominator();
a.setNumerator(a.getNumerator() * k);
a.setDenominator(a.getDenominator() * k);
b.setNumerator(b.getNumerator() * j);
b.setDenominator(b.getDenominator() * j);
//arithmetic
c.setNumerator(a.getNumerator() + b.getNumerator());
c.setDenominator(b.getDenominator());
//reduces to a proper fraction
if (c.getNumerator() >= c.getDenominator())
{
c.setNumerator(c.getNumerator()-c.getDenominator());
c.setWholes(c.getWholes() + 1);
}
//finds GCD
int r = euclid(c.getDenominator(), c.getNumerator());
//converts to lowest terms with gcd
c.setDenominator(c.getDenominator()/r);
c.setNumerator(c.getNumerator()/r);
//final output
if (c.getWholes() != 0)
cout << c.getWholes() << " " << c.getNumerator() << "/" << c.getDenominator() << "." << endl;
else if (c.getNumerator() == 0)
cout << c.getWholes() << "." << endl;
else
cout << c.getNumerator() << "/" << c.getDenominator() << "." << endl;
return;
}
2. #2
and the Hat of Guessing tabstop's Avatar
Join Date
Nov 2007
Posts
14,185
The clue is in the message: you never wrote getWholes.
Popular pages Recent additions subscribe to a feed
Similar Threads
1. Replies: 3
Last Post: 11-14-2012, 08:22 AM
2. Replies: 7
Last Post: 10-27-2012, 02:55 PM
3. LNK1120 error
By Shalmander in forum C++ Programming
Replies: 1
Last Post: 08-11-2010, 09:21 AM
4. LNK2019 and LNK1120 Errors?
By clegs in forum C++ Programming
Replies: 8
Last Post: 11-22-2007, 10:46 AM
5. error LNK1120 & LNK2001:
By hanhao in forum C++ Programming
Replies: 2
Last Post: 03-10-2004, 08:04 AM
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
{
"url": "http://cboard.cprogramming.com/cplusplus-programming/159817-error-lnk2019-error-lnk1120-help.html",
"source_domain": "cboard.cprogramming.com",
"snapshot_id": "crawl=CC-MAIN-2014-35",
"warc_metadata": {
"Content-Length": "46198",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:2JGTOGHLOUF7KX2Y5WBFNX4BQPUB6A5G",
"WARC-Concurrent-To": "<urn:uuid:e2a470c0-f25b-4506-9641-20b959fcca89>",
"WARC-Date": "2014-08-30T11:45:33Z",
"WARC-IP-Address": "76.74.254.184",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:MGWYJ3FHJA5SCGWKTCB76CE34MVKYKPG",
"WARC-Record-ID": "<urn:uuid:cb567b39-128b-4ba2-a9ee-f304f3d31739>",
"WARC-Target-URI": "http://cboard.cprogramming.com/cplusplus-programming/159817-error-lnk2019-error-lnk1120-help.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:6e177d8c-5eda-4a43-ae0c-6f0c8e4a64c2>"
},
"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,
37,
38,
309,
310,
318,
338,
352,
365,
375,
382,
383,
424,
425,
804,
805,
837,
847,
1118,
1258,
1283,
1293,
1324,
1330,
1343,
1366,
1391,
1411,
1423,
1447,
1472,
1500,
1534,
1564,
1600,
1625,
1656,
1663,
1698,
1708,
1738,
1761,
1786,
1806,
1812,
1817,
1822,
1827,
1832,
1862,
1868,
1874,
1879,
1884,
1917,
1923,
1949,
1955,
1960,
1965,
2000,
2006,
2034,
2040,
2045,
2050,
2089,
2095,
2118,
2134,
2140,
2145,
2150,
2191,
2197,
2222,
2238,
2244,
2249,
2254,
2290,
2296,
2316,
2332,
2338,
2477,
2487,
2546,
2571,
2701,
2706,
2711,
2759,
2795,
2831,
2877,
2927,
2973,
3023,
3028,
3033,
3054,
3115,
3161,
3166,
3171,
3210,
3262,
3272,
3337,
3381,
3391,
3396,
3401,
3421,
3483,
3488,
3493,
3537,
3585,
3629,
3634,
3639,
3662,
3694,
3800,
3840,
3890,
3903,
3985,
3990,
3995,
4011,
4017,
4018,
4026,
4071,
4085,
4098,
4108,
4119,
4178,
4179,
4230,
4231,
4247,
4248,
4264,
4300,
4316,
4352,
4371,
4414,
4429,
4465,
4498,
4536,
4551,
4587,
4617,
4656,
4671,
4707,
4708
],
"line_end_idx": [
37,
38,
309,
310,
318,
338,
352,
365,
375,
382,
383,
424,
425,
804,
805,
837,
847,
1118,
1258,
1283,
1293,
1324,
1330,
1343,
1366,
1391,
1411,
1423,
1447,
1472,
1500,
1534,
1564,
1600,
1625,
1656,
1663,
1698,
1708,
1738,
1761,
1786,
1806,
1812,
1817,
1822,
1827,
1832,
1862,
1868,
1874,
1879,
1884,
1917,
1923,
1949,
1955,
1960,
1965,
2000,
2006,
2034,
2040,
2045,
2050,
2089,
2095,
2118,
2134,
2140,
2145,
2150,
2191,
2197,
2222,
2238,
2244,
2249,
2254,
2290,
2296,
2316,
2332,
2338,
2477,
2487,
2546,
2571,
2701,
2706,
2711,
2759,
2795,
2831,
2877,
2927,
2973,
3023,
3028,
3033,
3054,
3115,
3161,
3166,
3171,
3210,
3262,
3272,
3337,
3381,
3391,
3396,
3401,
3421,
3483,
3488,
3493,
3537,
3585,
3629,
3634,
3639,
3662,
3694,
3800,
3840,
3890,
3903,
3985,
3990,
3995,
4011,
4017,
4018,
4026,
4071,
4085,
4098,
4108,
4119,
4178,
4179,
4230,
4231,
4247,
4248,
4264,
4300,
4316,
4352,
4371,
4414,
4429,
4465,
4498,
4536,
4551,
4587,
4617,
4656,
4671,
4707,
4708,
4761
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4761,
"ccnet_original_nlines": 163,
"rps_doc_curly_bracket": 0.004200799856334925,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.18308350443840027,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04175588861107826,
"rps_doc_frac_lines_end_with_ellipsis": 0.006097559817135334,
"rps_doc_frac_no_alph_words": 0.4486081302165985,
"rps_doc_frac_unique_words": 0.47708332538604736,
"rps_doc_mean_word_length": 5.9708333015441895,
"rps_doc_num_sentences": 69,
"rps_doc_symbol_to_word_ratio": 0.004282659851014614,
"rps_doc_unigram_entropy": 5.099485397338867,
"rps_doc_word_count": 480,
"rps_doc_frac_chars_dupe_10grams": 0.06978367269039154,
"rps_doc_frac_chars_dupe_5grams": 0.14898814260959625,
"rps_doc_frac_chars_dupe_6grams": 0.12177251279354095,
"rps_doc_frac_chars_dupe_7grams": 0.06978367269039154,
"rps_doc_frac_chars_dupe_8grams": 0.06978367269039154,
"rps_doc_frac_chars_dupe_9grams": 0.06978367269039154,
"rps_doc_frac_chars_top_2gram": 0.020935099571943283,
"rps_doc_frac_chars_top_3gram": 0.015701329335570335,
"rps_doc_frac_chars_top_4gram": 0.020935099571943283,
"rps_doc_books_importance": -423.4683532714844,
"rps_doc_books_importance_length_correction": -423.4683532714844,
"rps_doc_openwebtext_importance": -265.6338195800781,
"rps_doc_openwebtext_importance_length_correction": -265.6338195800781,
"rps_doc_wikipedia_importance": -216.6696319580078,
"rps_doc_wikipedia_importance_length_correction": -216.6696319580078
},
"fasttext": {
"dclm": 0.07433289289474487,
"english": 0.572058379650116,
"fineweb_edu_approx": 1.8323854207992554,
"eai_general_math": 0.5983363389968872,
"eai_open_web_math": 0.3944188356399536,
"eai_web_code": 0.03589797019958496
}
}
|
{
"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": "512.7",
"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": "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": "1",
"label": "Technically Flawed"
},
"secondary": {
"code": "2",
"label": "Partially Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-4,555,760,320,376,989,000
|
How much memory should I use in my Java program?
I am making a Java program. It involves making a image with size up to 9933 * 14043 pixels (which is A0 size and 300 ppi). The image is 24 bit, so it would take up about 400mb of space. The BufferedImage class some how take more RAM than the bitmap'...
more »
2017-08-13 18:08 (1) Answers
Mailgun send user specific html emails using Java
I have been playing around with mailgun, but there seems to be no way how I can send user specific email with html content. Meaning I dont want to send same email to every customer but with "Hi xyz user, ". I read and it says that I should use reci...
more »
2017-08-13 17:08 (0) Answers
When is a Java 8 Stream considered to be consumed?
My understanding was that a Java 8 Stream is considered to be consumed once a terminal operation, such as forEach() or count(), is performed. However, the test case multipleFilters_separate below throws an IllegalStateException even though filter i...
more »
2017-08-13 09:08 (2) Answers
spring data rest post sub-resource
I am using spring data rest and want to post a new resource and its sub-resource.Both of them are new resource so there is no link pointing to either of them.In fact,the following json is a reasonable json I think to post the new resource and its su...
more »
2017-08-13 09:08 (1) Answers
Jersey Service and Persistence Layers
I'm am developing a simple Question and Answer service (Jersey JAX-RS). With this service, I've come up with the following resource so far (might increase). GET|POST -------------/questions GET|PUT|DELETE -- /questions/{id} GET|POST ------------ /q...
more »
2017-08-13 08:08 (1) Answers
okhttpclient for android and Laravel API
Currently building an Android App that has a Web Service. Trying to get data from the SQL Database using the okhttp3 but I'm getting a weird response and I can't figure it out. My API in Laravel is: public function getAccount(Request $request, User ...
more »
2017-08-13 01:08 (1) Answers
Java base as Template parameter
I am semi Java literate and trying something in Groovy. Is the following possible in Groovy/Java: public class A { } public class B { } public class C<Ta extends A, Tb extends B> extends Ta { public Ta[] bArray; public Tb[] getAllBs() ...
more »
2017-08-12 20:08 (2) Answers
Generics vs. JavaFX
I fail to understand why there are certain ways my code doesn't work properly. This is the short but very dirty (who'd put a Stage into a TableView?) small sample code: package test; import javafx.application.Application; import javafx.scene.Scene;...
more »
2017-08-12 18:08 (0) Answers
Error creating bean with name 'validator'
I'm trying to create bean validation (I'm using tomcat server 7). When I added this piece of code @Bean public Validator validator() { return new org.springframework.validation.beanvalidation.LocalValidatorFactoryBean(); } I got the error org...
more »
2017-08-12 12:08 (2) Answers
|
{
"url": "http://howtodevelop.eu/tag/java,6842/page/1",
"source_domain": "howtodevelop.eu",
"snapshot_id": "crawl=CC-MAIN-2017-34",
"warc_metadata": {
"Content-Length": "92075",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:CFDSXWNWMLJ5M4UYP7HBYPV3Q6JYCCZL",
"WARC-Concurrent-To": "<urn:uuid:94c17324-177e-47f3-8f27-79982b238575>",
"WARC-Date": "2017-08-18T18:25:45Z",
"WARC-IP-Address": "87.98.239.17",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:T3YWCCP2G5W643XUALVZXGUMYJOEOBN4",
"WARC-Record-ID": "<urn:uuid:5d769b65-6cdb-4519-9f13-b29e1487ec0f>",
"WARC-Target-URI": "http://howtodevelop.eu/tag/java,6842/page/1",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:da37f9fd-c857-4377-b031-9216b7fbcddc>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-166-12-144.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-34\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for August 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,
49,
50,
303,
310,
311,
340,
341,
391,
392,
644,
651,
652,
681,
682,
733,
734,
986,
993,
994,
1023,
1024,
1059,
1060,
1313,
1320,
1321,
1350,
1351,
1389,
1390,
1642,
1649,
1650,
1679,
1680,
1721,
1722,
1975,
1982,
1983,
2012,
2013,
2045,
2046,
2285,
2292,
2293,
2322,
2323,
2343,
2344,
2596,
2603,
2604,
2633,
2634,
2676,
2677,
2923,
2930,
2931
],
"line_end_idx": [
49,
50,
303,
310,
311,
340,
341,
391,
392,
644,
651,
652,
681,
682,
733,
734,
986,
993,
994,
1023,
1024,
1059,
1060,
1313,
1320,
1321,
1350,
1351,
1389,
1390,
1642,
1649,
1650,
1679,
1680,
1721,
1722,
1975,
1982,
1983,
2012,
2013,
2045,
2046,
2285,
2292,
2293,
2322,
2323,
2343,
2344,
2596,
2603,
2604,
2633,
2634,
2676,
2677,
2923,
2930,
2931,
2959
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2959,
"ccnet_original_nlines": 61,
"rps_doc_curly_bracket": 0.0030415700748562813,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.28970587253570557,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.055882349610328674,
"rps_doc_frac_lines_end_with_ellipsis": 0.14516128599643707,
"rps_doc_frac_no_alph_words": 0.31911763548851013,
"rps_doc_frac_unique_words": 0.5147058963775635,
"rps_doc_mean_word_length": 4.697478771209717,
"rps_doc_num_sentences": 37,
"rps_doc_symbol_to_word_ratio": 0.013235289603471756,
"rps_doc_unigram_entropy": 5.146450042724609,
"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.020125219598412514,
"rps_doc_frac_chars_top_3gram": 0.03488371893763542,
"rps_doc_frac_chars_top_4gram": 0.010733449831604958,
"rps_doc_books_importance": -279.46356201171875,
"rps_doc_books_importance_length_correction": -279.46356201171875,
"rps_doc_openwebtext_importance": -124.01952362060547,
"rps_doc_openwebtext_importance_length_correction": -124.01952362060547,
"rps_doc_wikipedia_importance": -105.38931274414062,
"rps_doc_wikipedia_importance_length_correction": -105.38931274414062
},
"fasttext": {
"dclm": 0.04685854911804199,
"english": 0.8581153750419617,
"fineweb_edu_approx": 1.5980569124221802,
"eai_general_math": 0.07578588277101517,
"eai_open_web_math": 0.17309296131134033,
"eai_web_code": 0.17694133520126343
}
}
|
{
"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": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "1",
"label": "Truncated Snippets"
},
"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": "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
|
-2,929,094,415,302,571,500
|
sysio32.exe
Application using this process: Unknown
Recommended: Check your system for invalid registry entries.
sysio32.exe
Application using this process: Unknown
Recommended: Check your system for invalid registry entries.
sysio32.exe
Application using this process: Unknown
Recommended: Check your system for invalid registry entries.
What is sysio32.exe doing on my computer?
N/A Non-system processes like sysio32.exe originate from software you installed on your system. Since most applications store data in your system's registry, it is likely that over time your registry suffers fragmentation and accumulates invalid entries which can affect your PC's performance. It is recommended that you check your registry to identify slowdown issues.
sysio32.exe
In order to ensure your files and data are not lost, be sure to back up your files online. Using a cloud backup service will allow you to safely secure all your digital files. This will also enable you to access any of your files, at any time, on any device.
Is sysio32.exe harmful?
This process is considered safe. It is unlikely to pose any harm to your system.
sysio32.exe is a safe process
Can I stop or remove sysio32.exe?
Most non-system processes that are running can be stopped because they are not involved in running your operating system. Scan your system now to identify unused processes that are using up valuable resources. sysio32.exe is used by 'Unknown'.This is an application created by 'Unknown'. To stop sysio32.exe permanently uninstall 'Unknown' from your system. Uninstalling applications can leave invalid registry entries, accumulating over time.
Is sysio32.exe CPU intensive?
This process is not considered CPU intensive. However, running too many processes on your system may affect your PC’s performance. To reduce system overload, you can use the Microsoft System Configuration Utility to manually find and disable processes that launch upon start-up.
Why is sysio32.exe giving me errors?
Process related issues are usually related to problems encountered by the application that runs it. A safe way to stop these errors is to uninstall the application and run a system scan to automatically identify any PC issues.
Process Library is the unique and indispensable process listing database since 2004 Now counting 140,000 processes and 55,000 DLLs. Join and subscribe now!
Toolbox
ProcessQuicklink
|
{
"url": "http://www.processlibrary.com/en/directory/files/sysio32/23508/",
"source_domain": "www.processlibrary.com",
"snapshot_id": "crawl=CC-MAIN-2018-17",
"warc_metadata": {
"Content-Length": "31610",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:3T5XR3RJQ7FLXGVL3GODL47MX57TM5QF",
"WARC-Concurrent-To": "<urn:uuid:90782fc0-2283-494c-94b2-b970d67f3fb0>",
"WARC-Date": "2018-04-25T05:02:50Z",
"WARC-IP-Address": "54.247.105.247",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:IWOSMRZNV6YGFTWOO6ZE4ONGMIM5V2FM",
"WARC-Record-ID": "<urn:uuid:4f95ad1b-11d7-43b7-86f2-f72ef3857e05>",
"WARC-Target-URI": "http://www.processlibrary.com/en/directory/files/sysio32/23508/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:104c30c2-aa27-4ec7-aa00-8954d1556dd3>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-186-217-96.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,
12,
13,
53,
54,
115,
116,
128,
129,
169,
170,
231,
232,
244,
245,
246,
247,
248,
288,
289,
350,
351,
393,
394,
764,
776,
777,
1036,
1037,
1061,
1062,
1143,
1173,
1174,
1208,
1209,
1653,
1654,
1684,
1685,
1964,
1965,
2002,
2003,
2230,
2231,
2232,
2233,
2234,
2235,
2236,
2237,
2393,
2394,
2402,
2403
],
"line_end_idx": [
12,
13,
53,
54,
115,
116,
128,
129,
169,
170,
231,
232,
244,
245,
246,
247,
248,
288,
289,
350,
351,
393,
394,
764,
776,
777,
1036,
1037,
1061,
1062,
1143,
1173,
1174,
1208,
1209,
1653,
1654,
1684,
1685,
1964,
1965,
2002,
2003,
2230,
2231,
2232,
2233,
2234,
2235,
2236,
2237,
2393,
2394,
2402,
2403,
2419
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2419,
"ccnet_original_nlines": 55,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3333333432674408,
"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.16114790737628937,
"rps_doc_frac_unique_words": 0.4447513818740845,
"rps_doc_mean_word_length": 5.408839702606201,
"rps_doc_num_sentences": 43,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.652514457702637,
"rps_doc_word_count": 362,
"rps_doc_frac_chars_dupe_10grams": 0.14555668830871582,
"rps_doc_frac_chars_dupe_5grams": 0.14555668830871582,
"rps_doc_frac_chars_dupe_6grams": 0.14555668830871582,
"rps_doc_frac_chars_dupe_7grams": 0.14555668830871582,
"rps_doc_frac_chars_dupe_8grams": 0.14555668830871582,
"rps_doc_frac_chars_dupe_9grams": 0.14555668830871582,
"rps_doc_frac_chars_top_2gram": 0.04085801914334297,
"rps_doc_frac_chars_top_3gram": 0.04494382068514824,
"rps_doc_frac_chars_top_4gram": 0.04596526920795441,
"rps_doc_books_importance": -211.28526306152344,
"rps_doc_books_importance_length_correction": -211.28526306152344,
"rps_doc_openwebtext_importance": -125.59745025634766,
"rps_doc_openwebtext_importance_length_correction": -125.59745025634766,
"rps_doc_wikipedia_importance": -84.99781799316406,
"rps_doc_wikipedia_importance_length_correction": -84.99781799316406
},
"fasttext": {
"dclm": 0.0473591685295105,
"english": 0.9060214161872864,
"fineweb_edu_approx": 1.9109137058258057,
"eai_general_math": 0.029072230681777,
"eai_open_web_math": 0.07822691649198532,
"eai_web_code": 0.013769869692623615
}
}
|
{
"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": "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": "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": "10",
"label": "Knowledge Article"
},
"secondary": {
"code": "9",
"label": "FAQ"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No 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
|
-589,941,435,528,945,400
|
| Simple reasoning about the calendar and appointments, in a single time zone there is a time block starting some-start1 and ending some-fin1 there is a time block starting some-start2 and ending some-fin2 that-start1 is less than that-fin2 that-start2 is less than that-fin1 --------------------------------------------------------------------------------------------- the time block that-start1 to that-fin1 overlaps with the time block that-start2 to that-fin2 on some-year some-month some-day some-day-name from some-start1 to some-fin1 is scheduled for some-item the time block some-start to some-fin overlaps with the time block that-start1 to that-fin1 ------------------------------------------------------------------------------------------------------------------ on that-year that-month that-day that-day-name there is a scheduled item that overlaps with that-start to that-fin some-day-of-month is a possible day of a month day number some-day-number in some-year is the that-day-of-month day of month some-month there is a time block starting some-time1 and ending some-time2 in that-year day number that-day-number is some-day-name add : on that-year that-month that-day-of-month that-day-name from that-time1 to that-time2 is scheduled for some-item -------------------------------------------------------------------------------------------------------------------- schedule that-item for that-year that-month that-day-of-month that-day-name from that-time1 to that-time2 there is a half hour time block starting some-time1 and ending some-time there is a half hour time block starting that-time and ending some-time2 that-time1 is less than that-time2 --------------------------------------------------------------- there is a time block starting that-time1 and ending that-time2 on this-year this-month this-day this-day-name from this-start1 to this-fin1 is scheduled for this-item ============================================================================================================================== 2004 1 1 Thursday 700 800 Business Meeting 2004 3 11 Thursday 900 1000 Finance Review some-year is a year under consideration not : that-year is divisible by 4 some-mo-number some-month normally has some-number days -------------------------------------------------------------- in the year that-year month that-mo-number has that-number days some-year is a year under consideration that-year is divisible by 4 ------------------------------------------ in the year that-year month 2 has 29 days some-year is a year under consideration that-year is divisible by 4 some-mo-number some-month normally has some-number days not : that-month is equal February --------------------------------------------------------------- in the year that-year month that-mo-number has that-number days some-year is a year under consideration that-year is divisible by 4 ------------------------------------------ the year that-year has altogether 366 days some-year is a year under consideration not : that-year is divisible by 4 ------------------------------------------ the year that-year has altogether 365 days some-year is a year under consideration some-mo-number is a month number that-mo-number is less than or equal some-mo-number1 in the year that-year month that-mo-number has some-number days -------------------------------------------------------------------------------------- in the year that-year month that-mo-number at most that-mo-number1 has that-number days some-year is a year under consideration some-mo-number1 is a month number sum a-number : in the year that-year month that-mo-number at most that-mo-number1 has some-number days = a-total ------------------------------------------------------------------------------------------------------------------ in the year that-year the months up to that-mo-number1 have that-total days some-day-number is a possible day number in a year in the year some-year the months up to some-mo-number0 have some-total days that-day-number - that-total = some-number that-number is greater than 0 that-mo-number0 is less than 12 that-mo-number0 + 1 = some-mo-number in the year that-year month that-mo-number has some-number1 days that-number is less than or equal that-number1 ----------------------------------------------------------------------------------------- day number that-day-number in that-year is the that-number day of month that-mo-number some-day-number is a possible day number in a year in the year some-year month 1 has some-number1 days that-day-number is less than or equal that-number1 -------------------------------------------------------------------------------- day number that-day-number in that-year is the that-day-number day of month 1 the day of the week of the first day in some-year is some-day1-name the year that-year has altogether some-total days some-day-number is a possible day number in a year that-day-number is less than or equal that-total some-number1 that-day1-name is a day of the week that-day-number + that-number1 = some-number2 that-number2 - 2 = some-number3 that-number3 divided by 7 = a-quotient remainder some-remainder that-remainder + 1 = some-number4 that-number4 some-day-name is a day of the week ---------------------------------------------------------------- in that-year day number that-day-number is that-day-name some-year divided by 4 = a-number remainder 0 --------------------------------------------- that-year is divisible by 4 the day of the week of the first day in this-year is this-day ============================================================= 2004 Thursday 2005 Saturday there is a half hour time block starting this-time1 and ending this-time2 ========================================================================= 600 630 630 700 700 730 730 800 800 830 830 900 900 930 930 1000 1000 1030 1030 1100 1100 1130 1130 1200 1200 1230 1230 1300 1300 1330 1330 1400 1400 1430 1430 1500 1500 1530 1530 1600 1600 1630 1630 1700 1700 1730 1730 1800 1800 1830 1830 1900 this-number is a possible day number in a year ============================================== 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 some-mo-number some-month normally has some-number days ------------------------------------------------------- that-mo-number is a month number this-mo-number this-month normally has this-number days ======================================================= 1 January 31 2 February 28 3 March 31 4 April 30 5 May 31 6 June 30 7 July 31 8 August 31 9 September 30 10 October 31 11 November 30 12 December 31 this-number this-day is a day of the week ======================================== 1 Monday 2 Tuesday 3 Wednesday 4 Thursday 5 Friday 6 Saturday 7 Sunday this-year is a year under consideration ======================================= 2004 2005 this-number is a possible day of a month ======================================== 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | This file is an application written in the language Executable English. | You can view, run and change it by pointing a browser | to www.reengineeringllc.com and selecting Calendar1.
|
{
"url": "http://www.reengineeringllc.com/demo_agents/Calendar1.agent",
"source_domain": "www.reengineeringllc.com",
"snapshot_id": "crawl=CC-MAIN-2014-52",
"warc_metadata": {
"Content-Length": "11107",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:33IOI272MT6XAI7EAMMXMDSUGXFR7NVJ",
"WARC-Concurrent-To": "<urn:uuid:9aee72f7-5b76-4ca1-8e83-16c6057ac87a>",
"WARC-Date": "2014-12-22T22:40:06Z",
"WARC-IP-Address": "209.222.52.45",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:JFNS4GP3WU5V6X7AGIDLW3QFU2GJFGDU",
"WARC-Record-ID": "<urn:uuid:0900681f-38fa-4ec4-b416-925dc86bc972>",
"WARC-Target-URI": "http://www.reengineeringllc.com/demo_agents/Calendar1.agent",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:f1617266-9af2-43c0-a270-e5b629f739c0>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-231-17-201.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-52\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for December 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
],
"line_end_idx": [
8468
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 8468,
"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.2781267762184143,
"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.46087950468063354,
"rps_doc_frac_unique_words": 0.4658436179161072,
"rps_doc_mean_word_length": 4.353086471557617,
"rps_doc_num_sentences": 4,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.690343856811523,
"rps_doc_word_count": 1215,
"rps_doc_frac_chars_dupe_10grams": 0.20892417430877686,
"rps_doc_frac_chars_dupe_5grams": 0.4074494242668152,
"rps_doc_frac_chars_dupe_6grams": 0.37946683168411255,
"rps_doc_frac_chars_dupe_7grams": 0.2993004322052002,
"rps_doc_frac_chars_dupe_8grams": 0.26980525255203247,
"rps_doc_frac_chars_dupe_9grams": 0.2210247665643692,
"rps_doc_frac_chars_top_2gram": 0.015882020816206932,
"rps_doc_frac_chars_top_3gram": 0.031196819618344307,
"rps_doc_frac_chars_top_4gram": 0.018150879070162773,
"rps_doc_books_importance": -580.2318725585938,
"rps_doc_books_importance_length_correction": -580.2318725585938,
"rps_doc_openwebtext_importance": -221.82586669921875,
"rps_doc_openwebtext_importance_length_correction": -221.82586669921875,
"rps_doc_wikipedia_importance": -89.55079650878906,
"rps_doc_wikipedia_importance_length_correction": -89.55079650878906
},
"fasttext": {
"dclm": 0.19154024124145508,
"english": 0.8034030795097351,
"fineweb_edu_approx": 1.286965012550354,
"eai_general_math": 0.17622756958007812,
"eai_open_web_math": 0.09473174810409546,
"eai_web_code": 0.04895108938217163
}
}
|
{
"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.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": "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": "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
|
-4,907,786,039,544,266,000
|
This is a rough outline of my verbal remarks while giving a presentation at the Software Industry Conference. Regular readers of my blog will notice it has a lot of overlap with previous posts on the topic, but I thought posting it would save presentation watchers from having to take copious notes on URLs and expand the reach of the presentation to people who couldn’t attend this year.
Brief Biography
My name is Patrick McKenzie. For the last six years I was working in Japan, primarily as a software engineer. In the interim, I started a small software company in my spare time, at about five hours a week, which recently allowed me to quit my day job. Roughly half my sales and three quarters of my profits come as a result of organic SEO, and the majority of the remainder come from AdWords. If you need to know about AdWords, talk to Dave Collins, who is also attending. This presentation is about fairly advanced tactics — if you need beginner-friendly SEO advice, I recommend reading SEOMoz’s blog or taking a look at SEOBook.
Bingo Card Creator makes bingo cards for elementary schoolteachers. This lets them, for example, teach a unit on chemistry and then, as a fun review game, call out the names of compounds like “ozone” and have students search out the chemical symbols on their bingo cards. Students enjoy the game because it is more fun than drilling. Teachers enjoy the game because it scales to any number of students and slides easily into the schedule. However, making the cards by hand is a bit of a pain, so they go searching on the Internet for cards which already exist and find my website. I try to sell them a program which automates card creation.
SEO can be a powerful tool for finding more prospects for your business and increasing sales.
SEO In A Nutshell
People treat SEO like it is black magic, but at the core it is very simple: Content + Links = You Win.
Content: Fundamentally, users searching are looking for keywords, and Google wants to send searchers to content which is responsive to the intent of the searcher. Overwhelmingly, this means to content directly responsive to the keywords. This is particularly true on the long tail, meaning queries which are not near the top of the query frequency distribution. Many more people search for “credit cards” than for “How do I make a blueberry pie?”
For the most popular queries, the page that ranks will likely not be laser-targeted on “credit cards”. However, for the long tail, a page that is laser-targeted will tend to win if it exists. The reason is that Google thinks that your wording carries subtle clues of your intent, so it should generally be respected. Someone looking for “How to make a blueberry pie?” isn’t necessarily as sophisticated a cook as someone who searches for “blueberry pie recipe” — they might not even be looking with the intention of making a blueberry pie, but rather out of curiosity as to how it is made, and so a recipe does not directly answer their intent.
Links: With billions of pages on the Internet, there needs to be a way to sift the wheat from the chaff and determine who wins out of multiple close pages. The strongest signal for this is how trusted a site and how trusted a page is, and this is overwhelmingly measured by links. A link from a trusted page to another page says “I trust this other page”, and the aggregate graph shows you which pages are most trusted on the Internet. Note that trust is used as a proxy for quality because it is almost impossible to measure quality directly.
It is important to mention that links to one bit of content on your site help all other content — perhaps not as much as the linked content, but still substantially. Wikipedia’s article on dolphins doesn’t necessarily have thousands of links pointing to it, but over their millions of articles like the History of the Ottoman empire, they have accumulated trust sufficient that a new page on wiki is assumed to be much better than a new page on a hobbyist’s blog. Note that because Wiki ranks for nearly everything they tend to accumulate new citations when people are looking for someone to cite. This causes a virtuous cycle (for Wiki, anyway): winners win. You’ll see this over and over in SEO.
Despite this equation looking additive, SEO very rarely shows linear benefits. Benefits compound multiplicatively or exponentially. Sadly, many companies try to develop their SEO in a linear fashion: writing all content by hand, searching out links one at a time, etc. We’ll present a few techniques to do it more efficiently.
The Biggest Single Problem
The biggest single problem with software company’s SEO is that they treat their website like a second class citizen. The product gets total focus from a team of talented engineers for a year, and then the website is whipped up at 2 AM in the morning on release day and never touched again. You have to treat your website like it was a shipping **software product of your company**.
It needs:
• testing
• design
• strategic thought into feature set
• continuous improvement
• for loops
“For loops?” Yes, for loops. You’d never do calculations by counting on your fingers when you have a computer available to do them for you. Hand-writing all content in Notepad is essentially the same. Content should be separated from presentation — via templates & etc — so that you can reuse both the content and presentational elements. Code reuse: not just for software.
Scalable Content Generation
Does anyone have a thought about how large a website’s optimal size should be? 10 pages? A hundred pages? No, in the current environment, the best size for a website is “as large as it possibly can be”, because of how this helps you exploit the long tail. As long as you have a well-designed site architecture and sufficient trust, every marginal topic you cover on your website generates marginal traffic. And if you can outsource or automate this such that the marginal cost of creating a piece of content is less than the marginal revenue received from it, it makes sense to blow your website up.
This is especially powerful if you can make creation of content purely a “Pay money and it happens” endeavor, which lets you treat SEO like a channel like PPC: pour in money, watch sales, laugh all the way to the bank. The difference is that you get to keep your SEO gains forever rather than having to rebuy them on every click like PPC. This is extraordinarily powerful if you do it right. Here’s how:
Use a CMS
The first thing you need to enable scalable content generation is a CMS. People need to be able to create additional content for the website without hand-editing it. WordPress is an excellent first choice, but you can get very, very creative with custom CMSes for content types which are specific to your business if you have web development expertise.
Note that “content” isn’t necessarily just blog posts. It is anything your customers perceive value out of, anything which solves problems for them. That could be digitizing your documentation, or answering common questions in your niche (“How do I…” is a very common query pattern), or taking large complex data sets and explaining their elements individually in a comprehensible fashion. Also note that it isn’t strictly text: you can do images and even video in a scalable fashion these days.
For example, using Flickr Creative Commons search, you can tap millions of talented photographers for free to get photos, so illustrating thousands of pages is as simple as searching, copying, and crediting the photographer. You can use GraphicsMagick or ImageMagick to create or annotate images algorithmically. You can use graphing libraries to create beautiful graphs from boring CSV files — more on that later.
The reasons why you’d use a CMS are they make content easy to create and edit, so you’ll do more of it. Additionally, by eliminating the dependency on the webmaster, you can have non-technical employees or freelancers create content for you. This is key to achieving scale. You can also automate on-page SEO optimization — proper title tags, interlinking, etc — so that content creators don’t have to worry about this themselves.
Outsource Writing
You are expensive. English majors are cheap. Especially in the current down economy, stay at home moms, young graduates, the recently unemployed, and many other very talented folks are willing to write for cheap, particularly from home. This lets you push the marginal cost of creating a new page to $10 ~ $15 or lower. As long as you can monetize that page at a multiple of that, you’ll do very well for yourself. Demand Media is absolutely killing it with this model.
Finding and managing writers is difficult. If you use freelancers and find good ones, hold onto them for dear life, since training and management are your main costs. Standardize instructions to freelancers and find folks who you can rely on to exercise independent thinking.
You can also get content created as a service, using TextBroker. Think of the content on your website as a pyramid: you have a few pages handwritten by domain experts with quality off the chart, and then a base of the pyramid which is acceptable but perhaps not awe-inspiring. At the 4 star quality level, you can get content in virtually infinite quantity at 2.2 cents per word. You can either have someone copy/paste this into your website or do a bit of work with their API and automate the whole process.
You can use software to increase the quality of outsourced content. For example, putting a picture on it automatically makes it better. You can automate that process so your editors can quickly do it for all pages. You can remix common page elements — calls to action, etc — which are polished to a mirror shine with the outsourced content. You can also mix content from multiple sources to multiply its effectiveness: if you have 3 user segments and 3 features they really value, that might be 9 pages. (If you use 2 features per page, that is 18. As you can see, the math is gets very compelling very quickly.)
Milk It
Now that you’re set up to do content at scale, you can focus on doing it well. The best content is:
Modular: You can use it in multiple places on the website. You paid good money for it. If you can use it in two places, the cost just declined by half.
Evergreen: The best possible value for an expiration date is “never”. Chasing the news means your content gets stale and stops providing value for the business. Answering the common, recurring, eternal problems and aspirations of your market segment means content written this year will never go out of style. That lets you treat content as durable capital. Also, because it tends to pick up links over time, it will get increasing traffic over time.
The first piece of content I made for my website took me two hours to write. It made $100 the first month. Not bad, but why only get paid once? It has gone on to make me thousands over the years, and it will never go out of style.
Competitively Defensible: One of the tough things about blog posts is that any idiot can get a blog up as easily as you can. Ideally, you want to focus on content which other people can’t conveniently duplicate. OKCupid’s blog posts about dating data are a superb example of this: they use data that only they have, and they’ve made themselves synonymous with the category. No wonder they’re in the top 3 for “online dating”. Proprietary data, technical processes which are hard to duplicate, and other similar barriers establish a moat around your SEO advantage.
Process-oriented: If something works, you want to be able to exploit it in a repeatable fashion. Novelty is an excellent motivational factor and you can’t lose it, but novelty that can be repeated is a wonderful thing to have. You also want to have a defined step where you see what worked and what didn’t, so that you can improve your efforts as you go on.
Tracking:
Track what works! Do more of that! Install Google Analytics or similar to see what keywords people are reaching for on your site. Keywords (or AdWords data) are great sources of future improvements. Track conversions based on landing page, and create more content based on the content which is really winning. If content should be winning but isn’t, figure out why for later iterations — maybe it needs more external or internal promotion, a different slant, a different target market, etc.
Case Study
Getting into the heads of my teachers for a moment — a key step — most teachers have a lesson planned out and need an activity to slot into it. For example, they know they have a lesson about the American Revolution coming up. Some of them, who already like bingo, are going to look for American Revolution bingo cards. If my site ranked for that, that would be an opportunity to tell them that they could use software to create not just American Revolution activities but bingo for any lesson if they just bought my software.
So I made a CMS which, given a list of words and some explanatory text, would create a downloadable set of 8 bingo cards (great for parents, less great for teachers) on that topic, make a page to pitch that download in, and put an ad for Bingo Card Creator on the page. Note how I’m using this content to upsell the user into more of a relationship with me: signing up for a trial, giving me their email address, maybe eventually buying the software.
I have a teacher in New Mexico who produces the words and descriptions for me. The pages end up looking like this for the American Revolution. She produces 30 activities a month for $100, and I approve them and they go live instantly. This has been going on for a few years. In the last year, I’ve started doing end-to-end conversion tracking, so I can attribute sales directly to the initial activity people started with.
This really works. Some of the activities, like Summer bingo cards or Baby Shower Bingo cards, have resulted in thousands of dollars in sales in the last year. $3.50 in investment, thousands in returns. And there is a long tail of results:
This graph shows the 132 of the 900 activities which generated a sale in the last year. You can see that there is a long tail which each generated one sale — in fact, a hundred of them. Sure, you might not think that Famous Volcano bingo cards would be that popular, but I’ll pay $3.50 to get a $30 sale as often as the opportunity is offered. These will also continue producing value in the next years, as they already have over the last several years: note that roughly half of these which produced a sale in the last 12 months were written in 2007 or 2008.
This took only a week or two to code up, and now 5 minutes a month sending my check and a thank-you note to the freelancer. I’ve paid her about $3,000 over the last few years to write content. In the last year alone, it has generated well over $20,000 in sales. If you do things this efficiently, SEO becomes a channel like PPC — put in a quarter, get out a dollar, redeploy the profits to increase growth.
Any software company can create content like this, with a bit of strategic thinking, some engineering deployed, and outsourced content creation. Try it — you can do an experiment for just a few hundred dollars. If it works, invest more. (Aaron Wall says that one of the big problems is that people do not exploit things that work. If you’ve got it, flaunt it — until it stops working.)
Linkbait
Linkbait is creating content intended to solicit links to your website. This can be by exploiting the psychology of users — they show things to friends because they agree with them strongly, or they hate them. They create links because it creates value for them, not value for you — it increases their social status, it flatters their view of the world, it solves their problems.
All people are not equal on the Internet: twenty-something technologists in San Fransisco create hundreds of times more links per year than retired teachers in Florida. All else being equal, it makes sense to create more of your linkbait targeted at heavy linking groups. They’ve been labeled the Linkerati by SEOMoz, and I recommend the entire series of posts on them highly.
Software developers have some unique, effective ways to create linkbait. For example:
Open Source Software
OSS developers and users are generally in very link-rich demographics. OSS which solves problems for businesses tends to pick up links from, e.g., consultants deploying it — they will cite your website to justify their billing rate. That is a huge win for you. There are also numerous blogs which cover practically everything which happens in OSS.
OSS is fairly difficult to duplicate as linkbait, because software development is hard. (Don’t worry about people copying it — you’ll be the canonical source, and the canonical source for OSS tends to win the citation link. Make sure that is on your site rather than on Github, etc.)
OSS in new fields in software — for example, Rails development the last few years — has landgrab economics. The first semi-decent OSS in a particular category tends to win a lot of the links and mindshare. So get cracking! And keep your eyes open for new opportunities, particularly for bits of infrastructural code which you were going to write for your business needs anyhow.
Case Study: A/Bingo
I’m extraordinarily interested in A/B testing, and wanted to do more of it on my site. At the time, there was no good A/B testing option for Rails developers. So I wrote one. It went on to become one of the major options for A/B testing in Rails, and was covered on the official Rails blog, Ajaxian, and many other fairly authoritative places on the Internet. It is probably the most effective source of links per unit effort I’ve ever had.
Some tactical notes:
• Put it on your website. You did the work, get the credit for it.
• Invest in a logo — you can get them done very cheaply at 99designs. Pretty things are trusted more.
• Spend time “selling” the OSS software. Documentation, presentation of benefits, etc.
• OSS doesn’t have to be a huge project like Apache. You can do projects in 1 day or 1 week which people will happily use. (Remember, pick things which solve problems.)
Conclusion
I’m always willing to speak to people about this. Feel free to email me (patrick@ this domain).
|
{
"url": "https://kalzumeus.com/2010/07/17/seo-for-software-companies/",
"source_domain": "kalzumeus.com",
"snapshot_id": "crawl=CC-MAIN-2021-39",
"warc_metadata": {
"Content-Length": "30435",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VRELSDZ233YUBKJCL74RBWG54QVLEHFU",
"WARC-Concurrent-To": "<urn:uuid:914c393a-acdc-4a1b-bc17-9e210e4300d5>",
"WARC-Date": "2021-09-26T09:03:58Z",
"WARC-IP-Address": "34.195.86.8",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:TYUSX62FYQZ5454JD6EF66PK6QUB5XZQ",
"WARC-Record-ID": "<urn:uuid:73c1b899-be41-4201-a60b-8b392070da6e>",
"WARC-Target-URI": "https://kalzumeus.com/2010/07/17/seo-for-software-companies/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:73459d0a-c21f-4b2a-8d29-da8e3b775dbf>"
},
"warc_info": "isPartOf: CC-MAIN-2021-39\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for September 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-28\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,
390,
391,
407,
408,
1044,
1045,
1691,
1692,
1786,
1787,
1805,
1806,
1909,
1910,
2360,
2361,
3009,
3010,
3557,
3558,
4260,
4261,
4591,
4592,
4619,
4620,
5004,
5005,
5015,
5016,
5028,
5039,
5078,
5105,
5119,
5120,
5499,
5500,
5528,
5529,
6134,
6135,
6542,
6543,
6553,
6554,
6909,
6910,
7409,
7410,
7827,
7828,
8261,
8262,
8280,
8281,
8756,
8757,
9035,
9036,
9548,
9549,
10168,
10169,
10177,
10178,
10279,
10280,
10434,
10435,
10890,
10891,
11125,
11126,
11694,
11695,
12055,
12056,
12066,
12067,
12563,
12564,
12575,
12576,
13106,
13107,
13559,
13560,
13987,
13988,
14231,
14232,
14795,
14796,
15206,
15207,
15597,
15598,
15607,
15608,
15990,
15991,
16370,
16371,
16458,
16459,
16480,
16481,
16832,
16833,
17119,
17120,
17501,
17502,
17522,
17523,
17968,
17969,
17990,
17991,
18061,
18166,
18256,
18429,
18430,
18441,
18442
],
"line_end_idx": [
390,
391,
407,
408,
1044,
1045,
1691,
1692,
1786,
1787,
1805,
1806,
1909,
1910,
2360,
2361,
3009,
3010,
3557,
3558,
4260,
4261,
4591,
4592,
4619,
4620,
5004,
5005,
5015,
5016,
5028,
5039,
5078,
5105,
5119,
5120,
5499,
5500,
5528,
5529,
6134,
6135,
6542,
6543,
6553,
6554,
6909,
6910,
7409,
7410,
7827,
7828,
8261,
8262,
8280,
8281,
8756,
8757,
9035,
9036,
9548,
9549,
10168,
10169,
10177,
10178,
10279,
10280,
10434,
10435,
10890,
10891,
11125,
11126,
11694,
11695,
12055,
12056,
12066,
12067,
12563,
12564,
12575,
12576,
13106,
13107,
13559,
13560,
13987,
13988,
14231,
14232,
14795,
14796,
15206,
15207,
15597,
15598,
15607,
15608,
15990,
15991,
16370,
16371,
16458,
16459,
16480,
16481,
16832,
16833,
17119,
17120,
17501,
17502,
17522,
17523,
17968,
17969,
17990,
17991,
18061,
18166,
18256,
18429,
18430,
18441,
18442,
18538
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 18538,
"ccnet_original_nlines": 127,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.45030641555786133,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01731947995722294,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.14255261421203613,
"rps_doc_frac_unique_words": 0.31521737575531006,
"rps_doc_mean_word_length": 4.560558795928955,
"rps_doc_num_sentences": 183,
"rps_doc_symbol_to_word_ratio": 0.0002664499916136265,
"rps_doc_unigram_entropy": 5.916390419006348,
"rps_doc_word_count": 3220,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.01756894960999489,
"rps_doc_frac_chars_dupe_6grams": 0.0064010899513959885,
"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.011848829686641693,
"rps_doc_frac_chars_top_3gram": 0.004426289815455675,
"rps_doc_frac_chars_top_4gram": 0.003541029989719391,
"rps_doc_books_importance": -1836.0635986328125,
"rps_doc_books_importance_length_correction": -1836.0635986328125,
"rps_doc_openwebtext_importance": -1136.0328369140625,
"rps_doc_openwebtext_importance_length_correction": -1136.0328369140625,
"rps_doc_wikipedia_importance": -687.0443725585938,
"rps_doc_wikipedia_importance_length_correction": -687.0443725585938
},
"fasttext": {
"dclm": 0.05036813020706177,
"english": 0.9468978047370911,
"fineweb_edu_approx": 1.5390517711639404,
"eai_general_math": 0.16600841283798218,
"eai_open_web_math": 0.13854742050170898,
"eai_web_code": 0.04171359911561012
}
}
|
{
"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": "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": "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": "-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": "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
|
6,628,187,056,202,093,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 am trying to launch a cannonball from a cannon and have it follow a realistic path. The angle of fire changes depending on the orientation of the cannon (automatically orientates to mouse pointer). So what I'm trying to figure out, is how to move a cannonball along a parabolic path, when given an angle, and a set velocity.
I've read that this can be done without complicated trigonometry (never listened to it in highschool), and can be calculated simply by adding gravity to the yVelocity every tick. However, at this moment, I don't know how to calculate the initial yVelocity (again, depending on cannon orientation).
You can see the current animation here: http://kate.ict.op.ac.nz/~welfajw1/portfolio/videos/task3-assignment2.swf
This is all done in AS3, and the code I have is as follows:
Main timeline code:
import flash.display.*;
import flash.events.*;
import flash.geom.*;
var cannonball:ball_mc;
var angleDegree;
myCannon.addEventListener(Event.ENTER_FRAME, cannonEnterFrame);
function cannonEnterFrame(pEvt)
{
var mc = myCannon;
var mg = myCannon.myGun;
//find angle for orientation
var angleRadian = Math.atan2(mouseY - mc.y, mouseX - mc.x);
//convert to degrees
angleDegree = angleRadian * 180 / Math.PI;
//limit rotation
if(angleDegree > -63 && angleDegree < 20)
mg.rotation = angleDegree;
}
stage.addEventListener(Event.ENTER_FRAME, stageRefresh);
function stageRefresh(pEvt)
{
if (cannonball)
{
//move every "tick"
cannonball.move();
}
}
stage.addEventListener(MouseEvent.CLICK, mouseClicked);
function mouseClicked(pEvt)
{
//starting position of the ball
cannonball = new ball_mc(100, 475);
//SEND IN INITIAL x, y VELOCITIES
cannonball.fire(20, angleDegree);
//add to stage
stage.addChild(cannonball);
}
ball_mc code:
package
{
import flash.display.MovieClip;
import flash.sensors.Accelerometer;
import flashx.textLayout.formats.Float;
public class ball_mc extends MovieClip
{
//constant gravity
public static const g:Number = 2;
//starting velocities
private var ux:Number;
private var uy:Number;
public function ball_mc(startX:int, startY:int)
{
x = startX;
y = startY;
}
public function fire(vx:Number, vy:Number):void
{
ux = vx;
uy = vy;
}
public function move():void
{
//distance moved in x dir
var sx:Number = ux;
//new velocity in y dir
var vy:Number = uy + g;
//distance moved in y dir
var sy:Number = uy + g/2;
//apply movement
x += sx;
y += sy;
//save new y velocity
uy = vy;
}
}
}
share|improve this question
1 Answer 1
up vote 4 down vote accepted
You need a little bit of physics.
Initial speed must be calculated by using some criteria that you add on your own. One example is to calculate initial speed by using the distance between the mouse and the cannon, at the time the mouse is pressed. If the distance is greater the projectile will have a bigger speed, and if the distance is smaller the projectile will have smaller speed.
The you add an Event Listener with type ENTER_FRAME.
I guess it's 2 dimensional animation so you have to find the current x and y at any point in time.
Here's a little bit of code:
var TimeperFrame:Number = 1/fps //fps is not a constant, here you should add a number, a value that you previously added in fla. document properties. I usualy use 60 fps
var Time:Number = 0;
addEventListener(ENTER_FRAME, movingCannonBall);
function movingCannonBall(e:Event):void
{
Time += TimeperFrame;
}
Now here's the equitation for trajectory of projectile.
x = xo + vxo·t
y = yo + vyo·t - 0.5·g·t^2
yo = initial height of your cannon ball
vyo = initial y velocity; vyo = vo·sin θ
t = time passed, we conrol that by upper code
g = acceleration (9,81 m/s^2) at Earth's surface
xo = initial distance for the start
vxo = initial x velocity; vxo = vo·cos θ
Now in the upper code we add these equitations and it should look like this:
var TimeperFrame:Number = 1/fps
var Time:Number = 0;
var initx: Number = cannonball.x;
var inity: Number = cannonball.y;
var initVelocity: Number = (you define initial Velocity by your criteria)
var G: Number = 9.81;
addEventListener(ENTER_FRAME, movingCannonBall);
function movingCannonBall(e:Event):void
{
Time += TimeperFrame;
cannonball.x = initx + Math.cos(angle) * initVelocity * Time;
cannonball.y = inity + Math.sin(angle) * initVelocity * Time - G * Time * Time * 0.5
}
This should work. I have use this code many times and it's effiecient and also it's simple.
share|improve this answer
It sort- of works. The problem with this code is the fact that Flash has a coordinate system which is the reverse of the arcs generated. Consequently the object shot goes down (during the up- arc, when cannonball.y increases) and then up (when cannonball.y decreases). There needs to be a way to translate to Flash's coordinate system. – Factor Three Mar 28 '14 at 3:59
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/12444615/calculate-a-trajectory-for-an-object-when-given-an-angle-and-a-velocity-in-flas",
"source_domain": "stackoverflow.com",
"snapshot_id": "crawl=CC-MAIN-2015-18",
"warc_metadata": {
"Content-Length": "73861",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:5FF3SW7G5WP5CZC5ATOJQ2WIWBTFSM6W",
"WARC-Concurrent-To": "<urn:uuid:2905226d-e4f6-4b77-8ab8-29af757df902>",
"WARC-Date": "2015-05-04T02:24:51Z",
"WARC-IP-Address": "198.252.206.16",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:3SEDI2CCIIG2BBE6ZNNBSIZPU2MXETD2",
"WARC-Record-ID": "<urn:uuid:e16d7098-0fa0-47af-bcc3-0669e142f701>",
"WARC-Target-URI": "http://stackoverflow.com/questions/12444615/calculate-a-trajectory-for-an-object-when-given-an-angle-and-a-velocity-in-flas",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:074aa7c3-d6a6-4d82-a486-e9e20e41277a>"
},
"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,
25,
157,
158,
485,
486,
784,
785,
899,
900,
960,
961,
981,
982,
1006,
1029,
1050,
1051,
1075,
1092,
1093,
1157,
1158,
1190,
1192,
1215,
1244,
1245,
1278,
1342,
1343,
1368,
1415,
1416,
1437,
1483,
1518,
1520,
1521,
1578,
1579,
1607,
1609,
1629,
1635,
1663,
1690,
1696,
1698,
1699,
1755,
1756,
1784,
1786,
1822,
1862,
1863,
1901,
1939,
1940,
1959,
1991,
1993,
1994,
2008,
2009,
2018,
2020,
2021,
2057,
2097,
2141,
2142,
2143,
2186,
2192,
2219,
2261,
2262,
2292,
2323,
2354,
2355,
2411,
2421,
2445,
2469,
2479,
2480,
2536,
2546,
2567,
2588,
2598,
2599,
2635,
2645,
2683,
2716,
2752,
2788,
2826,
2864,
2865,
2894,
2915,
2936,
2937,
2971,
2992,
3002,
3008,
3010,
3038,
3039,
3050,
3051,
3080,
3081,
3115,
3116,
3469,
3470,
3523,
3524,
3623,
3624,
3653,
3654,
3824,
3845,
3846,
3895,
3935,
3937,
3962,
3964,
3965,
4021,
4022,
4037,
4038,
4065,
4066,
4106,
4107,
4148,
4149,
4195,
4196,
4245,
4246,
4282,
4283,
4324,
4325,
4402,
4403,
4435,
4456,
4490,
4524,
4598,
4620,
4621,
4670,
4710,
4712,
4737,
4802,
4890,
4892,
4893,
4985,
4986,
5012,
5017,
5388,
5389,
5401,
5402,
5404,
5412,
5413,
5491,
5492
],
"line_end_idx": [
25,
157,
158,
485,
486,
784,
785,
899,
900,
960,
961,
981,
982,
1006,
1029,
1050,
1051,
1075,
1092,
1093,
1157,
1158,
1190,
1192,
1215,
1244,
1245,
1278,
1342,
1343,
1368,
1415,
1416,
1437,
1483,
1518,
1520,
1521,
1578,
1579,
1607,
1609,
1629,
1635,
1663,
1690,
1696,
1698,
1699,
1755,
1756,
1784,
1786,
1822,
1862,
1863,
1901,
1939,
1940,
1959,
1991,
1993,
1994,
2008,
2009,
2018,
2020,
2021,
2057,
2097,
2141,
2142,
2143,
2186,
2192,
2219,
2261,
2262,
2292,
2323,
2354,
2355,
2411,
2421,
2445,
2469,
2479,
2480,
2536,
2546,
2567,
2588,
2598,
2599,
2635,
2645,
2683,
2716,
2752,
2788,
2826,
2864,
2865,
2894,
2915,
2936,
2937,
2971,
2992,
3002,
3008,
3010,
3038,
3039,
3050,
3051,
3080,
3081,
3115,
3116,
3469,
3470,
3523,
3524,
3623,
3624,
3653,
3654,
3824,
3845,
3846,
3895,
3935,
3937,
3962,
3964,
3965,
4021,
4022,
4037,
4038,
4065,
4066,
4106,
4107,
4148,
4149,
4195,
4196,
4245,
4246,
4282,
4283,
4324,
4325,
4402,
4403,
4435,
4456,
4490,
4524,
4598,
4620,
4621,
4670,
4710,
4712,
4737,
4802,
4890,
4892,
4893,
4985,
4986,
5012,
5017,
5388,
5389,
5401,
5402,
5404,
5412,
5413,
5491,
5492,
5582
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5582,
"ccnet_original_nlines": 185,
"rps_doc_curly_bracket": 0.0039412397891283035,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.25127333402633667,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01867572031915188,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3259762227535248,
"rps_doc_frac_unique_words": 0.4881118834018707,
"rps_doc_mean_word_length": 5.453146934509277,
"rps_doc_num_sentences": 69,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.417903900146484,
"rps_doc_word_count": 715,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.04719159007072449,
"rps_doc_frac_chars_dupe_6grams": 0.04719159007072449,
"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.00384713988751173,
"rps_doc_frac_chars_top_3gram": 0.00769427977502346,
"rps_doc_frac_chars_top_4gram": 0.004616570193320513,
"rps_doc_books_importance": -474.2273254394531,
"rps_doc_books_importance_length_correction": -474.2273254394531,
"rps_doc_openwebtext_importance": -248.3986053466797,
"rps_doc_openwebtext_importance_length_correction": -248.3986053466797,
"rps_doc_wikipedia_importance": -200.04656982421875,
"rps_doc_wikipedia_importance_length_correction": -200.04656982421875
},
"fasttext": {
"dclm": 0.9486829042434692,
"english": 0.753662645816803,
"fineweb_edu_approx": 2.759221315383911,
"eai_general_math": 0.43764209747314453,
"eai_open_web_math": 0.24893999099731445,
"eai_web_code": 0.15415263175964355
}
}
|
{
"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": "791.43",
"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": "4",
"label": "Code/Software"
},
"secondary": {
"code": "5",
"label": "Social/Forum"
}
},
"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": "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": "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
|
7,635,033,504,534,774,000
|
user548470 user548470 - 6 months ago 21
Linux Question
Python FileNotFoundError when using open()
I'm using
with open('myFile', 'rb') as file:
to read a file. When running the program with
python myProgram.py
everything works fine. But as soon I try to run it without
cd
-ing into the directory of
myProgram.py
and use an absolute path instead (like
python /home/myName/myCode/myProgram.py
I always get this error message:
FileNotFoundError: [Errno 2] No such file or directory
.
So why does
open()
behave differently depending on how the Python program is started? And is there a way to make things work even if starting with an absolute path?
I've already tried
open('/home/myName/myCode/myfile', 'rb')
but without success...
Answer
So why does open() behave differently depending on how the Python program is started? And is there a way to make things work even if starting with an absolute path?
Because that is standard behavior. Not just for Python, but for all applications (at least all that I know of). A relative path (like 'myfile') is assumed to be in the current directory. That path will change depending on what directory you are sitting in when you launch the script from a shell. If you don't give an absolute path, how would Python know which file to use in a directory structure like this?
root
|-- dir1
| `-- myFile
`-- dir2
`-- myFile
You were on the right track with open('/home/myName/myCode/myfile', 'rb').
Comments
|
{
"url": "https://codedump.io/share/O4eSm3Wbn4A7/1/python-filenotfounderror-when-using-open",
"source_domain": "codedump.io",
"snapshot_id": "crawl=CC-MAIN-2016-50",
"warc_metadata": {
"Content-Length": "47121",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:N7AYZYLTAQCNREWNZVWERH6WRVS4DNRG",
"WARC-Concurrent-To": "<urn:uuid:3079d481-1498-496b-987b-9fa3b5fdb11d>",
"WARC-Date": "2016-12-03T09:56:30Z",
"WARC-IP-Address": "84.22.103.185",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:GVXAEHEG3HEGWIO726Z5ZRN4DDPKZQ2X",
"WARC-Record-ID": "<urn:uuid:2347e049-a016-4233-a22e-133503c20cfe>",
"WARC-Target-URI": "https://codedump.io/share/O4eSm3Wbn4A7/1/python-filenotfounderror-when-using-open",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5c97350b-6f8b-4364-9720-4586b3c6a3ed>"
},
"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,
40,
55,
56,
99,
100,
110,
111,
146,
192,
212,
271,
274,
301,
314,
353,
393,
426,
481,
483,
484,
496,
503,
649,
650,
669,
710,
733,
734,
741,
742,
907,
908,
1317,
1318,
1323,
1332,
1347,
1356,
1371,
1372,
1447,
1448
],
"line_end_idx": [
40,
55,
56,
99,
100,
110,
111,
146,
192,
212,
271,
274,
301,
314,
353,
393,
426,
481,
483,
484,
496,
503,
649,
650,
669,
710,
733,
734,
741,
742,
907,
908,
1317,
1318,
1323,
1332,
1347,
1356,
1371,
1372,
1447,
1448,
1456
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1456,
"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.3589743673801422,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01923076994717121,
"rps_doc_frac_lines_end_with_ellipsis": 0.023255810141563416,
"rps_doc_frac_no_alph_words": 0.21153846383094788,
"rps_doc_frac_unique_words": 0.5281385183334351,
"rps_doc_mean_word_length": 4.813852787017822,
"rps_doc_num_sentences": 18,
"rps_doc_symbol_to_word_ratio": 0.00320513010956347,
"rps_doc_unigram_entropy": 4.59284782409668,
"rps_doc_word_count": 231,
"rps_doc_frac_chars_dupe_10grams": 0.23561151325702667,
"rps_doc_frac_chars_dupe_5grams": 0.23561151325702667,
"rps_doc_frac_chars_dupe_6grams": 0.23561151325702667,
"rps_doc_frac_chars_dupe_7grams": 0.23561151325702667,
"rps_doc_frac_chars_dupe_8grams": 0.23561151325702667,
"rps_doc_frac_chars_dupe_9grams": 0.23561151325702667,
"rps_doc_frac_chars_top_2gram": 0.03597122058272362,
"rps_doc_frac_chars_top_3gram": 0.050359711050987244,
"rps_doc_frac_chars_top_4gram": 0.023381289094686508,
"rps_doc_books_importance": -146.82708740234375,
"rps_doc_books_importance_length_correction": -142.02699279785156,
"rps_doc_openwebtext_importance": -74.56331634521484,
"rps_doc_openwebtext_importance_length_correction": -74.56331634521484,
"rps_doc_wikipedia_importance": -73.93907928466797,
"rps_doc_wikipedia_importance_length_correction": -64.95729064941406
},
"fasttext": {
"dclm": 0.9967204332351685,
"english": 0.9000980257987976,
"fineweb_edu_approx": 2.230679988861084,
"eai_general_math": 0.9866693019866943,
"eai_open_web_math": 0.3929687738418579,
"eai_web_code": 0.9437354207038879
}
}
|
{
"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": "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": "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
|
2,683,327,585,113,621,000
|
Core Java
Lombok, AutoValue and Immutables, or How to write less and better code returns
In the previous post about Lombok library, I have described a library that helps to deal with boilerplate code in Java (and yes I know that these problems are already solved in Kotlin, but this is real life and we can’t just all sit and rewrite every existing project once a newer or a simpler language appears). But as many things in life, project Lombok has its alternatives. Let’s give them a chance as well.
Code samples for this article can be found here and here.
Google AutoValue
It is really an alternative to Lombok – because you can’t use both at once. Or, at least it turns out that you will have difficulties while using both in the same project with IntelliJ IDEA, which is the IDE of choice for many and yours truly – because the two libraries deal with the annotation processing differently. So, neither can live while the other survives, which is approximately how a prophecy for Harry Potter and Voldemort sounded.
So, we already know how the Person class looked with Lombok annotations:
@Builder(toBuilder = true)
@ToString
@EqualsAndHashCode
@AllArgsConstructor(access = AccessLevel.PRIVATE)
public class Person {
@NonNull
@Getter
private final String lastName;
@NonNull
@Getter
private final String firstName;
@NonNull
@Getter
private final Integer age;
}
If we create a new project and make it use autovalue as described here, we can imitate pretty much the same model with AutoValue Builders.
Now let’s see how the AutoValue model looks:
package autovalue.model;
import com.google.auto.value.AutoValue;
@AutoValue
public abstract class Person {
public abstract String lastName();
public abstract String firstName();
public abstract Integer age();
public static Person create(String lastName, String firstName, Integer age) {
return builder().lastName(lastName).firstName(firstName).age(age).build();
}
public static Builder builder() {
return new AutoValue_Person.Builder();
}
@AutoValue.Builder
public abstract static class Builder {
public abstract Builder lastName(String lastName);
public abstract Builder firstName(String firstName);
public abstract Builder age(Integer age);
public abstract Person build();
}
}
What you can see is, there’s definitely more code.
While Lombok generates a builder with a single annotation, AutoValue will make you create your own builder code – not all of it though. Basically you define your interfaces and the implementation is left to AutoValue generated code, you don’t have to actually implement the code that is in getters and setters. Even if we agree that the AutoValue getter interfaces won’t take much more time or space than the Lombok field definitions, for some people it might still be a hassle and an annoyance to write the AutoValue builder code.
However, it allows for greater flexibility, because you can actually change the builder method names. Also, a big win is code analysis and usage search – this way, you can actually look for usages of actual getters and setters separately, which might also be important for developers.
The instance is created in the same way as with Lombok.
final Person anna = Person.builder()
.age(31)
.firstName("Anna")
.lastName("Smith")
.build();
All our tests run with minimal code changes, mostly because AutoValue doesn’t have a way to transform an instance to a builder (or at least I could not easily find it), so copying is just calling a static factory method:
package autovalue.model;
import org.junit.Test;
import static org.assertj.core.api.Java6Assertions.assertThat;
public class PersonTest {
private static Person JOHN = Person.builder()
.firstName("John")
.lastName("Doe")
.age(30)
.build();
private static Person JANE = Person.builder()
.firstName("Jane")
.lastName("Doe")
.age(30)
.build();
@Test
public void testEquals() throws Exception {
Person JOHN_COPY = Person.create(JOHN.lastName(), JOHN.firstName(), JOHN.age());
assertThat(JOHN_COPY).isEqualTo(JOHN);
}
@Test
public void testNotEquals() throws Exception {
assertThat(JANE).isNotEqualTo(JOHN);
}
@Test
public void testHashCode() throws Exception {
Person JOHN_COPY = Person.create(JOHN.lastName(), JOHN.firstName(), JOHN.age());
assertThat(JOHN_COPY.hashCode()).isEqualTo(JOHN.hashCode());
}
@Test
public void testHashCodeNotEquals() throws Exception {
Person JOHN_COPY = Person.create(JOHN.lastName(), JOHN.firstName(), JOHN.age());
assertThat(JOHN_COPY.hashCode()).isNotEqualTo(JANE.hashCode());
}
@Test
public void testToString() throws Exception {
String jane = JANE.toString();
assertThat(jane).contains(JANE.lastName());
assertThat(jane).contains(JANE.firstName());
assertThat(jane).contains("" + JANE.age());
assertThat(jane).doesNotContain(JOHN.firstName());
}
}
Other differences that are immediately obvious:
Why should you use AutoValue? The AutoValue creators took care to describe the gains of the library here and even create a whole presentation about it.
Immutables library
The library also uses Java annotation processors to generate simple, safe and consistent value objects. Well, same as the previous two. What else is new? Let’s see.
The simplest value class would look like this.
package immutables.model;
import org.immutables.value.Value;
@Value.Immutable
public abstract class Person {
public abstract String lastName();
public abstract String firstName();
public abstract Integer age();
}
So, there’s the same principle of having abstract classes, that are only implemented in the generated code. For that, you need to enable the IDE annotation processors, same as you do for Lombok (but not for AutoValue, as there it is done by a gradle plugin).
How does the object creation look, then?
final Person anna = ImmutablePerson.builder()
.age(31)
.firstName("Anna")
.lastName("Smith")
.build();
System.out.println(anna);
The most obvious differences are, at first glance:
• We don’t declare the builder methods.
• The static builder/factory methods are created not on our own class, but on the generated one.
• Same as AutoValue, there’s no way to generate setters on the class, just on the builder.
• The generated class also automatically adds with-ers, that is, instance methods, that allow to create a copy of the instance by changing one property:
final ImmutablePerson anna = ImmutablePerson.builder()
.age(31)
.firstName("Anna")
.lastName("Smith")
.build();
System.out.println(anna);
final ImmutablePerson annaTheSecond = anna.withAge(23).withLastName("Smurf");
System.out.println(annaTheSecond);
• The builder has an automatically added from() method, that allows to create an exact copy of the instance, and there’s also a generated static copyOf() method on the generated class:
Person JOHN_COPY = ImmutablePerson.builder().from(JOHN).build();
// OR
Person JOHN_COPY = ImmutablePerson.copyOf(JOHN);
And again, our test runs with minimal changes, which are mainly about how we copy the instances:
package immutables.model;
import org.junit.Test;
import static org.assertj.core.api.Assertions.assertThat;
public class PersonTest {
private static Person JOHN = ImmutablePerson.builder()
.firstName("John")
.lastName("Doe")
.age(30)
.build();
private static Person JANE = ImmutablePerson.builder()
.firstName("Jane")
.lastName("Doe")
.age(30)
.build();
@Test
public void testEquals() throws Exception {
//ImmutablePerson JOHN_COPY = ImmutablePerson.builder().from(JOHN).build();
Person JOHN_COPY = ImmutablePerson.copyOf(JOHN);
assertThat(JOHN_COPY).isEqualTo(JOHN);
}
@Test
public void testNotEquals() throws Exception {
assertThat(JANE).isNotEqualTo(JOHN);
}
@Test
public void testHashCode() throws Exception {
Person JOHN_COPY = ImmutablePerson.copyOf(JOHN);
assertThat(JOHN_COPY.hashCode()).isEqualTo(JOHN.hashCode());
}
@Test
public void testHashCodeNotEquals() throws Exception {
Person JOHN_COPY = ImmutablePerson.copyOf(JOHN);
assertThat(JOHN_COPY.hashCode()).isNotEqualTo(JANE.hashCode());
}
@Test
public void testToString() throws Exception {
String jane = JANE.toString();
assertThat(jane).contains(JANE.firstName());
assertThat(jane).contains(JANE.lastName());
assertThat(jane).contains("" + JANE.age());
assertThat(jane).doesNotContain(JOHN.firstName());
}
}
There’s much more to say about Immutables library, so there’s a pretty big manual for it here. Here in this article we only scratched the surface a little. There’s for example much more details about JSON serialization with Immitables and style customizations (method prefixes, builder names etc.) and even repository generation for Mongo so that documents could be treated as immutables. But that is all much more than I care for to touch in this simple article.
The takeaway is, one of the challenges of the not-going-anywhere-yet Java language is verbosity and boilerplate code. But there’s numerous tools to deal with it, and one can choose a library that fits best, instead of coding by copy-paste or trying to write your own code generator.
Use them well.
Use it well.
Published on Java Code Geeks with permission by Maryna Cherniavska, partner at our JCG program. See the original article here: Lombok, AutoValue and Immutables, or How to write less and better code returns
Opinions expressed by Java Code Geeks contributors are their own.
Maryna Cherniavska
Maryna has productively spent 10+ years in IT industry, designing, developing, building and deploying desktop and web applications, designing database structures and otherwise proving that females have a place among software developers. And this is a good place.
Subscribe
Notify of
guest
This site uses Akismet to reduce spam. Learn how your comment data is processed.
1 Comment
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Christian
Christian
6 years ago
I’m happy tout use Groovy for many years :-)
Back to top button
|
{
"url": "https://www.javacodegeeks.com/2018/03/lombok-autovalue-and-immutables-or-how-to-write-less-and-better-code-returns.html",
"source_domain": "www.javacodegeeks.com",
"snapshot_id": "CC-MAIN-2024-26",
"warc_metadata": {
"Content-Length": "252805",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LDCFLIUA2EWOE45RABBHGEIEZYQQT3VE",
"WARC-Concurrent-To": "<urn:uuid:c0654767-9600-41dc-ab0c-a8e61e701a65>",
"WARC-Date": "2024-06-24T15:45:07Z",
"WARC-IP-Address": "104.26.2.29",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:Z2CZLNW6PYYQIPJTNCT3WMTVJ5XA3E4C",
"WARC-Record-ID": "<urn:uuid:28fbd112-c3c2-4004-afab-ff599209debf>",
"WARC-Target-URI": "https://www.javacodegeeks.com/2018/03/lombok-autovalue-and-immutables-or-how-to-write-less-and-better-code-returns.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e386235a-3006-4bd5-9d8d-b2b7bae10155>"
},
"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-32\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,
90,
91,
503,
504,
562,
563,
580,
581,
1027,
1028,
1101,
1102,
1105,
1132,
1142,
1161,
1211,
1233,
1246,
1258,
1293,
1306,
1318,
1354,
1367,
1379,
1410,
1412,
1413,
1552,
1553,
1598,
1599,
1602,
1628,
1629,
1669,
1670,
1681,
1712,
1751,
1752,
1792,
1793,
1828,
1829,
1911,
1994,
2000,
2001,
2039,
2086,
2092,
2093,
2116,
2159,
2218,
2279,
2329,
2330,
2370,
2376,
2378,
2379,
2430,
2431,
2963,
2964,
3249,
3250,
3306,
3307,
3310,
3348,
3365,
3392,
3419,
3437,
3438,
3659,
3660,
3663,
3688,
3689,
3712,
3713,
3776,
3777,
3803,
3853,
3884,
3913,
3934,
3956,
4006,
4037,
4066,
4087,
4109,
4110,
4120,
4168,
4257,
4304,
4310,
4311,
4321,
4372,
4417,
4423,
4424,
4434,
4484,
4573,
4642,
4648,
4649,
4659,
4718,
4807,
4879,
4885,
4886,
4896,
4946,
4985,
4986,
5038,
5091,
5143,
5202,
5208,
5209,
5211,
5212,
5260,
5261,
5413,
5414,
5433,
5434,
5599,
5600,
5647,
5648,
5651,
5677,
5678,
5713,
5714,
5731,
5762,
5801,
5841,
5876,
5878,
5879,
6138,
6139,
6180,
6181,
6184,
6230,
6247,
6274,
6301,
6319,
6345,
6346,
6397,
6398,
6440,
6539,
6632,
6787,
6790,
6845,
6862,
6889,
6916,
6934,
6960,
6961,
7039,
7074,
7261,
7264,
7329,
7335,
7384,
7385,
7482,
7483,
7486,
7512,
7513,
7536,
7537,
7595,
7596,
7597,
7623,
7682,
7713,
7742,
7763,
7785,
7844,
7875,
7904,
7925,
7947,
7948,
7958,
8006,
8090,
8147,
8194,
8200,
8201,
8211,
8262,
8307,
8313,
8314,
8324,
8374,
8431,
8500,
8506,
8507,
8517,
8576,
8633,
8705,
8711,
8712,
8722,
8772,
8811,
8812,
8865,
8917,
8969,
9028,
9034,
9035,
9037,
9038,
9502,
9503,
9786,
9787,
9802,
9803,
9816,
9817,
10023,
10024,
10090,
10091,
10110,
10111,
10374,
10384,
10394,
10400,
10401,
10482,
10483,
10493,
10500,
10518,
10535,
10553,
10563,
10573,
10585,
10586,
10631,
10632
],
"line_end_idx": [
10,
11,
90,
91,
503,
504,
562,
563,
580,
581,
1027,
1028,
1101,
1102,
1105,
1132,
1142,
1161,
1211,
1233,
1246,
1258,
1293,
1306,
1318,
1354,
1367,
1379,
1410,
1412,
1413,
1552,
1553,
1598,
1599,
1602,
1628,
1629,
1669,
1670,
1681,
1712,
1751,
1752,
1792,
1793,
1828,
1829,
1911,
1994,
2000,
2001,
2039,
2086,
2092,
2093,
2116,
2159,
2218,
2279,
2329,
2330,
2370,
2376,
2378,
2379,
2430,
2431,
2963,
2964,
3249,
3250,
3306,
3307,
3310,
3348,
3365,
3392,
3419,
3437,
3438,
3659,
3660,
3663,
3688,
3689,
3712,
3713,
3776,
3777,
3803,
3853,
3884,
3913,
3934,
3956,
4006,
4037,
4066,
4087,
4109,
4110,
4120,
4168,
4257,
4304,
4310,
4311,
4321,
4372,
4417,
4423,
4424,
4434,
4484,
4573,
4642,
4648,
4649,
4659,
4718,
4807,
4879,
4885,
4886,
4896,
4946,
4985,
4986,
5038,
5091,
5143,
5202,
5208,
5209,
5211,
5212,
5260,
5261,
5413,
5414,
5433,
5434,
5599,
5600,
5647,
5648,
5651,
5677,
5678,
5713,
5714,
5731,
5762,
5801,
5841,
5876,
5878,
5879,
6138,
6139,
6180,
6181,
6184,
6230,
6247,
6274,
6301,
6319,
6345,
6346,
6397,
6398,
6440,
6539,
6632,
6787,
6790,
6845,
6862,
6889,
6916,
6934,
6960,
6961,
7039,
7074,
7261,
7264,
7329,
7335,
7384,
7385,
7482,
7483,
7486,
7512,
7513,
7536,
7537,
7595,
7596,
7597,
7623,
7682,
7713,
7742,
7763,
7785,
7844,
7875,
7904,
7925,
7947,
7948,
7958,
8006,
8090,
8147,
8194,
8200,
8201,
8211,
8262,
8307,
8313,
8314,
8324,
8374,
8431,
8500,
8506,
8507,
8517,
8576,
8633,
8705,
8711,
8712,
8722,
8772,
8811,
8812,
8865,
8917,
8969,
9028,
9034,
9035,
9037,
9038,
9502,
9503,
9786,
9787,
9802,
9803,
9816,
9817,
10023,
10024,
10090,
10091,
10110,
10111,
10374,
10384,
10394,
10400,
10401,
10482,
10483,
10493,
10500,
10518,
10535,
10553,
10563,
10573,
10585,
10586,
10631,
10632,
10650
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 10650,
"ccnet_original_nlines": 283,
"rps_doc_curly_bracket": 0.003380279988050461,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2625754475593567,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03370220959186554,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2826961874961853,
"rps_doc_frac_unique_words": 0.36093246936798096,
"rps_doc_mean_word_length": 6.207395553588867,
"rps_doc_num_sentences": 176,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.548902988433838,
"rps_doc_word_count": 1244,
"rps_doc_frac_chars_dupe_10grams": 0.1331261247396469,
"rps_doc_frac_chars_dupe_5grams": 0.24268324673175812,
"rps_doc_frac_chars_dupe_6grams": 0.2281792312860489,
"rps_doc_frac_chars_dupe_7grams": 0.2281792312860489,
"rps_doc_frac_chars_dupe_8grams": 0.1766381859779358,
"rps_doc_frac_chars_dupe_9grams": 0.1618751585483551,
"rps_doc_frac_chars_top_2gram": 0.02356901951134205,
"rps_doc_frac_chars_top_3gram": 0.018130019307136536,
"rps_doc_frac_chars_top_4gram": 0.018777519464492798,
"rps_doc_books_importance": -843.08349609375,
"rps_doc_books_importance_length_correction": -843.08349609375,
"rps_doc_openwebtext_importance": -527.5877075195312,
"rps_doc_openwebtext_importance_length_correction": -527.5877075195312,
"rps_doc_wikipedia_importance": -399.2623291015625,
"rps_doc_wikipedia_importance_length_correction": -399.2623291015625
},
"fasttext": {
"dclm": 0.23702359199523926,
"english": 0.7231146693229675,
"fineweb_edu_approx": 2.437408208847046,
"eai_general_math": 0.6173584461212158,
"eai_open_web_math": 0.10054867714643478,
"eai_web_code": 0.4244489073753357
}
}
|
{
"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": "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
|
5,987,203,267,571,488,000
|
3
Obviously this is rookie question, however I do not believe Solidity docs, nor W3Schools explicitly state this.
In the return statement, is the second line in the block equivalent to a second Then statement? My (basic) understanding is that a return statement signals immediately halt to the function execution.
function mint(address receiver, uint amount) {
if (msg.sender != minter) return;
balances[receiver] += amount;
}
Many thanks.
2 Answers 2
3
The construct if (condition) expression; is equivalent to if (condition) then expression. Essentially, if the sender is not equal to the minter, then it returns, so the rest of the function is not executed. Otherwise, execution continues.
So in this case, the line after the if statement is equivalent to being in an else clause.
2
is the second line in the block equivalent to a second Then statement?
No.
function mint(address receiver, uint amount) {
if (msg.sender != minter) {
return;
}
balances[receiver] += amount;
}
The code in the question is identical to the above. Note that it is different from treating the balances[receiver] += amount; as part of the Then statement, which would be:
function mint(address receiver, uint amount) {
if (msg.sender != minter) {
balances[receiver] += amount; // this is now inside the "if" but has completely changed the meaning from the original code
return;
}
}
Also, for each if there's only one Then statement. To have a second Then statement would require another if (or else if).
It's also worth pointing out that some coding conventions highly encourage the use of braces {} around the Then statement, even if the Then statement only contains one statement.
Your Answer
By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "https://ethereum.stackexchange.com/questions/1316/from-the-solidity-subcurrency-example-return-statements",
"source_domain": "ethereum.stackexchange.com",
"snapshot_id": "CC-MAIN-2023-50",
"warc_metadata": {
"Content-Length": "169826",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:Z6UVVVW4FVKRFSLMNB6ENT4WU3KCD7Y7",
"WARC-Concurrent-To": "<urn:uuid:25a96592-385c-4861-85ab-74afd09de3ba>",
"WARC-Date": "2023-12-04T10:50:35Z",
"WARC-IP-Address": "172.64.144.30",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:KGWFX4UEGCZW3PI6DZB5PNZHR7VUSSZV",
"WARC-Record-ID": "<urn:uuid:1d6e8cdb-33f6-4e56-83b7-d6a91d542ee4>",
"WARC-Target-URI": "https://ethereum.stackexchange.com/questions/1316/from-the-solidity-subcurrency-example-return-statements",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2cd5b49b-0a30-4cd6-8d05-1f4b1d3b8d5e>"
},
"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-172\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,
2,
3,
115,
116,
316,
317,
364,
406,
444,
450,
451,
464,
465,
477,
478,
480,
481,
720,
721,
812,
813,
815,
816,
887,
888,
892,
893,
940,
976,
996,
1006,
1044,
1050,
1051,
1224,
1225,
1272,
1308,
1444,
1464,
1474,
1480,
1481,
1603,
1604,
1783,
1784,
1796,
1797,
1953,
1954
],
"line_end_idx": [
2,
3,
115,
116,
316,
317,
364,
406,
444,
450,
451,
464,
465,
477,
478,
480,
481,
720,
721,
812,
813,
815,
816,
887,
888,
892,
893,
940,
976,
996,
1006,
1044,
1050,
1051,
1224,
1225,
1272,
1308,
1444,
1464,
1474,
1480,
1481,
1603,
1604,
1783,
1784,
1796,
1797,
1953,
1954,
2044
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2044,
"ccnet_original_nlines": 51,
"rps_doc_curly_bracket": 0.005870840046554804,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3611793518066406,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.002457000082358718,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.24815724790096283,
"rps_doc_frac_unique_words": 0.46979865431785583,
"rps_doc_mean_word_length": 5.030201435089111,
"rps_doc_num_sentences": 23,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.498202800750732,
"rps_doc_word_count": 298,
"rps_doc_frac_chars_dupe_10grams": 0.18545697629451752,
"rps_doc_frac_chars_dupe_5grams": 0.22148099541664124,
"rps_doc_frac_chars_dupe_6grams": 0.22148099541664124,
"rps_doc_frac_chars_dupe_7grams": 0.22148099541664124,
"rps_doc_frac_chars_dupe_8grams": 0.22148099541664124,
"rps_doc_frac_chars_dupe_9grams": 0.18545697629451752,
"rps_doc_frac_chars_top_2gram": 0.06070714071393013,
"rps_doc_frac_chars_top_3gram": 0.0220146793872118,
"rps_doc_frac_chars_top_4gram": 0.04002667963504791,
"rps_doc_books_importance": -186.723876953125,
"rps_doc_books_importance_length_correction": -186.723876953125,
"rps_doc_openwebtext_importance": -107.02171325683594,
"rps_doc_openwebtext_importance_length_correction": -107.02171325683594,
"rps_doc_wikipedia_importance": -106.7265625,
"rps_doc_wikipedia_importance_length_correction": -106.7265625
},
"fasttext": {
"dclm": 0.9477774500846863,
"english": 0.9239642024040222,
"fineweb_edu_approx": 2.229670763015747,
"eai_general_math": 0.23540842533111572,
"eai_open_web_math": 0.15626341104507446,
"eai_web_code": 0.03829294070601463
}
}
|
{
"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": "332.872",
"labels": {
"level_1": "Social sciences",
"level_2": "Economics",
"level_3": "Finance"
}
}
},
"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": "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": "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,914,260,683,852,658,000
|
Sign up ×
Webmasters Stack Exchange is a question and answer site for pro webmasters. It's 100% free, no registration required.
For this particular website there's no current mobile version.
My question is: by creating a simplified mobile version of the site, with obviously less content but more accessible, wouldn't the site be hurt?
Google seems, from what I've read to rank mobile versions higher in mobile searches, but with a limited content, should I even bother?
share|improve this question
1 Answer 1
up vote 3 down vote accepted
I would say this is a question many web developers come across and in the end it comes down to the service they provide. First of all, having a mobile version of a website that makes your page look better on mobile devices is never a bad idea.
BUT you usually have to be very careful with the way you implement that mobile version. Usually developers/webmasters tend to remove a lot of useful stuff that users really liked to use or need hence many users use the normal web page anyways or at worst case they believe they can't get the full experience on a mobile device and don't visit your page on mobile devices at all.
The questions you have to ask yourself are:
1. Can I provide a mobile version with all essential parts that makes my website what it is?
2. Would a mobile version help my users to experience my website in a better way?
3. Is it really worth the effort to create a full mobile version or could I use that time better on additional features or maybe even on some minor css changes so that my normal design looks better on mobile devices.
Never create a mobile version of a website just because you can. There are tons of websites that are perfectly fine the way they are on the other hand many websites benefited from a mobile version. So the points I mentioned above are usually what I try to figure out before I make a final decision. Page ranking based on mobile or desktop design are only secondary if the user leaves your page after a couple of seconds because he/she doesn't like what they see or can experience.
Regarding search ranking you would have to find out what is responsible for a good ranking on your page. Which aspects of your page make google index it to which searches. If you can track that down you can use these information to make sure you use these parts on a mobile version as well.
share|improve this answer
I side with you on all points. I see nothing wrong with a regular site on a phone or tablet, and quite frankly with these huge screens nowadays, I really don't see an issue. That being said, things like a button to place a phone call are really useful I think. But all and all, I just don't think its worth removing a lot of the good content we have to make a simplified version. Thanks for your answer. – riseagainst Dec 13 '13 at 12:17
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://webmasters.stackexchange.com/questions/56064/mobile-site-and-ranking-concerns",
"source_domain": "webmasters.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2015-40",
"warc_metadata": {
"Content-Length": "69596",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:6VF3EELGDBAVDFVCQXDMAUGL6T66MPRE",
"WARC-Concurrent-To": "<urn:uuid:8b290fad-c52b-4d5b-883e-4ed9e7557501>",
"WARC-Date": "2015-10-05T09:02:30Z",
"WARC-IP-Address": "104.16.16.128",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:NWQDZQKZUB7PEYJVT46KGAOZMCU7OTTE",
"WARC-Record-ID": "<urn:uuid:d3bfff7e-9d89-44ca-8690-17146a892412>",
"WARC-Target-URI": "http://webmasters.stackexchange.com/questions/56064/mobile-site-and-ranking-concerns",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ab061ba3-4fe6-4c06-ae20-61705cac4fe5>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-137-6-227.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-40\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for September 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,
10,
128,
129,
192,
193,
338,
339,
474,
475,
503,
504,
515,
516,
545,
546,
790,
791,
1170,
1171,
1215,
1216,
1311,
1395,
1614,
1615,
2096,
2097,
2388,
2389,
2415,
2420,
2859,
2860,
2872,
2873,
2875,
2883,
2884,
2962,
2963
],
"line_end_idx": [
10,
128,
129,
192,
193,
338,
339,
474,
475,
503,
504,
515,
516,
545,
546,
790,
791,
1170,
1171,
1215,
1216,
1311,
1395,
1614,
1615,
2096,
2097,
2388,
2389,
2415,
2420,
2859,
2860,
2872,
2873,
2875,
2883,
2884,
2962,
2963,
3053
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3053,
"ccnet_original_nlines": 40,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4864864945411682,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.022257549688220024,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.11764705926179886,
"rps_doc_frac_unique_words": 0.4321880638599396,
"rps_doc_mean_word_length": 4.356238842010498,
"rps_doc_num_sentences": 30,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.019155025482178,
"rps_doc_word_count": 553,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.019925279542803764,
"rps_doc_frac_chars_dupe_6grams": 0.019925279542803764,
"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.05396429821848869,
"rps_doc_frac_chars_top_3gram": 0.0348692387342453,
"rps_doc_frac_chars_top_4gram": 0.013283520005643368,
"rps_doc_books_importance": -254.5590362548828,
"rps_doc_books_importance_length_correction": -254.5590362548828,
"rps_doc_openwebtext_importance": -164.24217224121094,
"rps_doc_openwebtext_importance_length_correction": -164.24217224121094,
"rps_doc_wikipedia_importance": -98.57754516601562,
"rps_doc_wikipedia_importance_length_correction": -98.57754516601562
},
"fasttext": {
"dclm": 0.17219948768615723,
"english": 0.9590662717819214,
"fineweb_edu_approx": 1.1006124019622803,
"eai_general_math": 0.0006933200056664646,
"eai_open_web_math": 0.06048804894089699,
"eai_web_code": 0.0007043500081636012
}
}
|
{
"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": "658.87",
"labels": {
"level_1": "Industrial arts, Technology, and Engineering",
"level_2": "Business",
"level_3": "Management"
}
}
},
"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": "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": "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
|
-4,815,808,877,335,664,000
|
October 25, 2014
Hot Topics:
RSS RSS feed Download our iPhone app
VoiceXML Developer Series: A Tour Through VoiceXML, Part IX
• October 9, 2002
• By Jonathan Eisenzopf
• Send Email »
• More Articles »
In all of the examples thus far, we have collected input but stopped short of submitting the form fields to a back end script. In this edition of the VoiceXML Developer, we will complete our pizza ordering application by accepting the order, logging the transaction in an Access database, and playing an order confirmation for the user. We will also utilize many of the techniques that we have learned over the course of this tutorial to create a high quality voice application.
Overview
It's time to put all of the skills you've learned to use. We are going to start by designing a dialog flow. Then we will develop an application architecture and data model based upon the dialog flow. From the dialog flow, we will develop our VoiceXML forms and add the back-end scripting capability that will allow the system to recognize and create customer records as well as add a pizza order to a table in an Access database. We will be using PerlScript for Active Server Pages to perform SQL queries. We could have also used PHP, Cold Fusion, or JSP as well, but I'm most familiar with Perl and prefer its text processing capabilities, which come in handy when we're parsing text representations of user utterances.
Creating a dialog flow
I used Microsoft Viso to create a dialog flow that contains all of the prompts, decision trees, and processing instructions that are required for this application. I've split the whole diagram into two separate pieces. The first piece contains the flow for getting the customer's phone number and address. The flow starts by playing a greeting and is followed by a prompt asking the user for their phone number. The system confirms the number by speaking the number back and asking the customer to confirm that the number that was recognized as the number they uttered. If it's not, the system will prompt the customer for their phone number again until the customer confirms that the correct phone number was recognized.
When the customer does confirm that we have the correct number, we submit the VoiceXML form to a back-end ASP script, which uses we uses the phone number as a key to look up the customer's record in the Access database. If the number doesn't exist, we create one and prompt the user for their address. Their address is recorded as a .wav file and submitted to another ASP script, which saves the file and associates it with the customer's record.
If the customer has previously used the system to place an order and they provide the same phone number, the database will ask the user to confirm the address or provide a new one. If the customer confirms the address, we move on to the next dialog flow, which takes the customer's order. If the customer does not confirm the address, the system prompts the user to record their address, and the resulting .wav file is saved and associated with their customer record.
View the Dialog Flow image
Now we have confirmed a valid phone number and address, we move to the second part of the dialog flow, which prompts the customer for their pizza order. Notice that our prompt is, "May I take your order please." This is a rather open ended question. We need to be ready to handle many different utterances that the user might provide. If the range of utterances is too wide to cover, we may need to provide a more specific prompt that provides the options that the customer can select from. The slots (or form fields) that we need to fill to place a pizza order are the pizza size, the pizza type, and the pizza toppings. Because this will be a mixed initiative dialog, the customer could fill all of the slots with a single utterance like, "I would like a small hand tossed pizza with pepperoni and mushrooms". On the other hand, they might just say, "I'd like a small pepperoni pizza". So we need to be able to handle cases where the customer does not fill all of the slots by providing directed prompts for those fields that were not filled. In the last example utterance, we would want to prompt the customer for a pizza type.
Once all of the slots have been filled, we want to play the order back to the customer and have them confirm the order. If the customer says "Yes", then we thank them for the order, record the order in the Access database, and end the call. If the customer says "No", we need to go back and prompt them for their order again until we get it right.
View the 2nd Dialog Flow image
And that's our dialog flow. It a good idea to map it out on paper or in some kind of a dialog flow so that you or your customer can review the call flow to ensure that it will satisfy the business and customer needs fully.
Page 1 of 2
Comment and Contribute
(Maximum characters: 1200). You have characters left.
Sitemap | Contact Us
Rocket Fuel
|
{
"url": "http://www.developer.com/voice/article.php/1568861/VoiceXML-Developer-SeriesBRA-Tour-Through-VoiceXML-Part-IX.htm",
"source_domain": "www.developer.com",
"snapshot_id": "crawl=CC-MAIN-2014-42",
"warc_metadata": {
"Content-Length": "61054",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:IACVTDWQF3GKLORVLCTTHCLQJNBBKLKC",
"WARC-Concurrent-To": "<urn:uuid:613e6b38-600a-4acb-90e8-a9da2595b4dd>",
"WARC-Date": "2014-10-25T12:04:10Z",
"WARC-IP-Address": "23.0.160.11",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:7LRNXSEYVR2CYCBCX7BXG7HDPN4TBMHJ",
"WARC-Record-ID": "<urn:uuid:2effeaf1-6ae3-41b2-87e6-4fa61f7856d8>",
"WARC-Target-URI": "http://www.developer.com/voice/article.php/1568861/VoiceXML-Developer-SeriesBRA-Tour-Through-VoiceXML-Part-IX.htm",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:378bfcba-7053-4d83-a6e7-9a3e2451ef17>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-16-133-185.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-42\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for October 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,
17,
29,
66,
67,
127,
128,
148,
174,
191,
211,
212,
691,
692,
701,
702,
1423,
1424,
1447,
1448,
2170,
2171,
2618,
2619,
3087,
3088,
3115,
3116,
4247,
4248,
4596,
4597,
4628,
4629,
4852,
4853,
4854,
4855,
4856,
4857,
4869,
4870,
4871,
4872,
4895,
4896,
4898,
4899,
4900,
4954,
4955,
4957,
4958,
4960,
4961,
4962,
4983,
4984
],
"line_end_idx": [
17,
29,
66,
67,
127,
128,
148,
174,
191,
211,
212,
691,
692,
701,
702,
1423,
1424,
1447,
1448,
2170,
2171,
2618,
2619,
3087,
3088,
3115,
3116,
4247,
4248,
4596,
4597,
4628,
4629,
4852,
4853,
4854,
4855,
4856,
4857,
4869,
4870,
4871,
4872,
4895,
4896,
4898,
4899,
4900,
4954,
4955,
4957,
4958,
4960,
4961,
4962,
4983,
4984,
4995
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4995,
"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.44960474967956543,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.014822130091488361,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.11857707798480988,
"rps_doc_frac_unique_words": 0.37078651785850525,
"rps_doc_mean_word_length": 4.435955047607422,
"rps_doc_num_sentences": 41,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.042977809906006,
"rps_doc_word_count": 890,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.008611960336565971,
"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.04179330915212631,
"rps_doc_frac_chars_top_3gram": 0.012158050201833248,
"rps_doc_frac_chars_top_4gram": 0.009878420270979404,
"rps_doc_books_importance": -489.72320556640625,
"rps_doc_books_importance_length_correction": -489.72320556640625,
"rps_doc_openwebtext_importance": -284.58746337890625,
"rps_doc_openwebtext_importance_length_correction": -284.58746337890625,
"rps_doc_wikipedia_importance": -249.3068084716797,
"rps_doc_wikipedia_importance_length_correction": -249.3068084716797
},
"fasttext": {
"dclm": 0.33488547801971436,
"english": 0.9474102854728699,
"fineweb_edu_approx": 1.4471826553344727,
"eai_general_math": 0.21727705001831055,
"eai_open_web_math": 0.1559206247329712,
"eai_web_code": 0.18040579557418823
}
}
|
{
"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": "006.31",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Cognitive 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": "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": "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
|
-9,208,306,445,872,364,000
|
473,728 Members | 1,628 Online
Bytes | Software Development & Data Engineering Community
+ Post
Home Posts Topics Members FAQ
python for flash drives
Is there such a thing as a special version of python that I can run
more efficiently from a flash drive? I'll be at college for hours
every day with hours of free time for the next few months, but the only
computers at my disposal are windows PCs that use GoBack to auto-revert
every reboot. So I'm kinda stuck. I don't want to have to reinstall
python AND wxPython AND PIL every stinking time I log on. However,
using it from my flash drive is painfully slow taking up to a minute
just to execute some scripts. And it's not doing me any favors with
I/O to the flash disk either.
So I was wondering if anybody knew of some flash drive implementations
of python that might exist out there somewhere?
Aug 29 '06 #1
3 3836
Putty wrote:
Is there such a thing as a special version of python that I can run
more efficiently from a flash drive?
google for movable python (or similar)
--
Maciej "Fiedzia" Dziardziel (ma************ **@poczta.wp.pl )
In the land of the blind, the one eyed man is king.
Aug 29 '06 #2
You could always get an mp3 player that windows
can see as a drive letter. I'll bet the I/O
would be quite fast. Plus, you would be
getting an mp3 player.
If money is a concern, check out used ones
on ebay.
Putty wrote:
Is there such a thing as a special version of python that I can run
more efficiently from a flash drive? I'll be at college for hours
every day with hours of free time for the next few months, but the only
computers at my disposal are windows PCs that use GoBack to auto-revert
every reboot. So I'm kinda stuck. I don't want to have to reinstall
python AND wxPython AND PIL every stinking time I log on. However,
using it from my flash drive is painfully slow taking up to a minute
just to execute some scripts. And it's not doing me any favors with
I/O to the flash disk either.
--
Posted via a free Usenet account from http://www.teranews.com
Aug 29 '06 #3
Putty wrote:
Is there such a thing as a special version of python that I can run
more efficiently from a flash drive? I'll be at college for hours
every day with hours of free time for the next few months, but the only
computers at my disposal are windows PCs that use GoBack to auto-revert
every reboot. So I'm kinda stuck. I don't want to have to reinstall
python AND wxPython AND PIL every stinking time I log on. However,
using it from my flash drive is painfully slow taking up to a minute
just to execute some scripts. And it's not doing me any favors with
I/O to the flash disk either.
So I was wondering if anybody knew of some flash drive implementations
of python that might exist out there somewhere?
Use Movable Python, which comes with wxPython and PIL.
It's never been that slow for me off a USB flash drive, but you could
just copy the distribution onto the PC each time you use it.
http://www.voidspace.org.uk/python/movpy/
Fuzzyman
Aug 29 '06 #4
This thread has been closed and replies have been disabled. Please start a new discussion.
Similar topics
3
1782
by: TuxTrax | last post by:
Hi all I use a macintosh and a pc at home. On My Mac, I have python installed. But my Pc hard drive recently failed and I have been running Damn Small Linux, a derivitave of Knoppix Linux direct from the cd. I like Damn small Linux much better than Knoppix, but DSL dosen't have python. An idea came to me: what if I could load a complete python distribution for unix onto a jumpdrive (also known as a thumbdrive or
0
2211
by: python-help-bounces | last post by:
Your message for python-help@python.org, the Python programming language assistance line, has been received and is being delivered. This automated response is sent to those of you new to python-help, to point out a few resources that can help with answering your own questions, or improve the chances of getting a useful answer from the helpers. The most comprehensive overview of python.org help resources is at ...
9
3541
by: Mayer | last post by:
Hello: I'm running python under cygwin and need to find the drive letter. Cygwin has a way of calling my drives by a name relative to the Cygwin directory, so I get things like /home/user rather than /cygdrive/g/cygwin/home/usr, etc. How can I find the letter of the drive, or in the above example, the letter 'g'? My program needs to run on an external media that comes with Cygwin on it. I have no control over what drive is assigned to...
5
3945
by: Dustin Davis | last post by:
This might be a pipe dream, but here goes... I'm writing an application many users will be working on and saving files to USB flash drives. When they click the save button, I would like to have the default save path be the flash drive, if one exists. The best solution I can thing of is to assume the drive will be E:\ and put that in a Try/Catch to have that be the default path. Does anyone know of a better solution that this can be...
0
12483
Chrisjc
by: Chrisjc | last post by:
<Excerpted from this thread> All of these questions and answers are great. But it comes down to this I have seen this more than enough times to know better... From my experience at home and as an IT in an office with well over 900 computers to look after I maybe get this question up to 3 times in a week... sadly I suspect that if you remove your FLASH drive with out safely disconnecting it the next PC will not recognize it for the soul...
0
2006
by: norseman | last post by:
Hendrik van Rooyen wrote: ============================================= .....dreaded.... Yep! I know the feeling. Got lots of those T-Shirts. ;) I re-read your original post. I got the feeling the eBox is running a stripped down Linux. Is that so? If it is, then: You mention pcmcia. Is it external, a plug in? Do any of your
8
2429
by: Salad | last post by:
I was asked to get my daughter a flash drive. She needs to use it to copy files to it so she can transfer the files at school to her desktop at home. I've never used one but I figure some of you have. I see flash drives from on the net from 128 meg up to 16 gig. Prices range from $20 to $600. I see a lot of those ads referring to cameras. Are there USB flash drives specific for cameras and others for computers? Or do they all work...
1
1368
by: jwahlmann | last post by:
I'm experiencing some strange behavior when starting up python on a Debian-based PowerPC platform. Normally, I operate from this platform with a root file system on an IDE flash drive (/dev/hda1). However, I'm trying to get my system to run with root on a mechanical SATA drive (/dev/sda1). Both are installed on a PowerPC board via a PMC daughter board. When running off the flash drive, the Python interpreter loads and runs just fine....
0
2058
by: Daffydd | last post by:
Hi all, This one's driving me up a wall! We have a small office network, Windows SBS 2003, nothing fancy - recently upgraded from an old Compaq running Novell. Back in the day we used the "F" and "G" drive letters for our main network drives. This worked wonderfully until we started using flash drives recently - replacing floppies for portable data movement. Seems that, even tho we have 2 mapped drives as "F" and "G" Windows (XP and...
0
8894
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8753
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9411
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9265
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9188
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6704
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6012
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4787
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3230
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.
To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.
|
{
"url": "https://bytes.com/topic/python/529222-python-flash-drives",
"source_domain": "bytes.com",
"snapshot_id": "CC-MAIN-2024-26",
"warc_metadata": {
"Content-Length": "48298",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:Y6JOZ4PP2PPVPQU5PMKXR75MHI4ZFYLH",
"WARC-Concurrent-To": "<urn:uuid:da59f187-b498-4792-9942-f80a29bbec67>",
"WARC-Date": "2024-06-23T07:58:56Z",
"WARC-IP-Address": "34.49.238.24",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:6QD2Z2EOAF3OWBBWSTVTGTE6WRUNQOPW",
"WARC-Record-ID": "<urn:uuid:46b3f007-0fda-4fde-bbc8-58c89c74795c>",
"WARC-Target-URI": "https://bytes.com/topic/python/529222-python-flash-drives",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:564a21d1-75f1-41b4-8435-a3ef45302310>"
},
"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,
2,
4,
35,
93,
100,
101,
131,
132,
156,
157,
225,
291,
363,
435,
503,
570,
639,
707,
737,
738,
809,
857,
858,
872,
879,
892,
960,
997,
1036,
1037,
1040,
1102,
1103,
1155,
1169,
1217,
1261,
1301,
1324,
1325,
1368,
1377,
1378,
1391,
1459,
1525,
1597,
1669,
1737,
1804,
1873,
1941,
1971,
1974,
2036,
2037,
2051,
2052,
2065,
2133,
2199,
2271,
2343,
2411,
2478,
2547,
2615,
2645,
2646,
2717,
2765,
2820,
2821,
2891,
2952,
2953,
2995,
2996,
3005,
3006,
3020,
3021,
3112,
3113,
3128,
3129,
3131,
3136,
3164,
3580,
3582,
3587,
3627,
4044,
4046,
4051,
4077,
4519,
4521,
4526,
4559,
4998,
5000,
5006,
5014,
5042,
5485,
5487,
5492,
5521,
5847,
5849,
5854,
5880,
6318,
6320,
6325,
6355,
6796,
6798,
6803,
6831,
7271,
7273,
7278,
7287,
7316,
7768,
7770,
7775,
7802,
8248,
8250,
8255,
8263,
8291,
8730,
8732,
8737,
8746,
8775,
9222,
9224,
9229,
9256,
9707,
9709,
9714,
9723,
9752,
10194,
10196,
10201,
10233,
10652,
10654,
10659,
10687,
10770,
10772,
10777,
10808,
11031,
11032,
11120,
11121
],
"line_end_idx": [
2,
4,
35,
93,
100,
101,
131,
132,
156,
157,
225,
291,
363,
435,
503,
570,
639,
707,
737,
738,
809,
857,
858,
872,
879,
892,
960,
997,
1036,
1037,
1040,
1102,
1103,
1155,
1169,
1217,
1261,
1301,
1324,
1325,
1368,
1377,
1378,
1391,
1459,
1525,
1597,
1669,
1737,
1804,
1873,
1941,
1971,
1974,
2036,
2037,
2051,
2052,
2065,
2133,
2199,
2271,
2343,
2411,
2478,
2547,
2615,
2645,
2646,
2717,
2765,
2820,
2821,
2891,
2952,
2953,
2995,
2996,
3005,
3006,
3020,
3021,
3112,
3113,
3128,
3129,
3131,
3136,
3164,
3580,
3582,
3587,
3627,
4044,
4046,
4051,
4077,
4519,
4521,
4526,
4559,
4998,
5000,
5006,
5014,
5042,
5485,
5487,
5492,
5521,
5847,
5849,
5854,
5880,
6318,
6320,
6325,
6355,
6796,
6798,
6803,
6831,
7271,
7273,
7278,
7287,
7316,
7768,
7770,
7775,
7802,
8248,
8250,
8255,
8263,
8291,
8730,
8732,
8737,
8746,
8775,
9222,
9224,
9229,
9256,
9707,
9709,
9714,
9723,
9752,
10194,
10196,
10201,
10233,
10652,
10654,
10659,
10687,
10770,
10772,
10777,
10808,
11031,
11032,
11120,
11121,
11224
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 11224,
"ccnet_original_nlines": 166,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3969869613647461,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04356677830219269,
"rps_doc_frac_lines_end_with_ellipsis": 0.08383233845233917,
"rps_doc_frac_no_alph_words": 0.18770357966423035,
"rps_doc_frac_unique_words": 0.3453997075557709,
"rps_doc_mean_word_length": 4.3564605712890625,
"rps_doc_num_sentences": 136,
"rps_doc_symbol_to_word_ratio": 0.01017914991825819,
"rps_doc_unigram_entropy": 5.746511936187744,
"rps_doc_word_count": 1989,
"rps_doc_frac_chars_dupe_10grams": 0.19284477829933167,
"rps_doc_frac_chars_dupe_5grams": 0.20046162605285645,
"rps_doc_frac_chars_dupe_6grams": 0.19284477829933167,
"rps_doc_frac_chars_dupe_7grams": 0.19284477829933167,
"rps_doc_frac_chars_dupe_8grams": 0.19284477829933167,
"rps_doc_frac_chars_dupe_9grams": 0.19284477829933167,
"rps_doc_frac_chars_top_2gram": 0.016618579626083374,
"rps_doc_frac_chars_top_3gram": 0.020773230120539665,
"rps_doc_frac_chars_top_4gram": 0.005539529956877232,
"rps_doc_books_importance": -981.0115966796875,
"rps_doc_books_importance_length_correction": -981.0115966796875,
"rps_doc_openwebtext_importance": -779.2844848632812,
"rps_doc_openwebtext_importance_length_correction": -779.2844848632812,
"rps_doc_wikipedia_importance": -535.6785278320312,
"rps_doc_wikipedia_importance_length_correction": -535.6785278320312
},
"fasttext": {
"dclm": 0.018444359302520752,
"english": 0.938904881477356,
"fineweb_edu_approx": 1.3357244729995728,
"eai_general_math": 0.2632989287376404,
"eai_open_web_math": 0.12207341194152832,
"eai_web_code": 0.030338289216160774
}
}
|
{
"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": "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": "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": "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
|
7,964,118,408,971,990,000
|
0
-All of my EOS is staked for CPU and NET bandwidth, should I un-stake some of it first, and how ?
-What command should I execute with a BP to buy, lets say, 600 EOS worth of RAM on an existing account ?
-Am I going to be able to sell the RAM back for EOS once it is used with the airdrop transaction ?
1
I was doing a lot of bidding for eos.names (premium names) and found out quickly that the default 7KB or so RAM that I had was gone!
I used the https://toolkit.genereos.io/tools tools with Scatter to buy RAM using unstaked EOS. And I was able to resume transactions right away.
So what I recommend is as follows:
Of course, if you are out of EOS, then you should unstake first. It will take 3 days to get them back.
2
• Thank you, does the RAM burn out forever, or is it re-usable (lets say, for a Dapp) ? – Damir Olejar Jun 19 '18 at 11:09
• @DisplayName You can send a transaction to the contract that removes the used RAM if provided by the contract. There is an unanswered question: eosio.stackexchange.com/questions/921/… Follow-up there. – friedger Jun 20 '18 at 5:08
Your Answer
By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "https://eosio.stackexchange.com/questions/969/how-do-i-add-more-ram-on-existing-account",
"source_domain": "eosio.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2021-21",
"warc_metadata": {
"Content-Length": "165525",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:M66LW4ZJWOROZMNXQAHLK6MDFIJN5L4Y",
"WARC-Concurrent-To": "<urn:uuid:986c607c-9947-402c-a348-127d82aee7e5>",
"WARC-Date": "2021-05-15T12:09:28Z",
"WARC-IP-Address": "151.101.193.69",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:WUWTEGUYTAC5KEGOFFWPSVTUHNR2EDEC",
"WARC-Record-ID": "<urn:uuid:def7a962-36c7-4830-a713-60682594fbcd>",
"WARC-Target-URI": "https://eosio.stackexchange.com/questions/969/how-do-i-add-more-ram-on-existing-account",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:360e8d41-e04c-47ec-a3be-5eb9010c2546>"
},
"warc_info": "isPartOf: CC-MAIN-2021-21\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2021\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-67.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,
2,
3,
101,
102,
207,
208,
307,
308,
310,
311,
444,
445,
590,
591,
626,
627,
730,
731,
733,
858,
1093,
1094,
1106,
1107,
1207,
1208
],
"line_end_idx": [
2,
3,
101,
102,
207,
208,
307,
308,
310,
311,
444,
445,
590,
591,
626,
627,
730,
731,
733,
858,
1093,
1094,
1106,
1107,
1207,
1208,
1298
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1298,
"ccnet_original_nlines": 26,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.39542484283447266,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.07516340166330338,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.232026144862175,
"rps_doc_frac_unique_words": 0.5882353186607361,
"rps_doc_mean_word_length": 4.147058963775635,
"rps_doc_num_sentences": 18,
"rps_doc_symbol_to_word_ratio": 0.003267969936132431,
"rps_doc_unigram_entropy": 4.6865739822387695,
"rps_doc_word_count": 238,
"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.01418440043926239,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -127.3577880859375,
"rps_doc_books_importance_length_correction": -127.3577880859375,
"rps_doc_openwebtext_importance": -73.3671875,
"rps_doc_openwebtext_importance_length_correction": -73.3671875,
"rps_doc_wikipedia_importance": -48.883323669433594,
"rps_doc_wikipedia_importance_length_correction": -48.88331985473633
},
"fasttext": {
"dclm": 0.1781427264213562,
"english": 0.938914954662323,
"fineweb_edu_approx": 1.0226736068725586,
"eai_general_math": 0.00007652999920537695,
"eai_open_web_math": 0.07039421796798706,
"eai_web_code": -0.000002739999899858958
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "332.874",
"labels": {
"level_1": "Social sciences",
"level_2": "Economics",
"level_3": "Finance"
}
}
},
"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": "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,136,659,029,545,411,800
|
Download (470 KB)
For Minetest 5.0 and above
How do I install this?
Description:
Provides a simple way to change skins on the default character mesh.
Forked from prestidigitator's wardrobe mod.
Note: This only provides the default skin. New skins must be registered with the wardrobe. There are many available on the Addis Open MT-Skin Database. Some skins are provided by wardrobe_outfits.
Licensing:
Usage:
Changing skins is done via a "wardrobe" node, which brings up a form with skin names when you right-click on it. Choosing a skin instantly changes your character's appearance, and this change is kept if you log out.
Registering skins:
There are two ways to register skins:
1. adding the filenames to skins.txt located in this mod's directory or the world path (see "Skins file syntax" below)
2. using the wardrobe.registerSkin method:
wardrobe.registerSkin(texture, displayname)
• texture: real filename of texture (e.g. "my_skin.png")
• displayname: text shown to player (e.g. "My Skin")
Minetest recognizes skins located in a mod's textures sub-directory (e.g. <mod_path>/textures), <minetest_install>/textures, & textures installed to the current user's home directory:
• on Linux/Unix-like systems, this is ~/.minetest/textures
• on Windows, this is %AppData%/Minetest/textures (only if built with -DRUN_IN_PLACE=FALSE flag)
Skins file syntax:
A comment line starts with two dashes (like in Lua), but must be the only thing on the line:
-- This is a comment and has no effect.
Except for empty lines and comments, each line names a texture (file) and a name, separated by optional whitespace and a colon (:):
texture_file_name.png: My Skin skin_other_texture_file_name.png: Other Skin
The first string (e.g. "texture_file_name.png") will be passed to the Minetest API just like any other node or item texture. Generally it is simply the whole file name of an image in a mod "texture" directory or texture pack. The second string (e.g. "My Skin") is presented to the player in-world as the name of the texture. If this name is omitted, as in:
texture_file_name.png skin_other_texture_file_name.png
Then a name is constructed by removing any ".png" suffix any optional "skin_" or "wardrobe_skin_" prefix, and replacing underscores with spaces. So the above skins would be named "texture file name" and "other texture file name", respectively.
To remove a skin that was added elsewhere (for example, to remove a skin in a particular world), prepend a minus sign (-) to the line:
-skin_other_texture_file_name.png
This would remove the "skin_other_texture_file_name.png" skin no matter where it was specified or what name it was given.
Creating a preview image:
If previews are enabled, the mod will use an image following the naming convention <skin_file_name>-preview.png for the preview. If you want to generate a preview from a skin image, I have created a Python script to do so. It requires the ImageMagick executables to be installed.
There are also templates available if you want to create your own skin.
Settings:
wardrobe.skins_per_page
- determines how many skins are shown on each page
- type: int
- min: 1
- max: 8
- default: 8
wardrobe.previews
- determines if preview images are shown in form
- type: bool
- default: true
Crafting:
See: README
Requirements:
Alternative mods:
• wardrobe
• simple_skins
• skinsdb
• skinmaker
• homedecor (homedecor_wardrobe)
Reviews
Review
Do you recommend this mod?
• No reviews, yet.
Used By
|
{
"url": "https://content.minetest.net/packages/AntumDeluge/wardrobe_ad/",
"source_domain": "content.minetest.net",
"snapshot_id": "CC-MAIN-2024-30",
"warc_metadata": {
"Content-Length": "39244",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:A5XHPY76RBZK6YFVFGIRG2EZ2KOQFBFJ",
"WARC-Concurrent-To": "<urn:uuid:182e00f4-10fe-4d05-94e8-adefc649e586>",
"WARC-Date": "2024-07-16T20:43:52Z",
"WARC-IP-Address": "194.36.147.174",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RFWEL7DOAHUPPH5IAWDOKIBAG7KKJLNA",
"WARC-Record-ID": "<urn:uuid:6d55a140-a1b4-4a84-9cfb-89a32421d4ee>",
"WARC-Target-URI": "https://content.minetest.net/packages/AntumDeluge/wardrobe_ad/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d3a3853f-c14d-4156-8cb9-18a46a87e976>"
},
"warc_info": "isPartOf: CC-MAIN-2024-30\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-103\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,
45,
46,
69,
70,
83,
84,
153,
154,
198,
199,
396,
397,
408,
409,
416,
417,
633,
634,
653,
654,
692,
693,
814,
859,
860,
904,
905,
964,
1019,
1020,
1204,
1205,
1266,
1365,
1384,
1385,
1478,
1479,
1519,
1520,
1652,
1653,
1729,
1730,
2087,
2088,
2143,
2144,
2388,
2389,
2524,
2525,
2559,
2560,
2682,
2683,
2709,
2710,
2990,
2991,
3063,
3064,
3074,
3098,
3151,
3168,
3183,
3198,
3213,
3214,
3232,
3283,
3301,
3319,
3329,
3330,
3342,
3343,
3357,
3358,
3376,
3377,
3390,
3407,
3419,
3433,
3468,
3469,
3477,
3478,
3485,
3486,
3513,
3514,
3535,
3536
],
"line_end_idx": [
18,
45,
46,
69,
70,
83,
84,
153,
154,
198,
199,
396,
397,
408,
409,
416,
417,
633,
634,
653,
654,
692,
693,
814,
859,
860,
904,
905,
964,
1019,
1020,
1204,
1205,
1266,
1365,
1384,
1385,
1478,
1479,
1519,
1520,
1652,
1653,
1729,
1730,
2087,
2088,
2143,
2144,
2388,
2389,
2524,
2525,
2559,
2560,
2682,
2683,
2709,
2710,
2990,
2991,
3063,
3064,
3074,
3098,
3151,
3168,
3183,
3198,
3213,
3214,
3232,
3283,
3301,
3319,
3329,
3330,
3342,
3343,
3357,
3358,
3376,
3377,
3390,
3407,
3419,
3433,
3468,
3469,
3477,
3478,
3485,
3486,
3513,
3514,
3535,
3536,
3543
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3543,
"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.3274695575237274,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01217862032353878,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.26251691579818726,
"rps_doc_frac_unique_words": 0.47900763154029846,
"rps_doc_mean_word_length": 5.116412162780762,
"rps_doc_num_sentences": 52,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.083493232727051,
"rps_doc_word_count": 524,
"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.007459899876266718,
"rps_doc_frac_chars_top_3gram": 0.01118985004723072,
"rps_doc_frac_chars_top_4gram": 0.00969787035137415,
"rps_doc_books_importance": -431.4947814941406,
"rps_doc_books_importance_length_correction": -431.4947814941406,
"rps_doc_openwebtext_importance": -217.4423370361328,
"rps_doc_openwebtext_importance_length_correction": -217.4423370361328,
"rps_doc_wikipedia_importance": -130.03993225097656,
"rps_doc_wikipedia_importance_length_correction": -130.03993225097656
},
"fasttext": {
"dclm": 0.01937853917479515,
"english": 0.8098334670066833,
"fineweb_edu_approx": 2.1435277462005615,
"eai_general_math": 0.27384430170059204,
"eai_open_web_math": 0.21235191822052002,
"eai_web_code": 0.16909730434417725
}
}
|
{
"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": "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": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-1,007,094,559,128,700,900
|
Could not load file or assembly or one of its dependencies.
Here is a fix for an error that I received in Visual Studio 2010
The error reads:
Could not load file or assembly ‘file:/// [path to assembly]’ or one of its dependencies. An attempt was made to load a program with an incorrect format. Line 465, position 5.
To fix the problem, I did this:
1. Double-click the error (which was located in the VS2010 Error List Window)
2. After double-clicking the error, the cursor will be placed in an XML closing tag called </data>. From the closing </data> tag, scroll to the opening <data> tag. The <data> tag contents looked like this:
<data name="imageList.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64">
<value>
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w
3. Manually make a change to a part of the string exactly as follows: Change the end of the string from
j00LjAuMC4w to j0yLjAuMC4w
Note that the only change is swapping out the second zero with a ‘y’
4. Rebuild the Visual Studio Solution
Notice! The stream data that you edited was derived from an ImageList that exists in your assembly. So, each and every time you make a change to the ImageList or open the Windows Form (that contains the ImageList) in Designer Mode, you will need to do the above procedure.
This problem occurs when your development machine is running a 64bit OS (I was running Windows Server 2008 RS 64bit). Apparently, what’s happening is Visual Studio is serializing ImageLists with a reference to .NET 4.0 instead of .NET 2. This information is specifically defined at the “j00” section of the serialized data. Changing the data to “j0y” informs ResGen.exe that the ImageList targets .NET 2.
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://albao.wordpress.com/2012/06/27/could-not-load-file-or-assembly-or-one-of-its-dependencies/",
"source_domain": "albao.wordpress.com",
"snapshot_id": "crawl=CC-MAIN-2020-24",
"warc_metadata": {
"Content-Length": "61965",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VJBXLQXKB7FLLH3WYHCKZXF7QPD2JECU",
"WARC-Concurrent-To": "<urn:uuid:212fee7e-8eed-428e-b0b5-60b361aad82d>",
"WARC-Date": "2020-06-01T18:25:08Z",
"WARC-IP-Address": "192.0.78.12",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:UTRFSWPH62PLDFGLYHVIVBMINUAODCBT",
"WARC-Record-ID": "<urn:uuid:2a7386c0-43ce-46f5-aebc-9dd8cb3beaf8>",
"WARC-Target-URI": "https://albao.wordpress.com/2012/06/27/could-not-load-file-or-assembly-or-one-of-its-dependencies/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2c73d6f3-4fce-4d6e-ab01-e6557c929bb8>"
},
"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-84.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,
60,
61,
126,
127,
144,
145,
321,
322,
354,
355,
435,
643,
743,
759,
852,
958,
989,
990,
1063,
1064,
1104,
1105,
1379,
1380,
1785,
1786,
1800,
1801,
1856,
1857,
1876,
1877,
1950,
1951,
1964,
1965,
2031,
2032,
2048,
2049,
2116,
2117,
2132,
2133,
2201,
2202
],
"line_end_idx": [
60,
61,
126,
127,
144,
145,
321,
322,
354,
355,
435,
643,
743,
759,
852,
958,
989,
990,
1063,
1064,
1104,
1105,
1379,
1380,
1785,
1786,
1800,
1801,
1856,
1857,
1876,
1877,
1950,
1951,
1964,
1965,
2031,
2032,
2048,
2049,
2116,
2117,
2132,
2133,
2201,
2202,
2218
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2218,
"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.3273942172527313,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.024498889222741127,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2249443233013153,
"rps_doc_frac_unique_words": 0.4956268072128296,
"rps_doc_mean_word_length": 4.9795918464660645,
"rps_doc_num_sentences": 34,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.730889320373535,
"rps_doc_word_count": 343,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.12060890346765518,
"rps_doc_frac_chars_dupe_6grams": 0.06557376682758331,
"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.014051520265638828,
"rps_doc_frac_chars_top_3gram": 0.037470728158950806,
"rps_doc_frac_chars_top_4gram": 0.04918032884597778,
"rps_doc_books_importance": -152.78395080566406,
"rps_doc_books_importance_length_correction": -152.78395080566406,
"rps_doc_openwebtext_importance": -122.8381118774414,
"rps_doc_openwebtext_importance_length_correction": -122.8381118774414,
"rps_doc_wikipedia_importance": -71.93017578125,
"rps_doc_wikipedia_importance_length_correction": -71.93017578125
},
"fasttext": {
"dclm": 0.5567443370819092,
"english": 0.8242887258529663,
"fineweb_edu_approx": 2.2882792949676514,
"eai_general_math": 0.000017520000255899504,
"eai_open_web_math": 0.18138909339904785,
"eai_web_code": -0.000009299999874201603
}
}
|
{
"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": "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": "6",
"label": "Indeterminate"
}
},
"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": "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
|
-7,281,205,218,951,622,000
|
C3D Toolkit Kernel - 109696, Vision - 2.4.0.76
Shell or set of faces. More...
#include <topology_faceset.h>
+ Inheritance diagram for MbFaceShell:
+ Collaboration diagram for MbFaceShell:
Public Member Functions
MbFaceShell ()
Constructor without parameters.
template<class Faces >
MbFaceShell (const Faces &initFaces)
Constructor by a set of faces.
MbFaceShell (const MbFace &face)
Constructor by face.
MbFaceShell (const MbFaceShell &init)
Constructor by faces of other shell.
virtual ~MbFaceShell ()
Destructor.
virtual MbeTopologyType IsA () const
Functions of shell.
MbFaceShellCopy (MbeCopyMode sameShell, MbShellHistory *history=NULL)
Create a copy. More...
MbFaceShellDuplicate (MbRegDuplicate *iReg=NULL) const
Create a copy. More...
bool IsClosed () const
Is shell closed?
void SetClosed (bool c)
Set shell (un-) closedness.
size_t GetFacesCount () const
Get the number of faces.
ptrdiff_t GetFacesMaxIndex () const
Get the maximum index of a face.
void AddFace (const MbFace &)
Add a face into a shell.
template<class FacesVector >
void AddFaces (const FacesVector &newFaces, bool justAdd)
Add faces into a shell.
void InsertFace (size_t index, const MbFace &)
Insert a face before the face with the given index.
bool ChangeFace (size_t index, const MbFace &)
Replace a face with the given index.
bool DeleteFace (size_t index)
Delete a face at the given index.
bool DeleteFace (const MbFace *)
Delete a face.
MbFaceDetachFace (size_t index)
Detach a face from a shell with the given index.
void DetachFace (const MbFace *)
Detach face.
void DeleteFaces ()
Delete all faces of shell.
void DetachFaces ()
Detach all faces from shell.
template<class FacesVector >
void DetachFaces (FacesVector &detachFaces)
Detach all faces from shell.
bool ExchangeFaces (size_t i1, size_t i2)
Swap shell faces.
void MakeRight (bool setBounds=false)
Set the correct (the current) information in edges about the connected by them faces and parameters of surfaces by loops of faces (setBounds = true).
bool IsRight () const
Are the pointers in edges to the connected by them faces correctly set?
void SetNullToFace (const MbFace *delFace)
Set to null in edges the pointers to a face which is absent face.
void Transform (const MbMatrix3D &matr, MbRegTransform *iReg=NULL)
Transform according to the matrix. More...
void Move (const MbVector3D &to, MbRegTransform *iReg=NULL)
Move along a vector. More...
void Rotate (const MbAxis3D &axis, double angle, MbRegTransform *iReg=NULL)
Rotate around an axis. More...
double DistanceToPoint (const MbCartPoint3D &to) const
Calculate the distance to a point.
void Reverse ()
Revert the shell - reorientation of the whole set of faces.
bool IsSame (const MbFaceShell &faces, double accuracy) const
Determine whether objects are equal.
void SetLabelThrough (MbeLabelState, void *=NULL) const
Set labels for all objects which have them.
void SetLabelThrough (MbeLabelState, void *, bool) const
Set labels for all objects which have them.
void RemovePrivateLabelThrough (void *) const
Remove private labels for all objects which have them.
void SetOwnChangedThrough (MbeChangedType n)
Set flags that objects have been changed.
void ResetFlags (void *=NULL)
Set flags to initial state.
bool UnionWith (MbFaceShell &faces, c3d::FacesSet *sharedSet=NULL)
Move a set of faces to the shell from another shell.
size_t SetVerticesLabel (MbeLabelState, void *=NULL) const
Set the given label for all vertices of the shell.
size_t SetEdgesLabel (MbeLabelState, void *=NULL) const
Set the given label for all edges of the shell.
void SetFacesLabel (MbeLabelState, void *=NULL) const
Set the given label for all faces of the shell.
template<class VerticesVector >
void GetVertices (VerticesVector &) const
Get a set of vertices of the shell.
template<class EdgesVector >
void GetEdges (EdgesVector &edges) const
Get a set of edges of the shell.
template<class FacesVector >
void GetFaces (FacesVector &faces) const
Get a set of faces of the shell.
template<class FacesSet >
void GetFacesSet (FacesSet &faces) const
Get a set of faces of the shell.
template<class VerticesVector , class EdgesVector >
void GetItems (VerticesVector &vertices, EdgesVector &edges) const
Get a set of vertices and a set of edges of the shell.
void GetItems (RPArray< MbTopologyItem > &list) const
Get a set of vertices, a set of edges and a set of faces of the shell.
MbVertexGetVertex (size_t index) const
Get a vertex by an index.
MbCurveEdgeGetEdge (size_t index) const
Get an edge by an index.
MbFaceGetFace (size_t index) const
Get a face by an index.
MbFace_GetFace (size_t index) const
Get a face by an index without a check of index correctness.
const MbSurfaceGetSurface (size_t index) const
Give a surface of a face by an index.
size_t GetVertexIndex (const MbVertex &vertex) const
Get an index of a vertex.
size_t GetEdgeIndex (const MbCurveEdge &edge) const
Get an index of an edge.
size_t GetFaceIndex (const MbFace &face) const
Get an index of a face.
size_t Find (const MbFace *face) const
Find an index of a face in the shell.
size_t GetShellCount () const
Define the number of connected faces describing by the shell.
bool DistanceToShell (const MbFaceShell &shell, double lowerLimitDistance, bool tillFirstLowerLimit, double epsilon, std::vector< MbShellsDistanceData > &shellsDistanceData) const
Calculate the nearest distance to a shell. More...
bool DistanceToBound (const MbCartPoint3D &pnt, double accuracy, MbPntLoc &finFaceData, MbeItemLocation &rShell) const
Define the distance from a point to the shell. More...
bool PointClassification (const MbCartPoint3D &pnt, double accuracy, MbCartPoint3D &shellPoint, MbVector3D &shellNormal, MbeItemLocation &rShell) const
Define the point location relative to the shell. More...
bool PointClassification (const MbCartPoint3D &pnt, double accuracy, MbCartPoint3D &shellPoint, MbVector3D &shellNormal, MbPntLoc &rShell) const
Define the point location relative to the shell. More...
void PointOn (size_t n, double &u, double &v, MbCartPoint3D &p) const
Calculate a point of the shell. More...
void Normal (size_t n, double &u, double &v, MbVector3D &p) const
Calculate a normal of the shell. More...
void NearPointProjection (const MbCartPoint3D &p, SArray< size_t > &nums, SArray< MbCartPoint > &uv) const
Find the point projection to the shell. More...
bool NearPointProjection (const MbCartPoint3D &p, size_t &faceIndex, double &u, double &v) const
Find nearest point projection to the shell. More...
void DirectPointProjection (const MbCartPoint3D &p, const MbVector3D &vect, SArray< size_t > &nums, SArray< MbCartPoint > &uv) const
Find the point projection to the shell along a vector in either of two directions. More...
bool NearDirectPointProjection (const MbCartPoint3D &p, size_t &faceIndex, const MbVector3D &vect, double &u, double &v, bool onlyPositiveDirection=false) const
Find nearest point projection to the shell in the direction of the vector. More...
bool DirectPointProjection (const MbCartPoint3D &p, const MbVector3D &vect) const
Does the projection in direction of the vector exist? More...
void CurveIntersection (const MbCurve3D &curve, SArray< size_t > &nn, SArray< MbCartPoint > &uv, SArray< double > &tt) const
Intersection between a shell and a curve. More...
void AddYourGabaritTo (MbCube &) const
Add your own bounding box into bounding cube.
void CalculateGabarit (MbCube &) const
Calculate bounding box of the shell.
void CalculateLocalGabarit (const MbMatrix3D &matrToLocal, MbCube &cube) const
Calculate bounding box in the local coordinate system which is given by the matrix 'matrToLocal ' of transformation to it.
void CalculateLocalGabarit (const MbPlacement3D &localPlace, MbCube &cube) const
Calculate bounding box in the local coordinate system 'localPlace'.
void CalculateMesh (const MbStepData &stepData, const MbFormNote ¬e, MbMesh &mesh) const
Construct a polygonal copy of the shell. More...
void GetProperties (MbProperties &)
Get properties of the object.
void SetProperties (const MbProperties &)
Set properties of the object.
void SetMainName (SimpleName newMainName, bool addOldMainName)
Set the main name and insert an old name to the copy index. More...
void SetNamesCopyIndex (SimpleName index)
Insert copying index. More...
void SetNamesCopyIndex (SimpleName index, const SimpleName &newMainName)
Replace main name by new one, insert old main name and given copy index into name copy indices. More...
void MakeNewNames (SimpleName mainName, SimpleName modifier)
Set the main name and modify names of faces, edges and vertices for the shell-copy in order to prevent coincidence of several copies names.
void MakeNewNames (const MbSNameMaker &, SimpleName modifier)
Set the main name and modify names of faces for the shell-copy in order to prevent coincidence of several copies names.
void SetShellNames (const MbSNameMaker &)
Rename faces, edges and vertices of the shell.
void SetShellNames (const MbFaceShell &)
Name shell elements by names of the shell 's'.
void ClearShellNames ()
Clear all shell names. More...
void ClearEdgesNames (bool clearVerticesNames=true)
Clear all shell edges names.
MbResultType CheckTopology (MbCheckTopologyParams &checkParams)
Validation of the shell: vertices (deletion of coincident and extra), edges (with merge). More...
void CheckClosed (bool checkChangedOnly=false)
Check shell closedness with flag modification.
bool MakeBoundaryCurve ()
Find the boundary edges, make their curve boundary.
template<class ConstEdgesVector >
bool GetBoundaryEdges (ConstEdgesVector &) const
Get boundary edges of the shell.
bool FindFacesIndexByEdges (const RPArray< MbCurveEdge > &init, SArray< MbEdgeFacesIndexes > &indexes, bool any=false) const
For a set of edges find their indices and indices of their faces.
bool FindFacesIndexByEdges (const SArray< MbEdgeFunction > &init, RPArray< MbFunction > &functions, SArray< MbEdgeFacesIndexes > &indexes) const
For a set of structures (edges and functions of radii changing) find indices of edges and their faces.
bool FindEdgesByFacesIndex (const SArray< MbEdgeFacesIndexes > &indexes, RPArray< MbFunction > *functions, RPArray< MbCurveEdge > &initCurves, RPArray< MbFunction > &initFunctions) const
For a set of edge indices and indices of their faces find edges.
bool FindFacesIndexByEdge (const MbCurveEdge &edge, size_t &ind1, size_t &ind2, bool any=false) const
Find faces indices by the edge.
bool FindFacesIndexByFaces (const RPArray< MbFace > &init, SArray< size_t > &ind0) const
For a set of faces find a set of their indices.
template<class FacesPointersVector , class ItemIndices >
bool FindIndexByFaces (const FacesPointersVector &, ItemIndices &, size_t mapThreshold=50) const
For a set of faces find a set of their combined indices.
template<class ItemIndices , class ConstFacesPointersVector >
bool FindConstFacesByIndex (const ItemIndices &, ConstFacesPointersVector &) const
Find a set of faces by a set of combined indices.
bool FindIndexByVertices (const RPArray< MbVertex > &init, SArray< MbItemIndex > &indexes) const
For a set of vertices find a set of their combined indices.
bool FindVerticesByIndex (const SArray< MbItemIndex > &indexes, RPArray< MbVertex > &init) const
Find a set of vertices by a set of combined indices.
bool FindIndexByFace (const MbFace &, MbItemIndex &) const
Find combined index of a face.
const MbFaceFindFaceByIndex (MbItemIndex &) const
Find a face by combined index.
MbFaceFindFaceByIndex (MbItemIndex &)
Find a face by combined index.
void FindEdgesForVertex (const MbVertex &vertex, RPArray< MbCurveEdge > &findEdges) const
Find a set of edges with the common given vertex.
void FindFacesForVertex (const MbVertex &vertex, RPArray< MbFace > &findFaces) const
Find a set of faces with the common given vertex.
bool FindEdgeNumbers (const MbCurveEdge &edge, size_t &faceN, size_t &loopN, size_t &edgeN) const
For the edge 'edge' find an index of face, an index of loop and an index of edge in this loop.
const MbVertexFindVertexByName (const MbName &) const
Find vertex by name.
const MbCurveEdgeFindEdgeByName (const MbName &) const
Find edge by name.
const MbFaceFindFaceByName (const MbName &) const
Find face by name.
MbVertexFindVertexByName (const MbName &)
Find vertex by name.
MbCurveEdgeFindEdgeByName (const MbName &)
Find edge by name.
MbFaceFindFaceByName (const MbName &)
Find face by name.
bool MergeSimilarFaces (SimpleName simMainName=SIMPLENAME_MAX)
Merge similar faces. More...
bool IsTemporal () const
Is a temporary object for the maintenance created?
void RemoveTemporal () const
Delete a temporary maintenance object.
const MbFaceSetTemp * CreateTemporal (bool keepExisting) const
Create new temporary maintenance object.
bool UpdateTemporal (bool changedOnly=false) const
Update a temporary maintenance object of a face. changedOnly = true can only be used intact shell (after cutting edges).
bool IsTemporal (size_t k) const
Is a temporary object for the maintenance of a face created?
bool CreateTemporal (size_t k, bool keepExisting) const
Get a temporary maintenance object of a face.
void RemoveParentNamesAttributes ()
Delete attributes of name type with parent names.
- Public Member Functions inherited from MbTopItem
virtual MbeRefType RefType () const
Registration type (for copying, duplication).
void PrepareWrite () const
Prepare an object for writing.
bool IsAVertex () const
Is it a vertex?
bool IsAWireEdge () const
Is it an edge of wireframe?
bool IsAnEdge () const
Is it an edge?
bool IsAFace () const
Is it a face?
bool IsAShell () const
Is it a shell?
- Public Member Functions inherited from MbRefItem
MbRefItem ()
Constructor without parameters.
refcount_t GetUseCount () const
Get count of references (get count of owners of an object).
refcount_t AddRef () const
Increase count of references by one.
refcount_t DecRef () const
Decrease count of references by one.
refcount_t Release () const
Decrease count of references by one and if count of references became zero, then remove itself.
- Public Member Functions inherited from TapeBase
TapeBase (RegistrableRec regs=noRegistrable)
Constructor.
TapeBase (const TapeBase &)
Copy-constructor.
virtual ~TapeBase ()
Destructor.
RegistrableRec GetRegistrable () const
Whether the stream class is registrable.
void SetRegistrable (RegistrableRec regs=registrable) const
Set the state of registration of the stream class.
virtual const char * GetPureName (const VersionContainer &) const
Get the class name.
virtual bool IsFamilyRegistrable () const
Whether the object belongs to a registrable family.
- Public Member Functions inherited from MbSyncItem
void Lock () const
Switch lock on (locking happens only in parallel region).
void Unlock () const
Switch lock off if locking has been set.
Protected Attributes
RPArray< MbFacefaceSet
A set of faces.
bool closed
An attribute of closedness indicates the absence of boundary.
Additional Inherited Members
- Protected Member Functions inherited from MbTopItem
MbTopItem ()
Constructor.
Detailed Description
Shell or set of faces.
A shell is a composite surface formed by finite set of faces MbFace, connected together by edges MbCurveEdge.
In general case a shell may be multiply connected, i.e. it may describe several pairwise not connected surfaces.
A shell is called closed if it has not a boundary, otherwise a shell is called unclosed.
The closedness of a shell indicates the possibility of using of a set of its internal points in operations with solids MbSolid. Formally, a set of faces is not restricted by any conditions, but actually faces of the set satisfy certain conditions. In order to highlight this feature of a shell, the concept "manifold shell" is introduced. Shells which satisfy the below requirements are called manifold.
1. Shells are finite.
2. Shells do not intersect themselves.
3. Shells are two-sided (oriented).
4. At each edge of a shell not more than two faces are connected. Two faces of shell connected in such way, that the external side of one face turns to the external side of another face.
5. With any go-round of any vertex of closed shell on its surface, one will visit all faces connected with this vertex of a face and intersect all outgoing edges.
Since the external side of a face turns to the external side of adjacent face, a manifold shell also has the external and internal sides. A closed manifold shell divides the three-dimensional space into two parts, one of which is located inside the shell. Let closed manifold shell be called external shell, if its external side is directed out from a part of space bounding by the shell.
Let closed manifold shell be called an internal shell, if its external side is directed inside a part of space bounding by the shell.
Member Function Documentation
◆ Copy()
MbFaceShell* MbFaceShell::Copy ( MbeCopyMode sameShell,
MbShellHistory history = NULL
)
Create a copy.
Create a copy of a shell with copying of a part of data and moving another part of data from the original to the copy.
The parameter 'history' is used if the copying mode is cm_KeepHistory.
Parameters
[in]sameShell- A way of data transferring when copying of a shell MbeCopyMode:
sameShell == cm_Same - an initial shell is returned as the copy (a shell is not copied but the pointers of edges to the faces are correctly set);
sameShell == cm_KeepHistory - a part of data is copied (the initial shell and its copy have the common basis surfaces and vertices) and the sets of faces of the object 'history' are filled;
sameShell == cm_KeepSurface - a part of data is copied (the initial shell and its copy have the common basis surfaces);
sameShell == cm_Copy - an ordinary copying (the initial shell and its copy have no the common data).
[in]history- A history of faces copies is used after the operation for the replacement of unchanged copies by their originals.
Returns
Copy of an object or original (in a case of the mode cm_Same).
◆ Duplicate()
MbFaceShell* MbFaceShell::Duplicate ( MbRegDuplicate iReg = NULL) const
Create a copy.
Create a copy of a shell with registrator.
Returns
Copy of the object.
◆ Transform()
void MbFaceShell::Transform ( const MbMatrix3D matr,
MbRegTransform iReg = NULL
)
Transform according to the matrix.
The transformation of a shell according to a matrix. In a shell the same geometric objects, for example, surfaces, are used in both faces and in edges. For the transformation of each geometric object only once a registrator is used.
Parameters
[in]matr- A transformation matrix.
[in]iReg- Registrator of objects:
◆ Move()
void MbFaceShell::Move ( const MbVector3D to,
MbRegTransform iReg = NULL
)
Move along a vector.
Move of a shell along a vector. In a shell the same geometric objects, for example, faces, are used in both faces and in edges. For the transformation of each geometric object only once a registrator is used.
Parameters
[in]to- Translation vector.
[in]iReg- Registrator.
◆ Rotate()
void MbFaceShell::Rotate ( const MbAxis3D axis,
double angle,
MbRegTransform iReg = NULL
)
Rotate around an axis.
The rotation of a shell around an axis. In a shell the same geometric objects, for example, faces, are used in both faces and in edges. For the transformation of each geometric object only once a registrator is used.
Parameters
[in]axis- The rotation axis.
[in]angle- The rotation angle.
[in]iReg- Registrator.
◆ DistanceToShell()
bool MbFaceShell::DistanceToShell ( const MbFaceShell shell,
double lowerLimitDistance,
bool tillFirstLowerLimit,
double epsilon,
std::vector< MbShellsDistanceData > & shellsDistanceData
) const
Calculate the nearest distance to a shell.
Calculate the nearest distance to a shell with a specified tolerance with the same coordinate system. In case of intersection or tangent of the shells returns to zero distance.
Note
When multiply use shell, you should create objects for maintenance this shell and its faces.
Parameters
[in]shell- Shell.
[in]lowerLimitDistance- Minimum allowed distance.
[in]tillFirstLowerLimit- Stop the search after the first found distance is less or equal than to the minimum allowable.
[in]epsilon- Accuracy of distanse between shell face surfaces.
[out]shellsDistanceData- The data of nearest distance beetwen shells.
Returns
Whether the minimum distance between shells was successfully defined.
◆ DistanceToBound()
bool MbFaceShell::DistanceToBound ( const MbCartPoint3D pnt,
double accuracy,
MbPntLoc finFaceData,
MbeItemLocation rShell
) const
Define the distance from a point to the shell.
Define the distance from a point to the shell and location of a point: outside the shell, on the shell, inside the shell.
Parameters
[in]pnt- Point.
[in]accuracy- A given tolerance for the location definition.
[out]finFaceData- An information about surroundings of the point 'pnt' projection to the nearest face of the shell.
[out]rShell- The result of definition: outside the shell (-1), on the shell (0), inside the shell (+1).
Returns
Whether the distance from a point to the shell was successfully defined..
◆ PointClassification() [1/2]
bool MbFaceShell::PointClassification ( const MbCartPoint3D pnt,
double accuracy,
MbCartPoint3D shellPoint,
MbVector3D shellNormal,
MbeItemLocation rShell
) const
Define the point location relative to the shell.
Define the point location relative to the shell: outside the shell, on the shell, inside the shell.
Parameters
[in]pnt- Point.
[in]accuracy- A given tolerance for the location definition.
[out]shellPoint- A point on the shell which is the nearest to the point 'pnt'.
[out]shellNormal- A normal to the nearest to the 'pnt' point on the shell.
[out]rShell- The result of definition: outside the shell (-1), on the shell (0), inside the shell (+1).
Returns
Whether the point location relative to the shell was successfully defined.
◆ PointClassification() [2/2]
bool MbFaceShell::PointClassification ( const MbCartPoint3D pnt,
double accuracy,
MbCartPoint3D shellPoint,
MbVector3D shellNormal,
MbPntLoc rShell
) const
Define the point location relative to the shell.
Define the point location relative to the shell: outside the shell, on the shell, inside the shell.
Parameters
[in]pnt- Point.
[in]accuracy- A given tolerance for the location definition.
[out]shellPoint- A point on the shell which is the nearest to the point 'pnt'.
[out]shellNormal- A normal to the nearest to the 'pnt' point on the shell.
[out]rShell- The point location relative to the shell.
Returns
Whether the point location relative to the shell was successfully defined.
◆ PointOn()
void MbFaceShell::PointOn ( size_t n,
double & u,
double & v,
MbCartPoint3D p
) const
Calculate a point of the shell.
Calculate a point for the given face by the given parameters of its surface.
Parameters
[in]n- An index of a face of the shell.
[in]u- The first parameter of the face surface.
[in]v- The second parameter of the face surface.
[out]p- Calculated point of the shell.
◆ Normal()
void MbFaceShell::Normal ( size_t n,
double & u,
double & v,
MbVector3D p
) const
Calculate a normal of the shell.
Calculate a normal of the shell for the given face by the given parameters of its surface.
Parameters
[in]n- An index of a face of the shell.
[in]u- The first parameter of the face surface.
[in]v- The second parameter of the face surface.
[out]p- Calculated normal of the shell.
◆ NearPointProjection() [1/2]
void MbFaceShell::NearPointProjection ( const MbCartPoint3D p,
SArray< size_t > & nums,
SArray< MbCartPoint > & uv
) const
Find the point projection to the shell.
Find all point projections to all faces of the shell.
Parameters
[in]p- A point to project.
[out]nums- An array of faces numbers in the shell, synchronized with the array of projections parameters
[out]uv- An array of projections parameters.
◆ NearPointProjection() [2/2]
bool MbFaceShell::NearPointProjection ( const MbCartPoint3D p,
size_t & faceIndex,
double & u,
double & v
) const
Find nearest point projection to the shell.
Find face index and surface parameters for the nearest point projection to the shell.
Parameters
[in]p- A point to project.
[out]faceIndex- The index of nearest face of the shell.
[out]u- The first parameter of the face surface for the nearest projection.
[out]v- The second parameter of the face surface for the nearest projection.
Returns
Whether the point projection was successfully defined.
◆ DirectPointProjection() [1/2]
void MbFaceShell::DirectPointProjection ( const MbCartPoint3D p,
const MbVector3D vect,
SArray< size_t > & nums,
SArray< MbCartPoint > & uv
) const
Find the point projection to the shell along a vector in either of two directions.
Find all point projections to all faces of the shell along a vector in either of two directions.
Parameters
[in]p- A point to project.
[in]vect- The vector of direction.
[out]nums- An array of faces numbers in the shell, synchronized with the array of projections parameters
[out]uv- An array of projections parameters.
◆ NearDirectPointProjection()
bool MbFaceShell::NearDirectPointProjection ( const MbCartPoint3D p,
size_t & faceIndex,
const MbVector3D vect,
double & u,
double & v,
bool onlyPositiveDirection = false
) const
Find nearest point projection to the shell in the direction of the vector.
Find face index and surface parameters for the nearest point projection to the shell in the direction of the vector.
Parameters
[in]p- A point to project.
[out]faceIndex- The index of nearest face of the shell.
[in]vect- The vector of direction.
[out]u- The first parameter of the face surface for the nearest projection in the direction of the vector.
[out]v- The second parameter of the face surface for the nearest projection in the direction of the vector.
[in]onlyPositiveDirection- Find in the positive direction of vector vect from point p
Returns
Whether the point projection was successfully defined.
◆ DirectPointProjection() [2/2]
bool MbFaceShell::DirectPointProjection ( const MbCartPoint3D p,
const MbVector3D vect
) const
Does the projection in direction of the vector exist?
Define whether at least one projection of a point to the shell in direction of the vector exists.
Parameters
[in]p- A point to project.
[in]vect- A vector which defines the direction of projection.
Returns
True if at least one projection is found.
◆ CurveIntersection()
void MbFaceShell::CurveIntersection ( const MbCurve3D curve,
SArray< size_t > & nn,
SArray< MbCartPoint > & uv,
SArray< double > & tt
) const
Intersection between a shell and a curve.
Find intersections between a curve and faces of a shell.
Parameters
[in]curve- Curve.
[out]nn- Indices of shell faces that have intersections with the curve.
[out]uv- Parametric points of intersections on faces' surfaces.
[out]tt- Intersection parameters on the curve.
◆ CalculateMesh()
void MbFaceShell::CalculateMesh ( const MbStepData stepData,
const MbFormNote note,
MbMesh mesh
) const
Construct a polygonal copy of the shell.
Construct a polygonal copy of a shell and fill a polygonal object (a mesh) by it.
Note
In multithreaded mode m_Items runs in parallel.
Parameters
[in]stepData- Data for step calculation during triangulation.
[in]note- Way for polygonal object constructing.
[out]mesh- A polygonal object that being filled.
◆ SetMainName()
void MbFaceShell::SetMainName ( SimpleName newMainName,
bool addOldMainName
)
Set the main name and insert an old name to the copy index.
Set the main name and insert an old name to the copy index. Objects with empty names are skipped.
Parameters
[in]newMainName- The new main name.
[in]addOldMainName- Insert an old name to the copy index.
◆ SetNamesCopyIndex() [1/2]
void MbFaceShell::SetNamesCopyIndex ( SimpleName index)
Insert copying index.
Insert copying index.
Parameters
[in]index- Copying index.
◆ SetNamesCopyIndex() [2/2]
void MbFaceShell::SetNamesCopyIndex ( SimpleName index,
const SimpleName newMainName
)
Replace main name by new one, insert old main name and given copy index into name copy indices.
Replace main name by new one, insert old main name and given copy index into name copy indices. Objects with empty names are skipped.
Parameters
[in]index- Copying index.
[in]newMainName- The new main name.
◆ ClearShellNames()
void MbFaceShell::ClearShellNames ( )
Clear all shell names.
Clear the names of all shell elements: faces, edges, and vertices.
◆ CheckTopology()
MbResultType MbFaceShell::CheckTopology ( MbCheckTopologyParams checkParams)
Validation of the shell: vertices (deletion of coincident and extra), edges (with merge).
Validation of the shell: vertices (deletion of coincident and extra), edges (with merge).
Parameters
[in]checkParams- Function parameters.
◆ MergeSimilarFaces()
bool MbFaceShell::MergeSimilarFaces ( SimpleName simMainName = SIMPLENAME_MAX)
Merge similar faces.
Merge similar faces.
Parameters
[in]simMainName- The new primary name for the merged faces (if it is not equal to SIMPLENAME_MAX).
The documentation for this class was generated from the following file:
|
{
"url": "https://c3d.ascon.net/doc/math/class_mb_face_shell.html",
"source_domain": "c3d.ascon.net",
"snapshot_id": "crawl=CC-MAIN-2020-16",
"warc_metadata": {
"Content-Length": "160747",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:6DTLOMDLC4GRDUGCUXYQTSA3CEEYBKTS",
"WARC-Concurrent-To": "<urn:uuid:f5ea932b-1d89-46c6-a25c-e819d1c95b8b>",
"WARC-Date": "2020-04-04T20:09:15Z",
"WARC-IP-Address": "213.33.246.221",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:64QN6GN2QMAWL5QAF53UMCOABLVEO665",
"WARC-Record-ID": "<urn:uuid:0e209ae4-a19d-4e99-8805-b6283ad96d69>",
"WARC-Target-URI": "https://c3d.ascon.net/doc/math/class_mb_face_shell.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e7be09ea-7f1c-433d-9f95-57137e84c5ca>"
},
"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-81.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,
48,
49,
80,
81,
111,
112,
151,
192,
193,
217,
218,
234,
267,
269,
292,
330,
362,
364,
398,
420,
422,
461,
499,
501,
525,
538,
540,
577,
598,
600,
670,
694,
696,
751,
775,
777,
800,
818,
820,
844,
873,
875,
905,
931,
933,
969,
1003,
1005,
1035,
1061,
1063,
1092,
1150,
1175,
1177,
1224,
1277,
1279,
1326,
1364,
1366,
1397,
1432,
1434,
1467,
1483,
1485,
1517,
1567,
1569,
1602,
1616,
1618,
1638,
1666,
1668,
1688,
1718,
1720,
1749,
1793,
1823,
1825,
1867,
1886,
1888,
1926,
2077,
2079,
2101,
2174,
2176,
2219,
2286,
2288,
2355,
2399,
2401,
2461,
2491,
2493,
2569,
2601,
2603,
2658,
2694,
2696,
2712,
2773,
2775,
2837,
2875,
2877,
2933,
2978,
2980,
3037,
3082,
3084,
3130,
3186,
3188,
3233,
3276,
3278,
3308,
3337,
3339,
3406,
3460,
3462,
3521,
3573,
3575,
3631,
3680,
3682,
3736,
3785,
3787,
3819,
3861,
3898,
3900,
3929,
3970,
4004,
4006,
4035,
4076,
4110,
4112,
4138,
4179,
4213,
4215,
4267,
4334,
4390,
4392,
4446,
4518,
4520,
4559,
4586,
4588,
4628,
4654,
4656,
4691,
4716,
4718,
4754,
4816,
4818,
4865,
4904,
4906,
4959,
4986,
4988,
5040,
5066,
5068,
5115,
5140,
5142,
5181,
5220,
5222,
5252,
5315,
5317,
5497,
5549,
5551,
5670,
5726,
5728,
5880,
5938,
5940,
6085,
6143,
6145,
6215,
6256,
6258,
6324,
6366,
6368,
6475,
6524,
6526,
6623,
6676,
6678,
6811,
6903,
6905,
7066,
7150,
7152,
7234,
7297,
7299,
7424,
7475,
7477,
7516,
7563,
7565,
7604,
7642,
7644,
7723,
7847,
7849,
7930,
7999,
8001,
8093,
8143,
8145,
8181,
8212,
8214,
8256,
8287,
8289,
8352,
8421,
8423,
8465,
8496,
8498,
8571,
8676,
8678,
8739,
8880,
8882,
8944,
9065,
9067,
9109,
9157,
9159,
9200,
9248,
9250,
9274,
9306,
9308,
9360,
9390,
9392,
9456,
9555,
9557,
9604,
9652,
9654,
9680,
9733,
9735,
9769,
9818,
9852,
9854,
9979,
10046,
10048,
10193,
10297,
10299,
10486,
10552,
10554,
10656,
10689,
10691,
10780,
10829,
10831,
10888,
10985,
11043,
11045,
11107,
11190,
11241,
11243,
11340,
11401,
11403,
11500,
11554,
11556,
11615,
11647,
11649,
11699,
11731,
11733,
11771,
11803,
11805,
11895,
11946,
11948,
12033,
12084,
12086,
12184,
12280,
12282,
12336,
12358,
12360,
12415,
12435,
12437,
12487,
12507,
12509,
12551,
12573,
12575,
12618,
12638,
12640,
12678,
12698,
12700,
12763,
12793,
12795,
12820,
12872,
12874,
12903,
12943,
12945,
13008,
13050,
13052,
13103,
13225,
13227,
13260,
13322,
13324,
13380,
13427,
13429,
13465,
13516,
13518,
13569,
13605,
13652,
13654,
13681,
13713,
13715,
13739,
13756,
13758,
13784,
13813,
13815,
13838,
13854,
13856,
13878,
13893,
13895,
13918,
13934,
13936,
13987,
14001,
14034,
14036,
14068,
14129,
14131,
14158,
14196,
14198,
14225,
14263,
14265,
14293,
14390,
14392,
14442,
14488,
14502,
14504,
14533,
14552,
14554,
14575,
14588,
14590,
14629,
14671,
14673,
14733,
14785,
14787,
14853,
14874,
14876,
14918,
14971,
14973,
15025,
15044,
15103,
15105,
15126,
15168,
15170,
15171,
15192,
15193,
15216,
15233,
15235,
15247,
15310,
15312,
15313,
15342,
15343,
15397,
15411,
15425,
15427,
15428,
15449,
15450,
15473,
15474,
15584,
15697,
15786,
16190,
16191,
16215,
16256,
16294,
16483,
16648,
17041,
17179,
17180,
17210,
17211,
17220,
17221,
17278,
17309,
17311,
17312,
17327,
17328,
17447,
17518,
17519,
17530,
17609,
17755,
17945,
18065,
18166,
18293,
18301,
18364,
18365,
18379,
18380,
18452,
18453,
18468,
18469,
18512,
18513,
18521,
18541,
18542,
18556,
18557,
18610,
18638,
18640,
18641,
18676,
18677,
18910,
18911,
18922,
18957,
18991,
18992,
19001,
19002,
19048,
19076,
19078,
19079,
19100,
19101,
19310,
19311,
19322,
19350,
19373,
19374,
19385,
19386,
19434,
19449,
19477,
19479,
19480,
19503,
19504,
19721,
19722,
19733,
19762,
19793,
19816,
19817,
19837,
19838,
19899,
19927,
19954,
19971,
20030,
20038,
20039,
20082,
20083,
20260,
20261,
20266,
20359,
20370,
20388,
20438,
20558,
20621,
20691,
20699,
20769,
20770,
20790,
20791,
20852,
20870,
20892,
20916,
20924,
20925,
20972,
20973,
21095,
21096,
21107,
21123,
21184,
21300,
21404,
21412,
21486,
21487,
21517,
21518,
21583,
21601,
21627,
21651,
21675,
21683,
21684,
21733,
21734,
21834,
21835,
21846,
21862,
21923,
22002,
22077,
22181,
22189,
22264,
22265,
22295,
22296,
22361,
22379,
22405,
22429,
22446,
22454,
22455,
22504,
22505,
22605,
22606,
22617,
22633,
22694,
22773,
22848,
22903,
22911,
22986,
22987,
22999,
23000,
23039,
23052,
23065,
23082,
23090,
23091,
23123,
23124,
23201,
23202,
23213,
23253,
23301,
23350,
23389,
23390,
23401,
23402,
23440,
23453,
23466,
23480,
23488,
23489,
23522,
23523,
23614,
23615,
23626,
23666,
23714,
23763,
23803,
23804,
23834,
23835,
23898,
23924,
23953,
23961,
23962,
24002,
24003,
24057,
24058,
24069,
24096,
24201,
24246,
24247,
24277,
24278,
24341,
24362,
24375,
24388,
24396,
24397,
24441,
24442,
24528,
24529,
24540,
24567,
24623,
24699,
24776,
24784,
24839,
24840,
24872,
24873,
24938,
24961,
24987,
25016,
25024,
25025,
25108,
25109,
25206,
25207,
25218,
25245,
25280,
25385,
25430,
25431,
25461,
25462,
25531,
25552,
25575,
25588,
25601,
25638,
25646,
25647,
25722,
25723,
25840,
25841,
25852,
25879,
25935,
25970,
26077,
26185,
26271,
26279,
26334,
26335,
26367,
26368,
26433,
26456,
26464,
26465,
26519,
26520,
26618,
26619,
26630,
26657,
26719,
26727,
26769,
26770,
26792,
26793,
26854,
26878,
26907,
26931,
26939,
26940,
26982,
26983,
27040,
27041,
27052,
27070,
27142,
27206,
27253,
27254,
27272,
27273,
27334,
27357,
27370,
27378,
27379,
27420,
27421,
27503,
27504,
27509,
27557,
27568,
27630,
27679,
27728,
27729,
27745,
27746,
27803,
27825,
27827,
27828,
27888,
27889,
27987,
27988,
27999,
28035,
28093,
28094,
28122,
28123,
28180,
28181,
28203,
28204,
28226,
28227,
28238,
28264,
28265,
28293,
28294,
28351,
28381,
28383,
28384,
28480,
28481,
28615,
28616,
28627,
28653,
28689,
28690,
28710,
28711,
28749,
28750,
28773,
28774,
28841,
28842,
28860,
28861,
28938,
28939,
29029,
29030,
29120,
29121,
29132,
29170,
29171,
29193,
29194,
29274,
29275,
29296,
29297,
29318,
29319,
29330,
29429,
29430
],
"line_end_idx": [
48,
49,
80,
81,
111,
112,
151,
192,
193,
217,
218,
234,
267,
269,
292,
330,
362,
364,
398,
420,
422,
461,
499,
501,
525,
538,
540,
577,
598,
600,
670,
694,
696,
751,
775,
777,
800,
818,
820,
844,
873,
875,
905,
931,
933,
969,
1003,
1005,
1035,
1061,
1063,
1092,
1150,
1175,
1177,
1224,
1277,
1279,
1326,
1364,
1366,
1397,
1432,
1434,
1467,
1483,
1485,
1517,
1567,
1569,
1602,
1616,
1618,
1638,
1666,
1668,
1688,
1718,
1720,
1749,
1793,
1823,
1825,
1867,
1886,
1888,
1926,
2077,
2079,
2101,
2174,
2176,
2219,
2286,
2288,
2355,
2399,
2401,
2461,
2491,
2493,
2569,
2601,
2603,
2658,
2694,
2696,
2712,
2773,
2775,
2837,
2875,
2877,
2933,
2978,
2980,
3037,
3082,
3084,
3130,
3186,
3188,
3233,
3276,
3278,
3308,
3337,
3339,
3406,
3460,
3462,
3521,
3573,
3575,
3631,
3680,
3682,
3736,
3785,
3787,
3819,
3861,
3898,
3900,
3929,
3970,
4004,
4006,
4035,
4076,
4110,
4112,
4138,
4179,
4213,
4215,
4267,
4334,
4390,
4392,
4446,
4518,
4520,
4559,
4586,
4588,
4628,
4654,
4656,
4691,
4716,
4718,
4754,
4816,
4818,
4865,
4904,
4906,
4959,
4986,
4988,
5040,
5066,
5068,
5115,
5140,
5142,
5181,
5220,
5222,
5252,
5315,
5317,
5497,
5549,
5551,
5670,
5726,
5728,
5880,
5938,
5940,
6085,
6143,
6145,
6215,
6256,
6258,
6324,
6366,
6368,
6475,
6524,
6526,
6623,
6676,
6678,
6811,
6903,
6905,
7066,
7150,
7152,
7234,
7297,
7299,
7424,
7475,
7477,
7516,
7563,
7565,
7604,
7642,
7644,
7723,
7847,
7849,
7930,
7999,
8001,
8093,
8143,
8145,
8181,
8212,
8214,
8256,
8287,
8289,
8352,
8421,
8423,
8465,
8496,
8498,
8571,
8676,
8678,
8739,
8880,
8882,
8944,
9065,
9067,
9109,
9157,
9159,
9200,
9248,
9250,
9274,
9306,
9308,
9360,
9390,
9392,
9456,
9555,
9557,
9604,
9652,
9654,
9680,
9733,
9735,
9769,
9818,
9852,
9854,
9979,
10046,
10048,
10193,
10297,
10299,
10486,
10552,
10554,
10656,
10689,
10691,
10780,
10829,
10831,
10888,
10985,
11043,
11045,
11107,
11190,
11241,
11243,
11340,
11401,
11403,
11500,
11554,
11556,
11615,
11647,
11649,
11699,
11731,
11733,
11771,
11803,
11805,
11895,
11946,
11948,
12033,
12084,
12086,
12184,
12280,
12282,
12336,
12358,
12360,
12415,
12435,
12437,
12487,
12507,
12509,
12551,
12573,
12575,
12618,
12638,
12640,
12678,
12698,
12700,
12763,
12793,
12795,
12820,
12872,
12874,
12903,
12943,
12945,
13008,
13050,
13052,
13103,
13225,
13227,
13260,
13322,
13324,
13380,
13427,
13429,
13465,
13516,
13518,
13569,
13605,
13652,
13654,
13681,
13713,
13715,
13739,
13756,
13758,
13784,
13813,
13815,
13838,
13854,
13856,
13878,
13893,
13895,
13918,
13934,
13936,
13987,
14001,
14034,
14036,
14068,
14129,
14131,
14158,
14196,
14198,
14225,
14263,
14265,
14293,
14390,
14392,
14442,
14488,
14502,
14504,
14533,
14552,
14554,
14575,
14588,
14590,
14629,
14671,
14673,
14733,
14785,
14787,
14853,
14874,
14876,
14918,
14971,
14973,
15025,
15044,
15103,
15105,
15126,
15168,
15170,
15171,
15192,
15193,
15216,
15233,
15235,
15247,
15310,
15312,
15313,
15342,
15343,
15397,
15411,
15425,
15427,
15428,
15449,
15450,
15473,
15474,
15584,
15697,
15786,
16190,
16191,
16215,
16256,
16294,
16483,
16648,
17041,
17179,
17180,
17210,
17211,
17220,
17221,
17278,
17309,
17311,
17312,
17327,
17328,
17447,
17518,
17519,
17530,
17609,
17755,
17945,
18065,
18166,
18293,
18301,
18364,
18365,
18379,
18380,
18452,
18453,
18468,
18469,
18512,
18513,
18521,
18541,
18542,
18556,
18557,
18610,
18638,
18640,
18641,
18676,
18677,
18910,
18911,
18922,
18957,
18991,
18992,
19001,
19002,
19048,
19076,
19078,
19079,
19100,
19101,
19310,
19311,
19322,
19350,
19373,
19374,
19385,
19386,
19434,
19449,
19477,
19479,
19480,
19503,
19504,
19721,
19722,
19733,
19762,
19793,
19816,
19817,
19837,
19838,
19899,
19927,
19954,
19971,
20030,
20038,
20039,
20082,
20083,
20260,
20261,
20266,
20359,
20370,
20388,
20438,
20558,
20621,
20691,
20699,
20769,
20770,
20790,
20791,
20852,
20870,
20892,
20916,
20924,
20925,
20972,
20973,
21095,
21096,
21107,
21123,
21184,
21300,
21404,
21412,
21486,
21487,
21517,
21518,
21583,
21601,
21627,
21651,
21675,
21683,
21684,
21733,
21734,
21834,
21835,
21846,
21862,
21923,
22002,
22077,
22181,
22189,
22264,
22265,
22295,
22296,
22361,
22379,
22405,
22429,
22446,
22454,
22455,
22504,
22505,
22605,
22606,
22617,
22633,
22694,
22773,
22848,
22903,
22911,
22986,
22987,
22999,
23000,
23039,
23052,
23065,
23082,
23090,
23091,
23123,
23124,
23201,
23202,
23213,
23253,
23301,
23350,
23389,
23390,
23401,
23402,
23440,
23453,
23466,
23480,
23488,
23489,
23522,
23523,
23614,
23615,
23626,
23666,
23714,
23763,
23803,
23804,
23834,
23835,
23898,
23924,
23953,
23961,
23962,
24002,
24003,
24057,
24058,
24069,
24096,
24201,
24246,
24247,
24277,
24278,
24341,
24362,
24375,
24388,
24396,
24397,
24441,
24442,
24528,
24529,
24540,
24567,
24623,
24699,
24776,
24784,
24839,
24840,
24872,
24873,
24938,
24961,
24987,
25016,
25024,
25025,
25108,
25109,
25206,
25207,
25218,
25245,
25280,
25385,
25430,
25431,
25461,
25462,
25531,
25552,
25575,
25588,
25601,
25638,
25646,
25647,
25722,
25723,
25840,
25841,
25852,
25879,
25935,
25970,
26077,
26185,
26271,
26279,
26334,
26335,
26367,
26368,
26433,
26456,
26464,
26465,
26519,
26520,
26618,
26619,
26630,
26657,
26719,
26727,
26769,
26770,
26792,
26793,
26854,
26878,
26907,
26931,
26939,
26940,
26982,
26983,
27040,
27041,
27052,
27070,
27142,
27206,
27253,
27254,
27272,
27273,
27334,
27357,
27370,
27378,
27379,
27420,
27421,
27503,
27504,
27509,
27557,
27568,
27630,
27679,
27728,
27729,
27745,
27746,
27803,
27825,
27827,
27828,
27888,
27889,
27987,
27988,
27999,
28035,
28093,
28094,
28122,
28123,
28180,
28181,
28203,
28204,
28226,
28227,
28238,
28264,
28265,
28293,
28294,
28351,
28381,
28383,
28384,
28480,
28481,
28615,
28616,
28627,
28653,
28689,
28690,
28710,
28711,
28749,
28750,
28773,
28774,
28841,
28842,
28860,
28861,
28938,
28939,
29029,
29030,
29120,
29121,
29132,
29170,
29171,
29193,
29194,
29274,
29275,
29296,
29297,
29318,
29319,
29330,
29429,
29430,
29501
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 29501,
"ccnet_original_nlines": 881,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.24809767305850983,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.007255349773913622,
"rps_doc_frac_lines_end_with_ellipsis": 0.028344670310616493,
"rps_doc_frac_no_alph_words": 0.2659706175327301,
"rps_doc_frac_unique_words": 0.17355981469154358,
"rps_doc_mean_word_length": 5.631954669952393,
"rps_doc_num_sentences": 334,
"rps_doc_symbol_to_word_ratio": 0.004600959829986095,
"rps_doc_unigram_entropy": 5.2776713371276855,
"rps_doc_word_count": 4062,
"rps_doc_frac_chars_dupe_10grams": 0.33548977971076965,
"rps_doc_frac_chars_dupe_5grams": 0.46273550391197205,
"rps_doc_frac_chars_dupe_6grams": 0.4216461777687073,
"rps_doc_frac_chars_dupe_7grams": 0.392009437084198,
"rps_doc_frac_chars_dupe_8grams": 0.35594701766967773,
"rps_doc_frac_chars_dupe_9grams": 0.3388993442058563,
"rps_doc_frac_chars_top_2gram": 0.02937448024749756,
"rps_doc_frac_chars_top_3gram": 0.013987850397825241,
"rps_doc_frac_chars_top_4gram": 0.005289160180836916,
"rps_doc_books_importance": -2730.543212890625,
"rps_doc_books_importance_length_correction": -2730.543212890625,
"rps_doc_openwebtext_importance": -1273.7200927734375,
"rps_doc_openwebtext_importance_length_correction": -1273.7200927734375,
"rps_doc_wikipedia_importance": -1045.58447265625,
"rps_doc_wikipedia_importance_length_correction": -1045.58447265625
},
"fasttext": {
"dclm": 0.3899926543235779,
"english": 0.6106064319610596,
"fineweb_edu_approx": 2.767252206802368,
"eai_general_math": 0.5707422494888306,
"eai_open_web_math": 0.24130958318710327,
"eai_web_code": 0.15416020154953003
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.0151",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "516.3",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Geometry, Algebraic"
}
}
},
"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": "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": "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": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,758,735,495,397,185,500
|
Q
Problem solve Get help with specific problems with your technologies, process and projects.
Building a human resources data warehouse
I'm trying to implement a data warehouse, but I have to study a lot to get more information about it. For that reason, I want to ask you about the real possibilities are to build a DW with the following characteristics: I have a distributed human resource application in 15 companies around the country, and this application uses a MS Access database. Now the central level that groups these companies needs to obtain information about the human resource activity. Is that a reason to build a data warehouse? How can I use those databases to get the necessary information?
Bringing data together for an enterprise is an excellent (and most often driving factor) for implementing a data warehouse. To develop an HR data model that reflects the corporate view of the HR function, spend some time really understanding the business information needs (what questions are the corporate folks needing to get answers to and what metrics and measures do they need to help answer those questions). Build this information into a data model as well (this is your access layer data model). Determine and define the rules for enforcing conformance of data from the 15 locations in order for them to fit into the corporate view. This forms the basis of your transformation from the 15 sources to the corporate view. Map those sources to the Target and implement the software and scheduling to continually pull the information from the sources to your target corporate view.
Of course, this is a simplistic view of the work needed.
You might look into a hosted data warehouse solution as well. This provides a cost effective and expeditious means to implement business intelligence functionality for your company without causing a lot of technology change in your company.
For More Information
Dig Deeper on Oracle data warehousing
Start the conversation
Send me notifications when other members comment.
Please create a username to comment.
-ADS BY GOOGLE
SearchDataManagement
SearchBusinessAnalytics
SearchSAP
SearchSQLServer
TheServerSide.com
SearchDataCenter
SearchContentManagement
SearchHRSoftware
Close
|
{
"url": "https://searchoracle.techtarget.com/answer/Building-a-human-resources-data-warehouse",
"source_domain": "searchoracle.techtarget.com",
"snapshot_id": "crawl=CC-MAIN-2020-24",
"warc_metadata": {
"Content-Length": "218875",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:KI6FT45RYCUPPAUR545MRUU6EFLBWN2A",
"WARC-Concurrent-To": "<urn:uuid:58681dbd-0bbd-401b-aa84-c6609bdfb4f1>",
"WARC-Date": "2020-06-02T09:14:54Z",
"WARC-IP-Address": "206.19.49.153",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:L4FVRHV2LLKUACESSSOBA6QX7QKOLLEV",
"WARC-Record-ID": "<urn:uuid:bea2fcbe-eacc-4a17-85db-6fe0d4494675>",
"WARC-Target-URI": "https://searchoracle.techtarget.com/answer/Building-a-human-resources-data-warehouse",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:88e42684-1e16-43f1-a837-72ecd2f0565a>"
},
"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-253.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,
2,
94,
95,
137,
138,
711,
712,
1598,
1599,
1656,
1657,
1898,
1899,
1920,
1921,
1922,
1960,
1961,
1984,
1985,
2035,
2036,
2073,
2074,
2089,
2090,
2111,
2112,
2136,
2137,
2147,
2148,
2164,
2165,
2183,
2184,
2201,
2202,
2226,
2227,
2244,
2245
],
"line_end_idx": [
2,
94,
95,
137,
138,
711,
712,
1598,
1599,
1656,
1657,
1898,
1899,
1920,
1921,
1922,
1960,
1961,
1984,
1985,
2035,
2036,
2073,
2074,
2089,
2090,
2111,
2112,
2136,
2137,
2147,
2148,
2164,
2165,
2183,
2184,
2201,
2202,
2226,
2227,
2244,
2245,
2250
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2250,
"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.4244791567325592,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0338541716337204,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.0885416716337204,
"rps_doc_frac_unique_words": 0.5185185074806213,
"rps_doc_mean_word_length": 5.259259223937988,
"rps_doc_num_sentences": 19,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.753963947296143,
"rps_doc_word_count": 351,
"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.035211268812417984,
"rps_doc_frac_chars_top_3gram": 0.02275189943611622,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -176.31051635742188,
"rps_doc_books_importance_length_correction": -176.31051635742188,
"rps_doc_openwebtext_importance": -116.15973663330078,
"rps_doc_openwebtext_importance_length_correction": -116.15973663330078,
"rps_doc_wikipedia_importance": -72.57943725585938,
"rps_doc_wikipedia_importance_length_correction": -72.57943725585938
},
"fasttext": {
"dclm": 0.038567300885915756,
"english": 0.9159097671508789,
"fineweb_edu_approx": 1.5634828805923462,
"eai_general_math": 0.24814742803573608,
"eai_open_web_math": 0.07002013921737671,
"eai_web_code": 0.21837162971496582
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.758",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "658.3",
"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": "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": "10",
"label": "Knowledge Article"
}
},
"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
|
1,244,324,789,238,234,600
|
Author: The Studio
Responsive Web Design
One of the major trends in websites over the last few years has been Responsive Design. Responsive Design is way to design and program a website so it looks good at any screen size. This is import because of the
Content Management Systems
Content Management Systems (CMS) have become crucial part of website construction. Clients want to have greater and easier control over their sites content. They do not want to have to engage a web expert when making simple modifications to their
Kirk Peters Content Management System
Now with all Kirk Peters Web Multimedia Studio websites, customers can have a custom built content management system. A password protected backend to the site, the manager allows users to be able to add, delete and reorder the pages on
Another New Web Design for the Studio
The Kirk Peters Web Multimedia Studio web site has a new look. The Studio has been busy and we needed a new design to be more portfolio orientated. Now it is more convenient to view projects the Studio is working
A Simple Guide for Search Engine Optimization
What is the point of having a web site if no one can find it? A high search engine ranking is something we would all like to achieve with our web sites. This month’s article is how the high-end SEO
What is Anamorphic Widescreen Video?
More and more video is being shot in a 16×9 aspect ratio. The standard 4×3 that we are all used to is slowly going away. Widescreen video fills the newer widescreen televisions, more closely mimics high definition video, and is
The Ins and Outs of Domain Name Registration
I hear the same questions from my clients again and again. What should my domain name be? How do I get a domain name? How do I transfer my domain to your server? I thought I would take some time
Web Optimization: Making Your Content as Small as Possible
So you have designed a top notch website for yourself and are ready to convert to HTML or Flash. The quicker you can deliver your content to your final users the more likely they are to read it. So how
How to Design DVD Menus Like a Pro: Part 2, Structure
How a DVD menu is put together can be just as important as how it looks. A poorly executed DVD menu can be frustrating to understand and to navigate. This can result in a poor experience for the final user.
Kirk Peters Multimedia Studio Launches New Website Design
Kirk Peters Web/Multimedia Studio grew so quick over the course of last year that the simple web concept I had come up with at the beginning became overwhelmed with all of the additional information continually added to the site. Hopefully
HostExchange
|
{
"url": "http://www.kirkpeters.com/author/kirk/",
"source_domain": "www.kirkpeters.com",
"snapshot_id": "crawl=CC-MAIN-2018-09",
"warc_metadata": {
"Content-Length": "56438",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:NIPWFXZ7PYUF7VI6WCU2RC7LO72GZEWN",
"WARC-Concurrent-To": "<urn:uuid:7873980c-1320-4af0-8fee-b5590e9c699a>",
"WARC-Date": "2018-02-20T11:16:17Z",
"WARC-IP-Address": "162.144.60.211",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:OZT4DCFG2LI4PJVYSE5PNSI25KUDNF77",
"WARC-Record-ID": "<urn:uuid:b089e665-7054-4c28-b526-72b617acfa67>",
"WARC-Target-URI": "http://www.kirkpeters.com/author/kirk/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c9ae9108-86d2-4727-a7c0-42dcedc3ed40>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-228-65-216.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-09\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for February 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,
19,
20,
42,
43,
256,
257,
284,
285,
534,
535,
573,
574,
810,
811,
849,
850,
1063,
1064,
1110,
1111,
1309,
1310,
1347,
1348,
1576,
1577,
1622,
1623,
1818,
1819,
1878,
1879,
2081,
2082,
2136,
2137,
2344,
2345,
2403,
2404,
2644,
2645
],
"line_end_idx": [
19,
20,
42,
43,
256,
257,
284,
285,
534,
535,
573,
574,
810,
811,
849,
850,
1063,
1064,
1110,
1111,
1309,
1310,
1347,
1348,
1576,
1577,
1622,
1623,
1818,
1819,
1878,
1879,
2081,
2082,
2136,
2137,
2344,
2345,
2403,
2404,
2644,
2645,
2657
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2657,
"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.42105263471603394,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.031189080327749252,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.08382066339254379,
"rps_doc_frac_unique_words": 0.47021275758743286,
"rps_doc_mean_word_length": 4.529787063598633,
"rps_doc_num_sentences": 23,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.948354721069336,
"rps_doc_word_count": 470,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.027242839336395264,
"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.023485200479626656,
"rps_doc_frac_chars_top_3gram": 0.022545799612998962,
"rps_doc_frac_chars_top_4gram": 0.021606389433145523,
"rps_doc_books_importance": -266.72955322265625,
"rps_doc_books_importance_length_correction": -266.72955322265625,
"rps_doc_openwebtext_importance": -176.55184936523438,
"rps_doc_openwebtext_importance_length_correction": -176.55184936523438,
"rps_doc_wikipedia_importance": -113.74967193603516,
"rps_doc_wikipedia_importance_length_correction": -113.74967193603516
},
"fasttext": {
"dclm": 0.025821330025792122,
"english": 0.9334913492202759,
"fineweb_edu_approx": 1.4829864501953125,
"eai_general_math": 0.00938331987708807,
"eai_open_web_math": 0.09269226342439651,
"eai_web_code": 0.0038357400335371494
}
}
|
{
"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.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": "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": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-7,567,642,058,725,509,000
|
Ubuntu ls not listing??
I've just installed git on Ubuntu 11.04, and I create a directory, run 'git init', which runs ok, but i don't see the .git folder with ls, but I can cd into it?
(I'm a very occasional user of this Ubuntu box so its bound to be something very simple.)
Silas2Asked:
Who is Participating?
Patrick BogersConnect With a Mentor Datacenter platform engineer LindowsCommented:
Hi
The dot in front of the directory says it is a hidden directory.
ls -la
will show it.
0
Silas2Author Commented:
Ah..tks.
0
Question has a verified solution.
Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.
Have a better answer? Share it in a comment.
All Courses
From novice to tech pro — start learning today.
|
{
"url": "https://www.experts-exchange.com/questions/28342105/Ubuntu-ls-not-listing.html",
"source_domain": "www.experts-exchange.com",
"snapshot_id": "crawl=CC-MAIN-2018-17",
"warc_metadata": {
"Content-Length": "88062",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:OP2WCCK6C3B4FI4SXD4KEEPBXZ5G5UGL",
"WARC-Concurrent-To": "<urn:uuid:4f4a32e8-087f-4c34-bace-a32539aad49c>",
"WARC-Date": "2018-04-24T09:25:13Z",
"WARC-IP-Address": "104.20.169.10",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:CHI3QUIEOGNCITZIPYIHFJWF66A5KVSO",
"WARC-Record-ID": "<urn:uuid:961f994c-a649-410f-9444-bf14c41c39dd>",
"WARC-Target-URI": "https://www.experts-exchange.com/questions/28342105/Ubuntu-ls-not-listing.html",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ffae544d-769d-48c3-ad2a-a9f48caaa857>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-146-34-165.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,
24,
25,
186,
276,
289,
311,
313,
396,
399,
400,
465,
466,
473,
474,
488,
490,
492,
516,
525,
527,
561,
562,
663,
664,
709,
710,
722,
723
],
"line_end_idx": [
24,
25,
186,
276,
289,
311,
313,
396,
399,
400,
465,
466,
473,
474,
488,
490,
492,
516,
525,
527,
561,
562,
663,
664,
709,
710,
722,
723,
770
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 770,
"ccnet_original_nlines": 28,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3273809552192688,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02380952052772045,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2083333283662796,
"rps_doc_frac_unique_words": 0.7293233275413513,
"rps_doc_mean_word_length": 4.451128005981445,
"rps_doc_num_sentences": 16,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.401765823364258,
"rps_doc_word_count": 133,
"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.01351351011544466,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -70.72589111328125,
"rps_doc_books_importance_length_correction": -70.72589111328125,
"rps_doc_openwebtext_importance": -41.644317626953125,
"rps_doc_openwebtext_importance_length_correction": -41.644317626953125,
"rps_doc_wikipedia_importance": -25.856660842895508,
"rps_doc_wikipedia_importance_length_correction": -25.856660842895508
},
"fasttext": {
"dclm": 0.13762670755386353,
"english": 0.9211292862892151,
"fineweb_edu_approx": 1.2584418058395386,
"eai_general_math": 0.06887704133987427,
"eai_open_web_math": 0.30076444149017334,
"eai_web_code": 0.00034296998637728393
}
}
|
{
"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.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": "-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
|
-7,829,315,482,995,528,000
|
aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Expand)AuthorFilesLines
2017-03-16temporary dev: set debug log level almost everywheresysmocom/iuneels/iuNeels Hofmeyr1-17/+17
2017-03-16log protocol discriminators and message types by nameNeels Hofmeyr11-907/+923
2017-03-16mgcp: hack RAB success from nano3G: patch first RTP payloadNeels Hofmeyr2-0/+8
2017-03-16Implement IuCS (large refactoring and addition)Neels Hofmeyr93-2048/+4762
2017-03-16mscsplit: various preparations to separate MSC from BSCHarald Welte28-266/+446
2017-03-16IuPS adjustmentsHarald Welte5-23/+46
2017-03-16SI3: indicate R99+ MSC to GSM MS to enable UMTS AKANeels Hofmeyr1-0/+3
2017-03-16Add msc_vlr test suite for MSC+VLR end-to-end testsNeels Hofmeyr34-2/+15304
2017-03-16Use libvlr in libmsc (large refactoring)Harald Welte66-3827/+2142
2017-03-16Add libvlr implementationHarald Welte17-0/+5440
2017-03-16logging: auth request: use hexdump without spaces for RAND, AUTNNeels Hofmeyr1-2/+2
2017-03-16gsup_client: allow passing a unit id to identify with HLRNeels Hofmeyr4-7/+21
2017-03-16GPRS/IuPS: remove all 3G authentication dev hacksNeels Hofmeyr2-44/+2
2017-03-16LU counters: count completion and failure, not messages sentNeels Hofmeyr3-20/+38
2017-03-15oap tests: fix after SQN scheme changes from libosmocoreNeels Hofmeyr1-1/+1
2017-03-15OM2000: Change the order of MO initializationHarald Welte1-22/+24
2017-03-15gprs: fix T3186 encoding in Sysinfo 13Philipp Maier1-1/+7
2017-03-15examples: remove logging level * everythingMax2-7/+7
2017-03-15cosmetic: Add commandline option to display versionPhilipp Maier1-1/+6
2017-03-15libbsc: add chreq type for CHREQ_T_PDCH_ONE_PHASE & CHREQ_T_PDCH_TWO_PHASEAlexander Couzens3-3/+16
2017-03-14cosmetic: add copyright header to bsc_control.pyPhilipp Maier1-0/+21
2017-03-14gprs_sgsn.c: initialize ptmsi with 0xdeadbeefAlexander Couzens1-1/+1
2017-03-14python tests: vty and smpp: speed up >10 timesNeels Hofmeyr2-2/+0
2017-03-13unixsocket: start sabm for UNIXSOCKETAlexander Couzens1-2/+4
2017-03-13OM2000: Add FIXME comments for missing resolving of RX/TX MO!Harald Welte1-0/+2
2017-03-08add struct bsc_subscr, separating libbsc from gsm_subscriberNeels Hofmeyr30-115/+615
2017-03-07Add MS time. offset to gsm_lchanMax1-0/+6
2017-03-05vty tests: close msc socket after nat_msc_testNeels Hofmeyr1-23/+27
2017-03-05sgsn: fix problem with leading-zero-IMSIsPhilipp Maier1-2/+11
2017-03-02vty tests: allow picking specific tests to run by nameNeels Hofmeyr1-0/+5
2017-03-02Fix potential segfault in sgsn_libgtp.cMax1-3/+5
2017-03-02subscriber conn: add indicator for originating RANNeels Hofmeyr3-1/+10
2017-03-02fix: gprs_gmm, gprs_llc_vty: two unterminated value_string arraysNeels Hofmeyr2-0/+2
2017-03-01meas_json: fix NEIGH: missing array bracesKeith1-1/+2
2017-02-28libmsc/update_db_revision_3(): free memleaking db resultAlexander Couzens1-0/+2
2017-02-28silent_call: remove unfinished fuzzer interfacePhilipp Maier3-0/+9
2017-02-28ctrl_test_runner: speed up more than 10 fold by sleeping lessNeels Hofmeyr1-3/+13
2017-02-28vty test: nat_msc_test: setsockopt REUSE to avoid TIME_WAIT problemsNeels Hofmeyr1-0/+1
2017-02-27XID: resend xid with pdp-ctx-ack messagesPhilipp Maier1-1/+15
2017-02-27SGSN VTY: make missing GSUP server address+port fatalNeels Hofmeyr2-12/+10
2017-02-27SGSN: Integrate support for UMTS AKANeels Hofmeyr5-30/+205
2017-02-25smpp_test_runner.py: fix socket leakNeels Hofmeyr1-0/+2
2017-02-25python tests: remove process 'Launch' message, now at osmoutilNeels Hofmeyr3-3/+0
2017-02-25vty_rest_runner.py: remove debug monitoring for TCP socketsNeels Hofmeyr1-22/+0
2017-02-25utils: 'meas_json' utility to convert measurement feed into a JSON feed.Alexander Chemeris2-0/+206
2017-02-25add struct gprs_subscr, separating gprs from gsm_subscriberNeels Hofmeyr13-151/+269
2017-02-24cosmetic: rename struct osmo_msc_data to bsc_msc_dataNeels Hofmeyr14-107/+107
2017-02-24cosmetic: rename osmo_msc_data.h to bsc_msc_data.hNeels Hofmeyr19-18/+18
2017-02-24cosmetic: clarify BSC's remote MSC data vs. OsmoMSCNeels Hofmeyr1-0/+6
2017-02-24cosmetic: gsm_data.h, README: rename CSCN to MSCNeels Hofmeyr2-2/+2
|
{
"url": "https://cgit.osmocom.org/openbsc/log/?h=neels/iu",
"source_domain": "cgit.osmocom.org",
"snapshot_id": "crawl=CC-MAIN-2022-40",
"warc_metadata": {
"Content-Length": "31545",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LWOJCU4JPMFKXUGE23MBF666257YL776",
"WARC-Concurrent-To": "<urn:uuid:024bc891-2efd-42fc-a909-74ffed900c77>",
"WARC-Date": "2022-09-30T06:31:35Z",
"WARC-IP-Address": "78.46.96.155",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:SZNXOIWCTFRBWS5FSC2EMBIM56HAGAD4",
"WARC-Record-ID": "<urn:uuid:48b7dcfe-aedc-4458-9136-bbd81e23fc52>",
"WARC-Target-URI": "https://cgit.osmocom.org/openbsc/log/?h=neels/iu",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5310fe15-43f1-4067-afc9-9c12d8fa6595>"
},
"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-251\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,
39,
82,
185,
273,
362,
446,
535,
582,
663,
749,
825,
883,
977,
1065,
1145,
1237,
1323,
1399,
1467,
1530,
1611,
1720,
1799,
1878,
1954,
2025,
2115,
2210,
2262,
2340,
2412,
2496,
2555,
2636,
2731,
2795,
2885,
2962,
3054,
3152,
3224,
3309,
3378,
3444,
3536,
3626,
3735,
3829,
3917,
4000,
4081
],
"line_end_idx": [
39,
82,
185,
273,
362,
446,
535,
582,
663,
749,
825,
883,
977,
1065,
1145,
1237,
1323,
1399,
1467,
1530,
1611,
1720,
1799,
1878,
1954,
2025,
2115,
2210,
2262,
2340,
2412,
2496,
2555,
2636,
2731,
2795,
2885,
2962,
3054,
3152,
3224,
3309,
3378,
3444,
3536,
3626,
3735,
3829,
3917,
4000,
4081,
4158
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4158,
"ccnet_original_nlines": 51,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.07874865084886551,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0442286916077137,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5350593328475952,
"rps_doc_frac_unique_words": 0.7807881832122803,
"rps_doc_mean_word_length": 8.268472671508789,
"rps_doc_num_sentences": 13,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.5887861251831055,
"rps_doc_word_count": 406,
"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.006553470157086849,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -343.29840087890625,
"rps_doc_books_importance_length_correction": -343.29840087890625,
"rps_doc_openwebtext_importance": -109.23886108398438,
"rps_doc_openwebtext_importance_length_correction": -109.23886108398438,
"rps_doc_wikipedia_importance": -256.9636535644531,
"rps_doc_wikipedia_importance_length_correction": -256.9636535644531
},
"fasttext": {
"dclm": 0.07445985078811646,
"english": 0.4735857844352722,
"fineweb_edu_approx": 1.2458535432815552,
"eai_general_math": 0.04373491182923317,
"eai_open_web_math": 0.1440647840499878,
"eai_web_code": 0.3697674870491028
}
}
|
{
"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": "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": "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": "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": "1",
"label": "No Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-4,750,424,499,701,277,000
|
Advice on download manager
Discussion in 'other software & services' started by MobileForces, Jul 20, 2004.
Thread Status:
Not open for further replies.
1. MobileForces
MobileForces Guest
Hi
Does anyone here use a download manager? Like the one recommended on the Wilders free software page- DLExpert. Are they generally newbie friendly? Does it really speed up your downloads? I have 56k dialup, and was wondering how much of a speed up i may see when downloading files? Thanks for any help.
2. bigc73542
bigc73542 Retired Moderator
Joined:
Sep 21, 2003
Posts:
23,872
Location:
SW. Oklahoma
I have used several download managers when I was on dial up. I never actually noticed faster downloads but most dl managers can download from several sites or mirrors at once. What the multiple connections will do is it will allow it to keep downloading on the other sites or mirrors that it is connected to if it looses a connection on one of the connections it is useing. Which will allow it to complete the download with out having to reconnect and start over. That alone is a good thing to have if you are on dial up and are getting fairly large files.
3. Tassie_Devils
Tassie_Devils Global Moderator
Joined:
May 8, 2002
Posts:
2,514
Location:
State Queensland, Australia
Hi MobileForces...
Generally, you will not detect any differences speed wise using dial up...
What normally happens with DL managers, it they collect pieces of the file from various sites, dl all same time and put them together at the end.
Using dialup, this is virtually no gain at all. ;)
The only thing a DLManger [in my experience] can do for you on dial-up, is if a connection is lost, or you need to stop, you can resume the dl at a later date and not have to dl the whole file again.
Been there, done that. :'( on 56K Modem..
Generally the maximum is like 52K sec. [depends on each country's law].
TAS
edit: bigc beat me.... same reply though ;)
4. Paranoid2000
Paranoid2000 Registered Member
Joined:
May 2, 2004
Posts:
2,839
Location:
North West, United Kingdom
With a 56kbs dialup connection you can expect, at best, a 5KB/s download (note the change from kb=kilobit to KB=kilobyte). The main benefit on dialup of a download manager is the ability to resume interrupted downloads as stated previously.
Be careful with downloaders offering multiple connections. This can be useful if the limiting factor is the server (which is highly unlikely on dialup) and if the file is mirrored elsewhere. Otherwise it can actually slow things down (each network connection carries a protocol overhead) and some servers will ban your IP address (e.g. the Underdogs abandonware site) since multiple connections take up more server resources.
5. Basic1
Basic1 Guest
What Tassie_Devils and bigc73542 have said is true you will see very little to no increase in speed using a download manager.
As for being user friendly the only way to tell which one will suit your needs is to try them out. There are a lot of them out there.
I have been using one for years now but then I am a download freak. I will usually queue up a goodly list of downloads and then download them while I am asleep or at work with option to disconnect and shutdown computer after it is done. It will also sort downloaded files depending on which extension they are to different folders. It will also autimatically login to sites that require login before you can download.
Yeesh, it sounds like I am trying to sell you a download manager.:lol
Seriously though if you download a lot of files like I do and are on a 56k modem like I am then having a download manager is a good tool to have imho.
If you do decide to use one take a look at the version history and see if they are updating thier product fairly frequently. There are sites that want cookies and referrers to download.
A site with a good list freeware and shareware.
http://fileforum.betanews.com/browse/WWW&Internet/DownloadEnhancements
Good luck.
6. Azn_Tweaker
Azn_Tweaker Registered Member
Joined:
Jun 26, 2004
Posts:
120
Location:
Canada, Toronto
Loading...
Thread Status:
Not open for further replies.
|
{
"url": "http://www.wilderssecurity.com/threads/advice-on-download-manager.42226/",
"source_domain": "www.wilderssecurity.com",
"snapshot_id": "crawl=CC-MAIN-2016-44",
"warc_metadata": {
"Content-Length": "53937",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LI25N7NRLXN3AGYQGF4D7KDEDNJSW36B",
"WARC-Concurrent-To": "<urn:uuid:64e06b3c-be37-42f6-8824-25d66170e238>",
"WARC-Date": "2016-10-25T23:55:39Z",
"WARC-IP-Address": "104.236.97.180",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:IK2AOVOUUFDSVWLW2FS4XKKJXV4MZZX5",
"WARC-Record-ID": "<urn:uuid:66b219a6-b641-4f99-9335-e8770bd53b6a>",
"WARC-Target-URI": "http://www.wilderssecurity.com/threads/advice-on-download-manager.42226/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:1f945f7b-96c5-4e0e-a9c2-fbbe1076b64c>"
},
"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,
27,
28,
109,
110,
125,
155,
173,
174,
197,
198,
205,
206,
512,
518,
533,
534,
566,
567,
579,
596,
607,
618,
632,
649,
1210,
1216,
1235,
1236,
1271,
1272,
1284,
1300,
1311,
1321,
1335,
1367,
1390,
1391,
1470,
1471,
1621,
1622,
1677,
1678,
1882,
1883,
1929,
1930,
2006,
2007,
2015,
2016,
2064,
2070,
2088,
2089,
2124,
2125,
2137,
2153,
2164,
2174,
2188,
2219,
2464,
2465,
2895,
2901,
2913,
2914,
2931,
2932,
3062,
3063,
3201,
3202,
3624,
3625,
3699,
3700,
3855,
3856,
4046,
4047,
4099,
4100,
4175,
4176,
4191,
4197,
4214,
4215,
4249,
4250,
4262,
4279,
4290,
4298,
4312,
4332,
4343,
4358
],
"line_end_idx": [
27,
28,
109,
110,
125,
155,
173,
174,
197,
198,
205,
206,
512,
518,
533,
534,
566,
567,
579,
596,
607,
618,
632,
649,
1210,
1216,
1235,
1236,
1271,
1272,
1284,
1300,
1311,
1321,
1335,
1367,
1390,
1391,
1470,
1471,
1621,
1622,
1677,
1678,
1882,
1883,
1929,
1930,
2006,
2007,
2015,
2016,
2064,
2070,
2088,
2089,
2124,
2125,
2137,
2153,
2164,
2174,
2188,
2219,
2464,
2465,
2895,
2901,
2913,
2914,
2931,
2932,
3062,
3063,
3201,
3202,
3624,
3625,
3699,
3700,
3855,
3856,
4046,
4047,
4099,
4100,
4175,
4176,
4191,
4197,
4214,
4215,
4249,
4250,
4262,
4279,
4290,
4298,
4312,
4332,
4343,
4358,
4387
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4387,
"ccnet_original_nlines": 102,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.42771804332733154,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.025089610368013382,
"rps_doc_frac_lines_end_with_ellipsis": 0.029126210138201714,
"rps_doc_frac_no_alph_words": 0.17084826529026031,
"rps_doc_frac_unique_words": 0.45571428537368774,
"rps_doc_mean_word_length": 4.648571491241455,
"rps_doc_num_sentences": 54,
"rps_doc_symbol_to_word_ratio": 0.004778970032930374,
"rps_doc_unigram_entropy": 5.302742958068848,
"rps_doc_word_count": 700,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.022126609459519386,
"rps_doc_frac_chars_dupe_6grams": 0.022126609459519386,
"rps_doc_frac_chars_dupe_7grams": 0.022126609459519386,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.016594959422945976,
"rps_doc_frac_chars_top_3gram": 0.019668100401759148,
"rps_doc_frac_chars_top_4gram": 0.011677930131554604,
"rps_doc_books_importance": -390.7076721191406,
"rps_doc_books_importance_length_correction": -390.7076721191406,
"rps_doc_openwebtext_importance": -205.0511474609375,
"rps_doc_openwebtext_importance_length_correction": -205.0511474609375,
"rps_doc_wikipedia_importance": -173.19223022460938,
"rps_doc_wikipedia_importance_length_correction": -173.19223022460938
},
"fasttext": {
"dclm": 0.06249750033020973,
"english": 0.9395567774772644,
"fineweb_edu_approx": 1.217876672744751,
"eai_general_math": 0.04922186955809593,
"eai_open_web_math": 0.1695428490638733,
"eai_web_code": 0.0023853799793869257
}
}
|
{
"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": "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": "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": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
4,832,927,258,778,472,000
|
Forgot your password?
typodupeerror
Hardware
Software To Diagnose Faulty PC Hardware? 274
Posted by timothy
from the diagnostics-are-underrated dept.
Etylowy writes "Over the years I have repaired my own PC and those belonging to family and friends many, many times. While in most cases it turned out to be restoring a system after malware/the user/Windows made a mess, or simple cases of 'follow the smell of smoke and molten plastic,' there were some nasty ones where the computer mostly works. By 'mostly,' I mean: you can boot it up, it might even work for a while, but will crash way too often to blame it all on Microsoft — what do you do then? Once you strip it of any extra hardware (which, with today's motherboards that have pretty much everything integrated, might not be an option) you are left with the CPU, motherboard, graphics card, RAM and HDD. You can test the HDD, you can run memtest86+ to check the RAM, but how do you go about testing the CPU, motherboard and graphics card trio to find which is to blame? Replacing them one by one isn't really an option. Do you know of any software that would help the way memtest helps with RAM?"
This discussion has been archived. No new comments can be posted.
Software To Diagnose Faulty PC Hardware?
Comments Filter:
• OCCT (Score:5, Interesting)
by PFAK (524350) * on Saturday October 10, 2009 @03:50PM (#29705577)
It will stress your RAM, CPU, and GPU or all at once with pretty temperature and utilization graphs (for Windows only): http://www.ocbase.com/perestroika_en/ [ocbase.com]
• Overheat (Score:5, Informative)
by gd2shoe (747932) on Saturday October 10, 2009 @04:22PM (#29705793) Journal
That's a marginal idea at best, but a common one.
While the technique of blasting a processing unit to see how it behaves at maximum temperature will sometimes find a faulty unit, many faults are not temperature related, and will not show up on this test. It's fine that you brought it up here, but something that both heats the CPU/GPU and tries to test as many pathways / as much of the instruction set as possible would be far more useful. (cf memtest86+ for RAM)
• PSU (Score:5, Informative)
by gd2shoe (747932) on Saturday October 10, 2009 @04:24PM (#29705809) Journal
Oh, and don't forget to check the PSU. When it acts up, it will often appear to be a hardware fault somewhere else in the machine. (often RAM, but can be MB, CPU, GPU...)
This certainly doesn't answer the posters question, but it is related and important.
• Re:PSU (Score:5, Informative)
by Daneurysm (732825) on Saturday October 10, 2009 @06:04PM (#29706433)
I was just about to mention this. I used to work in a mom-n-pop shop, the only one in the area, for a long time.
I have seen some of the most ridiculous problems that were PSU related. Serial mouse not working, VGA card outputting in B&W, slow and or intermittent performance, HD's that constantly reset (and sound like click of death in the process), new memory being blown, known good memory acting like bad memory, CD-R's that can't burn (or finish burning successfully), software modems that couldn't go off hook, AGP cards crashing, PCI cards crashing, VLB SCSI cards not working at all.
The list really just goes on and on and on. Software to diagnose faulty PC hardware? Sorry, no thanks. I had tried all manner of diagnostic and test software over the years. Some worked some of the time. (mem tests and HD scanners), the rest were borderline use-less pieces of crap. Not only that, but because of faulty PSU's (usually overloaded, or just old, or overheating, etc etc etc) I have seen those same programs misdiagnose just about everything.
Aside from simple sensor reading and verification (of code, built in HW diagnostics, etc) I do no trust 'software based' hardware diagnosis, especially on a PC.
YMMV.
• Re:PSU (Score:5, Insightful)
by mysidia (191772) on Saturday October 10, 2009 @07:37PM (#29706999)
Check supply voltages first.
There's a really fancy test program to do this... it's called a digital multimeter, and it's a piece of hardware with two probes.
You touch one probe to ground, and then use the other to check all the leads going into MB for supply voltage.
For desktops that is.
For servers, the power supplies are generally smart modular units, and you check their voltage outputs in the BIOS screens, or using remote management via BMC: IPMI, iLO, Drac, or ALOM
• by gobbo (567674)
Mod parent up. A proper multimeter and a power supply voltage chart is the skeptic's answer to all kinds of hardware voodoo.
• Re:PSU (Score:5, Insightful)
by robbak (775424) on Saturday October 10, 2009 @08:08PM (#29707227) Homepage
While that is good "Bad or Maybe" test, most PSU problems are transient over- or under-voltage conditions, which a DMM is not going to reveal.
And there are testers that will measure all (or most) of the voltages produced at once - you jut plug the atx cable into the device, and many of them have a pass-through, so you can test the PSU under load. I'd look for one that could flag a transient problem, if it exists.
Mind you, since writing the above I have looked around for one, and have failed! They all are pretty simple devices that do not detect transients, I could find no pass-through devices, and they all test under very anemic loads. All told, I am not impressed by any of them.
• Re: (Score:3, Insightful)
by mysidia (191772)
Yes... but unless you are doing this professionally, or going way out of the way to build a full blown test rig and load bank [tomshardware.com] yourself, the gear required to fully test a PSU anywhere near max load is not worth it to the average person, a spot check with a DMM on the bench or in the PC (if the PC is working) is a good tradeoff, and if there is any question, try replacing the PSU.
Versus buying a $100,000 Sunmoon or Chroma tester. Or bench Oscilloscope + DC Load generator + Variable AC output gear (for
• by hannson (1369413)
This can also be done very quickly by using a ATX power supply tester like this one [coolmaxusa.com]. It has a LCD screen which shows the voltage for IIRC every connector on your power supply. In use image here: http://www.ocia.net/fullsize.php?filename=32_9.jpg [ocia.net]
• by hairyfeet (841228)
Preach fellow repair man, preach. That is why I always try to keep at least a couple of decent 400 watt PSUs around, as all kinds of hardware 'problems" could be traced back to those suckers. At the last shop I worked we had one of those PSU multimeters to test, but frankly I found that to be crap. You'd be surprised how many would test fine when first fired up only to get crappy once it had time to heat up. So with PSUs I'm of the "when in doubt, toss it out" mindset. 400 watt PSUs are cheap, and it is bet
• by Cloud K (125581)
Agreed, speaking as a sufferer of now 3 Enermax PSUs with "right, I'm going to die now kthxbai" syndrome. And these are supposedly *good* PSUs. In my case 2 identical systems did this on the same day. Put PSU2 into PC1 and it worked for an extra month - albeit risky - but some motherboards seem to have a greater tolerance of dying PSUs than others.
But the really crap PSUs that you get bundled with a case etc are most likely output all kinds of crap and cause random weirdness and crashing.
The unfortunate
• Re: (Score:3, Informative)
by Narpak (961733)
More than once I have experienced that the on-board sound chip from Realtek causes the computer crash or have significant slowdowns. Disabling and putting in a budget soundcard fixed it. So I would suggest that disabling various on-board components in turn could uncover the culprit. That being said, identifying hardware problems have always, for me, been a bit hit and/or miss.
• by astar (203020)
On your sig, English dictionaries have a lot of definitions of free, and as I understand it, none that exactly match free as in free software. That is why people who need to be precise say gratis and libre. You are playing nominalist.
Not all your fault. The current English dictionaries are probably the result of the ongoing long-term cultural deterioration. I would expect that really old English dictionaries have the meaning.
• Re: (Score:3, Informative)
by JMandingo (325160)
Use a can of compressed air to purge out any accumulated dust. Less dust means a cooler box, which may just bring the unit back within whatever temperature (or, by extension, power) tolerance it is pushing the envelope on. Another technique is to wiggle every cable and connector and slotted card, just to make sure nothing has come loose. Check to make sure all the fans are running whilst powered on.
• by Cylix (55374)
I also praise the authors of "stress" a handy application for linux which can perform non-destructive stress to hard disks as well as provide load on the processor and memory.
For memory I really do like memtester, but I wish it was a bit less verbose. (For a user space app it's not bad)
• what about PTS? (Score:2, Insightful)
by midol (752608)
The phoronix test suite is a good profiler, at least it would narrow the search. But, as you observed, once you are down to the RAM and integrated devices what options do you really have expect to toss the mobo?
• Integrated devices can typically be replaced with PCI/PCIe devices. If an integrated network or sound card gives out, it can often be easier and less expensive to shove a new device into the case and disable the old one in the Device Manager. Still, integrated devices don't go out that often. It's more common for the MB itself to go (my experience, anecdotal).
• by sortius_nod (1080919) on Saturday October 10, 2009 @05:31PM (#29706257) Homepage
Even when they do, it's usually a sign the rest of the board is on it's way out too. A device on the board not functioning can mean a number of things (MB controllers acting up, visible/non-visible corrosion in the board, blown capacitors, etc), so you can be up for a lot of weird behaviour from the board that you can't pin down.
To be honest, relying purely on a test suite to tell you what's broken will lead to disaster. Only through experience do you get the pointers toward what is actually faulty. Add to this that true diagnosis only comes from swapping out parts, and, well, test suites don't look at all like a viable option.
When I am repairing hardware about the only suite I use is memtest86+ and a decent live linux distro. You can usually pick devices that have failed with lspci, however this is not always correct. It all goes back to having test hardware & the knowledge of what certain behaviours in systems are caused by certain faults. After 15 years of working in IT with both hardware & software faults, there's only so much you can do with limited or no test hardware. Most of the time when you're diagnosing hardware faults on the phone it's an educated guess at best, the only time you truly get a decent diagnosis is when you have the machine with you and can swap parts out. Hell, we don't even use the Dell diagnostics at work due to their inability to give decent results on anything other than RAM.
• by gd2shoe (747932)
There is a lot of truth in your post. I think you're mostly right. I also think you might be holding a one-sided argument through much of your post.
Even when they do, it's usually a sign the rest of the board is on it's way out too.
It can be. You have to wonder, why did it fail? Was there a surge? Is the PSU dying and stressing things? Was that particular integrated chip part of a bad batch? Did it get an ESD on installation? Has a controller failed? In the last case, you will usually see additional symptoms. Most integrated devices are hooked into the PCI bus as if they were pl
• by Khyber (864651)
"In short: It is possible to diagnose a computer entirely from software."
Tell me a piece of software that'll expose a dying capacitor, please?
• Quicktech has a nice (non-free) test kit that includes software and hardware. I have seen the software used on my machine, and it has tests for just about every hardware component you can think of, including the video card.
• Eurosoft PC Check (Score:5, Informative)
by jdb2 (800046) * on Saturday October 10, 2009 @03:54PM (#29705611) Journal
This is probably one of the best and most comprehensive OS agnostic boot-CD/floppy general purpose PC hardware testing and burn-in tools I've come across IMHO.
Here's its web page : http://www.eurosoft-uk.com/pc_check.htm [eurosoft-uk.com]
In any case, I recommend plugging the ATX cable into a power supply tester that presents a non-trivial load as a first step in diagnosing any PC. You'd be surprised in what ways the problems caused by out-of-spec voltages can be manifested.
jdb2
• Re: (Score:2, Informative)
by Omnifarious (11933) *
I second this. I've had 2 or 3 PCs now that have begun acting very strangely only to discover that the real problem was the power supply. Replace it and the PC acts fine again.
• Re: (Score:2, Informative)
by piero.grimo (1652185)
Same here. I've consistently had problems with a PC to discover years later that the PSU was defective (it actually blew up). I got a 450W PSU and all the bizarre symptoms have vanished.
• Re:Eurosoft PC Check (Score:5, Informative)
by Artifakt (700173) on Saturday October 10, 2009 @06:20PM (#29706527)
Every power supply which I've found failed was visibly broken once you opened it up, and it was always the capacitors. No Exceptions - capacitors had sprayed gunk all over, their Aluminium cans had popped off the bases, etc. Typical electrolytic fluid is white-ish, but once it bakes dry will scorch, and so gradually turn reddish brown. Many capacitors have grooves scored into the tops which form sort of impromptu blow out panels, and often you will see them bulging, with traces of fluid escaping from these grooves where they are actually splitting open, or scorched fluid forming a red-brown powdery residue outlining them. The grooves are usually in either an X (or Plus) or a sort of K shape. The PSUs are often still working (somewhat) at that point, and often, the PSU may be putting out nominally correct voltages when cool but deviating when it heats up. I had one client's PC that made a loud bang twice over a period of about a week, but the PC didn't really start acting funny until the third bang. Opening the PSU revealed three small caps that had blown completely off the board. It had probably kept running with no obvious symptoms through the first two.
Of course, only a trained pro with good tools should ever examine the inside of a power supply while live. But, if you are willing to unplug one and take it out of the PC and let it sit overnight, just to make sure the larger capacitors have fully drained, I recommend examining them. Yes, that voids the warranty if you aren't a pro, but if you were going to junk it and buy a new one anyway, so what? But before you open one, read this:
DON"T EVER OPEN A PLUGGED IN POWER SUPPLY. IF THIS DOESN"T APPLY TO YOU YOU ALREADY HAVE AN ELECTRICIANS LICENCE, A EE DEGREE, OR SIMILAR. DON"T OPEN A POWER SUPPLY UNLESS YOU KNOW THE LARGE CAPACITORS INSIDE ARE DISCHARGED - THEY CAN MAKE YOUR ARM MUSCLES CONTRACT HARD ENOUGH TO BREAK YOUR BONES. GIVE THEM AT LEAST AN HOUR TO RUN DOWN, THEN USE AN INSULATED TOOL TO CROSS THE PLUG PRONGS BEFORE YOU OPEN THE CASE.
Split caps or scorched ones will confirm you are right in your guess that it's the PSU. While you're at it, if you think the problem is the motherboard, check for capacitor damage there too, as it's not all that uncommon for that to be why a mainboard fails. Cheap electrolytics are probably responsible for more than half of all consumer electronics failures, they are by far the most likely source of intermittent failures, ones that come and go with temperature, or glitches that only partly disable something, and they are detectable.
• Re: (Score:3, Informative)
by rickb928 (945187)
Don't trust the caps with the 'X' pattern. The 'K' pattern is more reliable.
Ask any of the many who had Dell machines from about 2000-2004. And HP/Compaq. And Acer. Not so much IBM/Lenovo. I have no reports for Gateway.
Also affected ASUS, MSI, AOpen, Gigabyte motherboards, pretty much all brands.
For a period of time, there werw substandard caps being used, but the maker either faked the testing or used different component parts in production runs than in certification. If you got stung by these, you a
• Re: (Score:3, Informative)
by Cylix (55374)
YOU SHOULD NEVER USE CAPS LIKE THIS AND NEVER SUGGEST SOMEONE BRIDGE COMPONENTS WITH A SCREW DRIVER.
I'm getting a bit tired of replying to all of the bad advice I see flying around. However, never discharge caps by bridge the connectors (even if the tool is insulated). A large enough power source can cause some serious problems.
The proper way to handle this is to terminate the load into a ground source capable of dissipating the load. Earth ground will suffice, but don't dump a crap ton of current into the
• random thoughts (Score:3, Insightful)
by Anonymous Coward on Saturday October 10, 2009 @03:54PM (#29705613)
self-checking programs like Prime95 can be useful to test the computer more generally (if you've verified with memtest a failure here basically means cpu/chipset at fault).
Other things I've tried before have been (if the motherboard allows) things like significantly underclocking sections of the motherboard/processor, if an specific underclock fixes the problem you just significatnly narrowed down the list of possible failures.
there are similar programs to memtest that will check a GPUs output conforms to what it should, but if you just have random-crashy-badness that can be a pain to diagnose. Sometimes things like just running without graphics drivers for a while can help spot those problems, if the computer no longer crashes you can look a bit further away from the graphics card as most of it's capabilities won't be used.
• Just replace it. (Score:2, Informative)
by lukas84 (912874)
Repairing hardware makes no sense anymore. Just swap in a new machine from the pool, so the user will be happy again, call the manufacturer to send someone onsite to replace the system board, redeploy the image, and put the machine back into the pool.
At home, i usually replace the machine before it has a chance to get old and flaky.
• by Trahloc (842734)
That works awesome for the corporate world. But last I checked friends and family dont have a pool to draw from and if you at least read the first couple words of the summary.
"Over the years I have repaired my own, family, and friends' PCs many, many times".
I know RTFA is too much to ask on other articles but RTFS's first sentence on askslashdot can't be THAT much ... can it?
• How to test? (Score:3, Insightful)
by girlintraining (1395911) on Saturday October 10, 2009 @03:55PM (#29705619)
Well... typically you find the fault by using an application which stresses one of those components far more than any other and then seeing if the failure condition you're observing occurs more often. This is just basic troubleshooting, it's not even specific to computers.
• by jackchance (947926) on Saturday October 10, 2009 @03:57PM (#29705631) Homepage
Most home computer hardware failures come from "brownouts".
If you notice that your lights dim a little bit when your fridge compressor or AirCon comes on, that is a recipe for a computer failure. Spend $50 get a UPS [amazon.com]
Btw, i noticed that my linksys wifi router was also extremely sensitive to brownouts. It would get funked up and need to be power cycled. Plug it into a UPS , no more wifi problems either.
I learned this the hard way when i moved to an old building in the east village of NYC and had 3 motherboards/cpu fail within a 3 month period.
• Re: (Score:2, Insightful)
by lukas84 (912874)
That's not an Online UPS, so it won't protect against all grid issues. And Online UPS are expensive and noisy.
• Re: (Score:2, Interesting)
by a09bdb811a (1453409)
If you notice that your lights dim a little bit when your fridge compressor or AirCon comes on, that is a recipe for a computer failure.
Why? Doesn't the computer's PSU have enough juice in it to survive a quick dip in voltage? Besides, almost all PSUs are rated ~90-260V, so I always assumed if it dips from 230V, it won't matter.
Occasionally my lights dim but I don't seem to have had problems. I'm still waiting for my decade-old P3 to die so it can be replaced by an Atom board, but the darn thing keeps on ru
• by The Grim Reefer2 (1195989) on Saturday October 10, 2009 @04:25PM (#29705813)
Most home computer hardware failures come from "brownouts".
If you notice that your lights dim a little bit when your fridge compressor or AirCon comes on, that is a recipe for a computer failure. Spend $50 get a UPS [amazon.com]
Btw, i noticed that my linksys wifi router was also extremely sensitive to brownouts. It would get funked up and need to be power cycled. Plug it into a UPS , no more wifi problems either.
I learned this the hard way when i moved to an old building in the east village of NYC and had 3 motherboards/cpu fail within a 3 month period.
What you really need in the case you describe is a good line conditioner. I didn't look at the 'UPS' you mentioned, but many in that price range are not a true UPS and will still allow for under voltage to occur, albeit for a shorter period if you're lucky. .
• by gd2shoe (747932)
I doubt it was the dips that killed your equipment. More likely, it was the spikes on the line that shortened their life. (same crummy electric grid that caused your brown outs) Of course, each dip can be accompanied by a spike as the power recovers. As the other poster here mentioned, its not a matter of keeping power to your devices, it's a matter of conditioning the power that's coming in.
• You have a source to back that up? Because if not, I'm calling shenanigans. That seems real unlikely for a number of reasons:
1) This would be a recipe for lawsuits. After all, this situation of momentary power drops happens ALL the time on all kinds of circuits. If computers weren't able to handle it, that'd be a great way to get sued. With consumer devices you don't get to say "Oh this thing is super sensitive you have to take all kinds of measures to protect it." You device is expected to deal with common
• I concede that i was incorrect to place the blame on the brownouts specifically. I should have said home PC hardware failures are caused mostly by electrical problems.. I mention the brownouts because that is something visible (as opposed to the spikes.)
And getting a cheap UPS solved the problem. Specifically I got an , which was around $50. [apc.com]
If you spend $500 to $5000 on a computer (or other electronics), it is a good investment to protect it with a $50 UPS.
• Microscope (Score:4, Informative)
by grapeape (137008) <mpope7@NOSpam.kc.rr.com> on Saturday October 10, 2009 @03:59PM (#29705649) Homepage
I like the Microscope products...their newest version Microscope duo boots off of a USB stick. For machines that dont boot at all they also have a diagnostic card, its basically a pci card that has an led readout that give a series of post codes that can help diagnose if its the board, a card, memory, etc. They can be found at http://www.micro2000.com/ [micro2000.com]
The handiest piece of diagnostic gear I use is actually a simple power supply tester. You would be amazed how many systems that appear to power up are actually suffering from a dead -5 or +5 rail on the powersupply. Many tend to think if the fans spinning the powersupply is ok but thats often not the case. The best part is they are cheap...around $10 for a basic one.
• by Cylix (55374)
A power supply tester is mostly useless. The basic features of any modern motherboard include sensors which display the voltage readings.
A power supply tester simply identifies whether or not an unloaded voltage source is within the 5% variance. It would have to be extremely poor condition to not pass this test (sic, obviously failed and identified from the same common tools everyone has access too).
In many circumstances I find it necessary to apply load to a power supply in order to quickly identify the fa
• Hiren's... (Score:4, Insightful)
by Zakabog (603757) <john@j[ ]g.com ['mau' in gap]> on Saturday October 10, 2009 @04:05PM (#29705681)
Hiren's BootCD [hiren.info] contains a bunch of different utilities for doing just this. Plus it's bootable, so if you can't get into the OS you can still use the CD. It can do just about anything you'd need to in order to diagnose and repair a machine. You just gotta find it (usually the pirate bay or other torrent sites are a good place to look.)
• Re: (Score:3, Insightful)
by DigiShaman (671371)
1. Hiren's BootCD is the only thing you need to diagnose hardware, repair, and transfer data. You can even make a bootable USB thumb drive instead of using it as a CD. It's the gift of the Gods!
2. Be aware that just about every program in this collection is pirated. If you are making a profit through using this boot CD, purchase the F-ing programs by themselves!!! It's one thing to pirate software, it's quite another to ride off the backs of others work.
• Hardware tester (Score:3, Informative)
by iammani (1392285) on Saturday October 10, 2009 @04:06PM (#29705689)
When you no longer trust your CPU/motherboard, I am afraid the only option to test them would be a hardware circuit (which can make decisions using its own CPU) specifically designed for your motherboard/processor. Which I believe only manufacturer will have access to. If you are looking for a more practical solution. The only way is to eliminate the possibility of all other hardware failing (by simply removing them or using them on a good machine) and assuming it must be CPU/motherboard issue(which means you may have to junk them both and buy new ones). And dont forget to test you power supply unit (not checking it on my old PC cost me hell a lot of hours)
• by Cylix (55374)
Most hardware is 'dumb' and does not have fault latches.
This is a cost that was avoided in order to make cheap motherboards and system components.
Hardware troubleshooting is in no form about trust. It is applying a series of logical steps designed to isolate and repair failures.
• by Wrath0fb0b (302444) on Saturday October 10, 2009 @04:15PM (#29705747)
http://sourceforge.net/apps/trac/smartmontools/wiki [sourceforge.net] is great for finding out what the drives think about their own health. Things to look out for are spin-retry counts (which lead to that annoying 2-5 seconds freeze), high reallocated sector counts (never never never use chkdsk to attempt to fix a broken hard drive. With the robustness of modern journaling file systems (HFS, extN, NTFS), storage errors are almost always hardware errors. Running chkdsk stresses the drive just as it's failing and usually pushes it over the edge -- and then users complain that you can't recover their data.
• prime 95 (Score:3, Interesting)
by LordKronos (470910) on Saturday October 10, 2009 @04:19PM (#29705775) Homepage
Prime 95 is a good test of CPU/RAM, as well as to see if the system remains stable under peak temperature. It's often used to burn in overclocked machines.
• by evilviper (135110) on Saturday October 10, 2009 @04:37PM (#29705917) Journal
but how do you go about testing CPU, motherboard and graphics card trio to find which is to blame? Replacing them one by one isn't really an option. Do you know any software that would help the way memtest helps with RAM?
There is no way to tell, with software, whether your PSU, CPU, or motherboard is to blame, in the overwhelming majority of cases.
It's just idiotic to say "Replacing them one by one isn't really an option". In fact, that's by far the best option. I don't run memtest for a week to find out I have bad RAM, I take 30 seconds to swap it, and find out, for certain, in no time. PSUs are equally easy to swap, AND are the more likely component to fail, so that's the best place to start.
If you don't know whether it's CPU or the MoBo, buy a new motherboard... Vastly more likely to be the cause, and pretty damn cheap just as soon as they're no longer brand new. Of course CPUs fail, but it's likely to be obvious from a visual inspection if they've been installed wrong, or otherwise abused.
• by Doppler00 (534739)
I agree. When I build a new system I first:
memtest86+
cpu test with something like prime95
CPU+GPU test with prime95 and then another 3D game running in the background.
If it survives that last test, then it's good. I've found overheating of my system to be the main cause of crashes. I've actually had to underclock my RAM to get it stable. If something does fail, I swap that component or add more fans and try again.
• by Cylix (55374)
Unfortunately you left out one major component in this troubleshooting scenario.
Before applying any troubleshooting steps you must first create a verifiable test condition to reproduce the problem.
If the problem cannot be reliably reproduced it will be difficult to isolate the fault with physical isolation, reduction or replacement of specific components.
Before beginning on such an endeavor strive to create a scenario in which the problem can be reproduced quickly.
Waiting a week for the fault to reproduce c
• by MoFoQ (584566)
never heard of prime95?
it's been used for years to check stability in rigs by overclocking and gaming enthusiasts.
They even have various different "levels" of FFT tests to limit the torture tests to within CPU cache levels which tests the CPU...or more than tests the RAM, PSU, etc.
Prime95 [mersenne.org]
• I've done a significant amount of PC construction and reconstruction: approximately 60 from-scratch builds in 20 years. One thing that that has taught me is: do not bother to try to diagnose motherboard or CPU faults: just replace them, end of story.
Even Integrated Motherboards can be had for £40, and CPUs for £25. You can get dual-core 1.6ghz Atom Integrated-everything-including-CPU motherboards for £90.
For the amount of time and effort spent unscrewing components and testing combinatio
• by vxvxvxvx (745287)
Other than that: if you cannot find any evidence of firmware upgrades to potentially fix an unreliable machine - throw out the power supply, the motherboard and the CPU, without hesitation (or get them replaced under warranty).
If you've only ruled it down to one of those 3, how will you get the companies to replace those parts under warranty?
• by Linker3000 (626634) on Saturday October 10, 2009 @04:41PM (#29705945) Journal
I stress my Linux boxes by telling them that if they develop a fault I'll re-image them with Vista.
Not a single one has dared to fail on me yet.
• by Artifakt (700173)
Take all your consumer electronics to the movies once a year. Set them on the couch, give them a bowl of popcorn buttered with WD40, and let them watch "The Brave Little Toaster". (Popcorn is optional).
• gcc is an incredibly good test application. it's horrendously cpu-intensive, and it is designed to eat whatever physical memory is available. compiling c++ applications is particularly memory-intensive, but the best test of both disk and memory has to be simply to compile the linux kernel.
if you have multiple cores, you can use "make -j {number of cores + 1}" and this will test all of the CPUs, as well. if you particularly want to stress things, make that "make -j {number of cores * 2}" instead.
• Re: (Score:2, Funny)
by cschepers (1581457)
Or you could install Gentoo. That'll eat up the CPU, RAM, and hard disk for darn near eternity.
• If your hardware is suspect, then the output of any program running on that hardware would also be suspect. Keep that in mind when you run diagnostic software - if it says the system is good then it probably is but if the software reports errors then the reported error isn't necessarily accurate. I've also seen these programs detect failures in perfectly working systems. I've tested many of these "technician on a disk" programs over the years and Microscope is the best of a bad bunch.
A more productive diag
• Your average PC hardware has utterly no way to "test" it. You can sort of test RAM - to the point of identifying there is a failure somewhere in the memory. OK, if you have four DIMMs what does that mean? Well, it means you have a RAM problem somewhere.
Motherboard? Not really any sort of testing possible. There are some "pretend" diagnostic tools that will try to tell you if something fails, but what exactly does that mean? Nothing. If you have a ATAPI DVD drive and a SATA hard drive I assure you tha
• 1. Check the software
2. It's probably the software
3. Really, it's going to be the software
...
87. OK, now you should run some diagnostics
Really. The bottom line is that computers and their parts (especially non-moving ones like processors and RAM), once they're burned in and assuming you don't try to run them overclocked for twenty years without rotating them out, are pretty reliable. I can't count more than a couple instances of hardware failure post burn-in across about fifteen different home machines
• Toast and Pi and various other CPU stability test programs will let you test the CPU.
Go into system configuration with windows and turn off auto-reboot, so that if the machine blue screens, you can see what the error code is. Sometimes that will let you isolate it to graphics or the motherboard.
Ultimately, the way to find out IS to replace the components one by one. If you have several machines, or spares from an older machine, you should swap each component and run the machine until either you get a cras
• Power supply (Score:3, Interesting)
by Alioth (221270) <no@spam> on Saturday October 10, 2009 @05:48PM (#29706359) Journal
You didn't mention the power supply.
In my experience, a "crashy machine" is almost always down to the PSU. Out of the dozens of "crashy machines" I've had to fix, only one was due to bad memory. The rest were *all* down to faulty power supplies, and all of those were due to capacitors that had failed.
I have an oscilloscope so I can easily test for ripple without needing to open up the power supply and look for the obvious signs (bulging capacitors, maybe ones that have leaked). We've had dozens of machines at work with supplies that have gone bad this way. Bad capacitors have been a real problem in recent years. Four years ago, it wasn't just in power supplies either - we had to return 70 machines to Hewlett-Packard under warranty after the capacitors on the motherboard began failing after 3 months of use. We've not seen anything on that scale on motherboards since, but we still have frequent problems with power supplies failing from "capacitor plague".
A machine of mine was actually killed by a sudden power supply failure - the PSU let the magic smoke out with a loud "bang", and there was the sound of stuff richocheting around the computer's case. That sound turned out to be bits of exploding chips on the motherboard. The only thing that survived that incident was the CD-ROM drive - all other components were destroyed.
• What's the best software to change a tire on your car and find the leak?
Software can check quite a few things, but for the most part during a short time interval, digital hardware is either working or it isn't. So software performance tests may not be very good at revealing something marginal.
Beyond a few software tests and ruling some things out by substitution, it generally takes someone with some hardware troubleshooting skills, and some test equipment.
Of course test equipment starts with your senses.
• I had this when I tried to run Windows 7 on my old machine (32bit). Random crashes, 7 or so alone in the first 48h. This machine never gave me issues with Linux, Windows XP or Vista. So I run Prime95 on Win 7 on it - guaranteed error in about 2h of processing. And now comes the odd part: Prime95 runs straight 9h on both XP and Vista without any problems. Anyone else got such problems?
• http://www.passmark.com/products/bit.htm [passmark.com]
burnintest. have used it for years. works fine. some systems which would run fine for days and then crash were driving us crazy. this software found memory, video and cpu problems. free version of version i bought only ran for 15 minutes. might be enough to find your problem. windows only though so that might be a problem.
• by GuyFawkes (729054) on Saturday October 10, 2009 @06:21PM (#29706537) Homepage Journal
Of course with time you get experience, dry joints tend to follow power tracks on a PCB, and by gently flexing you can hear them tick.
Swapping out is the ONLY way.
I have systems with intermittent (heat activated) dry joints on a mobo, partly duff RAM, and partly duff (rebranded at higher clock) CPU. ONLY swapping out will find it.
HTH etc
• Lots of good posts so far, but one thing I also do and would suggest trying as well (depending on what the problem you are dealing with) is to also drop in a live cd of Ubuntu or Knoppix, install whatever app would also put a strain on whatever part of the system appears to be failing, and see if the problem occurs in another OS as well. I've seen Windows fail in some pretty interesting ways that seems like hardware is failing. But when testing with another OS and the problem doesn't reoccur, I often then s
• Check the event viewer for logged any errors or crashing drivers. It boggles my mind how many people don't know to check this, and how many nerds trying to help don't tell you to check this. Frankly many people don't know Windows even has such logs. It is essiential when trying to troubleshoot unexplained crashes on any platform that you RTFL (read the fricken LOGS).
Most crashes in windows are either hardware related or shitty drivers. Windows these days is resilient to crashing applications, but crappy
• RAM is easy to test using basic troubleshooting techniques: Remove some of it, see if the problem recurs. Replace some of it with good spares, see if the problem recurs. Etc, so on. memtest86 also does a decent job of finding bad modules if left to run long enough, but since it runs in isolation from the rest of the computer it will not detect certain corner cases of bad RAM.
Power supplies are similarly easy: Swap it out for a known good supply, and see if the problem recurs.
I've never had a CPU fail,
• by skogs (628589)
I've found the UBCD -- Ultimate Boot CD to be quite useful.
http://www.ultimatebootcd.com/ [ultimatebootcd.com]
It does come in handy, includes many of the necessary tools to determine HDD end of life etc.
It certainly isn't perfect, but I am amazed nobody has mentioned it yet in the discussion. Obviously real tools are on my bench, but when the poster specifically asked for software....this is the easiest and most broad spectrum solution.
• I recently diagnosed two desktop machines. One ended up having a bad stick of memory, with the original symptoms being a corrupted copy of Windows XP that wouldn't boot. The other a bad hard drive, the symptoms being it would hang during use randomly and even during boot.
I used Prime95 and Memtest86+ to detect the bad stick of memory. Prime95 quickly came up with a error during the stress test, and Memtest86+ also came immediately came up with errors. In the past I have since subtle errors with Memtest86+ t
• Half of your RAM issues wont' be able to be diagnosed with any piece of software. No RAM checking software will keep tabs on the operating speed of the RAM. Ditto with a CPU tester, there's hardware and socket adapters to help you plug in CPUs and test them with hardware.
My time spent in the hardware repair/replacement service has taught me that most software diagnostics just fall short. One place I worked for used a combo of Prime95 and some custom stress-testing software - almost every machine would pass
• There are some fairly straight forward applications that several readers have mentioned.
However, relying on software to determine a fault when no fault indicators are built into your motherboard is an inherently flawed logic.
The vast majority of systems today are quite dumb and have no reporting. Even on more expensive systems this reporting is still not the most reliable method of troubleshooting hardware.
That is to say that software cannot be helpful in the troubleshooting process. It can be immensely use
• QuickTech or QT (Score:3, Interesting)
by iq in binary (305246) <<moc.liamtoh> <ta> <yranib_ni_qi>> on Saturday October 10, 2009 @10:27PM (#29708165) Homepage
My shop uses it, works pretty well. A full scan can take up to 6 or 8 hours (we set up hardware diags before leaving for the night, and in the morning on a 24-channel KVM), but it is THOROUGH. VRAM, RAM, HDD, CPU, everything is tested and thoroughly. First step should be testing the PSU, then running QT.
• by bwave (871010) on Sunday October 11, 2009 @01:17AM (#29708881)
We have repaired about in excess of 50,000 machines, and I'll tell you the tools needed are very simple. The process we do is, open the machine, dust with air compressor (with humidity drier, you can pickup at sears a 4gal with drier for about $99, saves alot of money on $3-6 cans of air) and central vacuum system (a shopvac will work), then inspect the motherboard & video card for blown caps. Take off the cpu fan and inspect the compound, if it is home built, lord only knows what you'll find. Test the power supply with a digital power supply tester (one of the $12 lcd ones) if good, still open the power supply, look for blown caps. (many will have blown caps, and be causing sporadic problems the simplistic tester will not). See if machine will power on / boot. If it doesn't power on, or hangs on post, remove modem and nic if it's a seperate card, when these are blown by lightning will cause no post. Ensure the hard drive is mounted properly with 4 screws installed, less than that the vibrations will cause the drive to go bad. (don't care what operating specifications you show me, or what G-rating the drive has, this is the case) Then test memory with Memtest86+ 1.70, and the hard drive with one of the 3 versions of Seatools by seagate. (some versions will lock on some video/chipsets, if you get a long string of bad sectors on a hdd bigger than 320gb, that begin about 2/3rds way through drive, test with a different version to be sure, as there is a sector count issue with some large hds) The 3 versions are an older GUI one, the newest GUI one, and the text version. If you have even 1 bad sector - replace the drive. We do the above process on EVERY machine before we attempt to do anything else, it is well worth the couple hours it takes to do. If you make it this far, than 99% of the time, you're problem is malware/viruses. Run Combofix, look for files not removed by it, boot with Ultimate Boot CD (the WinPE based one) or something like Knoppix and manually remove them. Search the WIndows, Windows/System32, Windows/System32/Drivers directories for files created in the past month, anything suspcious is probably a malware. Rename those files. Look under Program Files, Program Files/Common, ProgramData, and Users/UserName/ApplicationData for suspicious directories and rename/delete, these are where your AlphaAntivirus, Windows Police Pro, UltimateAV, etc, like to hide. Boot back into windows, run Hi-Jack This!, remove any suspicious entries, reboot, anything left? If so, remove manually with bootcd. In add/remove programs, remove all unneccessary programs. Then run CWShredder, Malwarebytes Antimalware, Spybot, and AVG Antivirus. (Feel free to substitute legimate antimalware/antivirus tools in place of these 3, but we find these 3 work best for us. Install all Windows updates, update all sytem drivers, try browsing the internet for 2 or 3 minutes. If all seems ok, reboot one last time, and be sure you can browse the inet still. All done! This fixes pretty much everything. Other than specific issue your customer may have complained about. Also, be sure to check the amount of ram here are what we recommend, otherwise, with latest service packs, etc. machine will seem sluggish. Windows 95 - 96mb+, Windows 98/ME - 196mb+, Windows 2000 384mb+, Windows XP 640mb+, Windows Vista Home Basic 1Gb+, Windows Home Premium 2Gb+, Windows Vista Ultimate/Windows 7 4Gb+ If you don't give machine back with this amount of ram, your customer will swear machine is slower than when the brought to you, doesn't matter how untrue it is, doesn't matter how much malware you removed or how machine didn't even go into windows! CPUs/Video Card rarely go bad unless abused. Normally, your find a under-rated power supply, or defective power supply to blame. Also, if you're working with a notebook, be sure to dust the exhaust/intake vents, if still power down/lockups, you need to disassemble and recompound cpu/video chipset with Arctic Silver 5. The other thing is power problems, mouse lockups, etc many times are caused by bad batteries, try running w/o a batter installed, just ac adapter. Any battery older than 2 1/2 years old is suspect. And of course, look for broken dc power jacks.
Reality must take precedence over public relations, for Mother Nature cannot be fooled. -- R.P. Feynman
Working...
|
{
"url": "http://hardware.slashdot.org/story/09/10/10/1823232/Software-To-Diagnose-Faulty-PC-Hardware",
"source_domain": "hardware.slashdot.org",
"snapshot_id": "crawl=CC-MAIN-2014-35",
"warc_metadata": {
"Content-Length": "308626",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:RTR54LJ64DKABTRSSCFRGPWDP3BEZP32",
"WARC-Concurrent-To": "<urn:uuid:ab5128e3-d5ff-4111-8cee-605a5cbd96fa>",
"WARC-Date": "2014-08-23T11:29:09Z",
"WARC-IP-Address": "216.34.181.48",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:5R6UHU3FIT44OMJSJPJZL5IQ47Y5CQCQ",
"WARC-Record-ID": "<urn:uuid:cae6dbed-8da8-40b5-94ba-1755e61d617b>",
"WARC-Target-URI": "http://hardware.slashdot.org/story/09/10/10/1823232/Software-To-Diagnose-Faulty-PC-Hardware",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:47d35c64-8361-480a-9f80-a472d62ddc3d>"
},
"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,
2,
3,
4,
5,
27,
41,
50,
51,
96,
97,
115,
157,
1162,
1228,
1229,
1270,
1271,
1288,
1320,
1321,
1394,
1395,
1570,
1571,
1609,
1610,
1694,
1695,
1751,
1752,
2175,
2176,
2211,
2212,
2298,
2299,
2478,
2479,
2572,
2573,
2613,
2614,
2696,
2819,
2820,
3310,
3311,
3777,
3778,
3949,
3950,
3966,
4007,
4008,
4090,
4091,
4132,
4133,
4275,
4276,
4399,
4400,
4434,
4435,
4632,
4633,
4665,
4666,
4805,
4806,
4849,
4850,
4942,
4943,
5100,
5389,
5390,
5677,
5678,
5720,
5721,
5757,
5758,
6175,
6176,
6316,
6317,
6352,
6353,
6641,
6642,
6676,
6677,
7202,
7203,
7233,
7234,
7595,
7596,
7750,
7751,
7777,
7778,
7811,
7812,
7837,
8223,
8247,
8248,
8489,
8490,
8692,
8693,
8726,
8727,
8755,
8756,
9165,
9166,
9189,
9190,
9372,
9373,
9492,
9493,
9535,
9536,
9558,
9774,
10143,
10235,
10236,
10576,
10577,
10890,
10891,
11693,
11694,
11724,
11725,
11884,
11885,
11980,
11981,
12345,
12346,
12377,
12378,
12464,
12465,
12547,
12548,
12778,
12823,
12824,
12905,
13069,
13070,
13154,
13155,
13400,
13401,
13410,
13443,
13444,
13475,
13476,
13659,
13660,
13693,
13694,
13725,
13726,
13919,
13920,
13972,
13973,
14052,
14053,
15235,
15690,
15691,
16124,
16125,
16680,
16681,
16718,
16719,
16750,
16751,
16838,
16839,
16993,
16994,
17083,
17084,
17304,
17305,
17342,
17343,
17370,
17371,
17482,
17483,
17724,
17725,
17917,
17918,
17960,
17961,
18035,
18036,
18213,
18214,
18478,
18479,
18889,
18890,
18934,
18935,
18959,
18960,
19216,
19217,
19305,
19306,
19332,
19514,
19515,
19605,
19606,
19733,
19734,
19773,
19774,
19856,
19857,
20135,
20136,
20222,
20223,
20287,
20288,
20462,
20655,
20656,
20804,
20805,
20837,
20838,
20864,
20865,
20982,
20983,
21016,
21017,
21047,
21048,
21191,
21192,
21393,
21394,
21583,
21584,
21670,
21671,
21737,
21738,
21914,
22109,
22110,
22260,
22261,
22527,
22528,
22554,
22956,
23088,
23089,
23483,
23484,
23747,
23748,
23856,
23857,
23984,
23985,
24023,
24024,
24134,
24135,
24510,
24511,
24885,
24886,
24909,
24910,
25054,
25055,
25328,
25329,
25445,
25446,
25483,
25484,
25590,
25945,
25977,
25978,
26007,
26008,
26209,
26210,
26481,
26482,
26525,
26526,
26601,
27271,
27294,
27295,
27358,
27359,
27456,
27457,
27597,
27598,
27675,
27676,
28292,
28293,
28329,
28330,
28416,
28417,
28577,
28578,
28662,
28663,
28889,
28890,
29024,
29025,
29383,
29384,
29694,
29695,
29723,
29724,
29774,
29791,
29834,
29918,
29919,
30176,
30177,
30200,
30201,
30288,
30289,
30413,
30414,
30581,
30582,
30701,
30702,
30752,
30753,
30775,
30776,
30804,
30805,
30901,
31074,
31075,
31102,
31103,
31358,
31359,
31522,
31523,
31612,
31613,
31640,
31641,
31875,
31876,
32000,
32001,
32086,
32087,
32191,
32192,
32242,
32243,
32270,
32271,
32480,
32481,
32776,
32777,
32992,
32993,
33020,
33021,
33050,
33152,
33646,
33647,
33674,
33675,
33933,
33934,
34191,
34192,
34218,
34252,
34297,
34298,
34306,
34307,
34355,
34356,
34732,
34733,
34823,
34824,
35040,
35041,
35260,
35261,
35301,
35302,
35393,
35394,
35435,
35436,
35707,
35708,
36378,
36379,
36757,
36758,
36835,
36836,
37063,
37064,
37235,
37236,
37290,
37291,
37683,
37743,
37744,
38073,
38074,
38167,
38306,
38307,
38341,
38342,
38516,
38517,
38529,
38530,
39047,
39421,
39422,
39566,
39949,
39950,
40057,
40058,
40089,
40090,
40112,
40113,
40177,
40178,
40234,
40235,
40333,
40334,
40576,
40577,
40854,
40855,
41100,
41101,
41378,
41379,
41623,
41624,
41717,
41718,
41860,
41861,
42051,
42052,
42159,
42160,
42203,
42204,
42328,
42329,
42639,
42640,
42710,
46938,
46939,
47043,
47044
],
"line_end_idx": [
2,
3,
4,
5,
27,
41,
50,
51,
96,
97,
115,
157,
1162,
1228,
1229,
1270,
1271,
1288,
1320,
1321,
1394,
1395,
1570,
1571,
1609,
1610,
1694,
1695,
1751,
1752,
2175,
2176,
2211,
2212,
2298,
2299,
2478,
2479,
2572,
2573,
2613,
2614,
2696,
2819,
2820,
3310,
3311,
3777,
3778,
3949,
3950,
3966,
4007,
4008,
4090,
4091,
4132,
4133,
4275,
4276,
4399,
4400,
4434,
4435,
4632,
4633,
4665,
4666,
4805,
4806,
4849,
4850,
4942,
4943,
5100,
5389,
5390,
5677,
5678,
5720,
5721,
5757,
5758,
6175,
6176,
6316,
6317,
6352,
6353,
6641,
6642,
6676,
6677,
7202,
7203,
7233,
7234,
7595,
7596,
7750,
7751,
7777,
7778,
7811,
7812,
7837,
8223,
8247,
8248,
8489,
8490,
8692,
8693,
8726,
8727,
8755,
8756,
9165,
9166,
9189,
9190,
9372,
9373,
9492,
9493,
9535,
9536,
9558,
9774,
10143,
10235,
10236,
10576,
10577,
10890,
10891,
11693,
11694,
11724,
11725,
11884,
11885,
11980,
11981,
12345,
12346,
12377,
12378,
12464,
12465,
12547,
12548,
12778,
12823,
12824,
12905,
13069,
13070,
13154,
13155,
13400,
13401,
13410,
13443,
13444,
13475,
13476,
13659,
13660,
13693,
13694,
13725,
13726,
13919,
13920,
13972,
13973,
14052,
14053,
15235,
15690,
15691,
16124,
16125,
16680,
16681,
16718,
16719,
16750,
16751,
16838,
16839,
16993,
16994,
17083,
17084,
17304,
17305,
17342,
17343,
17370,
17371,
17482,
17483,
17724,
17725,
17917,
17918,
17960,
17961,
18035,
18036,
18213,
18214,
18478,
18479,
18889,
18890,
18934,
18935,
18959,
18960,
19216,
19217,
19305,
19306,
19332,
19514,
19515,
19605,
19606,
19733,
19734,
19773,
19774,
19856,
19857,
20135,
20136,
20222,
20223,
20287,
20288,
20462,
20655,
20656,
20804,
20805,
20837,
20838,
20864,
20865,
20982,
20983,
21016,
21017,
21047,
21048,
21191,
21192,
21393,
21394,
21583,
21584,
21670,
21671,
21737,
21738,
21914,
22109,
22110,
22260,
22261,
22527,
22528,
22554,
22956,
23088,
23089,
23483,
23484,
23747,
23748,
23856,
23857,
23984,
23985,
24023,
24024,
24134,
24135,
24510,
24511,
24885,
24886,
24909,
24910,
25054,
25055,
25328,
25329,
25445,
25446,
25483,
25484,
25590,
25945,
25977,
25978,
26007,
26008,
26209,
26210,
26481,
26482,
26525,
26526,
26601,
27271,
27294,
27295,
27358,
27359,
27456,
27457,
27597,
27598,
27675,
27676,
28292,
28293,
28329,
28330,
28416,
28417,
28577,
28578,
28662,
28663,
28889,
28890,
29024,
29025,
29383,
29384,
29694,
29695,
29723,
29724,
29774,
29791,
29834,
29918,
29919,
30176,
30177,
30200,
30201,
30288,
30289,
30413,
30414,
30581,
30582,
30701,
30702,
30752,
30753,
30775,
30776,
30804,
30805,
30901,
31074,
31075,
31102,
31103,
31358,
31359,
31522,
31523,
31612,
31613,
31640,
31641,
31875,
31876,
32000,
32001,
32086,
32087,
32191,
32192,
32242,
32243,
32270,
32271,
32480,
32481,
32776,
32777,
32992,
32993,
33020,
33021,
33050,
33152,
33646,
33647,
33674,
33675,
33933,
33934,
34191,
34192,
34218,
34252,
34297,
34298,
34306,
34307,
34355,
34356,
34732,
34733,
34823,
34824,
35040,
35041,
35260,
35261,
35301,
35302,
35393,
35394,
35435,
35436,
35707,
35708,
36378,
36379,
36757,
36758,
36835,
36836,
37063,
37064,
37235,
37236,
37290,
37291,
37683,
37743,
37744,
38073,
38074,
38167,
38306,
38307,
38341,
38342,
38516,
38517,
38529,
38530,
39047,
39421,
39422,
39566,
39949,
39950,
40057,
40058,
40089,
40090,
40112,
40113,
40177,
40178,
40234,
40235,
40333,
40334,
40576,
40577,
40854,
40855,
41100,
41101,
41378,
41379,
41623,
41624,
41717,
41718,
41860,
41861,
42051,
42052,
42159,
42160,
42203,
42204,
42328,
42329,
42639,
42640,
42710,
46938,
46939,
47043,
47044,
47054
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 47054,
"ccnet_original_nlines": 512,
"rps_doc_curly_bracket": 0.00008500999683747068,
"rps_doc_ldnoobw_words": 1,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4039176404476166,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.044600699096918106,
"rps_doc_frac_lines_end_with_ellipsis": 0.0038986399304121733,
"rps_doc_frac_no_alph_words": 0.20662982761859894,
"rps_doc_frac_unique_words": 0.2448875904083252,
"rps_doc_mean_word_length": 4.5112409591674805,
"rps_doc_num_sentences": 463,
"rps_doc_symbol_to_word_ratio": 0.003716730047017336,
"rps_doc_unigram_entropy": 6.304407119750977,
"rps_doc_word_count": 7873,
"rps_doc_frac_chars_dupe_10grams": 0.04299350082874298,
"rps_doc_frac_chars_dupe_5grams": 0.07509080320596695,
"rps_doc_frac_chars_dupe_6grams": 0.05169355869293213,
"rps_doc_frac_chars_dupe_7grams": 0.04718866944313049,
"rps_doc_frac_chars_dupe_8grams": 0.04578088968992233,
"rps_doc_frac_chars_dupe_9grams": 0.04409155994653702,
"rps_doc_frac_chars_top_2gram": 0.003660219954326749,
"rps_doc_frac_chars_top_3gram": 0.011008810251951218,
"rps_doc_frac_chars_top_4gram": 0.012303969822824001,
"rps_doc_books_importance": -3866.0380859375,
"rps_doc_books_importance_length_correction": -3866.0380859375,
"rps_doc_openwebtext_importance": -2013.4415283203125,
"rps_doc_openwebtext_importance_length_correction": -2013.4415283203125,
"rps_doc_wikipedia_importance": -1582.04541015625,
"rps_doc_wikipedia_importance_length_correction": -1582.04541015625
},
"fasttext": {
"dclm": 0.0634988471865654,
"english": 0.95139080286026,
"fineweb_edu_approx": 1.7112516164779663,
"eai_general_math": 0.2751047611236572,
"eai_open_web_math": 0.29882168769836426,
"eai_web_code": 0.10467904806137085
}
}
|
{
"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": "-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": "5",
"label": "Comment Section"
},
"secondary": {
"code": "18",
"label": "Q&A Forum"
}
},
"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
|
-759,574,634,154,546,600
|
tag:blogger.com,1999:blog-5215551487816981140.post1905535936472058955..comments2017-02-19T13:31:37.823-08:00Comments on ORA-00001: Unique constraint violated: Calling a SOAP web service from PL/SQL by extending the FLEX_WS_APIMorten Bratenhttp://www.blogger.com/profile/12300886042835631690noreply@blogger.comBlogger6125tag:blogger.com,1999:blog-5215551487816981140.post-65269886559826303312013-05-17T00:40:08.823-07:002013-05-17T00:40:08.823-07:00@Piotr: Do you have Apex 4 installed in your datab...@Piotr: Do you have Apex 4 installed in your database? If so, please try out APEX_WEB_SERVICE.MAKE_REQUEST and pass the p_wallet_path and p_wallet_pwd parameters to do a call to an https site.<br /><br />See http://docs.oracle.com/cd/E23903_01/doc/doc.41/e21676/apex_web_service.htm#BABEEICD for more info.<br /><br />- MortenMorten Bratenhttp://www.blogger.com/profile/12300886042835631690noreply@blogger.comtag:blogger.com,1999:blog-5215551487816981140.post-21095830118649111582013-05-16T10:51:06.774-07:002013-05-16T10:51:06.774-07:00Dear mr Braten, Could please help me out. I am tr...Dear mr Braten,<br /><br />Could please help me out. I am trying to use the FLEX_WS_API for calling a SOAP service using certificates. I have created a wallet using the wallet manager. However, I have to deal with a root certificate and a system certificate. These certificates are used for authentication. When using the ewallet.p12 in the tool soapui I get a valid response. But when using the command UTL_HTTP.set_wallet and then other UTL_HTTP commands I get "validation certificate failed". I am using oracle 10.2 on Windows. Can you please help me out?Piotr Chabot Stadhoudershttp://www.blogger.com/profile/05171015351900902373noreply@blogger.comtag:blogger.com,1999:blog-5215551487816981140.post-56415572730453446812010-02-24T05:23:49.287-08:002010-02-24T05:23:49.287-08:00hmmm, it looks like my xml got hidden by the brows...hmmm, it looks like my xml got hidden by the browser - here it is again using [] instead of < ><br />----><br />When the response node contains single instances of each sub-node it works fine. However, one of my web services returns sub-node values that contain repeated sub-nodes i.e. an array of values<br />e.g.<br /> [ApplicationsReponse]<br /> [ApplicationsResult]<br /> [string][/string]<br /> [string][/string]<br /> [string][/string]<br /> [/ApplicationsResult]<br /> [/ApplicationsReponse]<br /><br />At the moment, flex_ws_util.get_value() returns null when I pass it 'ApplicationsResult' as p_name, rather than the '[string][/string][str...' value as I'd expect.<br /><br />How do I extract the [string] values? (at the moment I parse the entire returned XML using TABLE(XMLSEQUENCE(EXTRACT( )Richardnoreply@blogger.comtag:blogger.com,1999:blog-5215551487816981140.post-13697135635464578982010-02-24T05:21:32.871-08:002010-02-24T05:21:32.871-08:00Thanks for this, it works brilliantly. I have impl...Thanks for this, it works brilliantly. I have implemented it and now use it with a user validation solution (a kind of 'SSO-lite').<br /><br />When the response node contains single instances of each sub-node it works fine. However, one of my web services returns sub-node values that contain repeated sub-nodes i.e. an array of values<br />e.g.<br /> <br /> <br /> <br /> <br /> <br /> <br /> <br /><br />At the moment, flex_ws_util.get_value() returns null when I pass it 'ApplicationsResult' as p_name, rather than the ' values? (at the moment I parse the entire returned XML using TABLE(XMLSEQUENCE(EXTRACT( )<br /><br />Thanks again,<br />RIchardRichardnoreply@blogger.comtag:blogger.com,1999:blog-5215551487816981140.post-75922540777376555612009-10-23T06:50:05.678-07:002009-10-23T06:50:05.678-07:00@Anonymous: The main difference is that the utl_d...@Anonymous:<br /><br />The main difference is that the utl_dbws package is a wrapper for Java code, while the flex_ws_api package and my companion t_soap_envelope type are written in PL/SQL.<br /><br />- MortenMorten Bratenhttp://www.blogger.com/profile/16506692325808919895noreply@blogger.comtag:blogger.com,1999:blog-5215551487816981140.post-80413565386317756962009-10-08T08:45:01.638-07:002009-10-08T08:45:01.638-07:00How does this differ from the built-in utl_dbws pa...How does this differ from the built-in utl_dbws package?<br /><br />http://www.oracle-base.com/articles/10g/utl_dbws10g.phpAnonymousnoreply@blogger.com
|
{
"url": "http://ora-00001.blogspot.com/feeds/1905535936472058955/comments/default",
"source_domain": "ora-00001.blogspot.com",
"snapshot_id": "crawl=CC-MAIN-2017-09",
"warc_metadata": {
"Content-Length": "14429",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:NPDWGDNCHY3SO6RDKDZEZCMD3F5SAQSC",
"WARC-Concurrent-To": "<urn:uuid:a593be32-6e40-4434-8d4f-95bde6d7f557>",
"WARC-Date": "2017-02-22T08:26:51Z",
"WARC-IP-Address": "172.217.7.161",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:NAYTYZMPW3SILP3HGV6EPPRVU3XOET67",
"WARC-Record-ID": "<urn:uuid:22f40c92-8493-456f-838f-b0bc31cd2b39>",
"WARC-Target-URI": "http://ora-00001.blogspot.com/feeds/1905535936472058955/comments/default",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5f3207c1-2660-47a2-ae4a-1758b015e27a>"
},
"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
],
"line_end_idx": [
4475
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4475,
"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.20164233446121216,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.046532850712537766,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.45164233446121216,
"rps_doc_frac_unique_words": 0.44570136070251465,
"rps_doc_mean_word_length": 7.823529243469238,
"rps_doc_num_sentences": 95,
"rps_doc_symbol_to_word_ratio": 0.016423359513282776,
"rps_doc_unigram_entropy": 4.903557300567627,
"rps_doc_word_count": 442,
"rps_doc_frac_chars_dupe_10grams": 0.189126655459404,
"rps_doc_frac_chars_dupe_5grams": 0.29323306679725647,
"rps_doc_frac_chars_dupe_6grams": 0.29323306679725647,
"rps_doc_frac_chars_dupe_7grams": 0.27819550037384033,
"rps_doc_frac_chars_dupe_8grams": 0.22325043380260468,
"rps_doc_frac_chars_dupe_9grams": 0.20647773146629333,
"rps_doc_frac_chars_top_2gram": 0.009253899566829205,
"rps_doc_frac_chars_top_3gram": 0.010410640388727188,
"rps_doc_frac_chars_top_4gram": 0.011567380279302597,
"rps_doc_books_importance": -468.0118103027344,
"rps_doc_books_importance_length_correction": -468.0118103027344,
"rps_doc_openwebtext_importance": -317.64208984375,
"rps_doc_openwebtext_importance_length_correction": -317.64208984375,
"rps_doc_wikipedia_importance": -201.483154296875,
"rps_doc_wikipedia_importance_length_correction": -201.483154296875
},
"fasttext": {
"dclm": 0.14449834823608398,
"english": 0.6500370502471924,
"fineweb_edu_approx": 1.5139750242233276,
"eai_general_math": 0.19603711366653442,
"eai_open_web_math": 0.1515500545501709,
"eai_web_code": 0.792779803276062
}
}
|
{
"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.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": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "1",
"label": "Leftover HTML"
},
"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": "5",
"label": "Comment Section"
},
"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": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-1,102,424,126,086,198,400
|
NativeScript and Vue.js: Toast Plugin
We’ll start off by creating a new NativeScript Vue application:
# Install the NativeScript CLI
npm install nativescript -g
# New NativeScript Vue project
tns create NSVueToast –template nativescript-vue-template
# Change directory
cd NSVueToast
# Run on iOS
tns run ios
We can then add the NativeScript plugin:
# Add the NativeScript Toast plugin
tns plugin add nativescript-toast
I’ll then replace everything in app.js with the following:
const Vue = require(‘nativescript-vue’);
// Import the NativeScript Toast plugin
const Toast = require(‘nativescript-toast’);
new Vue({
template: `
<page>
<action-bar title=”NativeScript Toast”></action-bar>
<stack-layout>
<text-field v-model=”message”></text-field>
<button @tap=”showToast()” text=”Show Toast”></button>
</stack-layout>
</page>
`
}).$start();
We’re importing Toast from nativescript-toast and this allows us to use it inside of our Vue instance. We also have a simple template – one with a text field and a button – the button is tapped I want our toast to appear.
new Vue({
data: {
message: ‘Hello NativeScript Vue’
},
methods: {
showToast() {
const myToast = Toast.makeText(this.message, ‘long’);
myToast.show();
}
},
Awesome! Our text field is now prepopulated with a message and our showToast() method will show the text of that message with .a ‘long’ duration. If you’re confused why this.message is referring to the message string within our data object, it’s because Vue proxies everything to be referrenced in such a way.
|
{
"url": "https://swftovideoconverter.net/nativescript-and-vue-js-toast-plugin/",
"source_domain": "swftovideoconverter.net",
"snapshot_id": "crawl=CC-MAIN-2022-49",
"warc_metadata": {
"Content-Length": "34357",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XGV7AX73ALDW42DDLGE3BFZO7IYEO5E7",
"WARC-Concurrent-To": "<urn:uuid:d5f478ae-9369-45a2-9753-8bd78103ec91>",
"WARC-Date": "2022-11-26T15:09:26Z",
"WARC-IP-Address": "176.223.109.83",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:VJQKL3NFZ7MRQYCEZNGGMTFNYCJR6HSA",
"WARC-Record-ID": "<urn:uuid:52574924-262b-4cf2-9026-c530f4e3c3b3>",
"WARC-Target-URI": "https://swftovideoconverter.net/nativescript-and-vue-js-toast-plugin/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e5246223-9068-40ca-bc8f-2942371a71ea>"
},
"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-199\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,
38,
39,
103,
104,
135,
163,
164,
195,
253,
254,
273,
287,
288,
301,
313,
314,
355,
356,
392,
426,
485,
486,
527,
528,
568,
613,
614,
624,
636,
643,
696,
711,
755,
810,
826,
834,
836,
849,
850,
1072,
1073,
1083,
1091,
1125,
1128,
1139,
1153,
1207,
1208,
1224,
1226,
1229,
1230
],
"line_end_idx": [
38,
39,
103,
104,
135,
163,
164,
195,
253,
254,
273,
287,
288,
301,
313,
314,
355,
356,
392,
426,
485,
486,
527,
528,
568,
613,
614,
624,
636,
643,
696,
711,
755,
810,
826,
834,
836,
849,
850,
1072,
1073,
1083,
1091,
1125,
1128,
1139,
1153,
1207,
1208,
1224,
1226,
1229,
1230,
1539
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1539,
"ccnet_original_nlines": 53,
"rps_doc_curly_bracket": 0.005847950000315905,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2337278127670288,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.008875739760696888,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.30177515745162964,
"rps_doc_frac_unique_words": 0.5784313678741455,
"rps_doc_mean_word_length": 5.833333492279053,
"rps_doc_num_sentences": 13,
"rps_doc_symbol_to_word_ratio": 0.01479289960116148,
"rps_doc_unigram_entropy": 4.512537956237793,
"rps_doc_word_count": 204,
"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.05042016878724098,
"rps_doc_frac_chars_top_3gram": 0.03025210089981556,
"rps_doc_frac_chars_top_4gram": 0.043697480112314224,
"rps_doc_books_importance": -146.25103759765625,
"rps_doc_books_importance_length_correction": -134.7146759033203,
"rps_doc_openwebtext_importance": -87.64599609375,
"rps_doc_openwebtext_importance_length_correction": -87.64599609375,
"rps_doc_wikipedia_importance": -71.16622161865234,
"rps_doc_wikipedia_importance_length_correction": -57.83140563964844
},
"fasttext": {
"dclm": 0.10354346036911011,
"english": 0.5094351172447205,
"fineweb_edu_approx": 1.3034685850143433,
"eai_general_math": 0.28816521167755127,
"eai_open_web_math": 0.06496787071228027,
"eai_web_code": 0.8003684282302856
}
}
|
{
"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": "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
|
6,188,203,724,715,222,000
|
Customer email going to /dev/null
trumpetx
Member
Apr 3, 2004
23
0
151
I currently have a customer who reported his email stopped coming in sometime in the past 3 days. I have confirmed this and by checking my exim_mainlog I believe that his mail is being sent to /dev/null.
I have no idea why or how to change this... his settings in cPanel are correct, and I have no idea how this could have been changed. It's possible my prognosis is incorrect. So, here's what I've found.
The failing message:
Code:
2006-10-09 09:26:08 cwd=/var/spool/exim 3 args: /usr/sbin/exim -Mc 1GWv8t-0003br-4s
2006-10-09 09:26:09 1GWv8t-0003br-4s => /dev/null <[email protected]> R=central_user_filter T=**bypassed**
2006-10-09 09:26:09 1GWv8t-0003br-4s Completed
2006-10-09 09:26:09 1GWv8r-0003bj-Tp => xxxx <[email protected]> R=sa_localuser T=local_sa_delivery
2006-10-09 09:26:09 1GWv8r-0003bj-Tp Completed
The good message (tested on an address on my account -- same server):
Code:
2006-10-09 09:19:50 1GWv2s-0003Vs-NE <= [email protected] H=(xxxx.xxxxxxxxx.net) [204.89.253.13] P=esmtp S=730 [email protected]
om T="(no subject)"
2006-10-09 09:19:50 cwd=/var/spool/exim 3 args: /usr/sbin/exim -Mc 1GWv2s-0003Vs-NE
2006-10-09 09:19:50 1GWv2s-0003Vs-NE => frank <[email protected]> R=virtual_user T=virtual_userdelivery
2006-10-09 09:19:50 1GWv2s-0003Vs-NE Completed
Any ideas what setting needs to be changed? Either from the administrator end or the client end? This is happening with some, not all (confirmed), of my customers.
sparek-3
Well-Known Member
Aug 10, 2002
1,983
218
343
cPanel Access Level
Root Administrator
Check to see if the user has any e-mail filters set up. I would bet that they do and one of those filters is being triggered. I don't know if its possible to determine which particular filter is causing this (I've never been able to figure it out), but you can remove all of the filters by doing:
mv /etc/vfilters/domain.com /etc/vfilters/domain.com.old
on the shell.
trumpetx
Member
Apr 3, 2004
23
0
151
that worked!
now, why on earth would it work for some customers and not others? is this a setting that they changed?
sparek-3
Well-Known Member
Aug 10, 2002
1,983
218
343
cPanel Access Level
Root Administrator
Users have the ability to create e-mail filters in their control panel. Personally, I would not recommend using e-mail filters. Filters work in just the way you have seen. A message that matches a specific filter is removed, the user never knows the message was not receive, the sender never knows the message was not received, it can just create a lot of problems.
Also to keep in mind, by using e-mail filters, if you are filtering the body of a message for a specific term, that term may show up in the uuencoding of an e-mail attachment, meaning that the message would not be received. In my opinion, the better solution is to use SpamAssassin if you are wanting to control your spam as it offers better solutions to this than by just creating e-mail filters.
|
{
"url": "https://forums.cpanel.net/threads/customer-email-going-to-dev-null.58879/",
"source_domain": "forums.cpanel.net",
"snapshot_id": "crawl=CC-MAIN-2020-50",
"warc_metadata": {
"Content-Length": "93462",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:TZALW6E5SBFASIRAPEKHWNW3YQEB4ORT",
"WARC-Concurrent-To": "<urn:uuid:7ed767ba-d960-40d0-b777-5422bd290d22>",
"WARC-Date": "2020-11-25T05:30:38Z",
"WARC-IP-Address": "104.22.15.117",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:6DISJHSMVPDLMKFKCNJUB2KBRBHXYFZG",
"WARC-Record-ID": "<urn:uuid:881af5e2-553f-4d96-b227-ec1ab73daa9c>",
"WARC-Target-URI": "https://forums.cpanel.net/threads/customer-email-going-to-dev-null.58879/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d66b4295-34dd-49e9-9a1c-eee215b53486>"
},
"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-27.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,
35,
44,
45,
52,
64,
67,
69,
73,
277,
278,
480,
481,
502,
508,
592,
699,
746,
846,
893,
963,
969,
1098,
1118,
1202,
1306,
1353,
1517,
1519,
1520,
1529,
1530,
1548,
1561,
1567,
1571,
1575,
1595,
1614,
1911,
1912,
1969,
1970,
1984,
1986,
1987,
1996,
1997,
2004,
2016,
2019,
2021,
2025,
2038,
2039,
2040,
2144,
2146,
2147,
2156,
2157,
2175,
2188,
2194,
2198,
2202,
2222,
2241,
2607,
2608,
3006
],
"line_end_idx": [
34,
35,
44,
45,
52,
64,
67,
69,
73,
277,
278,
480,
481,
502,
508,
592,
699,
746,
846,
893,
963,
969,
1098,
1118,
1202,
1306,
1353,
1517,
1519,
1520,
1529,
1530,
1548,
1561,
1567,
1571,
1575,
1595,
1614,
1911,
1912,
1969,
1970,
1984,
1986,
1987,
1996,
1997,
2004,
2016,
2019,
2021,
2025,
2038,
2039,
2040,
2144,
2146,
2147,
2156,
2157,
2175,
2188,
2194,
2198,
2202,
2222,
2241,
2607,
2608,
3006,
3007
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3007,
"ccnet_original_nlines": 71,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.29105472564697266,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.033377841114997864,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.36181575059890747,
"rps_doc_frac_unique_words": 0.4737991392612457,
"rps_doc_mean_word_length": 5.030567646026611,
"rps_doc_num_sentences": 29,
"rps_doc_symbol_to_word_ratio": 0.0013351100496947765,
"rps_doc_unigram_entropy": 5.051782608032227,
"rps_doc_word_count": 458,
"rps_doc_frac_chars_dupe_10grams": 0.0651041716337204,
"rps_doc_frac_chars_dupe_5grams": 0.140625,
"rps_doc_frac_chars_dupe_6grams": 0.1119791716337204,
"rps_doc_frac_chars_dupe_7grams": 0.0894097164273262,
"rps_doc_frac_chars_dupe_8grams": 0.0894097164273262,
"rps_doc_frac_chars_dupe_9grams": 0.0651041716337204,
"rps_doc_frac_chars_top_2gram": 0.030381940305233,
"rps_doc_frac_chars_top_3gram": 0.0364583283662796,
"rps_doc_frac_chars_top_4gram": 0.015625,
"rps_doc_books_importance": -323.4408874511719,
"rps_doc_books_importance_length_correction": -323.4408874511719,
"rps_doc_openwebtext_importance": -181.44729614257812,
"rps_doc_openwebtext_importance_length_correction": -181.44729614257812,
"rps_doc_wikipedia_importance": -141.9062042236328,
"rps_doc_wikipedia_importance_length_correction": -141.9062042236328
},
"fasttext": {
"dclm": 0.04419839009642601,
"english": 0.9196590781211853,
"fineweb_edu_approx": 0.9426693320274353,
"eai_general_math": 0.09440135955810547,
"eai_open_web_math": 0.13580405712127686,
"eai_web_code": 0.040804680436849594
}
}
|
{
"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.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": "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": "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,294,918,037,650,811,000
|
Today's meeting is the last in summer 2017. (Well, summer in the northern hemisphere.) Pack up the grill and get out the sweaters and cider for the upcoming cool autumn nights of coding.
Issue triage
WiX v4.0 status
Rob summarized the work he, Sean, and I did a couple weekends ago to continue reorganizing the WiX source code into multiple repositories. The end goal is to make it easier to work on, build, debug, and deliver WiX. If lots of low-level hacking on build systems is your cup of tea, you can watch the recording Rob made of that weekend session, all six and a half hours of it.
The repo reorganization work continues and there will be ample opportunity to participate.
|
{
"url": "https://www.firegiant.com/blog/2017/9/14/wix-online-meeting-134-highlights/",
"source_domain": "www.firegiant.com",
"snapshot_id": "crawl=CC-MAIN-2017-51",
"warc_metadata": {
"Content-Length": "17537",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:CRNJLGBUD4GWPL7E7CCTHBFTXJ74CH6J",
"WARC-Concurrent-To": "<urn:uuid:b888537f-b3a7-4801-88e3-b88bc34ab3ed>",
"WARC-Date": "2017-12-12T13:50:36Z",
"WARC-IP-Address": "137.117.17.70",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:GBB62RZ7IH6FC3IJRFWOFMRFO44JVIJ2",
"WARC-Record-ID": "<urn:uuid:74bf9206-dfcd-4591-a912-901ccb07b367>",
"WARC-Target-URI": "https://www.firegiant.com/blog/2017/9/14/wix-online-meeting-134-highlights/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8ae0e735-dc4c-48bd-93d7-df50004811f3>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-146-103-40.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2017-51\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for December 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,
187,
188,
201,
202,
218,
219,
595,
596
],
"line_end_idx": [
187,
188,
201,
202,
218,
219,
595,
596,
686
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 686,
"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.3611111044883728,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.006944439839571714,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1458333283662796,
"rps_doc_frac_unique_words": 0.7213115096092224,
"rps_doc_mean_word_length": 4.434426307678223,
"rps_doc_num_sentences": 8,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.2551655769348145,
"rps_doc_word_count": 122,
"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.025877999141812325,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -56.47722625732422,
"rps_doc_books_importance_length_correction": -60.623443603515625,
"rps_doc_openwebtext_importance": -35.75008773803711,
"rps_doc_openwebtext_importance_length_correction": -39.89630889892578,
"rps_doc_wikipedia_importance": -23.824960708618164,
"rps_doc_wikipedia_importance_length_correction": -27.971179962158203
},
"fasttext": {
"dclm": 0.07700318098068237,
"english": 0.9344874024391174,
"fineweb_edu_approx": 0.9958073496818542,
"eai_general_math": 0.09102029353380203,
"eai_open_web_math": 0.13633817434310913,
"eai_web_code": 0.0025929200928658247
}
}
|
{
"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": "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": "-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": "13",
"label": "News (Org.)"
}
},
"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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-4,670,367,766,453,415,000
|
Prevenir correos de phishing cuando el cuerpo de PARA esta vacío (sin usar DKIM/DMARC)
Por: Adrian Kruss
Como podemos reducir las posibilidades de ataque de phishing usando las reglas de transporte sin la opción de DKIM/DMARC?
DKIM/DMARC es una opción diseñada para prevenir estos casos usando autenticación y verificación de mensajes. Para más información se puede ver https://blogs.office.com/2015/01/20/enhanced-email-protection-dkim-dmarc-office-365/. Pero para configurar DKIM/DMARC es necesario agregar registros CNAME (por ejemplo _dmarc.contoso.com) en el DNS público del dominio. El problema es que algunos proveedores de DNS no permiten utilizar el símbolo “ _ ” (Subrayado) como parte de un registro.
En ciertos casos es posible que los usuarios reciban correos de remitentes externos a la organización haciéndose pasar por una persona interna a esta. Estos mensajes de correo electrónico, en la mayoría de los casos, son los ataques conocidos como phishing.
En el ejemplo siguiente, el usuario Cloudmbx1 recibió un correo electrónico solicitando información sensible. Este correo provenía de una persona afuera de la organización haciéndose pasar por alguien interno. Ramon Rocha no es un usuario existente dentro del dominio y pudo envía un correo como si lo fuera al buzón del usuario Cloudmbx1.
clip_image002
Este mensaje en particular fue enviado usando unos simple comandos por medio de Telnet y es posible que cualquier persona en mi entorno sufra de mensajes como estos.
clip_image004
Este comportamiento es esperado cuando DKIM/DMARC no están habilitados. Usando la herramienta aka.ms/EXRCA podemos analizar el encabezado del correo, del que se envío por medio de telnet, en este podemos ver este no contiene un remitente:
clip_image006
Esto se debe a que en el momento de ejecutar los comandos de Telnet se dejó en blanco el campo de correo o se puso un nombre (como en nuestro caso Ramon Rocha)
Este formato se puede usar por personas que intentan enviar correos de phishing hacia una organización. Creando una regla de transporte se puede prevenir que estos correos lleguen hacia los usuarios internos:
1) Ir al portal de Office 365 (https://login.microsoftonline.com)
2) Acceder al portal de Exchange Online como administrador y navegar a Exchange
3) Haga clic en el flujo de correo.
4) En la ficha Reglas, haga clic en "+" y "Crear una nueva regla ..."
5) Añadir las condiciones como se muestran en la siguiente imagen:
clip_image008
El valor debe ser idéntico a como esta en la imagen de arriba ^$ , esa es la única manera que el producto reconozca que la condición es válida. Una vez que la regla se aplica si alguien intenta enviar otro correo con el cuerpo de PARA vacío el mensaje será bloqueado por esta regla. Haciendo una prueba y haciendo un rastreo de este correo podemos ver:
clip_image010
Con esta regla de transporte simple se puede aumentar la seguridad de la organización para prevenir ataques de phishing.
|
{
"url": "https://docs.microsoft.com/en-us/archive/blogs/latam/prevenir-correos-de-phishing-cuando-el-cuerpo-de-para-esta-vac-237-o",
"source_domain": "docs.microsoft.com",
"snapshot_id": "crawl=CC-MAIN-2020-29",
"warc_metadata": {
"Content-Length": "34980",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:S73ALZ5BC5JZIZJMW3JU3JZ5I7IULZEK",
"WARC-Concurrent-To": "<urn:uuid:a7377c40-df69-490e-a6ea-34675e3c7e9b>",
"WARC-Date": "2020-07-10T10:58:08Z",
"WARC-IP-Address": "96.7.23.136",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:JBHZF3THIEBVOK7M6ILZ5PW4UMDZQVHN",
"WARC-Record-ID": "<urn:uuid:ce0af3d4-417d-467f-852c-91017da5542b>",
"WARC-Target-URI": "https://docs.microsoft.com/en-us/archive/blogs/latam/prevenir-correos-de-phishing-cuando-el-cuerpo-de-para-esta-vac-237-o",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d3f49c3e-30f6-4c7c-b3cb-b42632fab46a>"
},
"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-15.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,
87,
88,
106,
107,
229,
230,
715,
716,
974,
975,
1315,
1316,
1330,
1331,
1497,
1498,
1512,
1513,
1752,
1753,
1767,
1768,
1928,
1929,
2138,
2139,
2205,
2206,
2286,
2287,
2323,
2324,
2394,
2395,
2462,
2463,
2477,
2478,
2831,
2832,
2846,
2847
],
"line_end_idx": [
87,
88,
106,
107,
229,
230,
715,
716,
974,
975,
1315,
1316,
1330,
1331,
1497,
1498,
1512,
1513,
1752,
1753,
1767,
1768,
1928,
1929,
2138,
2139,
2205,
2206,
2286,
2287,
2323,
2324,
2394,
2395,
2462,
2463,
2477,
2478,
2831,
2832,
2846,
2847,
2967
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2967,
"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.0677361935377121,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.028520500287413597,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.15329767763614655,
"rps_doc_frac_unique_words": 0.4502164423465729,
"rps_doc_mean_word_length": 5.244588851928711,
"rps_doc_num_sentences": 25,
"rps_doc_symbol_to_word_ratio": 0.0017825299873948097,
"rps_doc_unigram_entropy": 4.866291522979736,
"rps_doc_word_count": 462,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.02806437946856022,
"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.01650846004486084,
"rps_doc_frac_chars_top_3gram": 0.01403218973428011,
"rps_doc_frac_chars_top_4gram": 0.011555920355021954,
"rps_doc_books_importance": -255.68115234375,
"rps_doc_books_importance_length_correction": -255.68115234375,
"rps_doc_openwebtext_importance": -169.3278350830078,
"rps_doc_openwebtext_importance_length_correction": -169.3278350830078,
"rps_doc_wikipedia_importance": -128.72483825683594,
"rps_doc_wikipedia_importance_length_correction": -128.72483825683594
},
"fasttext": {
"dclm": 0.9265885949134827,
"english": 0.0005882600089535117,
"fineweb_edu_approx": 1.1758686304092407,
"eai_general_math": 0.00017887000285554677,
"eai_open_web_math": 0.7226960062980652,
"eai_web_code": 0.44536441564559937
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.822",
"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": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"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": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-2,948,983,187,308,556,000
|
TechJunkie is a BOX20 Media Company
How AirPods Pro Work
How AirPods Pro Work
AirPods Pro are one of the iPhone’s best paired headphones, and they offer so much more than previous versions. With a simplistic design, they’re light, easy to use, and have substantial battery life. This new version of the AirPods comes with more improvements to make your everyday life easier and your music sound better.
We’ll tell you more about how AirPods Pro works, how to adjust them to your needs, and the different ways you can use them.
How AirPods Pro Work
AirPods are Bluetooth wireless headphones packed with sensors and small batteries to provide users with a great sound experience. They’re equipped to connect with any Apple device via Bluetooth and make seamless transitions between devices. All you need to do is take them out of the case, and they’re ready.
How to Set Up Your AirPods Pro
When it’s time to set up your new AirPods Pro, simply follow these steps:
1. Open your iPhone’s Home screen.
2. Open the AirPods case and leave it next to your phone.
3. Click “Connect.”
4. Once you’ve connected them with the phone, Siri commands and iCloud can also be activated.
AirPods Pro connect with iPod or iPhone as soon as you open the lid. When you want to listen to music, all you need to is put them in your ears. Once you’ve finished listening, just put them back in the case, and the music stops.
Airpods Pro
Music on AirPods Pro
Whenever you open your AirPods Pro case, they’ll start playing audio from your device. You can pause the audio by taking one of them out of your ear and stop the audio completely by taking both of them out. Also, don’t forget to return them to their case, since you might break them or damage one of the sensors if you carry them around loosely in your pocket or a bag.
Switching Devices with AirPods Pro
As soon as you start using your AirPods Pro, they connect to your iPhone and iWatch. However, this new generation of AirPods also automatically switches between phones and iPads with the same Apple ID. This way, you can answer calls while watching a movie on your pad without having to take the pods out of your ears.
If by any chance your AirPods don’t connect automatically, you can use Control Center to choose the source the sound.
AirPods Pro Controls
AirPods have a specific set of controls, and here’s how to use them:
1. To “Play” or “Pause” audio, tap the force sensor. To “Resume Playback,” tap it again.
2. To “Skip Forward,” tap the sensor twice.
3. To increase or decrease volume, you should start with “Hey, Siri” and then say something like “Turn up the volume a bit.”
4. Double-tapping the AirPods Pro controls several things: use Siri, skip tracks, or play and pause your music.
Siri on AirPods Pro
AirPods Pro are designed to let you easily use Siri to make phone calls or to ask questions. You can activate it saying “Hey Siri,” followed by a request or inquiry. You can also make calls by asking Siri to connect you with someone on their mobile, through Facetime, or any other way. Siri will also notify you if you have a call or if new notifications or messages come in.
If you want Siri to read all your messages to you, do this:
1. Open the Settings app on your iPhone.
2. Click “Notifications” and find the option “Announce Messages with Siri.”
3. Toggle to turn on this option, and Siri will start announcing your messages.
Noise Cancellation
You can find three noise control settings on AirPods Pro: active noise cancellation, transparency mode, and off. If you’re looking for complete focus while listening to a podcast or music, active noise cancellation will dampen all external sounds.
Assuming that you want to let the outside sounds in, you can use transparency mode and hear what’s happening around you (traffic, announcements, etc.) as well as the audio from your phone. Either way, if you want these options to function correctly, you’ll need to choose the right ear tip size. Start with the medium one, and if it doesn’t fit or it’s loose, try the others.
Airpods Pro Work
Change the Volume with iPhone
You can change the volume on your Airpods Pro in several ways:
1. Say “Hi Siri” and ask it to raise or lower the volume.
2. Tap the volume side buttons on your phone.
3. Go to the Lock Screen and use the volume slider.
4. Open the app you’re using and change volume there.
The Finest Tech
Wireless headphones have been a revolutionary invention, and AirPods are at the front lines.
Now you know a bit more about how AirPods Pro work, how to customize them, and how to connect them with other Apple devices you own. With that in mind, would you invest in new AirPods? What would be the first thing you’d have to adjust when using AirPods Pro? Is it Siri reading your messages to you or the noise cancellation feature?
Let us know in the comments section below.
Does Amazon Notify You if Something is Purchased from Your Wish List?
Read Next
Leave a Reply
Your email address will not be published. Required fields are marked *
Anna Middleton
Oct 23, 2020
290 Articles Published
More
|
{
"url": "https://www.techjunkie.com/how-airpods-pro-work/",
"source_domain": "www.techjunkie.com",
"snapshot_id": "crawl=CC-MAIN-2021-49",
"warc_metadata": {
"Content-Length": "70903",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:2VS2HANPVPJSDSUOR42LFZARDAKF5MAC",
"WARC-Concurrent-To": "<urn:uuid:123c422e-cd84-47c4-8e27-4050cd7d6568>",
"WARC-Date": "2021-12-02T13:57:17Z",
"WARC-IP-Address": "104.26.7.27",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:3RUDBNMRLN6FHC2S4KHDXWE54HDCURP3",
"WARC-Record-ID": "<urn:uuid:48c7b964-d361-46a9-8af9-58cf375fd6d0>",
"WARC-Target-URI": "https://www.techjunkie.com/how-airpods-pro-work/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5c9e3a91-5e99-49c4-90b4-f9ec5ef7aef4>"
},
"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-166\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,
58,
59,
80,
81,
406,
407,
531,
532,
553,
554,
863,
864,
895,
896,
970,
971,
1008,
1068,
1090,
1186,
1187,
1417,
1418,
1430,
1431,
1452,
1453,
1823,
1824,
1859,
1860,
2178,
2179,
2297,
2298,
2319,
2320,
2389,
2390,
2481,
2527,
2654,
2768,
2769,
2789,
2790,
3166,
3167,
3227,
3228,
3271,
3349,
3431,
3432,
3451,
3452,
3700,
3701,
4077,
4078,
4095,
4096,
4126,
4127,
4190,
4191,
4251,
4299,
4353,
4409,
4410,
4426,
4427,
4520,
4521,
4856,
4857,
4900,
4901,
4971,
4972,
4983,
4984,
4998,
4999,
5070,
5071,
5072,
5087,
5088,
5101,
5102,
5125,
5126
],
"line_end_idx": [
36,
37,
58,
59,
80,
81,
406,
407,
531,
532,
553,
554,
863,
864,
895,
896,
970,
971,
1008,
1068,
1090,
1186,
1187,
1417,
1418,
1430,
1431,
1452,
1453,
1823,
1824,
1859,
1860,
2178,
2179,
2297,
2298,
2319,
2320,
2389,
2390,
2481,
2527,
2654,
2768,
2769,
2789,
2790,
3166,
3167,
3227,
3228,
3271,
3349,
3431,
3432,
3451,
3452,
3700,
3701,
4077,
4078,
4095,
4096,
4126,
4127,
4190,
4191,
4251,
4299,
4353,
4409,
4410,
4426,
4427,
4520,
4521,
4856,
4857,
4900,
4901,
4971,
4972,
4983,
4984,
4998,
4999,
5070,
5071,
5072,
5087,
5088,
5101,
5102,
5125,
5126,
5130
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5130,
"ccnet_original_nlines": 96,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.42580646276474,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0018433199729770422,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.16221198439598083,
"rps_doc_frac_unique_words": 0.38631346821784973,
"rps_doc_mean_word_length": 4.444812297821045,
"rps_doc_num_sentences": 67,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.181593894958496,
"rps_doc_word_count": 906,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.028805559501051903,
"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.05463124066591263,
"rps_doc_frac_chars_top_3gram": 0.016141049563884735,
"rps_doc_frac_chars_top_4gram": 0.016886020079255104,
"rps_doc_books_importance": -476.91656494140625,
"rps_doc_books_importance_length_correction": -476.91656494140625,
"rps_doc_openwebtext_importance": -282.9373474121094,
"rps_doc_openwebtext_importance_length_correction": -282.9373474121094,
"rps_doc_wikipedia_importance": -187.65675354003906,
"rps_doc_wikipedia_importance_length_correction": -187.65675354003906
},
"fasttext": {
"dclm": 0.0475735105574131,
"english": 0.9263957142829895,
"fineweb_edu_approx": 1.3298633098602295,
"eai_general_math": 0.002423289930447936,
"eai_open_web_math": 0.1336413025856018,
"eai_web_code": 0.0008403100073337555
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.68",
"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": "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": "-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": "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
|
9,068,115,984,446,114,000
|
Sign up ×
MathOverflow is a question and answer site for professional mathematicians. It's 100% free, no registration required.
I have two specific questions regarding the LLC for $GL_n$, and in particular, what we can say about the conjecture if we don't have the ideas of Bernstein and Zelevinski, which reduce the problem to finding a correspondence between supercuspidal representations on the automorphic side, and irreducible representations on the Galois side.
Question 1: If we don't have B-Z, is there a way to see that supercuspidal representations MUST correspond to irreducible representations? Obviously, there is lots of evidence that these two things SHOULD correspond. First, supercuspidals are the "building blocks" of automorphic representations just as irreducibles are the building blocks of Weil-Deligne representations. Moreover, it's easy to prove that the $L$-functions match: in the degree-one case this is just match of characters under Class Field Theory, and in higher degree it's easy to prove you have $L = 1$ on both sides. But my question is: without having the explicit construction of Bernstein and Zelevinski, is there a proof that if a local Langlands Correspondence exists, that supercuspidals must correspond with irreducibles?
Question 2: This is built from my comment at the bottom of: Weil group, Weil-Deligne group scheme and conjectural Langlands group
Let's say we're explicitly trying to find two automorphic representations whose corresponding Weil representations are the same. Under the ideas of BZ, we can say that if two representations have the same supercuspidal support, then they correspond to two Weil-Deligne representations with the same underlying Weil representation. Is it easy to prove that this is so, without using the ideas of Bernstein and Zelevinski?
As an example, let's take the degree-$2$ representation induced from the characters $\chi |\cdot|^{-1/2},\, \chi|\cdot|^{1/2}$. This decomposes into a one-dimensional representation $\pi$ of $GL_2$, and then a Steinberg representation $\sigma$. In this simple case, can we see that $\rho(\sigma) \cong \rho(\pi)$, without using BZ? (Here $\rho$ denotes the underlying Weil representation).
share|cite|improve this question
Your Answer
discard
By posting your answer, you agree to the privacy policy and terms of service.
Browse other questions tagged or ask your own question.
|
{
"url": "http://mathoverflow.net/questions/138533/what-can-we-say-about-the-local-langlands-correspondence-for-gl-n-without-using",
"source_domain": "mathoverflow.net",
"snapshot_id": "crawl=CC-MAIN-2015-40",
"warc_metadata": {
"Content-Length": "53917",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:QZAH24SOLO3GW7K4ZCA6U3EXDUD35AJJ",
"WARC-Concurrent-To": "<urn:uuid:f75f6461-b5c1-44bd-8109-4c751c44634e>",
"WARC-Date": "2015-10-07T16:07:04Z",
"WARC-IP-Address": "198.252.206.24",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:RWG4BMTECRUM3LCG3ZZQ4TVD4U26GFZK",
"WARC-Record-ID": "<urn:uuid:9df86a59-254a-41dc-9b7a-d0a0fc547bc9>",
"WARC-Target-URI": "http://mathoverflow.net/questions/138533/what-can-we-say-about-the-local-langlands-correspondence-for-gl-n-without-using",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:75c14599-9a92-45a8-a407-46265b1719e3>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-137-6-227.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-40\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for September 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,
10,
128,
129,
469,
470,
1268,
1269,
1399,
1400,
1821,
1822,
2212,
2213,
2246,
2247,
2259,
2260,
2262,
2270,
2271,
2349,
2350
],
"line_end_idx": [
10,
128,
129,
469,
470,
1268,
1269,
1399,
1400,
1821,
1822,
2212,
2213,
2246,
2247,
2259,
2260,
2262,
2270,
2271,
2349,
2350,
2405
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2405,
"ccnet_original_nlines": 22,
"rps_doc_curly_bracket": 0.001663199975155294,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3890063464641571,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.023255810141563416,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.21564482152462006,
"rps_doc_frac_unique_words": 0.48595505952835083,
"rps_doc_mean_word_length": 5.382022380828857,
"rps_doc_num_sentences": 17,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.788486957550049,
"rps_doc_word_count": 356,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.056367430835962296,
"rps_doc_frac_chars_dupe_6grams": 0.03340291976928711,
"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.012526099570095539,
"rps_doc_frac_chars_top_3gram": 0.015657620504498482,
"rps_doc_frac_chars_top_4gram": 0.037578288465738297,
"rps_doc_books_importance": -198.223388671875,
"rps_doc_books_importance_length_correction": -198.223388671875,
"rps_doc_openwebtext_importance": -96.60904693603516,
"rps_doc_openwebtext_importance_length_correction": -96.60904693603516,
"rps_doc_wikipedia_importance": -73.72476959228516,
"rps_doc_wikipedia_importance_length_correction": -73.72476959228516
},
"fasttext": {
"dclm": 0.6956347823143005,
"english": 0.9038400650024414,
"fineweb_edu_approx": 1.4306708574295044,
"eai_general_math": 0.6881041526794434,
"eai_open_web_math": 0.7065569162368774,
"eai_web_code": 0.014222090132534504
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "512.74",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Algebra"
}
},
"secondary": {
"code": "512.7",
"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": "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": "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,974,388,958,992,895,000
|
xxtea 1.0.0
XXTEA for D.
To use this package, put the following dependency into your project's dependencies section:
dub.json
dub.sdl
XXTEA for D
<a href="https://github.com/xxtea/">
<img src="https://avatars1.githubusercontent.com/u/6683159?v=3&s=86" alt="XXTEA logo" title="XXTEA" align="right" />
</a>
Build Status DUB DUB DUB DUB DUB DUB
Introduction
XXTEA is a fast and secure encryption algorithm. This is a XXTEA library for D.
It is different from the original XXTEA encryption algorithm. It encrypts and decrypts raw binary data instead of 32bit integer array, and the key is also the raw binary data.
Usage
This is a dub library (http://code.dlang.org/about). Just add dependancy to your package.json:
{
...
"dependencies": {
"xxtea": "~>1.0.0",
...
}
}
A simple source code example is in the provided app.d and looks like this:
import xxtea;
import std.stdio;
void main() {
auto text = "Hello World! 你好,中国!";
auto key = "1234567890";
auto encrypt_data = XXTEA.encryptToBase64(text, key);
writeln(encrypt_data);
auto decrypt_data = XXTEA.decryptFromBase64(encrypt_data, key);
assert(text == decrypt_data);
}
Authors:
• Ma Bingyao
Dependencies:
none
Versions:
1.0.0 2016-Feb-12
~master 2016-Feb-12
Show all 2 versions
Download Stats:
• 0 downloads today
• 0 downloads this week
• 0 downloads this month
• 0 downloads total
Score:
0.5
Short URL:
xxtea.dub.pm
|
{
"url": "https://code-mirror.dlang.io/packages/xxtea",
"source_domain": "code-mirror.dlang.io",
"snapshot_id": "crawl=CC-MAIN-2018-51",
"warc_metadata": {
"Content-Length": "7902",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:36MLPT6ZEYCUA3XCA3HRPI6Y6YOELIPS",
"WARC-Concurrent-To": "<urn:uuid:d1d6c943-21e3-4258-882d-48b966f5d7ae>",
"WARC-Date": "2018-12-16T04:26:05Z",
"WARC-IP-Address": "163.172.30.29",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:KJQUD2OIZ26FEP4NC5EZCVME65V4NLIL",
"WARC-Record-ID": "<urn:uuid:25bd74ff-be73-4ada-996d-3a333b58258a>",
"WARC-Target-URI": "https://code-mirror.dlang.io/packages/xxtea",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e34d8401-c332-458f-843e-7f89097434db>"
},
"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-30-193-233.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,
12,
13,
26,
27,
28,
120,
121,
130,
138,
139,
151,
152,
189,
190,
307,
308,
313,
314,
351,
352,
365,
366,
446,
447,
623,
624,
630,
631,
726,
727,
729,
737,
759,
787,
799,
805,
807,
808,
883,
884,
898,
916,
917,
931,
970,
999,
1057,
1084,
1152,
1186,
1188,
1197,
1212,
1226,
1231,
1241,
1259,
1279,
1299,
1315,
1337,
1338,
1364,
1365,
1392,
1393,
1415,
1416,
1423,
1427,
1438
],
"line_end_idx": [
12,
13,
26,
27,
28,
120,
121,
130,
138,
139,
151,
152,
189,
190,
307,
308,
313,
314,
351,
352,
365,
366,
446,
447,
623,
624,
630,
631,
726,
727,
729,
737,
759,
787,
799,
805,
807,
808,
883,
884,
898,
916,
917,
931,
970,
999,
1057,
1084,
1152,
1186,
1188,
1197,
1212,
1226,
1231,
1241,
1259,
1279,
1299,
1315,
1337,
1338,
1364,
1365,
1392,
1393,
1415,
1416,
1423,
1427,
1438,
1450
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1450,
"ccnet_original_nlines": 71,
"rps_doc_curly_bracket": 0.004137929994612932,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.15727002918720245,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.05934717878699303,
"rps_doc_frac_lines_end_with_ellipsis": 0.0277777798473835,
"rps_doc_frac_no_alph_words": 0.4154302775859833,
"rps_doc_frac_unique_words": 0.6022099256515503,
"rps_doc_mean_word_length": 5.668508052825928,
"rps_doc_num_sentences": 32,
"rps_doc_symbol_to_word_ratio": 0.005934719927608967,
"rps_doc_unigram_entropy": 4.438640594482422,
"rps_doc_word_count": 181,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.017543859779834747,
"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.029239770025014877,
"rps_doc_frac_chars_top_3gram": 0.035087719559669495,
"rps_doc_frac_chars_top_4gram": 0.035087719559669495,
"rps_doc_books_importance": -146.3090057373047,
"rps_doc_books_importance_length_correction": -142.16885375976562,
"rps_doc_openwebtext_importance": -92.50498962402344,
"rps_doc_openwebtext_importance_length_correction": -92.50498962402344,
"rps_doc_wikipedia_importance": -57.559547424316406,
"rps_doc_wikipedia_importance_length_correction": -49.072540283203125
},
"fasttext": {
"dclm": 0.06362920999526978,
"english": 0.5806276798248291,
"fineweb_edu_approx": 2.740385055541992,
"eai_general_math": 0.4612460136413574,
"eai_open_web_math": 0.07719022035598755,
"eai_web_code": 0.06067055091261864
}
}
|
{
"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": "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": "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": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
5,226,164,918,443,631,000
|
tracker-miners:master commits https://gitlab.gnome.org/Sumaid/tracker-miners/-/commits/master 2019-08-19T14:30:11+05:30 https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/edba66e5ce6a133b3598f4a30d368af12903c2cc Merge branch 'master' of https://gitlab.gnome.org/GNOME/tracker-miners 2019-08-19T14:30:11+05:30 Sumaid Syed sumaidsyed@gmail.com https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/40cc9e9bdf401d85b44b78a4b8a35023361563fa Merge branch 'wip/carlosg/dispose-resources' into 'master' 2019-08-12T15:54:39+00:00 Sam Thursfield sam@afuera.me.uk miner/fs: Run dispose on TrackerResource See merge request <a href="/GNOME/tracker-miners/-/merge_requests/95" data-original="GNOME/tracker-miners!95" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="17148" data-project-path="GNOME/tracker-miners" data-iid="95" data-mr-title="miner/fs: Run dispose on TrackerResource" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!95</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/1c56af345b9872d770a4922f6885883ca6482adf Update Basque translation 2019-08-11T13:54:30+00:00 Asier Sarasua Garmendia asier.sarasua@gmail.com https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/eeb42d74e2ea80f2f17a46e79e702328aa814646 miner/fs: Run dispose on TrackerResource 2019-08-10T13:31:16+02:00 Carlos Garnacho carlosg@gnome.org In the right circumstances the resource contains references to itself through nie:isStoredAs. Running dispose would allow the root TrackerResource to break those reference cycles. Related: <a href="https://gitlab.gnome.org/GNOME/tracker/merge_requests/116" data-original="https://gitlab.gnome.org/GNOME/tracker/merge_requests/116" data-link="false" data-link-reference="true" data-project="1593" data-merge-request="17146" data-project-path="GNOME/tracker" data-iid="116" data-mr-title="libtracker-sparql: Implement dispose() in TrackerResource" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">tracker!116</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/8e55fb75ec2994f5b7400e26d805924cd8b45f45 Release 2.2.99.0 2019-08-08T01:27:55+02:00 Carlos Garnacho carlosg@gnome.org https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/c8efa98297e2f5b18648e7c16c34215d74331063 Merge branch 'sam/log-domain' into 'master' 2019-08-06T19:12:53+00:00 Sam Thursfield sam@afuera.me.uk Set log domain to Tracker See merge request <a href="/GNOME/tracker-miners/-/merge_requests/94" data-original="GNOME/tracker-miners!94" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="17046" data-project-path="GNOME/tracker-miners" data-iid="94" data-mr-title="Set log domain to Tracker" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!94</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/c184f694283f129d205047e462dac10805d9e597 Set log domain to Tracker 2019-08-06T21:05:40+02:00 Sam Thursfield sam@afuera.me.uk This fixes a regression introduced by the Meson port, where this package didn't declare a GLib log domain. Fixing this means that you can once again use the environment variable `G_MESSAGES_DEBUG=Tracker` combined with `TRACKER_VERBOSITY` to show debug messages only from Tracker. Without this fix, `G_MESSAGES_DEBUG=all` is needed to enable the messages to be printed, but this may enable output from other packages too. https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/569259feec11d0135f141599689513b5de61075c Merge branch 'wip/jfelder/tracker-extract-musicbrainz-external-resources' int... 2019-08-06T17:38:36+00:00 Sam Thursfield sam@afuera.me.uk Use ExternalReference to store MusicBrainz identifiers See merge request <a href="/GNOME/tracker-miners/-/merge_requests/91" data-original="GNOME/tracker-miners!91" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15928" data-project-path="GNOME/tracker-miners" data-iid="91" data-mr-title="Use ExternalReference to store MusicBrainz identifiers" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!91</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/88589ce5d6620bac45dff824053dafe2927f42c4 extract-vorbis: Use ExtractReference to store musicbrainz tags 2019-08-06T19:34:53+02:00 Jean Felder jean.felder@estimages.com Store MusicBrainz IDs as ExternalResources instead of a list of properties. This approach is more generic. Extraction of MusicBrainz IDs is done based on tags used by Picard. Tags Mapping: <a href="https://picard.musicbrainz.org/docs/mappings/" rel="nofollow noreferrer noopener" target="_blank">https://picard.musicbrainz.org/docs/mappings/</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/d6c9479f226c04beb58edf80ccd5e5407bceb030 extract-mp3: Use ExtractReference to store musicbrainz tags 2019-08-06T19:34:53+02:00 Jean Felder jean.felder@estimages.com Store MusicBrainz IDs as ExternalResources instead of a list of properties. This approach is more generic. Extraction of MusicBrainz IDs is done based on tags used by Picard. Tags Mapping: <a href="https://picard.musicbrainz.org/docs/mappings/" rel="nofollow noreferrer noopener" target="_blank">https://picard.musicbrainz.org/docs/mappings/</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/54897caf850bc5e665663dde2f45bb112b1576f0 Update NEWS with 2.3.0-alpha1 features 2019-08-05T17:52:58+02:00 Sam Thursfield sam@afuera.me.uk https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/9ffe4a418d9f8b8b391edb1cb771d0cef6a66043 Merge branch 'ritzk/tracker-miners-master' 2019-08-01T11:25:25+02:00 Sam Thursfield sam@afuera.me.uk See: <a href="https://gitlab.gnome.org/GNOME/tracker-miners/merge_requests/88" data-original="https://gitlab.gnome.org/GNOME/tracker-miners/merge_requests/88" data-link="false" data-link-reference="true" data-project="1664" data-merge-request="15890" data-project-path="GNOME/tracker-miners" data-iid="88" data-mr-title="ignore folders contain .nomedia file seen on android devices" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!88</a>/ https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/9b4edb1371aecc3c06aebf10535486caa3d88ff5 Merge branch 'sam/lto' into 'master' 2019-07-15T10:07:28+00:00 Sam Thursfield sam@afuera.me.uk ci: Enable link-time optimization See merge request <a href="/GNOME/tracker-miners/-/merge_requests/90" data-original="GNOME/tracker-miners!90" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15897" data-project-path="GNOME/tracker-miners" data-iid="90" data-mr-title="ci: Enable link-time optimization" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!90</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/d4a2dd513444894f965d3723d4cf3d670dcae81f ci: Enable link-time optimization 2019-07-15T11:05:29+01:00 Sam Thursfield sam@afuera.me.uk This should help us to avoid regressions like <a href="https://gitlab.gnome.org/GNOME/tracker/issues/117" data-original="https://gitlab.gnome.org/GNOME/tracker/issues/117" data-link="false" data-link-reference="true" data-project="1593" data-issue="68983" data-reference-type="issue" data-container="body" data-placement="top" data-html="true" title="tracker-miner-fs crashes when compiled with LTO" class="gfm gfm-issue has-tooltip">tracker#117</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/846c3e1c0835098ef86b6d88a5c3ecb9f341d67f Merge branch 'sam/fix-domainontology-gtype-conflict' into 'master' 2019-07-15T09:35:42+00:00 Sam Thursfield sam@afuera.me.uk Replace TrackerDomainOntology class with a simpler function Closes <a href="/GNOME/tracker/-/issues/116" data-original="tracker#116" data-link="false" data-link-reference="false" data-project="1593" data-issue="68913" data-reference-type="issue" data-container="body" data-placement="top" data-html="true" title="Avoid conflicts between libtracker-common and libtracker-miners-common" class="gfm gfm-issue has-tooltip">tracker#116</a> See merge request <a href="/GNOME/tracker-miners/-/merge_requests/89" data-original="GNOME/tracker-miners!89" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15893" data-project-path="GNOME/tracker-miners" data-iid="89" data-mr-title="Replace TrackerDomainOntology class with a simpler function" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!89</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/4ddf5f02f1d3b45418bd72f53983230140dcb8a4 Merge branch 'master' of https://gitlab.gnome.org/GNOME/tracker-miners 2019-07-15T10:57:30+05:30 Sumaid Syed sumaidsyed@gmail.com https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/ef6261a0640309e52adc90f59d6c12ef6c5bcae4 tracker-extract: Use normal logging when in standalone mode 2019-07-15T01:08:06+01:00 Sam Thursfield sam@afuera.me.uk We were installing a different log handler which ignored our verbosity settings. Until recently this was harmless, but due to rearranging some code it started to print a log message from Gio that triggers when GFile is used for the first time: _g_io_module_get_default: Found default implementation gvfs (GDaemonVfs) for ‘gio-vfs’ https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/323aa7e3e0213608b1c123e952e3c6871d41db9d Merge branch 'sam/raw-warning-fix' into 'master' 2019-07-14T23:44:37+00:00 Sam Thursfield sam@afuera.me.uk tracker-extract-raw.c: Fix compile warning See merge request <a href="/GNOME/tracker-miners/-/merge_requests/87" data-original="GNOME/tracker-miners!87" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15878" data-project-path="GNOME/tracker-miners" data-iid="87" data-mr-title="tracker-extract-raw.c: Fix compile warning" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!87</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/2148096beb3e5d94272b08a2378bd966791a8938 Replace TrackerDomainOntology class with a simpler function 2019-07-15T00:34:45+01:00 Sam Thursfield sam@afuera.me.uk This allows us to remove some code from libtracker-miners-common, but the motivation is actually to fix a name conflict between libtracker-common and libtracker-miners-common. Previously we were prevented from linking statically to libtracker-miner, and prevented from using link-time optimization, due to the duplicate GTypes. The code is now diverged from that in libtracker-common, but it's unlikely to see major changes because the "domain ontology" format is part of Tracker's public API. Fixes: <a href="https://gitlab.gnome.org/GNOME/tracker/issues/116" data-original="https://gitlab.gnome.org/GNOME/tracker/issues/116" data-link="false" data-link-reference="true" data-project="1593" data-issue="68913" data-reference-type="issue" data-container="body" data-placement="top" data-html="true" title="Avoid conflicts between libtracker-common and libtracker-miners-common" class="gfm gfm-issue has-tooltip">tracker#116</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/7032766edecc2cc1b54f0160a584bd837e6ffd3d ignore folders contain .nomedia file seen on android devices 2019-07-14T15:10:10-07:00 Ritesh Khadgaray khadgaray@gmail.com https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/209b3ec874a775d9f4e5b693b1868a9e81050170 tracker-extract-raw.c: Fix compile warning 2019-07-14T12:37:34+01:00 Sam Thursfield sam@afuera.me.uk There is some witchcraft in GLib's definition of g_clear_pointer(). The function definition is overridden by a macro in `glib/gmem.h`, and the macro generates this warning if we cast the 'destroy' parameter to the expected type: [101/264] Compiling C object 'src/tracker-extract/ec38c81@@extract-raw@sha/tracker-extract-raw.c.o'. In file included from /usr/include/glib-2.0/glib/glist.h:32, from /usr/include/glib-2.0/glib/ghash.h:33, from /usr/include/glib-2.0/glib.h:50, from /usr/include/glib-2.0/gobject/gbinding.h:28, from /usr/include/glib-2.0/glib-object.h:23, from /usr/include/gexiv2/gexiv2-metadata.h:14, from /usr/include/gexiv2/gexiv2.h:13, from ../src/tracker-extract/tracker-extract-raw.c:24: ../src/tracker-extract/tracker-extract-raw.c: In function ‘tracker_extract_get_metadata’: ../src/tracker-extract/tracker-extract-raw.c:462:24: warning: function called through a non-compatible type g_clear_pointer (&ed, (GDestroyNotify) raw_exif_data_free); ^ Removing the cast prevents the warning from appearing. https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/7d28aa87ff85940c50e7fb8eb64ef209f01dbb65 Merge branch 'sam/config.h-subproject-warning' into 'master' 2019-07-14T10:46:50+00:00 Sam Thursfield sam@afuera.me.uk Rename config.h to config-miners.h See merge request <a href="/GNOME/tracker-miners/-/merge_requests/84" data-original="GNOME/tracker-miners!84" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15773" data-project-path="GNOME/tracker-miners" data-iid="84" data-mr-title="Rename config.h to config-miners.h" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!84</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/54144c9a0e59e80b84f3afed0bb27f98f249ee13 Rename config.h to config-miners.h 2019-07-14T11:40:59+01:00 Sam Thursfield sam@afuera.me.uk This fixes compile warnings which show up when we build with -Dtracker_core=subproject. This is an example of the kind of warning: [7/186] Compiling C object 'subprojects/tracker/src/tracker-store/7bb4675@@tracker-store@exe/tracker-config.c.o'. In file included from ../subprojects/tracker/src/tracker-store/tracker-config.c:21: subprojects/tracker/./config.h:25: warning: "GETTEXT_PACKAGE" redefined 25 | #define GETTEXT_PACKAGE "tracker" | In file included from <command-line>: ./config.h:25: note: this is the location of the previous definition 25 | #define GETTEXT_PACKAGE "tracker-miners" | https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/f3550b4adb21654a9fdea64646f957adc9f69329 Merge branch 'sam/g-add-private' into 'master' 2019-07-14T10:32:26+00:00 Sam Thursfield sam@afuera.me.uk Use G_ADD_PRIVATE() instead of g_type_class_add_private() Closes <a href="/GNOME/tracker/-/issues/115" data-original="tracker#115" data-link="false" data-link-reference="false" data-project="1593" data-issue="68807" data-reference-type="issue" data-container="body" data-placement="top" data-html="true" title="Fix g_type_class_add_private deprecation warnings" class="gfm gfm-issue has-tooltip">tracker#115</a> See merge request <a href="/GNOME/tracker-miners/-/merge_requests/85" data-original="GNOME/tracker-miners!85" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15787" data-project-path="GNOME/tracker-miners" data-iid="85" data-mr-title="Use G_ADD_PRIVATE() instead of g_type_class_add_private()" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!85</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/21ed37cddaf4bbb61bb4bfff46ba1dff016453f2 tracker-extract-gstreamer.c: Add comment 2019-07-14T11:29:37+01:00 Sam Thursfield sam@afuera.me.uk https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/815fab61f5b83b7378b0d8525b9942795d65586e Merge branch 'fix_gstreamer_segfault_tags' into 'master' 2019-07-14T10:25:28+00:00 Sam Thursfield sam@afuera.me.uk tracker-extract-gstreamer.c: Set empty tags list if no tags were found See merge request <a href="/GNOME/tracker-miners/-/merge_requests/86" data-original="GNOME/tracker-miners!86" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15860" data-project-path="GNOME/tracker-miners" data-iid="86" data-mr-title="tracker-extract-gstreamer.c: Set empty tags list if no tags were found" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!86</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/b009126fd46793ea7d209947ef10067c30156fb0 tracker-extract-gstreamer.c: Set empty tags list if no tags were found 2019-07-13T18:21:16+03:00 nightuser 22158-nightuser@users.noreply.gitlab.gnome.org If entry doesn't has tags then `tracker_toc_add_entry` receives NULL instead of the tag list. But this function immediately tries to make a reference to the tag list and fails on NULL pointer. And every function in `tracker-cue-sheet.c` assumes that the list is non-NULL. Now it creates empty tag list if an entry doesn't contain tags. It shouldn't have any impact since in normal case tag list is copied. https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/d8f89c069026f4f173d6f75ba9854cecb7b80d62 Merge branch 'master' of https://gitlab.gnome.org/GNOME/tracker-miners 2019-07-13T14:54:33+05:30 Sumaid Syed sumaidsyed@gmail.com https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/121efa6bd9030d4110ed3ad3a83546c751d1a63b Use G_ADD_PRIVATE() instead of g_type_class_add_private() 2019-07-12T14:52:27+01:00 Sam Thursfield sam@afuera.me.uk This fixes deprecation warnings about g_type_class_add_private() The new G_ADD_PRIVATE() method has been around since GLib 2.38 (we already depend on 2.40 at minimum). See this blog post for more details: <a href="https://www.bassi.io/articles/2013/06/21/the-king-is-dead/" rel="nofollow noreferrer noopener" target="_blank">https://www.bassi.io/articles/2013/06/21/the-king-is-dead/</a> Fixes <a href="https://gitlab.gnome.org/GNOME/tracker/issues/115" data-original="https://gitlab.gnome.org/GNOME/tracker/issues/115" data-link="false" data-link-reference="true" data-project="1593" data-issue="68807" data-reference-type="issue" data-container="body" data-placement="top" data-html="true" title="Fix g_type_class_add_private deprecation warnings" class="gfm gfm-issue has-tooltip">tracker#115</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/ad3bff3415fbbdb9e67e99fc1613b64916d47408 miners/fs: Fix compile warning in tracker-writeback-dispatcher.c 2019-07-11T12:24:05+01:00 Sam Thursfield sam@afuera.me.uk Fixes this: [3/4] Compiling C object 'src/miners/fs/8409082@@tracker-miner-fs@exe/tracker-writeback-dispatcher.c.o'. ../src/miners/fs/tracker-writeback-dispatcher.c: In function ‘writeback_dispatcher_writeback_file’: ../src/miners/fs/tracker-writeback-dispatcher.c:375:11: warning: assignment to ‘TrackerMinerFiles *’ {aka ‘struct TrackerMinerFiles *’} from incompatible pointer type ‘TrackerMinerFS *’ {aka ‘struct _TrackerMinerFS *’} [-Wincompatible-pointer-types] data->fs = g_object_ref (fs); https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/c9144e49b1aef7bfe8a924606c22a5114d1dbb61 build: Remove obsolete comment 2019-07-11T12:01:09+01:00 Sam Thursfield sam@afuera.me.uk This issue has been fixed in Meson since v0.42. See <a href="/GNOME/tracker/-/merge_requests/103" data-original="GNOME/tracker!103" data-link="false" data-link-reference="false" data-project="1593" data-merge-request="15777" data-project-path="GNOME/tracker" data-iid="103" data-mr-title="build: Use tracker_common_dep as a normal dependency" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">tracker!103</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/25f47adab44ad8a2bb801e48925909e15340fcad Add Belarusian translation 2019-07-11T08:35:55+00:00 Uladzimir Manulenka vlma@tut.by https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/bc4942469abc17adb0d195daba54da8f4093c80f Merge branch 'sam/ft-traceback-fix' into 'master' 2019-07-10T17:28:58+00:00 Sam Thursfield sam@afuera.me.uk functional-tests: Remove a double-traceback See merge request <a href="/GNOME/tracker-miners/-/merge_requests/82" data-original="GNOME/tracker-miners!82" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15768" data-project-path="GNOME/tracker-miners" data-iid="82" data-mr-title="functional-tests: Remove a double-traceback" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!82</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/aea42998dad4c7977b678d2d7b3dce5a9ced2477 Merge branch 'sam/static-libtracker-miners-common' into 'master' 2019-07-10T16:17:00+00:00 Sam Thursfield sam@afuera.me.uk build: libtracker-miners-common should be a static library See merge request <a href="/GNOME/tracker-miners/-/merge_requests/83" data-original="GNOME/tracker-miners!83" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15772" data-project-path="GNOME/tracker-miners" data-iid="83" data-mr-title="build: libtracker-miners-common should be a static library" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!83</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/65b1d2375fefad5bedff9d2cd0a5d77e92345be4 build: libtracker-miners-common should be a static library 2019-07-10T16:56:58+01:00 Sam Thursfield sam@afuera.me.uk This library is API-unstable helper code. In the Autotools build system we only linked to it statically and didn't install it. Fixes a regression introduced in <a href="/GNOME/tracker-miners/-/commit/8c1ff9cf0a4dd3d8394a6491bbc75cebb71796e7" data-original="8c1ff9cf0" data-link="false" data-link-reference="false" data-project="1664" data-commit="8c1ff9cf0a4dd3d8394a6491bbc75cebb71796e7" data-reference-type="commit" data-container="body" data-placement="top" data-html="true" title="build: Don't install libtracker-miners-common" class="gfm gfm-commit has-tooltip">8c1ff9cf</a>, where we stopped installing the library but didn't make it static, which totally broke installed versions of Tracker. https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/d6a50949f4d167ea9d4cd9f3430543cadc387e74 functional-tests: Remove a double-traceback 2019-07-10T16:09:55+01:00 Sam Thursfield sam@afuera.me.uk Before: Traceback (most recent call last): File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/helpers.py", line 403, in await_resource_inserted self.loop.run_checked() File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/mainloop.py", line 58, in run_checked raise self._exception File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/helpers.py", line 294, in _graph_updated_timeout_cb raise GraphUpdateTimeoutException() common.utils.helpers.GraphUpdateTimeoutException During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/minertest.py", line 145, in setUp super(CommonTrackerMinerFTSTest, self).setUp() File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/minertest.py", line 82, in setUp self.create_test_data() File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/minertest.py", line 117, in create_test_data self.tracker.await_resource_inserted(NFO_DOCUMENT, url=self.uri(tf)) File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/helpers.py", line 405, in await_resource_inserted raise GraphUpdateTimeoutException("Timeout waiting for resource: class %s, URL %s, title %s" % (rdf_class, url, title)) common.utils.helpers.GraphUpdateTimeoutException: Timeout waiting for resource: class <a href="http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#Document" rel="nofollow noreferrer noopener" target="_blank">http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#Document</a>, URL <a href="file:///home/tracker/tracker-tests/tmp6bkbec7d/test-monitored/dir1/file2.txt">file:///home/tracker/tracker-tests/tmp6bkbec7d/test-monitored/dir1/file2.txt</a>, title None After: Traceback (most recent call last): File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/minertest.py", line 145, in setUp super(CommonTrackerMinerFTSTest, self).setUp() File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/minertest.py", line 82, in setUp self.create_test_data() File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/minertest.py", line 117, in create_test_data self.tracker.await_resource_inserted(NFO_DOCUMENT, url=self.uri(tf)) File "/builds/GNOME/tracker-miners/tests/functional-tests/common/utils/helpers.py", line 405, in await_resource_inserted raise GraphUpdateTimeoutException("Timeout waiting for resource: class %s, URL %s, title %s" % (rdf_class, url, title)) common.utils.helpers.GraphUpdateTimeoutException: Timeout waiting for resource: class <a href="http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#Document" rel="nofollow noreferrer noopener" target="_blank">http://www.semanticdesktop.org/ontologies/2007/03/22/nfo#Document</a>, URL <a href="file:///home/tracker/tracker-tests/tmp6bkbec7d/test-monitored/dir1/file2.txt">file:///home/tracker/tracker-tests/tmp6bkbec7d/test-monitored/dir1/file2.txt</a>, title None https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/6055f5ed506b66a9744bffde3d7856ace3803b87 Merge branch 'sam/test-warning-fixes' into 'master' 2019-07-10T14:45:50+00:00 Sam Thursfield sam@afuera.me.uk Avoid g_critical() errors when unable to connect to upower Closes <a href="/GNOME/tracker-miners/-/issues/75" data-original="#75" data-link="false" data-link-reference="false" data-project="1664" data-issue="68904" data-reference-type="issue" data-container="body" data-placement="top" data-html="true" title="Warning from g_object_unref() during tests" class="gfm gfm-issue has-tooltip">#75</a> See merge request <a href="/GNOME/tracker-miners/-/merge_requests/81" data-original="GNOME/tracker-miners!81" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15765" data-project-path="GNOME/tracker-miners" data-iid="81" data-mr-title="Avoid g_critical() errors when unable to connect to upower" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!81</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/0d11b245365f71aca4acf70c0be8bd7ed9e548d3 Avoid g_critical() errors when unable to connect to upower 2019-07-10T15:41:19+01:00 Sam Thursfield sam@afuera.me.uk This removes two g_critical() errors that are seen when running the tests in CI. Before: (tracker-miner-fs:7050): libupower-glib-WARNING **: 14:31:50.109: Couldn't connect to proxy: Could not connect: No such file or directory (tracker-miner-fs:7050): GLib-GObject-CRITICAL **: 14:31:50.109: g_object_unref: assertion 'G_IS_OBJECT (object)' failed (tracker-miner-fs:7050): GLib-GObject-CRITICAL **: 14:31:50.109: g_object_unref: assertion 'G_IS_OBJECT (object)' failed ** (tracker-miner-fs:7050): WARNING **: 14:31:50.109: Unable to connect to UPower After: (tracker-miner-fs:12620): libupower-glib-WARNING **: 14:38:52.337: Couldn't connect to proxy: Could not connect: No such file or directory ** (tracker-miner-fs:12620): WARNING **: 14:38:52.337: Unable to connect to UPower Fixes <a href="https://gitlab.gnome.org/GNOME/tracker-miners/issues/75" data-original="https://gitlab.gnome.org/GNOME/tracker-miners/issues/75" data-link="false" data-link-reference="true" data-project="1664" data-issue="68904" data-reference-type="issue" data-container="body" data-placement="top" data-html="true" title="Warning from g_object_unref() during tests" class="gfm gfm-issue has-tooltip">#75</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/acb656491af0e5e32fc7e8c00ffda2995d86e0fa Merge branch 'sam/build-fixes' into 'master' 2019-07-10T14:18:38+00:00 Sam Thursfield sam@afuera.me.uk Fix some broken-by-default aspects of the developer experience See merge request <a href="/GNOME/tracker-miners/-/merge_requests/80" data-original="GNOME/tracker-miners!80" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="15762" data-project-path="GNOME/tracker-miners" data-iid="80" data-mr-title="Fix some broken-by-default aspects of the developer experience" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!80</a> https://gitlab.gnome.org/Sumaid/tracker-miners/-/commit/1d545b0e89044e74f8b24d62c083add0812342f0 Merge branch 'wip/jfelder/audio-writeback' into 'master' 2019-07-10T14:12:43+00:00 Sam Thursfield sam@afuera.me.uk writeback: Add GStreamer based writeback module See merge request <a href="/GNOME/tracker-miners/-/merge_requests/48" data-original="GNOME/tracker-miners!48" data-link="false" data-link-reference="false" data-project="1664" data-merge-request="11155" data-project-path="GNOME/tracker-miners" data-iid="48" data-mr-title="writeback: Add GStreamer based writeback module" data-reference-type="merge_request" data-container="body" data-placement="top" data-html="true" title="" class="gfm gfm-merge_request">!48</a>
|
{
"url": "https://gitlab.gnome.org/Sumaid/tracker-miners/-/commits/master?format=atom",
"source_domain": "gitlab.gnome.org",
"snapshot_id": "crawl=CC-MAIN-2020-29",
"warc_metadata": {
"Content-Length": "48275",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:BTDPH5523BLOSZP2UBS5AHAVD7WUBYTA",
"WARC-Concurrent-To": "<urn:uuid:c91385b7-b76e-4657-87b9-7fe9a14bdb9c>",
"WARC-Date": "2020-07-13T05:28:39Z",
"WARC-IP-Address": "8.43.85.27",
"WARC-Identified-Payload-Type": "application/atom+xml",
"WARC-Payload-Digest": "sha1:P4CWPRILZZ5MQYVILDJS7KRRYVU345OH",
"WARC-Record-ID": "<urn:uuid:c3cf9999-0c02-414e-9758-137abb90b5d1>",
"WARC-Target-URI": "https://gitlab.gnome.org/Sumaid/tracker-miners/-/commits/master?format=atom",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:60024203-65d8-4e9b-9692-58793cb62503>"
},
"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-117.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
],
"line_end_idx": [
29511
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 29511,
"ccnet_original_nlines": 0,
"rps_doc_curly_bracket": 0.0001355400017928332,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.07653333246707916,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.020400000736117363,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.48840001225471497,
"rps_doc_frac_unique_words": 0.3755143880844116,
"rps_doc_mean_word_length": 12.006173133850098,
"rps_doc_num_sentences": 376,
"rps_doc_symbol_to_word_ratio": 0.002266670111566782,
"rps_doc_unigram_entropy": 5.893420696258545,
"rps_doc_word_count": 1944,
"rps_doc_frac_chars_dupe_10grams": 0.1700085699558258,
"rps_doc_frac_chars_dupe_5grams": 0.3010282814502716,
"rps_doc_frac_chars_dupe_6grams": 0.2722793519496918,
"rps_doc_frac_chars_dupe_7grams": 0.21118251979351044,
"rps_doc_frac_chars_dupe_8grams": 0.18941730260849,
"rps_doc_frac_chars_dupe_9grams": 0.18376177549362183,
"rps_doc_frac_chars_top_2gram": 0.016152530908584595,
"rps_doc_frac_chars_top_3gram": 0.03230506181716919,
"rps_doc_frac_chars_top_4gram": 0.0538988895714283,
"rps_doc_books_importance": -3423.617919921875,
"rps_doc_books_importance_length_correction": -3423.617919921875,
"rps_doc_openwebtext_importance": -2186.173583984375,
"rps_doc_openwebtext_importance_length_correction": -2186.173583984375,
"rps_doc_wikipedia_importance": -1718.8851318359375,
"rps_doc_wikipedia_importance_length_correction": -1718.8851318359375
},
"fasttext": {
"dclm": 0.03780781850218773,
"english": 0.4621374011039734,
"fineweb_edu_approx": 1.751013159751892,
"eai_general_math": 0.02342855930328369,
"eai_open_web_math": 0.13389980792999268,
"eai_web_code": 0.5343546271324158
}
}
|
{
"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": "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": "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
|
-4,843,220,194,138,355,000
|
Sign in with
Sign up | Sign in
Your question
90C CPU idle
Last response: in CPUs
Share
My cpu temperature is always in the high 80's while at idle. When I start playing games the blue screen hits me and restarts the computer. When it's booting up, it won't let me past bios because it says the cpu is overheated and shows the temperature between 91c and 92c and never cools down until I turn off the pc.
I read some other posts stating it could be due to the thermal paste or the heatsink. I replaced the thermal paste several times (isopropyl for removing the paste) using the drop method, scraping it on with a card, using less thermal paste and none made the temperature go down. So I bought a heatsink with fan. Clipped it in and its reporting the same temperature. The heatsink is cold to the touch and is properly clipped in as much as it would go (the thermal paste transferred to the cpu when i take the heatsink off so I know it's clipped in right). I tried several programs such as Speedfan, hwmonitor, bios, etc and they are all reporting the same temperature although the core temperature at idle stay below 40c. Now I'm thinking it's due to the cpu or motherboard being defective. I bought these components 10 months ago and the cpu temperature recently just shot up to the high 80's.
Motherboard: Asus P8Z68-V LX
CPU: I5 2400 3.1ghz
Ram: 8gb ddr 3
GPU: bfg gtx 280
More about : 90c cpu idle
Either the thermal sensor in the CPU is broken.. your you have a unlocked multiplier and your CPU is un knowingly overclocked
Related resources
I would visit an Intel and Asus forums to see if this is prevalent elsewhere. The CPU is still under warranty if you bought it new. The only way to troubleshoot this is to replace the CPU with one that is not acting up elsewhere. If it's not the CPU then the MB may have bad voltage regulation and be supplying too much voltage.
Whats your case? If you put it in an old hp compact I can see high temps being a problem. Is the temperature of your room high? That just adds to the base temperature of your machine that the CPU raises. etc....
But since it "just shot up" I don't think that the case is really the case, I'd go with what ram1009 and try to trouble shoot what part is defective. Test the cpu somewhere else and test the motherboard with a different cpu.
Also test the case with a different PSU (or your PSU on a different case/motherboard) if you can, something might have fried that kept back the heat it produced before, and such.
Sure your fans are working right?
!
|
{
"url": "http://www.tomshardware.com/forum/351934-28-idle",
"source_domain": "www.tomshardware.com",
"snapshot_id": "crawl=CC-MAIN-2013-48",
"warc_metadata": {
"Content-Length": "125586",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FFXLCHVMLLDJG6J7RY3FF25EZTOAAW53",
"WARC-Concurrent-To": "<urn:uuid:99e470a0-5598-4eb4-af8a-00b68ebca5b3>",
"WARC-Date": "2013-12-22T03:45:32Z",
"WARC-IP-Address": "168.143.242.235",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:7PHDPTAGCVH5ZFTMU2GDPKVN2AIS7P2F",
"WARC-Record-ID": "<urn:uuid:f16d5989-cacb-4519-b20c-8be5742f96db>",
"WARC-Target-URI": "http://www.tomshardware.com/forum/351934-28-idle",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:46964b0f-92e1-4267-8047-2de0b5651821>"
},
"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,
13,
31,
45,
46,
59,
60,
83,
89,
90,
407,
408,
1302,
1303,
1332,
1352,
1367,
1384,
1385,
1411,
1412,
1538,
1556,
1557,
1886,
1887,
2099,
2100,
2101,
2326,
2327,
2328,
2507,
2508,
2542
],
"line_end_idx": [
13,
31,
45,
46,
59,
60,
83,
89,
90,
407,
408,
1302,
1303,
1332,
1352,
1367,
1384,
1385,
1411,
1412,
1538,
1556,
1557,
1886,
1887,
2099,
2100,
2101,
2326,
2327,
2328,
2507,
2508,
2542,
2543
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2543,
"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.46983546018600464,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.05484461039304733,
"rps_doc_frac_lines_end_with_ellipsis": 0.02857143059372902,
"rps_doc_frac_no_alph_words": 0.12614260613918304,
"rps_doc_frac_unique_words": 0.4894067943096161,
"rps_doc_mean_word_length": 4.211864471435547,
"rps_doc_num_sentences": 26,
"rps_doc_symbol_to_word_ratio": 0.0018281500088050961,
"rps_doc_unigram_entropy": 4.918454170227051,
"rps_doc_word_count": 472,
"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.03018108941614628,
"rps_doc_frac_chars_top_3gram": 0.012072429992258549,
"rps_doc_frac_chars_top_4gram": 0.027162980288267136,
"rps_doc_books_importance": -263.7843933105469,
"rps_doc_books_importance_length_correction": -263.7843933105469,
"rps_doc_openwebtext_importance": -157.45347595214844,
"rps_doc_openwebtext_importance_length_correction": -157.45347595214844,
"rps_doc_wikipedia_importance": -116.87459564208984,
"rps_doc_wikipedia_importance_length_correction": -116.87459564208984
},
"fasttext": {
"dclm": 0.26124101877212524,
"english": 0.9572241902351379,
"fineweb_edu_approx": 1.710898518562317,
"eai_general_math": 0.330624520778656,
"eai_open_web_math": 0.2236606478691101,
"eai_web_code": 0.1316782832145691
}
}
|
{
"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.3922",
"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": "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": "21",
"label": "Customer Support"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic 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
|
3,617,329,714,849,239,000
|
LLCoreWidget
LLCoreWidget is a container component used by various widget component where it is usually the first component rendered in the component hierarchy of a widget. This component is responsible for:
• Loading widget details based on widgetId and widgetKind using useLoadWidgetEffect hook.
• Add dismiss functionality using useWidgetDismiss.
• Render LoadingComponent when widget details are been loaded.
• Render ErrorComponent when there was an error loading widget details.
• Render widget UI using children prop.
Hooks used by LLCoreWidget
LLCoreWidget Props
📘
Customisation
Refer customisation core concepts to understand different level of component customisation.
programId
TypeDefault
String (Required)No Default
This is the Id of the program in which a given set of widgets are published from producer suite.
widgetId
TypeDefault
String (Required)No Default
widgetKind
TypeDefault
WidgetKind (Required)No Default
styles
TypeDefault
Stylesheet of type LLCoreWidgetStylesNo Default, if present styles props would be applied on top of internal LLCoreWidgetStyles.
LoadingComponent
TypeDefault
React ComponentActivityIndicator as default Loading component
Component to render when widget details are being loaded.
Example usage:
import React from 'react';
import { LLCoreWidget } from '@livelike/react-native';
import { WidgetKind } from '@livelike/javascript';
import { View, Text } from 'react-native';
const CustomLoadingComponent = () => {
return (
<View>
<Text> Loading Widget... </Text>
</View>
);
};
export function MyWidget() {
return (
<LLCoreWidget
programId="xxxxx"
widgetId="yyyy"
widgetKind={WidgetKind.TEXT_POLL}
LoadingComponent={CustomLoadingComponent}
>
{({ widget, onDismiss }) => {
// render widget UI
}}
</LLWidget>
);
}
ErrorComponent
TypeDefault
React ComponentView and Text component showing Unable to load widgets error text
Component to render whenever there's an error in loading widget.
Example usage:
import React from 'react';
import { LLWidget } from '@livelike/react-native';
import { WidgetKind } from '@livelike/javascript';
import { View, Text } from 'react-native';
const CustomErrorComponent = () => {
return (
<View>
<Text style={{ color: 'red' }}> Ohh snap! widgets not loaded </Text>
</View>
);
};
export function MyWidget() {
return (
<LLWidget
programId="xxxxx"
widgetId="yyyy"
widgetKind={WidgetKind.TEXT_POLL}
ErrorComponent={CustomErrorComponent}
>
{({ widget, onDismiss }) => {
// render widget UI
}}
</LLWidget>
);
}
onDismiss
TypeDefault
FunctionNo Default
Function that gets invoked whenever user dismisses the widget by clicking on dismiss Icon that is rendered as part of widget header.
children
TypeDefault
(props: LLCoreWidgetChildrenProps) => ReactNodeNo Default
children prop for LLCoreWidget that is called with prop LLCoreWidgetChildrenProps
Example usage:
import React from 'react';
import { LLCoreWidget } from '@livelike/react-native';
import { WidgetKind } from '@livelike/javascript';
export function MyWidget() {
return (
<LLCoreWidget
programId="xxxxx"
widgetId="yyyy"
widgetKind={WidgetKind.TEXT_POLL}
ErrorComponent={CustomErrorComponent}
>
{({ widget, onDismiss }) => { // core widget calling children prop function with widget, onDismiss
// render widget UI
}}
</LLWidget>
);
}
|
{
"url": "https://docs.livelike.com/docs/react-native-llcorewidget",
"source_domain": "docs.livelike.com",
"snapshot_id": "CC-MAIN-2023-40",
"warc_metadata": {
"Content-Length": "1049220",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:KVTPCKNPH5GHUC3JXWZ5PTF7ZUUAMS4P",
"WARC-Concurrent-To": "<urn:uuid:24dd428e-cd3c-4d5d-a868-770ab41e4916>",
"WARC-Date": "2023-10-01T09:29:14Z",
"WARC-IP-Address": "104.16.242.118",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:5WZQ3WFGDCPCTDUKEBDGQQOUXZ7JPV6S",
"WARC-Record-ID": "<urn:uuid:2f3d8d66-1b80-4170-b959-0e0038fc3246>",
"WARC-Target-URI": "https://docs.livelike.com/docs/react-native-llcorewidget",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:47394df5-a176-42a2-9096-05b1f1ef074a>"
},
"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-82\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,
13,
14,
209,
210,
302,
356,
421,
495,
537,
538,
565,
566,
585,
586,
588,
589,
603,
604,
696,
697,
707,
708,
720,
748,
749,
846,
847,
856,
857,
869,
897,
898,
909,
910,
922,
954,
955,
962,
963,
975,
1104,
1105,
1122,
1123,
1135,
1197,
1198,
1256,
1257,
1272,
1299,
1354,
1405,
1448,
1449,
1488,
1499,
1510,
1549,
1561,
1566,
1569,
1570,
1599,
1610,
1628,
1652,
1674,
1714,
1762,
1768,
1804,
1832,
1841,
1857,
1862,
1864,
1865,
1880,
1881,
1893,
1974,
1975,
2040,
2041,
2056,
2083,
2134,
2185,
2228,
2229,
2266,
2277,
2286,
2360,
2372,
2377,
2380,
2381,
2410,
2421,
2435,
2459,
2481,
2521,
2565,
2571,
2607,
2635,
2644,
2660,
2665,
2667,
2668,
2678,
2679,
2691,
2710,
2711,
2844,
2845,
2854,
2855,
2867,
2925,
2926,
3008,
3009,
3024,
3051,
3106,
3157,
3158,
3159,
3188,
3199,
3217,
3241,
3263,
3303,
3347,
3353,
3459,
3487,
3496,
3512,
3517
],
"line_end_idx": [
13,
14,
209,
210,
302,
356,
421,
495,
537,
538,
565,
566,
585,
586,
588,
589,
603,
604,
696,
697,
707,
708,
720,
748,
749,
846,
847,
856,
857,
869,
897,
898,
909,
910,
922,
954,
955,
962,
963,
975,
1104,
1105,
1122,
1123,
1135,
1197,
1198,
1256,
1257,
1272,
1299,
1354,
1405,
1448,
1449,
1488,
1499,
1510,
1549,
1561,
1566,
1569,
1570,
1599,
1610,
1628,
1652,
1674,
1714,
1762,
1768,
1804,
1832,
1841,
1857,
1862,
1864,
1865,
1880,
1881,
1893,
1974,
1975,
2040,
2041,
2056,
2083,
2134,
2185,
2228,
2229,
2266,
2277,
2286,
2360,
2372,
2377,
2380,
2381,
2410,
2421,
2435,
2459,
2481,
2521,
2565,
2571,
2607,
2635,
2644,
2660,
2665,
2667,
2668,
2678,
2679,
2691,
2710,
2711,
2844,
2845,
2854,
2855,
2867,
2925,
2926,
3008,
3009,
3024,
3051,
3106,
3157,
3158,
3159,
3188,
3199,
3217,
3241,
3263,
3303,
3347,
3353,
3459,
3487,
3496,
3512,
3517,
3518
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3518,
"ccnet_original_nlines": 147,
"rps_doc_curly_bracket": 0.017055140808224678,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.156089186668396,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.012006860226392746,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3396226465702057,
"rps_doc_frac_unique_words": 0.39058172702789307,
"rps_doc_mean_word_length": 7.091412544250488,
"rps_doc_num_sentences": 18,
"rps_doc_symbol_to_word_ratio": 0.0017152699874714017,
"rps_doc_unigram_entropy": 4.590917110443115,
"rps_doc_word_count": 361,
"rps_doc_frac_chars_dupe_10grams": 0.13710938394069672,
"rps_doc_frac_chars_dupe_5grams": 0.3394531309604645,
"rps_doc_frac_chars_dupe_6grams": 0.3394531309604645,
"rps_doc_frac_chars_dupe_7grams": 0.22539062798023224,
"rps_doc_frac_chars_dupe_8grams": 0.21054686605930328,
"rps_doc_frac_chars_dupe_9grams": 0.13710938394069672,
"rps_doc_frac_chars_top_2gram": 0.02031249925494194,
"rps_doc_frac_chars_top_3gram": 0.02187499962747097,
"rps_doc_frac_chars_top_4gram": 0.02695312909781933,
"rps_doc_books_importance": -217.26731872558594,
"rps_doc_books_importance_length_correction": -217.26731872558594,
"rps_doc_openwebtext_importance": -128.9347686767578,
"rps_doc_openwebtext_importance_length_correction": -128.9347686767578,
"rps_doc_wikipedia_importance": -80.3378677368164,
"rps_doc_wikipedia_importance_length_correction": -80.3378677368164
},
"fasttext": {
"dclm": 0.49765294790267944,
"english": 0.47379517555236816,
"fineweb_edu_approx": 2.8329226970672607,
"eai_general_math": 0.3013255000114441,
"eai_open_web_math": 0.008739950135350227,
"eai_web_code": 0.9913226962089539
}
}
|
{
"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": "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": "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": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
4,815,828,272,912,120,000
|
Apply a template to an email notification
After you create an email template, you can apply it to a notification.
Before you begin
Role required: admin
Procedure
1. Navigate to System Notification > Email > Notifications.
2. Open the email notification record that should use the template.
3. Navigate to the What it will contain section.
4. From the Email template field, select the appropriate template.
5. Click Update.
|
{
"url": "https://docs.servicenow.com/bundle/geneva-servicenow-platform/page/administer/notification/task/t_ApplyATemplateToAnEmailNotif.html",
"source_domain": "docs.servicenow.com",
"snapshot_id": "crawl=CC-MAIN-2018-22",
"warc_metadata": {
"Content-Length": "34126",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:WWNZD262USF6Z5NIIYAKORUN6WUDRCDU",
"WARC-Concurrent-To": "<urn:uuid:eb25137a-3bce-4f04-ad52-5a45db24525a>",
"WARC-Date": "2018-05-23T03:14:20Z",
"WARC-IP-Address": "34.197.177.137",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:ZMF2A2VQ5T3VMIHBQ6HXW63XZLPV3AT3",
"WARC-Record-ID": "<urn:uuid:9541f055-a796-41db-903e-ac9c4cabba48>",
"WARC-Target-URI": "https://docs.servicenow.com/bundle/geneva-servicenow-platform/page/administer/notification/task/t_ApplyATemplateToAnEmailNotif.html",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:341385a5-b76f-4613-9906-8d2b31e56629>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-158-150-190.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,
42,
43,
115,
116,
133,
134,
155,
156,
166,
167,
229,
299,
350,
419
],
"line_end_idx": [
42,
43,
115,
116,
133,
134,
155,
156,
166,
167,
229,
299,
350,
419,
437
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 437,
"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.3012048304080963,
"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.2530120611190796,
"rps_doc_frac_unique_words": 0.6268656849861145,
"rps_doc_mean_word_length": 5.04477596282959,
"rps_doc_num_sentences": 11,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 3.5261967182159424,
"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.04142012074589729,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -6.756568431854248,
"rps_doc_books_importance_length_correction": -6.783993721008301,
"rps_doc_openwebtext_importance": -8.676607131958008,
"rps_doc_openwebtext_importance_length_correction": -8.704031944274902,
"rps_doc_wikipedia_importance": 4.420952320098877,
"rps_doc_wikipedia_importance_length_correction": 4.393527507781982
},
"fasttext": {
"dclm": 0.1716676950454712,
"english": 0.6631041169166565,
"fineweb_edu_approx": 1.1287248134613037,
"eai_general_math": 0.0029399399645626545,
"eai_open_web_math": 0.00018471000657882541,
"eai_web_code": 0.0005184999899938703
}
}
|
{
"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.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": "-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": "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
|
-4,286,322,547,904,937,000
|
Sign up ×
Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute:
Possible Duplicate:
How to return AJAX response Text?
Variable doesn’t get returned JQuery
AJAX not updating variable
I am having issue with this code:
/**
* facebook Object*/
var fbObject = new Object();
/**
* Function to get login status
* @returns boolean Logged in status
* */
fbObject.getLoginStatus = function() {
FB.getLoginStatus(function(response) {
if (response.status == 'connected') {
console.log('logged in');
return true;
} else {
console.log('not logged in');
return false;
}
});
}
var status = fbObject.getLoginStatus();
alert('Status: '+ status);
My problem is that getLoginStatus method isn't returning the value.
share|improve this question
marked as duplicate by Denys Séguret, JohnnyHK, Quentin, Asad Saeeduddin, Jan Dvorak Dec 19 '12 at 14:09
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
1
Its asynchronous! And you don't return anything from the function, so what would you expect? – Bergi Dec 19 '12 at 14:08
What is the value you are getting for the response.status?? – palaѕн Dec 19 '12 at 14:08
The reason is simple : when getLoginStatus ends, the distant server hasn't received the question nor answered. So you can't get something returned. – Denys Séguret Dec 19 '12 at 14:09
@algorhythm Those are probably two distinct functions : one from an API and one from OP. – Denys Séguret Dec 19 '12 at 14:10
Thank you guys found solution here... stackoverflow.com/questions/12475269/… – Omer Abbas Dec 19 '12 at 14:19
3 Answers 3
You need a callback
Ajax requests do not return anything, they are asynchronous.
Try this:
var status = function(s){
alert('Status: '+ s);
};
/**
* Function to get login status
* @returns boolean Logged in status
* */
fbObject.getLoginStatus = function() {
FB.getLoginStatus(function(response) {
if (response.status == 'connected') {
console.log('logged in');
status(true);
} else {
console.log('not logged in');
status(false);
}
});
}
share|improve this answer
Tried this but this is also not working :( – Omer Abbas Dec 19 '12 at 14:16
The method is asynchronous, you are using it in a synchronous manner. It is impossible to return a value in the callback function.
share|improve this answer
The function is Asynchronous,
What I would do is to run the "callback code" in the actual callback:
fbObject.getLoginStatus = function() {
FB.getLoginStatus(function(response) {
if (response.status == 'connected') {
console.log('logged in');
alert('Status: '+ true);
} else {
console.log('not logged in');
alert('Status: '+ false);
}
});
}
or pass a callback to the function, or stall, until the function has returned.
share|improve this answer
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "http://stackoverflow.com/questions/13954107/javascript-method-isnt-returning-value/13954139",
"source_domain": "stackoverflow.com",
"snapshot_id": "crawl=CC-MAIN-2015-48",
"warc_metadata": {
"Content-Length": "80461",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4HO4BUTA2NSBWRDLTU2WQWVY2PYW43MQ",
"WARC-Concurrent-To": "<urn:uuid:6f0b39b5-c76b-4cd3-bcfb-00c07bc4b964>",
"WARC-Date": "2015-11-25T04:17:30Z",
"WARC-IP-Address": "104.16.33.249",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:RI7S6VGUH5UEWHY2QUGE565GPURDGRTR",
"WARC-Record-ID": "<urn:uuid:61999ed2-f25d-458c-bc9d-786d55ed0064>",
"WARC-Target-URI": "http://stackoverflow.com/questions/13954107/javascript-method-isnt-returning-value/13954139",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d9ddbdce-afc1-4d7a-99ac-b16be97a1246>"
},
"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,
10,
138,
139,
159,
193,
230,
257,
258,
292,
293,
297,
318,
347,
348,
349,
353,
385,
422,
428,
467,
510,
556,
596,
623,
644,
688,
716,
730,
738,
740,
741,
781,
782,
813,
814,
882,
883,
911,
912,
1017,
1018,
1161,
1162,
1166,
1287,
1292,
1381,
1386,
1570,
1575,
1700,
1705,
1815,
1816,
1828,
1829,
1849,
1850,
1911,
1912,
1913,
1923,
1924,
1950,
1976,
1979,
1980,
1984,
2016,
2053,
2059,
2098,
2141,
2187,
2224,
2249,
2267,
2308,
2334,
2345,
2353,
2355,
2381,
2386,
2462,
2463,
2594,
2595,
2621,
2622,
2652,
2653,
2723,
2724,
2767,
2810,
2856,
2896,
2935,
2956,
3000,
3040,
3054,
3062,
3064,
3065,
3144,
3145,
3171,
3172
],
"line_end_idx": [
10,
138,
139,
159,
193,
230,
257,
258,
292,
293,
297,
318,
347,
348,
349,
353,
385,
422,
428,
467,
510,
556,
596,
623,
644,
688,
716,
730,
738,
740,
741,
781,
782,
813,
814,
882,
883,
911,
912,
1017,
1018,
1161,
1162,
1166,
1287,
1292,
1381,
1386,
1570,
1575,
1700,
1705,
1815,
1816,
1828,
1829,
1849,
1850,
1911,
1912,
1913,
1923,
1924,
1950,
1976,
1979,
1980,
1984,
2016,
2053,
2059,
2098,
2141,
2187,
2224,
2249,
2267,
2308,
2334,
2345,
2353,
2355,
2381,
2386,
2462,
2463,
2594,
2595,
2621,
2622,
2652,
2653,
2723,
2724,
2767,
2810,
2856,
2896,
2935,
2956,
3000,
3040,
3054,
3062,
3064,
3065,
3144,
3145,
3171,
3172,
3262
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3262,
"ccnet_original_nlines": 110,
"rps_doc_curly_bracket": 0.007970569655299187,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.25830817222595215,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.013595170341432095,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.36102718114852905,
"rps_doc_frac_unique_words": 0.46437346935272217,
"rps_doc_mean_word_length": 5.405405521392822,
"rps_doc_num_sentences": 37,
"rps_doc_symbol_to_word_ratio": 0.0030211498960852623,
"rps_doc_unigram_entropy": 4.9070844650268555,
"rps_doc_word_count": 407,
"rps_doc_frac_chars_dupe_10grams": 0.14272727072238922,
"rps_doc_frac_chars_dupe_5grams": 0.27454546093940735,
"rps_doc_frac_chars_dupe_6grams": 0.22863635420799255,
"rps_doc_frac_chars_dupe_7grams": 0.22863635420799255,
"rps_doc_frac_chars_dupe_8grams": 0.19045454263687134,
"rps_doc_frac_chars_dupe_9grams": 0.14272727072238922,
"rps_doc_frac_chars_top_2gram": 0.015909090638160706,
"rps_doc_frac_chars_top_3gram": 0.022272730246186256,
"rps_doc_frac_chars_top_4gram": 0.02863636054098606,
"rps_doc_books_importance": -311.43389892578125,
"rps_doc_books_importance_length_correction": -311.43389892578125,
"rps_doc_openwebtext_importance": -147.57989501953125,
"rps_doc_openwebtext_importance_length_correction": -147.57989501953125,
"rps_doc_wikipedia_importance": -115.44932556152344,
"rps_doc_wikipedia_importance_length_correction": -115.44932556152344
},
"fasttext": {
"dclm": 0.5483425855636597,
"english": 0.7438255548477173,
"fineweb_edu_approx": 1.660090684890747,
"eai_general_math": 0.002402540063485503,
"eai_open_web_math": 0.07029510289430618,
"eai_web_code": 0.0005298299947753549
}
}
|
{
"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": "4",
"label": "Code/Software"
}
},
"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": "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": "2",
"label": "High School Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
8,320,152,762,408,467,000
|
Sunday
September 25, 2016
Homework Help: math
Posted by kim on Wednesday, January 20, 2010 at 4:35pm.
Jennifer considered the numbers 4, 24, 44, and 64 and
noticed that they all ended in 4 and that they can be
divided evenly by 4, leaving no remainder. She concluded
that all numbers that end in 4 can be divided
evenly by 4. What type of reasoning did Jennifer use? Is
her conclusion correct? Explain your answer.
Answer This Question
First Name:
School Subject:
Answer:
Related Questions
More Related Questions
|
{
"url": "http://www.jiskha.com/display.cgi?id=1264023332",
"source_domain": "www.jiskha.com",
"snapshot_id": "crawl=CC-MAIN-2016-40",
"warc_metadata": {
"Content-Length": "10509",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:TQWTVHE23ZTYUWNDJRXT34EBQRXBZ2CX",
"WARC-Concurrent-To": "<urn:uuid:01df45fc-30cc-43b6-a5c3-202940d2e996>",
"WARC-Date": "2016-09-25T22:49:05Z",
"WARC-IP-Address": "69.16.226.225",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:WH7U24GN6QWSMAQ2I6DL3KOPZWQPOYSH",
"WARC-Record-ID": "<urn:uuid:82bfa1a3-44fa-4a0c-a079-cdcf4287ac8f>",
"WARC-Target-URI": "http://www.jiskha.com/display.cgi?id=1264023332",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ad771fe1-c663-4159-b8c8-0d6d2a0c245c>"
},
"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,
7,
26,
27,
47,
48,
104,
105,
159,
213,
270,
316,
373,
418,
419,
440,
441,
453,
469,
477,
478,
496,
497
],
"line_end_idx": [
7,
26,
27,
47,
48,
104,
105,
159,
213,
270,
316,
373,
418,
419,
440,
441,
453,
469,
477,
478,
496,
497,
519
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 519,
"ccnet_original_nlines": 22,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2710280418395996,
"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.2897196412086487,
"rps_doc_frac_unique_words": 0.7272727489471436,
"rps_doc_mean_word_length": 4.625,
"rps_doc_num_sentences": 7,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.037233352661133,
"rps_doc_word_count": 88,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.10319410264492035,
"rps_doc_frac_chars_dupe_6grams": 0.10319410264492035,
"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.03931203857064247,
"rps_doc_frac_chars_top_3gram": 0.058968059718608856,
"rps_doc_frac_chars_top_4gram": 0.08845209330320358,
"rps_doc_books_importance": -42.009178161621094,
"rps_doc_books_importance_length_correction": -53.575687408447266,
"rps_doc_openwebtext_importance": -20.52719497680664,
"rps_doc_openwebtext_importance_length_correction": -32.09370422363281,
"rps_doc_wikipedia_importance": -15.393900871276855,
"rps_doc_wikipedia_importance_length_correction": -26.960411071777344
},
"fasttext": {
"dclm": 0.03988546133041382,
"english": 0.9709567427635193,
"fineweb_edu_approx": 2.3560118675231934,
"eai_general_math": 0.0002413400070508942,
"eai_open_web_math": 0.5495836734771729,
"eai_web_code": -0.000010009999641624745
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "510",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": ""
}
},
"secondary": {
"code": "372.7",
"labels": {
"level_1": "Social sciences",
"level_2": "Education",
"level_3": "Education, Elementary and Kindergarten"
}
}
},
"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": "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": "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": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
6,414,884,120,969,429,000
|
QGIS API Documentation 3.16.0-Hannover (43b64b13f3)
qgsstyle.cpp
Go to the documentation of this file.
1 /***************************************************************************
2 qgsstyle.cpp
3 ---------------------
4 begin : November 2009
5 copyright : (C) 2009 by Martin Dobias
6 email : wonder dot sk at gmail dot com
7 ***************************************************************************
8 * *
9 * This program is free software; you can redistribute it and/or modify *
10 * it under the terms of the GNU General Public License as published by *
11 * the Free Software Foundation; either version 2 of the License, or *
12 * (at your option) any later version. *
13 * *
14 ***************************************************************************/
15
16 #include "qgsstyle.h"
17
18 #include "qgssymbol.h"
19 #include "qgscolorramp.h"
20 #include "qgssymbollayerregistry.h"
21 #include "qgsapplication.h"
22 #include "qgslogger.h"
23 #include "qgsreadwritecontext.h"
24 #include "qgssettings.h"
25 #include "qgslegendpatchshape.h"
26 #include "qgslinestring.h"
27 #include "qgspolygon.h"
28 #include "qgsmarkersymbollayer.h"
29 #include "qgslinesymbollayer.h"
30 #include "qgsfillsymbollayer.h"
31 #include "qgsruntimeprofiler.h"
32 #include "qgsabstract3dsymbol.h"
33 #include "qgs3dsymbolregistry.h"
34
35 #include <QDomDocument>
36 #include <QDomElement>
37 #include <QDomNode>
38 #include <QDomNodeList>
39 #include <QFile>
40 #include <QTextStream>
41 #include <QByteArray>
42
43 #include <sqlite3.h>
44 #include "qgssqliteutils.h"
45
46 #define STYLE_CURRENT_VERSION "2"
47
52 {
57 };
58
63 {
68 };
69
70
71 QgsStyle *QgsStyle::sDefaultStyle = nullptr;
72
74 {
75 std::unique_ptr< QgsSimpleMarkerSymbolLayer > simpleMarker = qgis::make_unique< QgsSimpleMarkerSymbolLayer >( QgsSimpleMarkerSymbolLayerBase::Circle,
76 1.6, 0, QgsSymbol::ScaleArea, QColor( 84, 176, 74 ), QColor( 61, 128, 53 ) );
77 simpleMarker->setStrokeWidth( 0.4 );
78 mPatchMarkerSymbol = qgis::make_unique< QgsMarkerSymbol >( QgsSymbolLayerList() << simpleMarker.release() );
79
80 std::unique_ptr< QgsSimpleLineSymbolLayer > simpleLine = qgis::make_unique< QgsSimpleLineSymbolLayer >( QColor( 84, 176, 74 ), 0.6 );
81 mPatchLineSymbol = qgis::make_unique< QgsLineSymbol >( QgsSymbolLayerList() << simpleLine.release() );
82
83 std::unique_ptr< QgsGradientFillSymbolLayer > gradientFill = qgis::make_unique< QgsGradientFillSymbolLayer >( QColor( 66, 150, 63 ), QColor( 84, 176, 74 ) );
84 std::unique_ptr< QgsSimpleLineSymbolLayer > simpleOutline = qgis::make_unique< QgsSimpleLineSymbolLayer >( QColor( 56, 128, 54 ), 0.26 );
85 mPatchFillSymbol = qgis::make_unique< QgsFillSymbol >( QgsSymbolLayerList() << gradientFill.release() << simpleOutline.release() );
86 }
87
89 {
90 clear();
91 }
92
93 bool QgsStyle::addEntity( const QString &name, const QgsStyleEntityInterface *entity, bool update )
94 {
95 switch ( entity->type() )
96 {
97 case SymbolEntity:
98 if ( !static_cast< const QgsStyleSymbolEntity * >( entity )->symbol() )
99 return false;
100 return addSymbol( name, static_cast< const QgsStyleSymbolEntity * >( entity )->symbol()->clone(), update );
101
102 case ColorrampEntity:
103 if ( !static_cast< const QgsStyleColorRampEntity * >( entity )->ramp() )
104 return false;
105 return addColorRamp( name, static_cast< const QgsStyleColorRampEntity * >( entity )->ramp()->clone(), update );
106
107 case TextFormatEntity:
108 return addTextFormat( name, static_cast< const QgsStyleTextFormatEntity * >( entity )->format(), update );
109
110 case LabelSettingsEntity:
111 return addLabelSettings( name, static_cast< const QgsStyleLabelSettingsEntity * >( entity )->settings(), update );
112
114 return addLegendPatchShape( name, static_cast< const QgsStyleLegendPatchShapeEntity * >( entity )->shape(), update );
115
116 case Symbol3DEntity:
117 return addSymbol3D( name, static_cast< const QgsStyleSymbol3DEntity * >( entity )->symbol()->clone(), update );
118
119 case TagEntity:
120 case SmartgroupEntity:
121 break;
122
123 }
124 return false;
125 }
126
128 {
129 if ( !sDefaultStyle )
130 {
131 QgsScopedRuntimeProfile profile( tr( "Load default style database" ) );
132 QString styleFilename = QgsApplication::userStylePath();
133
134 // copy default style if user style doesn't exist
135 if ( !QFile::exists( styleFilename ) )
136 {
137 sDefaultStyle = new QgsStyle;
138 sDefaultStyle->createDatabase( styleFilename );
139 if ( QFile::exists( QgsApplication::defaultStylePath() ) )
140 {
141 sDefaultStyle->importXml( QgsApplication::defaultStylePath() );
142 }
143 }
144 else
145 {
146 sDefaultStyle = new QgsStyle;
147 if ( sDefaultStyle->load( styleFilename ) )
148 {
149 sDefaultStyle->upgradeIfRequired();
150 }
151 }
152 }
153 return sDefaultStyle;
154 }
155
157 {
158 delete sDefaultStyle;
159 sDefaultStyle = nullptr;
160 }
161
163 {
164 qDeleteAll( mSymbols );
165 qDeleteAll( mColorRamps );
166 qDeleteAll( m3dSymbols );
167
168 mSymbols.clear();
169 mColorRamps.clear();
170 mTextFormats.clear();
171 m3dSymbols.clear();
172
173 mCachedTags.clear();
174 mCachedFavorites.clear();
175 }
176
177 bool QgsStyle::addSymbol( const QString &name, QgsSymbol *symbol, bool update )
178 {
179 if ( !symbol || name.isEmpty() )
180 return false;
181
182 // delete previous symbol (if any)
183 if ( mSymbols.contains( name ) )
184 {
185 // TODO remove groups and tags?
186 delete mSymbols.value( name );
187 mSymbols.insert( name, symbol );
188 if ( update )
189 updateSymbol( SymbolEntity, name );
190 }
191 else
192 {
193 mSymbols.insert( name, symbol );
194 if ( update )
195 saveSymbol( name, symbol, false, QStringList() );
196 }
197
198 return true;
199 }
200
201 bool QgsStyle::saveSymbol( const QString &name, QgsSymbol *symbol, bool favorite, const QStringList &tags )
202 {
203 // TODO add support for groups
204 QDomDocument doc( QStringLiteral( "dummy" ) );
205 QDomElement symEl = QgsSymbolLayerUtils::saveSymbol( name, symbol, doc, QgsReadWriteContext() );
206 if ( symEl.isNull() )
207 {
208 QgsDebugMsg( QStringLiteral( "Couldn't convert symbol to valid XML!" ) );
209 return false;
210 }
211
212 QByteArray xmlArray;
213 QTextStream stream( &xmlArray );
214 stream.setCodec( "UTF-8" );
215 symEl.save( stream, 4 );
216 QString query = qgs_sqlite3_mprintf( "INSERT INTO symbol VALUES (NULL, '%q', '%q', %d);",
217 name.toUtf8().constData(), xmlArray.constData(), ( favorite ? 1 : 0 ) );
218
219 if ( !runEmptyQuery( query ) )
220 {
221 QgsDebugMsg( QStringLiteral( "Couldn't insert symbol into the database!" ) );
222 return false;
223 }
224
225 mCachedFavorites[ SymbolEntity ].insert( name, favorite );
226
227 tagSymbol( SymbolEntity, name, tags );
228
229 emit symbolSaved( name, symbol );
230 emit entityAdded( SymbolEntity, name );
231
232 return true;
233 }
234
235 bool QgsStyle::removeSymbol( const QString &name )
236 {
237 return removeEntityByName( SymbolEntity, name );
238 }
239
240 bool QgsStyle::renameEntity( QgsStyle::StyleEntity type, const QString &oldName, const QString &newName )
241 {
242 switch ( type )
243 {
244 case SymbolEntity:
245 return renameSymbol( oldName, newName );
246
247 case ColorrampEntity:
248 return renameColorRamp( oldName, newName );
249
250 case TextFormatEntity:
251 return renameTextFormat( oldName, newName );
252
253 case LabelSettingsEntity:
254 return renameLabelSettings( oldName, newName );
255
257 return renameLegendPatchShape( oldName, newName );
258
259 case Symbol3DEntity:
260 return renameSymbol3D( oldName, newName );
261
262 case TagEntity:
263 case SmartgroupEntity:
264 return false;
265 }
266 return false;
267 }
268
269 QgsSymbol *QgsStyle::symbol( const QString &name )
270 {
271 const QgsSymbol *symbol = symbolRef( name );
272 return symbol ? symbol->clone() : nullptr;
273 }
274
275 const QgsSymbol *QgsStyle::symbolRef( const QString &name ) const
276 {
277 return mSymbols.value( name );
278 }
279
281 {
282 return mSymbols.count();
283 }
284
285 QStringList QgsStyle::symbolNames() const
286 {
287 return mSymbols.keys();
288 }
289
290
291 bool QgsStyle::addColorRamp( const QString &name, QgsColorRamp *colorRamp, bool update )
292 {
293 if ( !colorRamp || name.isEmpty() )
294 return false;
295
296 // delete previous color ramps (if any)
297 if ( mColorRamps.contains( name ) )
298 {
299 // TODO remove groups and tags?
300 delete mColorRamps.value( name );
301 mColorRamps.insert( name, colorRamp );
302 if ( update )
303 updateSymbol( ColorrampEntity, name );
304 }
305 else
306 {
307 mColorRamps.insert( name, colorRamp );
308 if ( update )
309 saveColorRamp( name, colorRamp, false, QStringList() );
310 }
311
312 return true;
313 }
314
315 bool QgsStyle::addTextFormat( const QString &name, const QgsTextFormat &format, bool update )
316 {
317 // delete previous text format (if any)
318 if ( mTextFormats.contains( name ) )
319 {
320 // TODO remove groups and tags?
321 mTextFormats.remove( name );
322 mTextFormats.insert( name, format );
323 if ( update )
324 updateSymbol( TextFormatEntity, name );
325 }
326 else
327 {
328 mTextFormats.insert( name, format );
329 if ( update )
330 saveTextFormat( name, format, false, QStringList() );
331 }
332
333 return true;
334 }
335
336 bool QgsStyle::addLabelSettings( const QString &name, const QgsPalLayerSettings &settings, bool update )
337 {
338 // delete previous label settings (if any)
339 if ( mLabelSettings.contains( name ) )
340 {
341 // TODO remove groups and tags?
342 mLabelSettings.remove( name );
343 mLabelSettings.insert( name, settings );
344 if ( update )
345 updateSymbol( LabelSettingsEntity, name );
346 }
347 else
348 {
349 mLabelSettings.insert( name, settings );
350 if ( update )
351 saveLabelSettings( name, settings, false, QStringList() );
352 }
353
354 return true;
355 }
356
357 bool QgsStyle::addLegendPatchShape( const QString &name, const QgsLegendPatchShape &shape, bool update )
358 {
359 // delete previous legend patch shape (if any)
360 if ( mLegendPatchShapes.contains( name ) )
361 {
362 // TODO remove groups and tags?
363 mLegendPatchShapes.remove( name );
364 mLegendPatchShapes.insert( name, shape );
365 if ( update )
366 updateSymbol( LegendPatchShapeEntity, name );
367 }
368 else
369 {
370 mLegendPatchShapes.insert( name, shape );
371 if ( update )
372 saveLegendPatchShape( name, shape, false, QStringList() );
373 }
374
375 return true;
376 }
377
378 bool QgsStyle::addSymbol3D( const QString &name, QgsAbstract3DSymbol *symbol, bool update )
379 {
380 // delete previous symbol (if any)
381 if ( m3dSymbols.contains( name ) )
382 {
383 // TODO remove groups and tags?
384 delete m3dSymbols.take( name );
385 m3dSymbols.insert( name, symbol );
386 if ( update )
387 updateSymbol( Symbol3DEntity, name );
388 }
389 else
390 {
391 m3dSymbols.insert( name, symbol );
392 if ( update )
393 saveSymbol3D( name, symbol, false, QStringList() );
394 }
395
396 return true;
397 }
398
399 bool QgsStyle::saveColorRamp( const QString &name, QgsColorRamp *ramp, bool favorite, const QStringList &tags )
400 {
401 // insert it into the database
402 QDomDocument doc( QStringLiteral( "dummy" ) );
403 QDomElement rampEl = QgsSymbolLayerUtils::saveColorRamp( name, ramp, doc );
404
405 if ( rampEl.isNull() )
406 {
407 QgsDebugMsg( QStringLiteral( "Couldn't convert color ramp to valid XML!" ) );
408 return false;
409 }
410
411 QByteArray xmlArray;
412 QTextStream stream( &xmlArray );
413 stream.setCodec( "UTF-8" );
414 rampEl.save( stream, 4 );
415 QString query = qgs_sqlite3_mprintf( "INSERT INTO colorramp VALUES (NULL, '%q', '%q', %d);",
416 name.toUtf8().constData(), xmlArray.constData(), ( favorite ? 1 : 0 ) );
417 if ( !runEmptyQuery( query ) )
418 {
419 QgsDebugMsg( QStringLiteral( "Couldn't insert colorramp into the database!" ) );
420 return false;
421 }
422
423 mCachedFavorites[ ColorrampEntity ].insert( name, favorite );
424
425 tagSymbol( ColorrampEntity, name, tags );
426
427 emit rampAdded( name );
428 emit entityAdded( ColorrampEntity, name );
429
430 return true;
431 }
432
433 bool QgsStyle::removeColorRamp( const QString &name )
434 {
435 return removeEntityByName( ColorrampEntity, name );
436 }
437
438 QgsColorRamp *QgsStyle::colorRamp( const QString &name ) const
439 {
440 const QgsColorRamp *ramp = colorRampRef( name );
441 return ramp ? ramp->clone() : nullptr;
442 }
443
444 const QgsColorRamp *QgsStyle::colorRampRef( const QString &name ) const
445 {
446 return mColorRamps.value( name );
447 }
448
450 {
451 return mColorRamps.count();
452 }
453
454 QStringList QgsStyle::colorRampNames() const
455 {
456 return mColorRamps.keys();
457 }
458
459 void QgsStyle::handleDeferred3DSymbolCreation()
460 {
461 for ( auto it = mDeferred3DsymbolElements.constBegin(); it != mDeferred3DsymbolElements.constEnd(); ++it )
462 {
463 const QString symbolType = it.value().attribute( QStringLiteral( "type" ) );
464 std::unique_ptr< QgsAbstract3DSymbol > symbol( QgsApplication::symbol3DRegistry()->createSymbol( symbolType ) );
465 if ( symbol )
466 {
467 symbol->readXml( it.value(), QgsReadWriteContext() );
468 addSymbol3D( it.key(), symbol.release(), false );
469 emit entityAdded( Symbol3DEntity, it.key() );
470 }
471 else
472 {
473 QgsDebugMsg( "Cannot open 3d symbol " + it.key() );
474 continue;
475 }
476 }
477 mDeferred3DsymbolElements.clear();
478 }
479
480 bool QgsStyle::openDatabase( const QString &filename )
481 {
482 int rc = mCurrentDB.open( filename );
483 if ( rc )
484 {
485 mErrorString = QStringLiteral( "Couldn't open the style database: %1" ).arg( mCurrentDB.errorMessage() );
486 return false;
487 }
488
489 return true;
490 }
491
492 bool QgsStyle::createDatabase( const QString &filename )
493 {
494 mErrorString.clear();
495 if ( !openDatabase( filename ) )
496 {
497 mErrorString = QStringLiteral( "Unable to create database" );
498 QgsDebugMsg( mErrorString );
499 return false;
500 }
501
502 createTables();
503
504 return true;
505 }
506
508 {
509 mErrorString.clear();
510 if ( !openDatabase( QStringLiteral( ":memory:" ) ) )
511 {
512 mErrorString = QStringLiteral( "Unable to create temporary memory database" );
513 QgsDebugMsg( mErrorString );
514 return false;
515 }
516
517 createTables();
518
519 return true;
520 }
521
523 {
524 QString query = qgs_sqlite3_mprintf( "CREATE TABLE symbol("\
525 "id INTEGER PRIMARY KEY,"\
526 "name TEXT UNIQUE,"\
527 "xml TEXT,"\
528 "favorite INTEGER);"\
529 "CREATE TABLE colorramp("\
530 "id INTEGER PRIMARY KEY,"\
531 "name TEXT UNIQUE,"\
532 "xml TEXT,"\
533 "favorite INTEGER);"\
534 "CREATE TABLE textformat("\
535 "id INTEGER PRIMARY KEY,"\
536 "name TEXT UNIQUE,"\
537 "xml TEXT,"\
538 "favorite INTEGER);"\
539 "CREATE TABLE labelsettings("\
540 "id INTEGER PRIMARY KEY,"\
541 "name TEXT UNIQUE,"\
542 "xml TEXT,"\
543 "favorite INTEGER);"\
544 "CREATE TABLE legendpatchshapes("\
545 "id INTEGER PRIMARY KEY,"\
546 "name TEXT UNIQUE,"\
547 "xml TEXT,"\
548 "favorite INTEGER);"\
549 "CREATE TABLE symbol3d("\
550 "id INTEGER PRIMARY KEY,"\
551 "name TEXT UNIQUE,"\
552 "xml TEXT,"\
553 "favorite INTEGER);"\
554 "CREATE TABLE tag("\
555 "id INTEGER PRIMARY KEY,"\
556 "name TEXT);"\
557 "CREATE TABLE tagmap("\
558 "tag_id INTEGER NOT NULL,"\
559 "symbol_id INTEGER);"\
560 "CREATE TABLE ctagmap("\
561 "tag_id INTEGER NOT NULL,"\
562 "colorramp_id INTEGER);"\
563 "CREATE TABLE tftagmap("\
564 "tag_id INTEGER NOT NULL,"\
565 "textformat_id INTEGER);"\
566 "CREATE TABLE lstagmap("\
567 "tag_id INTEGER NOT NULL,"\
568 "labelsettings_id INTEGER);"\
569 "CREATE TABLE lpstagmap("\
570 "tag_id INTEGER NOT NULL,"\
571 "legendpatchshape_id INTEGER);"\
572 "CREATE TABLE symbol3dtagmap("\
573 "tag_id INTEGER NOT NULL,"\
574 "symbol3d_id INTEGER);"\
575 "CREATE TABLE smartgroup("\
576 "id INTEGER PRIMARY KEY,"\
577 "name TEXT,"\
578 "xml TEXT);" );
579 runEmptyQuery( query );
580 }
581
582 bool QgsStyle::load( const QString &filename )
583 {
584 mErrorString.clear();
585
586 // Open the sqlite database
587 if ( !openDatabase( filename ) )
588 {
589 mErrorString = QStringLiteral( "Unable to open database file specified" );
590 QgsDebugMsg( mErrorString );
591 return false;
592 }
593
594 // make sure text format table exists
595 QString query = qgs_sqlite3_mprintf( "SELECT name FROM sqlite_master WHERE name='textformat'" );
597 int rc;
598 statement = mCurrentDB.prepare( query, rc );
599 if ( rc != SQLITE_OK || sqlite3_step( statement.get() ) != SQLITE_ROW )
600 {
601 query = qgs_sqlite3_mprintf( "CREATE TABLE textformat("\
602 "id INTEGER PRIMARY KEY,"\
603 "name TEXT UNIQUE,"\
604 "xml TEXT,"\
605 "favorite INTEGER);"\
606 "CREATE TABLE tftagmap("\
607 "tag_id INTEGER NOT NULL,"\
608 "textformat_id INTEGER);" );
609 runEmptyQuery( query );
610 }
611 // make sure label settings table exists
612 query = qgs_sqlite3_mprintf( "SELECT name FROM sqlite_master WHERE name='labelsettings'" );
613 statement = mCurrentDB.prepare( query, rc );
614 if ( rc != SQLITE_OK || sqlite3_step( statement.get() ) != SQLITE_ROW )
615 {
616 query = qgs_sqlite3_mprintf( "CREATE TABLE labelsettings("\
617 "id INTEGER PRIMARY KEY,"\
618 "name TEXT UNIQUE,"\
619 "xml TEXT,"\
620 "favorite INTEGER);"\
621 "CREATE TABLE lstagmap("\
622 "tag_id INTEGER NOT NULL,"\
623 "labelsettings_id INTEGER);" );
624 runEmptyQuery( query );
625 }
626 // make sure legend patch shape table exists
627 query = qgs_sqlite3_mprintf( "SELECT name FROM sqlite_master WHERE name='legendpatchshapes'" );
628 statement = mCurrentDB.prepare( query, rc );
629 if ( rc != SQLITE_OK || sqlite3_step( statement.get() ) != SQLITE_ROW )
630 {
631 query = qgs_sqlite3_mprintf( "CREATE TABLE legendpatchshapes("\
632 "id INTEGER PRIMARY KEY,"\
633 "name TEXT UNIQUE,"\
634 "xml TEXT,"\
635 "favorite INTEGER);"\
636 "CREATE TABLE lpstagmap("\
637 "tag_id INTEGER NOT NULL,"\
638 "legendpatchshape_id INTEGER);" );
639 runEmptyQuery( query );
640 }
641 // make sure 3d symbol table exists
642 query = qgs_sqlite3_mprintf( "SELECT name FROM sqlite_master WHERE name='symbol3d'" );
643 statement = mCurrentDB.prepare( query, rc );
644 if ( rc != SQLITE_OK || sqlite3_step( statement.get() ) != SQLITE_ROW )
645 {
646 query = qgs_sqlite3_mprintf( "CREATE TABLE symbol3d("\
647 "id INTEGER PRIMARY KEY,"\
648 "name TEXT UNIQUE,"\
649 "xml TEXT,"\
650 "favorite INTEGER);"\
651 "CREATE TABLE symbol3dtagmap("\
652 "tag_id INTEGER NOT NULL,"\
653 "symbol3d_id INTEGER);" );
654 runEmptyQuery( query );
655 }
656
657 // Make sure there are no Null fields in parenting symbols and groups
658 query = qgs_sqlite3_mprintf( "UPDATE symbol SET favorite=0 WHERE favorite IS NULL;"
659 "UPDATE colorramp SET favorite=0 WHERE favorite IS NULL;"
660 "UPDATE textformat SET favorite=0 WHERE favorite IS NULL;"
661 "UPDATE labelsettings SET favorite=0 WHERE favorite IS NULL;"
662 "UPDATE legendpatchshapes SET favorite=0 WHERE favorite IS NULL;"
663 "UPDATE symbol3d SET favorite=0 WHERE favorite IS NULL;"
664 );
665 runEmptyQuery( query );
666
667 {
668 QgsScopedRuntimeProfile profile( tr( "Load symbols" ) );
669 // First create all the main symbols
670 query = qgs_sqlite3_mprintf( "SELECT * FROM symbol" );
671 statement = mCurrentDB.prepare( query, rc );
672
673 while ( rc == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
674 {
675 QDomDocument doc;
676 QString symbolName = statement.columnAsText( SymbolName );
677 QgsScopedRuntimeProfile profile( symbolName );
678 QString xmlstring = statement.columnAsText( SymbolXML );
679 if ( !doc.setContent( xmlstring ) )
680 {
681 QgsDebugMsg( "Cannot open symbol " + symbolName );
682 continue;
683 }
684
685 QDomElement symElement = doc.documentElement();
687 if ( symbol )
688 mSymbols.insert( symbolName, symbol );
689 }
690 }
691
692 {
693 QgsScopedRuntimeProfile profile( tr( "Load color ramps" ) );
694 query = qgs_sqlite3_mprintf( "SELECT * FROM colorramp" );
695 statement = mCurrentDB.prepare( query, rc );
696 while ( rc == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
697 {
698 QDomDocument doc;
699 const QString rampName = statement.columnAsText( ColorrampName );
700 QgsScopedRuntimeProfile profile( rampName );
701 QString xmlstring = statement.columnAsText( ColorrampXML );
702 if ( !doc.setContent( xmlstring ) )
703 {
704 QgsDebugMsg( "Cannot open symbol " + rampName );
705 continue;
706 }
707 QDomElement rampElement = doc.documentElement();
708 QgsColorRamp *ramp = QgsSymbolLayerUtils::loadColorRamp( rampElement );
709 if ( ramp )
710 mColorRamps.insert( rampName, ramp );
711 }
712 }
713
714 {
715 QgsScopedRuntimeProfile profile( tr( "Load text formats" ) );
716 query = qgs_sqlite3_mprintf( "SELECT * FROM textformat" );
717 statement = mCurrentDB.prepare( query, rc );
718 while ( rc == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
719 {
720 QDomDocument doc;
721 const QString formatName = statement.columnAsText( TextFormatName );
722 QgsScopedRuntimeProfile profile( formatName );
723 const QString xmlstring = statement.columnAsText( TextFormatXML );
724 if ( !doc.setContent( xmlstring ) )
725 {
726 QgsDebugMsg( "Cannot open text format " + formatName );
727 continue;
728 }
729 QDomElement formatElement = doc.documentElement();
730 QgsTextFormat format;
731 format.readXml( formatElement, QgsReadWriteContext() );
732 mTextFormats.insert( formatName, format );
733 }
734 }
735
736 {
737 QgsScopedRuntimeProfile profile( tr( "Load label settings" ) );
738 query = qgs_sqlite3_mprintf( "SELECT * FROM labelsettings" );
739 statement = mCurrentDB.prepare( query, rc );
740 while ( rc == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
741 {
742 QDomDocument doc;
743 const QString settingsName = statement.columnAsText( LabelSettingsName );
744 QgsScopedRuntimeProfile profile( settingsName );
745 const QString xmlstring = statement.columnAsText( LabelSettingsXML );
746 if ( !doc.setContent( xmlstring ) )
747 {
748 QgsDebugMsg( "Cannot open label settings " + settingsName );
749 continue;
750 }
751 QDomElement settingsElement = doc.documentElement();
752 QgsPalLayerSettings settings;
753 settings.readXml( settingsElement, QgsReadWriteContext() );
754 mLabelSettings.insert( settingsName, settings );
755 }
756 }
757
758 {
759 QgsScopedRuntimeProfile profile( tr( "Load legend patch shapes" ) );
760 query = qgs_sqlite3_mprintf( "SELECT * FROM legendpatchshapes" );
761 statement = mCurrentDB.prepare( query, rc );
762 while ( rc == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
763 {
764 QDomDocument doc;
765 const QString settingsName = statement.columnAsText( LegendPatchTableName );
766 QgsScopedRuntimeProfile profile( settingsName );
767 const QString xmlstring = statement.columnAsText( LegendPatchTableXML );
768 if ( !doc.setContent( xmlstring ) )
769 {
770 QgsDebugMsg( "Cannot open legend patch shape " + settingsName );
771 continue;
772 }
773 QDomElement settingsElement = doc.documentElement();
774 QgsLegendPatchShape shape;
775 shape.readXml( settingsElement, QgsReadWriteContext() );
776 mLegendPatchShapes.insert( settingsName, shape );
777 }
778 }
779
780 {
781 QgsScopedRuntimeProfile profile( tr( "Load 3D symbols shapes" ) );
782 query = qgs_sqlite3_mprintf( "SELECT * FROM symbol3d" );
783 statement = mCurrentDB.prepare( query, rc );
784
785 const bool registry3dPopulated = !QgsApplication::symbol3DRegistry()->symbolTypes().empty();
786
787 while ( rc == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
788 {
789 QDomDocument doc;
790 const QString settingsName = statement.columnAsText( Symbol3DTableName );
791 QgsScopedRuntimeProfile profile( settingsName );
792 const QString xmlstring = statement.columnAsText( Symbol3DTableXML );
793 if ( !doc.setContent( xmlstring ) )
794 {
795 QgsDebugMsg( "Cannot open 3d symbol " + settingsName );
796 continue;
797 }
798 QDomElement settingsElement = doc.documentElement();
799
800 if ( !registry3dPopulated )
801 {
802 mDeferred3DsymbolElements.insert( settingsName, settingsElement );
803 }
804 else
805 {
806 const QString symbolType = settingsElement.attribute( QStringLiteral( "type" ) );
807 std::unique_ptr< QgsAbstract3DSymbol > symbol( QgsApplication::symbol3DRegistry()->createSymbol( symbolType ) );
808 if ( symbol )
809 {
810 symbol->readXml( settingsElement, QgsReadWriteContext() );
811 m3dSymbols.insert( settingsName, symbol.release() );
812 }
813 else
814 {
815 QgsDebugMsg( "Cannot open 3d symbol " + settingsName );
816 continue;
817 }
818 }
819 }
820 }
821
822 mFileName = filename;
823 return true;
824 }
825
826
827
828 bool QgsStyle::save( QString filename )
829 {
830 mErrorString.clear();
831
832 if ( filename.isEmpty() )
833 filename = mFileName;
834
835 // TODO evaluate the requirement of this function and change implementation accordingly
836 // TODO remove QEXPECT_FAIL from TestStyle::testSaveLoad() when done
837 #if 0
838 QDomDocument doc( "qgis_style" );
839 QDomElement root = doc.createElement( "qgis_style" );
840 root.setAttribute( "version", STYLE_CURRENT_VERSION );
841 doc.appendChild( root );
842
843 QDomElement symbolsElem = QgsSymbolLayerUtils::saveSymbols( mSymbols, "symbols", doc );
844
845 QDomElement rampsElem = doc.createElement( "colorramps" );
846
847 // save color ramps
848 for ( QMap<QString, QgsColorRamp *>::iterator itr = mColorRamps.begin(); itr != mColorRamps.end(); ++itr )
849 {
850 QDomElement rampEl = QgsSymbolLayerUtils::saveColorRamp( itr.key(), itr.value(), doc );
851 rampsElem.appendChild( rampEl );
852 }
853
854 root.appendChild( symbolsElem );
855 root.appendChild( rampsElem );
856
857 // save
858 QFile f( filename );
859 if ( !f.open( QFile::WriteOnly ) )
860 {
861 mErrorString = "Couldn't open file for writing: " + filename;
862 return false;
863 }
864 QTextStream ts( &f );
865 ts.setCodec( "UTF-8" );
866 doc.save( ts, 2 );
867 f.close();
868 #endif
869
870 mFileName = filename;
871 return true;
872 }
873
874 bool QgsStyle::renameSymbol( const QString &oldName, const QString &newName )
875 {
876 if ( mSymbols.contains( newName ) )
877 {
878 QgsDebugMsg( QStringLiteral( "Symbol of new name already exists" ) );
879 return false;
880 }
881
882 QgsSymbol *symbol = mSymbols.take( oldName );
883 if ( !symbol )
884 return false;
885
886 mSymbols.insert( newName, symbol );
887
888 if ( !mCurrentDB )
889 {
890 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database to tag." ) );
891 return false;
892 }
893
894 int symbolid = symbolId( oldName );
895 if ( !symbolid )
896 {
897 QgsDebugMsg( QStringLiteral( "No such symbol for tagging in database: " ) + oldName );
898 return false;
899 }
900
901 mCachedTags[ SymbolEntity ].remove( oldName );
902 mCachedFavorites[ SymbolEntity ].remove( oldName );
903
904 const bool result = rename( SymbolEntity, symbolid, newName );
905 if ( result )
906 {
907 emit symbolRenamed( oldName, newName );
908 emit entityRenamed( SymbolEntity, oldName, newName );
909 }
910
911 return result;
912 }
913
914 bool QgsStyle::renameColorRamp( const QString &oldName, const QString &newName )
915 {
916 if ( mColorRamps.contains( newName ) )
917 {
918 QgsDebugMsg( QStringLiteral( "Color ramp of new name already exists." ) );
919 return false;
920 }
921
922 QgsColorRamp *ramp = mColorRamps.take( oldName );
923 if ( !ramp )
924 return false;
925
926 mColorRamps.insert( newName, ramp );
927 mCachedTags[ ColorrampEntity ].remove( oldName );
928 mCachedFavorites[ ColorrampEntity ].remove( oldName );
929
930 int rampid = 0;
932 QString query = qgs_sqlite3_mprintf( "SELECT id FROM colorramp WHERE name='%q'", oldName.toUtf8().constData() );
933 int nErr;
934 statement = mCurrentDB.prepare( query, nErr );
935 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
936 {
937 rampid = sqlite3_column_int( statement.get(), 0 );
938 }
939 const bool result = rename( ColorrampEntity, rampid, newName );
940 if ( result )
941 {
942 emit rampRenamed( oldName, newName );
943 emit entityRenamed( ColorrampEntity, oldName, newName );
944 }
945
946 return result;
947 }
948
949 bool QgsStyle::saveTextFormat( const QString &name, const QgsTextFormat &format, bool favorite, const QStringList &tags )
950 {
951 // insert it into the database
952 QDomDocument doc( QStringLiteral( "dummy" ) );
953 QDomElement formatElem = format.writeXml( doc, QgsReadWriteContext() );
954
955 if ( formatElem.isNull() )
956 {
957 QgsDebugMsg( QStringLiteral( "Couldn't convert text format to valid XML!" ) );
958 return false;
959 }
960
961 QByteArray xmlArray;
962 QTextStream stream( &xmlArray );
963 stream.setCodec( "UTF-8" );
964 formatElem.save( stream, 4 );
965 QString query = qgs_sqlite3_mprintf( "INSERT INTO textformat VALUES (NULL, '%q', '%q', %d);",
966 name.toUtf8().constData(), xmlArray.constData(), ( favorite ? 1 : 0 ) );
967 if ( !runEmptyQuery( query ) )
968 {
969 QgsDebugMsg( QStringLiteral( "Couldn't insert text format into the database!" ) );
970 return false;
971 }
972
973 mCachedFavorites[ TextFormatEntity ].insert( name, favorite );
974
975 tagSymbol( TextFormatEntity, name, tags );
976
977 emit textFormatAdded( name );
978 emit entityAdded( TextFormatEntity, name );
979
980 return true;
981 }
982
983 bool QgsStyle::removeTextFormat( const QString &name )
984 {
985 return removeEntityByName( TextFormatEntity, name );
986 }
987
988 bool QgsStyle::renameTextFormat( const QString &oldName, const QString &newName )
989 {
990 if ( mTextFormats.contains( newName ) )
991 {
992 QgsDebugMsg( QStringLiteral( "Text format of new name already exists." ) );
993 return false;
994 }
995
996 if ( !mTextFormats.contains( oldName ) )
997 return false;
998 QgsTextFormat format = mTextFormats.take( oldName );
999
1000 mTextFormats.insert( newName, format );
1001 mCachedTags[ TextFormatEntity ].remove( oldName );
1002 mCachedFavorites[ TextFormatEntity ].remove( oldName );
1003
1004 int textFormatId = 0;
1005 sqlite3_statement_unique_ptr statement;
1006 QString query = qgs_sqlite3_mprintf( "SELECT id FROM textformat WHERE name='%q'", oldName.toUtf8().constData() );
1007 int nErr;
1008 statement = mCurrentDB.prepare( query, nErr );
1009 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1010 {
1011 textFormatId = sqlite3_column_int( statement.get(), 0 );
1012 }
1013 const bool result = rename( TextFormatEntity, textFormatId, newName );
1014 if ( result )
1015 {
1016 emit textFormatRenamed( oldName, newName );
1017 emit entityRenamed( TextFormatEntity, oldName, newName );
1018 }
1019
1020 return result;
1021 }
1022
1023 bool QgsStyle::saveLabelSettings( const QString &name, const QgsPalLayerSettings &settings, bool favorite, const QStringList &tags )
1024 {
1025 // insert it into the database
1026 QDomDocument doc( QStringLiteral( "dummy" ) );
1027 QDomElement settingsElem = settings.writeXml( doc, QgsReadWriteContext() );
1028
1029 if ( settingsElem.isNull() )
1030 {
1031 QgsDebugMsg( QStringLiteral( "Couldn't convert label settings to valid XML!" ) );
1032 return false;
1033 }
1034
1035 QByteArray xmlArray;
1036 QTextStream stream( &xmlArray );
1037 stream.setCodec( "UTF-8" );
1038 settingsElem.save( stream, 4 );
1039 QString query = qgs_sqlite3_mprintf( "INSERT INTO labelsettings VALUES (NULL, '%q', '%q', %d);",
1040 name.toUtf8().constData(), xmlArray.constData(), ( favorite ? 1 : 0 ) );
1041 if ( !runEmptyQuery( query ) )
1042 {
1043 QgsDebugMsg( QStringLiteral( "Couldn't insert label settings into the database!" ) );
1044 return false;
1045 }
1046
1047 mCachedFavorites[ LabelSettingsEntity ].insert( name, favorite );
1048
1050
1051 emit labelSettingsAdded( name );
1052 emit entityAdded( LabelSettingsEntity, name );
1053
1054 return true;
1055 }
1056
1057 bool QgsStyle::removeLabelSettings( const QString &name )
1058 {
1059 return removeEntityByName( LabelSettingsEntity, name );
1060 }
1061
1062 bool QgsStyle::renameLabelSettings( const QString &oldName, const QString &newName )
1063 {
1064 if ( mLabelSettings.contains( newName ) )
1065 {
1066 QgsDebugMsg( QStringLiteral( "Label settings of new name already exists." ) );
1067 return false;
1068 }
1069
1070 if ( !mLabelSettings.contains( oldName ) )
1071 return false;
1072 QgsPalLayerSettings settings = mLabelSettings.take( oldName );
1073
1074 mLabelSettings.insert( newName, settings );
1075 mCachedTags[ LabelSettingsEntity ].remove( oldName );
1076 mCachedFavorites[ LabelSettingsEntity ].remove( oldName );
1077
1078 int labelSettingsId = 0;
1079 sqlite3_statement_unique_ptr statement;
1080 QString query = qgs_sqlite3_mprintf( "SELECT id FROM labelsettings WHERE name='%q'", oldName.toUtf8().constData() );
1081 int nErr;
1082 statement = mCurrentDB.prepare( query, nErr );
1083 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1084 {
1085 labelSettingsId = sqlite3_column_int( statement.get(), 0 );
1086 }
1087 const bool result = rename( LabelSettingsEntity, labelSettingsId, newName );
1088 if ( result )
1089 {
1090 emit labelSettingsRenamed( oldName, newName );
1091 emit entityRenamed( LabelSettingsEntity, oldName, newName );
1092 }
1093
1094 return result;
1095 }
1096
1097 bool QgsStyle::saveLegendPatchShape( const QString &name, const QgsLegendPatchShape &shape, bool favorite, const QStringList &tags )
1098 {
1099 // insert it into the database
1100 QDomDocument doc( QStringLiteral( "dummy" ) );
1101 QDomElement shapeElem = doc.createElement( QStringLiteral( "shape" ) );
1102 shape.writeXml( shapeElem, doc, QgsReadWriteContext() );
1103
1104 QByteArray xmlArray;
1105 QTextStream stream( &xmlArray );
1106 stream.setCodec( "UTF-8" );
1107 shapeElem.save( stream, 4 );
1108 QString query = qgs_sqlite3_mprintf( "INSERT INTO legendpatchshapes VALUES (NULL, '%q', '%q', %d);",
1109 name.toUtf8().constData(), xmlArray.constData(), ( favorite ? 1 : 0 ) );
1110 if ( !runEmptyQuery( query ) )
1111 {
1112 QgsDebugMsg( QStringLiteral( "Couldn't insert legend patch shape into the database!" ) );
1113 return false;
1114 }
1115
1116 mCachedFavorites[ LegendPatchShapeEntity ].insert( name, favorite );
1117
1119
1120 emit entityAdded( LegendPatchShapeEntity, name );
1121
1122 return true;
1123 }
1124
1125 bool QgsStyle::renameLegendPatchShape( const QString &oldName, const QString &newName )
1126 {
1127 if ( mLegendPatchShapes.contains( newName ) )
1128 {
1129 QgsDebugMsg( QStringLiteral( "Legend patch shape of new name already exists." ) );
1130 return false;
1131 }
1132
1133 if ( !mLegendPatchShapes.contains( oldName ) )
1134 return false;
1135 QgsLegendPatchShape shape = mLegendPatchShapes.take( oldName );
1136
1137 mLegendPatchShapes.insert( newName, shape );
1138 mCachedTags[ LegendPatchShapeEntity ].remove( oldName );
1139 mCachedFavorites[ LegendPatchShapeEntity ].remove( oldName );
1140
1141 int labelSettingsId = 0;
1142 sqlite3_statement_unique_ptr statement;
1143 QString query = qgs_sqlite3_mprintf( "SELECT id FROM legendpatchshapes WHERE name='%q'", oldName.toUtf8().constData() );
1144 int nErr;
1145 statement = mCurrentDB.prepare( query, nErr );
1146 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1147 {
1148 labelSettingsId = sqlite3_column_int( statement.get(), 0 );
1149 }
1150 const bool result = rename( LegendPatchShapeEntity, labelSettingsId, newName );
1151 if ( result )
1152 {
1153 emit entityRenamed( LegendPatchShapeEntity, oldName, newName );
1154 }
1155
1156 return result;
1157 }
1158
1160 {
1161 if ( type == QgsSymbol::Hybrid )
1162 return QgsLegendPatchShape();
1163
1164 if ( mDefaultPatchCache[ type ].contains( size ) )
1165 return mDefaultPatchCache[ type ].value( size );
1166
1167 QgsGeometry geom;
1168 switch ( type )
1169 {
1170 case QgsSymbol::Marker:
1171 geom = QgsGeometry( qgis::make_unique< QgsPoint >( static_cast< int >( size.width() ) / 2, static_cast< int >( size.height() ) / 2 ) );
1172 break;
1173
1174 case QgsSymbol::Line:
1175 {
1176 // we're adding 0.5 to get rid of blurred preview:
1177 // drawing antialiased lines of width 1 at (x,0)-(x,100) creates 2px line
1178 double y = static_cast< int >( size.height() ) / 2 + 0.5;
1179 geom = QgsGeometry( qgis::make_unique< QgsLineString >( ( QVector< double >() << 0 << size.width() ),
1180 ( QVector< double >() << y << y ) ) );
1181 break;
1182 }
1183
1184 case QgsSymbol::Fill:
1185 {
1186 geom = QgsGeometry( qgis::make_unique< QgsPolygon >(
1187 new QgsLineString( QVector< double >() << 0 << static_cast< int >( size.width() ) << static_cast< int >( size.width() ) << 0 << 0,
1188 QVector< double >() << static_cast< int >( size.height() ) << static_cast< int >( size.height() ) << 0 << 0 << static_cast< int >( size.height() ) ) ) );
1189 break;
1190 }
1191
1192 case QgsSymbol::Hybrid:
1193 break;
1194 }
1195
1196 QgsLegendPatchShape res = QgsLegendPatchShape( type, geom, false );
1197 mDefaultPatchCache[ type ][size ] = res;
1198 return res;
1199 }
1200
1201 QList<QList<QPolygonF> > QgsStyle::defaultPatchAsQPolygonF( QgsSymbol::SymbolType type, QSizeF size ) const
1202 {
1203 if ( type == QgsSymbol::Hybrid )
1204 return QList<QList<QPolygonF> >();
1205
1206 if ( mDefaultPatchQPolygonFCache[ type ].contains( size ) )
1207 return mDefaultPatchQPolygonFCache[ type ].value( size );
1208
1209 QList<QList<QPolygonF> > res = defaultPatch( type, size ).toQPolygonF( type, size );
1210 mDefaultPatchQPolygonFCache[ type ][size ] = res;
1211 return res;
1212 }
1213
1214 bool QgsStyle::saveSymbol3D( const QString &name, QgsAbstract3DSymbol *symbol, bool favorite, const QStringList &tags )
1215 {
1216 // insert it into the database
1217 QDomDocument doc( QStringLiteral( "dummy" ) );
1218 QDomElement elem = doc.createElement( QStringLiteral( "symbol" ) );
1219 elem.setAttribute( QStringLiteral( "type" ), symbol->type() );
1220 symbol->writeXml( elem, QgsReadWriteContext() );
1221
1222 QByteArray xmlArray;
1223 QTextStream stream( &xmlArray );
1224 stream.setCodec( "UTF-8" );
1225 elem.save( stream, 4 );
1226 QString query = qgs_sqlite3_mprintf( "INSERT INTO symbol3d VALUES (NULL, '%q', '%q', %d);",
1227 name.toUtf8().constData(), xmlArray.constData(), ( favorite ? 1 : 0 ) );
1228 if ( !runEmptyQuery( query ) )
1229 {
1230 QgsDebugMsg( QStringLiteral( "Couldn't insert 3d symbol into the database!" ) );
1231 return false;
1232 }
1233
1234 mCachedFavorites[ Symbol3DEntity ].insert( name, favorite );
1235
1236 tagSymbol( Symbol3DEntity, name, tags );
1237
1238 emit entityAdded( Symbol3DEntity, name );
1239
1240 return true;
1241 }
1242
1243 bool QgsStyle::renameSymbol3D( const QString &oldName, const QString &newName )
1244 {
1245 if ( m3dSymbols.contains( newName ) )
1246 {
1247 QgsDebugMsg( QStringLiteral( "3d symbol of new name already exists." ) );
1248 return false;
1249 }
1250
1251 if ( !m3dSymbols.contains( oldName ) )
1252 return false;
1253 QgsAbstract3DSymbol *symbol = m3dSymbols.take( oldName );
1254
1255 m3dSymbols.insert( newName, symbol );
1256 mCachedTags[Symbol3DEntity ].remove( oldName );
1257 mCachedFavorites[ Symbol3DEntity ].remove( oldName );
1258
1259 int labelSettingsId = 0;
1260 sqlite3_statement_unique_ptr statement;
1261 QString query = qgs_sqlite3_mprintf( "SELECT id FROM symbol3d WHERE name='%q'", oldName.toUtf8().constData() );
1262 int nErr;
1263 statement = mCurrentDB.prepare( query, nErr );
1264 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1265 {
1266 labelSettingsId = sqlite3_column_int( statement.get(), 0 );
1267 }
1268 const bool result = rename( Symbol3DEntity, labelSettingsId, newName );
1269 if ( result )
1270 {
1271 emit entityRenamed( Symbol3DEntity, oldName, newName );
1272 }
1273
1274 return result;
1275 }
1276
1277 QStringList QgsStyle::symbol3DNames() const
1278 {
1279 return m3dSymbols.keys();
1280 }
1281
1282 QStringList QgsStyle::symbolsOfFavorite( StyleEntity type ) const
1283 {
1284 if ( !mCurrentDB )
1285 {
1286 QgsDebugMsg( QStringLiteral( "Cannot Open database for getting favorite symbols" ) );
1287 return QStringList();
1288 }
1289
1290 QString query;
1291 switch ( type )
1292 {
1293 case TagEntity:
1294 case SmartgroupEntity:
1295 QgsDebugMsg( QStringLiteral( "No such style entity" ) );
1296 return QStringList();
1297
1298 default:
1299 query = qgs_sqlite3_mprintf( QStringLiteral( "SELECT name FROM %1 WHERE favorite=1" ).arg( entityTableName( type ) ).toLocal8Bit().data() );
1300 break;
1301 }
1302
1303 int nErr;
1304 sqlite3_statement_unique_ptr statement;
1305 statement = mCurrentDB.prepare( query, nErr );
1306
1307 QStringList symbols;
1308 while ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1309 {
1310 symbols << statement.columnAsText( 0 );
1311 }
1312
1313 return symbols;
1314 }
1315
1316 QStringList QgsStyle::symbolsWithTag( StyleEntity type, int tagid ) const
1317 {
1318 if ( !mCurrentDB )
1319 {
1320 QgsDebugMsg( QStringLiteral( "Cannot open database to get symbols of tagid %1" ).arg( tagid ) );
1321 return QStringList();
1322 }
1323
1324 QString subquery;
1325 switch ( type )
1326 {
1327 case TagEntity:
1328 case SmartgroupEntity:
1329 QgsDebugMsg( QStringLiteral( "Unknown Entity" ) );
1330 return QStringList();
1331
1332 default:
1333 subquery = qgs_sqlite3_mprintf( QStringLiteral( "SELECT %1 FROM %2 WHERE tag_id=%d" ).arg( tagmapEntityIdFieldName( type ),
1334 tagmapTableName( type ) ).toLocal8Bit().data(), tagid );
1335 break;
1336 }
1337
1338 int nErr;
1339 sqlite3_statement_unique_ptr statement;
1340 statement = mCurrentDB.prepare( subquery, nErr );
1341
1342 // get the symbol <-> tag connection from the tag map table
1343 QStringList symbols;
1344 while ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1345 {
1346 int id = sqlite3_column_int( statement.get(), 0 );
1347
1348 const QString query = qgs_sqlite3_mprintf( QStringLiteral( "SELECT name FROM %1 WHERE id=%d" ).arg( entityTableName( type ) ).toLocal8Bit().data(), id );
1349
1350 int rc;
1351 sqlite3_statement_unique_ptr statement2;
1352 statement2 = mCurrentDB.prepare( query, rc );
1353 while ( rc == SQLITE_OK && sqlite3_step( statement2.get() ) == SQLITE_ROW )
1354 {
1355 symbols << statement2.columnAsText( 0 );
1356 }
1357 }
1358
1359 return symbols;
1360 }
1361
1362 int QgsStyle::addTag( const QString &tagname )
1363 {
1364 if ( !mCurrentDB )
1365 return 0;
1366 sqlite3_statement_unique_ptr statement;
1367
1368 QString query = qgs_sqlite3_mprintf( "INSERT INTO tag VALUES (NULL, '%q')", tagname.toUtf8().constData() );
1369 int nErr;
1370 statement = mCurrentDB.prepare( query, nErr );
1371 if ( nErr == SQLITE_OK )
1372 ( void )sqlite3_step( statement.get() );
1373
1374 QgsSettings settings;
1375 settings.setValue( QStringLiteral( "qgis/symbolsListGroupsIndex" ), 0 );
1376
1377 emit groupsModified();
1378
1379 return static_cast< int >( sqlite3_last_insert_rowid( mCurrentDB.get() ) );
1380 }
1381
1382 QStringList QgsStyle::tags() const
1383 {
1384 if ( !mCurrentDB )
1385 return QStringList();
1386
1387 sqlite3_statement_unique_ptr statement;
1388
1389 QString query = qgs_sqlite3_mprintf( "SELECT name FROM tag" );
1390 int nError;
1391 statement = mCurrentDB.prepare( query, nError );
1392
1393 QStringList tagList;
1394 while ( nError == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1395 {
1396 tagList << statement.columnAsText( 0 );
1397 }
1398
1399 return tagList;
1400 }
1401
1402 bool QgsStyle::rename( StyleEntity type, int id, const QString &newName )
1403 {
1404 const QString query = qgs_sqlite3_mprintf( QStringLiteral( "UPDATE %1 SET name='%q' WHERE id=%d" ).arg( entityTableName( type ) ).toLocal8Bit().data(), newName.toUtf8().constData(), id );
1405
1406 const bool result = runEmptyQuery( query );
1407 if ( !result )
1408 {
1409 mErrorString = QStringLiteral( "Could not rename!" );
1410 }
1411 else
1412 {
1413 mCachedTags.clear();
1414 mCachedFavorites.clear();
1415
1416 switch ( type )
1417 {
1418 case TagEntity:
1419 {
1420 emit groupsModified();
1421 break;
1422 }
1423
1424 case SmartgroupEntity:
1425 {
1426 emit groupsModified();
1427 break;
1428 }
1429
1430 default:
1431 break;
1432 }
1433 }
1434 return result;
1435 }
1436
1437 bool QgsStyle::remove( StyleEntity type, int id )
1438 {
1439 bool groupRemoved = false;
1440 QString query;
1441 switch ( type )
1442 {
1443 case TagEntity:
1444 query = qgs_sqlite3_mprintf( "DELETE FROM tag WHERE id=%d; DELETE FROM tagmap WHERE tag_id=%d", id, id );
1445 groupRemoved = true;
1446 break;
1447 case SmartgroupEntity:
1448 query = qgs_sqlite3_mprintf( "DELETE FROM smartgroup WHERE id=%d", id );
1449 groupRemoved = true;
1450 break;
1451
1452 default:
1453 query = qgs_sqlite3_mprintf( QStringLiteral( "DELETE FROM %1 WHERE id=%d; DELETE FROM %2 WHERE %3=%d" ).arg(
1454 entityTableName( type ),
1455 tagmapTableName( type ),
1456 tagmapEntityIdFieldName( type )
1457 ).toLocal8Bit().data(), id, id );
1458 break;
1459 }
1460
1461 bool result = false;
1462 if ( !runEmptyQuery( query ) )
1463 {
1464 QgsDebugMsg( QStringLiteral( "Could not delete entity!" ) );
1465 }
1466 else
1467 {
1468 mCachedTags.clear();
1469 mCachedFavorites.clear();
1470
1471 if ( groupRemoved )
1472 {
1473 QgsSettings settings;
1474 settings.setValue( QStringLiteral( "qgis/symbolsListGroupsIndex" ), 0 );
1475
1476 emit groupsModified();
1477 }
1478 result = true;
1479 }
1480 return result;
1481 }
1482
1483 bool QgsStyle::removeEntityByName( QgsStyle::StyleEntity type, const QString &name )
1484 {
1485 switch ( type )
1486 {
1487 case QgsStyle::TagEntity:
1489 return false;
1490
1492 {
1493 std::unique_ptr< QgsSymbol > symbol( mSymbols.take( name ) );
1494 if ( !symbol )
1495 return false;
1496
1497 break;
1498 }
1499
1501 {
1502 std::unique_ptr< QgsAbstract3DSymbol > symbol( m3dSymbols.take( name ) );
1503 if ( !symbol )
1504 return false;
1505
1506 break;
1507 }
1508
1510 {
1511 std::unique_ptr< QgsColorRamp > ramp( mColorRamps.take( name ) );
1512 if ( !ramp )
1513 return false;
1514 break;
1515 }
1516
1518 {
1519 if ( !mTextFormats.contains( name ) )
1520 return false;
1521
1522 mTextFormats.remove( name );
1523 break;
1524 }
1525
1527 {
1528 if ( !mLabelSettings.contains( name ) )
1529 return false;
1530
1531 mLabelSettings.remove( name );
1532 break;
1533 }
1534
1536 {
1537 if ( !mLegendPatchShapes.contains( name ) )
1538 return false;
1539
1540 mLegendPatchShapes.remove( name );
1541 break;
1542 }
1543 }
1544
1545 if ( !mCurrentDB )
1546 {
1547 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database to modify." ) );
1548 return false;
1549 }
1550
1551 const int id = entityId( type, name );
1552 if ( !id )
1553 {
1554 QgsDebugMsg( "No matching entity for deleting in database: " + name );
1555 }
1556
1557 const bool result = remove( type, id );
1558 if ( result )
1559 {
1560 mCachedTags[ type ].remove( name );
1561 mCachedFavorites[ type ].remove( name );
1562
1563 switch ( type )
1564 {
1565 case SymbolEntity:
1566 emit symbolRemoved( name );
1567 break;
1568
1569 case ColorrampEntity:
1570 emit rampRemoved( name );
1571 break;
1572
1573 case TextFormatEntity:
1574 emit textFormatRemoved( name );
1575 break;
1576
1577 case LabelSettingsEntity:
1578 emit labelSettingsRemoved( name );
1579 break;
1580
1581 default:
1582 // these specific signals should be discouraged -- don't add them for new entity types!
1583 break;
1584 }
1585 emit entityRemoved( type, name );
1586 }
1587 return result;
1588 }
1589
1590 bool QgsStyle::runEmptyQuery( const QString &query )
1591 {
1592 if ( !mCurrentDB )
1593 return false;
1594
1595 char *zErr = nullptr;
1596 int nErr = sqlite3_exec( mCurrentDB.get(), query.toUtf8().constData(), nullptr, nullptr, &zErr );
1597
1598 if ( nErr != SQLITE_OK )
1599 {
1600 QgsDebugMsg( zErr );
1601 sqlite3_free( zErr );
1602 }
1603
1604 return nErr == SQLITE_OK;
1605 }
1606
1607 bool QgsStyle::addFavorite( StyleEntity type, const QString &name )
1608 {
1609 QString query;
1610
1611 switch ( type )
1612 {
1613 case TagEntity:
1614 case SmartgroupEntity:
1615 QgsDebugMsg( QStringLiteral( "Wrong entity value. cannot apply group" ) );
1616 return false;
1617
1618 default:
1619 query = qgs_sqlite3_mprintf( QStringLiteral( "UPDATE %1 SET favorite=1 WHERE name='%q'" ).arg( entityTableName( type ) ).toLocal8Bit().data(),
1620 name.toUtf8().constData() );
1621 break;
1622 }
1623
1624 const bool res = runEmptyQuery( query );
1625 if ( res )
1626 {
1627 switch ( type )
1628 {
1629 case TagEntity:
1630 case SmartgroupEntity:
1631 break;
1632
1633 default:
1634 mCachedFavorites[ type ].insert( name, true );
1635 break;
1636 }
1637 emit favoritedChanged( type, name, true );
1638 }
1639
1640 return res;
1641 }
1642
1643 bool QgsStyle::removeFavorite( StyleEntity type, const QString &name )
1644 {
1645 QString query;
1646
1647 switch ( type )
1648 {
1649 case TagEntity:
1650 case SmartgroupEntity:
1651 QgsDebugMsg( QStringLiteral( "Wrong entity value. cannot apply group" ) );
1652 return false;
1653
1654 default:
1655 query = qgs_sqlite3_mprintf( QStringLiteral( "UPDATE %1 SET favorite=0 WHERE name='%q'" ).arg( entityTableName( type ) ).toLocal8Bit().data(), name.toUtf8().constData() );
1656 break;
1657 }
1658
1659 const bool res = runEmptyQuery( query );
1660 if ( res )
1661 {
1662 mCachedFavorites[ type ].insert( name, false );
1663 emit favoritedChanged( type, name, false );
1664 }
1665
1666 return res;
1667 }
1668
1669 QStringList QgsStyle::findSymbols( StyleEntity type, const QString &qword )
1670 {
1671 if ( !mCurrentDB )
1672 {
1673 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database to search" ) );
1674 return QStringList();
1675 }
1676
1677 // first find symbols with matching name
1678 QString item;
1679 switch ( type )
1680 {
1681 case TagEntity:
1682 case SmartgroupEntity:
1683 return QStringList();
1684
1685 default:
1686 item = entityTableName( type );
1687 break;
1688 }
1689
1690 QString query = qgs_sqlite3_mprintf( "SELECT name FROM %q WHERE name LIKE '%%%q%%'",
1691 item.toUtf8().constData(), qword.toUtf8().constData() );
1692
1693 sqlite3_statement_unique_ptr statement;
1694 int nErr; statement = mCurrentDB.prepare( query, nErr );
1695
1696 QSet< QString > symbols;
1697 while ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1698 {
1699 symbols << statement.columnAsText( 0 );
1700 }
1701
1702 // next add symbols with matching tags
1703 query = qgs_sqlite3_mprintf( "SELECT id FROM tag WHERE name LIKE '%%%q%%'", qword.toUtf8().constData() );
1704 statement = mCurrentDB.prepare( query, nErr );
1705
1706 QStringList tagids;
1707 while ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1708 {
1709 tagids << statement.columnAsText( 0 );
1710 }
1711
1712 QString dummy = tagids.join( QLatin1String( ", " ) );
1713 query = qgs_sqlite3_mprintf( QStringLiteral( "SELECT %1 FROM %2 WHERE tag_id IN (%q)" ).arg( tagmapEntityIdFieldName( type ),
1714 tagmapTableName( type ) ).toLocal8Bit().data(), dummy.toUtf8().constData() );
1715
1716 statement = mCurrentDB.prepare( query, nErr );
1717
1718 QStringList symbolids;
1719 while ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1720 {
1721 symbolids << statement.columnAsText( 0 );
1722 }
1723
1724 dummy = symbolids.join( QLatin1String( ", " ) );
1725 query = qgs_sqlite3_mprintf( "SELECT name FROM %q WHERE id IN (%q)",
1726 item.toUtf8().constData(), dummy.toUtf8().constData() );
1727 statement = mCurrentDB.prepare( query, nErr );
1728 while ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1729 {
1730 symbols << statement.columnAsText( 0 );
1731 }
1732
1733 return qgis::setToList( symbols );
1734 }
1735
1736 bool QgsStyle::tagSymbol( StyleEntity type, const QString &symbol, const QStringList &tags )
1737 {
1738 if ( !mCurrentDB )
1739 {
1740 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database to tag." ) );
1741 return false;
1742 }
1743
1744 int symbolid = 0;
1745 switch ( type )
1746 {
1747 case TagEntity:
1748 case SmartgroupEntity:
1749 return false;
1750
1751 default:
1752 symbolid = entityId( type, symbol );
1753 break;
1754 }
1755
1756 if ( !symbolid )
1757 {
1758 QgsDebugMsg( QStringLiteral( "No such symbol for tagging in database: " ) + symbol );
1759 return false;
1760 }
1761
1762 QString tag;
1763 const auto constTags = tags;
1764 for ( const QString &t : constTags )
1765 {
1766 tag = t.trimmed();
1767 if ( !tag.isEmpty() )
1768 {
1769 // sql: gets the id of the tag if present or insert the tag and get the id of the tag
1770 int tagid( tagId( tag ) );
1771 if ( ! tagid )
1772 {
1773 tagid = addTag( tag );
1774 }
1775
1776 // Now map the tag to the symbol if it's not already tagged
1777 if ( !symbolHasTag( type, symbol, tag ) )
1778 {
1779 QString query = qgs_sqlite3_mprintf( QStringLiteral( "INSERT INTO %1 VALUES (%d,%d)" ).arg( tagmapTableName( type ) ).toLocal8Bit().data(), tagid, symbolid );
1780
1781 char *zErr = nullptr;
1782 int nErr;
1783 nErr = sqlite3_exec( mCurrentDB.get(), query.toUtf8().constData(), nullptr, nullptr, &zErr );
1784 if ( nErr )
1785 {
1786 QgsDebugMsg( zErr );
1787 sqlite3_free( zErr );
1788 }
1789 }
1790 }
1791 }
1792
1793 clearCachedTags( type, symbol );
1794 emit entityTagsChanged( type, symbol, tagsOfSymbol( type, symbol ) );
1795
1796 return true;
1797 }
1798
1799 bool QgsStyle::detagSymbol( StyleEntity type, const QString &symbol, const QStringList &tags )
1800 {
1801 if ( !mCurrentDB )
1802 {
1803 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database for detagging." ) );
1804 return false;
1805 }
1806
1807 switch ( type )
1808 {
1809 case TagEntity:
1810 case SmartgroupEntity:
1811 return false;
1812
1813 default:
1814 break;
1815 }
1816
1817 const int symbolid = entityId( type, symbol );
1818 if ( symbolid == 0 )
1819 return false;
1820
1821 int nErr;
1822 QString query;
1823 const auto constTags = tags;
1824 for ( const QString &tag : constTags )
1825 {
1826 query = qgs_sqlite3_mprintf( "SELECT id FROM tag WHERE name='%q'", tag.toUtf8().constData() );
1827
1828 sqlite3_statement_unique_ptr statement2;
1829 statement2 = mCurrentDB.prepare( query, nErr );
1830
1831 int tagid = 0;
1832 if ( nErr == SQLITE_OK && sqlite3_step( statement2.get() ) == SQLITE_ROW )
1833 {
1834 tagid = sqlite3_column_int( statement2.get(), 0 );
1835 }
1836
1837 if ( tagid )
1838 {
1839 // remove from the tagmap
1840 const QString query = qgs_sqlite3_mprintf( QStringLiteral( "DELETE FROM %1 WHERE tag_id=%d AND %2=%d" ).arg( tagmapTableName( type ), tagmapEntityIdFieldName( type ) ).toLocal8Bit().data(), tagid, symbolid );
1841 runEmptyQuery( query );
1842 }
1843 }
1844
1845 clearCachedTags( type, symbol );
1846 emit entityTagsChanged( type, symbol, tagsOfSymbol( type, symbol ) );
1847
1848 // TODO Perform tag cleanup
1849 // check the number of entries for a given tag in the tagmap
1850 // if the count is 0, then remove( TagEntity, tagid )
1851 return true;
1852 }
1853
1854 bool QgsStyle::detagSymbol( StyleEntity type, const QString &symbol )
1855 {
1856 if ( !mCurrentDB )
1857 {
1858 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database for detagging." ) );
1859 return false;
1860 }
1861
1862 switch ( type )
1863 {
1864 case TagEntity:
1865 case SmartgroupEntity:
1866 return false;
1867
1868 default:
1869 break;
1870 }
1871
1872 const int symbolid = entityId( type, symbol );
1873 if ( symbolid == 0 )
1874 {
1875 return false;
1876 }
1877
1878 // remove all tags
1879 const QString query = qgs_sqlite3_mprintf( QStringLiteral( "DELETE FROM %1 WHERE %2=%d" ).arg( tagmapTableName( type ),
1880 tagmapEntityIdFieldName( type ) ).toLocal8Bit().data(), symbolid );
1881 runEmptyQuery( query );
1882
1883 clearCachedTags( type, symbol );
1884 emit entityTagsChanged( type, symbol, QStringList() );
1885
1886 // TODO Perform tag cleanup
1887 // check the number of entries for a given tag in the tagmap
1888 // if the count is 0, then remove( TagEntity, tagid )
1889 return true;
1890 }
1891
1892 QStringList QgsStyle::tagsOfSymbol( StyleEntity type, const QString &symbol )
1893 {
1894 switch ( type )
1895 {
1896 case TagEntity:
1897 case SmartgroupEntity:
1898 return QStringList();
1899
1900 default:
1901 if ( mCachedTags[ type ].contains( symbol ) )
1902 return mCachedTags[ type ].value( symbol );
1903 break;
1904 }
1905
1906 if ( !mCurrentDB )
1907 {
1908 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database for getting the tags." ) );
1909 return QStringList();
1910 }
1911
1912 int symbolid = entityId( type, symbol );
1913 if ( !symbolid )
1914 return QStringList();
1915
1916 // get the ids of tags for the symbol
1917 const QString query = qgs_sqlite3_mprintf( QStringLiteral( "SELECT tag_id FROM %1 WHERE %2=%d" ).arg( tagmapTableName( type ),
1918 tagmapEntityIdFieldName( type ) ).toLocal8Bit().data(), symbolid );
1919
1920 sqlite3_statement_unique_ptr statement;
1921 int nErr; statement = mCurrentDB.prepare( query, nErr );
1922
1923 QStringList tagList;
1924 while ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
1925 {
1926 QString subquery = qgs_sqlite3_mprintf( "SELECT name FROM tag WHERE id=%d", sqlite3_column_int( statement.get(), 0 ) );
1927
1928 sqlite3_statement_unique_ptr statement2;
1929 int pErr;
1930 statement2 = mCurrentDB.prepare( subquery, pErr );
1931 if ( pErr == SQLITE_OK && sqlite3_step( statement2.get() ) == SQLITE_ROW )
1932 {
1933 tagList << statement2.columnAsText( 0 );
1934 }
1935 }
1936
1937 // update cache
1938 mCachedTags[ type ].insert( symbol, tagList );
1939
1940 return tagList;
1941 }
1942
1943 bool QgsStyle::isFavorite( QgsStyle::StyleEntity type, const QString &name )
1944 {
1945 if ( !mCurrentDB )
1946 {
1947 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database for getting the tags." ) );
1948 return false;
1949 }
1950
1951 switch ( type )
1952 {
1953 case TagEntity:
1954 case SmartgroupEntity:
1955 return false;
1956
1957 default:
1958 if ( mCachedFavorites[ type ].contains( name ) )
1959 return mCachedFavorites[ type ].value( name );
1960 break;
1961 }
1962
1963 const QStringList names = allNames( type );
1964 if ( !names.contains( name ) )
1965 return false; // entity doesn't exist
1966
1967 // for efficiency, retrieve names of all favorited symbols and store them in cache
1968 const QStringList favorites = symbolsOfFavorite( type );
1969 bool res = false;
1970 for ( const QString &n : names )
1971 {
1972 const bool isFav = favorites.contains( n );
1973 if ( n == name )
1974 res = isFav;
1975
1976 mCachedFavorites[ type ].insert( n, isFav );
1977 }
1978 return res;
1979 }
1980
1981 bool QgsStyle::symbolHasTag( StyleEntity type, const QString &symbol, const QString &tag )
1982 {
1983 if ( !mCurrentDB )
1984 {
1985 QgsDebugMsg( QStringLiteral( "Sorry! Cannot open database for getting the tags." ) );
1986 return false;
1987 }
1988
1989 int symbolid = 0;
1990 switch ( type )
1991 {
1992 case TagEntity:
1993 case SmartgroupEntity:
1994 return false;
1995
1996 default:
1997 symbolid = entityId( type, symbol );
1998 break;
1999 }
2000
2001 if ( !symbolid )
2002 {
2003 return false;
2004 }
2005 int tagid = tagId( tag );
2006 if ( !tagid )
2007 {
2008 return false;
2009 }
2010
2011 // get the ids of tags for the symbol
2012 const QString query = qgs_sqlite3_mprintf( QStringLiteral( "SELECT tag_id FROM %1 WHERE tag_id=%d AND %2=%d" ).arg( tagmapTableName( type ),
2013 tagmapEntityIdFieldName( type ) ).toLocal8Bit().data(), tagid, symbolid );
2014
2015 sqlite3_statement_unique_ptr statement;
2016 int nErr; statement = mCurrentDB.prepare( query, nErr );
2017
2018 return ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW );
2019 }
2020
2021 QString QgsStyle::tag( int id ) const
2022 {
2023 if ( !mCurrentDB )
2024 return QString();
2025
2026 sqlite3_statement_unique_ptr statement;
2027
2028 QString query = qgs_sqlite3_mprintf( "SELECT name FROM tag WHERE id=%d", id );
2029 int nError;
2030 statement = mCurrentDB.prepare( query, nError );
2031
2032 QString tag;
2033 if ( nError == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2034 {
2035 tag = statement.columnAsText( 0 );
2036 }
2037
2038 return tag;
2039 }
2040
2041 int QgsStyle::getId( const QString &table, const QString &name )
2042 {
2043 QString lowerName( name.toLower() );
2044 QString query = qgs_sqlite3_mprintf( "SELECT id FROM %q WHERE LOWER(name)='%q'", table.toUtf8().constData(), lowerName.toUtf8().constData() );
2045
2046 sqlite3_statement_unique_ptr statement;
2047 int nErr; statement = mCurrentDB.prepare( query, nErr );
2048
2049 int id = 0;
2050 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2051 {
2052 id = sqlite3_column_int( statement.get(), 0 );
2053 }
2054 else
2055 {
2056 // Try the name without lowercase conversion
2057 QString query = qgs_sqlite3_mprintf( "SELECT id FROM %q WHERE name='%q'", table.toUtf8().constData(), name.toUtf8().constData() );
2058
2059 sqlite3_statement_unique_ptr statement;
2060 int nErr; statement = mCurrentDB.prepare( query, nErr );
2061 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2062 {
2063 id = sqlite3_column_int( statement.get(), 0 );
2064 }
2065 }
2066
2067 return id;
2068 }
2069
2070 QString QgsStyle::getName( const QString &table, int id ) const
2071 {
2072 QString query = qgs_sqlite3_mprintf( "SELECT name FROM %q WHERE id='%q'", table.toUtf8().constData(), QString::number( id ).toUtf8().constData() );
2073
2074 sqlite3_statement_unique_ptr statement;
2075 int nErr; statement = mCurrentDB.prepare( query, nErr );
2076
2077 QString name;
2078 if ( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2079 {
2080 name = statement.columnAsText( 0 );
2081 }
2082
2083 return name;
2084 }
2085
2086 int QgsStyle::symbolId( const QString &name )
2087 {
2088 return getId( QStringLiteral( "symbol" ), name );
2089 }
2090
2091 int QgsStyle::entityId( QgsStyle::StyleEntity type, const QString &name )
2092 {
2093 return getId( entityTableName( type ), name );
2094 }
2095
2096 int QgsStyle::colorrampId( const QString &name )
2097 {
2098 return getId( QStringLiteral( "colorramp" ), name );
2099 }
2100
2101 QgsTextFormat QgsStyle::textFormat( const QString &name ) const
2102 {
2103 return mTextFormats.value( name );
2104 }
2105
2107 {
2108 return mTextFormats.count();
2109 }
2110
2111 QStringList QgsStyle::textFormatNames() const
2112 {
2113 return mTextFormats.keys();
2114 }
2115
2116 int QgsStyle::textFormatId( const QString &name )
2117 {
2118 return getId( QStringLiteral( "textformat" ), name );
2119 }
2120
2121 QgsPalLayerSettings QgsStyle::labelSettings( const QString &name ) const
2122 {
2123 return mLabelSettings.value( name );
2124 }
2125
2127 {
2128 return mLegendPatchShapes.value( name );
2129 }
2130
2132 {
2133 return mLegendPatchShapes.count();
2134 }
2135
2137 {
2138 if ( !mLegendPatchShapes.contains( name ) )
2139 return QgsSymbol::Hybrid;
2140
2141 return mLegendPatchShapes.value( name ).symbolType();
2142 }
2143
2144 QgsAbstract3DSymbol *QgsStyle::symbol3D( const QString &name ) const
2145 {
2146 return m3dSymbols.contains( name ) ? m3dSymbols.value( name )->clone() : nullptr;
2147 }
2148
2150 {
2151 return m3dSymbols.count();
2152 }
2153
2154 QList<QgsWkbTypes::GeometryType> QgsStyle::symbol3DCompatibleGeometryTypes( const QString &name ) const
2155 {
2156 if ( !m3dSymbols.contains( name ) )
2157 return QList<QgsWkbTypes::GeometryType>();
2158
2159 return m3dSymbols.value( name )->compatibleGeometryTypes();
2160 }
2161
2163 {
2164 if ( !mLabelSettings.contains( name ) )
2166
2167 return mLabelSettings.value( name ).layerType;
2168 }
2169
2171 {
2172 return mLabelSettings.count();
2173 }
2174
2175 QStringList QgsStyle::labelSettingsNames() const
2176 {
2177 return mLabelSettings.keys();
2178 }
2179
2180 int QgsStyle::labelSettingsId( const QString &name )
2181 {
2182 return getId( QStringLiteral( "labelsettings" ), name );
2183 }
2184
2186 {
2187 return mLegendPatchShapes.keys();
2188 }
2189
2191 {
2192 switch ( shape.symbolType() )
2193 {
2194 case QgsSymbol::Marker:
2195 return mPatchMarkerSymbol.get();
2196
2197 case QgsSymbol::Line:
2198 return mPatchLineSymbol.get();
2199
2200 case QgsSymbol::Fill:
2201 return mPatchFillSymbol.get();
2202
2203 case QgsSymbol::Hybrid:
2204 break;
2205 }
2206 return nullptr;
2207 }
2208
2209 int QgsStyle::tagId( const QString &name )
2210 {
2211 return getId( QStringLiteral( "tag" ), name );
2212 }
2213
2214 int QgsStyle::smartgroupId( const QString &name )
2215 {
2216 return getId( QStringLiteral( "smartgroup" ), name );
2217 }
2218
2220 {
2221 switch ( type )
2222 {
2223 case SymbolEntity:
2224 return symbolNames();
2225
2226 case ColorrampEntity:
2227 return colorRampNames();
2228
2229 case TextFormatEntity:
2230 return textFormatNames();
2231
2232 case LabelSettingsEntity:
2233 return labelSettingsNames();
2234
2236 return legendPatchShapeNames();
2237
2238 case Symbol3DEntity:
2239 return symbol3DNames();
2240
2241 case TagEntity:
2242 return tags();
2243
2244 case SmartgroupEntity:
2245 return smartgroupNames();
2246 }
2247 return QStringList();
2248 }
2249
2250 int QgsStyle::addSmartgroup( const QString &name, const QString &op, const QgsSmartConditionMap &conditions )
2251 {
2252 return addSmartgroup( name, op, conditions.values( QStringLiteral( "tag" ) ),
2253 conditions.values( QStringLiteral( "!tag" ) ),
2254 conditions.values( QStringLiteral( "name" ) ),
2255 conditions.values( QStringLiteral( "!name" ) ) );
2256 }
2257
2258 int QgsStyle::addSmartgroup( const QString &name, const QString &op, const QStringList &matchTag, const QStringList &noMatchTag, const QStringList &matchName, const QStringList &noMatchName )
2259 {
2260 QDomDocument doc( QStringLiteral( "dummy" ) );
2261 QDomElement smartEl = doc.createElement( QStringLiteral( "smartgroup" ) );
2262 smartEl.setAttribute( QStringLiteral( "name" ), name );
2263 smartEl.setAttribute( QStringLiteral( "operator" ), op );
2264
2265 auto addCondition = [&doc, &smartEl]( const QString & constraint, const QStringList & parameters )
2266 {
2267 for ( const QString ¶m : parameters )
2268 {
2269 QDomElement condEl = doc.createElement( QStringLiteral( "condition" ) );
2270 condEl.setAttribute( QStringLiteral( "constraint" ), constraint );
2271 condEl.setAttribute( QStringLiteral( "param" ), param );
2272 smartEl.appendChild( condEl );
2273 }
2274 };
2275 addCondition( QStringLiteral( "tag" ), matchTag );
2276 addCondition( QStringLiteral( "!tag" ), noMatchTag );
2277 addCondition( QStringLiteral( "name" ), matchName );
2278 addCondition( QStringLiteral( "!name" ), noMatchName );
2279
2280 QByteArray xmlArray;
2281 QTextStream stream( &xmlArray );
2282 stream.setCodec( "UTF-8" );
2283 smartEl.save( stream, 4 );
2284 QString query = qgs_sqlite3_mprintf( "INSERT INTO smartgroup VALUES (NULL, '%q', '%q')",
2285 name.toUtf8().constData(), xmlArray.constData() );
2286
2287 if ( runEmptyQuery( query ) )
2288 {
2289 QgsSettings settings;
2290 settings.setValue( QStringLiteral( "qgis/symbolsListGroupsIndex" ), 0 );
2291
2292 emit groupsModified();
2293 return static_cast< int >( sqlite3_last_insert_rowid( mCurrentDB.get() ) );
2294 }
2295 else
2296 {
2297 QgsDebugMsg( QStringLiteral( "Couldn't insert symbol into the database!" ) );
2298 return 0;
2299 }
2300 }
2301
2303 {
2304 if ( !mCurrentDB )
2305 {
2306 QgsDebugMsg( QStringLiteral( "Cannot open database for listing groups" ) );
2307 return QgsSymbolGroupMap();
2308 }
2309
2310 QString query = qgs_sqlite3_mprintf( "SELECT * FROM smartgroup" );
2311
2312 // Now run the query and retrieve the group names
2313 sqlite3_statement_unique_ptr statement;
2314 int nError;
2315 statement = mCurrentDB.prepare( query, nError );
2316
2317 QgsSymbolGroupMap groupNames;
2318 while ( nError == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2319 {
2320 QString group = statement.columnAsText( SmartgroupName );
2321 groupNames.insert( sqlite3_column_int( statement.get(), SmartgroupId ), group );
2322 }
2323
2324 return groupNames;
2325 }
2326
2327 QStringList QgsStyle::smartgroupNames() const
2328 {
2329 if ( !mCurrentDB )
2330 {
2331 QgsDebugMsg( QStringLiteral( "Cannot open database for listing groups" ) );
2332 return QStringList();
2333 }
2334
2335 QString query = qgs_sqlite3_mprintf( "SELECT name FROM smartgroup" );
2336
2337 // Now run the query and retrieve the group names
2338 sqlite3_statement_unique_ptr statement;
2339 int nError;
2340 statement = mCurrentDB.prepare( query, nError );
2341
2342 QStringList groups;
2343 while ( nError == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2344 {
2345 groups << statement.columnAsText( 0 );
2346 }
2347
2348 return groups;
2349 }
2350
2351 QStringList QgsStyle::symbolsOfSmartgroup( StyleEntity type, int id )
2352 {
2353 QStringList symbols;
2354
2355 QString query = qgs_sqlite3_mprintf( "SELECT xml FROM smartgroup WHERE id=%d", id );
2356
2357 sqlite3_statement_unique_ptr statement;
2358 int nErr; statement = mCurrentDB.prepare( query, nErr );
2359 if ( !( nErr == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW ) )
2360 {
2361 return QStringList();
2362 }
2363 else
2364 {
2365 QDomDocument doc;
2366 QString xmlstr = statement.columnAsText( 0 );
2367 if ( !doc.setContent( xmlstr ) )
2368 {
2369 QgsDebugMsg( QStringLiteral( "Cannot open smartgroup id: %1" ).arg( id ) );
2370 }
2371 QDomElement smartEl = doc.documentElement();
2372 QString op = smartEl.attribute( QStringLiteral( "operator" ) );
2373 QDomNodeList conditionNodes = smartEl.childNodes();
2374
2375 bool firstSet = true;
2376 for ( int i = 0; i < conditionNodes.count(); i++ )
2377 {
2378 QDomElement condEl = conditionNodes.at( i ).toElement();
2379 QString constraint = condEl.attribute( QStringLiteral( "constraint" ) );
2380 QString param = condEl.attribute( QStringLiteral( "param" ) );
2381
2382 QStringList resultNames;
2383 // perform suitable action for the given constraint
2384 if ( constraint == QLatin1String( "tag" ) )
2385 {
2386 resultNames = symbolsWithTag( type, tagId( param ) );
2387 }
2388 else if ( constraint == QLatin1String( "name" ) )
2389 {
2390 resultNames = allNames( type ).filter( param, Qt::CaseInsensitive );
2391 }
2392 else if ( constraint == QLatin1String( "!tag" ) )
2393 {
2394 resultNames = allNames( type );
2395 const QStringList unwanted = symbolsWithTag( type, tagId( param ) );
2396 for ( const QString &name : unwanted )
2397 {
2398 resultNames.removeAll( name );
2399 }
2400 }
2401 else if ( constraint == QLatin1String( "!name" ) )
2402 {
2403 const QStringList all = allNames( type );
2404 for ( const QString &str : all )
2405 {
2406 if ( !str.contains( param, Qt::CaseInsensitive ) )
2407 resultNames << str;
2408 }
2409 }
2410
2411 // not apply the operator
2412 if ( firstSet )
2413 {
2414 symbols = resultNames;
2415 firstSet = false;
2416 }
2417 else
2418 {
2419 if ( op == QLatin1String( "OR" ) )
2420 {
2421 symbols << resultNames;
2422 }
2423 else if ( op == QLatin1String( "AND" ) )
2424 {
2425 QStringList dummy = symbols;
2426 symbols.clear();
2427 for ( const QString &result : qgis::as_const( resultNames ) )
2428 {
2429 if ( dummy.contains( result ) )
2430 symbols << result;
2431 }
2432 }
2433 }
2434 } // DOM loop ends here
2435 }
2436
2437 // return sorted, unique list
2438 QStringList unique = qgis::setToList( qgis::listToSet( symbols ) );
2439 std::sort( unique.begin(), unique.end() );
2440 return unique;
2441 }
2442
2444 {
2445 if ( !mCurrentDB )
2446 {
2447 QgsDebugMsg( QStringLiteral( "Cannot open database for listing groups" ) );
2448 return QgsSmartConditionMap();
2449 }
2450
2451 QgsSmartConditionMap condition;
2452
2453 QString query = qgs_sqlite3_mprintf( "SELECT xml FROM smartgroup WHERE id=%d", id );
2454
2455 sqlite3_statement_unique_ptr statement;
2456 int nError;
2457 statement = mCurrentDB.prepare( query, nError );
2458 if ( nError == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2459 {
2460 QDomDocument doc;
2461 QString xmlstr = statement.columnAsText( 0 );
2462 if ( !doc.setContent( xmlstr ) )
2463 {
2464 QgsDebugMsg( QStringLiteral( "Cannot open smartgroup id: %1" ).arg( id ) );
2465 }
2466
2467 QDomElement smartEl = doc.documentElement();
2468 QDomNodeList conditionNodes = smartEl.childNodes();
2469
2470 for ( int i = 0; i < conditionNodes.count(); i++ )
2471 {
2472 QDomElement condEl = conditionNodes.at( i ).toElement();
2473 QString constraint = condEl.attribute( QStringLiteral( "constraint" ) );
2474 QString param = condEl.attribute( QStringLiteral( "param" ) );
2475
2476 condition.insert( constraint, param );
2477 }
2478 }
2479
2480 return condition;
2481 }
2482
2484 {
2485 if ( !mCurrentDB )
2486 {
2487 QgsDebugMsg( QStringLiteral( "Cannot open database for listing groups" ) );
2488 return QString();
2489 }
2490
2491 QString op;
2492
2493 QString query = qgs_sqlite3_mprintf( "SELECT xml FROM smartgroup WHERE id=%d", id );
2494
2495 int nError;
2496 sqlite3_statement_unique_ptr statement;
2497 statement = mCurrentDB.prepare( query, nError );
2498 if ( nError == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
2499 {
2500 QDomDocument doc;
2501 QString xmlstr = statement.columnAsText( 0 );
2502 if ( !doc.setContent( xmlstr ) )
2503 {
2504 QgsDebugMsg( QStringLiteral( "Cannot open smartgroup id: %1" ).arg( id ) );
2505 }
2506 QDomElement smartEl = doc.documentElement();
2507 op = smartEl.attribute( QStringLiteral( "operator" ) );
2508 }
2509
2510 return op;
2511 }
2512
2513 bool QgsStyle::exportXml( const QString &filename )
2514 {
2515 if ( filename.isEmpty() )
2516 {
2517 QgsDebugMsg( QStringLiteral( "Invalid filename for style export." ) );
2518 return false;
2519 }
2520
2521 QDomDocument doc( QStringLiteral( "qgis_style" ) );
2522 QDomElement root = doc.createElement( QStringLiteral( "qgis_style" ) );
2523 root.setAttribute( QStringLiteral( "version" ), QStringLiteral( STYLE_CURRENT_VERSION ) );
2524 doc.appendChild( root );
2525
2526 const QStringList favoriteSymbols = symbolsOfFavorite( SymbolEntity );
2527 const QStringList favoriteColorramps = symbolsOfFavorite( ColorrampEntity );
2528 const QStringList favoriteTextFormats = symbolsOfFavorite( TextFormatEntity );
2529 const QStringList favoriteLegendShapes = symbolsOfFavorite( LegendPatchShapeEntity );
2530 const QStringList favorite3DSymbols = symbolsOfFavorite( Symbol3DEntity );
2531
2532 // save symbols and attach tags
2533 QDomElement symbolsElem = QgsSymbolLayerUtils::saveSymbols( mSymbols, QStringLiteral( "symbols" ), doc, QgsReadWriteContext() );
2534 QDomNodeList symbolsList = symbolsElem.elementsByTagName( QStringLiteral( "symbol" ) );
2535 int nbSymbols = symbolsList.count();
2536 for ( int i = 0; i < nbSymbols; ++i )
2537 {
2538 QDomElement symbol = symbolsList.at( i ).toElement();
2539 QString name = symbol.attribute( QStringLiteral( "name" ) );
2540 QStringList tags = tagsOfSymbol( SymbolEntity, name );
2541 if ( tags.count() > 0 )
2542 {
2543 symbol.setAttribute( QStringLiteral( "tags" ), tags.join( ',' ) );
2544 }
2545 if ( favoriteSymbols.contains( name ) )
2546 {
2547 symbol.setAttribute( QStringLiteral( "favorite" ), QStringLiteral( "1" ) );
2548 }
2549 }
2550
2551 // save color ramps
2552 QDomElement rampsElem = doc.createElement( QStringLiteral( "colorramps" ) );
2553 for ( QMap<QString, QgsColorRamp *>::const_iterator itr = mColorRamps.constBegin(); itr != mColorRamps.constEnd(); ++itr )
2554 {
2555 QDomElement rampEl = QgsSymbolLayerUtils::saveColorRamp( itr.key(), itr.value(), doc );
2556 QStringList tags = tagsOfSymbol( ColorrampEntity, itr.key() );
2557 if ( tags.count() > 0 )
2558 {
2559 rampEl.setAttribute( QStringLiteral( "tags" ), tags.join( ',' ) );
2560 }
2561 if ( favoriteColorramps.contains( itr.key() ) )
2562 {
2563 rampEl.setAttribute( QStringLiteral( "favorite" ), QStringLiteral( "1" ) );
2564 }
2565 rampsElem.appendChild( rampEl );
2566 }
2567
2568 // save text formats
2569 QDomElement textFormatsElem = doc.createElement( QStringLiteral( "textformats" ) );
2570 for ( auto it = mTextFormats.constBegin(); it != mTextFormats.constEnd(); ++it )
2571 {
2572 QDomElement textFormatEl = doc.createElement( QStringLiteral( "textformat" ) );
2573 textFormatEl.setAttribute( QStringLiteral( "name" ), it.key() );
2574 QDomElement textStyleEl = it.value().writeXml( doc, QgsReadWriteContext() );
2575 textFormatEl.appendChild( textStyleEl );
2576 QStringList tags = tagsOfSymbol( TextFormatEntity, it.key() );
2577 if ( tags.count() > 0 )
2578 {
2579 textFormatEl.setAttribute( QStringLiteral( "tags" ), tags.join( ',' ) );
2580 }
2581 if ( favoriteTextFormats.contains( it.key() ) )
2582 {
2583 textFormatEl.setAttribute( QStringLiteral( "favorite" ), QStringLiteral( "1" ) );
2584 }
2585 textFormatsElem.appendChild( textFormatEl );
2586 }
2587
2588 // save label settings
2589 QDomElement labelSettingsElem = doc.createElement( QStringLiteral( "labelsettings" ) );
2590 for ( auto it = mLabelSettings.constBegin(); it != mLabelSettings.constEnd(); ++it )
2591 {
2592 QDomElement labelSettingsEl = doc.createElement( QStringLiteral( "labelsetting" ) );
2593 labelSettingsEl.setAttribute( QStringLiteral( "name" ), it.key() );
2594 QDomElement defEl = it.value().writeXml( doc, QgsReadWriteContext() );
2595 labelSettingsEl.appendChild( defEl );
2596 QStringList tags = tagsOfSymbol( LabelSettingsEntity, it.key() );
2597 if ( tags.count() > 0 )
2598 {
2599 labelSettingsEl.setAttribute( QStringLiteral( "tags" ), tags.join( ',' ) );
2600 }
2601 if ( favoriteTextFormats.contains( it.key() ) )
2602 {
2603 labelSettingsEl.setAttribute( QStringLiteral( "favorite" ), QStringLiteral( "1" ) );
2604 }
2605 labelSettingsElem.appendChild( labelSettingsEl );
2606 }
2607
2608 // save legend patch shapes
2609 QDomElement legendPatchShapesElem = doc.createElement( QStringLiteral( "legendpatchshapes" ) );
2610 for ( auto it = mLegendPatchShapes.constBegin(); it != mLegendPatchShapes.constEnd(); ++it )
2611 {
2612 QDomElement legendPatchShapeEl = doc.createElement( QStringLiteral( "legendpatchshape" ) );
2613 legendPatchShapeEl.setAttribute( QStringLiteral( "name" ), it.key() );
2614 QDomElement defEl = doc.createElement( QStringLiteral( "definition" ) );
2615 it.value().writeXml( defEl, doc, QgsReadWriteContext() );
2616 legendPatchShapeEl.appendChild( defEl );
2617 QStringList tags = tagsOfSymbol( LegendPatchShapeEntity, it.key() );
2618 if ( tags.count() > 0 )
2619 {
2620 legendPatchShapeEl.setAttribute( QStringLiteral( "tags" ), tags.join( ',' ) );
2621 }
2622 if ( favoriteLegendShapes.contains( it.key() ) )
2623 {
2624 legendPatchShapeEl.setAttribute( QStringLiteral( "favorite" ), QStringLiteral( "1" ) );
2625 }
2626 legendPatchShapesElem.appendChild( legendPatchShapeEl );
2627 }
2628
2629 // save symbols and attach tags
2630 QDomElement symbols3DElem = doc.createElement( QStringLiteral( "symbols3d" ) );
2631 for ( auto it = m3dSymbols.constBegin(); it != m3dSymbols.constEnd(); ++it )
2632 {
2633 QDomElement symbolEl = doc.createElement( QStringLiteral( "symbol3d" ) );
2634 symbolEl.setAttribute( QStringLiteral( "name" ), it.key() );
2635 QDomElement defEl = doc.createElement( QStringLiteral( "definition" ) );
2636 defEl.setAttribute( QStringLiteral( "type" ), it.value()->type() );
2637 it.value()->writeXml( defEl, QgsReadWriteContext() );
2638 symbolEl.appendChild( defEl );
2639 QStringList tags = tagsOfSymbol( Symbol3DEntity, it.key() );
2640 if ( tags.count() > 0 )
2641 {
2642 symbolEl.setAttribute( QStringLiteral( "tags" ), tags.join( ',' ) );
2643 }
2644 if ( favorite3DSymbols.contains( it.key() ) )
2645 {
2646 symbolEl.setAttribute( QStringLiteral( "favorite" ), QStringLiteral( "1" ) );
2647 }
2648 symbols3DElem.appendChild( symbolEl );
2649 }
2650
2651 root.appendChild( symbolsElem );
2652 root.appendChild( rampsElem );
2653 root.appendChild( textFormatsElem );
2654 root.appendChild( labelSettingsElem );
2655 root.appendChild( legendPatchShapesElem );
2656 root.appendChild( symbols3DElem );
2657
2658 // save
2659 QFile f( filename );
2660 if ( !f.open( QFile::WriteOnly | QIODevice::Truncate ) )
2661 {
2662 mErrorString = "Couldn't open file for writing: " + filename;
2663 return false;
2664 }
2665
2666 QTextStream ts( &f );
2667 ts.setCodec( "UTF-8" );
2668 doc.save( ts, 2 );
2669 f.close();
2670
2671 mFileName = filename;
2672 return true;
2673 }
2674
2675 bool QgsStyle::importXml( const QString &filename )
2676 {
2677 return importXml( filename, -1 );
2678 }
2679
2680 bool QgsStyle::importXml( const QString &filename, int sinceVersion )
2681 {
2682 mErrorString = QString();
2683 QDomDocument doc( QStringLiteral( "style" ) );
2684 QFile f( filename );
2685 if ( !f.open( QFile::ReadOnly ) )
2686 {
2687 mErrorString = QStringLiteral( "Unable to open the specified file" );
2688 QgsDebugMsg( QStringLiteral( "Error opening the style XML file." ) );
2689 return false;
2690 }
2691
2692 if ( !doc.setContent( &f ) )
2693 {
2694 mErrorString = QStringLiteral( "Unable to understand the style file: %1" ).arg( filename );
2695 QgsDebugMsg( QStringLiteral( "XML Parsing error" ) );
2696 f.close();
2697 return false;
2698 }
2699 f.close();
2700
2701 QDomElement docEl = doc.documentElement();
2702 if ( docEl.tagName() != QLatin1String( "qgis_style" ) )
2703 {
2704 mErrorString = "Incorrect root tag in style: " + docEl.tagName();
2705 return false;
2706 }
2707
2708 const QString version = docEl.attribute( QStringLiteral( "version" ) );
2709 if ( version != QLatin1String( STYLE_CURRENT_VERSION ) && version != QLatin1String( "0" ) && version != QLatin1String( "1" ) )
2710 {
2711 mErrorString = "Unknown style file version: " + version;
2712 return false;
2713 }
2714
2715 QgsSymbolMap symbols;
2716
2717 QDomElement symbolsElement = docEl.firstChildElement( QStringLiteral( "symbols" ) );
2718 QDomElement e = symbolsElement.firstChildElement();
2719
2720 // gain speed by re-grouping the INSERT statements in a transaction
2721 QString query = qgs_sqlite3_mprintf( "BEGIN TRANSACTION;" );
2722 runEmptyQuery( query );
2723
2724 if ( version == QLatin1String( STYLE_CURRENT_VERSION ) || version == QLatin1String( "1" ) )
2725 {
2726 // For the new style, load symbols individually
2727 while ( !e.isNull() )
2728 {
2729 const int entityAddedVersion = e.attribute( QStringLiteral( "addedVersion" ) ).toInt();
2730 if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
2731 {
2732 // skip the symbol, should already be present
2733 continue;
2734 }
2735
2736 if ( e.tagName() == QLatin1String( "symbol" ) )
2737 {
2738 QString name = e.attribute( QStringLiteral( "name" ) );
2739 QStringList tags;
2740 if ( e.hasAttribute( QStringLiteral( "tags" ) ) )
2741 {
2742 tags = e.attribute( QStringLiteral( "tags" ) ).split( ',' );
2743 }
2744 bool favorite = false;
2745 if ( e.hasAttribute( QStringLiteral( "favorite" ) ) && e.attribute( QStringLiteral( "favorite" ) ) == QLatin1String( "1" ) )
2746 {
2747 favorite = true;
2748 }
2749
2751 if ( symbol )
2752 {
2753 addSymbol( name, symbol );
2754 if ( mCurrentDB )
2755 {
2756 saveSymbol( name, symbol, favorite, tags );
2757 }
2758 }
2759 }
2760 else
2761 {
2762 QgsDebugMsg( "unknown tag: " + e.tagName() );
2763 }
2764 e = e.nextSiblingElement();
2765 }
2766 }
2767 else
2768 {
2769 // for the old version, use the utility function to solve @symbol@layer subsymbols
2770 symbols = QgsSymbolLayerUtils::loadSymbols( symbolsElement, QgsReadWriteContext() );
2771
2772 // save the symbols with proper name
2773 for ( QMap<QString, QgsSymbol *>::iterator it = symbols.begin(); it != symbols.end(); ++it )
2774 {
2775 addSymbol( it.key(), it.value() );
2776 }
2777 }
2778
2779 // load color ramps
2780 QDomElement rampsElement = docEl.firstChildElement( QStringLiteral( "colorramps" ) );
2781 e = rampsElement.firstChildElement();
2782 while ( !e.isNull() )
2783 {
2784 const int entityAddedVersion = e.attribute( QStringLiteral( "addedVersion" ) ).toInt();
2785 if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
2786 {
2787 // skip the ramp, should already be present
2788 continue;
2789 }
2790
2791 if ( e.tagName() == QLatin1String( "colorramp" ) )
2792 {
2793 QString name = e.attribute( QStringLiteral( "name" ) );
2794 QStringList tags;
2795 if ( e.hasAttribute( QStringLiteral( "tags" ) ) )
2796 {
2797 tags = e.attribute( QStringLiteral( "tags" ) ).split( ',' );
2798 }
2799 bool favorite = false;
2800 if ( e.hasAttribute( QStringLiteral( "favorite" ) ) && e.attribute( QStringLiteral( "favorite" ) ) == QLatin1String( "1" ) )
2801 {
2802 favorite = true;
2803 }
2804
2806 if ( ramp )
2807 {
2808 addColorRamp( name, ramp );
2809 if ( mCurrentDB )
2810 {
2811 saveColorRamp( name, ramp, favorite, tags );
2812 }
2813 }
2814 }
2815 else
2816 {
2817 QgsDebugMsg( "unknown tag: " + e.tagName() );
2818 }
2819 e = e.nextSiblingElement();
2820 }
2821
2822 // load text formats
2823 if ( version == STYLE_CURRENT_VERSION )
2824 {
2825 const QDomElement textFormatElement = docEl.firstChildElement( QStringLiteral( "textformats" ) );
2826 e = textFormatElement.firstChildElement();
2827 while ( !e.isNull() )
2828 {
2829 const int entityAddedVersion = e.attribute( QStringLiteral( "addedVersion" ) ).toInt();
2830 if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
2831 {
2832 // skip the format, should already be present
2833 continue;
2834 }
2835
2836 if ( e.tagName() == QLatin1String( "textformat" ) )
2837 {
2838 QString name = e.attribute( QStringLiteral( "name" ) );
2839 QStringList tags;
2840 if ( e.hasAttribute( QStringLiteral( "tags" ) ) )
2841 {
2842 tags = e.attribute( QStringLiteral( "tags" ) ).split( ',' );
2843 }
2844 bool favorite = false;
2845 if ( e.hasAttribute( QStringLiteral( "favorite" ) ) && e.attribute( QStringLiteral( "favorite" ) ) == QLatin1String( "1" ) )
2846 {
2847 favorite = true;
2848 }
2849
2850 QgsTextFormat format;
2851 const QDomElement styleElem = e.firstChildElement();
2852 format.readXml( styleElem, QgsReadWriteContext() );
2853 addTextFormat( name, format );
2854 if ( mCurrentDB )
2855 {
2856 saveTextFormat( name, format, favorite, tags );
2857 }
2858 }
2859 else
2860 {
2861 QgsDebugMsg( "unknown tag: " + e.tagName() );
2862 }
2863 e = e.nextSiblingElement();
2864 }
2865 }
2866
2867 // load label settings
2868 if ( version == STYLE_CURRENT_VERSION )
2869 {
2870 const QDomElement labelSettingsElement = docEl.firstChildElement( QStringLiteral( "labelsettings" ) );
2871 e = labelSettingsElement.firstChildElement();
2872 while ( !e.isNull() )
2873 {
2874 const int entityAddedVersion = e.attribute( QStringLiteral( "addedVersion" ) ).toInt();
2875 if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
2876 {
2877 // skip the settings, should already be present
2878 continue;
2879 }
2880
2881 if ( e.tagName() == QLatin1String( "labelsetting" ) )
2882 {
2883 QString name = e.attribute( QStringLiteral( "name" ) );
2884 QStringList tags;
2885 if ( e.hasAttribute( QStringLiteral( "tags" ) ) )
2886 {
2887 tags = e.attribute( QStringLiteral( "tags" ) ).split( ',' );
2888 }
2889 bool favorite = false;
2890 if ( e.hasAttribute( QStringLiteral( "favorite" ) ) && e.attribute( QStringLiteral( "favorite" ) ) == QLatin1String( "1" ) )
2891 {
2892 favorite = true;
2893 }
2894
2895 QgsPalLayerSettings settings;
2896 const QDomElement styleElem = e.firstChildElement();
2897 settings.readXml( styleElem, QgsReadWriteContext() );
2898 addLabelSettings( name, settings );
2899 if ( mCurrentDB )
2900 {
2901 saveLabelSettings( name, settings, favorite, tags );
2902 }
2903 }
2904 else
2905 {
2906 QgsDebugMsg( "unknown tag: " + e.tagName() );
2907 }
2908 e = e.nextSiblingElement();
2909 }
2910 }
2911
2912 // load legend patch shapes
2913 if ( version == STYLE_CURRENT_VERSION )
2914 {
2915 const QDomElement legendPatchShapesElement = docEl.firstChildElement( QStringLiteral( "legendpatchshapes" ) );
2916 e = legendPatchShapesElement.firstChildElement();
2917 while ( !e.isNull() )
2918 {
2919 const int entityAddedVersion = e.attribute( QStringLiteral( "addedVersion" ) ).toInt();
2920 if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
2921 {
2922 // skip the shape, should already be present
2923 continue;
2924 }
2925
2926 if ( e.tagName() == QLatin1String( "legendpatchshape" ) )
2927 {
2928 QString name = e.attribute( QStringLiteral( "name" ) );
2929 QStringList tags;
2930 if ( e.hasAttribute( QStringLiteral( "tags" ) ) )
2931 {
2932 tags = e.attribute( QStringLiteral( "tags" ) ).split( ',' );
2933 }
2934 bool favorite = false;
2935 if ( e.hasAttribute( QStringLiteral( "favorite" ) ) && e.attribute( QStringLiteral( "favorite" ) ) == QLatin1String( "1" ) )
2936 {
2937 favorite = true;
2938 }
2939
2940 QgsLegendPatchShape shape;
2941 const QDomElement shapeElem = e.firstChildElement();
2942 shape.readXml( shapeElem, QgsReadWriteContext() );
2943 addLegendPatchShape( name, shape );
2944 if ( mCurrentDB )
2945 {
2946 saveLegendPatchShape( name, shape, favorite, tags );
2947 }
2948 }
2949 else
2950 {
2951 QgsDebugMsg( "unknown tag: " + e.tagName() );
2952 }
2953 e = e.nextSiblingElement();
2954 }
2955 }
2956
2957 // load 3d symbols
2958 if ( version == STYLE_CURRENT_VERSION )
2959 {
2960 const QDomElement symbols3DElement = docEl.firstChildElement( QStringLiteral( "symbols3d" ) );
2961 e = symbols3DElement.firstChildElement();
2962 while ( !e.isNull() )
2963 {
2964 const int entityAddedVersion = e.attribute( QStringLiteral( "addedVersion" ) ).toInt();
2965 if ( entityAddedVersion != 0 && sinceVersion != -1 && entityAddedVersion <= sinceVersion )
2966 {
2967 // skip the symbol, should already be present
2968 continue;
2969 }
2970
2971 if ( e.tagName() == QLatin1String( "symbol3d" ) )
2972 {
2973 QString name = e.attribute( QStringLiteral( "name" ) );
2974 QStringList tags;
2975 if ( e.hasAttribute( QStringLiteral( "tags" ) ) )
2976 {
2977 tags = e.attribute( QStringLiteral( "tags" ) ).split( ',' );
2978 }
2979 bool favorite = false;
2980 if ( e.hasAttribute( QStringLiteral( "favorite" ) ) && e.attribute( QStringLiteral( "favorite" ) ) == QLatin1String( "1" ) )
2981 {
2982 favorite = true;
2983 }
2984
2985 const QDomElement symbolElem = e.firstChildElement();
2986 const QString type = symbolElem.attribute( QStringLiteral( "type" ) );
2987 std::unique_ptr< QgsAbstract3DSymbol > sym( QgsApplication::symbol3DRegistry()->createSymbol( type ) );
2988 if ( sym )
2989 {
2990 sym->readXml( symbolElem, QgsReadWriteContext() );
2991 QgsAbstract3DSymbol *newSym = sym.get();
2992 addSymbol3D( name, sym.release() );
2993 if ( mCurrentDB )
2994 {
2995 saveSymbol3D( name, newSym, favorite, tags );
2996 }
2997 }
2998 }
2999 else
3000 {
3001 QgsDebugMsg( "unknown tag: " + e.tagName() );
3002 }
3003 e = e.nextSiblingElement();
3004 }
3005 }
3006
3007 query = qgs_sqlite3_mprintf( "COMMIT TRANSACTION;" );
3008 runEmptyQuery( query );
3009
3010 mFileName = filename;
3011 return true;
3012 }
3013
3014 bool QgsStyle::isXmlStyleFile( const QString &path )
3015 {
3016 QFileInfo fileInfo( path );
3017
3018 if ( fileInfo.suffix().compare( QLatin1String( "xml" ), Qt::CaseInsensitive ) != 0 )
3019 return false;
3020
3021 // sniff the first line of the file to see if it's a style file
3022 if ( !QFile::exists( path ) )
3023 return false;
3024
3025 QFile inputFile( path );
3026 if ( !inputFile.open( QIODevice::ReadOnly ) )
3027 return false;
3028
3029 QTextStream stream( &inputFile );
3030 const QString line = stream.readLine();
3031 return line == QLatin1String( "<!DOCTYPE qgis_style>" );
3032 }
3033
3034 bool QgsStyle::updateSymbol( StyleEntity type, const QString &name )
3035 {
3036 QDomDocument doc( QStringLiteral( "dummy" ) );
3037 QDomElement symEl;
3038 QByteArray xmlArray;
3039 QTextStream stream( &xmlArray );
3040 stream.setCodec( "UTF-8" );
3041
3042 QString query;
3043
3044 switch ( type )
3045 {
3046 case SymbolEntity:
3047 {
3048 // check if it is an existing symbol
3049 if ( !symbolNames().contains( name ) )
3050 {
3051 QgsDebugMsg( QStringLiteral( "Update request received for unavailable symbol" ) );
3052 return false;
3053 }
3054
3055 symEl = QgsSymbolLayerUtils::saveSymbol( name, symbol( name ), doc, QgsReadWriteContext() );
3056 if ( symEl.isNull() )
3057 {
3058 QgsDebugMsg( QStringLiteral( "Couldn't convert symbol to valid XML!" ) );
3059 return false;
3060 }
3061 symEl.save( stream, 4 );
3062 query = qgs_sqlite3_mprintf( "UPDATE symbol SET xml='%q' WHERE name='%q';",
3063 xmlArray.constData(), name.toUtf8().constData() );
3064 break;
3065 }
3066
3067 case Symbol3DEntity:
3068 {
3069 // check if it is an existing symbol
3070 if ( !symbol3DNames().contains( name ) )
3071 {
3072 QgsDebugMsg( QStringLiteral( "Update request received for unavailable symbol" ) );
3073 return false;
3074 }
3075
3076 symEl = doc.createElement( QStringLiteral( "symbol" ) );
3077 symEl.setAttribute( QStringLiteral( "type" ), m3dSymbols.value( name )->type() );
3078 m3dSymbols.value( name )->writeXml( symEl, QgsReadWriteContext() );
3079 if ( symEl.isNull() )
3080 {
3081 QgsDebugMsg( QStringLiteral( "Couldn't convert symbol to valid XML!" ) );
3082 return false;
3083 }
3084 symEl.save( stream, 4 );
3085 query = qgs_sqlite3_mprintf( "UPDATE symbol3d SET xml='%q' WHERE name='%q';",
3086 xmlArray.constData(), name.toUtf8().constData() );
3087 break;
3088 }
3089
3090 case ColorrampEntity:
3091 {
3092 if ( !colorRampNames().contains( name ) )
3093 {
3094 QgsDebugMsg( QStringLiteral( "Update requested for unavailable color ramp." ) );
3095 return false;
3096 }
3097
3098 std::unique_ptr< QgsColorRamp > ramp( colorRamp( name ) );
3099 symEl = QgsSymbolLayerUtils::saveColorRamp( name, ramp.get(), doc );
3100 if ( symEl.isNull() )
3101 {
3102 QgsDebugMsg( QStringLiteral( "Couldn't convert color ramp to valid XML!" ) );
3103 return false;
3104 }
3105 symEl.save( stream, 4 );
3106 query = qgs_sqlite3_mprintf( "UPDATE colorramp SET xml='%q' WHERE name='%q';",
3107 xmlArray.constData(), name.toUtf8().constData() );
3108 break;
3109 }
3110
3111 case TextFormatEntity:
3112 {
3113 if ( !textFormatNames().contains( name ) )
3114 {
3115 QgsDebugMsg( QStringLiteral( "Update requested for unavailable text format." ) );
3116 return false;
3117 }
3118
3119 QgsTextFormat format( textFormat( name ) );
3120 symEl = format.writeXml( doc, QgsReadWriteContext() );
3121 if ( symEl.isNull() )
3122 {
3123 QgsDebugMsg( QStringLiteral( "Couldn't convert text format to valid XML!" ) );
3124 return false;
3125 }
3126 symEl.save( stream, 4 );
3127 query = qgs_sqlite3_mprintf( "UPDATE textformat SET xml='%q' WHERE name='%q';",
3128 xmlArray.constData(), name.toUtf8().constData() );
3129 break;
3130 }
3131
3132 case LabelSettingsEntity:
3133 {
3134 if ( !labelSettingsNames().contains( name ) )
3135 {
3136 QgsDebugMsg( QStringLiteral( "Update requested for unavailable label settings." ) );
3137 return false;
3138 }
3139
3140 QgsPalLayerSettings settings( labelSettings( name ) );
3141 symEl = settings.writeXml( doc, QgsReadWriteContext() );
3142 if ( symEl.isNull() )
3143 {
3144 QgsDebugMsg( QStringLiteral( "Couldn't convert label settings to valid XML!" ) );
3145 return false;
3146 }
3147 symEl.save( stream, 4 );
3148 query = qgs_sqlite3_mprintf( "UPDATE labelsettings SET xml='%q' WHERE name='%q';",
3149 xmlArray.constData(), name.toUtf8().constData() );
3150 break;
3151 }
3152
3154 {
3155 if ( !legendPatchShapeNames().contains( name ) )
3156 {
3157 QgsDebugMsg( QStringLiteral( "Update requested for unavailable legend patch shape." ) );
3158 return false;
3159 }
3160
3161 QgsLegendPatchShape shape( legendPatchShape( name ) );
3162 symEl = doc.createElement( QStringLiteral( "shape" ) );
3163 shape.writeXml( symEl, doc, QgsReadWriteContext() );
3164 symEl.save( stream, 4 );
3165 query = qgs_sqlite3_mprintf( "UPDATE legendpatchshapes SET xml='%q' WHERE name='%q';",
3166 xmlArray.constData(), name.toUtf8().constData() );
3167 break;
3168 }
3169
3170 case TagEntity:
3171 case SmartgroupEntity:
3172 {
3173 QgsDebugMsg( QStringLiteral( "Updating the unsupported StyleEntity" ) );
3174 return false;
3175 }
3176 }
3177
3178
3179 if ( !runEmptyQuery( query ) )
3180 {
3181 QgsDebugMsg( QStringLiteral( "Couldn't insert symbol into the database!" ) );
3182 return false;
3183 }
3184 else
3185 {
3186 switch ( type )
3187 {
3188 case SymbolEntity:
3189 emit symbolChanged( name );
3190 break;
3191
3192 case ColorrampEntity:
3193 emit rampChanged( name );
3194 break;
3195
3196 case TextFormatEntity:
3197 emit textFormatChanged( name );
3198 break;
3199
3200 case LabelSettingsEntity:
3201 emit labelSettingsChanged( name );
3202 break;
3203
3205 case TagEntity:
3206 case SmartgroupEntity:
3207 case Symbol3DEntity:
3208 break;
3209 }
3210 emit entityChanged( type, name );
3211 }
3212 return true;
3213 }
3214
3215 void QgsStyle::clearCachedTags( QgsStyle::StyleEntity type, const QString &name )
3216 {
3217 mCachedTags[ type ].remove( name );
3218 }
3219
3220 void QgsStyle::upgradeIfRequired()
3221 {
3222 // make sure metadata table exists
3223 QString query = qgs_sqlite3_mprintf( "SELECT name FROM sqlite_master WHERE name='stylemetadata'" );
3224 sqlite3_statement_unique_ptr statement;
3225 int rc;
3226 int dbVersion = 0;
3227 statement = mCurrentDB.prepare( query, rc );
3228
3229 if ( rc != SQLITE_OK || sqlite3_step( statement.get() ) != SQLITE_ROW )
3230 {
3231 // no metadata table
3232 query = qgs_sqlite3_mprintf( "CREATE TABLE stylemetadata("\
3233 "id INTEGER PRIMARY KEY,"\
3234 "key TEXT UNIQUE,"\
3235 "value TEXT);" );
3236 runEmptyQuery( query );
3237 query = qgs_sqlite3_mprintf( "INSERT INTO stylemetadata VALUES (NULL, '%q', '%q')", "version", "31200" );
3238 runEmptyQuery( query );
3239
3240 dbVersion = 31200;
3241 }
3242 else
3243 {
3244 query = qgs_sqlite3_mprintf( "SELECT value FROM stylemetadata WHERE key='version'" );
3245 statement = mCurrentDB.prepare( query, rc );
3246 if ( rc == SQLITE_OK && sqlite3_step( statement.get() ) == SQLITE_ROW )
3247 {
3248 dbVersion = statement.columnAsText( 0 ).toInt();
3249 }
3250 }
3251
3252 if ( dbVersion < Qgis::versionInt() )
3253 {
3254 // do upgrade
3255 if ( importXml( QgsApplication::defaultStylePath(), dbVersion ) )
3256 {
3257 query = qgs_sqlite3_mprintf( "UPDATE stylemetadata SET value='%q' WHERE key='version'", QString::number( Qgis::versionInt() ).toUtf8().constData() );
3258 runEmptyQuery( query );
3259 }
3260 }
3261 }
3262
3263 QString QgsStyle::entityTableName( QgsStyle::StyleEntity type )
3264 {
3265 switch ( type )
3266 {
3267 case SymbolEntity:
3268 return QStringLiteral( "symbol" );
3269
3270 case ColorrampEntity:
3271 return QStringLiteral( "colorramp" );
3272
3273 case TextFormatEntity:
3274 return QStringLiteral( "textformat" );
3275
3276 case LabelSettingsEntity:
3277 return QStringLiteral( "labelsettings" );
3278
3280 return QStringLiteral( "legendpatchshapes" );
3281
3282 case Symbol3DEntity:
3283 return QStringLiteral( "symbol3d" );
3284
3285 case TagEntity:
3286 return QStringLiteral( "tag" );
3287
3288 case SmartgroupEntity:
3289 return QStringLiteral( "smartgroup" );
3290 }
3291 return QString();
3292 }
3293
3294 QString QgsStyle::tagmapTableName( QgsStyle::StyleEntity type )
3295 {
3296 switch ( type )
3297 {
3298 case SymbolEntity:
3299 return QStringLiteral( "tagmap" );
3300
3301 case ColorrampEntity:
3302 return QStringLiteral( "ctagmap" );
3303
3304 case TextFormatEntity:
3305 return QStringLiteral( "tftagmap" );
3306
3307 case LabelSettingsEntity:
3308 return QStringLiteral( "lstagmap" );
3309
3311 return QStringLiteral( "lpstagmap" );
3312
3313 case Symbol3DEntity:
3314 return QStringLiteral( "symbol3dtagmap" );
3315
3316 case TagEntity:
3317 case SmartgroupEntity:
3318 break;
3319 }
3320 return QString();
3321 }
3322
3323 QString QgsStyle::tagmapEntityIdFieldName( QgsStyle::StyleEntity type )
3324 {
3325 switch ( type )
3326 {
3327 case SymbolEntity:
3328 return QStringLiteral( "symbol_id" );
3329
3330 case ColorrampEntity:
3331 return QStringLiteral( "colorramp_id" );
3332
3333 case TextFormatEntity:
3334 return QStringLiteral( "textformat_id" );
3335
3336 case LabelSettingsEntity:
3337 return QStringLiteral( "labelsettings_id" );
3338
3340 return QStringLiteral( "legendpatchshape_id" );
3341
3342 case Symbol3DEntity:
3343 return QStringLiteral( "symbol3d_id" );
3344
3345 case TagEntity:
3346 case SmartgroupEntity:
3347 break;
3348 }
3349 return QString();
3350 }
3351
3353 {
3354 return QgsStyle::SymbolEntity;
3355 }
3356
3358 {
3360 }
3361
3363 {
3365 }
3366
3368 {
3370 }
3371
3373 {
3375 }
3376
3378 {
3379 return QgsStyle::Symbol3DEntity;
3380 }
qgspolygon.h
QgsStyle::saveTextFormat
bool saveTextFormat(const QString &name, const QgsTextFormat &format, bool favorite, const QStringList &tags)
Adds a text format to the database.
Definition: qgsstyle.cpp:949
QgsColorRamp
Abstract base class for color ramps.
Definition: qgscolorramp.h:32
QgsStyle::favoritedChanged
void favoritedChanged(QgsStyle::StyleEntity entity, const QString &name, bool isFavorite)
Emitted whenever an entity is either favorited or un-favorited.
ColorrampXML
@ ColorrampXML
Color ramp definition (as XML)
Definition: qgsstyle.h:119
QgsPalLayerSettings::readXml
void readXml(const QDomElement &elem, const QgsReadWriteContext &context)
Read settings from a DOM element.
Definition: qgspallabeling.cpp:904
QgsLegendPatchShape::toQPolygonF
QList< QList< QPolygonF > > toQPolygonF(QgsSymbol::SymbolType type, QSizeF size) const
Converts the patch shape to a set of QPolygonF objects representing how the patch should be drawn for...
Definition: qgslegendpatchshape.cpp:84
QgsStyleSymbolEntity::type
QgsStyle::StyleEntity type() const override
Returns the type of style entity.
Definition: qgsstyle.cpp:3352
QgsStyle::renameColorRamp
bool renameColorRamp(const QString &oldName, const QString &newName)
Changes ramp's name.
Definition: qgsstyle.cpp:914
QgsStyle::isXmlStyleFile
static bool isXmlStyleFile(const QString &path)
Tests if the file at path is a QGIS style XML file.
Definition: qgsstyle.cpp:3014
sqlite3_database_unique_ptr::open
int open(const QString &path)
Opens the database at the specified file path.
Definition: qgssqliteutils.cpp:78
QgsStyle::ColorrampEntity
@ ColorrampEntity
Color ramps.
Definition: qgsstyle.h:182
qgsruntimeprofiler.h
QgsSymbolLayerUtils::loadSymbols
static QgsSymbolMap loadSymbols(QDomElement &element, const QgsReadWriteContext &context)
Reads a collection of symbols from XML and returns them in a map. Caller is responsible for deleting ...
Definition: qgssymbollayerutils.cpp:2946
QgsStyle::entityAdded
void entityAdded(QgsStyle::StyleEntity entity, const QString &name)
Emitted every time a new entity has been added to the database.
QgsStyle::tagSymbol
bool tagSymbol(StyleEntity type, const QString &symbol, const QStringList &tags)
Tags the symbol with the tags in the list.
Definition: qgsstyle.cpp:1736
qgslinestring.h
QgsReadWriteContext
The class is used as a container of context for various read/write operations on other objects.
Definition: qgsreadwritecontext.h:35
QgsStyle::labelSettingsLayerType
QgsWkbTypes::GeometryType labelSettingsLayerType(const QString &name) const
Returns the layer geometry type corresponding to the label settings with the specified name,...
Definition: qgsstyle.cpp:2162
QgsStyle::removeEntityByName
bool removeEntityByName(StyleEntity type, const QString &name)
Removes the entry of the specified type with matching name from the database.
Definition: qgsstyle.cpp:1483
QgsStyle::createDatabase
bool createDatabase(const QString &filename)
Creates an on-disk database.
Definition: qgsstyle.cpp:492
QgsStyle::textFormat
QgsTextFormat textFormat(const QString &name) const
Returns the text format with the specified name.
Definition: qgsstyle.cpp:2101
QgsStyle::renameTextFormat
bool renameTextFormat(const QString &oldName, const QString &newName)
Changes a text format's name.
Definition: qgsstyle.cpp:988
QgsStyle::createMemoryDatabase
bool createMemoryDatabase()
Creates a temporary memory database.
Definition: qgsstyle.cpp:507
QgsStyleSymbolEntity
A symbol entity for QgsStyle databases.
Definition: qgsstyle.h:1201
QgsPalLayerSettings
Definition: qgspallabeling.h:207
sqlite3_database_unique_ptr::prepare
sqlite3_statement_unique_ptr prepare(const QString &sql, int &resultCode) const
Prepares a sql statement, returning the result.
Definition: qgssqliteutils.cpp:99
QgsStyle::entityId
int entityId(StyleEntity type, const QString &name)
Returns the id in the style database for the given name of the specified entity type.
Definition: qgsstyle.cpp:2091
QgsStyle::symbolsOfFavorite
QStringList symbolsOfFavorite(StyleEntity type) const
Returns the symbol names which are flagged as favorite.
Definition: qgsstyle.cpp:1282
QgsStyle::symbol3DCount
int symbol3DCount() const
Returns count of 3D symbols in the style.
Definition: qgsstyle.cpp:2149
qgsreadwritecontext.h
QgsStyle::labelSettingsNames
QStringList labelSettingsNames() const
Returns a list of names of label settings in the style.
Definition: qgsstyle.cpp:2175
QgsSymbolMap
QMap< QString, QgsSymbol * > QgsSymbolMap
Definition: qgsrenderer.h:46
QgsStyleColorRampEntity
A color ramp entity for QgsStyle databases.
Definition: qgsstyle.h:1233
SmartgroupId
@ SmartgroupId
Smart group ID.
Definition: qgsstyle.h:150
QgsStyle::labelSettingsChanged
void labelSettingsChanged(const QString &name)
Emitted whenever a label setting's definition is changed.
QgsStyle::colorRampRef
const QgsColorRamp * colorRampRef(const QString &name) const
Returns a const pointer to a symbol (doesn't create new instance)
Definition: qgsstyle.cpp:444
Qgs3DSymbolRegistry::symbolTypes
QStringList symbolTypes() const
Returns a list of all available symbol types.
Definition: qgs3dsymbolregistry.cpp:76
QgsApplication::defaultStylePath
static QString defaultStylePath()
Returns the path to default style (works as a starting point).
Definition: qgsapplication.cpp:1220
QgsStyleEntityInterface
An interface for entities which can be placed in a QgsStyle database.
Definition: qgsstyle.h:1153
QgsApplication::symbol3DRegistry
static Qgs3DSymbolRegistry * symbol3DRegistry()
Returns registry of available 3D symbols.
Definition: qgsapplication.cpp:2288
qgsmarkersymbollayer.h
Symbol3DTableName
@ Symbol3DTableName
3d symbol name
Definition: qgsstyle.cpp:65
QgsStyle::labelSettingsRemoved
void labelSettingsRemoved(const QString &name)
Emitted whenever label settings have been removed from the style and the database has been updated as...
QgsStyle::addFavorite
bool addFavorite(StyleEntity type, const QString &name)
Adds the specified symbol to favorites.
Definition: qgsstyle.cpp:1607
TextFormatXML
@ TextFormatXML
Text format definition (as XML)
Definition: qgsstyle.h:130
QgsSettings
This class is a composition of two QSettings instances:
Definition: qgssettings.h:62
QgsStyle::load
bool load(const QString &filename)
Loads a file into the style.
Definition: qgsstyle.cpp:582
QgsStyle::findSymbols
QStringList findSymbols(StyleEntity type, const QString &qword)
Returns the names of the symbols which have a matching 'substring' in its definition.
Definition: qgsstyle.cpp:1669
QgsStyle::addSymbol3D
bool addSymbol3D(const QString &name, QgsAbstract3DSymbol *symbol, bool update=false)
Adds a 3d symbol with the specified name to the style.
Definition: qgsstyle.cpp:378
QgsSymbol
Abstract base class for all rendered symbols.
Definition: qgssymbol.h:64
QgsStyle::LegendPatchShapeEntity
@ LegendPatchShapeEntity
Legend patch shape (since QGIS 3.14)
Definition: qgsstyle.h:186
QgsStyle::renameEntity
bool renameEntity(StyleEntity type, const QString &oldName, const QString &newName)
Renames an entity of the specified type from oldName to newName.
Definition: qgsstyle.cpp:240
QgsDebugMsg
#define QgsDebugMsg(str)
Definition: qgslogger.h:38
QgsStyle::saveColorRamp
bool saveColorRamp(const QString &name, QgsColorRamp *ramp, bool favorite, const QStringList &tags)
Adds the colorramp to the database.
Definition: qgsstyle.cpp:399
QgsLineString
Line string geometry type, with support for z-dimension and m-values.
Definition: qgslinestring.h:44
QgsStyleColorRampEntity::type
QgsStyle::StyleEntity type() const override
Returns the type of style entity.
Definition: qgsstyle.cpp:3357
QgsStyle::entityRemoved
void entityRemoved(QgsStyle::StyleEntity entity, const QString &name)
Emitted whenever an entity of the specified type is removed from the style and the database has been ...
Symbol3DTableId
@ Symbol3DTableId
3d symbol ID
Definition: qgsstyle.cpp:64
QgsStyle::defaultPatch
QgsLegendPatchShape defaultPatch(QgsSymbol::SymbolType type, QSizeF size) const
Returns the default legend patch shape for the given symbol type.
Definition: qgsstyle.cpp:1159
sqlite3_database_unique_ptr::errorMessage
QString errorMessage() const
Returns the most recent error message encountered by the database.
Definition: qgssqliteutils.cpp:94
qgsabstract3dsymbol.h
qgs3dsymbolregistry.h
qgs_sqlite3_mprintf
QString qgs_sqlite3_mprintf(const char *format,...)
Wraps sqlite3_mprintf() by automatically freeing the memory.
Definition: qgssqliteutils.cpp:312
QgsStyle::textFormatAdded
void textFormatAdded(const QString &name)
Emitted whenever a text format has been added to the style and the database has been updated as a res...
QgsLegendPatchShape::symbolType
QgsSymbol::SymbolType symbolType() const
Returns the symbol type associated with this patch.
Definition: qgslegendpatchshape.cpp:207
QgsStyle::textFormatRenamed
void textFormatRenamed(const QString &oldName, const QString &newName)
Emitted whenever a text format has been renamed from oldName to newName.
QgsStyle::symbol
QgsSymbol * symbol(const QString &name)
Returns a NEW copy of symbol.
Definition: qgsstyle.cpp:269
QgsStyle::symbolChanged
void symbolChanged(const QString &name)
Emitted whenever a symbol's definition is changed.
QgsLegendPatchShape
Represents a patch shape for use in map legends.
Definition: qgslegendpatchshape.h:31
QgsStyle::SymbolEntity
@ SymbolEntity
Symbols.
Definition: qgsstyle.h:180
QgsStyle::symbol3DNames
QStringList symbol3DNames() const
Returns a list of names of 3d symbols in the style.
Definition: qgsstyle.cpp:1277
QgsStyle::addColorRamp
bool addColorRamp(const QString &name, QgsColorRamp *colorRamp, bool update=false)
Adds a color ramp to the style.
Definition: qgsstyle.cpp:291
QgsStyle::TagEntity
@ TagEntity
Tags.
Definition: qgsstyle.h:181
QgsStyle::labelSettingsId
int labelSettingsId(const QString &name)
Returns the ID in the style database for the given label settings by name.
Definition: qgsstyle.cpp:2180
QgsStyle::LabelSettingsEntity
@ LabelSettingsEntity
Label settings.
Definition: qgsstyle.h:185
QgsStyle::defaultStyle
static QgsStyle * defaultStyle()
Returns default application-wide style.
Definition: qgsstyle.cpp:127
QgsStyle::labelSettingsCount
int labelSettingsCount() const
Returns count of label settings in the style.
Definition: qgsstyle.cpp:2170
qgsapplication.h
QgsStyle::symbol3D
QgsAbstract3DSymbol * symbol3D(const QString &name) const
Returns a new copy of the 3D symbol with the specified name.
Definition: qgsstyle.cpp:2144
QgsStyle::symbol3DCompatibleGeometryTypes
QList< QgsWkbTypes::GeometryType > symbol3DCompatibleGeometryTypes(const QString &name) const
Returns the list of the vector layer geometry types which are compatible with the 3D symbol with the ...
Definition: qgsstyle.cpp:2154
LegendPatchTable
LegendPatchTable
Columns available in the legend patch table.
Definition: qgsstyle.cpp:52
Symbol3DTableXML
@ Symbol3DTableXML
3d symbol definition (as XML)
Definition: qgsstyle.cpp:66
QgsStyle::detagSymbol
bool detagSymbol(StyleEntity type, const QString &symbol, const QStringList &tags)
Detags the symbol with the given list.
Definition: qgsstyle.cpp:1799
QgsStyle::symbolsOfSmartgroup
QStringList symbolsOfSmartgroup(StyleEntity type, int id)
Returns the symbols for the smartgroup.
Definition: qgsstyle.cpp:2351
ColorrampName
@ ColorrampName
Color ramp name.
Definition: qgsstyle.h:118
QgsTextFormat
Container for all settings relating to text rendering.
Definition: qgstextformat.h:40
QgsAbstract3DSymbol
3 Abstract base class for 3D symbols that are used by VectorLayer3DRenderer objects.
Definition: qgsabstract3dsymbol.h:46
QgsStyle::textFormatId
int textFormatId(const QString &name)
Returns the ID in the style database for the given text format by name.
Definition: qgsstyle.cpp:2116
QgsStyle::addSmartgroup
int addSmartgroup(const QString &name, const QString &op, const QgsSmartConditionMap &conditions)
Adds a new smartgroup to the database and returns the id.
Definition: qgsstyle.cpp:2250
STYLE_CURRENT_VERSION
#define STYLE_CURRENT_VERSION
Definition: qgsstyle.cpp:46
QgsStyle::addSymbol
bool addSymbol(const QString &name, QgsSymbol *symbol, bool update=false)
Adds a symbol to style and takes symbol's ownership.
Definition: qgsstyle.cpp:177
QgsStyleSymbol3DEntity
A 3d symbol entity for QgsStyle databases.
Definition: qgsstyle.h:1354
QgsStyle::addLegendPatchShape
bool addLegendPatchShape(const QString &name, const QgsLegendPatchShape &shape, bool update=false)
Adds a legend patch shape with the specified name to the style.
Definition: qgsstyle.cpp:357
QgsStyle::textFormatCount
int textFormatCount() const
Returns count of text formats in the style.
Definition: qgsstyle.cpp:2106
QgsStyle::renameLegendPatchShape
bool renameLegendPatchShape(const QString &oldName, const QString &newName)
Changes a legend patch shape's name.
Definition: qgsstyle.cpp:1125
QgsStyle::Symbol3DEntity
@ Symbol3DEntity
3D symbol entity (since QGIS 3.14)
Definition: qgsstyle.h:187
QgsStyle::exportXml
bool exportXml(const QString &filename)
Exports the style as a XML file.
Definition: qgsstyle.cpp:2513
QgsStyleSymbol3DEntity::type
QgsStyle::StyleEntity type() const override
Returns the type of style entity.
Definition: qgsstyle.cpp:3377
LabelSettingsName
@ LabelSettingsName
Label settings name.
Definition: qgsstyle.h:140
qgscolorramp.h
QgsStyle::removeFavorite
bool removeFavorite(StyleEntity type, const QString &name)
Removes the specified symbol from favorites.
Definition: qgsstyle.cpp:1643
QgsStyle::importXml
bool importXml(const QString &filename)
Imports the symbols and colorramps into the default style database from the given XML file.
Definition: qgsstyle.cpp:2675
QgsStyle::clear
void clear()
Removes all contents of the style.
Definition: qgsstyle.cpp:162
QgsStyle::tag
QString tag(int id) const
Returns the tag name for the given id.
Definition: qgsstyle.cpp:2021
QgsStyle::colorrampId
int colorrampId(const QString &name)
Returns the id in the style database for the given colorramp name returns 0 if not found.
Definition: qgsstyle.cpp:2096
qgssymbollayerregistry.h
QgsSymbolLayerUtils::saveColorRamp
static QDomElement saveColorRamp(const QString &name, QgsColorRamp *ramp, QDomDocument &doc)
Encodes a color ramp's settings to an XML element.
Definition: qgssymbollayerutils.cpp:3112
QgsStyle::entityTagsChanged
void entityTagsChanged(QgsStyle::StyleEntity entity, const QString &name, const QStringList &newTags)
Emitted whenever an entity's tags are changed.
QgsStyle::addEntity
bool addEntity(const QString &name, const QgsStyleEntityInterface *entity, bool update=false)
Adds an entity to the style, with the specified name.
Definition: qgsstyle.cpp:93
QgsStyle::textFormatChanged
void textFormatChanged(const QString &name)
Emitted whenever a text format's definition is changed.
QgsStyle::smartgroupNames
QStringList smartgroupNames() const
Returns the smart groups list.
Definition: qgsstyle.cpp:2327
QgsStyle::previewSymbolForPatchShape
const QgsSymbol * previewSymbolForPatchShape(const QgsLegendPatchShape &shape) const
Returns a symbol to use for rendering preview icons for a patch shape.
Definition: qgsstyle.cpp:2190
QgsStyle::tags
QStringList tags() const
Returns a list of all tags in the style database.
Definition: qgsstyle.cpp:1382
QgsSimpleMarkerSymbolLayerBase::Circle
@ Circle
Circle.
Definition: qgsmarkersymbollayer.h:58
QgsStyle::cleanDefaultStyle
static void cleanDefaultStyle()
Deletes the default style. Only to be used by QgsApplication::exitQgis()
Definition: qgsstyle.cpp:156
QgsStyleEntityInterface::type
virtual QgsStyle::StyleEntity type() const =0
Returns the type of style entity.
QgsStyleTextFormatEntity
A text format entity for QgsStyle databases.
Definition: qgsstyle.h:1264
QgsStyle::SmartgroupEntity
@ SmartgroupEntity
Smart groups.
Definition: qgsstyle.h:183
Symbol3DTableFavoriteId
@ Symbol3DTableFavoriteId
3d symbol is favorite flag
Definition: qgsstyle.cpp:67
LegendPatchTableName
@ LegendPatchTableName
Legend patch name.
Definition: qgsstyle.cpp:54
QgsStyle::createTables
void createTables()
Creates tables structure for new database.
Definition: qgsstyle.cpp:522
QgsStyle::smartgroupsListMap
QgsSymbolGroupMap smartgroupsListMap()
Returns the smart groups map with id as key and name as value.
Definition: qgsstyle.cpp:2302
QgsSymbolLayerUtils::loadSymbol
static QgsSymbol * loadSymbol(const QDomElement &element, const QgsReadWriteContext &context)
Attempts to load a symbol from a DOM element.
Definition: qgssymbollayerutils.cpp:1043
QgsStyle::groupsModified
void groupsModified()
Emitted every time a tag or smartgroup has been added, removed, or renamed.
qgslegendpatchshape.h
QgsSymbol::Fill
@ Fill
Fill symbol.
Definition: qgssymbol.h:89
QgsTextFormat::readXml
void readXml(const QDomElement &elem, const QgsReadWriteContext &context)
Read settings from a DOM element.
Definition: qgstextformat.cpp:406
QgsSettings::setValue
void setValue(const QString &key, const QVariant &value, QgsSettings::Section section=QgsSettings::NoSection)
Sets the value of setting key to value.
Definition: qgssettings.cpp:289
qgsfillsymbollayer.h
QgsStyle::entityChanged
void entityChanged(QgsStyle::StyleEntity entity, const QString &name)
Emitted whenever an entity's definition is changed.
QgsApplication::userStylePath
static QString userStylePath()
Returns the path to user's style.
Definition: qgsapplication.cpp:1087
Symbol3DTable
Symbol3DTable
Columns available in the 3d symbol table.
Definition: qgsstyle.cpp:63
QgsStyle::removeLabelSettings
bool removeLabelSettings(const QString &name)
Removes label settings from the style.
Definition: qgsstyle.cpp:1057
QgsStyle::rampAdded
void rampAdded(const QString &name)
Emitted whenever a color ramp has been added to the style and the database has been updated as a resu...
QgsStyleLabelSettingsEntity
A label settings entity for QgsStyle databases.
Definition: qgsstyle.h:1294
QgsStyle::symbolCount
int symbolCount()
Returns count of symbols in style.
Definition: qgsstyle.cpp:280
QgsColorRamp::clone
virtual QgsColorRamp * clone() const =0
Creates a clone of the color ramp.
qgsstyle.h
QgsSymbolLayerUtils::loadColorRamp
static QgsColorRamp * loadColorRamp(QDomElement &element)
Creates a color ramp from the settings encoded in an XML element.
Definition: qgssymbollayerutils.cpp:3087
QgsStyle::renameSymbol3D
bool renameSymbol3D(const QString &oldName, const QString &newName)
Changes a 3d symbol's name.
Definition: qgsstyle.cpp:1243
QgsStyle::symbolId
int symbolId(const QString &name)
Returns the id in the style database for the given symbol name returns 0 if not found.
Definition: qgsstyle.cpp:2086
QgsStyle::symbolNames
QStringList symbolNames() const
Returns a list of names of symbols.
Definition: qgsstyle.cpp:285
sqlite3_statement_unique_ptr::columnAsText
QString columnAsText(int column) const
Returns the column value from the current statement row as a string.
Definition: qgssqliteutils.cpp:61
QgsStyleLegendPatchShapeEntity::type
QgsStyle::StyleEntity type() const override
Returns the type of style entity.
Definition: qgsstyle.cpp:3372
QgsPalLayerSettings::writeXml
QDomElement writeXml(QDomDocument &doc, const QgsReadWriteContext &context) const
Write settings into a DOM element.
Definition: qgspallabeling.cpp:1144
QgsStyle::allNames
QStringList allNames(StyleEntity type) const
Returns a list of the names of all existing entities of the specified type.
Definition: qgsstyle.cpp:2219
QgsSymbol::clone
virtual QgsSymbol * clone() const =0
Returns a deep copy of this symbol.
QgsStyle::smartgroup
QgsSmartConditionMap smartgroup(int id)
Returns the QgsSmartConditionMap for the given id.
Definition: qgsstyle.cpp:2443
QgsStyle::removeSymbol
bool removeSymbol(const QString &name)
Removes symbol from style (and delete it)
Definition: qgsstyle.cpp:235
QgsStyle::smartgroupId
int smartgroupId(const QString &smartgroup)
Returns the database id for the given smartgroup name.
Definition: qgsstyle.cpp:2214
QgsStyle::removeColorRamp
bool removeColorRamp(const QString &name)
Removes color ramp from style (and delete it)
Definition: qgsstyle.cpp:433
QgsStyle::legendPatchShape
QgsLegendPatchShape legendPatchShape(const QString &name) const
Returns the legend patch shape with the specified name.
Definition: qgsstyle.cpp:2126
QgsStyle::defaultPatchAsQPolygonF
QList< QList< QPolygonF > > defaultPatchAsQPolygonF(QgsSymbol::SymbolType type, QSizeF size) const
Returns the default patch geometry for the given symbol type and size as a set of QPolygonF objects (...
Definition: qgsstyle.cpp:1201
QgsStyle::textFormatNames
QStringList textFormatNames() const
Returns a list of names of text formats in the style.
Definition: qgsstyle.cpp:2111
qgslinesymbollayer.h
QgsStyle::rampRenamed
void rampRenamed(const QString &oldName, const QString &newName)
Emitted whenever a color ramp has been renamed from oldName to newName.
QgsWkbTypes::GeometryType
GeometryType
The geometry types are used to group QgsWkbTypes::Type in a coarse way.
Definition: qgswkbtypes.h:141
QgsGeometry
A geometry is the spatial representation of a feature.
Definition: qgsgeometry.h:124
QgsStyle::rename
bool rename(StyleEntity type, int id, const QString &newName)
Renames the given entity with the specified id.
Definition: qgsstyle.cpp:1402
QgsStyle
Definition: qgsstyle.h:160
QgsStyle::TextFormatEntity
@ TextFormatEntity
Text formats.
Definition: qgsstyle.h:184
QgsSymbolLayerUtils::saveSymbols
static QDomElement saveSymbols(QgsSymbolMap &symbols, const QString &tagName, QDomDocument &doc, const QgsReadWriteContext &context)
Writes a collection of symbols to XML with specified tagName for the top-level element.
Definition: qgssymbollayerutils.cpp:3024
TextFormatName
@ TextFormatName
Text format name.
Definition: qgsstyle.h:129
QgsStyleTextFormatEntity::type
QgsStyle::StyleEntity type() const override
Returns the type of style entity.
Definition: qgsstyle.cpp:3362
QgsSymbolLayerList
QList< QgsSymbolLayer * > QgsSymbolLayerList
Definition: qgssymbol.h:53
QgsSymbolGroupMap
QMap< int, QString > QgsSymbolGroupMap
Definition: qgsstyle.h:42
QgsStyle::symbolSaved
void symbolSaved(const QString &name, QgsSymbol *symbol)
Emitted every time a new symbol has been added to the database.
QgsScopedRuntimeProfile
Scoped object for logging of the runtime for a single operation or group of operations.
Definition: qgsruntimeprofiler.h:328
qgssettings.h
QgsStyle::colorRampCount
int colorRampCount()
Returns count of color ramps.
Definition: qgsstyle.cpp:449
SymbolXML
@ SymbolXML
Symbol definition (as XML)
Definition: qgsstyle.h:90
QgsStyle::smartgroupOperator
QString smartgroupOperator(int id)
Returns the operator for the smartgroup.
Definition: qgsstyle.cpp:2483
QgsStyle::labelSettingsRenamed
void labelSettingsRenamed(const QString &oldName, const QString &newName)
Emitted whenever label settings have been renamed from oldName to newName.
QgsStyle::legendPatchShapesCount
int legendPatchShapesCount() const
Returns count of legend patch shapes in the style.
Definition: qgsstyle.cpp:2131
QgsSymbol::Line
@ Line
Line symbol.
Definition: qgssymbol.h:88
QgsWkbTypes::UnknownGeometry
@ UnknownGeometry
Definition: qgswkbtypes.h:145
QgsStyle::labelSettingsAdded
void labelSettingsAdded(const QString &name)
Emitted whenever label settings have been added to the style and the database has been updated as a r...
LegendPatchTableXML
@ LegendPatchTableXML
Legend patch definition (as XML)
Definition: qgsstyle.cpp:55
QgsSymbol::type
SymbolType type() const
Returns the symbol's type.
Definition: qgssymbol.h:122
QgsSymbol::Marker
@ Marker
Marker symbol.
Definition: qgssymbol.h:87
SymbolName
@ SymbolName
Symbol Name.
Definition: qgsstyle.h:89
QgsStyle::symbolRenamed
void symbolRenamed(const QString &oldName, const QString &newName)
Emitted whenever a symbol has been renamed from oldName to newName.
qgssqliteutils.h
QgsStyle::addLabelSettings
bool addLabelSettings(const QString &name, const QgsPalLayerSettings &settings, bool update=false)
Adds label settings with the specified name to the style.
Definition: qgsstyle.cpp:336
QgsStyle::saveSymbol
bool saveSymbol(const QString &name, QgsSymbol *symbol, bool favorite, const QStringList &tags)
Adds the symbol to the database with tags.
Definition: qgsstyle.cpp:201
QgsStyle::entityRenamed
void entityRenamed(QgsStyle::StyleEntity entity, const QString &oldName, const QString &newName)
Emitted whenever a entity of the specified type has been renamed from oldName to newName.
QgsStyle::colorRampNames
QStringList colorRampNames() const
Returns a list of names of color ramps.
Definition: qgsstyle.cpp:454
LabelSettingsXML
@ LabelSettingsXML
Label settings definition (as XML)
Definition: qgsstyle.h:141
QgsStyle::rampRemoved
void rampRemoved(const QString &name)
Emitted whenever a color ramp has been removed from the style and the database has been updated as a ...
QgsStyle::legendPatchShapeSymbolType
QgsSymbol::SymbolType legendPatchShapeSymbolType(const QString &name) const
Returns the symbol type corresponding to the legend patch shape with the specified name,...
Definition: qgsstyle.cpp:2136
QgsStyleLegendPatchShapeEntity
A legend patch shape entity for QgsStyle databases.
Definition: qgsstyle.h:1324
QgsSymbol::SymbolType
SymbolType
Type of the symbol.
Definition: qgssymbol.h:86
QgsStyleLabelSettingsEntity::type
QgsStyle::StyleEntity type() const override
Returns the type of style entity.
Definition: qgsstyle.cpp:3367
QgsStyle::remove
bool remove(StyleEntity type, int id)
Removes the specified entity from the database.
Definition: qgsstyle.cpp:1437
QgsStyle::rampChanged
void rampChanged(const QString &name)
Emitted whenever a color ramp's definition is changed.
QgsSymbol::Hybrid
@ Hybrid
Hybrid symbol.
Definition: qgssymbol.h:90
qgslogger.h
QgsStyle::saveLegendPatchShape
bool saveLegendPatchShape(const QString &name, const QgsLegendPatchShape &shape, bool favorite, const QStringList &tags)
Adds a legend patch shape to the database.
Definition: qgsstyle.cpp:1097
QgsStyle::legendPatchShapeNames
QStringList legendPatchShapeNames() const
Returns a list of names of legend patch shapes in the style.
Definition: qgsstyle.cpp:2185
QgsSymbol::ScaleArea
@ ScaleArea
Calculate scale by the area.
Definition: qgssymbol.h:98
QgsStyle::tagsOfSymbol
QStringList tagsOfSymbol(StyleEntity type, const QString &symbol)
Returns the tags associated with the symbol.
Definition: qgsstyle.cpp:1892
QgsStyle::symbolHasTag
bool symbolHasTag(StyleEntity type, const QString &symbol, const QString &tag)
Returns whether a given tag is associated with the symbol.
Definition: qgsstyle.cpp:1981
LegendPatchTableFavoriteId
@ LegendPatchTableFavoriteId
Legend patch is favorite flag.
Definition: qgsstyle.cpp:56
SmartgroupName
@ SmartgroupName
Smart group name.
Definition: qgsstyle.h:151
QgsStyle::textFormatRemoved
void textFormatRemoved(const QString &name)
Emitted whenever a text format has been removed from the style and the database has been updated as a...
QgsStyle::removeTextFormat
bool removeTextFormat(const QString &name)
Removes a text format from the style.
Definition: qgsstyle.cpp:983
QgsStyle::isFavorite
bool isFavorite(StyleEntity type, const QString &name)
Returns true if the symbol with matching type and name is marked as a favorite.
Definition: qgsstyle.cpp:1943
QgsStyle::addTextFormat
bool addTextFormat(const QString &name, const QgsTextFormat &format, bool update=false)
Adds a text format with the specified name to the style.
Definition: qgsstyle.cpp:315
QgsStyle::symbolsWithTag
QStringList symbolsWithTag(StyleEntity type, int tagid) const
Returns the symbol names with which have the given tag.
Definition: qgsstyle.cpp:1316
QgsStyle::QgsStyle
QgsStyle()
Constructor for QgsStyle.
Definition: qgsstyle.cpp:73
QgsLegendPatchShape::writeXml
void writeXml(QDomElement &element, QDomDocument &doc, const QgsReadWriteContext &context) const
Write settings into a DOM element.
Definition: qgslegendpatchshape.cpp:200
QgsStyle::labelSettings
QgsPalLayerSettings labelSettings(const QString &name) const
Returns the label settings with the specified name.
Definition: qgsstyle.cpp:2121
QgsStyle::~QgsStyle
~QgsStyle() override
Definition: qgsstyle.cpp:88
QgsStyle::symbolRef
const QgsSymbol * symbolRef(const QString &name) const
Returns a const pointer to a symbol (doesn't create new instance)
Definition: qgsstyle.cpp:275
LegendPatchTableId
@ LegendPatchTableId
Legend patch ID.
Definition: qgsstyle.cpp:53
Qgis::versionInt
static int versionInt()
Version number used for comparing versions using the "Check QGIS Version" function.
Definition: qgis.cpp:281
QgsSmartConditionMap
QMultiMap< QString, QString > QgsSmartConditionMap
A multimap to hold the smart group conditions as constraint and parameter pairs.
Definition: qgsstyle.h:79
QgsTextFormat::writeXml
QDomElement writeXml(QDomDocument &doc, const QgsReadWriteContext &context) const
Write settings into a DOM element.
Definition: qgstextformat.cpp:555
QgsStyle::renameLabelSettings
bool renameLabelSettings(const QString &oldName, const QString &newName)
Changes a label setting's name.
Definition: qgsstyle.cpp:1062
qgssymbol.h
QgsStyle::renameSymbol
bool renameSymbol(const QString &oldName, const QString &newName)
Renames a symbol from oldName to newName.
Definition: qgsstyle.cpp:874
QgsSymbolLayerUtils::saveSymbol
static QDomElement saveSymbol(const QString &symbolName, const QgsSymbol *symbol, QDomDocument &doc, const QgsReadWriteContext &context)
Writes a symbol definition to XML.
Definition: qgssymbollayerutils.cpp:1182
QgsStyle::saveLabelSettings
bool saveLabelSettings(const QString &name, const QgsPalLayerSettings &settings, bool favorite, const QStringList &tags)
Adds label settings to the database.
Definition: qgsstyle.cpp:1023
QgsStyle::save
bool save(QString filename=QString())
Saves style into a file (will use current filename if empty string is passed)
Definition: qgsstyle.cpp:828
QgsStyle::colorRamp
QgsColorRamp * colorRamp(const QString &name) const
Returns a new copy of the specified color ramp.
Definition: qgsstyle.cpp:438
QgsLegendPatchShape::readXml
void readXml(const QDomElement &element, const QgsReadWriteContext &context)
Read settings from a DOM element.
Definition: qgslegendpatchshape.cpp:193
sqlite3_statement_unique_ptr
Unique pointer for sqlite3 prepared statements, which automatically finalizes the statement when the ...
Definition: qgssqliteutils.h:70
QgsStyle::tagId
int tagId(const QString &tag)
Returns the database id for the given tag name.
Definition: qgsstyle.cpp:2209
QgsStyle::symbolRemoved
void symbolRemoved(const QString &name)
Emitted whenever a symbol has been removed from the style and the database has been updated as a resu...
QgsStyle::StyleEntity
StyleEntity
Enum for Entities involved in a style.
Definition: qgsstyle.h:179
QgsStyle::saveSymbol3D
bool saveSymbol3D(const QString &name, QgsAbstract3DSymbol *symbol, bool favorite, const QStringList &tags)
Adds a 3d symbol to the database.
Definition: qgsstyle.cpp:1214
QgsStyle::addTag
int addTag(const QString &tagName)
Adds a new tag and returns the tag's id.
Definition: qgsstyle.cpp:1362
|
{
"url": "https://api.qgis.org/api/3.16/qgsstyle_8cpp_source.html",
"source_domain": "api.qgis.org",
"snapshot_id": "CC-MAIN-2024-30",
"warc_metadata": {
"Content-Length": "662592",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:CMVAMG2WQOIYBEJDBGS2LUQUS24RK4AH",
"WARC-Concurrent-To": "<urn:uuid:aba3d8c4-d7a8-40c7-a9ab-8092637d10b4>",
"WARC-Date": "2024-07-23T22:06:58Z",
"WARC-IP-Address": "172.67.143.23",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:YB65UL633SEGU5OJN7NLPWHRTDPBGX57",
"WARC-Record-ID": "<urn:uuid:31711276-9d57-4100-808f-24223487df26>",
"WARC-Target-URI": "https://api.qgis.org/api/3.16/qgsstyle_8cpp_source.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:acff09b3-4197-4050-97af-ae130b1d6595>"
},
"warc_info": "isPartOf: CC-MAIN-2024-30\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July 2024\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-67-67-173\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,
53,
66,
104,
183,
199,
224,
249,
290,
332,
411,
418,
494,
571,
645,
689,
697,
778,
782,
807,
811,
837,
866,
905,
936,
962,
998,
1026,
1062,
1092,
1119,
1156,
1191,
1226,
1261,
1297,
1333,
1337,
1364,
1390,
1413,
1440,
1460,
1486,
1511,
1515,
1539,
1570,
1574,
1611,
1615,
1620,
1626,
1630,
1635,
1641,
1645,
1649,
1697,
1701,
1706,
1860,
1942,
1983,
2096,
2100,
2238,
2345,
2349,
2511,
2653,
2789,
2794,
2798,
2803,
2816,
2821,
2825,
2928,
2933,
2963,
2969,
2992,
3068,
3086,
3199,
3204,
3231,
3309,
3328,
3445,
3450,
3478,
3590,
3595,
3626,
3746,
3751,
3874,
3879,
3905,
4022,
4027,
4048,
4076,
4088,
4093,
4100,
4119,
4125,
4130,
4136,
4163,
4170,
4247,
4309,
4314,
4369,
4413,
4420,
4455,
4508,
4572,
4579,
4648,
4655,
4662,
4672,
4679,
4714,
4763,
4770,
4811,
4818,
4825,
4832,
4859,
4865,
4870,
4876,
4903,
4933,
4939,
4944,
4950,
4979,
5011,
5042,
5047,
5070,
5096,
5123,
5148,
5153,
5179,
5210,
5216,
5221,
5305,
5311,
5349,
5368,
5373,
5413,
5451,
5458,
5495,
5531,
5569,
5588,
5629,
5636,
5646,
5653,
5691,
5710,
5765,
5772,
5777,
5795,
5801,
5806,
5918,
5924,
5960,
6012,
6114,
6141,
6148,
6227,
6246,
6253,
6258,
6284,
6322,
6355,
6385,
6480,
6558,
6563,
6599,
6606,
6689,
6708,
6715,
6720,
6784,
6789,
6833,
6838,
6877,
6922,
6927,
6945,
6951,
6956,
7011,
7017,
7071,
7077,
7082,
7192,
7198,
7219,
7226,
7250,
7296,
7301,
7328,
7377,
7382,
7410,
7460,
7465,
7496,
7549,
7554,
7610,
7615,
7641,
7689,
7694,
7715,
7743,
7762,
7769,
7788,
7794,
7799,
7854,
7860,
7910,
7958,
7964,
7969,
8039,
8045,
8081,
8087,
8092,
8098,
8128,
8134,
8139,
8185,
8191,
8220,
8226,
8231,
8236,
8329,
8335,
8376,
8395,
8400,
8445,
8486,
8493,
8530,
8569,
8613,
8632,
8676,
8683,
8693,
8700,
8744,
8763,
8824,
8831,
8836,
8854,
8860,
8865,
8963,
8969,
9014,
9056,
9063,
9100,
9134,
9176,
9195,
9240,
9247,
9257,
9264,
9306,
9325,
9384,
9391,
9396,
9414,
9420,
9425,
9534,
9540,
9588,
9632,
9639,
9676,
9712,
9758,
9777,
9825,
9832,
9842,
9849,
9895,
9914,
9978,
9985,
9990,
10008,
10014,
10019,
10128,
10134,
10186,
10234,
10241,
10278,
10318,
10365,
10384,
10435,
10442,
10452,
10459,
10506,
10525,
10589,
10596,
10601,
10619,
10625,
10630,
10726,
10732,
10772,
10812,
10819,
10856,
10893,
10933,
10952,
10995,
11002,
11012,
11019,
11059,
11078,
11135,
11142,
11147,
11165,
11171,
11176,
11292,
11298,
11334,
11386,
11467,
11472,
11500,
11507,
11590,
11609,
11616,
11621,
11647,
11685,
11718,
11749,
11847,
11925,
11961,
11968,
12054,
12073,
12080,
12085,
12152,
12157,
12204,
12209,
12238,
12286,
12291,
12309,
12315,
12320,
12378,
12384,
12441,
12447,
12452,
12519,
12525,
12579,
12623,
12629,
12634,
12710,
12716,
12755,
12761,
12766,
12772,
12805,
12811,
12816,
12865,
12871,
12903,
12909,
12914,
12966,
12972,
13084,
13091,
13173,
13291,
13310,
13317,
13376,
13431,
13482,
13489,
13499,
13506,
13563,
13578,
13585,
13592,
13632,
13638,
13643,
13702,
13708,
13751,
13766,
13773,
13884,
13903,
13910,
13915,
13933,
13939,
13944,
14005,
14011,
14038,
14076,
14083,
14150,
14184,
14203,
14210,
14215,
14236,
14241,
14259,
14265,
14270,
14276,
14303,
14361,
14368,
14452,
14486,
14505,
14512,
14517,
14538,
14543,
14561,
14567,
14572,
14578,
14644,
14676,
14702,
14720,
14747,
14779,
14811,
14837,
14855,
14882,
14915,
14947,
14973,
14991,
15018,
15054,
15086,
15112,
15130,
15157,
15197,
15229,
15255,
15273,
15300,
15331,
15363,
15389,
15407,
15434,
15460,
15492,
15512,
15541,
15574,
15602,
15632,
15665,
15696,
15727,
15760,
15792,
15823,
15856,
15891,
15923,
15956,
15994,
16031,
16064,
16094,
16127,
16159,
16178,
16199,
16228,
16234,
16239,
16290,
16296,
16323,
16328,
16361,
16399,
16406,
16486,
16520,
16539,
16546,
16551,
16594,
16696,
16709,
16759,
16836,
16843,
16905,
16937,
16963,
16981,
17008,
17039,
17072,
17106,
17135,
17142,
17188,
17285,
17335,
17412,
17419,
17484,
17516,
17542,
17560,
17587,
17618,
17651,
17688,
17717,
17724,
17774,
17875,
17925,
18002,
18009,
18078,
18110,
18136,
18154,
18181,
18213,
18246,
18286,
18315,
18322,
18363,
18455,
18505,
18582,
18589,
18649,
18681,
18707,
18725,
18752,
18789,
18822,
18854,
18883,
18890,
18895,
18970,
19059,
19122,
19186,
19253,
19324,
19386,
19394,
19423,
19428,
19435,
19497,
19539,
19599,
19649,
19654,
19734,
19741,
19764,
19828,
19880,
19942,
19983,
19990,
20046,
20061,
20068,
20073,
20126,
20145,
20189,
20196,
20203,
20208,
20215,
20281,
20344,
20394,
20474,
20481,
20504,
20575,
20625,
20690,
20731,
20738,
20792,
20807,
20814,
20868,
20945,
20962,
21005,
21012,
21019,
21024,
21031,
21098,
21162,
21212,
21292,
21299,
21322,
21396,
21448,
21520,
21561,
21568,
21629,
21644,
21651,
21707,
21734,
21795,
21843,
21850,
21857,
21862,
21869,
21938,
22005,
22055,
22135,
22142,
22165,
22244,
22298,
22373,
22414,
22421,
22487,
22502,
22509,
22567,
22602,
22667,
22721,
22728,
22735,
22740,
22747,
22821,
22892,
22942,
23022,
23029,
23052,
23134,
23188,
23266,
23307,
23314,
23384,
23399,
23406,
23464,
23496,
23558,
23613,
23620,
23627,
23632,
23639,
23711,
23773,
23823,
23828,
23926,
23931,
24011,
24018,
24041,
24120,
24174,
24249,
24290,
24297,
24358,
24373,
24380,
24438,
24443,
24476,
24483,
24555,
24562,
24572,
24579,
24666,
24784,
24803,
24810,
24874,
24932,
24939,
24949,
24956,
25017,
25032,
25039,
25046,
25053,
25060,
25065,
25092,
25110,
25116,
25121,
25126,
25131,
25175,
25181,
25208,
25213,
25244,
25271,
25276,
25369,
25443,
25453,
25492,
25551,
25611,
25641,
25646,
25739,
25744,
25808,
25813,
25838,
25950,
25957,
26050,
26088,
26095,
26100,
26138,
26174,
26179,
26192,
26218,
26258,
26265,
26332,
26351,
26358,
26385,
26414,
26438,
26454,
26465,
26470,
26497,
26515,
26521,
26526,
26608,
26614,
26655,
26662,
26737,
26756,
26763,
26768,
26819,
26839,
26858,
26863,
26904,
26909,
26933,
26940,
27017,
27036,
27043,
27048,
27089,
27111,
27118,
27210,
27229,
27236,
27241,
27293,
27350,
27355,
27423,
27442,
27449,
27494,
27553,
27560,
27565,
27585,
27591,
27596,
27681,
27687,
27731,
27738,
27818,
27837,
27844,
27849,
27904,
27922,
27941,
27946,
27988,
28043,
28103,
28108,
28129,
28247,
28262,
28314,
28393,
28400,
28456,
28463,
28532,
28551,
28558,
28601,
28663,
28670,
28675,
28695,
28701,
28706,
28832,
28838,
28874,
28926,
29003,
29008,
29040,
29047,
29131,
29150,
29157,
29162,
29188,
29226,
29259,
29294,
29393,
29471,
29507,
29514,
29602,
29621,
29628,
29633,
29701,
29706,
29754,
29759,
29794,
29843,
29848,
29866,
29872,
29877,
29936,
29942,
30000,
30006,
30011,
30097,
30103,
30148,
30155,
30236,
30255,
30262,
30267,
30313,
30332,
30390,
30395,
30441,
30498,
30560,
30566,
30594,
30640,
30760,
30776,
30829,
30909,
30917,
30980,
30988,
31065,
31085,
31093,
31143,
31207,
31215,
31221,
31242,
31249,
31255,
31393,
31400,
31437,
31490,
31572,
31578,
31613,
31621,
31709,
31729,
31737,
31743,
31770,
31809,
31843,
31881,
31984,
32063,
32100,
32108,
32200,
32220,
32228,
32234,
32306,
32312,
32318,
32357,
32410,
32416,
32435,
32442,
32448,
32511,
32518,
32580,
32587,
32593,
32683,
32690,
32738,
32746,
32831,
32851,
32859,
32865,
32914,
32934,
33003,
33009,
33059,
33119,
33184,
33190,
33221,
33267,
33390,
33406,
33459,
33539,
33547,
33613,
33621,
33704,
33724,
33732,
33785,
33852,
33860,
33866,
33887,
33894,
33900,
34038,
34045,
34082,
34135,
34213,
34276,
34282,
34309,
34348,
34382,
34417,
34524,
34603,
34640,
34648,
34744,
34764,
34772,
34778,
34853,
34859,
34865,
34921,
34927,
34946,
34953,
34959,
35052,
35059,
35111,
35119,
35208,
35228,
35236,
35242,
35295,
35315,
35385,
35391,
35442,
35505,
35573,
35579,
35610,
35656,
35783,
35799,
35852,
35932,
35940,
36006,
36014,
36100,
36120,
36128,
36198,
36206,
36212,
36233,
36240,
36246,
36253,
36292,
36328,
36334,
36391,
36446,
36452,
36476,
36498,
36506,
36536,
36678,
36691,
36697,
36725,
36733,
36790,
36870,
36934,
37042,
37087,
37100,
37108,
37114,
37142,
37150,
37209,
37346,
37506,
37519,
37527,
37533,
37563,
37576,
37584,
37590,
37664,
37711,
37729,
37736,
37742,
37855,
37862,
37901,
37942,
37948,
38014,
38078,
38084,
38175,
38231,
38249,
38256,
38262,
38387,
38394,
38431,
38484,
38558,
38627,
38682,
38688,
38715,
38754,
38788,
38818,
38916,
38995,
39032,
39040,
39127,
39147,
39155,
39161,
39228,
39234,
39281,
39287,
39335,
39341,
39360,
39367,
39373,
39458,
39465,
39509,
39517,
39597,
39617,
39625,
39631,
39676,
39696,
39760,
39766,
39810,
39864,
39924,
39930,
39961,
40007,
40125,
40141,
40194,
40274,
40282,
40348,
40356,
40434,
40454,
40462,
40524,
40532,
40538,
40559,
40566,
40572,
40621,
40628,
40660,
40667,
40673,
40744,
40751,
40776,
40784,
40876,
40904,
40912,
40918,
40939,
40961,
40969,
40991,
41020,
41083,
41111,
41117,
41132,
41279,
41292,
41300,
41306,
41322,
41368,
41421,
41427,
41454,
41537,
41545,
41591,
41599,
41605,
41627,
41634,
41640,
41719,
41726,
41751,
41759,
41862,
41890,
41898,
41904,
41928,
41950,
41958,
41980,
42009,
42066,
42094,
42100,
42115,
42245,
42308,
42321,
42329,
42335,
42351,
42397,
42453,
42459,
42525,
42552,
42635,
42643,
42700,
42706,
42866,
42872,
42886,
42933,
42985,
43067,
43075,
43122,
43130,
43138,
43144,
43166,
43173,
43179,
43231,
43238,
43263,
43279,
43325,
43331,
43445,
43461,
43514,
43545,
43592,
43598,
43626,
43705,
43711,
43740,
43746,
43828,
43835,
43841,
43881,
43888,
43913,
43941,
43947,
43993,
43999,
44068,
44086,
44141,
44147,
44174,
44259,
44267,
44313,
44321,
44327,
44349,
44356,
44362,
44441,
44448,
44642,
44648,
44698,
44719,
44727,
44787,
44795,
44806,
44814,
44841,
44873,
44879,
44901,
44909,
44931,
44939,
44968,
44981,
44989,
44995,
45024,
45032,
45061,
45074,
45082,
45088,
45103,
45116,
45124,
45132,
45153,
45160,
45166,
45221,
45228,
45261,
45282,
45304,
45312,
45334,
45446,
45473,
45486,
45515,
45594,
45621,
45634,
45640,
45655,
45770,
45801,
45832,
45870,
45910,
45923,
45931,
45937,
45964,
46001,
46009,
46076,
46084,
46095,
46103,
46130,
46162,
46168,
46194,
46202,
46230,
46309,
46315,
46344,
46352,
46373,
46381,
46402,
46409,
46415,
46505,
46512,
46534,
46542,
46574,
46594,
46600,
46608,
46676,
46697,
46717,
46723,
46736,
46744,
46750,
46758,
46838,
46859,
46879,
46885,
46898,
46906,
46912,
46920,
46992,
47011,
47031,
47044,
47052,
47058,
47066,
47110,
47130,
47136,
47171,
47184,
47192,
47198,
47206,
47252,
47272,
47278,
47315,
47328,
47336,
47342,
47350,
47400,
47420,
47426,
47467,
47480,
47488,
47496,
47502,
47527,
47535,
47616,
47636,
47644,
47650,
47695,
47712,
47720,
47797,
47805,
47811,
47857,
47877,
47885,
47927,
47974,
47980,
48002,
48010,
48035,
48069,
48082,
48088,
48116,
48148,
48161,
48167,
48196,
48234,
48247,
48253,
48285,
48326,
48339,
48345,
48360,
48454,
48467,
48475,
48515,
48523,
48544,
48551,
48557,
48615,
48622,
48647,
48667,
48673,
48701,
48805,
48811,
48842,
48850,
48877,
48905,
48913,
48919,
48951,
48958,
48964,
49037,
49044,
49065,
49071,
49093,
49101,
49123,
49152,
49233,
49253,
49259,
49274,
49423,
49458,
49471,
49479,
49485,
49532,
49549,
49557,
49579,
49587,
49609,
49638,
49651,
49657,
49672,
49725,
49738,
49746,
49795,
49803,
49809,
49827,
49834,
49840,
49916,
49923,
49944,
49950,
49972,
49980,
50002,
50031,
50112,
50132,
50138,
50153,
50331,
50344,
50352,
50358,
50405,
50422,
50430,
50484,
50534,
50542,
50548,
50566,
50573,
50579,
50660,
50667,
50692,
50700,
50780,
50808,
50816,
50822,
50869,
50889,
50911,
50919,
50941,
50970,
50998,
51004,
51019,
51057,
51070,
51078,
51084,
51175,
51238,
51244,
51290,
51353,
51359,
51390,
51473,
51481,
51527,
51535,
51541,
51586,
51698,
51751,
51757,
51783,
51866,
51874,
51919,
51927,
51933,
51993,
52125,
52209,
52215,
52268,
52274,
52303,
52386,
52394,
52442,
52450,
52456,
52511,
52586,
52649,
52702,
52785,
52793,
52839,
52847,
52853,
52894,
52901,
52907,
53005,
53012,
53037,
53045,
53123,
53143,
53151,
53157,
53181,
53203,
53211,
53233,
53262,
53282,
53288,
53303,
53346,
53359,
53367,
53373,
53396,
53404,
53496,
53516,
53524,
53530,
53549,
53584,
53627,
53635,
53660,
53688,
53696,
53788,
53821,
53842,
53850,
53879,
53887,
53893,
53959,
54007,
54015,
54180,
54186,
54214,
54230,
54330,
54348,
54356,
54383,
54411,
54419,
54427,
54435,
54443,
54449,
54488,
54564,
54570,
54589,
54596,
54602,
54702,
54709,
54734,
54742,
54827,
54847,
54855,
54861,
54883,
54891,
54913,
54942,
54962,
54968,
54983,
54996,
55004,
55010,
55063,
55090,
55110,
55116,
55132,
55153,
55188,
55233,
55241,
55342,
55348,
55395,
55449,
55455,
55476,
55557,
55565,
55622,
55630,
55636,
55655,
55663,
55695,
55910,
55940,
55948,
55956,
55962,
56001,
56077,
56083,
56117,
56184,
56244,
56263,
56270,
56276,
56351,
56358,
56383,
56391,
56476,
56496,
56504,
56510,
56532,
56540,
56562,
56591,
56611,
56617,
56632,
56645,
56653,
56659,
56712,
56739,
56747,
56767,
56775,
56781,
56806,
56932,
57006,
57036,
57042,
57081,
57142,
57148,
57182,
57249,
57309,
57328,
57335,
57341,
57424,
57431,
57453,
57461,
57483,
57512,
57540,
57546,
57561,
57613,
57663,
57676,
57684,
57690,
57715,
57723,
57815,
57843,
57851,
57857,
57904,
57927,
57955,
57961,
58005,
58138,
58212,
58218,
58264,
58327,
58333,
58360,
58443,
58451,
58577,
58583,
58630,
58646,
58703,
58784,
58792,
58839,
58847,
58855,
58861,
58883,
58936,
58942,
58964,
58971,
58977,
59059,
59066,
59091,
59099,
59191,
59211,
59219,
59225,
59247,
59255,
59277,
59306,
59326,
59332,
59347,
59402,
59455,
59468,
59476,
59482,
59532,
59569,
59613,
59619,
59708,
59771,
59795,
59834,
59842,
59892,
59915,
59934,
59940,
59991,
59999,
60017,
60024,
60030,
60126,
60133,
60158,
60166,
60258,
60278,
60286,
60292,
60316,
60338,
60346,
60368,
60397,
60417,
60423,
60438,
60481,
60494,
60502,
60508,
60531,
60539,
60559,
60567,
60599,
60619,
60627,
60647,
60655,
60661,
60705,
60852,
60933,
60939,
60985,
61048,
61054,
61139,
61146,
61152,
61195,
61202,
61227,
61251,
61257,
61303,
61309,
61394,
61412,
61467,
61473,
61492,
61574,
61582,
61623,
61631,
61637,
61655,
61662,
61668,
61738,
61745,
61788,
61937,
61943,
61989,
62052,
62058,
62076,
62156,
62164,
62217,
62225,
62236,
62244,
62295,
62432,
62438,
62484,
62547,
62627,
62635,
62688,
62696,
62704,
62710,
62727,
62734,
62740,
62809,
62816,
62970,
62976,
63022,
63085,
63091,
63111,
63191,
63199,
63241,
63249,
63255,
63274,
63281,
63287,
63338,
63345,
63401,
63408,
63414,
63493,
63500,
63553,
63560,
63566,
63620,
63627,
63686,
63693,
63699,
63768,
63775,
63816,
63823,
63829,
63836,
63871,
63878,
63884,
63935,
63942,
63976,
63983,
63989,
64044,
64051,
64111,
64118,
64124,
64202,
64209,
64252,
64259,
64265,
64272,
64319,
64326,
64332,
64339,
64380,
64387,
64393,
64400,
64450,
64482,
64488,
64548,
64555,
64561,
64635,
64642,
64730,
64737,
64743,
64750,
64783,
64790,
64796,
64905,
64912,
64954,
65003,
65009,
65075,
65082,
65088,
65095,
65141,
65147,
65200,
65207,
65213,
65220,
65257,
65264,
65270,
65324,
65331,
65367,
65374,
65380,
65438,
65445,
65508,
65515,
65521,
65528,
65568,
65575,
65581,
65588,
65624,
65632,
65662,
65701,
65707,
65735,
65772,
65778,
65806,
65843,
65849,
65879,
65892,
65900,
65922,
65929,
65935,
65983,
65990,
66043,
66050,
66056,
66111,
66118,
66178,
66185,
66191,
66198,
66220,
66228,
66253,
66281,
66287,
66315,
66346,
66352,
66381,
66413,
66419,
66451,
66486,
66492,
66530,
66536,
66563,
66593,
66599,
66621,
66642,
66648,
66677,
66709,
66717,
66745,
66752,
66758,
66873,
66880,
66964,
67017,
67070,
67126,
67133,
67139,
67336,
67343,
67396,
67477,
67539,
67603,
67609,
67714,
67722,
67770,
67778,
67857,
67930,
67993,
68030,
68038,
68047,
68104,
68164,
68223,
68285,
68291,
68318,
68357,
68391,
68424,
68519,
68576,
68582,
68618,
68626,
68654,
68733,
68739,
68768,
68850,
68858,
68869,
68877,
68961,
68977,
68985,
68992,
68998,
69005,
69030,
69038,
69120,
69154,
69162,
69168,
69241,
69247,
69303,
69349,
69367,
69422,
69428,
69464,
69549,
69557,
69621,
69708,
69716,
69722,
69747,
69754,
69760,
69811,
69818,
69843,
69851,
69933,
69961,
69969,
69975,
70051,
70057,
70113,
70159,
70177,
70232,
70238,
70264,
70349,
70357,
70402,
70410,
70416,
70437,
70444,
70450,
70525,
70532,
70559,
70565,
70656,
70662,
70708,
70771,
70856,
70864,
70892,
70900,
70911,
70919,
70943,
70995,
71034,
71042,
71124,
71132,
71183,
71253,
71311,
71317,
71345,
71402,
71410,
71473,
71552,
71621,
71627,
71658,
71716,
71766,
71774,
71834,
71842,
71898,
71906,
71981,
71989,
72045,
72053,
72091,
72166,
72211,
72219,
72256,
72264,
72272,
72329,
72337,
72385,
72424,
72432,
72489,
72515,
72523,
72531,
72537,
72569,
72591,
72599,
72628,
72652,
72660,
72671,
72679,
72720,
72728,
72758,
72766,
72813,
72821,
72856,
72879,
72947,
72955,
72993,
73018,
73026,
73034,
73042,
73072,
73080,
73086,
73122,
73196,
73245,
73266,
73273,
73279,
73286,
73311,
73319,
73401,
73438,
73446,
73452,
73490,
73496,
73587,
73593,
73639,
73657,
73712,
73794,
73802,
73826,
73878,
73917,
73925,
74007,
74015,
74021,
74072,
74130,
74136,
74193,
74201,
74264,
74343,
74412,
74418,
74463,
74471,
74479,
74485,
74509,
74516,
74522,
74529,
74554,
74562,
74644,
74668,
74676,
74682,
74700,
74706,
74797,
74803,
74821,
74867,
74922,
75004,
75012,
75036,
75088,
75127,
75135,
75217,
75225,
75276,
75338,
75346,
75352,
75369,
75376,
75382,
75439,
75446,
75478,
75486,
75563,
75583,
75591,
75597,
75655,
75733,
75830,
75861,
75867,
75944,
76027,
76112,
76204,
76285,
76291,
76329,
76464,
76558,
76601,
76645,
76653,
76713,
76780,
76841,
76871,
76879,
76952,
76960,
77006,
77014,
77096,
77104,
77112,
77118,
77144,
77227,
77356,
77364,
77458,
77527,
77557,
77565,
77638,
77646,
77700,
77708,
77790,
77798,
77837,
77845,
77851,
77878,
77968,
78055,
78063,
78149,
78220,
78303,
78350,
78419,
78449,
78457,
78536,
78544,
78598,
78606,
78694,
78702,
78753,
78761,
78767,
78796,
78890,
78981,
78989,
79080,
79154,
79231,
79275,
79347,
79377,
79385,
79467,
79475,
79529,
79537,
79628,
79636,
79692,
79700,
79706,
79740,
79842,
79941,
79949,
80047,
80124,
80203,
80267,
80314,
80389,
80419,
80427,
80512,
80520,
80575,
80583,
80677,
80685,
80748,
80756,
80762,
80800,
80886,
80969,
80977,
81057,
81124,
81203,
81277,
81337,
81374,
81441,
81471,
81479,
81554,
81562,
81614,
81622,
81706,
81714,
81759,
81767,
81773,
81812,
81849,
81892,
81937,
81986,
82027,
82033,
82047,
82074,
82137,
82145,
82213,
82233,
82241,
82247,
82275,
82305,
82330,
82347,
82353,
82381,
82400,
82407,
82413,
82470,
82477,
82517,
82524,
82530,
82605,
82612,
82644,
82697,
82724,
82764,
82772,
82848,
82924,
82944,
82952,
82958,
82993,
83001,
83099,
83159,
83176,
83196,
83204,
83221,
83227,
83276,
83338,
83346,
83418,
83438,
83446,
83452,
83530,
83663,
83671,
83734,
83754,
83762,
83768,
83796,
83802,
83893,
83951,
83957,
84031,
84098,
84128,
84134,
84232,
84240,
84294,
84322,
84330,
84424,
84521,
84529,
84581,
84597,
84605,
84611,
84665,
84673,
84735,
84759,
84815,
84823,
84890,
84898,
84927,
85058,
85066,
85089,
85097,
85103,
85123,
85131,
85164,
85188,
85196,
85246,
85254,
85262,
85270,
85281,
85289,
85341,
85349,
85383,
85391,
85399,
85410,
85418,
85507,
85598,
85604,
85647,
85746,
85754,
85795,
85803,
85811,
85817,
85843,
85935,
85979,
86007,
86015,
86109,
86206,
86214,
86264,
86280,
86288,
86294,
86351,
86359,
86421,
86445,
86501,
86509,
86576,
86584,
86613,
86744,
86752,
86775,
86783,
86789,
86807,
86815,
86849,
86873,
86881,
86932,
86940,
86948,
86956,
86967,
86975,
87027,
87035,
87069,
87077,
87083,
87110,
87156,
87164,
87268,
87317,
87345,
87353,
87447,
87544,
87552,
87604,
87620,
87628,
87634,
87692,
87700,
87762,
87786,
87842,
87850,
87917,
87925,
87954,
88085,
88093,
88116,
88124,
88130,
88158,
88217,
88275,
88312,
88336,
88344,
88398,
88406,
88414,
88425,
88433,
88485,
88493,
88527,
88535,
88543,
88549,
88578,
88624,
88632,
88741,
88793,
88821,
88829,
88923,
89020,
89028,
89082,
89098,
89106,
89112,
89172,
89180,
89242,
89266,
89322,
89330,
89397,
89405,
89434,
89565,
89573,
89596,
89604,
89610,
89646,
89705,
89765,
89807,
89831,
89839,
89898,
89906,
89914,
89925,
89933,
89985,
89993,
90027,
90035,
90043,
90049,
90083,
90129,
90137,
90254,
90310,
90338,
90346,
90440,
90537,
90545,
90596,
90612,
90620,
90626,
90690,
90698,
90760,
90784,
90840,
90848,
90915,
90923,
90952,
91083,
91091,
91114,
91122,
91128,
91161,
91220,
91277,
91319,
91343,
91351,
91410,
91418,
91426,
91437,
91445,
91497,
91505,
91539,
91547,
91555,
91561,
91586,
91632,
91640,
91741,
91789,
91817,
91825,
91919,
92016,
92024,
92076,
92092,
92100,
92106,
92162,
92170,
92232,
92256,
92312,
92320,
92387,
92395,
92424,
92555,
92563,
92586,
92594,
92600,
92660,
92737,
92847,
92864,
92872,
92929,
92976,
93018,
93042,
93050,
93102,
93110,
93118,
93126,
93137,
93145,
93197,
93205,
93239,
93247,
93255,
93261,
93321,
93351,
93357,
93385,
93404,
93411,
93417,
93475,
93482,
93516,
93522,
93613,
93633,
93639,
93709,
93745,
93765,
93771,
93802,
93854,
93874,
93880,
93920,
93966,
94029,
94036,
94042,
94116,
94123,
94176,
94201,
94228,
94267,
94301,
94307,
94328,
94334,
94356,
94364,
94389,
94397,
94440,
94485,
94493,
94582,
94602,
94610,
94616,
94715,
94743,
94751,
94831,
94851,
94859,
94890,
94972,
95029,
95042,
95050,
95056,
95083,
95091,
95134,
95181,
95189,
95278,
95298,
95306,
95312,
95375,
95463,
95537,
95565,
95573,
95653,
95673,
95681,
95712,
95796,
95853,
95866,
95874,
95880,
95908,
95916,
95964,
95972,
96059,
96079,
96087,
96093,
96158,
96233,
96261,
96269,
96353,
96373,
96381,
96412,
96497,
96554,
96567,
96575,
96581,
96610,
96618,
96667,
96675,
96763,
96783,
96791,
96797,
96847,
96908,
96936,
96944,
97029,
97049,
97057,
97088,
97174,
97231,
97244,
97252,
97258,
97290,
97298,
97350,
97358,
97449,
97469,
97477,
97483,
97544,
97607,
97635,
97643,
97731,
97751,
97759,
97790,
97879,
97936,
97949,
97957,
97963,
97971,
98026,
98034,
98129,
98149,
98157,
98163,
98224,
98286,
98345,
98376,
98469,
98526,
98539,
98547,
98553,
98575,
98604,
98612,
98691,
98711,
98719,
98727,
98733,
98739,
98776,
98784,
98868,
98888,
98896,
98907,
98915,
98937,
98945,
98970,
99004,
99017,
99023,
99051,
99083,
99096,
99102,
99131,
99169,
99182,
99188,
99220,
99261,
99274,
99280,
99302,
99331,
99358,
99371,
99379,
99419,
99427,
99446,
99453,
99459,
99546,
99553,
99595,
99602,
99608,
99648,
99655,
99696,
99802,
99848,
99862,
99887,
99938,
99944,
100022,
100030,
100057,
100123,
100156,
100182,
100206,
100236,
100348,
100378,
100384,
100409,
100417,
100428,
100436,
100528,
100579,
100657,
100665,
100720,
100728,
100736,
100742,
100786,
100794,
100814,
100886,
100894,
101050,
101080,
101088,
101096,
101103,
101109,
101178,
101185,
101207,
101215,
101240,
101281,
101287,
101315,
101359,
101365,
101394,
101439,
101445,
101477,
101525,
101531,
101583,
101589,
101616,
101659,
101665,
101687,
101725,
101731,
101760,
101805,
101813,
101837,
101844,
101850,
101919,
101926,
101948,
101956,
101981,
102022,
102028,
102056,
102098,
102104,
102133,
102176,
102182,
102214,
102257,
102263,
102307,
102313,
102340,
102389,
102395,
102417,
102446,
102459,
102467,
102491,
102498,
102504,
102581,
102588,
102610,
102618,
102643,
102687,
102693,
102721,
102768,
102774,
102803,
102851,
102857,
102889,
102940,
102946,
103000,
103006,
103033,
103079,
103085,
103107,
103136,
103149,
103157,
103181,
103188,
103194,
103201,
103238,
103245,
103251,
103258,
103265,
103271,
103278,
103285,
103291,
103298,
103305,
103311,
103318,
103325,
103331,
103338,
103377,
103384,
103397,
103422,
103532,
103568,
103597,
103610,
103647,
103677,
103704,
103794,
103858,
103871,
103886,
103917,
103944,
103973,
104047,
104081,
104116,
104149,
104236,
104341,
104380,
104407,
104451,
104485,
104515,
104541,
104610,
104631,
104660,
104685,
104733,
104785,
104815,
104849,
104879,
104926,
104960,
104986,
105004,
105017,
105044,
105065,
105098,
105188,
105293,
105334,
105356,
105424,
105488,
105508,
105589,
105632,
105662,
105678,
105698,
105794,
105831,
105864,
105940,
106036,
106066,
106095,
106158,
106236,
106266,
106291,
106336,
106365,
106394,
106415,
106467,
106516,
106546,
106573,
106643,
106673,
106702,
106733,
106761,
106798,
106827,
106848,
106888,
106916,
106936,
106969,
107006,
107086,
107134,
107168,
107187,
107239,
107325,
107355,
107383,
107437,
107493,
107523,
107547,
107573,
107615,
107645,
107667,
107696,
107735,
107791,
107821,
107834,
107876,
107905,
107929,
107973,
108001,
108014,
108029,
108045,
108072,
108103,
108150,
108208,
108231,
108292,
108358,
108387,
108420,
108452,
108498,
108537,
108570,
108604,
108667,
108703,
108727,
108797,
108825,
108858,
108906,
108948,
108984,
109007,
109025,
109045,
109060,
109088,
109119,
109166,
109271,
109293,
109349,
109389,
109419,
109433,
109449,
109481,
109508,
109520,
109576,
109605,
109620,
109655,
109684,
109713,
109735,
109799,
109885,
109915,
109937,
110023,
110078,
110107,
110117,
110163,
110190,
110223,
110248,
110285,
110312,
110335,
110419,
110484,
110513,
110525,
110550,
110577,
110601,
110701,
110737,
110766,
110780,
110850,
110881,
110911,
110955,
110989,
111019,
111043,
111113,
111218,
111234,
111252,
111265,
111293,
111316,
111396,
111462,
111492,
111534,
111563,
111630,
111664,
111686,
111708,
111728,
111780,
111841,
111876,
111902,
111944,
112049,
112081,
112122,
112174,
112214,
112242,
112313,
112386,
112403,
112443,
112473,
112502,
112526,
112566,
112617,
112637,
112686,
112723,
112746,
112761,
112770,
112797,
112821,
112855,
112907,
112937,
112960,
113043,
113075,
113104,
113124,
113136,
113142,
113169,
113195,
113236,
113311,
113341,
113371,
113393,
113409,
113436,
113459,
113492,
113532,
113561,
113590,
113621,
113667,
113697,
113714,
113733,
113791,
113852,
113882,
113924,
114018,
114123,
114153,
114170,
114187,
114232,
114260,
114277,
114296,
114326,
114354,
114376,
114459,
114498,
114528,
114558,
114616,
114656,
114686,
114700,
114716,
114733,
114760,
114774,
114829,
114860,
114880,
114965,
115002,
115025,
115063,
115135,
115165,
115189,
115287,
115345,
115375,
115397,
115427,
115455,
115475,
115549,
115602,
115631,
115654,
115697,
115725,
115755,
115854,
115918,
115947,
115973,
116001,
116045,
116075,
116108,
116184,
116221,
116251,
116276,
116293,
116328,
116355,
116375,
116415,
116448,
116478,
116507,
116551,
116585,
116615,
116633,
116653,
116674,
116701,
116716,
116741,
116800,
116845,
116875,
116895,
116935,
117027,
117057,
117073,
117086,
117121,
117150,
117164,
117190,
117229,
117259,
117281,
117318,
117408,
117438,
117463,
117498,
117591,
117642,
117683,
117711,
117813,
117860,
117880,
117974,
118028,
118056,
118084,
118128,
118184,
118210,
118246,
118277,
118307,
118344,
118429,
118500,
118530,
118545,
118570,
118620,
118650,
118689,
118698,
118706,
118744,
118772,
118804,
118877,
118906,
118936,
118982,
119016,
119041,
119086,
119114,
119141,
119160,
119174,
119201,
119225,
119251,
119278,
119306,
119327,
119350,
119369,
119397,
119420,
119440,
119483,
119512,
119541,
119580,
119643,
119673,
119705,
119799,
119845,
119886,
119911,
119933,
120009,
120031,
120047,
120054,
120067,
120094,
120117,
120191,
120225,
120259,
120281,
120391,
120431,
120463,
120484,
120508,
120578,
120630,
120660,
120691,
120725,
120761,
120775,
120789,
120831,
120859,
120889,
120935,
120974,
121004,
121024,
121060,
121165,
121193,
121241,
121269,
121291,
121309,
121344,
121373,
121393,
121433,
121468,
121479,
121514,
121572,
121638,
121679,
121704,
121772,
121800,
121830,
121849,
121883,
121970,
122000,
122022,
122054,
122090,
122119,
122162,
122201,
122270,
122304,
122341,
122385,
122419,
122449,
122479,
122561,
122596,
122632,
122651,
122696,
122772,
122802,
122819,
122856,
122892,
122913,
122953,
123004,
123034,
123057,
123096,
123138,
123167,
123190,
123234,
123289,
123319,
123345,
123387,
123433,
123462,
123489,
123553,
123609,
123639,
123673,
123772,
123877,
123907,
123933,
123969,
124023,
124053,
124074,
124096,
124161,
124233,
124259,
124272,
124344,
124374,
124386,
124441,
124471,
124488,
124550,
124598,
124628,
124637,
124664,
124691,
124710,
124724,
124751,
124784,
124917,
125005,
125046,
125061,
125078,
125096,
125123,
125154,
125198,
125232,
125262,
125281,
125326,
125353,
125371,
125410,
125436,
125458,
125515,
125579,
125603,
125691,
125728,
125742,
125767,
125788,
125818,
125847,
125857,
125869,
125896,
125922,
125951,
125986,
126027,
126057,
126088,
126162,
126237,
126270,
126305,
126356,
126386,
126402,
126409,
126422,
126449,
126478,
126496,
126526,
126555,
126600,
126705,
126725,
126747,
126780,
126808,
126824,
126848,
126875,
126903,
126921,
126930,
126945,
126972,
126983,
126996,
127009,
127035,
127059,
127126,
127194,
127211,
127238,
127337,
127395,
127424,
127445,
127541,
127584,
127613,
127637,
127734,
127824,
127849,
127884,
127924,
127953,
127970,
127989,
128024,
128051,
128073,
128111,
128216,
128253,
128329,
128421,
128451,
128482,
128534,
128562,
128584,
128595,
128615,
128642,
128676,
128720,
128754,
128784,
128801,
128839,
128887,
128917,
128939,
128977,
129032,
129050,
129059,
129074,
129101,
129113,
129144,
129265,
129308,
129338,
129370,
129412,
129473,
129503,
129524,
129536,
129565,
129592,
129615,
129681,
129726,
129756,
129779,
129858,
129917,
129947,
129974,
130003,
130034,
130062,
130077,
130094,
130112,
130139,
130167,
130211,
130316,
130343,
130386,
130424,
130453,
130474,
130529,
130609,
130639,
130663,
130751,
130808,
130837,
130862,
130924,
130980,
131010,
131029,
131040,
131066,
131094,
131124,
131221,
131256,
131296,
131320,
131381,
131433,
131463,
131483,
131504,
131532,
131552,
131607,
131673,
131702,
131721,
131742,
131759,
131787,
131804,
131828,
131912,
131937,
131958,
132009,
132090,
132116,
132140,
132222,
132257,
132291,
132321,
132394,
132426,
132456,
132468,
132491,
132557,
132599,
132628,
132660,
132797,
132832,
132873,
132901,
133022,
133059,
133089,
133104,
133142,
133220,
133249,
133269,
133321,
133369,
133398,
133427,
133504,
133538,
133578,
133607,
133712,
133744,
133760,
133790,
133838,
133868,
133892,
133932,
134037,
134059,
134071,
134110,
134137,
134160,
134268,
134302,
134332,
134349,
134384,
134425
],
"line_end_idx": [
53,
66,
104,
183,
199,
224,
249,
290,
332,
411,
418,
494,
571,
645,
689,
697,
778,
782,
807,
811,
837,
866,
905,
936,
962,
998,
1026,
1062,
1092,
1119,
1156,
1191,
1226,
1261,
1297,
1333,
1337,
1364,
1390,
1413,
1440,
1460,
1486,
1511,
1515,
1539,
1570,
1574,
1611,
1615,
1620,
1626,
1630,
1635,
1641,
1645,
1649,
1697,
1701,
1706,
1860,
1942,
1983,
2096,
2100,
2238,
2345,
2349,
2511,
2653,
2789,
2794,
2798,
2803,
2816,
2821,
2825,
2928,
2933,
2963,
2969,
2992,
3068,
3086,
3199,
3204,
3231,
3309,
3328,
3445,
3450,
3478,
3590,
3595,
3626,
3746,
3751,
3874,
3879,
3905,
4022,
4027,
4048,
4076,
4088,
4093,
4100,
4119,
4125,
4130,
4136,
4163,
4170,
4247,
4309,
4314,
4369,
4413,
4420,
4455,
4508,
4572,
4579,
4648,
4655,
4662,
4672,
4679,
4714,
4763,
4770,
4811,
4818,
4825,
4832,
4859,
4865,
4870,
4876,
4903,
4933,
4939,
4944,
4950,
4979,
5011,
5042,
5047,
5070,
5096,
5123,
5148,
5153,
5179,
5210,
5216,
5221,
5305,
5311,
5349,
5368,
5373,
5413,
5451,
5458,
5495,
5531,
5569,
5588,
5629,
5636,
5646,
5653,
5691,
5710,
5765,
5772,
5777,
5795,
5801,
5806,
5918,
5924,
5960,
6012,
6114,
6141,
6148,
6227,
6246,
6253,
6258,
6284,
6322,
6355,
6385,
6480,
6558,
6563,
6599,
6606,
6689,
6708,
6715,
6720,
6784,
6789,
6833,
6838,
6877,
6922,
6927,
6945,
6951,
6956,
7011,
7017,
7071,
7077,
7082,
7192,
7198,
7219,
7226,
7250,
7296,
7301,
7328,
7377,
7382,
7410,
7460,
7465,
7496,
7549,
7554,
7610,
7615,
7641,
7689,
7694,
7715,
7743,
7762,
7769,
7788,
7794,
7799,
7854,
7860,
7910,
7958,
7964,
7969,
8039,
8045,
8081,
8087,
8092,
8098,
8128,
8134,
8139,
8185,
8191,
8220,
8226,
8231,
8236,
8329,
8335,
8376,
8395,
8400,
8445,
8486,
8493,
8530,
8569,
8613,
8632,
8676,
8683,
8693,
8700,
8744,
8763,
8824,
8831,
8836,
8854,
8860,
8865,
8963,
8969,
9014,
9056,
9063,
9100,
9134,
9176,
9195,
9240,
9247,
9257,
9264,
9306,
9325,
9384,
9391,
9396,
9414,
9420,
9425,
9534,
9540,
9588,
9632,
9639,
9676,
9712,
9758,
9777,
9825,
9832,
9842,
9849,
9895,
9914,
9978,
9985,
9990,
10008,
10014,
10019,
10128,
10134,
10186,
10234,
10241,
10278,
10318,
10365,
10384,
10435,
10442,
10452,
10459,
10506,
10525,
10589,
10596,
10601,
10619,
10625,
10630,
10726,
10732,
10772,
10812,
10819,
10856,
10893,
10933,
10952,
10995,
11002,
11012,
11019,
11059,
11078,
11135,
11142,
11147,
11165,
11171,
11176,
11292,
11298,
11334,
11386,
11467,
11472,
11500,
11507,
11590,
11609,
11616,
11621,
11647,
11685,
11718,
11749,
11847,
11925,
11961,
11968,
12054,
12073,
12080,
12085,
12152,
12157,
12204,
12209,
12238,
12286,
12291,
12309,
12315,
12320,
12378,
12384,
12441,
12447,
12452,
12519,
12525,
12579,
12623,
12629,
12634,
12710,
12716,
12755,
12761,
12766,
12772,
12805,
12811,
12816,
12865,
12871,
12903,
12909,
12914,
12966,
12972,
13084,
13091,
13173,
13291,
13310,
13317,
13376,
13431,
13482,
13489,
13499,
13506,
13563,
13578,
13585,
13592,
13632,
13638,
13643,
13702,
13708,
13751,
13766,
13773,
13884,
13903,
13910,
13915,
13933,
13939,
13944,
14005,
14011,
14038,
14076,
14083,
14150,
14184,
14203,
14210,
14215,
14236,
14241,
14259,
14265,
14270,
14276,
14303,
14361,
14368,
14452,
14486,
14505,
14512,
14517,
14538,
14543,
14561,
14567,
14572,
14578,
14644,
14676,
14702,
14720,
14747,
14779,
14811,
14837,
14855,
14882,
14915,
14947,
14973,
14991,
15018,
15054,
15086,
15112,
15130,
15157,
15197,
15229,
15255,
15273,
15300,
15331,
15363,
15389,
15407,
15434,
15460,
15492,
15512,
15541,
15574,
15602,
15632,
15665,
15696,
15727,
15760,
15792,
15823,
15856,
15891,
15923,
15956,
15994,
16031,
16064,
16094,
16127,
16159,
16178,
16199,
16228,
16234,
16239,
16290,
16296,
16323,
16328,
16361,
16399,
16406,
16486,
16520,
16539,
16546,
16551,
16594,
16696,
16709,
16759,
16836,
16843,
16905,
16937,
16963,
16981,
17008,
17039,
17072,
17106,
17135,
17142,
17188,
17285,
17335,
17412,
17419,
17484,
17516,
17542,
17560,
17587,
17618,
17651,
17688,
17717,
17724,
17774,
17875,
17925,
18002,
18009,
18078,
18110,
18136,
18154,
18181,
18213,
18246,
18286,
18315,
18322,
18363,
18455,
18505,
18582,
18589,
18649,
18681,
18707,
18725,
18752,
18789,
18822,
18854,
18883,
18890,
18895,
18970,
19059,
19122,
19186,
19253,
19324,
19386,
19394,
19423,
19428,
19435,
19497,
19539,
19599,
19649,
19654,
19734,
19741,
19764,
19828,
19880,
19942,
19983,
19990,
20046,
20061,
20068,
20073,
20126,
20145,
20189,
20196,
20203,
20208,
20215,
20281,
20344,
20394,
20474,
20481,
20504,
20575,
20625,
20690,
20731,
20738,
20792,
20807,
20814,
20868,
20945,
20962,
21005,
21012,
21019,
21024,
21031,
21098,
21162,
21212,
21292,
21299,
21322,
21396,
21448,
21520,
21561,
21568,
21629,
21644,
21651,
21707,
21734,
21795,
21843,
21850,
21857,
21862,
21869,
21938,
22005,
22055,
22135,
22142,
22165,
22244,
22298,
22373,
22414,
22421,
22487,
22502,
22509,
22567,
22602,
22667,
22721,
22728,
22735,
22740,
22747,
22821,
22892,
22942,
23022,
23029,
23052,
23134,
23188,
23266,
23307,
23314,
23384,
23399,
23406,
23464,
23496,
23558,
23613,
23620,
23627,
23632,
23639,
23711,
23773,
23823,
23828,
23926,
23931,
24011,
24018,
24041,
24120,
24174,
24249,
24290,
24297,
24358,
24373,
24380,
24438,
24443,
24476,
24483,
24555,
24562,
24572,
24579,
24666,
24784,
24803,
24810,
24874,
24932,
24939,
24949,
24956,
25017,
25032,
25039,
25046,
25053,
25060,
25065,
25092,
25110,
25116,
25121,
25126,
25131,
25175,
25181,
25208,
25213,
25244,
25271,
25276,
25369,
25443,
25453,
25492,
25551,
25611,
25641,
25646,
25739,
25744,
25808,
25813,
25838,
25950,
25957,
26050,
26088,
26095,
26100,
26138,
26174,
26179,
26192,
26218,
26258,
26265,
26332,
26351,
26358,
26385,
26414,
26438,
26454,
26465,
26470,
26497,
26515,
26521,
26526,
26608,
26614,
26655,
26662,
26737,
26756,
26763,
26768,
26819,
26839,
26858,
26863,
26904,
26909,
26933,
26940,
27017,
27036,
27043,
27048,
27089,
27111,
27118,
27210,
27229,
27236,
27241,
27293,
27350,
27355,
27423,
27442,
27449,
27494,
27553,
27560,
27565,
27585,
27591,
27596,
27681,
27687,
27731,
27738,
27818,
27837,
27844,
27849,
27904,
27922,
27941,
27946,
27988,
28043,
28103,
28108,
28129,
28247,
28262,
28314,
28393,
28400,
28456,
28463,
28532,
28551,
28558,
28601,
28663,
28670,
28675,
28695,
28701,
28706,
28832,
28838,
28874,
28926,
29003,
29008,
29040,
29047,
29131,
29150,
29157,
29162,
29188,
29226,
29259,
29294,
29393,
29471,
29507,
29514,
29602,
29621,
29628,
29633,
29701,
29706,
29754,
29759,
29794,
29843,
29848,
29866,
29872,
29877,
29936,
29942,
30000,
30006,
30011,
30097,
30103,
30148,
30155,
30236,
30255,
30262,
30267,
30313,
30332,
30390,
30395,
30441,
30498,
30560,
30566,
30594,
30640,
30760,
30776,
30829,
30909,
30917,
30980,
30988,
31065,
31085,
31093,
31143,
31207,
31215,
31221,
31242,
31249,
31255,
31393,
31400,
31437,
31490,
31572,
31578,
31613,
31621,
31709,
31729,
31737,
31743,
31770,
31809,
31843,
31881,
31984,
32063,
32100,
32108,
32200,
32220,
32228,
32234,
32306,
32312,
32318,
32357,
32410,
32416,
32435,
32442,
32448,
32511,
32518,
32580,
32587,
32593,
32683,
32690,
32738,
32746,
32831,
32851,
32859,
32865,
32914,
32934,
33003,
33009,
33059,
33119,
33184,
33190,
33221,
33267,
33390,
33406,
33459,
33539,
33547,
33613,
33621,
33704,
33724,
33732,
33785,
33852,
33860,
33866,
33887,
33894,
33900,
34038,
34045,
34082,
34135,
34213,
34276,
34282,
34309,
34348,
34382,
34417,
34524,
34603,
34640,
34648,
34744,
34764,
34772,
34778,
34853,
34859,
34865,
34921,
34927,
34946,
34953,
34959,
35052,
35059,
35111,
35119,
35208,
35228,
35236,
35242,
35295,
35315,
35385,
35391,
35442,
35505,
35573,
35579,
35610,
35656,
35783,
35799,
35852,
35932,
35940,
36006,
36014,
36100,
36120,
36128,
36198,
36206,
36212,
36233,
36240,
36246,
36253,
36292,
36328,
36334,
36391,
36446,
36452,
36476,
36498,
36506,
36536,
36678,
36691,
36697,
36725,
36733,
36790,
36870,
36934,
37042,
37087,
37100,
37108,
37114,
37142,
37150,
37209,
37346,
37506,
37519,
37527,
37533,
37563,
37576,
37584,
37590,
37664,
37711,
37729,
37736,
37742,
37855,
37862,
37901,
37942,
37948,
38014,
38078,
38084,
38175,
38231,
38249,
38256,
38262,
38387,
38394,
38431,
38484,
38558,
38627,
38682,
38688,
38715,
38754,
38788,
38818,
38916,
38995,
39032,
39040,
39127,
39147,
39155,
39161,
39228,
39234,
39281,
39287,
39335,
39341,
39360,
39367,
39373,
39458,
39465,
39509,
39517,
39597,
39617,
39625,
39631,
39676,
39696,
39760,
39766,
39810,
39864,
39924,
39930,
39961,
40007,
40125,
40141,
40194,
40274,
40282,
40348,
40356,
40434,
40454,
40462,
40524,
40532,
40538,
40559,
40566,
40572,
40621,
40628,
40660,
40667,
40673,
40744,
40751,
40776,
40784,
40876,
40904,
40912,
40918,
40939,
40961,
40969,
40991,
41020,
41083,
41111,
41117,
41132,
41279,
41292,
41300,
41306,
41322,
41368,
41421,
41427,
41454,
41537,
41545,
41591,
41599,
41605,
41627,
41634,
41640,
41719,
41726,
41751,
41759,
41862,
41890,
41898,
41904,
41928,
41950,
41958,
41980,
42009,
42066,
42094,
42100,
42115,
42245,
42308,
42321,
42329,
42335,
42351,
42397,
42453,
42459,
42525,
42552,
42635,
42643,
42700,
42706,
42866,
42872,
42886,
42933,
42985,
43067,
43075,
43122,
43130,
43138,
43144,
43166,
43173,
43179,
43231,
43238,
43263,
43279,
43325,
43331,
43445,
43461,
43514,
43545,
43592,
43598,
43626,
43705,
43711,
43740,
43746,
43828,
43835,
43841,
43881,
43888,
43913,
43941,
43947,
43993,
43999,
44068,
44086,
44141,
44147,
44174,
44259,
44267,
44313,
44321,
44327,
44349,
44356,
44362,
44441,
44448,
44642,
44648,
44698,
44719,
44727,
44787,
44795,
44806,
44814,
44841,
44873,
44879,
44901,
44909,
44931,
44939,
44968,
44981,
44989,
44995,
45024,
45032,
45061,
45074,
45082,
45088,
45103,
45116,
45124,
45132,
45153,
45160,
45166,
45221,
45228,
45261,
45282,
45304,
45312,
45334,
45446,
45473,
45486,
45515,
45594,
45621,
45634,
45640,
45655,
45770,
45801,
45832,
45870,
45910,
45923,
45931,
45937,
45964,
46001,
46009,
46076,
46084,
46095,
46103,
46130,
46162,
46168,
46194,
46202,
46230,
46309,
46315,
46344,
46352,
46373,
46381,
46402,
46409,
46415,
46505,
46512,
46534,
46542,
46574,
46594,
46600,
46608,
46676,
46697,
46717,
46723,
46736,
46744,
46750,
46758,
46838,
46859,
46879,
46885,
46898,
46906,
46912,
46920,
46992,
47011,
47031,
47044,
47052,
47058,
47066,
47110,
47130,
47136,
47171,
47184,
47192,
47198,
47206,
47252,
47272,
47278,
47315,
47328,
47336,
47342,
47350,
47400,
47420,
47426,
47467,
47480,
47488,
47496,
47502,
47527,
47535,
47616,
47636,
47644,
47650,
47695,
47712,
47720,
47797,
47805,
47811,
47857,
47877,
47885,
47927,
47974,
47980,
48002,
48010,
48035,
48069,
48082,
48088,
48116,
48148,
48161,
48167,
48196,
48234,
48247,
48253,
48285,
48326,
48339,
48345,
48360,
48454,
48467,
48475,
48515,
48523,
48544,
48551,
48557,
48615,
48622,
48647,
48667,
48673,
48701,
48805,
48811,
48842,
48850,
48877,
48905,
48913,
48919,
48951,
48958,
48964,
49037,
49044,
49065,
49071,
49093,
49101,
49123,
49152,
49233,
49253,
49259,
49274,
49423,
49458,
49471,
49479,
49485,
49532,
49549,
49557,
49579,
49587,
49609,
49638,
49651,
49657,
49672,
49725,
49738,
49746,
49795,
49803,
49809,
49827,
49834,
49840,
49916,
49923,
49944,
49950,
49972,
49980,
50002,
50031,
50112,
50132,
50138,
50153,
50331,
50344,
50352,
50358,
50405,
50422,
50430,
50484,
50534,
50542,
50548,
50566,
50573,
50579,
50660,
50667,
50692,
50700,
50780,
50808,
50816,
50822,
50869,
50889,
50911,
50919,
50941,
50970,
50998,
51004,
51019,
51057,
51070,
51078,
51084,
51175,
51238,
51244,
51290,
51353,
51359,
51390,
51473,
51481,
51527,
51535,
51541,
51586,
51698,
51751,
51757,
51783,
51866,
51874,
51919,
51927,
51933,
51993,
52125,
52209,
52215,
52268,
52274,
52303,
52386,
52394,
52442,
52450,
52456,
52511,
52586,
52649,
52702,
52785,
52793,
52839,
52847,
52853,
52894,
52901,
52907,
53005,
53012,
53037,
53045,
53123,
53143,
53151,
53157,
53181,
53203,
53211,
53233,
53262,
53282,
53288,
53303,
53346,
53359,
53367,
53373,
53396,
53404,
53496,
53516,
53524,
53530,
53549,
53584,
53627,
53635,
53660,
53688,
53696,
53788,
53821,
53842,
53850,
53879,
53887,
53893,
53959,
54007,
54015,
54180,
54186,
54214,
54230,
54330,
54348,
54356,
54383,
54411,
54419,
54427,
54435,
54443,
54449,
54488,
54564,
54570,
54589,
54596,
54602,
54702,
54709,
54734,
54742,
54827,
54847,
54855,
54861,
54883,
54891,
54913,
54942,
54962,
54968,
54983,
54996,
55004,
55010,
55063,
55090,
55110,
55116,
55132,
55153,
55188,
55233,
55241,
55342,
55348,
55395,
55449,
55455,
55476,
55557,
55565,
55622,
55630,
55636,
55655,
55663,
55695,
55910,
55940,
55948,
55956,
55962,
56001,
56077,
56083,
56117,
56184,
56244,
56263,
56270,
56276,
56351,
56358,
56383,
56391,
56476,
56496,
56504,
56510,
56532,
56540,
56562,
56591,
56611,
56617,
56632,
56645,
56653,
56659,
56712,
56739,
56747,
56767,
56775,
56781,
56806,
56932,
57006,
57036,
57042,
57081,
57142,
57148,
57182,
57249,
57309,
57328,
57335,
57341,
57424,
57431,
57453,
57461,
57483,
57512,
57540,
57546,
57561,
57613,
57663,
57676,
57684,
57690,
57715,
57723,
57815,
57843,
57851,
57857,
57904,
57927,
57955,
57961,
58005,
58138,
58212,
58218,
58264,
58327,
58333,
58360,
58443,
58451,
58577,
58583,
58630,
58646,
58703,
58784,
58792,
58839,
58847,
58855,
58861,
58883,
58936,
58942,
58964,
58971,
58977,
59059,
59066,
59091,
59099,
59191,
59211,
59219,
59225,
59247,
59255,
59277,
59306,
59326,
59332,
59347,
59402,
59455,
59468,
59476,
59482,
59532,
59569,
59613,
59619,
59708,
59771,
59795,
59834,
59842,
59892,
59915,
59934,
59940,
59991,
59999,
60017,
60024,
60030,
60126,
60133,
60158,
60166,
60258,
60278,
60286,
60292,
60316,
60338,
60346,
60368,
60397,
60417,
60423,
60438,
60481,
60494,
60502,
60508,
60531,
60539,
60559,
60567,
60599,
60619,
60627,
60647,
60655,
60661,
60705,
60852,
60933,
60939,
60985,
61048,
61054,
61139,
61146,
61152,
61195,
61202,
61227,
61251,
61257,
61303,
61309,
61394,
61412,
61467,
61473,
61492,
61574,
61582,
61623,
61631,
61637,
61655,
61662,
61668,
61738,
61745,
61788,
61937,
61943,
61989,
62052,
62058,
62076,
62156,
62164,
62217,
62225,
62236,
62244,
62295,
62432,
62438,
62484,
62547,
62627,
62635,
62688,
62696,
62704,
62710,
62727,
62734,
62740,
62809,
62816,
62970,
62976,
63022,
63085,
63091,
63111,
63191,
63199,
63241,
63249,
63255,
63274,
63281,
63287,
63338,
63345,
63401,
63408,
63414,
63493,
63500,
63553,
63560,
63566,
63620,
63627,
63686,
63693,
63699,
63768,
63775,
63816,
63823,
63829,
63836,
63871,
63878,
63884,
63935,
63942,
63976,
63983,
63989,
64044,
64051,
64111,
64118,
64124,
64202,
64209,
64252,
64259,
64265,
64272,
64319,
64326,
64332,
64339,
64380,
64387,
64393,
64400,
64450,
64482,
64488,
64548,
64555,
64561,
64635,
64642,
64730,
64737,
64743,
64750,
64783,
64790,
64796,
64905,
64912,
64954,
65003,
65009,
65075,
65082,
65088,
65095,
65141,
65147,
65200,
65207,
65213,
65220,
65257,
65264,
65270,
65324,
65331,
65367,
65374,
65380,
65438,
65445,
65508,
65515,
65521,
65528,
65568,
65575,
65581,
65588,
65624,
65632,
65662,
65701,
65707,
65735,
65772,
65778,
65806,
65843,
65849,
65879,
65892,
65900,
65922,
65929,
65935,
65983,
65990,
66043,
66050,
66056,
66111,
66118,
66178,
66185,
66191,
66198,
66220,
66228,
66253,
66281,
66287,
66315,
66346,
66352,
66381,
66413,
66419,
66451,
66486,
66492,
66530,
66536,
66563,
66593,
66599,
66621,
66642,
66648,
66677,
66709,
66717,
66745,
66752,
66758,
66873,
66880,
66964,
67017,
67070,
67126,
67133,
67139,
67336,
67343,
67396,
67477,
67539,
67603,
67609,
67714,
67722,
67770,
67778,
67857,
67930,
67993,
68030,
68038,
68047,
68104,
68164,
68223,
68285,
68291,
68318,
68357,
68391,
68424,
68519,
68576,
68582,
68618,
68626,
68654,
68733,
68739,
68768,
68850,
68858,
68869,
68877,
68961,
68977,
68985,
68992,
68998,
69005,
69030,
69038,
69120,
69154,
69162,
69168,
69241,
69247,
69303,
69349,
69367,
69422,
69428,
69464,
69549,
69557,
69621,
69708,
69716,
69722,
69747,
69754,
69760,
69811,
69818,
69843,
69851,
69933,
69961,
69969,
69975,
70051,
70057,
70113,
70159,
70177,
70232,
70238,
70264,
70349,
70357,
70402,
70410,
70416,
70437,
70444,
70450,
70525,
70532,
70559,
70565,
70656,
70662,
70708,
70771,
70856,
70864,
70892,
70900,
70911,
70919,
70943,
70995,
71034,
71042,
71124,
71132,
71183,
71253,
71311,
71317,
71345,
71402,
71410,
71473,
71552,
71621,
71627,
71658,
71716,
71766,
71774,
71834,
71842,
71898,
71906,
71981,
71989,
72045,
72053,
72091,
72166,
72211,
72219,
72256,
72264,
72272,
72329,
72337,
72385,
72424,
72432,
72489,
72515,
72523,
72531,
72537,
72569,
72591,
72599,
72628,
72652,
72660,
72671,
72679,
72720,
72728,
72758,
72766,
72813,
72821,
72856,
72879,
72947,
72955,
72993,
73018,
73026,
73034,
73042,
73072,
73080,
73086,
73122,
73196,
73245,
73266,
73273,
73279,
73286,
73311,
73319,
73401,
73438,
73446,
73452,
73490,
73496,
73587,
73593,
73639,
73657,
73712,
73794,
73802,
73826,
73878,
73917,
73925,
74007,
74015,
74021,
74072,
74130,
74136,
74193,
74201,
74264,
74343,
74412,
74418,
74463,
74471,
74479,
74485,
74509,
74516,
74522,
74529,
74554,
74562,
74644,
74668,
74676,
74682,
74700,
74706,
74797,
74803,
74821,
74867,
74922,
75004,
75012,
75036,
75088,
75127,
75135,
75217,
75225,
75276,
75338,
75346,
75352,
75369,
75376,
75382,
75439,
75446,
75478,
75486,
75563,
75583,
75591,
75597,
75655,
75733,
75830,
75861,
75867,
75944,
76027,
76112,
76204,
76285,
76291,
76329,
76464,
76558,
76601,
76645,
76653,
76713,
76780,
76841,
76871,
76879,
76952,
76960,
77006,
77014,
77096,
77104,
77112,
77118,
77144,
77227,
77356,
77364,
77458,
77527,
77557,
77565,
77638,
77646,
77700,
77708,
77790,
77798,
77837,
77845,
77851,
77878,
77968,
78055,
78063,
78149,
78220,
78303,
78350,
78419,
78449,
78457,
78536,
78544,
78598,
78606,
78694,
78702,
78753,
78761,
78767,
78796,
78890,
78981,
78989,
79080,
79154,
79231,
79275,
79347,
79377,
79385,
79467,
79475,
79529,
79537,
79628,
79636,
79692,
79700,
79706,
79740,
79842,
79941,
79949,
80047,
80124,
80203,
80267,
80314,
80389,
80419,
80427,
80512,
80520,
80575,
80583,
80677,
80685,
80748,
80756,
80762,
80800,
80886,
80969,
80977,
81057,
81124,
81203,
81277,
81337,
81374,
81441,
81471,
81479,
81554,
81562,
81614,
81622,
81706,
81714,
81759,
81767,
81773,
81812,
81849,
81892,
81937,
81986,
82027,
82033,
82047,
82074,
82137,
82145,
82213,
82233,
82241,
82247,
82275,
82305,
82330,
82347,
82353,
82381,
82400,
82407,
82413,
82470,
82477,
82517,
82524,
82530,
82605,
82612,
82644,
82697,
82724,
82764,
82772,
82848,
82924,
82944,
82952,
82958,
82993,
83001,
83099,
83159,
83176,
83196,
83204,
83221,
83227,
83276,
83338,
83346,
83418,
83438,
83446,
83452,
83530,
83663,
83671,
83734,
83754,
83762,
83768,
83796,
83802,
83893,
83951,
83957,
84031,
84098,
84128,
84134,
84232,
84240,
84294,
84322,
84330,
84424,
84521,
84529,
84581,
84597,
84605,
84611,
84665,
84673,
84735,
84759,
84815,
84823,
84890,
84898,
84927,
85058,
85066,
85089,
85097,
85103,
85123,
85131,
85164,
85188,
85196,
85246,
85254,
85262,
85270,
85281,
85289,
85341,
85349,
85383,
85391,
85399,
85410,
85418,
85507,
85598,
85604,
85647,
85746,
85754,
85795,
85803,
85811,
85817,
85843,
85935,
85979,
86007,
86015,
86109,
86206,
86214,
86264,
86280,
86288,
86294,
86351,
86359,
86421,
86445,
86501,
86509,
86576,
86584,
86613,
86744,
86752,
86775,
86783,
86789,
86807,
86815,
86849,
86873,
86881,
86932,
86940,
86948,
86956,
86967,
86975,
87027,
87035,
87069,
87077,
87083,
87110,
87156,
87164,
87268,
87317,
87345,
87353,
87447,
87544,
87552,
87604,
87620,
87628,
87634,
87692,
87700,
87762,
87786,
87842,
87850,
87917,
87925,
87954,
88085,
88093,
88116,
88124,
88130,
88158,
88217,
88275,
88312,
88336,
88344,
88398,
88406,
88414,
88425,
88433,
88485,
88493,
88527,
88535,
88543,
88549,
88578,
88624,
88632,
88741,
88793,
88821,
88829,
88923,
89020,
89028,
89082,
89098,
89106,
89112,
89172,
89180,
89242,
89266,
89322,
89330,
89397,
89405,
89434,
89565,
89573,
89596,
89604,
89610,
89646,
89705,
89765,
89807,
89831,
89839,
89898,
89906,
89914,
89925,
89933,
89985,
89993,
90027,
90035,
90043,
90049,
90083,
90129,
90137,
90254,
90310,
90338,
90346,
90440,
90537,
90545,
90596,
90612,
90620,
90626,
90690,
90698,
90760,
90784,
90840,
90848,
90915,
90923,
90952,
91083,
91091,
91114,
91122,
91128,
91161,
91220,
91277,
91319,
91343,
91351,
91410,
91418,
91426,
91437,
91445,
91497,
91505,
91539,
91547,
91555,
91561,
91586,
91632,
91640,
91741,
91789,
91817,
91825,
91919,
92016,
92024,
92076,
92092,
92100,
92106,
92162,
92170,
92232,
92256,
92312,
92320,
92387,
92395,
92424,
92555,
92563,
92586,
92594,
92600,
92660,
92737,
92847,
92864,
92872,
92929,
92976,
93018,
93042,
93050,
93102,
93110,
93118,
93126,
93137,
93145,
93197,
93205,
93239,
93247,
93255,
93261,
93321,
93351,
93357,
93385,
93404,
93411,
93417,
93475,
93482,
93516,
93522,
93613,
93633,
93639,
93709,
93745,
93765,
93771,
93802,
93854,
93874,
93880,
93920,
93966,
94029,
94036,
94042,
94116,
94123,
94176,
94201,
94228,
94267,
94301,
94307,
94328,
94334,
94356,
94364,
94389,
94397,
94440,
94485,
94493,
94582,
94602,
94610,
94616,
94715,
94743,
94751,
94831,
94851,
94859,
94890,
94972,
95029,
95042,
95050,
95056,
95083,
95091,
95134,
95181,
95189,
95278,
95298,
95306,
95312,
95375,
95463,
95537,
95565,
95573,
95653,
95673,
95681,
95712,
95796,
95853,
95866,
95874,
95880,
95908,
95916,
95964,
95972,
96059,
96079,
96087,
96093,
96158,
96233,
96261,
96269,
96353,
96373,
96381,
96412,
96497,
96554,
96567,
96575,
96581,
96610,
96618,
96667,
96675,
96763,
96783,
96791,
96797,
96847,
96908,
96936,
96944,
97029,
97049,
97057,
97088,
97174,
97231,
97244,
97252,
97258,
97290,
97298,
97350,
97358,
97449,
97469,
97477,
97483,
97544,
97607,
97635,
97643,
97731,
97751,
97759,
97790,
97879,
97936,
97949,
97957,
97963,
97971,
98026,
98034,
98129,
98149,
98157,
98163,
98224,
98286,
98345,
98376,
98469,
98526,
98539,
98547,
98553,
98575,
98604,
98612,
98691,
98711,
98719,
98727,
98733,
98739,
98776,
98784,
98868,
98888,
98896,
98907,
98915,
98937,
98945,
98970,
99004,
99017,
99023,
99051,
99083,
99096,
99102,
99131,
99169,
99182,
99188,
99220,
99261,
99274,
99280,
99302,
99331,
99358,
99371,
99379,
99419,
99427,
99446,
99453,
99459,
99546,
99553,
99595,
99602,
99608,
99648,
99655,
99696,
99802,
99848,
99862,
99887,
99938,
99944,
100022,
100030,
100057,
100123,
100156,
100182,
100206,
100236,
100348,
100378,
100384,
100409,
100417,
100428,
100436,
100528,
100579,
100657,
100665,
100720,
100728,
100736,
100742,
100786,
100794,
100814,
100886,
100894,
101050,
101080,
101088,
101096,
101103,
101109,
101178,
101185,
101207,
101215,
101240,
101281,
101287,
101315,
101359,
101365,
101394,
101439,
101445,
101477,
101525,
101531,
101583,
101589,
101616,
101659,
101665,
101687,
101725,
101731,
101760,
101805,
101813,
101837,
101844,
101850,
101919,
101926,
101948,
101956,
101981,
102022,
102028,
102056,
102098,
102104,
102133,
102176,
102182,
102214,
102257,
102263,
102307,
102313,
102340,
102389,
102395,
102417,
102446,
102459,
102467,
102491,
102498,
102504,
102581,
102588,
102610,
102618,
102643,
102687,
102693,
102721,
102768,
102774,
102803,
102851,
102857,
102889,
102940,
102946,
103000,
103006,
103033,
103079,
103085,
103107,
103136,
103149,
103157,
103181,
103188,
103194,
103201,
103238,
103245,
103251,
103258,
103265,
103271,
103278,
103285,
103291,
103298,
103305,
103311,
103318,
103325,
103331,
103338,
103377,
103384,
103397,
103422,
103532,
103568,
103597,
103610,
103647,
103677,
103704,
103794,
103858,
103871,
103886,
103917,
103944,
103973,
104047,
104081,
104116,
104149,
104236,
104341,
104380,
104407,
104451,
104485,
104515,
104541,
104610,
104631,
104660,
104685,
104733,
104785,
104815,
104849,
104879,
104926,
104960,
104986,
105004,
105017,
105044,
105065,
105098,
105188,
105293,
105334,
105356,
105424,
105488,
105508,
105589,
105632,
105662,
105678,
105698,
105794,
105831,
105864,
105940,
106036,
106066,
106095,
106158,
106236,
106266,
106291,
106336,
106365,
106394,
106415,
106467,
106516,
106546,
106573,
106643,
106673,
106702,
106733,
106761,
106798,
106827,
106848,
106888,
106916,
106936,
106969,
107006,
107086,
107134,
107168,
107187,
107239,
107325,
107355,
107383,
107437,
107493,
107523,
107547,
107573,
107615,
107645,
107667,
107696,
107735,
107791,
107821,
107834,
107876,
107905,
107929,
107973,
108001,
108014,
108029,
108045,
108072,
108103,
108150,
108208,
108231,
108292,
108358,
108387,
108420,
108452,
108498,
108537,
108570,
108604,
108667,
108703,
108727,
108797,
108825,
108858,
108906,
108948,
108984,
109007,
109025,
109045,
109060,
109088,
109119,
109166,
109271,
109293,
109349,
109389,
109419,
109433,
109449,
109481,
109508,
109520,
109576,
109605,
109620,
109655,
109684,
109713,
109735,
109799,
109885,
109915,
109937,
110023,
110078,
110107,
110117,
110163,
110190,
110223,
110248,
110285,
110312,
110335,
110419,
110484,
110513,
110525,
110550,
110577,
110601,
110701,
110737,
110766,
110780,
110850,
110881,
110911,
110955,
110989,
111019,
111043,
111113,
111218,
111234,
111252,
111265,
111293,
111316,
111396,
111462,
111492,
111534,
111563,
111630,
111664,
111686,
111708,
111728,
111780,
111841,
111876,
111902,
111944,
112049,
112081,
112122,
112174,
112214,
112242,
112313,
112386,
112403,
112443,
112473,
112502,
112526,
112566,
112617,
112637,
112686,
112723,
112746,
112761,
112770,
112797,
112821,
112855,
112907,
112937,
112960,
113043,
113075,
113104,
113124,
113136,
113142,
113169,
113195,
113236,
113311,
113341,
113371,
113393,
113409,
113436,
113459,
113492,
113532,
113561,
113590,
113621,
113667,
113697,
113714,
113733,
113791,
113852,
113882,
113924,
114018,
114123,
114153,
114170,
114187,
114232,
114260,
114277,
114296,
114326,
114354,
114376,
114459,
114498,
114528,
114558,
114616,
114656,
114686,
114700,
114716,
114733,
114760,
114774,
114829,
114860,
114880,
114965,
115002,
115025,
115063,
115135,
115165,
115189,
115287,
115345,
115375,
115397,
115427,
115455,
115475,
115549,
115602,
115631,
115654,
115697,
115725,
115755,
115854,
115918,
115947,
115973,
116001,
116045,
116075,
116108,
116184,
116221,
116251,
116276,
116293,
116328,
116355,
116375,
116415,
116448,
116478,
116507,
116551,
116585,
116615,
116633,
116653,
116674,
116701,
116716,
116741,
116800,
116845,
116875,
116895,
116935,
117027,
117057,
117073,
117086,
117121,
117150,
117164,
117190,
117229,
117259,
117281,
117318,
117408,
117438,
117463,
117498,
117591,
117642,
117683,
117711,
117813,
117860,
117880,
117974,
118028,
118056,
118084,
118128,
118184,
118210,
118246,
118277,
118307,
118344,
118429,
118500,
118530,
118545,
118570,
118620,
118650,
118689,
118698,
118706,
118744,
118772,
118804,
118877,
118906,
118936,
118982,
119016,
119041,
119086,
119114,
119141,
119160,
119174,
119201,
119225,
119251,
119278,
119306,
119327,
119350,
119369,
119397,
119420,
119440,
119483,
119512,
119541,
119580,
119643,
119673,
119705,
119799,
119845,
119886,
119911,
119933,
120009,
120031,
120047,
120054,
120067,
120094,
120117,
120191,
120225,
120259,
120281,
120391,
120431,
120463,
120484,
120508,
120578,
120630,
120660,
120691,
120725,
120761,
120775,
120789,
120831,
120859,
120889,
120935,
120974,
121004,
121024,
121060,
121165,
121193,
121241,
121269,
121291,
121309,
121344,
121373,
121393,
121433,
121468,
121479,
121514,
121572,
121638,
121679,
121704,
121772,
121800,
121830,
121849,
121883,
121970,
122000,
122022,
122054,
122090,
122119,
122162,
122201,
122270,
122304,
122341,
122385,
122419,
122449,
122479,
122561,
122596,
122632,
122651,
122696,
122772,
122802,
122819,
122856,
122892,
122913,
122953,
123004,
123034,
123057,
123096,
123138,
123167,
123190,
123234,
123289,
123319,
123345,
123387,
123433,
123462,
123489,
123553,
123609,
123639,
123673,
123772,
123877,
123907,
123933,
123969,
124023,
124053,
124074,
124096,
124161,
124233,
124259,
124272,
124344,
124374,
124386,
124441,
124471,
124488,
124550,
124598,
124628,
124637,
124664,
124691,
124710,
124724,
124751,
124784,
124917,
125005,
125046,
125061,
125078,
125096,
125123,
125154,
125198,
125232,
125262,
125281,
125326,
125353,
125371,
125410,
125436,
125458,
125515,
125579,
125603,
125691,
125728,
125742,
125767,
125788,
125818,
125847,
125857,
125869,
125896,
125922,
125951,
125986,
126027,
126057,
126088,
126162,
126237,
126270,
126305,
126356,
126386,
126402,
126409,
126422,
126449,
126478,
126496,
126526,
126555,
126600,
126705,
126725,
126747,
126780,
126808,
126824,
126848,
126875,
126903,
126921,
126930,
126945,
126972,
126983,
126996,
127009,
127035,
127059,
127126,
127194,
127211,
127238,
127337,
127395,
127424,
127445,
127541,
127584,
127613,
127637,
127734,
127824,
127849,
127884,
127924,
127953,
127970,
127989,
128024,
128051,
128073,
128111,
128216,
128253,
128329,
128421,
128451,
128482,
128534,
128562,
128584,
128595,
128615,
128642,
128676,
128720,
128754,
128784,
128801,
128839,
128887,
128917,
128939,
128977,
129032,
129050,
129059,
129074,
129101,
129113,
129144,
129265,
129308,
129338,
129370,
129412,
129473,
129503,
129524,
129536,
129565,
129592,
129615,
129681,
129726,
129756,
129779,
129858,
129917,
129947,
129974,
130003,
130034,
130062,
130077,
130094,
130112,
130139,
130167,
130211,
130316,
130343,
130386,
130424,
130453,
130474,
130529,
130609,
130639,
130663,
130751,
130808,
130837,
130862,
130924,
130980,
131010,
131029,
131040,
131066,
131094,
131124,
131221,
131256,
131296,
131320,
131381,
131433,
131463,
131483,
131504,
131532,
131552,
131607,
131673,
131702,
131721,
131742,
131759,
131787,
131804,
131828,
131912,
131937,
131958,
132009,
132090,
132116,
132140,
132222,
132257,
132291,
132321,
132394,
132426,
132456,
132468,
132491,
132557,
132599,
132628,
132660,
132797,
132832,
132873,
132901,
133022,
133059,
133089,
133104,
133142,
133220,
133249,
133269,
133321,
133369,
133398,
133427,
133504,
133538,
133578,
133607,
133712,
133744,
133760,
133790,
133838,
133868,
133892,
133932,
134037,
134059,
134071,
134110,
134137,
134160,
134268,
134302,
134332,
134349,
134384,
134425,
134454
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 134454,
"ccnet_original_nlines": 4133,
"rps_doc_curly_bracket": 0.006113620009273291,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.08838603645563126,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.022210409864783287,
"rps_doc_frac_lines_end_with_ellipsis": 0.0036284499801695347,
"rps_doc_frac_no_alph_words": 0.5335054397583008,
"rps_doc_frac_unique_words": 0.3437785506248474,
"rps_doc_mean_word_length": 6.9945197105407715,
"rps_doc_num_sentences": 1410,
"rps_doc_symbol_to_word_ratio": 0.0017844300018623471,
"rps_doc_unigram_entropy": 6.94187593460083,
"rps_doc_word_count": 14233,
"rps_doc_frac_chars_dupe_10grams": 0.02852752059698105,
"rps_doc_frac_chars_dupe_5grams": 0.2056894302368164,
"rps_doc_frac_chars_dupe_6grams": 0.15895050764083862,
"rps_doc_frac_chars_dupe_7grams": 0.11182987689971924,
"rps_doc_frac_chars_dupe_8grams": 0.07526644319295883,
"rps_doc_frac_chars_dupe_9grams": 0.05180155113339424,
"rps_doc_frac_chars_top_2gram": 0.016513820737600327,
"rps_doc_frac_chars_top_3gram": 0.008357360027730465,
"rps_doc_frac_chars_top_4gram": 0.014062860049307346,
"rps_doc_books_importance": -13171.681640625,
"rps_doc_books_importance_length_correction": -13171.681640625,
"rps_doc_openwebtext_importance": -8931.1064453125,
"rps_doc_openwebtext_importance_length_correction": -8931.1064453125,
"rps_doc_wikipedia_importance": -6699.94677734375,
"rps_doc_wikipedia_importance_length_correction": -6699.94677734375
},
"fasttext": {
"dclm": 0.4072319269180298,
"english": 0.11745154857635498,
"fineweb_edu_approx": 1.9374754428863525,
"eai_general_math": 0.4596167206764221,
"eai_open_web_math": 0.0650951936841011,
"eai_web_code": 0.632591187953949
}
}
|
{
"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.019",
"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": "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
|
3,468,657,724,537,405,400
|
Psychological profiling for a shopping bargain
iBeacons
Comment on “Is sending shoppers ads by Bluetooth just a bit creepy?” in the Conversation.
Professor Angela Sasse and Dr Charlene Jennett, based at the UCL Interaction Centre (UCLIC), are interested in understanding how people interact with technology and in particular, the use of proximity ‘beacons’. iBeacon is one such indoor proximity system that can trigger actions on smart phones and other devices. This new technology has already been trialled in the retail sector to simplify payments and enable on-site offers and personalised adverts to customers. Whilst seemingly offering consumers a quicker and more streamlined shopping experience, the application of the technology also raises a number of ethical issues that require consideration.
According to studies by the UCL Interaction Centre, personalised ads are more likely to be noticed by customers but the probability of accepting or rejecting a tailored advert will depend on the customers’ specific needs at that exact time, which are not easy to predict. This ‘unpredictable’ decision-making behaviour poses one of the biggest challenges for smartphone advertising. Obtaining sensitive, fine-grain data on the customer’s emotional state and information about their immediate circumstances could generate more accurate and profitable predictions but at a potentially high price to the privacy and psychological integrity of the customer who’s personal and intimate data is being mined.
Even if developers of technologies such as the iBeacons are well intentioned, it is important to remember that the primary purpose is to serve the interest of businesses who are trying to sell products more effectively. In exchange for easier access to products and special offers, prospective users (that is, customers) are asked to provide a deep level of access to the data of their private lives. Personal information is then processed by companies to build psychological profiles that can be matched to specific marketing strategies. If the service is provided using the standard methodology of ‘big data’ services, the users transmit their data to a central database, maintained by the service provider company.
From this point onwards, the power balance in the relationship between the user and the service provider is heavily tilted towards the service provider. With typically very limited transparency the user will have to trust that the service provider: 1) has sufficient security to safeguard against theft of the user’s data; 2) will analyse the data only to the extent necessary for the purpose of providing the agreed upon service; 3) will not sell the data to third parties; 4) will properly remove all the data they hold of the user if/when the user indicates a wish to withdraw from the service; 5) will refrain from using the data to nudge the user into irresponsible spending behaviour.
Experiments such as those performed by Prof. Sasse and Dr Jennett can help us to understand human behaviour and have the potential to greatly improve and optimize people’s daily activities. At the same time, however, the ethical issues associated with studies serve as a reminder that researchers have a responsibility to consider the potential power imbalance between the user and the service provider that can be introduced by devices such as the iBeacon, and should contribute to the development of new operating principles to safeguard the rights of individuals.
With this in mind, the CaSMa project is looking at solutions that put people at the centre of human data by introducing a novel citizen-centred approach to social media analysis. CaSMa aims to promote ways for individuals to control their data and their desired level of privacy, including mechanisms that make it realistically possible to implement a withdrawal of consent. Indeed, one of the core CaSMa objectives is to ensure that social media users are aware of how their personal data can be used to understand human behaviour and the ethics of handling human data obtained from online sources.
|
{
"url": "https://casma.wp.horizon.ac.uk/2014/10/28/46/",
"source_domain": "casma.wp.horizon.ac.uk",
"snapshot_id": "crawl=CC-MAIN-2017-09",
"warc_metadata": {
"Content-Length": "76729",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:JRJD3TVPHA23BDXUY4THEJBYKPLR24JZ",
"WARC-Concurrent-To": "<urn:uuid:4e2cd939-f415-48e9-a685-236d5b9505b7>",
"WARC-Date": "2017-02-21T16:32:20Z",
"WARC-IP-Address": "40.115.2.71",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:IIRGEL63BZHX3ZRPJ7KLEAFTNXD3QA3G",
"WARC-Record-ID": "<urn:uuid:01896213-3df8-4c7c-a640-58fa3bfcfccf>",
"WARC-Target-URI": "https://casma.wp.horizon.ac.uk/2014/10/28/46/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:aad03a5b-1398-42b6-bb7d-cea269079d21>"
},
"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,
47,
48,
57,
58,
148,
149,
807,
808,
809,
1511,
1512,
2230,
2921,
2922,
3489,
3490
],
"line_end_idx": [
47,
48,
57,
58,
148,
149,
807,
808,
809,
1511,
1512,
2230,
2921,
2922,
3489,
3490,
4089
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4089,
"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.43115437030792236,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.004172460176050663,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.10292071849107742,
"rps_doc_frac_unique_words": 0.5085803270339966,
"rps_doc_mean_word_length": 5.2761311531066895,
"rps_doc_num_sentences": 21,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.156957149505615,
"rps_doc_word_count": 641,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.037847429513931274,
"rps_doc_frac_chars_dupe_6grams": 0.020697809755802155,
"rps_doc_frac_chars_dupe_7grams": 0.020697809755802155,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.020697809755802155,
"rps_doc_frac_chars_top_3gram": 0.02661146968603134,
"rps_doc_frac_chars_top_4gram": 0.013601420447230339,
"rps_doc_books_importance": -269.003662109375,
"rps_doc_books_importance_length_correction": -269.003662109375,
"rps_doc_openwebtext_importance": -165.1602325439453,
"rps_doc_openwebtext_importance_length_correction": -165.1602325439453,
"rps_doc_wikipedia_importance": -159.98870849609375,
"rps_doc_wikipedia_importance_length_correction": -159.98870849609375
},
"fasttext": {
"dclm": 0.45221632719039917,
"english": 0.9471039772033691,
"fineweb_edu_approx": 2.0762410163879395,
"eai_general_math": 0.2044880986213684,
"eai_open_web_math": 0.15728533267974854,
"eai_web_code": 0.2692776322364807
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.689",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "153.9",
"labels": {
"level_1": "Philosophy and psychology",
"level_2": "Psychology",
"level_3": "Thought and thinking"
}
}
},
"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": "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": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "10",
"label": "Knowledge Article"
},
"secondary": {
"code": "13",
"label": "News (Org.)"
}
},
"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
|
-14,642,593,058,252,374
|
View Javadoc
1 package org.apache.juddi.adminconsole.hub;
2
3 /*
4 * Copyright 2001-2013 The Apache Software Foundation.
5 *
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 *
18 */
19 import java.io.InputStream;
20 import java.io.StringReader;
21 import java.io.StringWriter;
22 import java.math.BigInteger;
23 import java.net.URL;
24 import java.rmi.RemoteException;
25 import java.util.ArrayList;
26 import java.util.List;
27 import java.util.Map;
28 import java.util.Properties;
29 import java.util.logging.Level;
30 import java.util.logging.Logger;
31 import javax.persistence.EntityManager;
32 import javax.persistence.EntityTransaction;
33 import javax.persistence.Query;
34 import javax.servlet.ServletContext;
35 import javax.servlet.http.HttpServletRequest;
36 import javax.servlet.http.HttpSession;
37 import javax.xml.XMLConstants;
38 import javax.xml.bind.JAXB;
39 import javax.xml.datatype.DatatypeConfigurationException;
40 import javax.xml.parsers.DocumentBuilder;
41 import javax.xml.parsers.DocumentBuilderFactory;
42 import javax.xml.transform.OutputKeys;
43 import javax.xml.transform.Transformer;
44 import javax.xml.transform.TransformerFactory;
45 import javax.xml.transform.dom.DOMSource;
46 import javax.xml.transform.stream.StreamResult;
47 import javax.xml.transform.stream.StreamSource;
48 import javax.xml.ws.BindingProvider;
49 import javax.xml.ws.Holder;
50 import org.apache.commons.configuration.Configuration;
51 import org.apache.commons.configuration.ConfigurationException;
52 import org.apache.commons.lang.StringEscapeUtils;
53 import org.apache.commons.logging.Log;
54 import org.apache.commons.logging.LogFactory;
55 import org.apache.juddi.api_v3.Clerk;
56 import org.apache.juddi.api_v3.ClientSubscriptionInfoDetail;
57 import org.apache.juddi.api_v3.DeleteClientSubscriptionInfo;
58 import org.apache.juddi.api_v3.DeletePublisher;
59 import org.apache.juddi.api_v3.GetAllPublisherDetail;
60 import org.apache.juddi.api_v3.GetPublisherDetail;
61 import org.apache.juddi.api_v3.Node;
62 import org.apache.juddi.api_v3.Publisher;
63 import org.apache.juddi.api_v3.PublisherDetail;
64 import org.apache.juddi.api_v3.SaveClerk;
65 import org.apache.juddi.api_v3.SaveClientSubscriptionInfo;
66 import org.apache.juddi.api_v3.SaveNode;
67 import org.apache.juddi.api_v3.SavePublisher;
68 import org.apache.juddi.api_v3.SyncSubscription;
69 import org.apache.juddi.api_v3.SyncSubscriptionDetail;
70 import org.apache.juddi.v3.client.UDDIConstants;
71 import org.apache.juddi.v3.client.config.ClientConfig;
72 import org.apache.juddi.v3.client.config.UDDIClient;
73 import org.apache.juddi.v3.client.config.UDDINode;
74 import org.apache.juddi.v3.client.transport.Transport;
75 import org.apache.juddi.v3_service.JUDDIApiPortType;
76 import org.apache.juddi.adminconsole.AES;
77 import org.apache.juddi.adminconsole.resources.ResourceLoader;
78 import org.apache.juddi.api.impl.JUDDIApiImpl;
79 import org.apache.juddi.api.impl.UDDIInquiryImpl;
80 import org.apache.juddi.api.impl.UDDIPublicationImpl;
81 import org.apache.juddi.api.impl.UDDIReplicationImpl;
82 import org.apache.juddi.api_v3.AdminSaveBusiness;
83 import org.apache.juddi.api_v3.AdminSaveSubscriptionRequest;
84 import org.apache.juddi.api_v3.AdminSaveSubscriptionResponse;
85 import org.apache.juddi.api_v3.AdminSaveTModel;
86 import org.apache.juddi.api_v3.ClerkList;
87 import org.apache.juddi.api_v3.ClientSubscriptionInfo;
88 import org.apache.juddi.api_v3.DeleteClerk;
89 import org.apache.juddi.api_v3.DeleteNode;
90 import org.apache.juddi.api_v3.GetEntityHistoryMessageRequest;
91 import org.apache.juddi.api_v3.GetEntityHistoryMessageResponse;
92 import org.apache.juddi.api_v3.GetFailedReplicationChangeRecordsMessageRequest;
93 import org.apache.juddi.api_v3.GetFailedReplicationChangeRecordsMessageResponse;
94 import org.apache.juddi.api_v3.NodeList;
95 import org.apache.juddi.api_v3.SubscriptionWrapper;
96 import org.apache.juddi.config.AppConfig;
97 import org.apache.juddi.config.PersistenceManager;
98 import org.apache.juddi.config.Property;
99 import org.apache.juddi.model.BindingTemplate;
100 import org.apache.juddi.subscription.notify.SMTPNotifier;
101 import org.apache.juddi.v3.client.cryptor.XmlUtils;
102 import org.uddi.api_v3.AuthToken;
103 import org.uddi.api_v3.BusinessDetail;
104 import org.uddi.api_v3.BusinessEntity;
105 import org.uddi.api_v3.BusinessService;
106 import org.uddi.api_v3.DeleteBusiness;
107 import org.uddi.api_v3.DeleteTModel;
108 import org.uddi.api_v3.DiscardAuthToken;
109 import org.uddi.api_v3.DispositionReport;
110 import org.uddi.api_v3.FindBusiness;
111 import org.uddi.api_v3.FindQualifiers;
112 import org.uddi.api_v3.GetAuthToken;
113 import org.uddi.api_v3.GetBusinessDetail;
114 import org.uddi.api_v3.Name;
115 import org.uddi.api_v3.SaveBusiness;
116 import org.uddi.repl_v3.ChangeRecordIDType;
117 import org.uddi.repl_v3.ChangeRecords;
118 import org.uddi.repl_v3.GetChangeRecords;
119 import org.uddi.repl_v3.HighWaterMarkVectorType;
120 import org.uddi.repl_v3.ReplicationConfiguration;
121 import org.uddi.sub_v3.Subscription;
122 import org.uddi.sub_v3.SubscriptionResultsList;
123 import org.uddi.subr_v3.NotifySubscriptionListener;
124
125 import org.uddi.v3_service.DispositionReportFaultMessage;
126 import org.uddi.v3_service.UDDISecurityPortType;
127 import org.w3c.dom.Document;
128 import org.xml.sax.InputSource;
129
130 /**
131 * UddiHub - The hub acts as a single point for managing browser to uddi
132 * services. At most 1 instance is allowed per http session. In general, all
133 * methods in the class trigger web service call outs. All callouts also support
134 * expired UDDI tokens and will attempt to reauthenticate and retry the request.
135 *
136 * @author <a href="mailto:alexoree@apache.org">Alex O'Ree</a>
137 */
138 public class UddiAdminHub {
139
140 /**
141 * The logger name
142 */
143 public static final String LOGGER_NAME = "org.apache.juddi";
144 transient AuthStyle style = null;
145 Properties properties = null;
146 /**
147 * The Log4j logger. This is also referenced from the Builders class,
148 * thus it is public
149 */
150 public static final Log log = LogFactory.getLog(LOGGER_NAME);
151
152 private UddiAdminHub() throws DatatypeConfigurationException {
153 // df = DatatypeFactory.newInstance();
154 }
155
156 /**
157 * removes the Hub from the current http session
158 *
159 * @param _session
160 */
161 public static void reset(HttpSession _session) {
162 _session.removeAttribute("hub");
163 // token = null;
164 }
165
166 /**
167 * This kills any authentication tokens, logs the user out and nulls out
168 * all services
169 */
170 public void die() {
171 if (token != null && security != null) {
172 DiscardAuthToken da = new DiscardAuthToken();
173 da.setAuthInfo(token);
174 try {
175 security.discardAuthToken(da);
176 } catch (Exception ex) {
177 HandleException(ex);
178 }
179 }
180 token = null;
181 security = null;
182 juddi = null;
183 }
184 /**
185 * the name of the 'node' property in the config
186 */
187 public static final String PROP_CONFIG_NODE = "config.props.node";
188 /**
189 *
190 */
191 public static final String PROP_AUTH_TYPE = "config.props.authtype";
192 /**
193 *
194 */
195 public static final String PROP_AUTO_LOGOUT = "config.props.automaticLogouts.enable";
196 /**
197 *
198 */
199 public static final String PROP_AUTO_LOGOUT_TIMER = "config.props.automaticLogouts.duration";
200 /**
201 *
202 */
203 public static final String PROP_PREFIX = "config.props.";
204 /**
205 *
206 *
207 */
208 public static final String PROP_ADMIN_LOCALHOST_ONLY = "config.props.configLocalHostOnly";
209
210 private transient UDDISecurityPortType security = null;
211 private transient JUDDIApiPortType juddi = null;
212 private transient String token = null;
213 private transient HttpSession session;
214 private transient Transport transport = null;
215 private transient ClientConfig clientConfig;
216 private static final long serialVersionUID = 1L;
217 private String nodename = "default";
218 private final String clientName = "juddigui";
219 private boolean WS_Transport = false;
220 private boolean WS_securePorts = false;
221
222 /**
223 * This is the singleton accessor UddiHub. There should be at most 1
224 * instance per HTTP Session (user login)
225 *
226 * @param application
227 * @param _session
228 * @return instance
229 * @throws Exception
230 */
231 public static UddiAdminHub getInstance(ServletContext application, HttpSession _session) throws Exception {
232 Object j = _session.getAttribute("hub");
233 if (j == null) {
234 UddiAdminHub hub = new UddiAdminHub(application, _session);
235 _session.setAttribute("hub", hub);
236 return hub;
237 }
238
239 return (UddiAdminHub) j;
240 }
241 String locale = "en";
242
243 private UddiAdminHub(ServletContext application, HttpSession _session) throws Exception {
244 URL prop = application.getResource("/WEB-INF/config.properties");
245 if (prop == null) {
246 application.getResource("WEB-INF/config.properties");
247 }
248 if (prop == null) {
249 throw new Exception("Cannot locate the configuration file.");
250 }
251 session = _session;
252
253 InputStream in = prop.openStream();
254 Properties p = new Properties();
255 p.load(in);
256 in.close();
257 session = _session;
258 properties = p;
259 EnsureConfig();
260 }
261
262 private void EnsureConfig() {
263 if (clientConfig == null) {
264 try {
265 UDDIClient client = new UDDIClient();
266
267 clientConfig = client.getClientConfig();
268 try {
269 style = AuthStyle.valueOf(clientConfig.getConfiguration().getString(PROP_AUTH_TYPE));
270 } catch (Exception ex) {
271 log.warn("'UDDI_AUTH' is not defined in the config (" + PROP_AUTH_TYPE + ")! defaulting to UDDI_AUTH");
272 style = AuthStyle.UDDI_AUTH;
273 }
274
275 nodename = clientConfig.getConfiguration().getString(PROP_CONFIG_NODE);
276 if (nodename == null || nodename.equals("")) {
277 log.warn("'node' is not defined in the config! defaulting to 'default'");
278 nodename = "default";
279 }
280 UDDINode uddiNode = clientConfig.getUDDINode(nodename);
281
282 String clazz = uddiNode.getProxyTransport();
283 if (clazz.contains("JAXWSTransport")) {
284 WS_Transport = true;
285 }
286
287 transport = client.getTransport(nodename);
288 security = transport.getUDDISecurityService();
289 juddi = transport.getJUDDIApiService();
290 if (WS_Transport) {
291 if (uddiNode.getJuddiApiUrl().toLowerCase().startsWith("https://")
292 && (uddiNode.getSecurityUrl() != null && uddiNode.getSecurityUrl().toLowerCase().startsWith("https://"))) {
293 WS_securePorts = true;
294 }
295 }
296
297 } catch (Exception ex) {
298 HandleException(ex);
299 }
300 }
301
302 }
303
304 /**
305 * This function provides a basic error handling rutine that will pull
306 * out the true error message in a UDDI fault message, returning
307 * bootstrap stylized html error message
308 *
309 * @param ex
310 * @return
311 */
312 private String HandleException(Exception ex) {
313 if (ex instanceof DispositionReportFaultMessage) {
314 DispositionReportFaultMessage f = (DispositionReportFaultMessage) ex;
315 log.error(ex.getMessage() + (f.detail != null && f.detail.getMessage() != null ? StringEscapeUtils.escapeHtml(f.detail.getMessage()) : ""));
316 log.debug(ex.getMessage(), ex);
317 return ResourceLoader.GetResource(session, "errors.generic") + " " + StringEscapeUtils.escapeHtml(ex.getMessage()) + " " + (f.detail != null && f.detail.getMessage() != null ? StringEscapeUtils.escapeHtml(f.detail.getMessage()) : "");
318 } else if (ex instanceof RemoteException) {
319 RemoteException f = (RemoteException) ex;
320 log.error("RemoteException " + ex.getMessage());
321 log.debug("RemoteException " + ex.getMessage(), ex);
322 return ResourceLoader.GetResource(session, "errors.generic") + " " + StringEscapeUtils.escapeHtml(ex.getMessage()) + " " + (f.detail != null && f.detail.getMessage() != null ? StringEscapeUtils.escapeHtml(f.detail.getMessage()) : "");
323 } else if (ex instanceof NullPointerException) {
324 log.error("NPE! Please report! " + ex.getMessage(), ex);
325 log.debug("NPE! Please report! " + ex.getMessage(), ex);
326 return ResourceLoader.GetResource(session, "errors.generic") + " " + StringEscapeUtils.escapeHtml(ex.getMessage());
327 } else {
328 log.error("Unexpected error " + ex.getMessage(), ex);
329 //log.debug(ex.getMessage(), ex);
330 return ResourceLoader.GetResource(session, "errors.generic") + " " + StringEscapeUtils.escapeHtml(ex.getMessage());
331 }
332 }
333
334 /**
335 * returns true if we are using JAXWS transport AND all of the URLs
336 * start with https://
337 *
338 * @return true/false
339 */
340 public boolean isSecure() {
341
342 EnsureConfig();
343 return WS_securePorts;
344 }
345
346 /**
347 * gets a reference to the current juddi client config file. this is a
348 * live instance changes can be stored to disk, usually
349 *
350 * @return client config
351 * @throws ConfigurationException g
352 */
353 public ClientConfig GetJuddiClientConfig() throws ConfigurationException {
354 EnsureConfig();
355 return clientConfig;
356 }
357
358 /**
359 * Handles all API calls to the juddi web service
360 *
361 * @param parameters
362 * @return html formatted status message
363 */
364 public String go(HttpServletRequest parameters) {
365 try {
366 String action = parameters.getParameter("soapaction");
367 if (action.equalsIgnoreCase("adminDelete_tmodel")) {
368 return adminDelete_tmodel(parameters);
369 } else if (action.equalsIgnoreCase("delete_ClientSubscriptionInfo")) {
370 return delete_ClientSubscriptionInfo(parameters);
371 } else if (action.equalsIgnoreCase("delete_publisher")) {
372 return delete_publisher(parameters);
373 } else if (action.equalsIgnoreCase("getAllPublisherDetail")) {
374 return getAllPublisherDetail(parameters);
375 } else if (action.equalsIgnoreCase("get_publisherDetail")) {
376 return get_publisherDetail(parameters);
377 } else if (action.equalsIgnoreCase("invoke_SyncSubscription")) {
378 return invoke_SyncSubscription(parameters);
379 } else if (action.equalsIgnoreCase("save_Clerk")) {
380 return save_Clerk(parameters);
381 } else if (action.equalsIgnoreCase("save_ClientSubscriptionInfo")) {
382 return save_ClientSubscriptionInfo(parameters);
383 } else if (action.equalsIgnoreCase("save_Node")) {
384 return save_Node(parameters);
385 } else if (action.equalsIgnoreCase("save_publisher")) {
386 return save_publisher(parameters);
387 } else if (action.equalsIgnoreCase("send_EmailTest")) {
388 return sendTestEmail(parameters);
389 } else if (action.equalsIgnoreCase("get_AllNodes")) {
390 return getAllNodes(parameters);
391 } else if (action.equalsIgnoreCase("get_AllClerks")) {
392 return getAllClerks(parameters);
393 } else if (action.equalsIgnoreCase("delete_Node")) {
394 return deleteNode(parameters);
395 } else if (action.equalsIgnoreCase("delete_Clerk")) {
396 return deleteClerk(parameters);
397 } else if (action.equalsIgnoreCase("admin_DeleteSubscription")) {
398 return deleteSubscription(parameters);
399 } else if (action.equalsIgnoreCase("admin_SaveBusiness")) {
400 return adminSaveBusiness(parameters);
401 } else if (action.equalsIgnoreCase("admin_SaveTModel")) {
402 return adminSaveTmodel(parameters);
403 } else if (action.equalsIgnoreCase("get_AllClientSubscriptionInfo")) {
404 return getAllClientSubscriptionInfo(parameters);
405 } else if (action.equalsIgnoreCase("set_ReplicationNodes")) {
406 return setReplicationConfig(parameters);
407 } else if (action.equalsIgnoreCase("get_ReplicationNodes")) {
408 return getReplicationNodes(parameters);
409 } else if (action.equalsIgnoreCase("admin_SaveSubscription")) {
410 return adminSaveSubscription(parameters);
411 } else if (action.equalsIgnoreCase("get_EntityHistory")) {
412 return getEntityHistory(parameters);
413 } else if (action.equalsIgnoreCase("change_NodeID")) {
414 return change_NodeID(parameters);
415 } else if (action.equalsIgnoreCase("changeRecord")) {
416 return getChangeRecord(parameters);
417 } else if (action.equalsIgnoreCase("getFailedReplicationChangeRecords")) {
418 return getFailedReplicationChangeRecords(parameters);
419 }
420
421 } catch (Exception ex) {
422 return "Error!" + HandleException(ex);
423 }
424 return "not yet implemented!";
425 }
426
427 private String save_Clerk(HttpServletRequest parameters) {
428 SaveClerk sc = new SaveClerk();
429 sc.setAuthInfo(GetToken());
430 Clerk c = new Clerk();
431 c.setName(parameters.getParameter("CLERKsetName"));
432 Node node = new Node();
433 node.setClientName(parameters.getParameter("CLERKNODEsetClientName"));
434 node.setCustodyTransferUrl(parameters.getParameter("CLERKNODEsetCustodyTransferUrl"));
435 node.setDescription(parameters.getParameter("CLERKNODEsetDescription"));
436 node.setFactoryInitial(parameters.getParameter("CLERKNODEsetFactoryInitial"));
437 node.setFactoryNamingProvider(parameters.getParameter("CLERKNODEsetFactoryNamingProvider"));
438 node.setFactoryURLPkgs(parameters.getParameter("CLERKNODEsetFactoryURLPkgs"));
439 node.setInquiryUrl(parameters.getParameter("CLERKNODEsetInquiryUrl"));
440 node.setJuddiApiUrl(parameters.getParameter("CLERKNODEsetJuddiApiUrl"));
441 node.setName(parameters.getParameter("CLERKNODEsetName"));
442 node.setProxyTransport(parameters.getParameter("CLERKNODEsetProxyTransport"));
443 node.setPublishUrl(parameters.getParameter("CLERKNODEsetPublishUrl"));
444 node.setReplicationUrl(parameters.getParameter("CLERKNODEsetReplicationUrl"));
445 node.setSecurityUrl(parameters.getParameter("CLERKNODEsetSecurityUrl"));
446 node.setSubscriptionListenerUrl(parameters.getParameter("CLERKNODEsetSubscriptionListenerUrl"));
447 node.setSubscriptionUrl(parameters.getParameter("CLERKNODEsetSubscriptionUrl"));
448 c.setNode(node);
449 c.setPassword(parameters.getParameter("CLERKsetPassword"));
450 c.setPublisher(parameters.getParameter("CLERKsetPublisher"));
451
452 sc.getClerk().add(c);
453 try {
454 juddi.saveClerk(sc);
455 } catch (Exception ex) {
456 if (isExceptionExpiration(ex)) {
457 token = null;
458 sc.setAuthInfo(GetToken());
459 try {
460 juddi.saveClerk(sc);
461 } catch (Exception ex1) {
462 return "Error!" + HandleException(ex1);
463 }
464
465 } else {
466 return "Error!" + HandleException(ex);
467 }
468 }
469 return "Success";
470 }
471
472 private String save_Node(HttpServletRequest parameters) {
473 SaveNode sn = new SaveNode();
474 sn.setAuthInfo(GetToken());
475 Node node = new Node();
476 node.setClientName(parameters.getParameter("NODEsetClientName"));
477 node.setCustodyTransferUrl(parameters.getParameter("NODEsetCustodyTransferUrl"));
478 node.setDescription(parameters.getParameter("NODEsetDescription"));
479 node.setFactoryInitial(parameters.getParameter("NODEsetFactoryInitial"));
480 node.setFactoryNamingProvider(parameters.getParameter("NODEsetFactoryNamingProvider"));
481 node.setFactoryURLPkgs(parameters.getParameter("NODEsetFactoryURLPkgs"));
482 node.setInquiryUrl(parameters.getParameter("NODEsetInquiryUrl"));
483 node.setJuddiApiUrl(parameters.getParameter("NODEsetJuddiApiUrl"));
484 node.setName(parameters.getParameter("NODEsetName"));
485 node.setProxyTransport(parameters.getParameter("NODEsetProxyTransport"));
486 node.setPublishUrl(parameters.getParameter("NODEsetPublishUrl"));
487 node.setReplicationUrl(parameters.getParameter("NODEsetReplicationUrl"));
488 node.setSecurityUrl(parameters.getParameter("NODEsetSecurityUrl"));
489 node.setSubscriptionListenerUrl(parameters.getParameter("NODEsetSubscriptionListenerUrl"));
490 node.setSubscriptionUrl(parameters.getParameter("NODEsetSubscriptionUrl"));
491 sn.getNode().add(node);
492
493 try {
494 juddi.saveNode(sn);
495 } catch (Exception ex) {
496 if (isExceptionExpiration(ex)) {
497 token = null;
498 sn.setAuthInfo(GetToken());
499 try {
500 juddi.saveNode(sn);
501 } catch (Exception ex1) {
502 return "Error!" + HandleException(ex1);
503 }
504
505 } else {
506 return "Error!" + HandleException(ex);
507 }
508 }
509 return "Success";
510 }
511
512 private String sendTestEmail(HttpServletRequest parameters) {
513 try {
514
515 String to = parameters.getParameter("send_EmailTestEMAIL");
516 if (!to.startsWith("mailto:")) {
517 to = "mailto:" + to;
518 }
519 BindingTemplate modellbt = new BindingTemplate("test", null, "endpoint", to, null, null, null, null, null);
520 org.apache.juddi.subscription.notify.SMTPNotifier smtp = new SMTPNotifier(modellbt);
521 NotifySubscriptionListener body = new NotifySubscriptionListener();
522
523 body.setSubscriptionResultsList(new SubscriptionResultsList());
524 body.getSubscriptionResultsList().setSubscription(new Subscription());
525 body.getSubscriptionResultsList().getSubscription().setSubscriptionKey("TEST");
526 smtp.notifySubscriptionListener(body);
527 return "Success";
528 } catch (Exception ex) {
529 return "Failure!" + HandleException(ex);
530 }
531 }
532
533 private String getAllNodes(HttpServletRequest parameters) {
534 NodeList allNodes = null;
535 try {
536
537 allNodes = juddi.getAllNodes(GetToken());
538 } catch (Exception ex) {
539
540 if (isExceptionExpiration(ex)) {
541 token = null;
542 try {
543 allNodes = juddi.getAllNodes(GetToken());
544 } catch (Exception ex1) {
545 return HandleException(ex1);
546 }
547 } else {
548 return HandleException(ex);
549 }
550 }
551 try {
552 return PrettyPrintJaxbObject(allNodes);
553 } catch (Exception ex) {
554 return HandleException(ex);
555 }
556
557 }
558
559 private String getAllClerks(HttpServletRequest parameters) {
560 ClerkList allNodes = null;
561 try {
562
563 allNodes = juddi.getAllClerks(GetToken());
564 } catch (Exception ex) {
565
566 if (isExceptionExpiration(ex)) {
567 token = null;
568 try {
569 allNodes = juddi.getAllClerks(GetToken());
570 } catch (Exception ex1) {
571 return HandleException(ex1);
572 }
573 } else {
574 return HandleException(ex);
575 }
576 }
577 try {
578 return PrettyPrintJaxbObject(allNodes);
579 } catch (Exception ex) {
580 return HandleException(ex);
581 }
582 }
583
584 private String getAllClientSubscriptionInfo(HttpServletRequest parameters) {
585 List<SubscriptionWrapper> allClientSubscriptionInfo = null;
586 try {
587
588 allClientSubscriptionInfo = juddi.getAllClientSubscriptionInfo(GetToken());
589 } catch (Exception ex) {
590
591 if (isExceptionExpiration(ex)) {
592 token = null;
593 try {
594 allClientSubscriptionInfo = juddi.getAllClientSubscriptionInfo(GetToken());
595 } catch (Exception ex1) {
596 return HandleException(ex1);
597 }
598 } else {
599 return HandleException(ex);
600 }
601 }
602 try {
603 return PrettyPrintJaxbObject(allClientSubscriptionInfo);
604 } catch (Exception ex) {
605 return HandleException(ex);
606 }
607 }
608
609 private String getReplicationNodes(HttpServletRequest parameters) {
610 ReplicationConfiguration cfg = null;
611 try {
612
613 cfg = juddi.getReplicationNodes(GetToken());
614 } catch (Exception ex) {
615
616 if (isExceptionExpiration(ex)) {
617 token = null;
618 try {
619 cfg = juddi.getReplicationNodes(GetToken());
620 } catch (Exception ex1) {
621 return HandleException(ex1);
622 }
623 } else {
624 return HandleException(ex);
625 }
626 }
627 try {
628 return PrettyPrintJaxbObject(cfg);
629 } catch (Exception ex) {
630 return HandleException(ex);
631 }
632 }
633
634 private String deleteNode(HttpServletRequest parameters) {
635 DeleteNode cfg = new DeleteNode();
636 cfg.setAuthInfo(GetToken());
637 cfg.setNodeID(parameters.getParameter("delete_NodeName"));
638 try {
639
640 juddi.deleteNode(cfg);
641 } catch (Exception ex) {
642
643 if (isExceptionExpiration(ex)) {
644 token = null;
645 try {
646 cfg.setAuthInfo(GetToken());
647 juddi.deleteNode(cfg);
648 } catch (Exception ex1) {
649 return HandleException(ex1);
650 }
651 } else {
652 return HandleException(ex);
653 }
654 }
655
656 return "Success";
657 }
658
659 private String deleteSubscription(HttpServletRequest parameters) {
660 List<String> keys = new ArrayList<String>();
661 keys.add(parameters.getParameter("admin_DeleteSubscriptionKey"));
662 try {
663
664 juddi.adminDeleteSubscription(GetToken(), keys);
665 } catch (Exception ex) {
666
667 if (isExceptionExpiration(ex)) {
668 token = null;
669 try {
670 juddi.adminDeleteSubscription(GetToken(), keys);
671 } catch (Exception ex1) {
672 return HandleException(ex1);
673 }
674 } else {
675 return HandleException(ex);
676 }
677 }
678
679 return "Success";
680 }
681
682 private String deleteClerk(HttpServletRequest parameters) {
683 DeleteClerk cfg = new DeleteClerk();
684 cfg.setAuthInfo(GetToken());
685 cfg.setClerkID(parameters.getParameter("delete_ClerkName"));
686 try {
687
688 juddi.deleteClerk(cfg);
689 } catch (Exception ex) {
690
691 if (isExceptionExpiration(ex)) {
692 token = null;
693 try {
694 cfg.setAuthInfo(GetToken());
695 juddi.deleteClerk(cfg);
696 } catch (Exception ex1) {
697 return HandleException(ex1);
698 }
699 } else {
700 return HandleException(ex);
701 }
702 }
703
704 return "Success";
705 }
706
707 private String setReplicationConfig(HttpServletRequest parameters) {
708 ReplicationConfiguration cfg = (ReplicationConfiguration) JUDDIRequestsAsXML.getObjectJuddi("set_ReplicationNodes", parameters.getParameter("set_ReplicationNodesXML"));
709 DispositionReport setReplicationNodes = null;
710 try {
711
712 setReplicationNodes = juddi.setReplicationNodes(GetToken(), cfg);
713 } catch (Exception ex) {
714
715 if (isExceptionExpiration(ex)) {
716 token = null;
717 try {
718 setReplicationNodes = juddi.setReplicationNodes(GetToken(), cfg);
719 } catch (Exception ex1) {
720 return HandleException(ex1);
721 }
722 } else {
723 return HandleException(ex);
724 }
725 }
726 try {
727 return PrettyPrintJaxbObject(setReplicationNodes);
728 } catch (Exception ex) {
729 return HandleException(ex);
730 }
731 }
732
733 private String adminSaveBusiness(HttpServletRequest parameters) {
734 //admin_SaveBusiness
735 AdminSaveBusiness cfg = (AdminSaveBusiness) JUDDIRequestsAsXML.getObjectJuddi("admin_SaveBusiness", parameters.getParameter("admin_SaveBusinessXML"));
736 DispositionReport setReplicationNodes = null;
737 try {
738
739 setReplicationNodes = juddi.adminSaveBusiness(GetToken(), cfg.getValues());
740 } catch (Exception ex) {
741
742 if (isExceptionExpiration(ex)) {
743 token = null;
744 try {
745 setReplicationNodes = juddi.adminSaveBusiness(GetToken(), cfg.getValues());
746 } catch (Exception ex1) {
747 return HandleException(ex1);
748 }
749 } else {
750 return HandleException(ex);
751 }
752 }
753 try {
754 return PrettyPrintJaxbObject(setReplicationNodes);
755 } catch (Exception ex) {
756 return HandleException(ex);
757 }
758 }
759
760 private String adminSaveTmodel(HttpServletRequest parameters) {
761 //admin_SaveTModel
762 AdminSaveTModel cfg = (AdminSaveTModel) JUDDIRequestsAsXML.getObjectJuddi("admin_SaveTModel", parameters.getParameter("admin_SaveTModelXML"));
763 //JAXB.marshal(cfg, System.out);
764 DispositionReport setReplicationNodes = null;
765 try {
766
767 setReplicationNodes = juddi.adminSaveTModel(GetToken(), cfg.getValues());
768 } catch (Exception ex) {
769
770 if (isExceptionExpiration(ex)) {
771 token = null;
772 try {
773 setReplicationNodes = juddi.adminSaveTModel(GetToken(), cfg.getValues());
774 } catch (Exception ex1) {
775 return HandleException(ex1);
776 }
777 } else {
778 return HandleException(ex);
779 }
780 }
781 try {
782 return PrettyPrintJaxbObject(setReplicationNodes);
783 } catch (Exception ex) {
784 return HandleException(ex);
785 }
786 }
787
788 private String adminSaveSubscription(HttpServletRequest parameters) {
789 //
790 AdminSaveSubscriptionRequest cfg = (AdminSaveSubscriptionRequest) JUDDIRequestsAsXML.getObjectJuddi("admin_SaveSubscription", parameters.getParameter("admin_SaveSubscriptionXML"));
791
792 Holder<List<Subscription>> holder = new Holder<List<Subscription>>(cfg.getSubscriptions());
793 try {
794
795 juddi.adminSaveSubscription(GetToken(), cfg.getPublisherOrUsername(), holder);
796 } catch (Exception ex) {
797
798 if (isExceptionExpiration(ex)) {
799 token = null;
800 try {
801 juddi.adminSaveSubscription(GetToken(), cfg.getPublisherOrUsername(), holder);
802 } catch (Exception ex1) {
803 return HandleException(ex1);
804 }
805 } else {
806 return HandleException(ex);
807 }
808 }
809 AdminSaveSubscriptionResponse res = new AdminSaveSubscriptionResponse();
810 res.getSubscriptions().addAll(holder.value);
811 try {
812 return PrettyPrintJaxbObject(res);
813 } catch (Exception ex) {
814 return HandleException(ex);
815 }
816 }
817
818 private String getEntityHistory(HttpServletRequest parameters) {
819 GetEntityHistoryMessageRequest sn = new GetEntityHistoryMessageRequest();
820 sn.setAuthInfo(GetToken());
821 sn.setEntityKey(parameters.getParameter("get_EntityHistoryKey"));
822 GetEntityHistoryMessageResponse entityHistory = null;
823 try {
824 sn.setMaxRecords(Long.parseLong(parameters.getParameter("get_EntityHistoryMaxCount")));
825 sn.setOffset(Long.parseLong(parameters.getParameter("get_EntityHistoryOffset")));
826 entityHistory = juddi.getEntityHistory(sn);
827 } catch (Exception ex) {
828 if (isExceptionExpiration(ex)) {
829 token = null;
830 sn.setAuthInfo(GetToken());
831 try {
832 entityHistory = juddi.getEntityHistory(sn);
833 } catch (Exception ex1) {
834 return "Error!" + HandleException(ex1);
835 }
836
837 } else {
838 return "Error!" + HandleException(ex);
839 }
840 }
841 if (entityHistory == null) {
842 return "Something went wrong!";
843 }
844 try {
845 return PrettyPrintJaxbObject(entityHistory);
846 } catch (Exception ex) {
847 return HandleException(ex);
848 }
849
850 }
851
852 private String change_NodeID(HttpServletRequest parameters) {
853 //check replication config
854
855 EntityManager em = PersistenceManager.getEntityManager();
856 EntityTransaction tx = em.getTransaction();
857
858 try {
859
860 ReplicationConfiguration replicationNodes = new JUDDIApiImpl().getReplicationNodes(GetToken());
861 if (replicationNodes.getOperator().size() > 1) {
862 throw new Exception("Replication is configured with " + replicationNodes.getOperator() + " nodes. Node rename aborted");
863 }
864 Configuration configuration = AppConfig.getConfiguration();
865 //this is going to break a few design rules.
866 String currentnode = configuration.getString(Property.JUDDI_NODE_ID);
867 String newnode = parameters.getParameter("change_NodeIDKey");
868 if (newnode == null) {
869 throw new Exception("The new node id was not specified");
870 }
871 newnode = newnode.trim();
872 newnode = newnode.toLowerCase();
873 log.warn("AUDIT - Renaming Node ID from " + currentnode + " to " + newnode);
874
875 UDDIPublicationImpl pub = new UDDIPublicationImpl();
876 UDDIInquiryImpl inquire = new UDDIInquiryImpl();
877
878 GetBusinessDetail gbd = new GetBusinessDetail();
879 gbd.setAuthInfo(GetToken());
880 gbd.getBusinessKey().add(newnode);
881 BusinessDetail businessDetail = null;
882 try {
883 businessDetail = inquire.getBusinessDetail(gbd);
884 } catch (Exception ex) {
885 //business doesn't exist
886 }
887 if (businessDetail == null || businessDetail.getBusinessEntity().isEmpty()) {
888 //copy the existing Root Node and rekey it with the new key
889 //incase the destination key generator is valid, we'll abort.
890 gbd.getBusinessKey().clear();
891 gbd.getBusinessKey().add(AppConfig.getConfiguration().getString(Property.JUDDI_NODE_ROOT_BUSINESS));
892 businessDetail = inquire.getBusinessDetail(gbd);
893 BusinessEntity get = businessDetail.getBusinessEntity().get(0);
894 get.setBusinessKey(newnode);
895 get.getSignature().clear();
896 if (get.getBusinessServices() != null) {
897 for (BusinessService bs : get.getBusinessServices().getBusinessService()) {
898 bs.setBusinessKey(newnode);
899 bs.getSignature().clear();
900 //we also need to rekey all of the services and bindings wait do we?
901 //bs.setServiceKey(bs.getServiceKey());
902 }
903 }
904 SaveBusiness sb = new SaveBusiness();
905 sb.setAuthInfo(GetToken());
906 sb.getBusinessEntity().add(get);
907 //if there's something wrong with the new key, this will throw
908 BusinessDetail saveBusiness = pub.saveBusiness(sb);
909 newnode = saveBusiness.getBusinessEntity().get(0).getBusinessKey();
910 }
911
912 tx.begin();
913 //rekey all entities with the new node id
914 Query createQuery = em.createQuery("Update UddiEntity ue set ue.nodeId=:node where ue.nodeId=:oldnode");
915 createQuery.setParameter("node", newnode);
916 createQuery.setParameter("oldnode", currentnode);
917 int records = createQuery.executeUpdate();
918 //rekey all the existing change records with the new node id
919 createQuery = em.createQuery("Update ChangeRecord ue set ue.nodeID=:node where ue.nodeID=:oldnode");
920 createQuery.setParameter("node", newnode);
921 createQuery.setParameter("oldnode", currentnode);
922 records += createQuery.executeUpdate();
923
924 //rekey is_replaced_by references? nah
925 tx.commit();
926 try {
927 DeleteBusiness db = new DeleteBusiness();
928 db.setAuthInfo(GetToken());
929 db.getBusinessKey().add(currentnode);
930 pub.deleteBusiness(db);
931 } catch (Exception ex) {
932 log.warn("Node id change error: ", ex);
933 }
934
935 //finally update the xml config and resave it
936 AppConfig.setJuddiProperty(Property.JUDDI_NODE_ID, newnode);
937 AppConfig.setJuddiProperty(Property.JUDDI_NODE_ROOT_BUSINESS, newnode);
938
939 return "Sucess, Records update: " + records + " current node id is now " + AppConfig.getConfiguration().getString(Property.JUDDI_NODE_ID);
940 } catch (Exception ex) {
941 return HandleException(ex);
942 } finally {
943 if (tx.isActive()) {
944 tx.rollback();
945 }
946 em.close();
947 }
948 }
949
950 private String getChangeRecord(HttpServletRequest parameters) {
951 try {
952 GetChangeRecords req = new GetChangeRecords();
953
954 req.setRequestingNode(AppConfig.getConfiguration().getString(Property.JUDDI_NODE_ID));
955
956 req.setResponseLimitCount(BigInteger.ONE);
957 req.setChangesAlreadySeen(new HighWaterMarkVectorType());
958 req.getChangesAlreadySeen().getHighWaterMark().add(
959 new ChangeRecordIDType(parameters.getParameter("nodeid"),
960 Long.parseLong(parameters.getParameter("recordid"))));
961 ChangeRecords changeRecords = new UDDIReplicationImpl().getChangeRecords(req);
962 return PrettyPrintJaxbObject(changeRecords);
963
964 } catch (Exception ex) {
965 return HandleException(ex);
966 }
967 }
968
969 /**
970 * returns html/xml escaped, pretty printed pre formated xml string
971 *
972 * @param jaxb
973 * @return
974 * @throws Exception
975 */
976 private String PrettyPrintJaxbObject(Object jaxb) throws Exception {
977 DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
978 dbf.setFeature("http://apache.org/xml/features/disallow-doctype-decl", true);
979 DocumentBuilder db = dbf.newDocumentBuilder();
980 StringWriter sw = new StringWriter();
981 JAXB.marshal(jaxb, sw);
982 InputSource is = new InputSource(new StringReader(sw.toString()));
983
984 TransformerFactory transFactory = TransformerFactory.newInstance();
985 transFactory.setAttribute(XMLConstants.ACCESS_EXTERNAL_DTD, "");
986 transFactory.setAttribute(XMLConstants.ACCESS_EXTERNAL_STYLESHEET, "");
987 Transformer transformer = transFactory.newTransformer();
988 transformer.setOutputProperty(OutputKeys.INDENT, "yes");
989 //initialize StreamResult with File object to save to file
990 StreamResult result = new StreamResult(new StringWriter());
991 Document document = db.parse(is);
992 DOMSource source = new DOMSource(document);
993 transformer.transform(source, result);
994 String xmlString = result.getWriter().toString();
995
996 return "<pre>" + StringEscapeUtils.escapeXml(xmlString) + "</pre>";
997 }
998
999 private String getFailedReplicationChangeRecords(HttpServletRequest parameters) {
1000 try {
1001
1002 GetFailedReplicationChangeRecordsMessageRequest req = new GetFailedReplicationChangeRecordsMessageRequest();
1003 req.setAuthInfo(GetToken());
1004 req.setMaxRecords(Integer.parseInt(parameters.getParameter("getFailedReplicationChangeRecordsMaxCount")));
1005 req.setOffset(0);
1006 req.setOffset(Integer.parseInt(parameters.getParameter("getFailedReplicationChangeRecordsOffset")));
1007 GetFailedReplicationChangeRecordsMessageResponse failedReplicationChangeRecords = null;
1008 try {
1009 failedReplicationChangeRecords = juddi.getFailedReplicationChangeRecords(req);
1010 } catch (Exception ex) {
1011 if (isExceptionExpiration(ex)) {
1012 token = null;
1013 req.setAuthInfo(GetToken());
1014 try {
1015 failedReplicationChangeRecords = juddi.getFailedReplicationChangeRecords(req);
1016 } catch (Exception ex1) {
1017 return "Error!" + HandleException(ex1);
1018 }
1019
1020 } else {
1021 return "Error!" + HandleException(ex);
1022 }
1023 }
1024
1025 return PrettyPrintJaxbObject(failedReplicationChangeRecords);
1026 } catch (Exception ex) {
1027 return HandleException(ex);
1028 }
1029 }
1030
1031 public enum AuthStyle {
1032
1033 /**
1034 * Http
1035 */
1036 HTTP,
1037 /**
1038 * UDDI Authentication via the Security API
1039 */
1040 UDDI_AUTH
1041 }
1042
1043 private String GetToken() {
1044 EnsureConfig();
1045 if (style != AuthStyle.UDDI_AUTH) {
1046 BindingProvider bp = null;
1047 if (WS_Transport) {
1048 Map<String, Object> context = null;
1049 bp = (BindingProvider) juddi;
1050 context = bp.getRequestContext();
1051 context.put(BindingProvider.USERNAME_PROPERTY, session.getAttribute("username"));
1052 context.put(BindingProvider.USERNAME_PROPERTY, session.getAttribute(AES.Decrypt("password", (String) properties.get("key"))));
1053 }
1054 return null;
1055 } else {
1056 if (token != null) {
1057 return token;
1058 }
1059 GetAuthToken req = new GetAuthToken();
1060 if (session.getAttribute("username") != null
1061 && session.getAttribute("password") != null) {
1062 req.setUserID((String) session.getAttribute("username"));
1063 req.setCred(AES.Decrypt((String) session.getAttribute("password"), (String) properties.get("key")));
1064 try {
1065 AuthToken authToken = security.getAuthToken(req);
1066 token = authToken.getAuthInfo();
1067 } catch (Exception ex) {
1068 return HandleException(ex);
1069 }
1070 }
1071 }
1072 return token;
1073 }
1074
1075 private String delete_publisher(HttpServletRequest parameters) {
1076 DeletePublisher sb = new DeletePublisher();
1077 sb.setAuthInfo(GetToken());
1078 sb.getPublisherId().add(parameters.getParameter("delete_publisherKEY"));
1079 try {
1080 juddi.deletePublisher(sb);
1081 } catch (Exception ex) {
1082 if (isExceptionExpiration(ex)) {
1083 token = null;
1084 sb.setAuthInfo(GetToken());
1085 try {
1086 juddi.deletePublisher(sb);
1087 } catch (Exception e) {
1088 return HandleException(e);
1089 }
1090
1091 } else {
1092 return HandleException(ex);
1093 }
1094 }
1095 return "Success";
1096 }
1097
1098 private String getAllPublisherDetail(HttpServletRequest parameters) {
1099 StringBuilder ret = new StringBuilder();
1100 GetAllPublisherDetail sb = new GetAllPublisherDetail();
1101 sb.setAuthInfo(GetToken());
1102 PublisherDetail d = null;
1103 try {
1104 d = juddi.getAllPublisherDetail(sb);
1105 } catch (Exception ex) {
1106 if (isExceptionExpiration(ex)) {
1107 token = null;
1108 sb.setAuthInfo(GetToken());
1109 try {
1110 d = juddi.getAllPublisherDetail(sb);
1111 } catch (Exception ex1) {
1112 return HandleException(ex1);
1113 }
1114
1115 } else {
1116 return HandleException(ex);
1117 }
1118 }
1119 if (d != null) {
1120 ret.append("<table class=\"table table-hover\"><tr><th>Name</th><th>Info</th></tr>");
1121 for (int i = 0; i < d.getPublisher().size(); i++) {
1122 ret.append("<tr><td>").append(StringEscapeUtils.escapeHtml(d.getPublisher().get(i).getPublisherName()))
1123 .append("</td><td>");
1124 ret.append(PrintPublisherDetail(d.getPublisher().get(i)))
1125 .append("</td></tr>");
1126 }
1127 ret.append("</table>");
1128 } else {
1129 ret.append("No data returned");
1130 }
1131 return ret.toString();
1132 }
1133
1134 private String PrintPublisherDetail(Publisher p) {
1135 StringBuilder ret = new StringBuilder();
1136
1137 ret.append("Authorized Name = ").append(StringEscapeUtils.escapeHtml(p.getAuthorizedName()))
1138 .append("<br>")
1139 .append("Publisher Name = ").append(StringEscapeUtils.escapeHtml(p.getPublisherName()))
1140 .append("<br>")
1141 .append("Email = ")
1142 .append(StringEscapeUtils.escapeHtml(p.getEmailAddress()))
1143 .append("<br>")
1144 .append("Administrator = ")
1145 .append((p.isIsAdmin()))
1146 .append("<br>")
1147 .append("Enabled = ")
1148 .append((p.isIsEnabled()))
1149 .append("<br>")
1150 .append("Max Bindings per = ")
1151 .append(p.getMaxBindingsPerService())
1152 .append("<br>")
1153 .append("Max Businesses = ")
1154 .append(p.getMaxBusinesses())
1155 .append("<br>")
1156 .append("Max Services per = ")
1157 .append(p.getMaxServicePerBusiness())
1158 .append("<br>")
1159 .append("Max tModels = ")
1160 .append(p.getMaxTModels())
1161 .append("");
1162 return ret.toString();
1163 }
1164
1165 private String get_publisherDetail(HttpServletRequest parameters) {
1166 StringBuilder ret = new StringBuilder();
1167 GetPublisherDetail sb = new GetPublisherDetail();
1168 sb.getPublisherId().add(parameters.getParameter("get_publisherDetailKEY"));
1169 sb.setAuthInfo(GetToken());
1170 PublisherDetail d = null;
1171 try {
1172 d = juddi.getPublisherDetail(sb);
1173 } catch (Exception ex) {
1174 if (isExceptionExpiration(ex)) {
1175 token = null;
1176 sb.setAuthInfo(GetToken());
1177 try {
1178 d = juddi.getPublisherDetail(sb);
1179 } catch (Exception ex1) {
1180 return HandleException(ex1);
1181 }
1182
1183 } else {
1184 return HandleException(ex);
1185 }
1186 }
1187 if (d != null) {
1188 ret.append("<table class=\"table table-hover\"><tr><th>Name</th><th>Info</th></tr>");
1189 for (int i = 0; i < d.getPublisher().size(); i++) {
1190 ret.append("<tr><td>").append(StringEscapeUtils.escapeHtml(d.getPublisher().get(i).getPublisherName()))
1191 .append("</td><td>");
1192 ret.append(PrintPublisherDetail(d.getPublisher().get(i)))
1193 .append("</td></tr>");
1194 }
1195 ret.append("</table>");
1196 } else {
1197 ret.append("No data returned");
1198 }
1199 return ret.toString();
1200 }
1201
1202 private String invoke_SyncSubscription(HttpServletRequest parameters) {
1203 StringBuilder ret = new StringBuilder();
1204 SyncSubscription sb = new SyncSubscription();
1205
1206 SyncSubscriptionDetail d = null;
1207 try {
1208 StringReader sr = new StringReader(parameters.getParameter("invoke_SyncSubscriptionXML").trim());
1209 sb = (SyncSubscription) (XmlUtils.unmarshal(sr, SyncSubscription.class));
1210 sb.setAuthInfo(GetToken());
1211 d = juddi.invokeSyncSubscription(sb);
1212 } catch (Exception ex) {
1213 if (isExceptionExpiration(ex)) {
1214 token = null;
1215 sb.setAuthInfo(GetToken());
1216 try {
1217 d = juddi.invokeSyncSubscription(sb);
1218 } catch (Exception ex1) {
1219 return HandleException(ex1);
1220 }
1221
1222 } else {
1223 return HandleException(ex);
1224 }
1225 }
1226 if (d != null) {
1227 try {
1228 ret.append(PrettyPrintJaxbObject(d));
1229 } catch (Exception ex) {
1230 return HandleException(ex);
1231 }
1232
1233 } else {
1234 ret.append("No data returned");
1235 }
1236 return ret.toString();
1237 }
1238
1239 private static String PrettyPrintXML(String input) {
1240 try {
1241 TransformerFactory transFactory = TransformerFactory.newInstance();
1242 transFactory.setAttribute(XMLConstants.ACCESS_EXTERNAL_DTD, "");
1243 transFactory.setAttribute(XMLConstants.ACCESS_EXTERNAL_STYLESHEET, "");
1244 Transformer transformer = transFactory.newTransformer();
1245 transformer.setOutputProperty(OutputKeys.INDENT, "yes");
1246 //initialize StreamResult with File object to save to file
1247 StreamResult result = new StreamResult(new StringWriter());
1248 StreamSource source = new StreamSource(new StringReader(input));
1249 transformer.transform(source, result);
1250 String xmlString = result.getWriter().toString();
1251 return (xmlString);
1252 } catch (Exception ex) {
1253 }
1254 return null;
1255 }
1256
1257 public String getSampleSave_ClientSubscriptionInfo() {
1258 SaveClientSubscriptionInfo x = new SaveClientSubscriptionInfo();
1259 x.setAuthInfo("");
1260 x.getClientSubscriptionInfo().add(new ClientSubscriptionInfo());
1261 x.getClientSubscriptionInfo().get(0).setFromClerk(new Clerk());
1262 x.getClientSubscriptionInfo().get(0).setToClerk(new Clerk());
1263 x.getClientSubscriptionInfo().get(0).setSubscriptionKey("subscription key");
1264 x.getClientSubscriptionInfo().get(0).setLastModified(null);
1265 x.getClientSubscriptionInfo().get(0).setLastNotified(null);
1266 x.getClientSubscriptionInfo().get(0).getFromClerk().setName("ClerkName");
1267 x.getClientSubscriptionInfo().get(0).getFromClerk().setPublisher("username");
1268 x.getClientSubscriptionInfo().get(0).getFromClerk().setPassword("password");
1269 x.getClientSubscriptionInfo().get(0).getFromClerk().setNode(new Node());
1270 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setClientName("clientname");
1271 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setName("nodename");
1272 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setDescription("description");
1273 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setInquiryUrl("http://localhost:8080/juddiv3/services/inquiry");
1274 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setPublishUrl("http://localhost:8080/juddiv3/services/publish");
1275 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setCustodyTransferUrl("http://localhost:8080/juddiv3/services/custody-transfer");
1276 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setSubscriptionUrl("http://localhost:8080/juddiv3/services/subscription");
1277 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setSubscriptionListenerUrl("http://localhost:8080/juddiv3/services/subscription-listener");
1278 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setJuddiApiUrl("http://localhost:8080/juddiv3/services/juddi-api");
1279 x.getClientSubscriptionInfo().get(0).getFromClerk().getNode().setReplicationUrl("http://localhost:8080/juddiv3/services/replication");
1280
1281 x.getClientSubscriptionInfo().get(0).getToClerk().setName("ClerkName");
1282 x.getClientSubscriptionInfo().get(0).getToClerk().setPublisher("username");
1283 x.getClientSubscriptionInfo().get(0).getToClerk().setPassword("password");
1284 x.getClientSubscriptionInfo().get(0).getToClerk().setNode(new Node());
1285 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setClientName("clientname");
1286 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setName("nodename");
1287 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setDescription("description");
1288 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setInquiryUrl("http://localhost:8080/juddiv3/services/inquiry");
1289 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setPublishUrl("http://localhost:8080/juddiv3/services/publish");
1290 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setCustodyTransferUrl("http://localhost:8080/juddiv3/services/custody-transfer");
1291 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setSubscriptionUrl("http://localhost:8080/juddiv3/services/subscription");
1292 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setSubscriptionListenerUrl("http://localhost:8080/juddiv3/services/subscription-listener");
1293 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setJuddiApiUrl("http://localhost:8080/juddiv3/services/juddi-api");
1294 x.getClientSubscriptionInfo().get(0).getToClerk().getNode().setReplicationUrl("http://localhost:8080/juddiv3/services/replication");
1295 StringWriter sw = new StringWriter();
1296 JAXB.marshal(x, sw);
1297 return sw.toString();
1298 }
1299
1300 private String save_ClientSubscriptionInfo(HttpServletRequest parameters) {
1301 StringBuilder ret = new StringBuilder();
1302 SaveClientSubscriptionInfo sb = new SaveClientSubscriptionInfo();
1303
1304 if (parameters.getParameter("ClientSubscriptionInfoDetailXML") == null) {
1305 return "No input!";
1306 }
1307 ClientSubscriptionInfoDetail d = null;
1308 try {
1309 StringReader sr = new StringReader(parameters.getParameter("ClientSubscriptionInfoDetailXML").trim());
1310 sb = (JAXB.unmarshal(sr, SaveClientSubscriptionInfo.class));
1311 sb.setAuthInfo(GetToken());
1312 d = juddi.saveClientSubscriptionInfo(sb);
1313 } catch (Exception ex) {
1314 if (ex instanceof DispositionReportFaultMessage) {
1315 DispositionReportFaultMessage f = (DispositionReportFaultMessage) ex;
1316 if (f.getFaultInfo().countainsErrorCode(DispositionReport.E_AUTH_TOKEN_EXPIRED)) {
1317 token = null;
1318 sb.setAuthInfo(GetToken());
1319 try {
1320 d = juddi.saveClientSubscriptionInfo(sb);
1321 } catch (Exception ex1) {
1322 return HandleException(ex1);
1323 }
1324 }
1325 } else {
1326 return HandleException(ex);
1327 }
1328 }
1329 if (d != null) {
1330 try {
1331 ret.append(PrettyPrintJaxbObject(d));
1332 } catch (Exception ex) {
1333 return HandleException(ex);
1334 }
1335
1336 } else {
1337 ret.append("No data returned");
1338 }
1339 return ret.toString();
1340 }
1341
1342 /**
1343 * return true if the word expire is in the exception or the UDDI error
1344 * code representing an expired token
1345 *
1346 * @param ex
1347 * @return r
1348 */
1349 public static boolean isExceptionExpiration(Exception ex) {
1350 if (ex == null) {
1351 return false;
1352 }
1353 if (ex instanceof DispositionReportFaultMessage) {
1354 DispositionReportFaultMessage f = (DispositionReportFaultMessage) ex;
1355 if (f.getFaultInfo().countainsErrorCode(DispositionReport.E_AUTH_TOKEN_EXPIRED) || ex.getMessage().contains(DispositionReport.E_AUTH_TOKEN_EXPIRED) || ex.getMessage().toLowerCase().contains("expired")) {
1356 return true;
1357 }
1358 }
1359
1360 if (ex.getMessage() == null) {
1361 return false;
1362 }
1363 if (ex.getMessage().toLowerCase().contains("expire")) {
1364 return true;
1365 }
1366
1367 if (ex.getMessage().toLowerCase().contains(DispositionReport.E_AUTH_TOKEN_EXPIRED.toLowerCase())) {
1368 return true;
1369 }
1370 if (ex.getLocalizedMessage() == null) {
1371 return false;
1372 }
1373 if (ex.getLocalizedMessage().toLowerCase().contains("expire")) {
1374 return true;
1375 }
1376 return false;
1377 }
1378
1379 private String save_publisher(HttpServletRequest parameters) {
1380
1381 SavePublisher sb = new SavePublisher();
1382 Publisher p = new Publisher();
1383 p.setAuthorizedName(parameters.getParameter("savePublisherAuthorizedName"));
1384 p.setPublisherName(parameters.getParameter("savePublisherNAME"));
1385 p.setEmailAddress(parameters.getParameter("savePublisherEMAIL"));
1386 try {
1387 p.setIsAdmin(Boolean.parseBoolean(parameters.getParameter("savePublisherIsAdmin")));
1388 } catch (Exception ex) {
1389 }
1390 try {
1391 p.setIsEnabled(Boolean.parseBoolean(parameters.getParameter("savePublisherIsEnabled")));
1392 } catch (Exception ex) {
1393 }
1394
1395 PublisherDetail d = null;
1396 sb.setAuthInfo(GetToken());
1397 try {
1398 if (parameters.getParameter("savePublisherMaxBindings") != null) {
1399 p.setMaxBindingsPerService(Integer.parseInt(parameters.getParameter("savePublisherMaxBindings")));
1400 }
1401 } catch (Exception ex) {
1402 }
1403 try {
1404 if (parameters.getParameter("savePublisherMaxServices") != null) {
1405 p.setMaxServicePerBusiness(Integer.parseInt(parameters.getParameter("savePublisherMaxServices")));
1406 }
1407 } catch (Exception ex) {
1408 }
1409 try {
1410 if (parameters.getParameter("savePublisherMaxBusiness") != null) {
1411 p.setMaxBusinesses(Integer.parseInt(parameters.getParameter("savePublisherMaxBusiness")));
1412 }
1413 } catch (Exception ex) {
1414 }
1415 try {
1416 if (parameters.getParameter("savePublisherMaxTModels") != null) {
1417 p.setMaxTModels(Integer.parseInt(parameters.getParameter("savePublisherMaxTModels")));
1418 }
1419 } catch (Exception ex) {
1420 }
1421 sb.getPublisher().add(p);
1422 try {
1423
1424 d = juddi.savePublisher(sb);
1425 } catch (Exception ex) {
1426
1427 if (isExceptionExpiration(ex)) {
1428 token = null;
1429 sb.setAuthInfo(GetToken());
1430 try {
1431 d = juddi.savePublisher(sb);
1432 } catch (Exception ex1) {
1433 return HandleException(ex1);
1434 }
1435 } else {
1436 return HandleException(ex);
1437 }
1438 }
1439 return "Success";
1440 }
1441
1442 private String adminDelete_tmodel(HttpServletRequest parameters) {
1443 DeleteTModel sb = new DeleteTModel();
1444 sb.getTModelKey().add(parameters.getParameter("adminDelete_tmodelKEY"));
1445 sb.setAuthInfo(GetToken());
1446 try {
1447 juddi.adminDeleteTModel(sb);
1448 } catch (Exception ex) {
1449 if (isExceptionExpiration(ex)) {
1450 token = null;
1451 sb.setAuthInfo(GetToken());
1452 try {
1453 juddi.adminDeleteTModel(sb);
1454 } catch (Exception ex1) {
1455 return HandleException(ex1);
1456 }
1457 } else {
1458 return HandleException(ex);
1459 }
1460 }
1461 return "Success";
1462 }
1463
1464 private String delete_ClientSubscriptionInfo(HttpServletRequest parameters) {
1465 DeleteClientSubscriptionInfo sb = new DeleteClientSubscriptionInfo();
1466 sb.getSubscriptionKey().add(parameters.getParameter("delete_ClientSubscriptionInfoKEY"));
1467 sb.setAuthInfo(GetToken());
1468 try {
1469 juddi.deleteClientSubscriptionInfo(sb);
1470 } catch (Exception ex) {
1471 if (isExceptionExpiration(ex)) {
1472 token = null;
1473 sb.setAuthInfo(GetToken());
1474 try {
1475 juddi.deleteClientSubscriptionInfo(sb);
1476 } catch (Exception ex1) {
1477 return HandleException(ex1);
1478 }
1479
1480 } else {
1481 return HandleException(ex);
1482 }
1483 }
1484 return "Success";
1485 }
1486
1487 /**
1488 * If false, the configuration page will be available from anywhere. If
1489 * true, it will only be accessible from the server hosting juddi-gui.
1490 * if not defined, the result is true.
1491 *
1492 * @return true/false
1493 */
1494 public boolean isAdminLocalhostOnly() {
1495 return clientConfig.getConfiguration().getBoolean(PROP_ADMIN_LOCALHOST_ONLY, true);
1496 }
1497
1498 public String verifyLogin() {
1499 EnsureConfig();
1500 if (style != AuthStyle.UDDI_AUTH) {
1501 if (WS_Transport) {
1502 BindingProvider bp = null;
1503 Map<String, Object> context = null;
1504
1505 bp = (BindingProvider) juddi;
1506 context = bp.getRequestContext();
1507 context.put(BindingProvider.USERNAME_PROPERTY, session.getAttribute("username"));
1508 context.put(BindingProvider.USERNAME_PROPERTY, session.getAttribute(AES.Decrypt("password", (String) properties.get("key"))));
1509 }
1510 FindBusiness fb = new FindBusiness();
1511 fb.setListHead(0);
1512 fb.setMaxRows(1);
1513 fb.setFindQualifiers(new FindQualifiers());
1514 fb.getFindQualifiers().getFindQualifier().add(UDDIConstants.APPROXIMATE_MATCH);
1515 fb.getName().add(new Name(UDDIConstants.WILDCARD, null));
1516 try {
1517 GetPublisherDetail publisherDetail = new GetPublisherDetail();
1518 publisherDetail.getPublisherId().add((String) session.getAttribute("username"));
1519 juddi.getPublisherDetail(publisherDetail);
1520
1521 } catch (Exception ex) {
1522 return HandleException(ex);
1523 }
1524 /*
1525 bp = (BindingProvider) juddi;
1526 context = bp.getRequestContext();
1527 context.put(BindingProvider.USERNAME_PROPERTY, session.getAttribute("username"));
1528 context.put(BindingProvider.USERNAME_PROPERTY, session.getAttribute(AES.Decrypt("password", (String) properties.get("key"))));*/
1529 return null;
1530 } else {
1531 if (token != null) {
1532 return token;
1533 }
1534 if (WS_Transport) {
1535 BindingProvider bp = null;
1536 Map<String, Object> context = null;
1537
1538 bp = (BindingProvider) juddi;
1539 context = bp.getRequestContext();
1540 context.remove(BindingProvider.USERNAME_PROPERTY);
1541 context.remove(BindingProvider.PASSWORD_PROPERTY);
1542 }
1543 GetAuthToken req = new GetAuthToken();
1544 try {
1545 if (security == null) {
1546 security = transport.getUDDISecurityService();
1547 }
1548 } catch (Exception ex) {
1549 return HandleException(ex);
1550 }
1551 if (session.getAttribute("username") != null
1552 && session.getAttribute("password") != null) {
1553 req.setUserID((String) session.getAttribute("username"));
1554 req.setCred(AES.Decrypt((String) session.getAttribute("password"), (String) properties.get("key")));
1555 log.info("AUDIT: fetching auth token for " + req.getUserID() + " Auth Mode is " + ((security == null) ? "HTTP" : "AUTH_TOKEN"));
1556 try {
1557 AuthToken authToken = security.getAuthToken(req);
1558 token = authToken.getAuthInfo();
1559 return null;
1560 } catch (Exception ex) {
1561 return HandleException(ex);
1562 }
1563 }
1564 }
1565 return "Unexpected error";
1566 }
1567
1568 public String SendAdvanced(Object request, String method) {
1569 StringWriter sw = new StringWriter();
1570 Object result=null;
1571 try {
1572 if (method.equalsIgnoreCase("save_ClientSubscriptionInfo")) {
1573 SaveClientSubscriptionInfo x = (SaveClientSubscriptionInfo) request;
1574 x.setAuthInfo(GetToken());
1575 ClientSubscriptionInfoDetail saveClientSubscriptionInfo = null;
1576 try {
1577 result = juddi.saveClientSubscriptionInfo(x);
1578 sw.append("Success:<br>");
1579 //JAXB.marshal(saveClientSubscriptionInfo, sw);
1580 } catch (Exception ex) {
1581 if (isExceptionExpiration(ex)) {
1582 token = null;
1583 x.setAuthInfo(GetToken());
1584 result = juddi.saveClientSubscriptionInfo(x);
1585 sw.append("Success:<br>");
1586 //JAXB.marshal(saveClientSubscriptionInfo, sw);
1587
1588 } else {
1589 throw ex;
1590 }
1591 }
1592
1593 }
1594 if (method.equalsIgnoreCase("invoke_SyncSubscription")) {
1595 SyncSubscription x = (SyncSubscription) request;
1596 x.setAuthInfo(GetToken());
1597 SyncSubscriptionDetail invokeSyncSubscription = null;
1598 try {
1599 result = juddi.invokeSyncSubscription(x);
1600 sw.append("Success:<br>");
1601 //JAXB.marshal(invokeSyncSubscription, sw);
1602 } catch (Exception ex) {
1603 if (isExceptionExpiration(ex)) {
1604 token = null;
1605 x.setAuthInfo(GetToken());
1606 result = juddi.invokeSyncSubscription(x);
1607 sw.append("Success:<br>");
1608 //JAXB.marshal(invokeSyncSubscription, sw);
1609
1610 } else {
1611 throw ex;
1612 }
1613 }
1614
1615 }
1616 if (method.equalsIgnoreCase("admin_SaveBusiness")) {
1617 AdminSaveBusiness x = (AdminSaveBusiness) request;
1618
1619 DispositionReport adminSaveBusiness = null;
1620
1621 try {
1622 result = juddi.adminSaveBusiness(GetToken(), x.getValues());
1623 sw.append("Success:<br>");
1624 //JAXB.marshal(adminSaveBusiness, sw);
1625
1626 } catch (Exception ex) {
1627 if (isExceptionExpiration(ex)) {
1628 token = null;
1629 x.setAuthInfo(GetToken());
1630 result = juddi.adminSaveBusiness(GetToken(), x.getValues());
1631 sw.append("Success:<br>");
1632 // JAXB.marshal(adminSaveBusiness, sw);
1633
1634 } else {
1635 throw ex;
1636 }
1637 }
1638 }
1639 if (method.equalsIgnoreCase("admin_SaveTModel")) {
1640 AdminSaveTModel x = (AdminSaveTModel) request;
1641
1642 DispositionReport adminSaveTModel = null;
1643 try {
1644 result = juddi.adminSaveTModel(GetToken(), x.getValues());
1645 sw.append("Success:<br>");
1646 //JAXB.marshal(adminSaveTModel, sw);
1647
1648 } catch (Exception ex) {
1649 if (isExceptionExpiration(ex)) {
1650 token = null;
1651 x.setAuthInfo(GetToken());
1652 result = juddi.adminSaveTModel(GetToken(), x.getValues());
1653 sw.append("Success:<br>");
1654 //JAXB.marshal(adminSaveTModel, sw);
1655
1656 } else {
1657 throw ex;
1658 }
1659 }
1660
1661 }
1662
1663 if (method.equalsIgnoreCase("admin_SaveSubscription")) {
1664 AdminSaveSubscriptionRequest x = (AdminSaveSubscriptionRequest) request;
1665 Holder<List<Subscription>> holder = new Holder<List<Subscription>>(x.getSubscriptions());
1666 try {
1667 juddi.adminSaveSubscription(GetToken(), x.getPublisherOrUsername(), holder);
1668 sw.append("Success:<br>");
1669 result=holder;
1670 } catch (Exception ex) {
1671 if (isExceptionExpiration(ex)) {
1672 token = null;
1673
1674 juddi.adminSaveSubscription(GetToken(), x.getPublisherOrUsername(), holder);
1675 sw.append("Success:<br>");
1676 result=holder;
1677
1678 } else {
1679 throw ex;
1680 }
1681 }
1682 }
1683 if (method.equalsIgnoreCase("set_ReplicationNodes")) {
1684 ReplicationConfiguration x = (ReplicationConfiguration) request;
1685 // Holder<List<Subscription>> holder = new Holder<List<Subscription>>(x.getSubscriptions());
1686 try {
1687 result = juddi.setReplicationNodes(GetToken(), x);
1688 sw.append("Success:<br>");
1689 // JAXB.marshal(setReplicationNodes, sw);
1690 } catch (Exception ex) {
1691 if (isExceptionExpiration(ex)) {
1692 token = null;
1693
1694 result = juddi.setReplicationNodes(GetToken(), x);
1695 sw.append("Success:<br>");
1696 //JAXB.marshal(setReplicationNodes, sw);
1697
1698 } else {
1699 throw ex;
1700 }
1701 }
1702 }
1703
1704 } catch (Exception ex) {
1705 return HandleException(ex);
1706 }
1707 if (result!=null){
1708 try {
1709 return sw.toString() + "<br>" + PrettyPrintJaxbObject(result);
1710 } catch (Exception ex) {
1711 return HandleException(ex);
1712 }
1713 }
1714 return "Error! no work was done?";
1715
1716 }
1717
1718 }
|
{
"url": "https://juddi.apache.org/xref/org/apache/juddi/adminconsole/hub/UddiAdminHub.html",
"source_domain": "juddi.apache.org",
"snapshot_id": "crawl=CC-MAIN-2022-27",
"warc_metadata": {
"Content-Length": "251547",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:2W2KOYT6HWGF6VCXYOSZA5WQILGANDAV",
"WARC-Concurrent-To": "<urn:uuid:fa67ed40-28dc-4dfc-994e-742fb19df714>",
"WARC-Date": "2022-07-04T12:29:34Z",
"WARC-IP-Address": "151.101.2.132",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:RKT7UMTCJUWWGETT4QNAZP7PXUUOYBD3",
"WARC-Record-ID": "<urn:uuid:2f87f37b-7d87-4498-b72c-f4f8419ebc3d>",
"WARC-Target-URI": "https://juddi.apache.org/xref/org/apache/juddi/adminconsole/hub/UddiAdminHub.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:cad727f1-d8a6-427d-87e1-d105c73b673a>"
},
"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,
13,
60,
65,
72,
131,
139,
210,
282,
329,
337,
392,
400,
475,
548,
628,
703,
741,
748,
756,
788,
821,
854,
887,
912,
949,
981,
1008,
1034,
1067,
1103,
1140,
1184,
1232,
1268,
1309,
1359,
1402,
1437,
1469,
1531,
1577,
1630,
1673,
1717,
1768,
1814,
1866,
1918,
1959,
1991,
2050,
2118,
2172,
2215,
2265,
2307,
2372,
2437,
2489,
2547,
2602,
2643,
2689,
2741,
2787,
2850,
2895,
2945,
2998,
3057,
3110,
3169,
3226,
3281,
3340,
3397,
3443,
3510,
3561,
3615,
3673,
3731,
3785,
3850,
3916,
3968,
4014,
4073,
4121,
4168,
4235,
4303,
4387,
4472,
4517,
4573,
4619,
4674,
4719,
4770,
4832,
4888,
4926,
4969,
5012,
5056,
5099,
5140,
5185,
5231,
5272,
5315,
5356,
5402,
5435,
5476,
5524,
5567,
5613,
5666,
5720,
5761,
5813,
5869,
5874,
5936,
5989,
6022,
6058,
6063,
6071,
6148,
6229,
6314,
6399,
6406,
6473,
6481,
6513,
6518,
6534,
6565,
6581,
6654,
6700,
6742,
6758,
6840,
6873,
6889,
6963,
6968,
7043,
7105,
7119,
7124,
7140,
7201,
7216,
7247,
7263,
7324,
7377,
7414,
7428,
7433,
7449,
7534,
7562,
7578,
7610,
7671,
7745,
7796,
7830,
7897,
7950,
8007,
8037,
8059,
8093,
8130,
8164,
8178,
8194,
8255,
8271,
8350,
8366,
8381,
8397,
8478,
8494,
8509,
8525,
8623,
8639,
8654,
8670,
8776,
8792,
8807,
8823,
8893,
8909,
8924,
8939,
8955,
9058,
9063,
9131,
9192,
9243,
9294,
9352,
9409,
9470,
9519,
9577,
9627,
9679,
9684,
9700,
9781,
9835,
9850,
9884,
9915,
9947,
9980,
9996,
10116,
10177,
10214,
10302,
10365,
10405,
10427,
10432,
10477,
10491,
10525,
10530,
10632,
10718,
10758,
10840,
10862,
10902,
10992,
11014,
11054,
11059,
11115,
11168,
11200,
11232,
11272,
11308,
11344,
11358,
11363,
11405,
11453,
11487,
11561,
11566,
11643,
11685,
11815,
11876,
12024,
12097,
12135,
12140,
12248,
12331,
12449,
12515,
12553,
12645,
12650,
12731,
12807,
12872,
12910,
12915,
12994,
13077,
13153,
13209,
13320,
13480,
13555,
13601,
13639,
13644,
13697,
13754,
13784,
13806,
13811,
13825,
13830,
13846,
13929,
14006,
14059,
14074,
14099,
14122,
14138,
14197,
14268,
14366,
14535,
14595,
14858,
14922,
14992,
15069,
15150,
15413,
15482,
15567,
15652,
15796,
15825,
15907,
15969,
16113,
16135,
16149,
16154,
16170,
16250,
16285,
16300,
16334,
16350,
16390,
16395,
16431,
16474,
16488,
16493,
16509,
16592,
16660,
16675,
16712,
16760,
16776,
16863,
16899,
16940,
16954,
16959,
16975,
17037,
17052,
17085,
17138,
17154,
17216,
17242,
17325,
17406,
17481,
17580,
17666,
17752,
17825,
17916,
17994,
18083,
18159,
18252,
18332,
18412,
18479,
18576,
18660,
18739,
18805,
18889,
18960,
19044,
19114,
19196,
19264,
19347,
19416,
19497,
19564,
19646,
19714,
19808,
19883,
19971,
20045,
20131,
20203,
20302,
20387,
20477,
20554,
20644,
20720,
20812,
20890,
20977,
21050,
21133,
21203,
21285,
21357,
21460,
21550,
21580,
21585,
21630,
21697,
21719,
21770,
21784,
21789,
21860,
21912,
21960,
22003,
22075,
22119,
22210,
22317,
22410,
22509,
22622,
22721,
22812,
22905,
22984,
23083,
23174,
23273,
23366,
23483,
23584,
23621,
23701,
23783,
23788,
23830,
23856,
23905,
23950,
24011,
24061,
24125,
24167,
24232,
24294,
24378,
24416,
24421,
24458,
24533,
24563,
24585,
24623,
24637,
24642,
24712,
24762,
24810,
24854,
24940,
25042,
25130,
25224,
25332,
25426,
25512,
25600,
25674,
25768,
25854,
25948,
26036,
26148,
26244,
26288,
26293,
26319,
26367,
26412,
26473,
26523,
26587,
26629,
26693,
26755,
26839,
26877,
26882,
26919,
26994,
27024,
27046,
27084,
27098,
27103,
27177,
27203,
27208,
27296,
27357,
27414,
27444,
27580,
27693,
27789,
27794,
27886,
27985,
28093,
28160,
28206,
28251,
28320,
28342,
28356,
28361,
28433,
28479,
28505,
28510,
28580,
28625,
28630,
28691,
28741,
28783,
28869,
28931,
29004,
29042,
29079,
29143,
29173,
29195,
29221,
29289,
29334,
29390,
29412,
29433,
29447,
29452,
29525,
29572,
29598,
29603,
29674,
29719,
29724,
29785,
29835,
29877,
29964,
30026,
30099,
30137,
30174,
30238,
30268,
30290,
30317,
30385,
30430,
30486,
30508,
30522,
30527,
30616,
30696,
30722,
30727,
30831,
30876,
30881,
30942,
30992,
31034,
31154,
31216,
31289,
31327,
31364,
31428,
31458,
31480,
31507,
31592,
31637,
31693,
31715,
31729,
31734,
31814,
31871,
31897,
31902,
31975,
32020,
32025,
32086,
32136,
32178,
32267,
32329,
32402,
32440,
32477,
32541,
32571,
32593,
32620,
32683,
32728,
32784,
32806,
32820,
32825,
32896,
32951,
33000,
33079,
33105,
33110,
33161,
33206,
33211,
33272,
33322,
33364,
33437,
33504,
33566,
33639,
33677,
33714,
33778,
33808,
33830,
33835,
33873,
33887,
33892,
33971,
34036,
34122,
34148,
34153,
34230,
34275,
34280,
34341,
34391,
34433,
34526,
34588,
34661,
34699,
34736,
34800,
34830,
34852,
34857,
34895,
34909,
34914,
34986,
35043,
35092,
35173,
35199,
35204,
35256,
35301,
35306,
35367,
35417,
35459,
35532,
35600,
35662,
35735,
35773,
35810,
35874,
35904,
35926,
35931,
35969,
35983,
35988,
36069,
36258,
36324,
36350,
36355,
36449,
36494,
36499,
36560,
36610,
36652,
36762,
36824,
36897,
36935,
36972,
37036,
37066,
37088,
37115,
37194,
37239,
37295,
37317,
37331,
37336,
37414,
37455,
37626,
37692,
37718,
37723,
37827,
37872,
37877,
37938,
37988,
38030,
38150,
38212,
38285,
38323,
38360,
38424,
38454,
38476,
38503,
38582,
38627,
38683,
38705,
38719,
38724,
38800,
38839,
39002,
39055,
39121,
39147,
39152,
39254,
39299,
39304,
39365,
39415,
39457,
39575,
39637,
39710,
39748,
39785,
39849,
39879,
39901,
39928,
40007,
40052,
40108,
40130,
40144,
40149,
40231,
40254,
40455,
40460,
40572,
40598,
40603,
40710,
40755,
40760,
40821,
40871,
40913,
41036,
41098,
41171,
41209,
41246,
41310,
41340,
41362,
41455,
41520,
41547,
41610,
41655,
41711,
41733,
41747,
41752,
41829,
41923,
41971,
42057,
42131,
42157,
42273,
42383,
42455,
42500,
42561,
42611,
42675,
42717,
42805,
42867,
42951,
42989,
42994,
43031,
43106,
43136,
43158,
43207,
43267,
43289,
43315,
43388,
43433,
43489,
43511,
43516,
43530,
43535,
43609,
43656,
43661,
43739,
43803,
43808,
43834,
43839,
43963,
44040,
44197,
44227,
44315,
44388,
44486,
44576,
44627,
44721,
44751,
44805,
44866,
44971,
44976,
45057,
45134,
45139,
45216,
45273,
45336,
45402,
45436,
45521,
45574,
45635,
45665,
45771,
45867,
45965,
46031,
46168,
46253,
46353,
46418,
46482,
46559,
46679,
46759,
46838,
46959,
47051,
47097,
47135,
47209,
47273,
47342,
47441,
47529,
47633,
47663,
47668,
47708,
47778,
47911,
47982,
48060,
48131,
48220,
48349,
48420,
48498,
48566,
48571,
48638,
48679,
48713,
48791,
48855,
48929,
48989,
49042,
49118,
49148,
49153,
49227,
49316,
49416,
49421,
49588,
49633,
49689,
49721,
49770,
49821,
49851,
49891,
49913,
49927,
49932,
50008,
50034,
50109,
50114,
50229,
50234,
50305,
50391,
50471,
50565,
50664,
50771,
50844,
50849,
50894,
50950,
50972,
50986,
50991,
51007,
51087,
51102,
51129,
51152,
51185,
51201,
51282,
51369,
51467,
51534,
51592,
51636,
51723,
51728,
51816,
51901,
51993,
52070,
52147,
52226,
52306,
52360,
52424,
52483,
52553,
52573,
52661,
52675,
52680,
52774,
52801,
52807,
52945,
53003,
53139,
53186,
53316,
53433,
53468,
53584,
53638,
53708,
53767,
53841,
53892,
54024,
54095,
54188,
54235,
54241,
54287,
54371,
54410,
54441,
54447,
54538,
54584,
54641,
54664,
54679,
54685,
54722,
54728,
54753,
54782,
54807,
54834,
54859,
54924,
54949,
54980,
54995,
55001,
55042,
55079,
55136,
55192,
55241,
55314,
55381,
55452,
55571,
55735,
55766,
55808,
55838,
55888,
55939,
55970,
56038,
56112,
56196,
56291,
56429,
56472,
56567,
56645,
56707,
56780,
56819,
56850,
56873,
56908,
56923,
56929,
57007,
57072,
57121,
57215,
57242,
57298,
57344,
57406,
57457,
57522,
57565,
57637,
57698,
57770,
57809,
57815,
57853,
57918,
57949,
57972,
58011,
58026,
58032,
58115,
58177,
58254,
58303,
58350,
58377,
58443,
58489,
58551,
58602,
58667,
58710,
58792,
58855,
58929,
58968,
58974,
59012,
59077,
59108,
59131,
59169,
59284,
59365,
59506,
59573,
59668,
59736,
59767,
59820,
59850,
59911,
59934,
59978,
59993,
59999,
60063,
60125,
60131,
60245,
60290,
60407,
60452,
60501,
60589,
60634,
60691,
60745,
60790,
60841,
60897,
60942,
61002,
61069,
61114,
61172,
61231,
61276,
61336,
61403,
61448,
61503,
61559,
61601,
61645,
61660,
61666,
61747,
61809,
61880,
61977,
62026,
62073,
62100,
62163,
62209,
62271,
62322,
62387,
62430,
62509,
62572,
62646,
62685,
62691,
62729,
62794,
62825,
62848,
62886,
63001,
63082,
63223,
63290,
63385,
63453,
63484,
63537,
63567,
63628,
63651,
63695,
63710,
63716,
63801,
63863,
63930,
63936,
63990,
64017,
64144,
64247,
64304,
64371,
64417,
64479,
64530,
64595,
64638,
64721,
64784,
64858,
64897,
64903,
64941,
65006,
65037,
65060,
65098,
65133,
65208,
65262,
65327,
65358,
65364,
65394,
65455,
65478,
65522,
65537,
65543,
65609,
65636,
65733,
65827,
65928,
66014,
66100,
66164,
66253,
66347,
66415,
66494,
66543,
66589,
66612,
66646,
66661,
66667,
66736,
66822,
66862,
66948,
67033,
67116,
67214,
67295,
67376,
67471,
67570,
67668,
67762,
67874,
67978,
68092,
68240,
68388,
68553,
68711,
68886,
69037,
69193,
69199,
69292,
69389,
69485,
69577,
69687,
69789,
69901,
70047,
70193,
70356,
70512,
70685,
70834,
70988,
71047,
71089,
71132,
71147,
71153,
71242,
71304,
71391,
71397,
71492,
71541,
71564,
71624,
71651,
71783,
71873,
71930,
72001,
72047,
72127,
72234,
72354,
72413,
72486,
72537,
72632,
72703,
72785,
72832,
72871,
72909,
72974,
73005,
73028,
73066,
73101,
73176,
73230,
73295,
73326,
73332,
73362,
73423,
73446,
73490,
73505,
73511,
73528,
73613,
73664,
73680,
73706,
73732,
73749,
73822,
73861,
73904,
73927,
73999,
74098,
74331,
74381,
74412,
74435,
74441,
74493,
74536,
74559,
74636,
74678,
74701,
74707,
74828,
74870,
74893,
74954,
74997,
75020,
75106,
75148,
75171,
75206,
75221,
75227,
75303,
75309,
75370,
75422,
75520,
75607,
75694,
75721,
75835,
75881,
75904,
75931,
76049,
76095,
76118,
76124,
76171,
76220,
76247,
76343,
76479,
76510,
76556,
76579,
76606,
76702,
76838,
76869,
76915,
76938,
76965,
77061,
77189,
77220,
77266,
77289,
77316,
77411,
77535,
77566,
77612,
77635,
77682,
77709,
77715,
77773,
77819,
77825,
77887,
77938,
78003,
78046,
78120,
78183,
78257,
78296,
78334,
78399,
78430,
78453,
78492,
78507,
78513,
78593,
78652,
78746,
78795,
78822,
78880,
78926,
78988,
79039,
79104,
79147,
79221,
79284,
79358,
79397,
79435,
79500,
79531,
79554,
79593,
79608,
79614,
79705,
79796,
79907,
79956,
79983,
80052,
80098,
80160,
80211,
80276,
80319,
80404,
80467,
80541,
80580,
80586,
80624,
80689,
80720,
80743,
80782,
80797,
80803,
80820,
80905,
80989,
81041,
81057,
81092,
81109,
81162,
81267,
81282,
81288,
81331,
81368,
81425,
81474,
81538,
81611,
81617,
81684,
81755,
81874,
82038,
82069,
82136,
82184,
82231,
82304,
82413,
82500,
82535,
82635,
82753,
82833,
82839,
82893,
82958,
82989,
83021,
83081,
83145,
83257,
83416,
83458,
83488,
83538,
83589,
83620,
83669,
83733,
83806,
83812,
83879,
83950,
84038,
84126,
84157,
84225,
84260,
84321,
84413,
84452,
84506,
84571,
84602,
84676,
84760,
84855,
84993,
85159,
85202,
85297,
85375,
85433,
85495,
85568,
85607,
85638,
85661,
85709,
85724,
85730,
85803,
85862,
85903,
85930,
86021,
86127,
86191,
86292,
86335,
86426,
86498,
86591,
86653,
86731,
86798,
86878,
86977,
87057,
87158,
87164,
87218,
87281,
87328,
87367,
87373,
87404,
87491,
87577,
87641,
87732,
87775,
87862,
87934,
88023,
88085,
88163,
88230,
88310,
88405,
88485,
88582,
88588,
88642,
88705,
88752,
88791,
88797,
88828,
88910,
88998,
89004,
89085,
89091,
89134,
89240,
89312,
89396,
89402,
89464,
89542,
89609,
89689,
89803,
89883,
89975,
89981,
90035,
90098,
90145,
90184,
90215,
90295,
90379,
90385,
90464,
90507,
90611,
90683,
90765,
90771,
90833,
90911,
90978,
91058,
91170,
91250,
91340,
91346,
91400,
91463,
91510,
91549,
91555,
91586,
91592,
91678,
91788,
91915,
91958,
92080,
92152,
92212,
92274,
92352,
92419,
92425,
92555,
92635,
92703,
92709,
92763,
92826,
92873,
92912,
92943,
93027,
93129,
93262,
93305,
93401,
93473,
93559,
93621,
93699,
93766,
93772,
93876,
93956,
94050,
94056,
94110,
94173,
94220,
94259,
94290,
94296,
94342,
94399,
94422,
94462,
94497,
94597,
94651,
94716,
94747,
94770,
94826,
94832,
94847,
94853
],
"line_end_idx": [
13,
60,
65,
72,
131,
139,
210,
282,
329,
337,
392,
400,
475,
548,
628,
703,
741,
748,
756,
788,
821,
854,
887,
912,
949,
981,
1008,
1034,
1067,
1103,
1140,
1184,
1232,
1268,
1309,
1359,
1402,
1437,
1469,
1531,
1577,
1630,
1673,
1717,
1768,
1814,
1866,
1918,
1959,
1991,
2050,
2118,
2172,
2215,
2265,
2307,
2372,
2437,
2489,
2547,
2602,
2643,
2689,
2741,
2787,
2850,
2895,
2945,
2998,
3057,
3110,
3169,
3226,
3281,
3340,
3397,
3443,
3510,
3561,
3615,
3673,
3731,
3785,
3850,
3916,
3968,
4014,
4073,
4121,
4168,
4235,
4303,
4387,
4472,
4517,
4573,
4619,
4674,
4719,
4770,
4832,
4888,
4926,
4969,
5012,
5056,
5099,
5140,
5185,
5231,
5272,
5315,
5356,
5402,
5435,
5476,
5524,
5567,
5613,
5666,
5720,
5761,
5813,
5869,
5874,
5936,
5989,
6022,
6058,
6063,
6071,
6148,
6229,
6314,
6399,
6406,
6473,
6481,
6513,
6518,
6534,
6565,
6581,
6654,
6700,
6742,
6758,
6840,
6873,
6889,
6963,
6968,
7043,
7105,
7119,
7124,
7140,
7201,
7216,
7247,
7263,
7324,
7377,
7414,
7428,
7433,
7449,
7534,
7562,
7578,
7610,
7671,
7745,
7796,
7830,
7897,
7950,
8007,
8037,
8059,
8093,
8130,
8164,
8178,
8194,
8255,
8271,
8350,
8366,
8381,
8397,
8478,
8494,
8509,
8525,
8623,
8639,
8654,
8670,
8776,
8792,
8807,
8823,
8893,
8909,
8924,
8939,
8955,
9058,
9063,
9131,
9192,
9243,
9294,
9352,
9409,
9470,
9519,
9577,
9627,
9679,
9684,
9700,
9781,
9835,
9850,
9884,
9915,
9947,
9980,
9996,
10116,
10177,
10214,
10302,
10365,
10405,
10427,
10432,
10477,
10491,
10525,
10530,
10632,
10718,
10758,
10840,
10862,
10902,
10992,
11014,
11054,
11059,
11115,
11168,
11200,
11232,
11272,
11308,
11344,
11358,
11363,
11405,
11453,
11487,
11561,
11566,
11643,
11685,
11815,
11876,
12024,
12097,
12135,
12140,
12248,
12331,
12449,
12515,
12553,
12645,
12650,
12731,
12807,
12872,
12910,
12915,
12994,
13077,
13153,
13209,
13320,
13480,
13555,
13601,
13639,
13644,
13697,
13754,
13784,
13806,
13811,
13825,
13830,
13846,
13929,
14006,
14059,
14074,
14099,
14122,
14138,
14197,
14268,
14366,
14535,
14595,
14858,
14922,
14992,
15069,
15150,
15413,
15482,
15567,
15652,
15796,
15825,
15907,
15969,
16113,
16135,
16149,
16154,
16170,
16250,
16285,
16300,
16334,
16350,
16390,
16395,
16431,
16474,
16488,
16493,
16509,
16592,
16660,
16675,
16712,
16760,
16776,
16863,
16899,
16940,
16954,
16959,
16975,
17037,
17052,
17085,
17138,
17154,
17216,
17242,
17325,
17406,
17481,
17580,
17666,
17752,
17825,
17916,
17994,
18083,
18159,
18252,
18332,
18412,
18479,
18576,
18660,
18739,
18805,
18889,
18960,
19044,
19114,
19196,
19264,
19347,
19416,
19497,
19564,
19646,
19714,
19808,
19883,
19971,
20045,
20131,
20203,
20302,
20387,
20477,
20554,
20644,
20720,
20812,
20890,
20977,
21050,
21133,
21203,
21285,
21357,
21460,
21550,
21580,
21585,
21630,
21697,
21719,
21770,
21784,
21789,
21860,
21912,
21960,
22003,
22075,
22119,
22210,
22317,
22410,
22509,
22622,
22721,
22812,
22905,
22984,
23083,
23174,
23273,
23366,
23483,
23584,
23621,
23701,
23783,
23788,
23830,
23856,
23905,
23950,
24011,
24061,
24125,
24167,
24232,
24294,
24378,
24416,
24421,
24458,
24533,
24563,
24585,
24623,
24637,
24642,
24712,
24762,
24810,
24854,
24940,
25042,
25130,
25224,
25332,
25426,
25512,
25600,
25674,
25768,
25854,
25948,
26036,
26148,
26244,
26288,
26293,
26319,
26367,
26412,
26473,
26523,
26587,
26629,
26693,
26755,
26839,
26877,
26882,
26919,
26994,
27024,
27046,
27084,
27098,
27103,
27177,
27203,
27208,
27296,
27357,
27414,
27444,
27580,
27693,
27789,
27794,
27886,
27985,
28093,
28160,
28206,
28251,
28320,
28342,
28356,
28361,
28433,
28479,
28505,
28510,
28580,
28625,
28630,
28691,
28741,
28783,
28869,
28931,
29004,
29042,
29079,
29143,
29173,
29195,
29221,
29289,
29334,
29390,
29412,
29433,
29447,
29452,
29525,
29572,
29598,
29603,
29674,
29719,
29724,
29785,
29835,
29877,
29964,
30026,
30099,
30137,
30174,
30238,
30268,
30290,
30317,
30385,
30430,
30486,
30508,
30522,
30527,
30616,
30696,
30722,
30727,
30831,
30876,
30881,
30942,
30992,
31034,
31154,
31216,
31289,
31327,
31364,
31428,
31458,
31480,
31507,
31592,
31637,
31693,
31715,
31729,
31734,
31814,
31871,
31897,
31902,
31975,
32020,
32025,
32086,
32136,
32178,
32267,
32329,
32402,
32440,
32477,
32541,
32571,
32593,
32620,
32683,
32728,
32784,
32806,
32820,
32825,
32896,
32951,
33000,
33079,
33105,
33110,
33161,
33206,
33211,
33272,
33322,
33364,
33437,
33504,
33566,
33639,
33677,
33714,
33778,
33808,
33830,
33835,
33873,
33887,
33892,
33971,
34036,
34122,
34148,
34153,
34230,
34275,
34280,
34341,
34391,
34433,
34526,
34588,
34661,
34699,
34736,
34800,
34830,
34852,
34857,
34895,
34909,
34914,
34986,
35043,
35092,
35173,
35199,
35204,
35256,
35301,
35306,
35367,
35417,
35459,
35532,
35600,
35662,
35735,
35773,
35810,
35874,
35904,
35926,
35931,
35969,
35983,
35988,
36069,
36258,
36324,
36350,
36355,
36449,
36494,
36499,
36560,
36610,
36652,
36762,
36824,
36897,
36935,
36972,
37036,
37066,
37088,
37115,
37194,
37239,
37295,
37317,
37331,
37336,
37414,
37455,
37626,
37692,
37718,
37723,
37827,
37872,
37877,
37938,
37988,
38030,
38150,
38212,
38285,
38323,
38360,
38424,
38454,
38476,
38503,
38582,
38627,
38683,
38705,
38719,
38724,
38800,
38839,
39002,
39055,
39121,
39147,
39152,
39254,
39299,
39304,
39365,
39415,
39457,
39575,
39637,
39710,
39748,
39785,
39849,
39879,
39901,
39928,
40007,
40052,
40108,
40130,
40144,
40149,
40231,
40254,
40455,
40460,
40572,
40598,
40603,
40710,
40755,
40760,
40821,
40871,
40913,
41036,
41098,
41171,
41209,
41246,
41310,
41340,
41362,
41455,
41520,
41547,
41610,
41655,
41711,
41733,
41747,
41752,
41829,
41923,
41971,
42057,
42131,
42157,
42273,
42383,
42455,
42500,
42561,
42611,
42675,
42717,
42805,
42867,
42951,
42989,
42994,
43031,
43106,
43136,
43158,
43207,
43267,
43289,
43315,
43388,
43433,
43489,
43511,
43516,
43530,
43535,
43609,
43656,
43661,
43739,
43803,
43808,
43834,
43839,
43963,
44040,
44197,
44227,
44315,
44388,
44486,
44576,
44627,
44721,
44751,
44805,
44866,
44971,
44976,
45057,
45134,
45139,
45216,
45273,
45336,
45402,
45436,
45521,
45574,
45635,
45665,
45771,
45867,
45965,
46031,
46168,
46253,
46353,
46418,
46482,
46559,
46679,
46759,
46838,
46959,
47051,
47097,
47135,
47209,
47273,
47342,
47441,
47529,
47633,
47663,
47668,
47708,
47778,
47911,
47982,
48060,
48131,
48220,
48349,
48420,
48498,
48566,
48571,
48638,
48679,
48713,
48791,
48855,
48929,
48989,
49042,
49118,
49148,
49153,
49227,
49316,
49416,
49421,
49588,
49633,
49689,
49721,
49770,
49821,
49851,
49891,
49913,
49927,
49932,
50008,
50034,
50109,
50114,
50229,
50234,
50305,
50391,
50471,
50565,
50664,
50771,
50844,
50849,
50894,
50950,
50972,
50986,
50991,
51007,
51087,
51102,
51129,
51152,
51185,
51201,
51282,
51369,
51467,
51534,
51592,
51636,
51723,
51728,
51816,
51901,
51993,
52070,
52147,
52226,
52306,
52360,
52424,
52483,
52553,
52573,
52661,
52675,
52680,
52774,
52801,
52807,
52945,
53003,
53139,
53186,
53316,
53433,
53468,
53584,
53638,
53708,
53767,
53841,
53892,
54024,
54095,
54188,
54235,
54241,
54287,
54371,
54410,
54441,
54447,
54538,
54584,
54641,
54664,
54679,
54685,
54722,
54728,
54753,
54782,
54807,
54834,
54859,
54924,
54949,
54980,
54995,
55001,
55042,
55079,
55136,
55192,
55241,
55314,
55381,
55452,
55571,
55735,
55766,
55808,
55838,
55888,
55939,
55970,
56038,
56112,
56196,
56291,
56429,
56472,
56567,
56645,
56707,
56780,
56819,
56850,
56873,
56908,
56923,
56929,
57007,
57072,
57121,
57215,
57242,
57298,
57344,
57406,
57457,
57522,
57565,
57637,
57698,
57770,
57809,
57815,
57853,
57918,
57949,
57972,
58011,
58026,
58032,
58115,
58177,
58254,
58303,
58350,
58377,
58443,
58489,
58551,
58602,
58667,
58710,
58792,
58855,
58929,
58968,
58974,
59012,
59077,
59108,
59131,
59169,
59284,
59365,
59506,
59573,
59668,
59736,
59767,
59820,
59850,
59911,
59934,
59978,
59993,
59999,
60063,
60125,
60131,
60245,
60290,
60407,
60452,
60501,
60589,
60634,
60691,
60745,
60790,
60841,
60897,
60942,
61002,
61069,
61114,
61172,
61231,
61276,
61336,
61403,
61448,
61503,
61559,
61601,
61645,
61660,
61666,
61747,
61809,
61880,
61977,
62026,
62073,
62100,
62163,
62209,
62271,
62322,
62387,
62430,
62509,
62572,
62646,
62685,
62691,
62729,
62794,
62825,
62848,
62886,
63001,
63082,
63223,
63290,
63385,
63453,
63484,
63537,
63567,
63628,
63651,
63695,
63710,
63716,
63801,
63863,
63930,
63936,
63990,
64017,
64144,
64247,
64304,
64371,
64417,
64479,
64530,
64595,
64638,
64721,
64784,
64858,
64897,
64903,
64941,
65006,
65037,
65060,
65098,
65133,
65208,
65262,
65327,
65358,
65364,
65394,
65455,
65478,
65522,
65537,
65543,
65609,
65636,
65733,
65827,
65928,
66014,
66100,
66164,
66253,
66347,
66415,
66494,
66543,
66589,
66612,
66646,
66661,
66667,
66736,
66822,
66862,
66948,
67033,
67116,
67214,
67295,
67376,
67471,
67570,
67668,
67762,
67874,
67978,
68092,
68240,
68388,
68553,
68711,
68886,
69037,
69193,
69199,
69292,
69389,
69485,
69577,
69687,
69789,
69901,
70047,
70193,
70356,
70512,
70685,
70834,
70988,
71047,
71089,
71132,
71147,
71153,
71242,
71304,
71391,
71397,
71492,
71541,
71564,
71624,
71651,
71783,
71873,
71930,
72001,
72047,
72127,
72234,
72354,
72413,
72486,
72537,
72632,
72703,
72785,
72832,
72871,
72909,
72974,
73005,
73028,
73066,
73101,
73176,
73230,
73295,
73326,
73332,
73362,
73423,
73446,
73490,
73505,
73511,
73528,
73613,
73664,
73680,
73706,
73732,
73749,
73822,
73861,
73904,
73927,
73999,
74098,
74331,
74381,
74412,
74435,
74441,
74493,
74536,
74559,
74636,
74678,
74701,
74707,
74828,
74870,
74893,
74954,
74997,
75020,
75106,
75148,
75171,
75206,
75221,
75227,
75303,
75309,
75370,
75422,
75520,
75607,
75694,
75721,
75835,
75881,
75904,
75931,
76049,
76095,
76118,
76124,
76171,
76220,
76247,
76343,
76479,
76510,
76556,
76579,
76606,
76702,
76838,
76869,
76915,
76938,
76965,
77061,
77189,
77220,
77266,
77289,
77316,
77411,
77535,
77566,
77612,
77635,
77682,
77709,
77715,
77773,
77819,
77825,
77887,
77938,
78003,
78046,
78120,
78183,
78257,
78296,
78334,
78399,
78430,
78453,
78492,
78507,
78513,
78593,
78652,
78746,
78795,
78822,
78880,
78926,
78988,
79039,
79104,
79147,
79221,
79284,
79358,
79397,
79435,
79500,
79531,
79554,
79593,
79608,
79614,
79705,
79796,
79907,
79956,
79983,
80052,
80098,
80160,
80211,
80276,
80319,
80404,
80467,
80541,
80580,
80586,
80624,
80689,
80720,
80743,
80782,
80797,
80803,
80820,
80905,
80989,
81041,
81057,
81092,
81109,
81162,
81267,
81282,
81288,
81331,
81368,
81425,
81474,
81538,
81611,
81617,
81684,
81755,
81874,
82038,
82069,
82136,
82184,
82231,
82304,
82413,
82500,
82535,
82635,
82753,
82833,
82839,
82893,
82958,
82989,
83021,
83081,
83145,
83257,
83416,
83458,
83488,
83538,
83589,
83620,
83669,
83733,
83806,
83812,
83879,
83950,
84038,
84126,
84157,
84225,
84260,
84321,
84413,
84452,
84506,
84571,
84602,
84676,
84760,
84855,
84993,
85159,
85202,
85297,
85375,
85433,
85495,
85568,
85607,
85638,
85661,
85709,
85724,
85730,
85803,
85862,
85903,
85930,
86021,
86127,
86191,
86292,
86335,
86426,
86498,
86591,
86653,
86731,
86798,
86878,
86977,
87057,
87158,
87164,
87218,
87281,
87328,
87367,
87373,
87404,
87491,
87577,
87641,
87732,
87775,
87862,
87934,
88023,
88085,
88163,
88230,
88310,
88405,
88485,
88582,
88588,
88642,
88705,
88752,
88791,
88797,
88828,
88910,
88998,
89004,
89085,
89091,
89134,
89240,
89312,
89396,
89402,
89464,
89542,
89609,
89689,
89803,
89883,
89975,
89981,
90035,
90098,
90145,
90184,
90215,
90295,
90379,
90385,
90464,
90507,
90611,
90683,
90765,
90771,
90833,
90911,
90978,
91058,
91170,
91250,
91340,
91346,
91400,
91463,
91510,
91549,
91555,
91586,
91592,
91678,
91788,
91915,
91958,
92080,
92152,
92212,
92274,
92352,
92419,
92425,
92555,
92635,
92703,
92709,
92763,
92826,
92873,
92912,
92943,
93027,
93129,
93262,
93305,
93401,
93473,
93559,
93621,
93699,
93766,
93772,
93876,
93956,
94050,
94056,
94110,
94173,
94220,
94259,
94290,
94296,
94342,
94399,
94422,
94462,
94497,
94597,
94651,
94716,
94747,
94770,
94826,
94832,
94847,
94853,
94859
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 94859,
"ccnet_original_nlines": 1718,
"rps_doc_curly_bracket": 0.0077588800340890884,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.07939861714839935,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.008370580151677132,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5609102249145508,
"rps_doc_frac_unique_words": 0.5497006177902222,
"rps_doc_mean_word_length": 9.51656723022461,
"rps_doc_num_sentences": 1353,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 6.946564674377441,
"rps_doc_word_count": 5010,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.018750790506601334,
"rps_doc_frac_chars_dupe_6grams": 0.011074289679527283,
"rps_doc_frac_chars_dupe_7grams": 0.010109479539096355,
"rps_doc_frac_chars_dupe_8grams": 0.0089768897742033,
"rps_doc_frac_chars_dupe_9grams": 0.0089768897742033,
"rps_doc_frac_chars_top_2gram": 0.02525274083018303,
"rps_doc_frac_chars_top_3gram": 0.02114183083176613,
"rps_doc_frac_chars_top_4gram": 0.0033768198918551207,
"rps_doc_books_importance": -4651.23974609375,
"rps_doc_books_importance_length_correction": -4651.23974609375,
"rps_doc_openwebtext_importance": -2002.50439453125,
"rps_doc_openwebtext_importance_length_correction": -2002.50439453125,
"rps_doc_wikipedia_importance": -1455.3526611328125,
"rps_doc_wikipedia_importance_length_correction": -1455.3526611328125
},
"fasttext": {
"dclm": 0.9970594644546509,
"english": 0.18164832890033722,
"fineweb_edu_approx": 2.4356329441070557,
"eai_general_math": 0.43738871812820435,
"eai_open_web_math": 0.048615988343954086,
"eai_web_code": 0.9181392192840576
}
}
|
{
"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": "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
|
-8,934,470,418,384,976,000
|
3
$\begingroup$
Given the following matrix, find an approximation of the largest eigenvalue. $$ A = \begin{bmatrix} 3 & 2 \\ 7 & 5 \\ \end{bmatrix} $$
And I was also given $$\vec x= \begin{bmatrix} 1 \\ 0 \\ \end{bmatrix} $$
How my professor solves this is by calculating the slopes of $A\vec x = \vec b_1$, $A^2 \vec x = \vec b_2$, $A^3 \vec x = \vec b_3$ and so on until we get the slope of $\vec b_i$ converging to the same value. Then when we get the approximated $\vec b$, he plug into $A \vec b = \lambda \vec b$, and the corresponding $\lambda$ is the largest eigenvalue.
Since slope is $\frac yx$ , it works fine for $2 x 2$ matrix. But how do I apply this method for a bigger matrix?
$\endgroup$
• $\begingroup$ I've given you a full explanation and representation of the method used down below, make sure to check it out ! $\endgroup$ – Rebellos Dec 7 '17 at 1:23
• $\begingroup$ It's very helpful thank you! $\endgroup$ – dembrownies Dec 7 '17 at 1:28
1
$\begingroup$
Here's a hint: You want to determine when $\mathbf{b}_n$ is a near-scalar multiple of $\mathbf{b}_{n-1}$. In $\mathbb{R}^2$, (nonzero) vectors are scalar multiples of one another iff their slopes are equal. A possibly more useful definition is that two vectors $\mathbf{v}$ and $\mathbf{w}$ are scalar multiples of one another if and only if
$$\hat{\mathbf{v}} = \pm\hat{\mathbf{w}},$$
where
$$\hat{\mathbf{v}} = \frac{\mathbf{v}}{|\mathbf{v}|},$$
which extends more nicely to multiple dimensions.
$\endgroup$
• $\begingroup$ I'll try to apply this to the problem and see how it works out. Thank you ! $\endgroup$ – dembrownies Dec 7 '17 at 1:21
• $\begingroup$ @dembrownies Great. Let me know if you have any more questions. $\endgroup$ – Carl Schildkraut Dec 7 '17 at 2:13
2
$\begingroup$
What you mention, is a known numerical analysis method for the approximation of the largest (by absolute value) eigenvalue of a matrix.
Let $A\in \mathbb R^{n\times n}$ have $n$ linearly independent eigenvalues $\{ u \}_{i=1}^n$ as well as a unique eigenvalue $λ_1$ such that : $|λ_1| < |λ_2| \leq \dots \leq |λ_n|$ where $λ_1 \in \mathbb R$ and $u_1 \in \mathbb R^n$ : $Au_1=λ_1u_1.$
The method "Power Iteration" :
$$\begin{cases} x_k= Ax_{k-1} \to x_k = A^kx_0 \quad k=1,2,\dots \\ x_0 \end{cases}$$
Thorem : The method "Power Iteration" converges $\forall x_0$ (that is adequate for the problem given) and it is :
$$\lim_{k\to \infty} ε_k\frac{x_k}{||x_k||_2}=u_1$$
$$\lim_{k \to \infty} \frac{x_{k,i}}{x_{k-1,i}}=λ_1 \quad \forall \space i=1,2,\dots,n \quad \text{with} \quad u_{1,i} \neq 0 $$
where $\{ ε_k\}_{k=1}^\infty = \{ \pm1\}$ and $u_1$ eigenvector of $A$ with $||u_1||_2=1$.
I've given you a formal explanation of the method according to my old notes and my knowledge, for more, check here.
$\endgroup$
1
$\begingroup$
You normalize the vector at each iteration by dividing by its length, and wait until the resulting sequence of unit vectors has gotten close enough to converging for your purpose. (This is called the power method. It's pretty much the worst iterative method for eigenvalues there is, but it is the theoretical basis for lots of better methods.)
This is similar to what you're doing when you measure the slope in the 2D case, except in that case you divide by $x$ instead of dividing by $\sqrt{x^2+y^2}$. The point is that all that matters is the direction, not the magnitude.
$\endgroup$
• $\begingroup$ that makes more sense. thank you! $\endgroup$ – dembrownies Dec 7 '17 at 1:20
0
$\begingroup$
The method you are thinking of is called Power Iteration. More formally, take any vector $x_0\ne 0$. (In practice, it is good to choose $x_0$ randomly. Then define
$$ x_k := \frac{Ax_{k-1}}{\|Ax_{k-1}\|_2}, \quad k\in\{1,2,\ldots\} $$
With high probability, $x_k$ will converge to an eigenvector of $A$ corresponding to the largest eigenvalue $\lambda_1$ of $A$ with
$$ \lambda_1 = \lim_{k\to\infty} x_k^T Ax_k. $$
In practice, in computer arithmetic, this method is numerically stable. For a better method, see for example, this.
$\endgroup$
0
$\begingroup$
Its the power itaratin method
https://en.wikipedia.org/wiki/Power_iteration
The main reason way it works is that, if J is the Jordan canonical (possibly diagonal) form of A, which "contains" A's eigenvalues :
$$A=P^{-1}JP \\ A^2=P^{-1}JPP^{-1}JP=P^{-1}J^2P\\ A^3=P^{-1}J^2PP^{-1}JP=P^{-1}J^3P\\ ...\\ A^n=P^{-1}J^{n-1}PP^{-1}JP=P^{-1}J^nP$$
$\endgroup$
Your Answer
By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "https://math.stackexchange.com/questions/2554808/finding-approximation-of-largest-eigenvalue",
"source_domain": "math.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2019-22",
"warc_metadata": {
"Content-Length": "155368",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4HQRPPNPXZMJUSIK6JC3LLB6ZSNDYEGE",
"WARC-Concurrent-To": "<urn:uuid:3585cd7d-48d8-4db5-bb7c-86149b5fc4f1>",
"WARC-Date": "2019-05-21T02:29:53Z",
"WARC-IP-Address": "151.101.1.69",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:S4ZZFDVQVYX6KFACVFWCZTMBFARLDGC2",
"WARC-Record-ID": "<urn:uuid:c16a6083-1628-489c-94a3-525d0b01e397>",
"WARC-Target-URI": "https://math.stackexchange.com/questions/2554808/finding-approximation-of-largest-eigenvalue",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:6f94897b-36ab-4215-aa5a-16730bef75f8>"
},
"warc_info": "isPartOf: CC-MAIN-2019-22\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for May 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-179-25-131.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,
2,
16,
17,
152,
153,
227,
228,
582,
583,
697,
698,
710,
881,
972,
974,
988,
989,
1331,
1332,
1376,
1377,
1383,
1384,
1440,
1441,
1491,
1492,
1504,
1642,
1773,
1775,
1789,
1790,
1926,
1927,
2176,
2177,
2208,
2209,
2295,
2296,
2411,
2412,
2464,
2465,
2594,
2595,
2686,
2687,
2803,
2804,
2816,
2818,
2832,
2833,
3178,
3179,
3410,
3411,
3423,
3519,
3521,
3535,
3536,
3700,
3701,
3772,
3773,
3905,
3906,
3954,
3955,
4071,
4072,
4084,
4086,
4100,
4101,
4131,
4132,
4178,
4179,
4312,
4313,
4445,
4446,
4458,
4459,
4471,
4472,
4572,
4573
],
"line_end_idx": [
2,
16,
17,
152,
153,
227,
228,
582,
583,
697,
698,
710,
881,
972,
974,
988,
989,
1331,
1332,
1376,
1377,
1383,
1384,
1440,
1441,
1491,
1492,
1504,
1642,
1773,
1775,
1789,
1790,
1926,
1927,
2176,
2177,
2208,
2209,
2295,
2296,
2411,
2412,
2464,
2465,
2594,
2595,
2686,
2687,
2803,
2804,
2816,
2818,
2832,
2833,
3178,
3179,
3410,
3411,
3423,
3519,
3521,
3535,
3536,
3700,
3701,
3772,
3773,
3905,
3906,
3954,
3955,
4071,
4072,
4084,
4086,
4100,
4101,
4131,
4132,
4178,
4179,
4312,
4313,
4445,
4446,
4458,
4459,
4471,
4472,
4572,
4573,
4663
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4663,
"ccnet_original_nlines": 92,
"rps_doc_curly_bracket": 0.02444778010249138,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2602633535861969,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03872967138886452,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.41828039288520813,
"rps_doc_frac_unique_words": 0.4602026045322418,
"rps_doc_mean_word_length": 4.651230335235596,
"rps_doc_num_sentences": 36,
"rps_doc_symbol_to_word_ratio": 0.0007745900074951351,
"rps_doc_unigram_entropy": 5.26801061630249,
"rps_doc_word_count": 691,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.05227131024003029,
"rps_doc_frac_chars_dupe_6grams": 0.05227131024003029,
"rps_doc_frac_chars_dupe_7grams": 0.033602990210056305,
"rps_doc_frac_chars_dupe_8grams": 0.033602990210056305,
"rps_doc_frac_chars_dupe_9grams": 0.033602990210056305,
"rps_doc_frac_chars_top_2gram": 0.017112629488110542,
"rps_doc_frac_chars_top_3gram": 0.009334160014986992,
"rps_doc_frac_chars_top_4gram": 0.012445550411939621,
"rps_doc_books_importance": -638.3822021484375,
"rps_doc_books_importance_length_correction": -638.3822021484375,
"rps_doc_openwebtext_importance": -316.7601623535156,
"rps_doc_openwebtext_importance_length_correction": -316.7601623535156,
"rps_doc_wikipedia_importance": -209.84170532226562,
"rps_doc_wikipedia_importance_length_correction": -209.84170532226562
},
"fasttext": {
"dclm": 0.8793066143989563,
"english": 0.7843931913375854,
"fineweb_edu_approx": 2.2770068645477295,
"eai_general_math": 0.8402614593505859,
"eai_open_web_math": 0.9704126715660095,
"eai_web_code": 0.024422170594334602
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "512.5",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Algebra"
}
},
"secondary": {
"code": "518",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Numerical analysis"
}
}
},
"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": "1",
"label": "Leftover HTML"
},
"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": "4",
"label": "Advanced Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
672,733,759,997,279,400
|
Skip to content
Instantly share code, notes, and snippets.
@sincerefly
Created March 28, 2019 03:08
Show Gist options
• Save sincerefly/dd69c0c1a274a70a7f66422361bdcc1f to your computer and use it in GitHub Desktop.
Save sincerefly/dd69c0c1a274a70a7f66422361bdcc1f to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<!--
* Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree.
-->
<html>
<head>
<meta charset="utf-8">
<meta name="description" content="WebRTC code samples">
<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1, maximum-scale=1">
<meta itemprop="description" content="Client-side WebRTC code samples">
<meta itemprop="image" content="images/webrtc-icon-192x192.png">
<meta itemprop="name" content="WebRTC code samples">
<meta name="mobile-web-app-capable" content="yes">
<meta id="theme-color" name="theme-color" content="#ffffff">
<base target="_blank">
<title>Peer connection</title>
<link rel="icon" sizes="192x192" href="images/webrtc-icon-192x192.png">
<!-- <link href="//fonts.loli.net/css?family=Roboto:300,400,500,700" rel="stylesheet" type="text/css"> -->
<link rel="stylesheet" href="css/main.css"/>
<link rel="stylesheet" href="css/peerconn.css"/>
<style>
body::-webkit-scrollbar {
display: none;
}
body {
/* background-color: #d8cbbb; */
padding: 1px;
margin: 1px;
width: 800px;
height: 600px;
background-color: #3c4f65;
-webkit-app-region: drag;
}
h1 {
color: white;
/* -webkit-app-region: drag; */
user-select: none;
}
p {
color: white;
user-select: none;
}
#quit {
position: absolute;
top: 25px;
right: 25px;
-webkit-app-region: no-drag;
}
button {
-webkit-app-region: no-drag;
user-select: none;
}
video {
width: 320px;
height: 240px;
}
</style>
</head>
<body>
<div id="container">
<h1>WebRTC Peer Connection</h1>
<!-- <h1>点对点音视频通信</h1> -->
<video id="localVideo" poster="images/poster.png" playsinline autoplay muted></video>
<video id="remoteVideo" poster="images/poster.png" playsinline autoplay></video>
<img id="quit" src="images/close-circular-button.png" width="28px"/>
<div class="box">
<button id="startButton" hidden>Start</button>
<button id="prepareButton" hidden>Prepare</button>
<button id="startButton2">Start</button>
<button id="callButton">Call</button>
<button id="hangupButton">Hang Up</button>
</div>
<p>点击Start可以开启本地摄像头并使程序处于准备状态可以接受远程的视频, 点击Call可以发起视频请求, 点击Hang Up可以停止接受远程的视频连接</p>
</div>
<script>
let quitButton = document.getElementById('quit');
quitButton.addEventListener('click', () => {
window.close()
})
</script>
<script src="js/adapter.js"></script>
<script src="js/socket.io.js"></script>
<script src="js/main.js"></script>
</body>
</html>
/*
* Copyright (c) 2015 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree.
*/
'use strict';
var socket = io.connect('http://192.168.38.142:8181')
// ice_servers
var servers = {
"iceServers": [
{
urls: "stun:192.168.38.142:3478"
},
// {
// urls: "stun:stun.l.google.com:19302"
// },
// {
// urls: "turn:192.168.38.142:3478",
// username: "dongdong", // optional
// credential: "123456" // optional
// },
]
}
const startButton = document.getElementById('startButton');
const startButton2 = document.getElementById('startButton2');
const prepareButton = document.getElementById('prepareButton');
const callButton = document.getElementById('callButton');
const hangupButton = document.getElementById('hangupButton');
callButton.disabled = true;
hangupButton.disabled = true;
startButton.addEventListener('click', start);
prepareButton.addEventListener('click', prepare);
callButton.addEventListener('click', call);
hangupButton.addEventListener('click', hangup);
startButton2.addEventListener('click', async () => {
await start();
await prepare();
})
let startTime;
const localVideo = document.getElementById('localVideo');
const remoteVideo = document.getElementById('remoteVideo');
localVideo.addEventListener('loadedmetadata', function() {
console.log(`Local video videoWidth: ${this.videoWidth}px, videoHeight: ${this.videoHeight}px`);
});
remoteVideo.addEventListener('loadedmetadata', function() {
console.log(`Remote video videoWidth: ${this.videoWidth}px, videoHeight: ${this.videoHeight}px`);
});
remoteVideo.addEventListener('resize', () => {
console.log(`Remote video size changed to ${remoteVideo.videoWidth}x${remoteVideo.videoHeight}`);
if (startTime) {
const elapsedTime = window.performance.now() - startTime;
console.log('Setup time: ' + elapsedTime.toFixed(3) + 'ms');
startTime = null;
}
});
let localStream;
let localPeerConnection;
const offerOptions = {
offerToReceiveAudio: 1,
offerToReceiveVideo: 1
};
function getName(pc) {
return (pc === localPeerConnection) ? 'localPeerConnection' : 'remote';
}
// 点击开始,启用本地摄像头
async function start() {
console.log('Requesting local stream');
startButton.disabled = true;
try {
const stream = await navigator.mediaDevices.getUserMedia({audio: true, video: true});
console.log('Received local stream');
localVideo.srcObject = stream;
localStream = stream;
callButton.disabled = false;
} catch (e) {
alert(`getUserMedia() error: ${e.name}`);
}
}
// 进入准备阶段,初始化将本地音视频轨道加入到RTCPeerConnection
// 并监听获取自己的ICE协商信息
async function prepare() {
console.log('Prepare for peer connect');
startButton.disabled = true;
prepareButton.disabled = true;
startTime = window.performance.now();
const videoTracks = localStream.getVideoTracks();
const audioTracks = localStream.getAudioTracks();
if (videoTracks.length > 0) {
console.log(`Using video device: ${videoTracks[0].label}`);
}
if (audioTracks.length > 0) {
console.log(`Using audio device: ${audioTracks[0].label}`);
}
const configuration = servers;
console.log('RTCPeerConnection configuration:', configuration);
localPeerConnection = new RTCPeerConnection(configuration);
// localPeerConnection = new RTCPeerConnection();
console.log('Created local peer connection object localPeerConnection');
localPeerConnection.addEventListener('icecandidate', e => onIceCandidate(e));
localPeerConnection.addEventListener('iceconnectionstatechange', e => onIceStateChange(localPeerConnection, e));
localPeerConnection.addEventListener('track', gotRemoteStream);
localStream.getTracks().forEach(track => localPeerConnection.addTrack(track, localStream));
console.log('Added local stream to localPeerConnection');
}
// 发送自己的SDP信息
async function call() {
callButton.disabled = true;
hangupButton.disabled = false;
console.log('Starting call');
try {
console.log('localPeerConnection createOffer start');
const offer = await localPeerConnection.createOffer(offerOptions);
console.log(offer);
localPeerConnection.setLocalDescription(offer)
socket.emit('offer', offer);
} catch (e) {
console.log(`Failed to create session description: ${e.toString()}`);
}
}
// 当收到SDP信息后,生成回复SDP信息
socket.on('offer', (desc) => {
console.log("I got offer: ");
localPeerConnection.setRemoteDescription(desc);
localPeerConnection.createAnswer(function(desc) {
localPeerConnection.setLocalDescription(desc)
console.log("I will reply a answer")
socket.emit('answer', desc)
}, function(error){
console.log(error)
});
})
// 当收到回复的SDP后,设置到连接中
socket.on('answer', (desc) => {
console.log("I got answer: ", desc.sdp);
localPeerConnection.setRemoteDescription(desc);
})
function gotRemoteStream(e) {
if (remoteVideo.srcObject !== e.streams[0]) {
remoteVideo.srcObject = e.streams[0];
console.log('received remote stream');
callButton.disabled = true;
hangupButton.disabled = false;
}
}
// 获取到其它客户端的ice信息,设置到连接中
socket.on('onicecandidate', (candidate) => {
localPeerConnection.addIceCandidate(candidate)
})
// 当获得到自己的公网地址后,发送给其它客户端
async function onIceCandidate(event) {
console.log('I got my icecandidate info')
if (event.candidate) {
console.log(event.candidate.candidate)
}
socket.emit('onicecandidate', event.candidate);
}
function onIceStateChange(pc, event) {
if (pc) {
console.log(`${getName(pc)} ICE state: ${pc.iceConnectionState}`);
console.log('ICE state change event: ', event);
}
}
function hangup() {
console.log('Ending call');
localPeerConnection.close();
localPeerConnection = null;
hangupButton.disabled = true;
callButton.disabled = false;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
|
{
"url": "https://gist.github.com/sincerefly/dd69c0c1a274a70a7f66422361bdcc1f",
"source_domain": "gist.github.com",
"snapshot_id": "CC-MAIN-2024-22",
"warc_metadata": {
"Content-Length": "188829",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:I7LP722WBPHJL6PO5JZ3GTJ6PBBHD4IT",
"WARC-Concurrent-To": "<urn:uuid:b34dfc66-188b-4fba-926e-7b79859e6519>",
"WARC-Date": "2024-05-22T11:50:54Z",
"WARC-IP-Address": "140.82.112.3",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:IGNLY65DWZVOMZOWA5AM3TFITMJ7BYHU",
"WARC-Record-ID": "<urn:uuid:41ee3e00-8740-422b-910d-8e6b79ebd2be>",
"WARC-Target-URI": "https://gist.github.com/sincerefly/dd69c0c1a274a70a7f66422361bdcc1f",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:bd4b4211-b679-4904-a4ff-cdb2c21d22e4>"
},
"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-96\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,
60,
61,
73,
102,
120,
220,
316,
332,
337,
407,
409,
470,
536,
544,
548,
555,
562,
585,
641,
746,
818,
883,
936,
987,
1048,
1071,
1102,
1174,
1281,
1326,
1375,
1383,
1409,
1424,
1426,
1433,
1466,
1480,
1493,
1507,
1522,
1549,
1575,
1577,
1582,
1596,
1628,
1647,
1649,
1653,
1667,
1686,
1688,
1696,
1716,
1727,
1740,
1769,
1771,
1780,
1809,
1828,
1830,
1838,
1852,
1867,
1869,
1878,
1886,
1893,
1914,
1946,
1973,
2059,
2140,
2209,
2227,
2274,
2325,
2366,
2404,
2447,
2454,
2537,
2544,
2553,
2603,
2648,
2663,
2666,
2676,
2714,
2754,
2789,
2797,
2805,
2808,
2878,
2880,
2941,
3007,
3015,
3018,
3032,
3086,
3101,
3117,
3133,
3135,
3168,
3171,
3176,
3216,
3222,
3227,
3264,
3301,
3337,
3343,
3345,
3347,
3407,
3469,
3533,
3591,
3653,
3681,
3711,
3757,
3807,
3851,
3899,
3952,
3967,
3984,
3987,
4002,
4060,
4120,
4179,
4276,
4280,
4340,
4438,
4442,
4489,
4587,
4604,
4662,
4723,
4741,
4743,
4747,
4764,
4789,
4812,
4836,
4859,
4862,
4885,
4957,
4959,
4975,
5000,
5040,
5069,
5075,
5161,
5199,
5230,
5252,
5281,
5295,
5337,
5339,
5341,
5383,
5402,
5429,
5470,
5499,
5530,
5568,
5618,
5668,
5698,
5758,
5760,
5790,
5850,
5852,
5883,
5947,
6007,
6057,
6130,
6208,
6321,
6385,
6477,
6535,
6537,
6551,
6575,
6603,
6634,
6664,
6670,
6724,
6791,
6811,
6858,
6887,
6901,
6971,
6973,
6975,
6998,
7029,
7059,
7107,
7157,
7203,
7240,
7268,
7288,
7307,
7311,
7314,
7335,
7367,
7408,
7456,
7459,
7489,
7535,
7573,
7612,
7640,
7671,
7673,
7675,
7700,
7745,
7792,
7795,
7820,
7859,
7901,
7924,
7963,
7965,
8013,
8015,
8054,
8064,
8131,
8179,
8181,
8183,
8203,
8231,
8260,
8288,
8318,
8347,
8349
],
"line_end_idx": [
16,
17,
60,
61,
73,
102,
120,
220,
316,
332,
337,
407,
409,
470,
536,
544,
548,
555,
562,
585,
641,
746,
818,
883,
936,
987,
1048,
1071,
1102,
1174,
1281,
1326,
1375,
1383,
1409,
1424,
1426,
1433,
1466,
1480,
1493,
1507,
1522,
1549,
1575,
1577,
1582,
1596,
1628,
1647,
1649,
1653,
1667,
1686,
1688,
1696,
1716,
1727,
1740,
1769,
1771,
1780,
1809,
1828,
1830,
1838,
1852,
1867,
1869,
1878,
1886,
1893,
1914,
1946,
1973,
2059,
2140,
2209,
2227,
2274,
2325,
2366,
2404,
2447,
2454,
2537,
2544,
2553,
2603,
2648,
2663,
2666,
2676,
2714,
2754,
2789,
2797,
2805,
2808,
2878,
2880,
2941,
3007,
3015,
3018,
3032,
3086,
3101,
3117,
3133,
3135,
3168,
3171,
3176,
3216,
3222,
3227,
3264,
3301,
3337,
3343,
3345,
3347,
3407,
3469,
3533,
3591,
3653,
3681,
3711,
3757,
3807,
3851,
3899,
3952,
3967,
3984,
3987,
4002,
4060,
4120,
4179,
4276,
4280,
4340,
4438,
4442,
4489,
4587,
4604,
4662,
4723,
4741,
4743,
4747,
4764,
4789,
4812,
4836,
4859,
4862,
4885,
4957,
4959,
4975,
5000,
5040,
5069,
5075,
5161,
5199,
5230,
5252,
5281,
5295,
5337,
5339,
5341,
5383,
5402,
5429,
5470,
5499,
5530,
5568,
5618,
5668,
5698,
5758,
5760,
5790,
5850,
5852,
5883,
5947,
6007,
6057,
6130,
6208,
6321,
6385,
6477,
6535,
6537,
6551,
6575,
6603,
6634,
6664,
6670,
6724,
6791,
6811,
6858,
6887,
6901,
6971,
6973,
6975,
6998,
7029,
7059,
7107,
7157,
7203,
7240,
7268,
7288,
7307,
7311,
7314,
7335,
7367,
7408,
7456,
7459,
7489,
7535,
7573,
7612,
7640,
7671,
7673,
7675,
7700,
7745,
7792,
7795,
7820,
7859,
7901,
7924,
7963,
7965,
8013,
8015,
8054,
8064,
8131,
8179,
8181,
8183,
8203,
8231,
8260,
8288,
8318,
8347,
8349,
8446
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 8446,
"ccnet_original_nlines": 269,
"rps_doc_curly_bracket": 0.01255031954497099,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.06217345967888832,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.008359460160136223,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5099268555641174,
"rps_doc_frac_unique_words": 0.5680000185966492,
"rps_doc_mean_word_length": 10.112000465393066,
"rps_doc_num_sentences": 152,
"rps_doc_symbol_to_word_ratio": 0.0020898599177598953,
"rps_doc_unigram_entropy": 5.6108832359313965,
"rps_doc_word_count": 625,
"rps_doc_frac_chars_dupe_10grams": 0.07658228278160095,
"rps_doc_frac_chars_dupe_5grams": 0.09525316208600998,
"rps_doc_frac_chars_dupe_6grams": 0.07658228278160095,
"rps_doc_frac_chars_dupe_7grams": 0.07658228278160095,
"rps_doc_frac_chars_dupe_8grams": 0.07658228278160095,
"rps_doc_frac_chars_dupe_9grams": 0.07658228278160095,
"rps_doc_frac_chars_top_2gram": 0.003164560068398714,
"rps_doc_frac_chars_top_3gram": 0.007120249792933464,
"rps_doc_frac_chars_top_4gram": 0.016455700621008873,
"rps_doc_books_importance": -811.9198608398438,
"rps_doc_books_importance_length_correction": -811.9198608398438,
"rps_doc_openwebtext_importance": -558.0301513671875,
"rps_doc_openwebtext_importance_length_correction": -558.0301513671875,
"rps_doc_wikipedia_importance": -433.2557067871094,
"rps_doc_wikipedia_importance_length_correction": -433.2557067871094
},
"fasttext": {
"dclm": 0.9829393625259399,
"english": 0.29735708236694336,
"fineweb_edu_approx": 3.1361935138702393,
"eai_general_math": 0.08256477117538452,
"eai_open_web_math": 0.035468101501464844,
"eai_web_code": 0.4942883849143982
}
}
|
{
"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.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": "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": "4",
"label": "Missing Images or Figures"
}
},
"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,382,127,388,782,393,300
|
Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
PerlMonks
Re: How to Sell Perl 6
by marcussen (Pilgrim)
on Oct 28, 2008 at 00:33 UTC ( #719869=note: print w/ replies, xml ) Need Help??
in reply to How to Sell Perl 6
My biggest concern with perl6 used to be that without a default implementation you would be spending too much time making sure that your code would run on the different implementations, as I fully expect the underlying languages to cause differences in compiler behavior. Although it is my personal belief that Rakudo will become the de-facto implementation and solve that issue.
Projects like November helps sell perl6 more than anything. The more usable perl6 seems to be, the more it will get considered for use.
Confucius says kill mosquito unless cannon
Comment on Re: How to Sell Perl 6
Log In?
Username:
Password:
What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://719869]
help
Chatterbox?
and the web crawler heard nothing...
How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (6)
As of 2014-09-17 03:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
Voting Booth?
How do you remember the number of days in each month?
Results (57 votes), past polls
|
{
"url": "http://www.perlmonks.org/?node_id=719869",
"source_domain": "www.perlmonks.org",
"snapshot_id": "crawl=CC-MAIN-2014-41",
"warc_metadata": {
"Content-Length": "17820",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:J74Z3S7F2KTG7DSRGJHFSXDC6U3O6KWJ",
"WARC-Concurrent-To": "<urn:uuid:b7a121ef-72b9-4c09-84cf-edaeb18d57f3>",
"WARC-Date": "2014-09-17T03:34:23Z",
"WARC-IP-Address": "216.92.34.251",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:N6N4QLZYD3USASAK4775N7GB2NTPVJIR",
"WARC-Record-ID": "<urn:uuid:b9ff4a9f-7c76-4582-9ec4-e616fdc27c1a>",
"WARC-Target-URI": "http://www.perlmonks.org/?node_id=719869",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:cfcb542b-76ea-4142-b789-bb733d287441>"
},
"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,
63,
82,
84,
96,
97,
120,
121,
144,
225,
226,
227,
258,
259,
639,
640,
776,
777,
820,
821,
822,
856,
857,
865,
875,
885,
886,
906,
924,
937,
950,
980,
985,
997,
1034,
1035,
1073,
1086,
1124,
1151,
1161,
1174,
1186,
1197,
1215,
1216,
1274,
1275,
1276,
1277,
1278,
1279,
1280,
1281,
1282,
1283,
1284,
1285
],
"line_end_idx": [
63,
82,
84,
96,
97,
120,
121,
144,
225,
226,
227,
258,
259,
639,
640,
776,
777,
820,
821,
822,
856,
857,
865,
875,
885,
886,
906,
924,
937,
950,
980,
985,
997,
1034,
1035,
1073,
1086,
1124,
1151,
1161,
1174,
1186,
1197,
1215,
1216,
1274,
1275,
1276,
1277,
1278,
1279,
1280,
1281,
1282,
1283,
1284,
1285,
1319
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1319,
"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.3003663122653961,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.025641029700636864,
"rps_doc_frac_lines_end_with_ellipsis": 0.017241379246115685,
"rps_doc_frac_no_alph_words": 0.24175824224948883,
"rps_doc_frac_unique_words": 0.7023255825042725,
"rps_doc_mean_word_length": 4.679069995880127,
"rps_doc_num_sentences": 19,
"rps_doc_symbol_to_word_ratio": 0.007326010148972273,
"rps_doc_unigram_entropy": 4.838978290557861,
"rps_doc_word_count": 215,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.04572565108537674,
"rps_doc_frac_chars_dupe_6grams": 0.03180915117263794,
"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.014910539612174034,
"rps_doc_frac_chars_top_3gram": 0.026838969439268112,
"rps_doc_frac_chars_top_4gram": 0.03876740112900734,
"rps_doc_books_importance": -103.33575439453125,
"rps_doc_books_importance_length_correction": -103.33575439453125,
"rps_doc_openwebtext_importance": -70.20968627929688,
"rps_doc_openwebtext_importance_length_correction": -70.20968627929688,
"rps_doc_wikipedia_importance": -46.8987922668457,
"rps_doc_wikipedia_importance_length_correction": -46.898624420166016
},
"fasttext": {
"dclm": 0.02164578065276146,
"english": 0.913132905960083,
"fineweb_edu_approx": 1.770513653755188,
"eai_general_math": 0.00016682999557815492,
"eai_open_web_math": 0.05592269077897072,
"eai_web_code": -0.00000869999985297909
}
}
|
{
"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": "338.72",
"labels": {
"level_1": "Social sciences",
"level_2": "Economics",
"level_3": "Industries, Prices, and Microeconomics"
}
}
},
"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": "-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": "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": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-8,159,818,687,826,201,000
|
Culture
Why does Amazon taunt me with surround sound?
Despite a label of 5.1 surround I only ever get stereo sound from Amazon Prime. I mange to get surround from other providers and devices, just not Amazon. Is it one of those annoying licensing issues, perhaps a language mismatch, or is it a technical deficiency? I’m determined to find out.
The answer I got from Amazon support is perplexing… but more on that later.
My equipment
I joined the world of big screen TVs in 2015 when I bought a LG 49UBB20V. I was determining how to get streaming video but not enjoying the complexity of getting a good internet connection to my TV, finding the right media player device, and finding the right connectors. As questionable as they may be, a Smart TV made it easy for me — at least I thought at the time.
I have this TV connected to a Yamaha RX-V457 receiver via optical cable. I’ve never had any problems with this amplifier before. I presume it does full surround, but I only have the front left/right and center channels connected. For completeness, this is hooked up to a set a of Magnat speakers, though I’m quite positive they aren’t involved in my problem.
I don’t really need full surround, I just like having the center channel so speech comes through clearly. It’s been a trend over the years that voice is being lost more and more in the stereo mixes. It appears studios assume the listener has surround sound and give the stereo mix over to their intern.
The Netflix issue
When I first started watching Netflix I was disappointed that few shows offered surround sound. I have a strong suspicion this is due to licensing. I’m signed up in Germany, and this greatly reduces the selection I have on Netflix.
Worse, it appears to limit the language selection I have. German audio and subtitles are always available. Even German 5.1 is sometimes available even when English 5.1 is not. It’s a definite downgrade from renting DVDs which always have the proper English surround sound. The DVD player is connected with a coaxial digital cable to the same receiver.
The newer the show the more likely it was to offer surround. All Netflix exclusives offer it. But I was so used to shows not offering it that I didn’t really notice that the ones that did were still not playing in surround. They were coming across as 2-channel to my receiver.
What gives?
For whatever reason the LG TV has a default “Speaker” setting of “LG Sound System”. It sounds reasonable, but what it does it convert all surround sound to stereo. I had to switch this to “External Speaker”. The option makes no sense since the system only has external speakers.
I had a similar problem with the PS3. It apparently tries to detect audio support over the HDMI connection, but the TV won’t report anything useful. I had to go into the PS3 settings and choose an override, forcing it to believe one of the surround protocols was supported. It unfortunately never remembered this setting on reboot.
The Amazon issue
I previously wrote that the Amazon app on this TV is kind of crappy. While some things have improved the fundamental problems remain. If there is any blip in the internet connection it loses audio sync and never recovers. It frequently freezes while starting a show as well. And it never plays surround sound!
This is the type of nonsense I was hoping to avoid by getting a smart TV with an integrated app. I just never suspected Amazon would be shipping such a broken app with it.
In any case, they appear to have the same licensing problems as Netflix, some shows just don’t offer surround sound in English. Actually, very few shows appeared to offer surround. In the last year this appears to have changed, and at least the Amazon productions offer surround. But it never works. I always get stuck in stereo output.
The ugly part
It’s hard to get information on what format of audio is being used on Netflix or Amazon. It was only through forums and press releases that I found they support “Dolby Digital Plus”. On Netflix I could partially confirm this in their help section, but for Amazon I cannot find any official notice.
My searching also reveal that many people have a problem with Amazon not playing surround sound. At least I’m not alone.
My device supports Dobly Digital EX and Dolby Pro Logic IIx, Dolby Digital Plus is not in the list, but the newer Yamaha receivers also don’t list it; they only show “Dolby Digital”. Yet Netflix works.
According to Wikipedia, Dobly Digital Plus is a functional superset of Dolby Digital. Decoders are mandated (by the standard apparently) to be able to convert to the old format without doing any re-encoding. I presume this is just a repackaging of the bitstreams. I’m not sure what standard mandates this though, since the “Plus” spec came out after the “EX” devices were built. I’m also not sure where this downgrade happens, in the video app, on the TV, or on the receiver.
Even though Netflix works I didn’t assume my equipment was setup right. I tried many combinations of settings, but nothing seemed to help. I sure wish I was technically inclined enough to figure this out.
The stupid Amazon answer
While writing this I sent a support question off to Amazon. I got an answer quite quickly, but it only adds to the mystery. While they partially confirm a licensing issue, it’s the first line that’s dumbfounding:
Unsere Videos werden nur im Stereo Modus wiedergegeben. (Translated: Our videos are only played in stereo mode)
There’s no uncertainty here: there is no surround sound. If this is true it means the surround icons on the screen are just a lie. It would certainly explain why I wouldn’t get it working. But was my quest truly in vain, or has this support person just said something incorrect?
9 replies »
1. Thank you for sharing their reply. It is difficult even finding an email address for Amazon so I’m glad you relayed their message. I’m not sure if this site was up when you wrote this piece but it seems they say only virtual surround.
https://www.dolby.com/us/en/technologies/dolby-digital-plus/amazon-case-study.html
I am listening to a pair of surround sound Sony headphones using windows 10 hdmi out to an audio extractor because my display does not have optical out. It sounds fine for the money I paid for everything but the receiver for the headphones is supposed to light up when you are in surround sound to indicate such. Not sure if it is my headphone arrangement or Amazon streaming…
Anyhow… take care.
• I believe I might be getting surround now as well . I have all new equipment though (Nvidia shield TV and a new Pioneer receiver).
2. The lack of PC streaming support is annoying (to me, at least, since I use a media PC and don’t want to add another Fire Stick to the mix just to get 5.1). Netflix’s player does support 5.1 on a PC.
3. LG55C7 (one month old) + Yamaha RX663 with the same problem: at startup no surround (= no dialogue) in Netflix or Amazon, but YouTube is ok. After restart it works. What’s the problem here?
• Sound + Smart TVs + Receivers just seems like a voodoo combination. My newest TV plus receiver brand I had before also does weird things. if I clikc “Auto” it detects stereo, despite being surround. If I click surround it choose surround (I hope it’s choosing proper surround, and not an emulated one from stereo).
• +1 to mororay.
Just yesterday (Dec 2018), I watched an old, remastered episode of Star Trek TNG on Amazon Prime Video via our Roku Premier Plus to my Onkyo TX-NR515 AVR via HDMI v1.4 cables and got Dolby Digital Plus from the source (so 5.1 channels out to my delicious sounding Klipsch speakers). No sound processing; just straight decoding of the Dolby soundtrack from Amazon.
So the OP’s problems could be anywhere in the vodoo mix, meaning anything like:
a) content that isn’t encoded in surround formats
b) components or a configuration that isn’t compatible with the sound format (*)
c) downmixing the surround sound to stero (**)
I’ve heard some horrible”vodoo” setups. Like, why on Earth would someone Chromecast a show from their web browser to their Smart TV? There is a terribly inefficient way to watch content and some sleuthing geeks have found out that such setups end up transcoding the content, which is terrible. [0] Just because “it works” doesn’t mean it will be all that you want. Also, the OP said, “Yamaha RX-V457 receiver via optical cable”. Why optical? Is that Yamaha configured to do bitstream or decode? And this optical cable is connected to the LG TV on the other end?? What’s the end of it configured for input?
Get a good AVR and setup that can tell you _exactly_ what the source is giving you and supports all the formats that you expect to hear.
(*) yes you read that right. The original Roku boxes could only bitstream Dolby/ DTS, not decode it. Check your manufacturer’s documentation on supported formats. Even HDMI cables are not all the same, and I don’t mean gold plated versus silver ones but that older HDMI <1.4, for example, cannot handle the bandwidth of uncompressed Dolby TrueHD.
(**) this could be a mis-configuration anywhere in the "vodoo" setup: the Roku, the AVR, etc.
[0] https://www.xaprb.com/blog/spotify-audio-quality/
4. I have a Samsung smart TV,I just when to audio set up and change the speakers from tv to receiver using HDMI cables,now I can enjoy 5.1 from Amazon prime video
5. Could simply be an EDID problem. Your input devices read the default EDID of your TV (stereo) and send the appropriate signal. Either change the way you’ve set it up, e.g. from Device >TV>Receiver to Device>Receiver>TV or hack the service menu of your TV (using Anymote on a phone with an IR blaster) and change the TV’s ID to AC3 or DTS. Hope this helps.
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://mortoray.com/2017/05/08/why-does-amazon-taunt-me-with-surround-sound/",
"source_domain": "mortoray.com",
"snapshot_id": "crawl=CC-MAIN-2019-04",
"warc_metadata": {
"Content-Length": "135190",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:GSCDL5P7O2AB4DR3NIM5CMYWX7KS2OFJ",
"WARC-Concurrent-To": "<urn:uuid:7d0ea6fd-8dca-4af6-85dd-de1199b53f58>",
"WARC-Date": "2019-01-16T11:21:31Z",
"WARC-IP-Address": "192.0.78.25",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:OLGKYA3OSHEY5GCGGAGFTTVP47XRZL5M",
"WARC-Record-ID": "<urn:uuid:462a9981-7d67-41db-8312-aae0a1c2a4b4>",
"WARC-Target-URI": "https://mortoray.com/2017/05/08/why-does-amazon-taunt-me-with-surround-sound/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:e70450a1-eaea-4749-81ef-60a57be92cec>"
},
"warc_info": "isPartOf: CC-MAIN-2019-04\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for January 2019\r\noperator: Common Crawl Admin (info@commoncrawl.org)\r\nhostname: ip-10-101-220-24.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,
8,
9,
55,
56,
347,
348,
424,
425,
438,
439,
808,
809,
1168,
1169,
1472,
1473,
1491,
1492,
1724,
1725,
2077,
2078,
2355,
2356,
2368,
2369,
2648,
2649,
2981,
2982,
2999,
3000,
3310,
3311,
3483,
3484,
3821,
3822,
3836,
3837,
4135,
4136,
4257,
4258,
4460,
4461,
4937,
4938,
5143,
5144,
5169,
5170,
5383,
5384,
5496,
5497,
5776,
5777,
5789,
5790,
6030,
6031,
6118,
6119,
6500,
6501,
6524,
6525,
6662,
6663,
6867,
6868,
7063,
7064,
7385,
7386,
7407,
7408,
7778,
7779,
7865,
7866,
7922,
8009,
8062,
8063,
8675,
8676,
8819,
8820,
9173,
9273,
9333,
9334,
9499,
9500,
9861,
9862,
9876,
9877,
9932,
9933,
9952,
9953,
10026,
10027,
10041,
10042,
10109,
10110,
10126,
10127,
10194,
10195,
10210,
10211,
10279,
10280
],
"line_end_idx": [
8,
9,
55,
56,
347,
348,
424,
425,
438,
439,
808,
809,
1168,
1169,
1472,
1473,
1491,
1492,
1724,
1725,
2077,
2078,
2355,
2356,
2368,
2369,
2648,
2649,
2981,
2982,
2999,
3000,
3310,
3311,
3483,
3484,
3821,
3822,
3836,
3837,
4135,
4136,
4257,
4258,
4460,
4461,
4937,
4938,
5143,
5144,
5169,
5170,
5383,
5384,
5496,
5497,
5776,
5777,
5789,
5790,
6030,
6031,
6118,
6119,
6500,
6501,
6524,
6525,
6662,
6663,
6867,
6868,
7063,
7064,
7385,
7386,
7407,
7408,
7778,
7779,
7865,
7866,
7922,
8009,
8062,
8063,
8675,
8676,
8819,
8820,
9173,
9273,
9333,
9334,
9499,
9500,
9861,
9862,
9876,
9877,
9932,
9933,
9952,
9953,
10026,
10027,
10041,
10042,
10109,
10110,
10126,
10127,
10194,
10195,
10210,
10211,
10279,
10280,
10296
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 10296,
"ccnet_original_nlines": 118,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.40257352590560913,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0546875,
"rps_doc_frac_lines_end_with_ellipsis": 0.008403359912335873,
"rps_doc_frac_no_alph_words": 0.1672794073820114,
"rps_doc_frac_unique_words": 0.3671388030052185,
"rps_doc_mean_word_length": 4.5694050788879395,
"rps_doc_num_sentences": 138,
"rps_doc_symbol_to_word_ratio": 0.0013786799972876906,
"rps_doc_unigram_entropy": 5.7020673751831055,
"rps_doc_word_count": 1765,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.013639179989695549,
"rps_doc_frac_chars_dupe_6grams": 0.007439550012350082,
"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.01934283971786499,
"rps_doc_frac_chars_top_3gram": 0.007935520261526108,
"rps_doc_frac_chars_top_4gram": 0.010415379889309406,
"rps_doc_books_importance": -913.3441162109375,
"rps_doc_books_importance_length_correction": -913.3441162109375,
"rps_doc_openwebtext_importance": -605.67822265625,
"rps_doc_openwebtext_importance_length_correction": -605.67822265625,
"rps_doc_wikipedia_importance": -338.6423645019531,
"rps_doc_wikipedia_importance_length_correction": -338.6423645019531
},
"fasttext": {
"dclm": 0.022444840520620346,
"english": 0.9446867108345032,
"fineweb_edu_approx": 1.0296030044555664,
"eai_general_math": 0.01313066016882658,
"eai_open_web_math": 0.16825765371322632,
"eai_web_code": 0.002343239961192012
}
}
|
{
"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": "780.285",
"labels": {
"level_1": "Arts",
"level_2": "Music",
"level_3": ""
}
}
},
"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": "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": "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
|
6,399,055,071,230,554,000
|
Restrict Application Creation
Configure Fiat, the Spinnaker microservice responsible for authorization (authz), to control which users can create applications by using the prefix parameter.
Requirements and guidelines for using Fiat
• Armory 2.17 (Open Source SpinnakerTM 1.17) or later
• Fiat must be enabled and configured to work with an identity provider. For more information, see Authorization (RBAC).
When managing roles for Spinnaker, keep the following in mind:
• Roles are case insensitive. All roles are changed to lowercase in Fiat’s internal model.
• You must explicitly configure permissions for each user role. The default for a user role is no permissions, which means it cannot perform any actions.
Restrict application creation
To restrict which users can create applications in Spinnaker, perform the following steps:
1. Add the line auth.permissions.provider.application: aggregate to SpinnakerService manifest under key spec.spinnakerConfig.profiles.fiat.
2. Add prefixes as a source:
auth.permissions.source.application.prefix:
enabled: true
3. Define the permissions for a prefix:
- prefix: <some_prefix>
permissions:
READ:
- "<user role 1>"
- "<user role 2>"
- "<user role n>"
WRITE:
- "<user role n>"
EXECUTE:
- "user role n>"
Here is an example configuration with in-line comments:
apiVersion: spinnaker.armory.io/v1alpha2
kind: SpinnakerService
metadata:
name: spinnaker
spec:
spinnakerConfig:
profiles:
fiat:
# Enables Fiat to read from new sources.
auth.permissions.provider.application: aggregate
# Sets `prefix` as one of these new sources
auth.permissions.source.application.prefix:
enabled: true
prefixes:
# Defines the prefix `apptest-x`.
- prefix: "apptest-*"
permissions:
# Defines permission requirements for all applications that match the prefix `apptest-*` based on roles.
# role-one and role-two have READ permission
READ:
- "role-one"
- "role-two"
# role-one has write permission
WRITE:
- "role-one"
# role-one has execute permission
EXECUTE:
- "role-one"
As a result, any application that matches the prefix apptest-* has restrictions on who can perform actions. For example, a user with the user role role-two only has READ permission.
4. To restrict application creation specifically, add fiat.restrictApplicationCreation at the top of fiat config and set it to true.
Note: Currently, the prefix source is the only source that support the CREATE permission.
The following example builds upon the example from the previous steps. In-line comments describe additions:
apiVersion: spinnaker.armory.io/v1alpha2
kind: SpinnakerService
metadata:
name: spinnaker
spec:
spinnakerConfig:
profiles:
fiat:
# Add CREATE as a permission
fiat.restrictApplicationCreation: true
auth.permissions.provider.application: aggregate
auth.permissions.source.application.prefix:
enabled: true
prefixes:
- prefix: "*"
permissions:
# Assign CREATE permission to role-one
CREATE:
- "role-one"
READ:
- "role-one"
- "role-two"
WRITE:
- "role-one"
EXECUTE:
- "role-one"
The above example assigns CREATE permission to users with the role-one role. Users without the role-one role cannot create any applications in Spinnaker.
5. Apply your configuration changes to Spinnaker by running the following command: kubectl -n <spinnaker namespace> apply -f <SpinnakerService manifest>.
The following screenshot shows what happens when a user without sufficient permissions attempts to create an application in Deck, Spinnaker’s UI: No CREATE Permission
Last modified July 20, 2022: (83f09a7)
|
{
"url": "https://docs.armory.io/armory-enterprise/armory-admin/fiat-create-permissions/",
"source_domain": "docs.armory.io",
"snapshot_id": "crawl=CC-MAIN-2022-40",
"warc_metadata": {
"Content-Length": "190931",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:IILCABW6QV7UW755Z3RCUSNYK75VI7XK",
"WARC-Concurrent-To": "<urn:uuid:70166e60-1871-47e7-b7cd-677a62e0e1f4>",
"WARC-Date": "2022-09-28T13:08:16Z",
"WARC-IP-Address": "35.229.48.116",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:3A3EUOIZC7SNC6YTP7GOPEFUHRP6IMAS",
"WARC-Record-ID": "<urn:uuid:13d4eca9-2861-415b-81bb-e11d2b0b71af>",
"WARC-Target-URI": "https://docs.armory.io/armory-enterprise/armory-admin/fiat-create-permissions/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ce6c3b8e-a4bb-4bd8-b4f0-ff67787bb769>"
},
"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-62\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,
30,
31,
191,
192,
235,
236,
292,
415,
416,
479,
480,
573,
729,
730,
760,
761,
852,
853,
995,
996,
1027,
1028,
1076,
1096,
1101,
1143,
1144,
1172,
1191,
1204,
1229,
1254,
1279,
1293,
1318,
1334,
1358,
1363,
1364,
1424,
1425,
1470,
1497,
1511,
1533,
1543,
1568,
1586,
1602,
1655,
1716,
1772,
1828,
1856,
1880,
1930,
1966,
1995,
2118,
2181,
2205,
2236,
2267,
2317,
2342,
2373,
2425,
2452,
2483,
2488,
2489,
2675,
2676,
2811,
2812,
2906,
2907,
3019,
3020,
3065,
3092,
3106,
3128,
3138,
3163,
3181,
3197,
3238,
3289,
3350,
3406,
3434,
3458,
3486,
3515,
3572,
3598,
3629,
3653,
3684,
3715,
3740,
3771,
3798,
3829,
3834,
3835,
3993,
3994,
4150,
4151,
4318,
4319,
4320
],
"line_end_idx": [
30,
31,
191,
192,
235,
236,
292,
415,
416,
479,
480,
573,
729,
730,
760,
761,
852,
853,
995,
996,
1027,
1028,
1076,
1096,
1101,
1143,
1144,
1172,
1191,
1204,
1229,
1254,
1279,
1293,
1318,
1334,
1358,
1363,
1364,
1424,
1425,
1470,
1497,
1511,
1533,
1543,
1568,
1586,
1602,
1655,
1716,
1772,
1828,
1856,
1880,
1930,
1966,
1995,
2118,
2181,
2205,
2236,
2267,
2317,
2342,
2373,
2425,
2452,
2483,
2488,
2489,
2675,
2676,
2811,
2812,
2906,
2907,
3019,
3020,
3065,
3092,
3106,
3128,
3138,
3163,
3181,
3197,
3238,
3289,
3350,
3406,
3434,
3458,
3486,
3515,
3572,
3598,
3629,
3653,
3684,
3715,
3740,
3771,
3798,
3829,
3834,
3835,
3993,
3994,
4150,
4151,
4318,
4319,
4320,
4358
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4358,
"ccnet_original_nlines": 114,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.22758620977401733,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02620689943432808,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.32965517044067383,
"rps_doc_frac_unique_words": 0.41163310408592224,
"rps_doc_mean_word_length": 6.230424880981445,
"rps_doc_num_sentences": 57,
"rps_doc_symbol_to_word_ratio": 0.012413790449500084,
"rps_doc_unigram_entropy": 4.83082914352417,
"rps_doc_word_count": 447,
"rps_doc_frac_chars_dupe_10grams": 0.07684022188186646,
"rps_doc_frac_chars_dupe_5grams": 0.09910233318805695,
"rps_doc_frac_chars_dupe_6grams": 0.07684022188186646,
"rps_doc_frac_chars_dupe_7grams": 0.07684022188186646,
"rps_doc_frac_chars_dupe_8grams": 0.07684022188186646,
"rps_doc_frac_chars_dupe_9grams": 0.07684022188186646,
"rps_doc_frac_chars_top_2gram": 0.022980250418186188,
"rps_doc_frac_chars_top_3gram": 0.029084380716085434,
"rps_doc_frac_chars_top_4gram": 0.013644520193338394,
"rps_doc_books_importance": -312.40399169921875,
"rps_doc_books_importance_length_correction": -312.40399169921875,
"rps_doc_openwebtext_importance": -214.5820770263672,
"rps_doc_openwebtext_importance_length_correction": -214.5820770263672,
"rps_doc_wikipedia_importance": -134.47544860839844,
"rps_doc_wikipedia_importance_length_correction": -134.47544860839844
},
"fasttext": {
"dclm": 0.09837151318788528,
"english": 0.7103393077850342,
"fineweb_edu_approx": 2.058394193649292,
"eai_general_math": 0.545604944229126,
"eai_open_web_math": 0.1208156868815422,
"eai_web_code": 0.831900417804718
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.452",
"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": "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
|
-3,406,193,298,075,407,000
|
Traduções desta página:
Ferramentas do usuário
Ferramentas do site
02_tutoriais:tutorial3:start
3. Tutoriais de Leitura e Manipulação de dados no R
Os 10 mandamentos do R Agora que já tem alguma experiência com a linguagem, veja os 10 mandamentos do R! Ao final do curso revisite esses mandamentos e avalie quantos pecados deve confessar.
Objetos de Dados
Vetores como estrutura básica de dados
Nos tutoriais anteriores, nós usamos uma classe de objetos que é a estrutura básica de armazenamento de dados no R, a classe de objetos vetores. Vamos revisitar alguns conceitos neste tópico, criando um vetor de dados numéricos, chamado num, que seja uma sequência de valores de 0 a 15 divididos em 7 valores equidistantes.
| Criando Vetor
num <- seq(0, 15, len=7)
Agora vamos olhar os valores do objeto criado, em seguida elevar cada valor ao quadrado, atribuindo o resultado ao objeto “num2”. Em seguida tire a raiz-quadrada desse vetor.
Operando vetor
num
length(num)
class(num)
num2 <- num^2
num2
sqrt(num2)
num
Agora vamos extrair apenas o quinto elemento e em seguida substituir esse elemento pela palavra “quinto_elemento”. Em seguida vamos repetir as operações anteriores:
Quinto elemento
num[5]
num[5] <- "quinto_elemento"
num
num[-5]
length(num)
class(num)
num^2
sqrt(num^2)
O que aconteceu aqui? Por que não conseguimos mais operar o vetor num? Vamos agora voltar o vetor para sua forma original e operar novamente:
Retorno do elemento
num[5] <- 10
num
num^2
sqrt(num^2)
Por que ainda não conseguimos? Vamos investigar o vetor e ajustá-lo.
| Classe do vetor
length(num)
class(num)
num <- as.numeric(num)
sqrt(num^2)
Como já havíamos visto, uma das característica do vetor é que só armazena um tipo de natureza de dados e o R faz a coerção da classe do objeto dependendo da característica desses dados. Incluir algo que não é dígito ou símbolo de decimal em um objeto da classe numérica faz com que a classe seja convertida automaticamente em character.
A raiz de um valor elevado ao quadrado é o próprio valor? O que aconteceria se o vetor fosse de números negativos? Veja a discussão sobre função quadrática e raiz quadrada como funções inversas nesse link
Leitura de Dados
A principal função para a leitura de dados no R é read.table. Ela é bem flexível e se aplica para a leitura de dados tabulares como uma planilha eletrônica usual, tendo colunas como variáveis e as linhas como observações. Esta estrutura é análoga a um conjunto de vetores lado a lado, de mesmo comprimento, como veremos a seguir. Antes da leitura de dados é importante garantir que temos eles bem organizados em uma planilha. O artigo Data Organization in Spreedsheets (Broman & Woo, 2018) faz uma ótima síntese de boas práticas para estruturar dados brutos em uma planilha, sua leitura é rápida e irá poupar muito tempo futuro e evitar muitos erros comuns que usuários de planilhas cometem. Os exemplos de erros comuns em planilhas de ecologia do datacarpentry são também muito bons, uma forma interessante de aprender é ser exposto ao que não devemos fazer.
Tendo a planilha eletrônica com os dados brutos bem estruturados, precisamos exportá-la como arquivo texto puro para fazer a leitura no R. Os arquivos de texto são uma forma eficiente de armazenar dados que tem uma estrutura simples de linhas e colunas. Além de poderem ser abertos em qualquer programa simples de texto e sistema operacional, são reconhecidos nas planilhas eletrônicas como estrutura de dados. Normalmente, utilizamos as extensões .txt ou .csv para designar arquivos texto com campos de dados separados por tabulação e vírgula, respectivamente1).
Ao exportar os dados deve ficar atento para algumas opções de exportação da planilha, as principais são os caracteres para designar a separação de campo e o símbolo de decimal. Evite, sempre que possível, caracteres especiais como acentos e aspas ( ' , `, ), se houver a opção de escolher a codificação de caracteres (“enconding”) opte pelo UTF-8.
Sabendo o formato que os dados foram salvos no arquivo texto, na maioria dos casos, precisamos apenas do seguintes argumentos para fazer a leitura dos dados no R 2):
Principais argumentos do read.table
Argumento Descrição Padrão Alternativas
file nome do arquivo 3)
"nome_arquivo.txt"
"/caminho_dir/nome_arquivo.txt"
header nome das variáveis 4)
FALSE
TRUE
sep separador 5)
" "
"," ";" "\t"
dec símbolo de decimal
"."
","
as.is mantenha caracteres 6)
TRUE
FALSE
Verificando a leitura
Logo após a leitura dos dados é recomendável fazer a verificação do objeto lido para ter certificar que os dados foram lidos corretamente. É possível retornar na tela todo o objeto criado, mas para conjunto de dados grandes, fica difícil a visualização. Para isso, usamos algumas funções acessórias que extraem atributos ou parte dos dados. As principais são:
• str: faz uma síntese da estrutura do objeto;
• dim: mostra as dimensões do objeto, primeiro o número de linhas (observações) e em seguida colunas (variáveis);
• head: mostra as primeiras linhas, por padrão as primeiras 6 observações;
• names: mostra o nome das variáveis (colunas).
Dados de Caixeta
Entre na página levantamento de espécies em caixetais, leia a descrição dos dados e das variáveis e salve o arquivo de dados no diretório de trabalho.
Obs.: Se o arquivo abrir em uma aba do navegador, clique com o botão direito do mouse no link e selecione “salvar link”.
Vamos fazer a leitura do arquivo com o padrão de leitura da função read.table e verificar em seguida a classe e a formatação do arquivo:
caixeta
caixeta <- read.table(file = "caixeta.csv")
Esse código retornar o erro:
Lendo caixeta?
Error in scan(file = file, what = what, sep = sep, quote = quote, dec = dec, :
line 5 did not have 3 elements
Indicando que tentou ler o arquivo, mas algumas linhas tinham dimensões diferentes, ou seja, o formato não era tabular. Isso ocorre, normalmente, devido ao tipo de separador de campo utilizado no arquivo que não é espaço, o padrão da função. No caso, o separador é , como relatado na documentação dos dados. Vamos usar o argumento sep para indicar o separador. Em seguida vamos verificar a classe do objeto.
Relendo caixeta
caixeta <- read.table(file = "caixeta.csv", sep = ",")
class(caixeta)
Leitura de dados Online
A função read.table também funciona com endereço web como caminho para leitura de arquivos. Só precisamos fornecer a url do arquivo. No nosso caso, como os dados estão no nosso wiki, podemos usar:
Caixeta url
caixeta <- read.table(file = "http://ecor.ib.usp.br/lib/exe/fetch.php?media=dados:caixeta.csv", sep = ",")
Data Frames
A classe do objeto é um data.frame. Esse é o segundo tipo de objeto para armazenar dados no R que apresentamos: o vetor tem apenas uma dimensão de dados, o data.frame tem duas. Os datas frames no R são conjuntos de vetores de mesmo tamanho, similares a uma planilha de dados. Todas as características que vimos do objeto vetor, valem para as colunas do data.frame. Uma outra forma de pensar o data frame é que são variáveis (colunas) de um conjunto de observações (linhas). Assim como deve ser uma planilha de dados bem estruturada.
Vamos insistir em uma sugestão importante, que evita muitos transtornos para quem está iniciando no R é: depois de efetuar a leitura sempre verificar a estrutura dos dados antes de iniciar as análises, usando as funções indicadas acima.
Verifica caixesta
dim(caixeta)
names(caixeta)
str(caixeta)
head(caixeta)
Apesar do objeto ter sido lido, ele não parece o que deveria. A dimensão do objeto mostra que tem uma observação a mais, os nomes das variáveis não corresponde ao que está definido no metadado e as variáveis foram todas lidas com characters ou factor dependendo da versão do R. O head mostra exatamente o que aconteceu: a linha com os nomes das variáveis foi lida como sendo uma observação. Com isso, todas as variáveis foram classificadas como caracteres. Vamos agora usar o argumento header e fazer novamente a verificação:
Caixeta header
caixeta <- read.table(file = "caixeta.csv", sep = ",", header = TRUE)
dim(caixeta)
names(caixeta)
str(caixeta)
head(caixeta)
No código acima temos resultados que podem variar dependendo da versão do R. Isso não é muito comum, pois a equipe de desenvolvedores busca manter a compatibilidade dos scripts entre versões.
stringsAsFactors
Por padrão, até a versão anterior a 4.0.0 de abril de 2020, o padrão das funções read.table e data.frame era classificar as variáveis com caracteres como sendo um fator. Isso era definido com os padrões dos argumentos stringsAsFactors = TRUE ou as.is = FALSE. Desde da versão 4.0.0 o padrão é classificar as variáveis que contém caracteres como sendo character. O que acontece é que a partir dessa versão o padrão para as.is = !stringAsFactor e a função read.table incorporou o argumento stringAsFactors = TRUE. Ou seja, por padrão o stringAsFactor diz para a função transformar caracteres em fator, mas é sobreposto pelo argumento as.is que inverte o valor lógico com !. Essa conversão automática para fator é um legado da linguagem S7).
Incluir Variáveis
Vamos então transformar as variáveis local e especie para fator, assim independente da versão do R instalada, estaremos todos com a mesma estrutura de objeto.
Fatores caixeta
caixeta$local <- factor(caixeta$local)
caixeta$ssp <- factor(caixeta$especie)
str(caixeta)
Percebam que na primeira linha de comando estamos sobrescrevendo a variável local como fator para a mesma coluna. No caso da conversão de especie em fator, criamos uma nova variável no nosso data.frame chamada spp, um fator, e preservamos a variável especie que continua como caracteres.
Incluir Variáveis no data.frame
Para incluir novas variáveis no data.frame só é preciso fornecer os valores e indicar a coluna onde esses valores devem ser atribuídos, tomando o cuidado de indicar um nome diferente das variável existentes caso não queira sobrescrever. O vetor da nova variável deve ter o mesmo tamanho do número de linhas do data.frame. A regra de ciclagem vale aqui também, veja o que acontece com o código:
Ciclando NA
caixeta$dap <- NA
str(caixeta)
No quadro acima criamos uma variável chamada dap que contém só NAs (not available). Vamos incluir agora, nessa coluna, os valores de diâmetro à altura do peito. Para isso, vamos usar o valor de cap (circunferência à altura do peito) e a relação:
$$ dap = \frac{cap}{pi} $$
Cap para dap
caixeta$dap <- caixeta$cap/pi
str(caixeta)
Aqui também temos a regra da ciclagem com o valor da constante pi sendo ciclado para operar todos os elementos da variável cap.
Indexação
Acima usamos a indexação da coluna do data.frame pelo nome da variável, usando o operador $. Veja o que temos ao pedir a estrutura de uma variável do data.frame
Estrutura da variável
str(caixeta$especie)
str(caixeta$cap)
O que temos é a estrutura básica de armazenamento de dados: vetores das classes básicas de dado. Portanto, para indexar as posições nesse vetores, podemos usar a indexação básica de vetores:
Indexando posição
caixeta$dap[1]
caixeta$dap[c(1, 3, 5, 7, 9)]
caixeta$dap[seq(1, 19, by= 2)]
Uma outra forma de indexar é pelas posições da linha e coluna. No caso do data.frame isso é feito pela indicação das duas posições separadas por vírgula entre colchetes [ , ]. Sempre o valor antes da vírgula se refere a primeira dimensão do data.frame que são as linhas (observações) e o valor depois refere-se a coluna (variável).
Indexando duas dimensões
caixeta[1, 9]
caixeta[c(1, 3, 5, 7, 9), 9]
caixeta[seq(1, 19, by= 2), 9]
Por fim, é possível também combinar nomes das variáveis com as posições das observações:
Indexando por nome
caixeta[1, "dap"]
caixeta[c(1, 3, 5, 7, 9), "dap"]
caixeta[seq(1, 19, by= 2), "dap"]
Inclusive, combinar nomes de variáveis:
Indexando duas variáveis
caixeta[1, c("dap", "cap")]
caixeta[c(1, 3, 5, 7, 9), c("dap", "cap")]
caixeta[seq(1, 19, by= 2), c("dap", "cap")]
Indexação com Lógica
Para apresentar essa última forma de indexação, vamos construir um data.frame sem fazer a leitura, usando a função data.frame que recebe os vetores de dados de mesmo tamanho.
Os trapalhões
trapalhoes <- data.frame(nomes = c("Didi","Dedé","Mussum","Zacarias"), ano.nasc = c(1936, 1936, 1941, 1934), vive = c("V", "V", "F", "F"))
Vamos agora calcular a idade dos meninos:
Operando variáveis
ano.atual <- as.numeric(format(Sys.Date(), "%Y"))
ano.atual - trapalhoes$ano.nasc
trapalhoes$idade <- ano.atual - trapalhoes$ano.nasc
Tá bom! Vou explicar a primeira linha de comando, ao mesmo tempo, indicar o caminho para entender comandos mais complicados em geral. Primeiro temos a característica da sintaxe aninhada, padrão do R. Para entender o que está sendo feito, pegue a função mais interna e veja o que ela está retornando, em seguida veja o que função externa a ela está fazendo com esse resultado, e assim por diante!
Dilacerando o código
Sys.Date()
format(Sys.Date(), "%Y")
as.numeric(format(Sys.Date(), "%Y"))
Por que?
Pois bem, estamos primeiro pegando a data atual armazenada no computador, depois pegando apenas o ano e em seguida transformando o ano em número. Ué? Não seria mais fácil digitar o ano diretamente? Sim, mas depois teria que atualizar o código todos os anos antes do curso!
porquesim.gif
Para extrair informações específicas do data.frame usamos a indexação com um vetor lógico. Por exemplo, podemos nos perguntar: Quais os nomes dos trapalhões que nasceram antes de 1940?
Operação lógica
antes40 <- trapalhoes$ano.nasc < 1940
antes40
O resultado desse teste lógico é um vetor de TRUE e FALSE:
[1] TRUE TRUE FALSE TRUE
Ele nos diz que a condição é verdadeira para todas as posições menos para a terceira. Como o vetor lógico tem o mesmo comprimento do número de linhas, podemos então indexar o nosso data.frame com esse vetor, da seguinte forma:
Indexação com lógica
trapalhoes[antes40, ]
ou diretamente, sem o objeto intermediário:
Indexação com operação lógica
trapalhoes[trapalhoes$ano.nasc < 1940, ]
Note que fizemos a indexação pelas linhas, deixando a indexação da coluna vazia, ou seja, solicitando retornar todas as colunas para as linhas em que o vetor antes40 é TRUE. Como data.frame tem duas dimensões, a vírgula é mandatória para a indexação.
Nossa pergunta foi mais específica, perguntamos o nome e não pedimos as outras informações:
Indexando ambas dimensões
trapalhoes[antes40, "nomes" ]
Nesse caso, a indexação da coluna pode ser feita pelo nome da variável ou pela posição e também pode ser combinada.
E se quisermos o inverso, o nome e a idade dos que nasceram depois de 1940? Precisamos só inverter o vetor de TRUE e FALSE usando o operador !:
Invertendo a lógica
trapalhoes[!antes40, c("nomes","idade") ]
Essas são as principais instrumentações de indexação no R. Aplicadas em um data.frame com quatro observações não parece muito vantajoso. Vamos nos perguntar algo então para os dados das caixeta que tem mais de mil observações:
Quais árvores, na amostra da Juréia, tem mais de 100 mm de dap?
Combinando lógica
jureiaVF <- caixeta$local == "jureia"
bigtree <- caixeta$dap > 100
caixeta[jureiaVF & bigtree, ]
Aqui utilizamos o operador lógico & para perguntar para o R quais posições de jureiaVF e bigtree são verdadeiras em ambos os vetores.
E para saber quantas árvores tem na amostra da Juréia, quantas dessas são grandes e em que proporção? Lembra que o TRUE é operado algebricamente como sendo o valor 1?
Opera lógica
sum(jureiaVF)
sum(bigtree & jureiaVF)
sum(bigtree & jureiaVF)/sum(jureiaVF)
Salvando Data Frame
Após manipular os dados no R podemos salvar uma nova versão em um arquivo texto. Para salvar a nossa nova versão dos dados de caixetais, que incorpora o dap, usamos a função write.table. Os parâmetros são parecidos com a função de leitura, só que precisamos indicar qual o objeto a ser salvo e nome do arquivo no qual ele será gravado. Caso queira salvar em um local diferente do diretório de trabalho deve também fornecer o caminho das pastas do computador. Abaixo estamos salvando os dados no arquivo caixeta.txt, com os campos separados por tabulação (\t) e indicando que não queremos salvar nomes de linhas8) (row.names= FALSE)
Salvando arquivos de dados
write.table(caixeta, file = "dados/caixeta.txt", sep = "\t", dec = ",", row.names = FALSE)
Caso receba a mensagem de erro:
Error in file(file, ifelse(append, "a", "w")) :
cannot open the connection
In addition: Warning message:
In file(file, ifelse(append, "a", "w")) :
cannot open file 'dados/caixeta.txt': No such file or directory
Significa que o caminho para gravar o arquivo tem algum problema, no caso não há a pasta dados subordinada ao seu diretório de trabalho. Para criar uma pasta pelo R, use o comando abaixo:
Criando pastas
dir.create("dados")
dir.exists("dados")
dir()
Agora podemos rodar novamente a linha de comando do write.table e gravar o nosso arquivo caixeta.txt no diretório dados, subordinado ao diretório de trabalho que a sessão do R está associado.
Formato de Arquivo de Dados
Arquivos de dados no formato de texto são uma forma segura de salvar conjunto de dados pequenos ou medianos ( ~100 mil registros). Os formatos mais usados são os com campo separados por espaço (padrão do read.table), separados por vírgula ou ponto e vírgula, normalmente com extensão .csv, ou tabulação, normalmente com extensão .txt. A extensão é apenas uma indicação de formato e como é possível salvar o arquivo com qualquer extensão, precisamos saber qual estrutura foi utilizada para salvar os dados. O excel em sistemas operacionais em português salva arquivos csv separados por ;, com símbolo de decimal ,, o que causa bastante confusão. Nossa sugestão é que configure seu computador para decimal com . e estabeleça o seu padrão de separação de campo, deixando indicado em um arquivo acessório de metadados. Antes de ler um arquivo de dados de texto que desconheça a formatação, abra em um arquivo de edição de texto simples, como o bloco de notas, para verificar os símbolos de separação de campo e decimal.
Matrix e Array
Matrizes
Outro tipo de objeto no R com estrutura tabular é a matrix, que está associado à álgebra linear. A principal diferença com data.frame é que matrix só aceita uma classe de dados, assim como vector. A matrix é usada no sentido de matrizes da álgebra linear e operações matriciais.
Vamos aprender o objeto matrix associada ao estudo de dinâmica populacional.
Operações Matriciais
matrizestruturada.jpegAs matrizes de transição são uma maneira conveniente de modelar o crescimento de uma população dividida em faixas etárias, ou estágios de desenvolvimento 9). Uma forma de representar essas populações estruturadas10) é com diagramas mostrando as transições e permanências entre estados.
Uma forma compacta de representar matematicamente essas transições e permanência é utilizando a forma de matriz, que nesse caso se chama matriz de transição, como na figura abaixo: matrizestruturada1.jpeg
Uma população de Escobaria robbinsiorum (Cactaceae) no deserto do Arizona, com três estágios de desenvolvimento, tinha a seguinte a matriz de transição:
Escobaria robbinsiorum escRobbins.jpg
0,43 0 0,56
0,33 0,61 0
0 0,30 0,96
Os elementos da matriz, com exceção da fecundidade (F2 e F3 no diagrama), são as probabilidades de transição, num intervalo de tempo, do estágio correspondente ao número da coluna para o estágio correspondente ao número da linha. Por exemplo, a chance de um indivíduo passar do estágio 1 (plântula) para o 2 (jovem) é 0,33, e de permanecer em 1 é de 0,43. A fecundidade, representada nessa matriz como o elemento da primeira linha e terceira coluna (0,56) é o único que não é uma probabilidade e representa a contribuição, em número de jovens do estágio 1, que um adulto produz em média a cada ciclo.
Vamos criar um objeto da classe matriz com esses valores. Isso nos permitirá realizar operações matriciais para prever o tamanho da população.
Criando matriz
matCory <- matrix( c(0.43, 0.33, 0, 0, 0.61, 0.3, 0.52, 0, 0.96), nrow = 3, ncol = 3)
matCory
A indexação da matrix é similar ao data.frame quando usamos o [. A indexação utilizando $ não se aplica nesse caso. Por exemplo, a fecundidade foi digitada errada no código acima e precisamos ajustá-la:
Indexando matriz
matCory[1, 3]
matCory[1, 3] <- 0.56
matCory
Aqui estamos usando uma regra básica dos objetos de dados no R: se consegue extrair um elemento de um objeto é possível atribuir algo a essa posição.
Agora crie um vetor com as abundâncias iniciais de indivíduos em cada classe. Vamos começar com uma população de 50 plântulas , 25 jovens e 10 adultos.
Vetor de tamanho populacional
popN0 <- c(50, 25, 10)
popN0
Para calcular o número de indivíduos em cada estágio após um intervalo de tempo, basta multiplicar a matriz de transição pelas abundâncias dos indivíduos em cada estágio. Usamos o operador de multiplicação matricial %*% para isso. Qual será o número de plantas em cada estágio após três intervalos?
Multiplicação matricial
popN1 <- matCory %*% popN0
popN1
popN2 <- matCory %*% popN1
popN2
popN3 <- matCory %*% popN2
popN3
Vamos agora armazenar a trajetória do tamanho dos estágios na população em uma matrix:
Matriz de tamanho populacional
pop <- matrix(c(popN0, popN1, popN2, popN3), ncol = 3, byrow = TRUE)
colnames(pop) <- c("plântula", "jovem", "adulto")
pop
O que acontece aqui?
pop <- rbind(pop, t(matCory %*% pop[nrow(pop),]))
No código acima, fazemos a multiplicação matricial %*% de duas matrizes: matCory e a última linha do objeto pop. Em seguida transpomos11) a matriz resultante com a função t para depois combinar o resultado transposto com o objeto pop. Para isso, usamos a função rbind que combina as linhas de dois objetos tabulares. Por último, sobrescrevemos o objeto pop com essa nova combinação.
Veja como funciona o código acima executando cada passo separadamente, do mais interno para o mais externo:
Entendendo o código
nrow(pop)
pop[nrow(pop),]
matCory %*% pop[nrow(pop),]
t(matCory %*% pop[nrow(pop),])
rbind(pop, t(matCory %*% pop[nrow(pop),]))
Podemos fazer mais algumas multiplicações, guardando o resultado diretamente no objeto pop, usando somente a mesma linha de comando novamente.
Repetição
pop <- rbind(pop, t(matCory %*% pop[nrow(pop),]))
pop <- rbind(pop, t(matCory %*% pop[nrow(pop),]))
pop <- rbind(pop, t(matCory %*% pop[nrow(pop),]))
pop <- rbind(pop, t(matCory %*% pop[nrow(pop),]))
pop <- rbind(pop, t(matCory %*% pop[nrow(pop),]))
## ...
Vamos agora nomear essas linhas usando a função paste que combina caracteres.
Nomeando linhas
rownames(pop) <- paste("t", seq(from = 0, to = (nrow(pop) - 1)), sep = "")
A função paste junta caracteres de dois vetores com os princípios da equivalência de posição e ciclagem, próprios das operações com vetores. Caso não tenha entendido o código acima, faça a separação de cada passo e veja a documentação das funções. Esse é um procedimento básico para entender códigos quando estamos iniciando no aprendizado de uma linguagem computacional.
Por fim, vamos olhar esses dados em um gráfico no objeto pop . O código abaixo vai ser abordado na aula de gráficos, por enquanto apenas copie e execute o código no R:
Grafico de matriz
matplot(x = 0:(nrow(pop)-1), pop, type = "l", xlab = "Tempo", ylab = "Número de indivíduos", lty = 2, lwd = 2, col = c("red", "blue", "green"), cex.lab = 1.2, cex.axis = 1.2, las = 1)
legend("topleft", legend = colnames(pop), bty = "n", lty = 1, col = c("red", "blue", "green"))
Modelos Matriciais de Dinâmica Populacional
Com um pouco mais de álgebra linear você pode obter muito mais informações sobre características da população biológica, apenas a partir das informações intrínsecas da matriz de transição (autovalores e autovetores). Por exemplo, a taxa de crescimento (λ) da população é o primeiro autovalor da matriz de transição, enquanto que o valor reprodutivo e a distribuição da proporção dos estágios no equilíbrio estão relacionados aos autovetores. Esses valores podem ser obtidos com a função eigen12). Para saber como calcular esses valores veja o roteiro da disciplina de ecologia de populações na qual esse tópico foi baseado.
Autovalores da matriz
eigen(matCory)
Matrix de comunidade
Um formato de dados clássico em ecologia de comunidades é o de espécies por localidade, como a ocorrência ou a contagem de indivíduos. Já usamos a função table para contagem de uma variável tipo fator. Vamos construir essa nova estrutura de dados a partir do objeto caixeta e fazer a coerção para a classe matrix.
Matriz caixeta
str(caixeta)
caixTable <- table(caixeta$especie, caixeta$local)
str(caixTable)
class(caixTable)
caixTable[,"chauas"]
caixMatrix <- as.matrix(caixTable)
str(caixMatrix)
identical(caixMatrix, caixTable)
class(caixMatrix)
Apesar de parecer que a coerção do objeto table para matrix não tenha funcionado, a coerção funcionou como deveria. Os objetos da classe table são matrizes especiais de tabelas de contingência13) usadas para os testes de dependência entre variáveis categóricas. Para o R é um objeto subordinado à classe matrix.
Vamos agora fazer a manipulação desses dados para saber quantos indivíduos e espécies temos na localidade jureia. Primeiro precisamos manipular o objeto caixMatrix para que ela tenha apenas a informação de ocorrência
Operando caixeta
caixMatrix[caixTable > 0 ] <- 1
head(caixTable)
head(caixMatrix)
Agora podemos contar a coluna jureia em cada uma dos objetos:
Operando jureia
sum(caixTable[, "jureia"])
sum(caixMatrix[, "jureia"])
Poderíamos usar a função apply para fazer a contagem de todas as colunas de uma vez. A função apply aplica uma função para alguma dimensão dos dados, no caso, coluna ou linhas, e cicla a função para todas as posições dessa dimensão.
Apply em matriz
apply(caixTable, MARGIN = 2, FUN = sum)
apply(caixMatrix, 2, sum)
Combinando Dados Tabulares
É comum termos informações que estão em formato de dados tabulares e precisam ser agrupadas com outro conjunto de dados. Vamos olhar algumas das ferramentas para fazer isso.
Em construção
Combinando colunas ou linhas
As funções rbind e cbind são utilizadas para concatenar dados tabulares pelas linhas ou colunas. Entretanto, só funcionam se a estrutura é a mesma, ou seja as variáveis são as mesmas e na mesma posição para acrescentar novas observações, ou as observações estão nas mesmas linhas para acrescentar novas variáveis.
Combinando matrizes
trapa <- read.table("http://ecor.ib.usp.br/lib/exe/fetch.php?media=dados:trapa.csv", header = TRUE, sep = ",")
str(trapa)
trapaNome <- read.table("http://ecor.ib.usp.br/lib/exe/fetch.php?media=dados:trapa_nome.txt", header = TRUE, sep = ",")
str(trapaNome)
trapaNome
trapa
rbind(trapa, trapa)
trapabind <- cbind(trapa, trapaNome)
Outras formas de combinar
Quando colunas ou linhas não podem ser combinadas diretamente, porque as posições não são compatíveis, podemos usar as funções merge e match. O merge combina dois objetos por uma coluna que é a referência comum, combinando as variáveis de ambos dataframe. O match funciona também a partir de uma variável comum a ambos objetos e produz um índice de posição que ordena um dos objetos na mesma posição que o outro. O match é um pouco mais difícil de entender, mas é uma ferramenta poderosa para manipular dados tabulares. Abaixo apresentamos ambas funções manipulando dados muito simples para demonstrar como funcionam.
Merge
## merge
merge(trapa, trapaNome, by = "codinome")
trapa$codinome
trapaNome$codinome
merge(trapa, trapaNome, by = "codinome", all = TRUE)
trapa$codinome[2] <- trapaNome$codinome[3]
trapa$codinome
merge(trapa, trapaNome, by = "codinome")
## match
(matchtrap <- match(trapa$codinome, trapaNome$codinome))
trapaNome[matchtrap, ]
trapa$nome <- trapaNome[matchtrap, "nome"]
trapa
Array
O objeto matrix por sua vez é apenas um objeto da classe array com apenas duas dimensões, assim como o vector é um array de uma dimensão. Veja a classe do objeto pop que criamos na sessão de multiplicação de matrizes:
Array
class(pop)
A classe é matrix mas a classe parental é array. Essa possibilidade de um array ter muitas dimensões permite efetuarmos operações e análises em múltiplas dimensões. As características e operações que fizemos em matrix se aplicam também para array.
Vamos avaliar um objeto dessa classe chamado Titanic. Primeiro vamos entender onde está esse objeto.
A função search mostra o caminho de busca nos compartimentos de memória da sessão do R. Nele há um pacote chamado datasets que é carregado por padrão ao abrirmos uma sessão do R.
Datasets
search()
ls("package:datasets")
ls("package:datasets", pattern = "Tit")
Isso significa que esse objeto está disponível para uso sem a necessidade de carregá-lo. Vamos investigar alguns atributos dele:
Titanic
is.array(Titanic)
dim(Titanic)
dimnames(Titanic)
Um tanto mais complicado de visualizar os dados do que uma planilha. Imagine os quatro níveis de Class como sendo as linhas de um planilha, sex como as colunas, age como sendo a repetição dessa estrutura para Child e Adult, por fim essa estrutura replicada para Survived igual a No e Yes. Como as quatro dimensões tem tamanhos pequenos é possível visualizar todos dados:
array
str(Titanic)
Titanic
Essa estrutura permite operar qualquer dimensão, ou mesmo algumas dimensões ao mesmo tempo. Vamos usar o apply para obter algumas informações interessantes sobre as vítimas do naufrágio.
Será que crianças e adultos tiveram a mesma proporção de vítimas?
Array apply
apply(Titanic, c("Age", "Survived"), sum)
Será que a proporção de vítimas entre homens e mulheres foi similar?
Array apply II
apply(Titanic, c("Sex", "Survived"), sum)
E entre os passageiros de diferentes classes?
Array apply III
apply(Titanic, c("Class", "Survived"), sum)
Mistério do Titanic: mulheres e crianças primeiro
Os grupos com maior sobrevivência no desastre do Titanic foram as mulheres e crianças da primeira classe. Analisando dados de múltiplos acidentes marinhos o artigo ''Gender, social norms, and survival in maritime disasters'', Elinder & Erixson (2012) verifica que a distribuição de sobrevivência do Titanic é uma exceção. As evidências nos dados desse artigo mostram que a maior sobrevivência está entre os homens da tripulação e a menor entre as crianças.
Listas
Listas são os objetos mais versáteis para armazenar informação no R. Apesar de ter uma única dimensão, suas posições comportam qualquer outra classe de objeto que vimos até então. Normalmente os objetos mais complexos no R, como por exemplo resultados de modelos estatísticos, são casos especiais de listas padronizadas. Vamos criar a nossa primeira lista com alguns objetos desse tutorial:
Criando listas
minhaLista <- list(vectorNum = num, dfTrapa = trapalhoes, matPop = pop, arrayTit = Titanic)
str(minhaLista)
A indexação da lista é um misto das classes de objetos que vimos anteriormente. Na sua primeira dimensão aceita tanto o nome com $ como um data.frame quanto um novo indexador que é o [[ colchete duplo.
Indexando listas
minhaLista <- list(vectorNum = num, dfTrapa = trapalhoes, matPop = pop, arrayTit = Titanic)
str(minhaLista)
minhaLista$dfTrapa
minhaLista[[3]]
minhaLista[["vectorNum"]]
Os elementos de cada posição podem ser acessados usando as indexações correspondentes a cada classe!
Niveis de indexação
minhaLista$dfTrapa[, "nomes"]
minhaLista[[3]][1,]
minhaLista[["vectorNum"]] [7]
Lembre-se sempre de olhar o help. Não cometa o 7º pecado da lista do início desse tutorial, acostume-se com a documentação e como a sua estrutura. Todas as funções nesse tutorial apresentam um hiperlink que leva à sua documentação.
Um Exemplo
No vídeo abaixo apresento um exemplo de manipulação de dados de um estudo sobre dinâmica de população de uma espécie de árvore (Guapira opposita) da floresta atlântica, utilizando matrizes e arrays.
1)
existem muitos outros tipos de formatos de armazenamento de dados que incorporam dados mais complexos e georreferenciados
2)
read.table é muito flexível, veja a documentação!
3)
incluíndo a extensão e o caminho, caso não esteja no diretório de trabalho
4)
utiliza a primeira linha dos dados para o nome das colunas
5)
qual o símbolo separa os dados de uma mesma linha em colunas. Ex: “\t” é tabulação
6)
O padrão até a versão 4.0 do R era transformar caracteres em fator na leitura. A partir dessa versão o padrão mudou e a versão mais recente da função não faz essa transformação automática.
7)
veja artigo sobre essa mudança em developer blog
8)
Por padrão a função write.table salvará o valor de indexação da linha como o nome da observação
9)
para saber mais veja o roteiro de população estruturada em nosso projeto EcoVirtual
10)
apresentam estágios diferentes
11)
ou seja, trocamos as linhas pelas colunas
12)
consulte a ajuda para interpretar o resultados dessa função
13)
tabelas de contagem
02_tutoriais/tutorial3/start.txt · Última modificação: 2023/08/23 12:24 (edição externa)
|
{
"url": "http://ecor.ib.usp.br/doku.php?id=02_tutoriais:tutorial3:start",
"source_domain": "ecor.ib.usp.br",
"snapshot_id": "CC-MAIN-2024-18",
"warc_metadata": {
"Content-Length": "137241",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ZXKDVCKPRC4TISQI33JFYPFG2EXBOLTD",
"WARC-Concurrent-To": "<urn:uuid:0222cb18-240f-4ac1-b9f3-abc31de07bb5>",
"WARC-Date": "2024-04-20T04:36:04Z",
"WARC-IP-Address": "143.107.246.248",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:IKMSTY7C6KHAGUENOD2CY57RCWAGDCMI",
"WARC-Record-ID": "<urn:uuid:cd5b93c4-a28a-4622-af10-dc1526226074>",
"WARC-Target-URI": "http://ecor.ib.usp.br/doku.php?id=02_tutoriais:tutorial3:start",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2c0a364c-0a33-4b1e-8e7b-4865efc1d520>"
},
"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-118\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,
24,
25,
48,
49,
69,
70,
71,
100,
101,
153,
154,
345,
346,
363,
364,
403,
404,
728,
729,
745,
770,
771,
946,
947,
962,
966,
978,
989,
1003,
1008,
1019,
1023,
1024,
1189,
1190,
1206,
1213,
1241,
1245,
1253,
1255,
1267,
1278,
1284,
1296,
1297,
1439,
1440,
1460,
1473,
1477,
1483,
1495,
1496,
1565,
1566,
1584,
1596,
1607,
1630,
1642,
1643,
1980,
1981,
2186,
2187,
2204,
2205,
3065,
3066,
3630,
3631,
3979,
3980,
4146,
4147,
4183,
4184,
4224,
4248,
4268,
4300,
4329,
4336,
4342,
4359,
4364,
4384,
4407,
4412,
4418,
4447,
4454,
4461,
4462,
4484,
4485,
4845,
4846,
4895,
5011,
5088,
5138,
5139,
5156,
5157,
5308,
5309,
5430,
5431,
5568,
5569,
5577,
5621,
5622,
5651,
5652,
5667,
5748,
5781,
5782,
6190,
6191,
6207,
6262,
6277,
6278,
6302,
6303,
6500,
6501,
6513,
6620,
6621,
6633,
6634,
7167,
7168,
7405,
7406,
7424,
7437,
7452,
7465,
7479,
7480,
8006,
8007,
8022,
8092,
8105,
8120,
8133,
8147,
8148,
8340,
8341,
8358,
8359,
9098,
9099,
9117,
9118,
9277,
9278,
9294,
9333,
9372,
9385,
9386,
9674,
9675,
9707,
9708,
10102,
10103,
10115,
10134,
10147,
10148,
10394,
10395,
10422,
10423,
10436,
10467,
10480,
10481,
10609,
10610,
10620,
10621,
10782,
10783,
10805,
10826,
10843,
10844,
11035,
11036,
11054,
11069,
11099,
11130,
11131,
11463,
11464,
11489,
11503,
11532,
11562,
11563,
11652,
11653,
11672,
11690,
11723,
11757,
11758,
11798,
11799,
11824,
11852,
11895,
11939,
11940,
11961,
11962,
12137,
12138,
12152,
12291,
12292,
12334,
12335,
12354,
12404,
12437,
12490,
12491,
12887,
12888,
12909,
12920,
12945,
12982,
12983,
12992,
12993,
13266,
13267,
13281,
13282,
13467,
13468,
13484,
13522,
13530,
13531,
13590,
13591,
13619,
13620,
13847,
13848,
13869,
13891,
13892,
13936,
13937,
13967,
14008,
14009,
14260,
14261,
14353,
14354,
14380,
14410,
14411,
14527,
14528,
14672,
14673,
14693,
14735,
14736,
14963,
14964,
15028,
15029,
15047,
15085,
15114,
15144,
15145,
15279,
15280,
15447,
15448,
15461,
15475,
15499,
15537,
15538,
15558,
15559,
16191,
16192,
16219,
16310,
16311,
16343,
16344,
16393,
16422,
16452,
16494,
16560,
16561,
16749,
16750,
16765,
16785,
16805,
16811,
16812,
17004,
17005,
17033,
17034,
18050,
18051,
18066,
18067,
18076,
18077,
18356,
18357,
18434,
18435,
18456,
18457,
18765,
18766,
18971,
18972,
19125,
19126,
19164,
19165,
19195,
19224,
19255,
19256,
19857,
19858,
20001,
20002,
20017,
20103,
20111,
20112,
20315,
20316,
20333,
20347,
20369,
20377,
20378,
20528,
20529,
20681,
20682,
20712,
20735,
20741,
20742,
21041,
21042,
21066,
21093,
21099,
21126,
21132,
21159,
21165,
21166,
21253,
21254,
21285,
21354,
21404,
21408,
21429,
21479,
21480,
21863,
21864,
21972,
21973,
21993,
22003,
22019,
22047,
22078,
22121,
22122,
22265,
22266,
22276,
22326,
22376,
22426,
22476,
22526,
22533,
22534,
22612,
22613,
22629,
22704,
22705,
23077,
23078,
23246,
23247,
23265,
23449,
23544,
23545,
23589,
23590,
24214,
24215,
24237,
24252,
24253,
24274,
24275,
24589,
24590,
24605,
24618,
24669,
24684,
24701,
24722,
24757,
24773,
24806,
24824,
24825,
25137,
25138,
25355,
25356,
25373,
25405,
25421,
25438,
25439,
25501,
25502,
25518,
25545,
25573,
25574,
25807,
25808,
25824,
25864,
25890,
25891,
25918,
25919,
26093,
26094,
26108,
26109,
26138,
26139,
26453,
26454,
26474,
26585,
26596,
26598,
26718,
26733,
26735,
26745,
26751,
26753,
26773,
26810,
26811,
26837,
26838,
27456,
27457,
27463,
27473,
27475,
27516,
27531,
27550,
27552,
27605,
27648,
27663,
27704,
27706,
27708,
27717,
27719,
27776,
27799,
27842,
27848,
27849,
27855,
27856,
28074,
28075,
28081,
28092,
28093,
28341,
28342,
28443,
28444,
28623,
28624,
28633,
28642,
28665,
28705,
28706,
28835,
28836,
28844,
28862,
28875,
28893,
28894,
29265,
29266,
29272,
29285,
29293,
29294,
29481,
29482,
29548,
29549,
29561,
29603,
29604,
29673,
29674,
29689,
29731,
29732,
29778,
29779,
29795,
29839,
29840,
29890,
29891,
30348,
30349,
30356,
30357,
30748,
30749,
30764,
30857,
30873,
30874,
31076,
31077,
31094,
31187,
31203,
31222,
31238,
31264,
31265,
31366,
31367,
31387,
31417,
31437,
31467,
31468,
31700,
31701,
31712,
31713,
31912,
31913,
31916,
32038,
32041,
32091,
32094,
32169,
32172,
32231,
32234,
32317,
32320,
32509,
32512,
32561,
32564,
32660,
32663,
32747,
32751,
32782,
32786,
32828,
32832,
32892,
32896,
32916
],
"line_end_idx": [
24,
25,
48,
49,
69,
70,
71,
100,
101,
153,
154,
345,
346,
363,
364,
403,
404,
728,
729,
745,
770,
771,
946,
947,
962,
966,
978,
989,
1003,
1008,
1019,
1023,
1024,
1189,
1190,
1206,
1213,
1241,
1245,
1253,
1255,
1267,
1278,
1284,
1296,
1297,
1439,
1440,
1460,
1473,
1477,
1483,
1495,
1496,
1565,
1566,
1584,
1596,
1607,
1630,
1642,
1643,
1980,
1981,
2186,
2187,
2204,
2205,
3065,
3066,
3630,
3631,
3979,
3980,
4146,
4147,
4183,
4184,
4224,
4248,
4268,
4300,
4329,
4336,
4342,
4359,
4364,
4384,
4407,
4412,
4418,
4447,
4454,
4461,
4462,
4484,
4485,
4845,
4846,
4895,
5011,
5088,
5138,
5139,
5156,
5157,
5308,
5309,
5430,
5431,
5568,
5569,
5577,
5621,
5622,
5651,
5652,
5667,
5748,
5781,
5782,
6190,
6191,
6207,
6262,
6277,
6278,
6302,
6303,
6500,
6501,
6513,
6620,
6621,
6633,
6634,
7167,
7168,
7405,
7406,
7424,
7437,
7452,
7465,
7479,
7480,
8006,
8007,
8022,
8092,
8105,
8120,
8133,
8147,
8148,
8340,
8341,
8358,
8359,
9098,
9099,
9117,
9118,
9277,
9278,
9294,
9333,
9372,
9385,
9386,
9674,
9675,
9707,
9708,
10102,
10103,
10115,
10134,
10147,
10148,
10394,
10395,
10422,
10423,
10436,
10467,
10480,
10481,
10609,
10610,
10620,
10621,
10782,
10783,
10805,
10826,
10843,
10844,
11035,
11036,
11054,
11069,
11099,
11130,
11131,
11463,
11464,
11489,
11503,
11532,
11562,
11563,
11652,
11653,
11672,
11690,
11723,
11757,
11758,
11798,
11799,
11824,
11852,
11895,
11939,
11940,
11961,
11962,
12137,
12138,
12152,
12291,
12292,
12334,
12335,
12354,
12404,
12437,
12490,
12491,
12887,
12888,
12909,
12920,
12945,
12982,
12983,
12992,
12993,
13266,
13267,
13281,
13282,
13467,
13468,
13484,
13522,
13530,
13531,
13590,
13591,
13619,
13620,
13847,
13848,
13869,
13891,
13892,
13936,
13937,
13967,
14008,
14009,
14260,
14261,
14353,
14354,
14380,
14410,
14411,
14527,
14528,
14672,
14673,
14693,
14735,
14736,
14963,
14964,
15028,
15029,
15047,
15085,
15114,
15144,
15145,
15279,
15280,
15447,
15448,
15461,
15475,
15499,
15537,
15538,
15558,
15559,
16191,
16192,
16219,
16310,
16311,
16343,
16344,
16393,
16422,
16452,
16494,
16560,
16561,
16749,
16750,
16765,
16785,
16805,
16811,
16812,
17004,
17005,
17033,
17034,
18050,
18051,
18066,
18067,
18076,
18077,
18356,
18357,
18434,
18435,
18456,
18457,
18765,
18766,
18971,
18972,
19125,
19126,
19164,
19165,
19195,
19224,
19255,
19256,
19857,
19858,
20001,
20002,
20017,
20103,
20111,
20112,
20315,
20316,
20333,
20347,
20369,
20377,
20378,
20528,
20529,
20681,
20682,
20712,
20735,
20741,
20742,
21041,
21042,
21066,
21093,
21099,
21126,
21132,
21159,
21165,
21166,
21253,
21254,
21285,
21354,
21404,
21408,
21429,
21479,
21480,
21863,
21864,
21972,
21973,
21993,
22003,
22019,
22047,
22078,
22121,
22122,
22265,
22266,
22276,
22326,
22376,
22426,
22476,
22526,
22533,
22534,
22612,
22613,
22629,
22704,
22705,
23077,
23078,
23246,
23247,
23265,
23449,
23544,
23545,
23589,
23590,
24214,
24215,
24237,
24252,
24253,
24274,
24275,
24589,
24590,
24605,
24618,
24669,
24684,
24701,
24722,
24757,
24773,
24806,
24824,
24825,
25137,
25138,
25355,
25356,
25373,
25405,
25421,
25438,
25439,
25501,
25502,
25518,
25545,
25573,
25574,
25807,
25808,
25824,
25864,
25890,
25891,
25918,
25919,
26093,
26094,
26108,
26109,
26138,
26139,
26453,
26454,
26474,
26585,
26596,
26598,
26718,
26733,
26735,
26745,
26751,
26753,
26773,
26810,
26811,
26837,
26838,
27456,
27457,
27463,
27473,
27475,
27516,
27531,
27550,
27552,
27605,
27648,
27663,
27704,
27706,
27708,
27717,
27719,
27776,
27799,
27842,
27848,
27849,
27855,
27856,
28074,
28075,
28081,
28092,
28093,
28341,
28342,
28443,
28444,
28623,
28624,
28633,
28642,
28665,
28705,
28706,
28835,
28836,
28844,
28862,
28875,
28893,
28894,
29265,
29266,
29272,
29285,
29293,
29294,
29481,
29482,
29548,
29549,
29561,
29603,
29604,
29673,
29674,
29689,
29731,
29732,
29778,
29779,
29795,
29839,
29840,
29890,
29891,
30348,
30349,
30356,
30357,
30748,
30749,
30764,
30857,
30873,
30874,
31076,
31077,
31094,
31187,
31203,
31222,
31238,
31264,
31265,
31366,
31367,
31387,
31417,
31437,
31467,
31468,
31700,
31701,
31712,
31713,
31912,
31913,
31916,
32038,
32041,
32091,
32094,
32169,
32172,
32231,
32234,
32317,
32320,
32509,
32512,
32561,
32564,
32660,
32663,
32747,
32751,
32782,
32786,
32828,
32832,
32892,
32896,
32916,
33004
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 33004,
"ccnet_original_nlines": 629,
"rps_doc_curly_bracket": 0.00012119999882997945,
"rps_doc_ldnoobw_words": 2,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.10857059061527252,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.016079070046544075,
"rps_doc_frac_lines_end_with_ellipsis": 0.0015872999792918563,
"rps_doc_frac_no_alph_words": 0.2515120208263397,
"rps_doc_frac_unique_words": 0.26138895750045776,
"rps_doc_mean_word_length": 5.395019054412842,
"rps_doc_num_sentences": 319,
"rps_doc_symbol_to_word_ratio": 0.0010325999464839697,
"rps_doc_unigram_entropy": 6.08762788772583,
"rps_doc_word_count": 4939,
"rps_doc_frac_chars_dupe_10grams": 0.01189672015607357,
"rps_doc_frac_chars_dupe_5grams": 0.030623730272054672,
"rps_doc_frac_chars_dupe_6grams": 0.019552649930119514,
"rps_doc_frac_chars_dupe_7grams": 0.017526080831885338,
"rps_doc_frac_chars_dupe_8grams": 0.014974099583923817,
"rps_doc_frac_chars_dupe_9grams": 0.01189672015607357,
"rps_doc_frac_chars_top_2gram": 0.00866921991109848,
"rps_doc_frac_chars_top_3gram": 0.0021016299724578857,
"rps_doc_frac_chars_top_4gram": 0.006530059967190027,
"rps_doc_books_importance": -3183.466552734375,
"rps_doc_books_importance_length_correction": -3183.466552734375,
"rps_doc_openwebtext_importance": -1731.873779296875,
"rps_doc_openwebtext_importance_length_correction": -1731.873779296875,
"rps_doc_wikipedia_importance": -984.4796142578125,
"rps_doc_wikipedia_importance_length_correction": -984.4796142578125
},
"fasttext": {
"dclm": 0.873344361782074,
"english": 0.0019664799328893423,
"fineweb_edu_approx": 1.8058481216430664,
"eai_general_math": 0.00276333000510931,
"eai_open_web_math": 0.45347511768341064,
"eai_web_code": 0.9630910158157349
}
}
|
{
"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": "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": "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
|