prompt
stringlengths 4
3.12k
| chosen
stringlengths 3
10.5k
| rejected
stringlengths 3
8.98k
|
---|---|---|
machine learning is teaching us the secret to teaching
| “in many cases, humans use their own knowledge about
actions to recognize those actions in others,” he told
me. “if a robot knows how to grasp, it has better chance
of recognizing grasping actions of a person,” he said.
metta is going one step further, by teaching icub to
follow social cues, like directing its attention to
an object when someone looks at it. these cues become
another channel through which to collect privileged
information about a complex world.
this article kept getting better and better. i thought this was particularly interesting because it leads to a world where the ai software is available to all, but what's of value is the rules or metaphors you've developed for your robots. that would give garage hobbyists a chance of coming up with their own special formulas and possibly be the ones to figure out something novel or world-altering in ai. | > his advice gave no specific information on what angle the bow should describe, or how to move the fingers across the frets to create vibratoand it's a good thing he didn't - violins don't have frets /nitpick |
machine learning is teaching us the secret to teaching
| > his advice gave no specific information on what angle the bow should describe, or how to move the fingers across the frets to create vibratoand it's a good thing he didn't - violins don't have frets /nitpick | as i see it, the natural extension of identifying this "secret to teaching," is to try and extrapolate it to "unlearning," or memory loss, dementia and alzheimer's.if we can mimic and model the neuronal pathways and firings within humans, using ai, then we should also be able to study the relationship between the failure and degradation of pathways. ai pathways are subject to break and fail as well, though the causes are of course different. however, it would be imagined that there must be some shared structural stresses that result in the "unlearning" and failure to fire or function.the potential for ai is immeasurable. if we can teach a robot, surely we can stress its system enough to "unteach" it. despite being unable to force-feed it junk-food and/or vitamins/minerals, we can replicate environmental stressors, and once having generated the "unlearning" process, examine how to halt the degradation and perhaps reverse the trajectory. |
machine learning is teaching us the secret to teaching
| as i see it, the natural extension of identifying this "secret to teaching," is to try and extrapolate it to "unlearning," or memory loss, dementia and alzheimer's.if we can mimic and model the neuronal pathways and firings within humans, using ai, then we should also be able to study the relationship between the failure and degradation of pathways. ai pathways are subject to break and fail as well, though the causes are of course different. however, it would be imagined that there must be some shared structural stresses that result in the "unlearning" and failure to fire or function.the potential for ai is immeasurable. if we can teach a robot, surely we can stress its system enough to "unteach" it. despite being unable to force-feed it junk-food and/or vitamins/minerals, we can replicate environmental stressors, and once having generated the "unlearning" process, examine how to halt the degradation and perhaps reverse the trajectory. | although the article makes no mention of them, george lakoff and mark johnson's research on conceptual metaphor[0] seems to be intricately tied to this, somehow. i recently read two books by them: metaphors we live by (see peter norvig's description here[1]), and philosophy in the flesh[2] and found the ideas in them on how humans use metaphors to make sese of things very interesting and intuitive. it actually left me wondering when and how ai would use these insights.[0] <link>[1] <link> - because it stays focused on language it manages to make a clear and convincing case[2] <link> - by comparison a flawed but nonetheless good read. i agree with the critiques laid out this review: <link> |
machine learning is teaching us the secret to teaching
| although the article makes no mention of them, george lakoff and mark johnson's research on conceptual metaphor[0] seems to be intricately tied to this, somehow. i recently read two books by them: metaphors we live by (see peter norvig's description here[1]), and philosophy in the flesh[2] and found the ideas in them on how humans use metaphors to make sese of things very interesting and intuitive. it actually left me wondering when and how ai would use these insights.[0] <link>[1] <link> - because it stays focused on language it manages to make a clear and convincing case[2] <link> - by comparison a flawed but nonetheless good read. i agree with the critiques laid out this review: <link> | i found some slides [1] explaining how this works.a less poetic example of privileged information: if you're training on time-series information, you can include events from the future in the training examples, even though they won't be available while making predictions in production.apparently this helps the machine learning algorithm find the outlying data points when the data isn't linearly separable.[1] <link> |
mining bitcoin with pencil and paper: 0.67 hashes per day
| i once calculated the mandelbrot set on graph paper. this article makes me feel slightly less dorky. :) | i'm a big fan of ken shirriff's blog. if you're interested in learning more about bitcoin i would also recommend reading his post titled "bitcoins the hard way: using the raw bitcoin protocol". |
mining bitcoin with pencil and paper: 0.67 hashes per day
| i'm a big fan of ken shirriff's blog. if you're interested in learning more about bitcoin i would also recommend reading his post titled "bitcoins the hard way: using the raw bitcoin protocol". | i assume there are mathematician farms where they are no longer born but grown for the purpose of finding any possible ways to cut steps from hashing.do the chips still run this plain vanilla sha256 algo, or have they found some steps that can be skipped? things like not calculating the final steps if you notice that there won't be enough zeroes. |
mining bitcoin with pencil and paper: 0.67 hashes per day
| i assume there are mathematician farms where they are no longer born but grown for the purpose of finding any possible ways to cut steps from hashing.do the chips still run this plain vanilla sha256 algo, or have they found some steps that can be skipped? things like not calculating the final steps if you notice that there won't be enough zeroes. | i'm probably going to do one step wrongly and get laughed at, but here goes:7 000 000 000 humans * 0.67 hashes per day = 4 690 000 000 hashes per day (or 54282.4074074 per second)54282h/s would give us a daily profit of: 0.00078760 btc ($0.30)so when the evil space aliens conquers the human race, they can put us to good use to generate 30 cents worth of bitcoins for them every day (not counting human electricity cost aka food). |
mining bitcoin with pencil and paper: 0.67 hashes per day
| i'm probably going to do one step wrongly and get laughed at, but here goes:7 000 000 000 humans * 0.67 hashes per day = 4 690 000 000 hashes per day (or 54282.4074074 per second)54282h/s would give us a daily profit of: 0.00078760 btc ($0.30)so when the evil space aliens conquers the human race, they can put us to good use to generate 30 cents worth of bitcoins for them every day (not counting human electricity cost aka food). | reminds me of xiaoyun wang's discovery of md5 (and other hash functions') collisions, which was allegedly done mostly manually:<link> that the output conditions for a bitcoin hash are essentially a limited form of preimage attack, i wonder if this "human uses properties of hash function to reduce the problem space, lets the machine bruteforce the rest" method could have any advantage. machines are great at doing operations quickly, but human brains tend to be far better at noticing patterns and using ingenuity. |
ask hn: as a busy founder, how to address a website best?
i'm a single founder of a high-tech (but not web-based) company. however, i don't really have the thousands of dollars it would take to get a website designer to put together a site for me.<p>i absolutely respect that it's worth the money, the money just doesn't exist. so, i need to find a stopgap so that my company has <i>something</i> out on the web which makes us look professional enough that when i reach out to customers we don't look like total amateurs.<p>can anyone help me navigate this mild morass? should i just use bootstrap and get something minimal up? or is there some other solution that takes a little more time but would look a lot better?<p>what i'm trying to find is whatever will get me to a site that, not including creating the content, will take me less than 10 hours to get to a clean and modern state for someone who has used linux exclusively for over a decade, and knows basic programming, but is busy enough to want to really just follow a tutorial (that actually works).<p>i don't care about things like the new trend of scrolling graphics windows or whatever that sin of nature is, or probably most other modern features. i'm looking to make a site closer to dupont in style than a web startup. the one thing that would be a really "nice to have" is a news feed that i can update via the web to keep the content updated more often. | a lot of founders who have businesses that aren't reliant on the internet dump money on a really nice website thinking it'll be a great marketing tool. then they end up disappointed when their website isn't generating any leads.the web is so competitive nowadays, simply having a site (even if it looks great) won't do you any good.10-20% of a budget should be spent on web design and 80-90% on actually marketing the website. so if you have a 5k budget you should spend around $500-$1000 on the website and the rest on marketing the website.if you can't get something built for under 20% then maybe just put up a facebook or google places page in the interim. a website can be a huge distraction from time better spent going out and getting customers.also, if you're a designer doing basic business websites, keep in mind on-page seo practices. it really bothers me when designers completely disregard search engines and do their clients a huge disservice. designers who can talk about basic seo principles have a huge leg up. at the end of the day, a business owner is only really interested in more business.i'm not suggesting this is the op, but a common mistake i see amongst founders | have you seen squarespace[0]? it is one of the quickest ways to launch a website. it even lets you register a domain, so it is all-inclusive.[0] - <link> |
ask hn: as a busy founder, how to address a website best?
i'm a single founder of a high-tech (but not web-based) company. however, i don't really have the thousands of dollars it would take to get a website designer to put together a site for me.<p>i absolutely respect that it's worth the money, the money just doesn't exist. so, i need to find a stopgap so that my company has <i>something</i> out on the web which makes us look professional enough that when i reach out to customers we don't look like total amateurs.<p>can anyone help me navigate this mild morass? should i just use bootstrap and get something minimal up? or is there some other solution that takes a little more time but would look a lot better?<p>what i'm trying to find is whatever will get me to a site that, not including creating the content, will take me less than 10 hours to get to a clean and modern state for someone who has used linux exclusively for over a decade, and knows basic programming, but is busy enough to want to really just follow a tutorial (that actually works).<p>i don't care about things like the new trend of scrolling graphics windows or whatever that sin of nature is, or probably most other modern features. i'm looking to make a site closer to dupont in style than a web startup. the one thing that would be a really "nice to have" is a news feed that i can update via the web to keep the content updated more often. | have you seen squarespace[0]? it is one of the quickest ways to launch a website. it even lets you register a domain, so it is all-inclusive.[0] - <link> | like others have said just go with a themeforest theme, if you or someone else in your company knows html/css they can take an html theme and have your website up and running in an afternoon.i'm not a fan of wordpress unless you're going to be blogging posting articles on a regular basis.wp is fast and easy to setup from scratch on hostgator or any web host . . . it will probably take longer to get the site setup vs. an html version . . . but it will be easier to edit/post articles.hostgator is good shared hosting . . . to get setup fast and inexpensively . . .good luck with your new website. |
ask hn: as a busy founder, how to address a website best?
i'm a single founder of a high-tech (but not web-based) company. however, i don't really have the thousands of dollars it would take to get a website designer to put together a site for me.<p>i absolutely respect that it's worth the money, the money just doesn't exist. so, i need to find a stopgap so that my company has <i>something</i> out on the web which makes us look professional enough that when i reach out to customers we don't look like total amateurs.<p>can anyone help me navigate this mild morass? should i just use bootstrap and get something minimal up? or is there some other solution that takes a little more time but would look a lot better?<p>what i'm trying to find is whatever will get me to a site that, not including creating the content, will take me less than 10 hours to get to a clean and modern state for someone who has used linux exclusively for over a decade, and knows basic programming, but is busy enough to want to really just follow a tutorial (that actually works).<p>i don't care about things like the new trend of scrolling graphics windows or whatever that sin of nature is, or probably most other modern features. i'm looking to make a site closer to dupont in style than a web startup. the one thing that would be a really "nice to have" is a news feed that i can update via the web to keep the content updated more often. | like others have said just go with a themeforest theme, if you or someone else in your company knows html/css they can take an html theme and have your website up and running in an afternoon.i'm not a fan of wordpress unless you're going to be blogging posting articles on a regular basis.wp is fast and easy to setup from scratch on hostgator or any web host . . . it will probably take longer to get the site setup vs. an html version . . . but it will be easier to edit/post articles.hostgator is good shared hosting . . . to get setup fast and inexpensively . . .good luck with your new website. | i'd say your best bet is to check out some of the high quality themes at <link> -- if you don't want to deal with html / css the wordpress themes are really easy to setup and look amazing. |
ask hn: as a busy founder, how to address a website best?
i'm a single founder of a high-tech (but not web-based) company. however, i don't really have the thousands of dollars it would take to get a website designer to put together a site for me.<p>i absolutely respect that it's worth the money, the money just doesn't exist. so, i need to find a stopgap so that my company has <i>something</i> out on the web which makes us look professional enough that when i reach out to customers we don't look like total amateurs.<p>can anyone help me navigate this mild morass? should i just use bootstrap and get something minimal up? or is there some other solution that takes a little more time but would look a lot better?<p>what i'm trying to find is whatever will get me to a site that, not including creating the content, will take me less than 10 hours to get to a clean and modern state for someone who has used linux exclusively for over a decade, and knows basic programming, but is busy enough to want to really just follow a tutorial (that actually works).<p>i don't care about things like the new trend of scrolling graphics windows or whatever that sin of nature is, or probably most other modern features. i'm looking to make a site closer to dupont in style than a web startup. the one thing that would be a really "nice to have" is a news feed that i can update via the web to keep the content updated more often. | i'd say your best bet is to check out some of the high quality themes at <link> -- if you don't want to deal with html / css the wordpress themes are really easy to setup and look amazing. | find a suitable free template here: <link> some suitable stock photo here: <link> it here: <link> looking website in a couple of hours. |
rob pike: reflections on window systems (2008) [video]
| in the middle of the talk, pike said that the idea of a workstation in every office was one of the stupidest things he'd ever heard, but then decided not to digress and explain why. has he discussed that at length in any other paper or recorded talk? | i loved plan9. i was into it before the 3rd edition was released and i built a small career out of it. it was and still is the most enjoyable system to work with.i'm happy it's getting its dues in retrospect and is now considered a cool thing, but i can't help but remember how just after the first open release everybody and their uncle kept complaining about trivia: "how can i become root?" "it doesn't do x11?" "its license isn't gnu-open?"rob is probably right: licensing killed plan9, but so did everybody who couldn't see the forest for the trees. the linux juggernaut was too popular back then. |
rob pike: reflections on window systems (2008) [video]
| i loved plan9. i was into it before the 3rd edition was released and i built a small career out of it. it was and still is the most enjoyable system to work with.i'm happy it's getting its dues in retrospect and is now considered a cool thing, but i can't help but remember how just after the first open release everybody and their uncle kept complaining about trivia: "how can i become root?" "it doesn't do x11?" "its license isn't gnu-open?"rob is probably right: licensing killed plan9, but so did everybody who couldn't see the forest for the trees. the linux juggernaut was too popular back then. | the blit video he mentions: <link> similarly interesting talk by him on csp-inspired languages (occam, erlang, squeak, newsqueak, limbo, alef, go): <link> (not shown in the video): <link> as well: from parellel to concurrent (on sawzall and go): <link> |
rob pike: reflections on window systems (2008) [video]
| the blit video he mentions: <link> similarly interesting talk by him on csp-inspired languages (occam, erlang, squeak, newsqueak, limbo, alef, go): <link> (not shown in the video): <link> as well: from parellel to concurrent (on sawzall and go): <link> | "to be honest, looking back on it, unix today is worse than the systems that unix itself was created to get away from." |
rob pike: reflections on window systems (2008) [video]
| "to be honest, looking back on it, unix today is worse than the systems that unix itself was created to get away from." | who's the guy at the end saying "let's forget where i work and where you work", asking the "hard" question? |
ask hn: what was the easiest buck you've made on the web in 2014?
| send me a buck and i'll let you know. | there was an article on digg.com about google becoming a worse search engine. the article was on news.yahoo.comsomeone commented "5 dollars to someone who points out the irony in this", i replied. the guy sent me $5 via paypal. i used the $5 to get a .com domain (special offer on godaddy). the domain was for my web design portfolio, and that's how i got started. |
ask hn: what was the easiest buck you've made on the web in 2014?
| there was an article on digg.com about google becoming a worse search engine. the article was on news.yahoo.comsomeone commented "5 dollars to someone who points out the irony in this", i replied. the guy sent me $5 via paypal. i used the $5 to get a .com domain (special offer on godaddy). the domain was for my web design portfolio, and that's how i got started. | <link> |
ask hn: what was the easiest buck you've made on the web in 2014?
| <link> | $1,100 a month from my udemy course: <link> i got it it up and did the first little bit of marketing, it's been literally no work. maybe 30-45 min a month answering questions, but i wouldn't consider that work. :) |
ask hn: what was the easiest buck you've made on the web in 2014?
| $1,100 a month from my udemy course: <link> i got it it up and did the first little bit of marketing, it's been literally no work. maybe 30-45 min a month answering questions, but i wouldn't consider that work. :) | i put together what i think is a decent game on the ipad a little while back[1]. in 2014 i think it made me about a buck[2]. putting something up in the app store can be a good source of passive income, but don't recommend it if you are looking for more than a buck.[1] <link>
[2] if you don't count the $100/yr developer fees |
how to stop time
| the quality of discussion about procrastination is shockingly low. try telling people you're reading a book on procrastination, and some joker will say, "ha! ironic, right? get it?" and everyone will chuckle good-naturedly at the thought of someone procrastinating by reading a book on procrastination.no one stops to examine why we should assume someone reading a book is shirking their duties. even watching a youtube video is not inherently an act of procrastination. if anything, our culture has an epidemic of people not being able to relax without being filled with guilt and shame over their momentary lack of productivity. | also a good read on the subject <link> |
how to stop time
| also a good read on the subject <link> | age and the accompanying experience have started to bring me introspection and retrospection, and from these i've realized opportunities i've missed out on because i didn't do something earlier that i could/should have. |
how to stop time
| age and the accompanying experience have started to bring me introspection and retrospection, and from these i've realized opportunities i've missed out on because i didn't do something earlier that i could/should have. | as i've matured and grown in my technology career, i've found procrastination pays enormous dividends with only small drawbacks.procrastination pushes you to wait to do a task until you find the optimal amount of time you know you need left, while doing it in the most relevant environment.for example, if i code or design something to early it is more likely that research, marketing or product direction could have changed, causing a percentage or all of my work to become moot.however, if i wait to do my work until i know i have just enough time left, i find my work is the most relevant and least likely to require changes of substance due to shifts of other parties.i whole heartedly advocate for procrastination due to this. its a beneficial decision making response that we should stop fighting. |
how to stop time
| as i've matured and grown in my technology career, i've found procrastination pays enormous dividends with only small drawbacks.procrastination pushes you to wait to do a task until you find the optimal amount of time you know you need left, while doing it in the most relevant environment.for example, if i code or design something to early it is more likely that research, marketing or product direction could have changed, causing a percentage or all of my work to become moot.however, if i wait to do my work until i know i have just enough time left, i find my work is the most relevant and least likely to require changes of substance due to shifts of other parties.i whole heartedly advocate for procrastination due to this. its a beneficial decision making response that we should stop fighting. | simply not doing what one is specifically "tasked to do" does not necessarily represent procrastination. it may be not be a direct route to one's specific end; however, it's important to recognize that sometimes on the journey from side to side, one learns, finds, or imagines a new way to move forward.
the internet simply provides new ways (which society moves to chastise and to ascribe blame) to wander off the beaten path. i find that when my internet clicking and surfing become as wayward as a three year old following a butterfly in flight, usually i come away having learned something unexpected or something i didn't know i wanted to know, in both cases, of value. do i think people spend/waste a lot of time watching random fart contests and people acting the fool? well sure. but, let's not throw the baby out with the bathwater. the benefit of online "procrastination" in many cases is significant. |
songdo, south korea: city of the future?
| songdo has been plagued by poor planning from the start. the gov't contracted gale international, a company with no previous international experience, to manage the project and posco, a korean company whose work was not considered in the top 3 best lf korean contractors at the time.consider, an american company from boston is put in charge to manage, fund, and (formerly) profit from building a world class city with questionable demand over the course of 15 years (financial crisis anyone?) while partnering with a mediocre contractor in the mud flats of korea (ruining natural bird habitats along the way).poor logic and planning has contributed to the low population and overall eery feeling of the city. | >there are even small plots of land for urban farming, many of which were given to songdo's former fishermen as reparation for the destruction of their fisheries.i really wish this was less of a puff-piece for the "city of the future" songdo (tm) and looked more into how land was acquired, who owns the rights to land and property, who pays for things, how much does it cost to live there now, etc. it has a skeptical tone but it fails to address any of the real questions people might have about living there or its history.if it's so empty, why hasn't it been filled up by people looking for low-cost housing? (if the supply is high, <fill in armchair economics here>)there are few cities with this level of infrastructure planning springing up in the west as far as i know. lots of people are pointing to empty cities in nk, china, and the uae but lack of coverage there can be explained by their hostility to free journalism. are sk voices just as restricted? |
songdo, south korea: city of the future?
| >there are even small plots of land for urban farming, many of which were given to songdo's former fishermen as reparation for the destruction of their fisheries.i really wish this was less of a puff-piece for the "city of the future" songdo (tm) and looked more into how land was acquired, who owns the rights to land and property, who pays for things, how much does it cost to live there now, etc. it has a skeptical tone but it fails to address any of the real questions people might have about living there or its history.if it's so empty, why hasn't it been filled up by people looking for low-cost housing? (if the supply is high, <fill in armchair economics here>)there are few cities with this level of infrastructure planning springing up in the west as far as i know. lots of people are pointing to empty cities in nk, china, and the uae but lack of coverage there can be explained by their hostility to free journalism. are sk voices just as restricted? | i'd like to see a smart city with grand infrastructure (subways designed ahead of time, the garbage system outlined in this article, etc) but designed on a human scale.that is, not bulked out by endless roads and parking allowances. there are many charming and walkable cities around the world but so often these "designed" cities are created on the scale of cars and end up feeling so wrong.if you need service roads and parking, hide them underground perhaps.images of houston are often used to demonstrate the sprawl you get from giving way to the convenience of cars and parking: <link> |
songdo, south korea: city of the future?
| i'd like to see a smart city with grand infrastructure (subways designed ahead of time, the garbage system outlined in this article, etc) but designed on a human scale.that is, not bulked out by endless roads and parking allowances. there are many charming and walkable cities around the world but so often these "designed" cities are created on the scale of cars and end up feeling so wrong.if you need service roads and parking, hide them underground perhaps.images of houston are often used to demonstrate the sprawl you get from giving way to the convenience of cars and parking: <link> | photos look a bit like minsk by the river northwards from centre, the combination of high rises, park and river.of course more modern and with even higher buildings.it's a nice look but not very comfortable for living. taking a walk across the street might take fifteen minutes. |
songdo, south korea: city of the future?
| photos look a bit like minsk by the river northwards from centre, the combination of high rises, park and river.of course more modern and with even higher buildings.it's a nice look but not very comfortable for living. taking a walk across the street might take fifteen minutes. | i almost wish all cities were built like this, all at once and never incremented (though i'm sure construction will continue after the city is "done").it would be great to see different trends in design and architecture splayed out across a list of cities. |
irobot roomba serial command interface specification [pdf]
| i was going to crack a "roombaduino in 3..2..1.." joke but it turns out there is already a library for this: <link> (-: | their competition neato has, in my opinion, a more interesting platform to hack on, mostly due to the fact that the device has a lidar sensor on top.<link>
<link> |
irobot roomba serial command interface specification [pdf]
| their competition neato has, in my opinion, a more interesting platform to hack on, mostly due to the fact that the device has a lidar sensor on top.<link>
<link> | <link> i wrote one a while back as well, if you are using .net |
irobot roomba serial command interface specification [pdf]
| <link> i wrote one a while back as well, if you are using .net | the cool kids are all using <link> |
irobot roomba serial command interface specification [pdf]
| the cool kids are all using <link> | having worked with roomba sci a while back, a few things come to mind. first is a lack of integrity checking. the default baud rate of 57600 is too high (at least for the 6-ft mini-din cables we could find), and it's really annoying when your roomba goes careening off in a weird direction because your command got corrupted. thankfully the baud rate can be reduced, but there really ought to be something in the next layer to check integrity, as the roomba firmware is a black box.also, it's kinda obvious in retrospect, but roombas were not designed to drive in straight lines. which can be annoying if you want to use them as a robotics platform. |
show hn: simple logger and debugger for go programs
| does this only output to stdout? it would be useful if it took an io.writer so you could write to a file or something else, too. | i've been trying to find a small logger program for go and haven't had time to write my own. looks great and may start using it :)the one minor issue is there is a syntax error in the readme. should be import "github.com/apsdehal/go-logger", not "go get github.com/apsdehal/go-logger" |
show hn: simple logger and debugger for go programs
| i've been trying to find a small logger program for go and haven't had time to write my own. looks great and may start using it :)the one minor issue is there is a syntax error in the readme. should be import "github.com/apsdehal/go-logger", not "go get github.com/apsdehal/go-logger" | a wise gopher would use rob pikes glog package instead <link> |
show hn: simple logger and debugger for go programs
| a wise gopher would use rob pikes glog package instead <link> | this looks interesting - i'll take a closer look.you might want to check out the logrus package - which i'm using and pretty happy with. <link> lets you add structured k,v fields so you do have to mess around with fmt and also has hooks to support things like sending logs to syslog or remote exception handling services. |
show hn: simple logger and debugger for go programs
| this looks interesting - i'll take a closer look.you might want to check out the logrus package - which i'm using and pretty happy with. <link> lets you add structured k,v fields so you do have to mess around with fmt and also has hooks to support things like sending logs to syslog or remote exception handling services. | colorized output by default will make for messy logs that can't be used. sure you can turn it off (with an integer, why not a bool?), but that shouldn't be something compiled in your program. also there are no means to `printf` strings from the logger.finally, there are already a plethora of loggers for go. i'd recommend logrus for structured logs:<link> glog otherwise.and a note: a logger isn't a debugger. gdb is a debugger for go, see <link> if i come across as heartless, it's nice to see new people coming to go. but i don't think this is novel or news worthy. |
the beale ciphers
| i learned about the beale ciphers in the 80s and wrote a simple program to try deciphering ciphers one and three using a given key text. i think it's probably a hoax, but the codes are fun to play around with. | here's a blog entry describing some small investigations into the beale ciphers, which revealed a few surprises (for me at least): <link> |
the beale ciphers
| here's a blog entry describing some small investigations into the beale ciphers, which revealed a few surprises (for me at least): <link> | also: <link> |
the beale ciphers
| also: <link> | i grew up in roanoke county, neighboring bedford. we had books that mentioned this treasure, and i've always harbored a dream of deciphering the text then casually buying the property where the treasure is. if it's not a hoax maybe i can spin up some aws instances and get cracking :) |
the beale ciphers
| i grew up in roanoke county, neighboring bedford. we had books that mentioned this treasure, and i've always harbored a dream of deciphering the text then casually buying the property where the treasure is. if it's not a hoax maybe i can spin up some aws instances and get cracking :) | had to double take at reading robert morriss (surely no relation..surely)> beale entrusted a box containing the encrypted messages to a local innkeeper named robert morrissif it's just an unknown one time pad we're looking for, this is pretty damning:> if the declaration of independence is used as a key for the first cipher, it yields alphabetical sequences such as abfdefghiijklmmnohpp and others |
writing a simple operating system from scratch (2010) [pdf]
| i highly recommend everyone to go through the book <link> before, or as a complementary direction to, diving into any "operating system" resources mentioned on this page. (you could try this on a qemu/vmware/virtualbox/kvm/whatever instance instead of risking your current hard-drive partition setup).(alert: it's not really a book, it's a project: to compile and install linux without using any distro! the whole process could take somewhere from 1 day to 1 week, depending on the speed of your machine and your command-line skills.)because then you would discover (if you haven't already) that what all these people call "operating system" is essentially only a nucleus of the operating system (kernel) and that there is much more to an operating system than whatever is discussed in an os class.also lfs is enlightening in ways i may not have expressed here. if you successfully go through the process, your first thought might be to roll your own linux distro! | by far one of the most satisfactory things (and also hair reducing things) i've had as a long term hobby is: o/s development. been doing it seriously for just over a year now, it's slow because it is purely free time. was working happily on the kernel but decided to go back and build a bootloader after i got to higher half kernel and was messing around with the gdt base address overflow hack. it's now turned into a multi-stage boot loader, because i appreciate the idea of your system have full control over your own partition, nothing else.i enjoy going to <link> for a broad overview and then hitting the manuals for the details; sometimes that manual and note book session can take up to 3 days of my free time haha.i especially love writing custom tools around the development process; i like to call it reducing reliance - i found that this really helps solidify concepts in my mind; although making the process even slower, i feel comfortable at every stage. |
writing a simple operating system from scratch (2010) [pdf]
| by far one of the most satisfactory things (and also hair reducing things) i've had as a long term hobby is: o/s development. been doing it seriously for just over a year now, it's slow because it is purely free time. was working happily on the kernel but decided to go back and build a bootloader after i got to higher half kernel and was messing around with the gdt base address overflow hack. it's now turned into a multi-stage boot loader, because i appreciate the idea of your system have full control over your own partition, nothing else.i enjoy going to <link> for a broad overview and then hitting the manuals for the details; sometimes that manual and note book session can take up to 3 days of my free time haha.i especially love writing custom tools around the development process; i like to call it reducing reliance - i found that this really helps solidify concepts in my mind; although making the process even slower, i feel comfortable at every stage. | for those that really want to build everything from scratch, including hardware, niklaus wirth has revised his project oberon book, including the verilog files<link> you could have your own graphical workstation. :) |
writing a simple operating system from scratch (2010) [pdf]
| for those that really want to build everything from scratch, including hardware, niklaus wirth has revised his project oberon book, including the verilog files<link> you could have your own graphical workstation. :) | if you're interested in this type of stuff i can personally recommend mit's 6.828 course (operating systems engineering) as an additional resource. specifically, you'll want to take a look at xv6, a teaching os implemented for the course (<link> the os is small enough to print as cross referenced code listing (<link> and has a book that fully explains each piece (<link> you are only 9,000 lines of code away from fully understanding basic operating systems concepts!it's been a few years since i took the class but it was an absolute blast. the offering in 2011 has recorded lecture videos (<link> |
writing a simple operating system from scratch (2010) [pdf]
| if you're interested in this type of stuff i can personally recommend mit's 6.828 course (operating systems engineering) as an additional resource. specifically, you'll want to take a look at xv6, a teaching os implemented for the course (<link> the os is small enough to print as cross referenced code listing (<link> and has a book that fully explains each piece (<link> you are only 9,000 lines of code away from fully understanding basic operating systems concepts!it's been a few years since i took the class but it was an absolute blast. the offering in 2011 has recorded lecture videos (<link> | there's also the tried and true lions' commentary on unix 6th edition with source code pdf floating around to understand what's going on in the workings of a timesharing os.nickolai zeldovich a current mit professor wrote histar os from scratch and it's source is still available online to view how a minimally trusted system could work <link> |
hong kong protest: why are pro-democracy supporters staging a sit-in?
| all this "article" says is that hong kong protesters are using two hashtags on twitter, while giving no further information on the nature or purpose of the protests.much better to read the linked independent piece: <link> | honest question: how effective are these sorts of protests in achieving their intended goals?maybe i'm suffering from confirmation bias, but it seems all the major demonstrations in the last few decades (tiananmen square, iraq war, occupy wall street, post-iranian election, etc) have sizzled out and failed. the one exception i can think of is the anti-proposition 8 protests, but prop 8 was defeated in the courts through routine legal channels (ultimately culminating in the supreme court decision on hollingsworth v. perry) and it's unclear whether the protests held any sway over the rulings. |
hong kong protest: why are pro-democracy supporters staging a sit-in?
| honest question: how effective are these sorts of protests in achieving their intended goals?maybe i'm suffering from confirmation bias, but it seems all the major demonstrations in the last few decades (tiananmen square, iraq war, occupy wall street, post-iranian election, etc) have sizzled out and failed. the one exception i can think of is the anti-proposition 8 protests, but prop 8 was defeated in the courts through routine legal channels (ultimately culminating in the supreme court decision on hollingsworth v. perry) and it's unclear whether the protests held any sway over the rulings. | hongkonger here. i help out with a number of volunteer tech groups in hk, including a few resistance groups. i'm also on the hong kong python user group committee.we are hoping for the best but would like to prepare for the worst, so i'd like to ask fellow hners here who have been in similar situations before: what can we expect to encounter in terms of disruptions in communications? under those situations, how can we counter them with technology? there were rumors that cell towers in certain areas would be shut down, which i don't think happened. the cell network slowdown was more like overloaded cell towers to me. we tried firechat yesterday and it's terrible. with 100s of people on the same room, it's impossible to follow the feed. it's also very easy to be taken over by ccp spies who just won't stop polluting the room. is there anything you'd recommend?thanks hners in advance.updated resources on the situations on the ground:<link> |
hong kong protest: why are pro-democracy supporters staging a sit-in?
| hongkonger here. i help out with a number of volunteer tech groups in hk, including a few resistance groups. i'm also on the hong kong python user group committee.we are hoping for the best but would like to prepare for the worst, so i'd like to ask fellow hners here who have been in similar situations before: what can we expect to encounter in terms of disruptions in communications? under those situations, how can we counter them with technology? there were rumors that cell towers in certain areas would be shut down, which i don't think happened. the cell network slowdown was more like overloaded cell towers to me. we tried firechat yesterday and it's terrible. with 100s of people on the same room, it's impossible to follow the feed. it's also very easy to be taken over by ccp spies who just won't stop polluting the room. is there anything you'd recommend?thanks hners in advance.updated resources on the situations on the ground:<link> | hongkonger here also (now going to out to see the latest situation)for those who want a tldr: <link> of protesters are just teenagers/students who want a peaceful protest , and the crazy police are fully armed and used countless tear gas on them.this is going to be one of the largest events in hk history. |
hong kong protest: why are pro-democracy supporters staging a sit-in?
| hongkonger here also (now going to out to see the latest situation)for those who want a tldr: <link> of protesters are just teenagers/students who want a peaceful protest , and the crazy police are fully armed and used countless tear gas on them.this is going to be one of the largest events in hk history. | i'm from chinese mainland, a student at shanghai.there is not even a piece of information about this leaked to the mainstream media. many of my classmates managed to get information from multiple sources but more have no idea what happened.it's quite strange that the blocking turns a political event into a technical one.i'm not a 100% supporter for the protest, but i extremely dislike the government's passion of blocking everying. it makes me feel hopeless in the country knowing more and more interesting things are becoming far away from us. |
fans raise cash to help phone phreaker john draper, aka cap‘n crunch
| the qikfunder project was previously in the top five on then hn front page but even though it was well voted, got buried after an hour or so.not sure why, but glad the ars page is now on. | i hope he is considering fecal transplant for his c.diff infection. |
fans raise cash to help phone phreaker john draper, aka cap‘n crunch
| i hope he is considering fecal transplant for his c.diff infection. | he joined my cards against humanity game in burger king a couple years ago at defcon. definitely an interesting guy... he had lots of stories and was pretty open about everything. |
fans raise cash to help phone phreaker john draper, aka cap‘n crunch
| he joined my cards against humanity game in burger king a couple years ago at defcon. definitely an interesting guy... he had lots of stories and was pretty open about everything. | " draper himself doesn't even know who started the fundraiser, but the money is intended to help with his medical bills"if he doesn't know who started it, how do we know the money will actually get to him? |
fans raise cash to help phone phreaker john draper, aka cap‘n crunch
| " draper himself doesn't even know who started the fundraiser, but the money is intended to help with his medical bills"if he doesn't know who started it, how do we know the money will actually get to him? | for those interested he's currently doing an ama on reddit.<link> |
amazon mobile analytics
| wow! considering that mixpanel charges $2000 for 20mm data points, this is awesome. love how the cost of starting up just keeps getting lower and lower. :)also, i understand that amazon includes 'system events' in their free tier. even with this included, at an average of 15 custom events + 5 system events, you can have 5mm sessions a month for free. this is more than enough for bootstrapped companies/projects to start and grow with.i'm not sure who the customers for these analytics companies are (small projects that grow with them vs big projects that join them) but if it is the latter, well amazon is def. the better choice. although they do not offer any complex funnels/segmentation, i am sure this and other features will be added in the future.thinking about peter thiel's monopoly vs competition eating profits (zero to one, awesome book!), i wonder if and how players in this space will be able to differentiate themselves enough to really have a competitive advantage over one another. | "1st party" analytics on android is a bit weird at the moment. since google analytics for mobile requires google play services - you can't use it in for installations on amazon fire devices. of course there are third party services (crashlytics, mixpanel, etc), but it's just interesting to see amazon and google essentially forced to build their own versions of each other's services to compete on android. |
amazon mobile analytics
| "1st party" analytics on android is a bit weird at the moment. since google analytics for mobile requires google play services - you can't use it in for installations on amazon fire devices. of course there are third party services (crashlytics, mixpanel, etc), but it's just interesting to see amazon and google essentially forced to build their own versions of each other's services to compete on android. | mobile analytics is relatively new amazon offering. seems follow their typical approach, start with low prices with small number of features and build new ones.amazon unlikely will be the best solution (e.g. i bet mixpanel will be significantly better for at least next few years), but they may cover a lot of typical use cases. that will commoditize the user event analytics and put pressure on the other companies. |
amazon mobile analytics
| mobile analytics is relatively new amazon offering. seems follow their typical approach, start with low prices with small number of features and build new ones.amazon unlikely will be the best solution (e.g. i bet mixpanel will be significantly better for at least next few years), but they may cover a lot of typical use cases. that will commoditize the user event analytics and put pressure on the other companies. | (disclaimer: i'm a founder at heap. we build mobile analytics, so i'm far from impartial.)amazon's main purpose in building an analytics tool is to drive spend to the amazon app store. if you can't measure the roi of their app store, you can't devote more resources to it.this applies to just about all the big tech companies and their respective distribution platforms: google with adwords, facebook with mobile ads, and apple with the ios app store. lots of dollars flow through these platforms, and amazon/facebook/apple don't want their developers measuring those dollars with a hostile competitor's analytics offering. (often, the hostile competitor they have in mind is google.)you'll notice this in the screenshots for amazon's mobile analytics. on the overview page, note the breakdown of "lifetime value per user". there are separate figures for ios users, android users, and...fire os users. a line item for "fire ios users" would never be so prominent in google or apple's analytics (or even present).thus, amazon et al. focus on making their own analytics tools good at measuring acquisition (prioritizing their own channels) and some high-level metrics. digging into the data is much less of a priority. even basic questions - "what's the conversion rate for my signup flow?", "what are the email addresses of my active users?", "what percent of my revenue comes from repeat visits?" - require you to use a different tool.bigger companies are aware of this feature gap and happy to pay the price premium. but startups are (appropriately) more price-sensitive, even though a solid investment in growth/analytics is arguably more important for startups.i'd love to hear hn's feedback on how heap (and other analytics companies) can structure their pricing to better accommodate small companies. |
amazon mobile analytics
| (disclaimer: i'm a founder at heap. we build mobile analytics, so i'm far from impartial.)amazon's main purpose in building an analytics tool is to drive spend to the amazon app store. if you can't measure the roi of their app store, you can't devote more resources to it.this applies to just about all the big tech companies and their respective distribution platforms: google with adwords, facebook with mobile ads, and apple with the ios app store. lots of dollars flow through these platforms, and amazon/facebook/apple don't want their developers measuring those dollars with a hostile competitor's analytics offering. (often, the hostile competitor they have in mind is google.)you'll notice this in the screenshots for amazon's mobile analytics. on the overview page, note the breakdown of "lifetime value per user". there are separate figures for ios users, android users, and...fire os users. a line item for "fire ios users" would never be so prominent in google or apple's analytics (or even present).thus, amazon et al. focus on making their own analytics tools good at measuring acquisition (prioritizing their own channels) and some high-level metrics. digging into the data is much less of a priority. even basic questions - "what's the conversion rate for my signup flow?", "what are the email addresses of my active users?", "what percent of my revenue comes from repeat visits?" - require you to use a different tool.bigger companies are aware of this feature gap and happy to pay the price premium. but startups are (appropriately) more price-sensitive, even though a solid investment in growth/analytics is arguably more important for startups.i'd love to hear hn's feedback on how heap (and other analytics companies) can structure their pricing to better accommodate small companies. | disclosure: i am the co-founder of mixpanelthis is far more of a competitor to google analytics instead of us. google analytics gives away their product for free - by that measure this is expensive!though biased, i wanted to point out a few things since this isn't as amazing as one might think -- it comes with several gotchas (and please correct me if i am wrong):- systems events will take up a large portion of this free tier and the paid tiers. start and end events are going to put reasonably sized apps into the billions.- if you manage to get rid of said system events, big parts of the dashboard are likely to be rendered useless like dau, mau, retention, etc.- you cannot deeply segment any of this information so you will have a lot of questions remaining even just the next day- it will be difficult to offer funnel analysis (which doesn't exist) that is retroactive at that scale. that means you will get the same kind of funnel that people hate with google analytics' goals.- generally speaking: complexity of analysis will mean higher priceswhile mixpanel pricing may seem expensive by comparison, the products are not comparable. you get what you pay for in the level of sophisticated analysis.given that, over time it is our plan to lower prices relative to the rate that hardware and infrastructure becomes less expensive. we think that's fair. and if we can improve our technology to become more efficient we most certainly want to make our software and products more accessible.we are very open to your thoughts so please be harsh and candid (as i know hn can be). we deeply care about our startup customers who made and pushed us into who we are today. |
swi-prolog for the semantic web
| the opening paragraph is structurally identical to "buy our nuclear power plant, it'll generate a billion terawatts, oh and it also comes with this bike shed". prolog (the submission says) handles the gruesome problem of dealing with rdf, oh and it also generates html pages and json!that pattern's a red flag whenever i see it. like an ostensible proof of p!=np that begins with a 30 page history written for laymen. who is that paragraph aimed at? is there really a sizeable population casually using rdf and prolog but losing sleep over html and json? | there is also a really interesting biomedical toolkit for swi-prolog, which if iirc uses or integrates with the semantic capabilities (for ontologies etc), although it was a while since i looked at it, so might recall wrong:* blipkit - biomedical logic programming : <link> |
swi-prolog for the semantic web
| there is also a really interesting biomedical toolkit for swi-prolog, which if iirc uses or integrates with the semantic capabilities (for ontologies etc), although it was a while since i looked at it, so might recall wrong:* blipkit - biomedical logic programming : <link> | for anyone interested, i did my masters thesis on swi-prolog as a semantic querying tool, integrating it with the eclipse rcp platform (bioclipse.net in particular), and compared its querying performance with java based jena sparql parser for some typical tasks in cheminformatics.the title was "swi-prolog as a semantic web tool for semantic querying in bioclipse: integration and performance benchmarking", and it is available for download here: <link> this particular task, swi-prolog totally knocked out jena, and it was also more amenable to some heuristic optimiziations, where we the running time really became infinitesimal in comparison to other tools. |
swi-prolog for the semantic web
| for anyone interested, i did my masters thesis on swi-prolog as a semantic querying tool, integrating it with the eclipse rcp platform (bioclipse.net in particular), and compared its querying performance with java based jena sparql parser for some typical tasks in cheminformatics.the title was "swi-prolog as a semantic web tool for semantic querying in bioclipse: integration and performance benchmarking", and it is available for download here: <link> this particular task, swi-prolog totally knocked out jena, and it was also more amenable to some heuristic optimiziations, where we the running time really became infinitesimal in comparison to other tools. | how does the closed world assumption of prolog (if it's not explicitly specified it is assumed false) mesh with the open world assumption (if it is not explicitly specified it is unknown) of rdf? |
swi-prolog for the semantic web
| how does the closed world assumption of prolog (if it's not explicitly specified it is assumed false) mesh with the open world assumption (if it is not explicitly specified it is unknown) of rdf? | i used to use the swi-prolog semantic web tools heavily. very good stuff.the cleopatria semantic web server is interesting, but i have just played with it. the core rdf storage and inference get libraries were solid and nice to use. |
mailgun downtime resulting from rackspace cloud server reboots
| expect this to happen on more services, too. rackspace customer are reporting uncontrollable downtimes (because the physical hardware is down) ranging from "a few minutes" to "six hours." search twitter for [rackspace reboot].also, since rackspace didn't communicate it that effectively: if you're on their first-gen infrastructure (your servers have an asterix next to them in the list), you won't get rebooted. i had to hear this from a fellow customer who heard it from support, as i was searching my inbox frantically wondering why they hadn't given me a heads-up about an incoming-any-minute-now reboot yet. | i got bit by this over this weekend, too. i received the initial email september 27 @ 1:35 am local time. i called rackspace to see if they would be sending out emails prior to each vps being rebooted 30 minutes or so before just as a heads up for human monitoring purposes. the representative told me that it "was not feasible" for them to do that for every vps. instead... i've been camped by my computer all of today (sunday) to monitor the reboots since i have servers at dfw & ord and they have a 24 hour time window for those regions.while their status page was somewhat helpful, i find it absolutely absurd that they can only update it once every 60 minutes to cue customers in. in addition, their cloud control panel doesn't reflect the reboots. when a vps goes down for a reboot... the cp shows the server as "active - online and functioning as properly". thankfully great third party monitoring services (using scout) exist so they can notify in-place of rackspace's incompetency.as someone who shells out a significant amount of money to them each month, this is pretty disheartening. that being said... i seem to have survived the great rackspace reboot of 2014 and can only hope they handle the next event better. |
mailgun downtime resulting from rackspace cloud server reboots
| i got bit by this over this weekend, too. i received the initial email september 27 @ 1:35 am local time. i called rackspace to see if they would be sending out emails prior to each vps being rebooted 30 minutes or so before just as a heads up for human monitoring purposes. the representative told me that it "was not feasible" for them to do that for every vps. instead... i've been camped by my computer all of today (sunday) to monitor the reboots since i have servers at dfw & ord and they have a 24 hour time window for those regions.while their status page was somewhat helpful, i find it absolutely absurd that they can only update it once every 60 minutes to cue customers in. in addition, their cloud control panel doesn't reflect the reboots. when a vps goes down for a reboot... the cp shows the server as "active - online and functioning as properly". thankfully great third party monitoring services (using scout) exist so they can notify in-place of rackspace's incompetency.as someone who shells out a significant amount of money to them each month, this is pretty disheartening. that being said... i seem to have survived the great rackspace reboot of 2014 and can only hope they handle the next event better. | we're a mg user via heroku.our heroku mg logs indicate that all messages are getting "delivered", but that doesn't match reality. we've been testing with our own accounts -- ones that receive copies of all automated emails, as well as our personal accounts.the heroku mg logs says "delivered" for all the emails.... but using 4 different addresses across 4 different carriers confirms: a vast number of emails (since noon today) were not actually delivered. the only change in configuration: mg's downtime. i seriously hope all of these "delivered" emails are re-sent. if someone from mg could weigh in, that would be fantastic! (we have a ticket filed, but email also in profile). |
mailgun downtime resulting from rackspace cloud server reboots
| we're a mg user via heroku.our heroku mg logs indicate that all messages are getting "delivered", but that doesn't match reality. we've been testing with our own accounts -- ones that receive copies of all automated emails, as well as our personal accounts.the heroku mg logs says "delivered" for all the emails.... but using 4 different addresses across 4 different carriers confirms: a vast number of emails (since noon today) were not actually delivered. the only change in configuration: mg's downtime. i seriously hope all of these "delivered" emails are re-sent. if someone from mg could weigh in, that would be fantastic! (we have a ticket filed, but email also in profile). | i don't get it. if a server restarts, don't you just get a different one? why is that disruptive?at work every machine reboots at least every month. everything is designed to cope with that reality. |
mailgun downtime resulting from rackspace cloud server reboots
| i don't get it. if a server restarts, don't you just get a different one? why is that disruptive?at work every machine reboots at least every month. everything is designed to cope with that reality. | mailgunner here: usually we just redirect traffic from one environment to another, but this time we are having unexpected networking issues that are preventing us from that. we are still debugging the issue, stay tuned on status.mailgun.com |
with new ad platform, facebook opens gates to its vault of user data
| i still think the primary problem is that facebook does not understand intent and so it will still be a 2nd class citizen compared to google. | i created a secondary account only to handle our pharmacy's facebook page to promote our brick and stones shop. there's no eshop yet, so i tried to run ads (spend about 30 eur so far), but the targeting is awfully off the mark. i didn't spam any of my friends, tried just to use ads. results are lousy. i targeted a specific greek city, surrounding areas and specific ages and all i get are 'likes' from people in other cities, which have zero value to me at the moment. so in a sense i'm just waisting money.i don't know if this new system will be available for small shops, but the current system for narrow areas (> 50k inhabitants) doesn't seem to work properly. |
with new ad platform, facebook opens gates to its vault of user data
| i created a secondary account only to handle our pharmacy's facebook page to promote our brick and stones shop. there's no eshop yet, so i tried to run ads (spend about 30 eur so far), but the targeting is awfully off the mark. i didn't spam any of my friends, tried just to use ads. results are lousy. i targeted a specific greek city, surrounding areas and specific ages and all i get are 'likes' from people in other cities, which have zero value to me at the moment. so in a sense i'm just waisting money.i don't know if this new system will be available for small shops, but the current system for narrow areas (> 50k inhabitants) doesn't seem to work properly. | people have always asked for a solid google adsense competitor. maybe this will be it. though looks like it's not wide open yet, publishers have to apply/ be certified: <link> you could imagine this being pretty massive. |
with new ad platform, facebook opens gates to its vault of user data
| people have always asked for a solid google adsense competitor. maybe this will be it. though looks like it's not wide open yet, publishers have to apply/ be certified: <link> you could imagine this being pretty massive. | if you thought that retargeting was bad because you saw the same advertisements for the same things no matter where you were, you haven't seen anything yet. |
with new ad platform, facebook opens gates to its vault of user data
| if you thought that retargeting was bad because you saw the same advertisements for the same things no matter where you were, you haven't seen anything yet. | i think the thing that frustrates me the most about all of this is not the privacy, but the fact that facebook gets exclusive access to data that i think is rightfully public knowledge. i'm fine with advertisers knowing that i really enjoy hiking, what my salary is, etc., but i don't like that they have to go through facebook to get that knowledge. ideally, they would go through me, or even better some publicly available repository of data that i've allowed to be assembled.but there is also data that i may not want to be public knowledge. if facebook scans my chat logs, then facebook knows a lot about me that i would not want some of my friends and family knowing. and i wouldn't be surprised if their tos permits them to scan my chat logs.and you can also do interesting oracle attacks with this. let's say i'm trying to figure out if my son is homosexual. (substitute for any fact facebook may know, and for any person you want to investigate). i already know a ton of things about my son. age, where he lives, what sports he plays, his favorite foods, etc. so i create one really specific ad that's guaranteed to include only my son and maybe a few other people. this one is only shown to homosexuals. then i create an alternate ad that targets the same group, but only heterosexuals. then i just need to watch which ad appears on my sons computer, and i suddenly know what facebook thinks his sexual orientation is. |
a desktop for the web
hello everyone,<p>after lots of month of work we are very proud and excited to share with everyone the preview of ahomé desk: our web desktop platform. this is the beginning of an incredible journey for our small start up and we welcome you all to help us by giving some feedback and helping us build a better web.<p>as this is a preview release please expect some bugs. we hope the application is still good enough to show where we are heading with the project.<p>the main idea behind the ahomé desk can be found in our blog:
<link><p>to play around with the desktop please visit :
<link><p>cheers | > "because the ahomé desk client is a pure html5/js/css solution, it is totally transparent to any server runtime. from java to ruby on rails, from php to .net our client can run everywhere. "how will the client be licensed? | feedback - <link> * the white text in the upper right is a bit hard to read, due to the different contrast in parts of the background. one idea is to use a semi-transparent background color to provide more / equaler contrast.
* your logo doesn't take me to your main site (ahome-it.com), nor is there any way else to get there from this page.
* your copyright text has a link to nowhere. remove it, or show me some more info.
* it'd be nice to demo without creating an account...
i had some other thoughts on your main site, and haven't played around with the demo yet. i hope to be able to tomorrow, but in the event that i can't- best of luck!just btw- no news is good news. i really like the layout and background image of your demo page, and you did many things right with your main site. since a pat on the back is less helpful than constructive criticism, unless you did something exceptionally well i usually don't mention the good things. |
a desktop for the web
hello everyone,<p>after lots of month of work we are very proud and excited to share with everyone the preview of ahomé desk: our web desktop platform. this is the beginning of an incredible journey for our small start up and we welcome you all to help us by giving some feedback and helping us build a better web.<p>as this is a preview release please expect some bugs. we hope the application is still good enough to show where we are heading with the project.<p>the main idea behind the ahomé desk can be found in our blog:
<link><p>to play around with the desktop please visit :
<link><p>cheers | feedback - <link> * the white text in the upper right is a bit hard to read, due to the different contrast in parts of the background. one idea is to use a semi-transparent background color to provide more / equaler contrast.
* your logo doesn't take me to your main site (ahome-it.com), nor is there any way else to get there from this page.
* your copyright text has a link to nowhere. remove it, or show me some more info.
* it'd be nice to demo without creating an account...
i had some other thoughts on your main site, and haven't played around with the demo yet. i hope to be able to tomorrow, but in the event that i can't- best of luck!just btw- no news is good news. i really like the layout and background image of your demo page, and you did many things right with your main site. since a pat on the back is less helpful than constructive criticism, unless you did something exceptionally well i usually don't mention the good things. | it's cool. i think it's implemented with extjs.but please, please no bootstrap 2 on the home page :(i'm really fed up with that blue bs2 button. it's everywhere. i fully understand, you're creating a mvp here so you shouldn't waste time with other things. but at least, you can download a bs3 theme [here](<link> instead of a classic bootstrap theme. therefore, it would be kind of different than other sites. |
a desktop for the web
hello everyone,<p>after lots of month of work we are very proud and excited to share with everyone the preview of ahomé desk: our web desktop platform. this is the beginning of an incredible journey for our small start up and we welcome you all to help us by giving some feedback and helping us build a better web.<p>as this is a preview release please expect some bugs. we hope the application is still good enough to show where we are heading with the project.<p>the main idea behind the ahomé desk can be found in our blog:
<link><p>to play around with the desktop please visit :
<link><p>cheers | it's cool. i think it's implemented with extjs.but please, please no bootstrap 2 on the home page :(i'm really fed up with that blue bs2 button. it's everywhere. i fully understand, you're creating a mvp here so you shouldn't waste time with other things. but at least, you can download a bs3 theme [here](<link> instead of a classic bootstrap theme. therefore, it would be kind of different than other sites. | your logo / text is behind the login box, which is unfortunate. we can't read it and it's not very pretty. :( |
a desktop for the web
hello everyone,<p>after lots of month of work we are very proud and excited to share with everyone the preview of ahomé desk: our web desktop platform. this is the beginning of an incredible journey for our small start up and we welcome you all to help us by giving some feedback and helping us build a better web.<p>as this is a preview release please expect some bugs. we hope the application is still good enough to show where we are heading with the project.<p>the main idea behind the ahomé desk can be found in our blog:
<link><p>to play around with the desktop please visit :
<link><p>cheers | your logo / text is behind the login box, which is unfortunate. we can't read it and it's not very pretty. :( | under firefox, at 1024x: <link> an alert box pops up with "undefined, " then nothing loads
- after refresh, the landing shows, with the login box covering the welcome text that lets me know what this isdidn't sign up, for those two reasons.isn't this a "show hn" post? |
postgres full text search is good enough
| well the article is right in one sense: postgres full text search is probably better than you think it would be and is very usable at non-massive scalehowever, i still wouldn't recommend using it. the queries and indexes are all unintuitive, complex, not very readable and require learning a bunch of new syntax anyways (as you can see in the examples in the blog post). so just take the effort you would spend doing that and instead learn something with more features that will continue running no matter how large your scale.while the blog mentions elasticsearch/solr (which are awesome and powerful), it doesn't mention sphinx (<link> if i were trying to make a simple search engine for my postgres/mysql powered site, i'd use sphinx. the indexer can be fed directly with a postgres/mysql query, and it includes simple apis for all languages to interface with the searcher daemon. and of course it is super fast, has way more features and can scale larger than you'd ever need (sphinx powers craiglist's search). | the most important sentence: "probably not if your core business needs revolve around search."postgres full text search is very good, but once you get into the realms were elasticsearch and solr really shine (complex scoring based on combinations of fields, temporal conditions or in multiple passes, all that with additional faceting etc.), trying to rebuild all that on top of postgres will be a pain.while that doesn't break the article, it runs into a nasty problem: `unaccent` doesn't handle denormalized accents. # select unaccent(u&'\0065\0301');
unaccent
----------
é
(1 row)
(that problem is also present in elasticsearch if you forget to configure the analyzer to normalize properly before unaccenting) |
postgres full text search is good enough
| the most important sentence: "probably not if your core business needs revolve around search."postgres full text search is very good, but once you get into the realms were elasticsearch and solr really shine (complex scoring based on combinations of fields, temporal conditions or in multiple passes, all that with additional faceting etc.), trying to rebuild all that on top of postgres will be a pain.while that doesn't break the article, it runs into a nasty problem: `unaccent` doesn't handle denormalized accents. # select unaccent(u&'\0065\0301');
unaccent
----------
é
(1 row)
(that problem is also present in elasticsearch if you forget to configure the analyzer to normalize properly before unaccenting) | while it's certainly good enough for english bodies, its half-assed support for compounds is a problem for bodies in languages that use compounds (german for example).there is sorta-support for compounds, but only really for ispell dictionaries and the ispell format isn't very good at dealing with compounds (you have to declare all permutations and manually flag them as compoundable) plus the world overall has moved over to hunspell, so even just getting an ispell dictionary is tricky.as a reminder: this is about finding the "wurst" in "weisswürste" for example.furthermore, another problem is that the decision whether the output of a dictionary module should be chained into the next module specified or not is up to the c code of the module itself, not part of the fts config.this bit me for example when i wanted to have a thesaurus match for common misspellings and colloquial terms which i then further wanted to feed into the dictionary, again for compound matching.unfortunately, the thesaurus module is configured as a non-chainable one, so once there's a thesaurus match, that's what's ending up in the index. no chance to ever also looking it up in the dictionary.changing this requires changing the c code and subsequently deploying your custom module, all of which is certainly doable but also additional work you might not want to have to do.and finally: if you use a dictionary, keep in mind that it's by default not shared between connections. that means that you have to pay the price of loading that dictionary whenever you use the text search engine the first time over a connection.for smaller dictionaries, this isn't significant, but due to the compound handling in ispell, you'll have huge-ass(tm) dictionaries. case in point is ours which is about 25 megs in size and costs 0.5 seconds of load time on an 8 drive 15k raid10 array.in practice (i.e. whenever you want to respond to a search in less than 0.5 secs, which is, i would argue, always), this forces you to either use some kind of connection pooling (which can have other side-effects for your application), or you use the shared_ispell extension (<link>, though i've seen crashes in production when using that which led me to go back to pgbouncer.aside of these limitations (neither of which will apply to you if you have an english body, because searching these works without a dictionary to begin with), yes, it works great.(edited: added a note about chaining dictionary modules) |
postgres full text search is good enough
| while it's certainly good enough for english bodies, its half-assed support for compounds is a problem for bodies in languages that use compounds (german for example).there is sorta-support for compounds, but only really for ispell dictionaries and the ispell format isn't very good at dealing with compounds (you have to declare all permutations and manually flag them as compoundable) plus the world overall has moved over to hunspell, so even just getting an ispell dictionary is tricky.as a reminder: this is about finding the "wurst" in "weisswürste" for example.furthermore, another problem is that the decision whether the output of a dictionary module should be chained into the next module specified or not is up to the c code of the module itself, not part of the fts config.this bit me for example when i wanted to have a thesaurus match for common misspellings and colloquial terms which i then further wanted to feed into the dictionary, again for compound matching.unfortunately, the thesaurus module is configured as a non-chainable one, so once there's a thesaurus match, that's what's ending up in the index. no chance to ever also looking it up in the dictionary.changing this requires changing the c code and subsequently deploying your custom module, all of which is certainly doable but also additional work you might not want to have to do.and finally: if you use a dictionary, keep in mind that it's by default not shared between connections. that means that you have to pay the price of loading that dictionary whenever you use the text search engine the first time over a connection.for smaller dictionaries, this isn't significant, but due to the compound handling in ispell, you'll have huge-ass(tm) dictionaries. case in point is ours which is about 25 megs in size and costs 0.5 seconds of load time on an 8 drive 15k raid10 array.in practice (i.e. whenever you want to respond to a search in less than 0.5 secs, which is, i would argue, always), this forces you to either use some kind of connection pooling (which can have other side-effects for your application), or you use the shared_ispell extension (<link>, though i've seen crashes in production when using that which led me to go back to pgbouncer.aside of these limitations (neither of which will apply to you if you have an english body, because searching these works without a dictionary to begin with), yes, it works great.(edited: added a note about chaining dictionary modules) | for full text search, the only global frequency information postgres uses is the stop-word list. it does not do tf-idf ranking. [1]for example, if you search for "bob peterson", postgres will rank these two documents the same:"i saw bob.""i saw peterson."in contrast, an idf-aware search would notice that "peterson" occurs in fewer documents than "bob" and score "i saw peterson" higher for that reason.[1] <link>[2] <link> |
postgres full text search is good enough
| for full text search, the only global frequency information postgres uses is the stop-word list. it does not do tf-idf ranking. [1]for example, if you search for "bob peterson", postgres will rank these two documents the same:"i saw bob.""i saw peterson."in contrast, an idf-aware search would notice that "peterson" occurs in fewer documents than "bob" and score "i saw peterson" higher for that reason.[1] <link>[2] <link> | as the author, it's maybe worthwhile that i explain the goals of this post.the first goal is about using your current architecture to solve small/medium search needs and help your project to introduce search without requiring to add components to your current architecture. it's not a solution on the long run if your application revolve around search. i'm hoping that with the introduction of jsonb in 9.4, the idea of using postgres as document store raise more attention on the search which can to be improved. but for an out-of-the-box feature, i think that the postgres community did an amazing job.
you can imagine that you get something working with postgres in matter of hours if you are already using it (and you are comfortable with pg), but if you have never used solr/elasticsearch it will take you much longer to introduce it in your project and get started (ops, document sync, getting familiar with query, ...).the second goal, is about introducing full-text search concepts. the post try to guide the user to build a search from nothing to a quite decent full text search in english / french (i cannot give feedbacks on other languages)the third which is probably the less clear is that people are still using mysql search sometimes which is imho an horrible search solution. i think this happen because some web framework like django provide easy access to match in the orm. in this context, the post is aimed also to provide mysql user some insights about what can be done with postgres and being more aware about its features.if you are interested by the topic then i suggest you to have a look to the amazings posts from tim van der linden who did an amazing job of going into more details about the subject.<link>
<link>
<link> full-text search is not the silver bullet of search but matter of your needs, it's maybe good enough ;) |
a glum sign for apple in china, as smuggled iphones go begging
| or it's a sign that the market was saturated at too high a price, or a sign that people are waiting for the official release so they don't have the risk of not having warranty. if it's a glum sign for apple that china has lost interest and that they still sold 10+m devices, i'm sure they won't be too upset. | >he hoped a new crackdown on smuggling by customs officers would help push their price back up.black market economics. restrict the flow of desired product only serves to enrich those with access to the distribution channels. |
a glum sign for apple in china, as smuggled iphones go begging
| >he hoped a new crackdown on smuggling by customs officers would help push their price back up.black market economics. restrict the flow of desired product only serves to enrich those with access to the distribution channels. | so far apple has been able to stay out of the race to the bottom when it comes to prices of its devices. and it did not look that the price of its devices was going to slow its sales much.
i have always believed the 2 year contract system with small upfront cost has helped apple move devices a lot in the us. and without 2 year contracts it would not dominate as much as it does. |
a glum sign for apple in china, as smuggled iphones go begging
| so far apple has been able to stay out of the race to the bottom when it comes to prices of its devices. and it did not look that the price of its devices was going to slow its sales much.
i have always believed the 2 year contract system with small upfront cost has helped apple move devices a lot in the us. and without 2 year contracts it would not dominate as much as it does. | i don't think it's a glum sign. they're still selling for a significant margin over what retail prices will be. and if you, as a prospective buyer, only need to wait a couple more weeks to get your hands on one[1], why would you pay double retail price?[1] <link> |
a glum sign for apple in china, as smuggled iphones go begging
| i don't think it's a glum sign. they're still selling for a significant margin over what retail prices will be. and if you, as a prospective buyer, only need to wait a couple more weeks to get your hands on one[1], why would you pay double retail price?[1] <link> | the iphone is in the final stages of approval in china. is it really worth paying a premium for at this point?<link> |
a simple guide to five normal forms in relational database theory (1982)
| it's worth noting that this model works quite well for the vast majority of client facing applications out there.i.e. things categorized by tags or groups where 1-to-n relationships are necessary. of course, the extreme of this is eav (entity attribute value) which i would limit to meta/taxonomy data for performance reasons.but for information where the labels (or quantity) aren't known before input are easier to deal with in normalized databases.e.g. getting metadata on a specific entry with no prior knowlege of said data except parent id: select id, label, content from meta where id in (
select meta_id from posts_meta where post_id = :id
);
or if you're using postgres, you can return the metadata as an associative array. e.g. <link> following is an excerpt from the actual schema i used on a very simple forum that ran on sqlite for years before switching to postgres fairly recently. the normalization (varying forms) afforded a lot of flexibility. maybe someone will find it useful. create table posts (
id integer primary key autoincrement not null,
created_at datetime not null default current_timestamp,
updated_at datetime default null,
title varchar null,
summary text not null,
body text not null,
plain text not null,
quality float not null default 0,
status integer not null default 0,
reply_count integer not null default 0,
auth_key varchar not null
);
create index idx_posts_on_status on posts ( status );
create index idx_posts_on_created_at on posts ( created_at );
create virtual table posts_search using fts4 ( search_data );
create table posts_family (
parent_id integer not null,
child_id integer not null,
primary key ( child_id, parent_id )
);
create table taxonomy (
id integer primary key autoincrement not null,
label varchar not null,
term varchar not null,
created_at datetime not null default current_timestamp,
updated_at datetime default null,
status integer not null default 0
);
create table posts_taxonomy (
post_id integer not null,
taxonomy_id integer not null,
primary key ( post_id, taxonomy_id )
);
create table taxonomy_family (
parent_id integer not null,
child_id integer not null,
primary key ( child_id, parent_id )
);
create table meta (
id integer primary key autoincrement not null,
label varchar not null,
parse_as varchar not null default "text",
content text not null
);
create table posts_meta (
post_id integer not null,
meta_id integer not null,
primary key ( post_id, meta_id )
);
create unique index idx_taxonomy_on_terms on taxonomy ( label asc, term asc );
create index idx_taxonomy_on_status on taxonomy ( status );
-- triggers
-- post create procedures
create trigger post_after_insert after insert on posts for each row
begin
insert into posts_search ( docid, search_data )
values ( new.rowid, new.plain );
update posts set updated_at = current_timestamp where id = new.rowid;
end;
-- post update procedures
create trigger post_before_update before update on posts for each row
begin
delete from posts_search where docid = old.rowid;
end;
create trigger post_after_update after update on posts for each row
begin
insert into posts_search ( docid, search_data )
values ( new.rowid, new.plain );
update posts set updated_at = current_timestamp where id = new.rowid;
end;
-- post deletion procedure
create trigger post_before_delete before delete on posts for each row
begin
update posts set reply_count = ( reply_count - 1 )
where id != old.rowid and id in (
select parent_id from posts_family where child_id = old.rowid
);
delete from posts_family where parent_id = old.rowid or child_id = old.rowid;
delete from posts_search where docid = old.rowid;
delete from posts_taxonomy where post_id = old.rowid;
delete from meta where id in (
select meta_id from posts_meta where post_id = old.rowid
);
delete from posts_meta where post_id = old.rowid;
end;
-- post parent insert procedures
create trigger posts_family_after_insert after insert on posts_family for each row
begin
update posts set reply_count = ( reply_count + 1 ) where id in (
select parent_id from posts_family where child_id = new.rowid
);
end;
-- taxonomy procedures
create trigger taxonomy_after_insert after insert on taxonomy for each row
begin
update taxonomy set updated_at = current_timestamp where id = new.rowid;
end;
create trigger taxonomy_after_update after update on taxonomy for each row
begin
update taxonomy set updated_at = current_timestamp where id = new.rowid;
end;
create trigger taxonomy_before_delete before delete on taxonomy for each row
begin
delete from posts_taxonomy where taxonomy_id = old.rowid;
delete from taxonomy_family where parent_id = old.rowid or child_id = old.rowid;
end; | first normal form excludes variable repeating fields and groupswhat are the definitions of "variable repeating fields" and "groups?"what would violating records look like? |
a simple guide to five normal forms in relational database theory (1982)
| first normal form excludes variable repeating fields and groupswhat are the definitions of "variable repeating fields" and "groups?"what would violating records look like? | can't you summarise all of that simply: "a database schema should be able to represent only valid data".e.g. employee, department, location is not good because that schema can represent invalid data: a single department can't be in 2 locations but the schema can represent that.the same rule of thumb applies to types in programming: a data type should be able to represent only valid values. this is why sum types are superior to error codes: a function can return a result and an error code, when what we usually want is that the function returns a result or an error code. when invalid values are unrepresentable that makes a lot of errors impossible. though sometimes your type system can't deal with all the constraints that you have, e.g. an array should be sorted (an unsorted array is representable but not valid => bad). |
a simple guide to five normal forms in relational database theory (1982)
| can't you summarise all of that simply: "a database schema should be able to represent only valid data".e.g. employee, department, location is not good because that schema can represent invalid data: a single department can't be in 2 locations but the schema can represent that.the same rule of thumb applies to types in programming: a data type should be able to represent only valid values. this is why sum types are superior to error codes: a function can return a result and an error code, when what we usually want is that the function returns a result or an error code. when invalid values are unrepresentable that makes a lot of errors impossible. though sometimes your type system can't deal with all the constraints that you have, e.g. an array should be sorted (an unsorted array is representable but not valid => bad). | i actually got a chance to chat about nosql with one of the people who coined the term "nosql" (here on hn, no less). it sounds like it was a term that got away from them a bit. i don't think anyone really intended to suggest that sql should be completely abandoned. notalwayssql, or maybeconsidersomethingotherthansql might have been better terms (well, not better, but more specific to what was actually intended).relational databases and sql are an exceptionally sound approach to a lot of data storage and retrieval problems. some of the "nosql" technologies emerged from new problems that emerged (such as full text indexing, networks).progress is an interesting thing, and doesn't always happen on an even keel. these days, i think you're far less likely to encounter knee-jerk resistance to an rdbms or sql. the dust is settling a bit, and in this case, that's a good thing. |
a simple guide to five normal forms in relational database theory (1982)
| i actually got a chance to chat about nosql with one of the people who coined the term "nosql" (here on hn, no less). it sounds like it was a term that got away from them a bit. i don't think anyone really intended to suggest that sql should be completely abandoned. notalwayssql, or maybeconsidersomethingotherthansql might have been better terms (well, not better, but more specific to what was actually intended).relational databases and sql are an exceptionally sound approach to a lot of data storage and retrieval problems. some of the "nosql" technologies emerged from new problems that emerged (such as full text indexing, networks).progress is an interesting thing, and doesn't always happen on an even keel. these days, i think you're far less likely to encounter knee-jerk resistance to an rdbms or sql. the dust is settling a bit, and in this case, that's a good thing. | my biggest pet peeve in the world of data storage is that the most powerful ideas from relational data theory are still mostly locked up in books and papers, and most programmers who think they know what "relational" means aren't aware of the full picture.the people who did all the pioneering work on the subject (mostly e.f. codd and chris date) seem to have made several blunders in trying to popularize their ideas. for example, one of date's later books ("go faster: the transrelational(tm) approach to dbms implementation") contains some very useful ideas. but it was written in 2001 and not published until 2011, because he was working with a now-failed startup that was trying to keep it all a trade secret.most of their writing is not available online. you have to buy their books. which is an author's prerogative, but seriously limits the reach of the ideas.the world thinks it already has relational databases that are good enough. convincing it otherwise requires a web-savvy marketing approach that has so far been lacking. |
template metaprogramming with modern c++: templates in depth
| guys, you have managed to put our site down. we are working on it but hn has managed to put our site down.manu sánchez will be conducting a talk about template metaprogramming in the c/c++ madrid meetup (spain):<link> should now be able to access a style-less version of the post in the same url. | because they can take integral types, they can take function addresses. this is a really interesting article:<link> passing the address of the function to the template, the compiler knows which function is going to be called - the idea being that a smart compiler can now inline your delegates for you. |
template metaprogramming with modern c++: templates in depth
| because they can take integral types, they can take function addresses. this is a really interesting article:<link> passing the address of the function to the template, the compiler knows which function is going to be called - the idea being that a smart compiler can now inline your delegates for you. | yes, you can, but you probably shouldn't.template "metaprogramming" is something that originated by accident, as a side effect of the original template mechanism, which was intended as a way to allow writing small generic functions. then it got a fan club, and influence on the c++ standards committee. now the c++ language design has gone off into template la-la land, with lots of feature support for a bad idea.it's kind of cool that rewrite rules are turing complete, and that c++ lets you do things like compute fibonacci numbers at compile time using recursive rewrite rules. this is a terrible way to program. someday, someone will have to debug the thing, and it won't be easy.there's a long history of this sort of clever stupidity. lisp doesn't have a for statement. so one was created as a compile-time macro. here's the mit loop macro, common lisp version:ftp://ftp.cs.cmu.edu/user/ai/lang/lisp/code/iter/loop/mit/mit_loop.clall 1496 lines of it. it's very clever. it took over a decade to debug.don't go there. |
template metaprogramming with modern c++: templates in depth
| yes, you can, but you probably shouldn't.template "metaprogramming" is something that originated by accident, as a side effect of the original template mechanism, which was intended as a way to allow writing small generic functions. then it got a fan club, and influence on the c++ standards committee. now the c++ language design has gone off into template la-la land, with lots of feature support for a bad idea.it's kind of cool that rewrite rules are turing complete, and that c++ lets you do things like compute fibonacci numbers at compile time using recursive rewrite rules. this is a terrible way to program. someday, someone will have to debug the thing, and it won't be easy.there's a long history of this sort of clever stupidity. lisp doesn't have a for statement. so one was created as a compile-time macro. here's the mit loop macro, common lisp version:ftp://ftp.cs.cmu.edu/user/ai/lang/lisp/code/iter/loop/mit/mit_loop.clall 1496 lines of it. it's very clever. it took over a decade to debug.don't go there. | "by default, there is no exponential and mind blowing executable size increase."i'm sorry but that's not really true. if you compile with debugging information included (with or without optimization), gcc will give you tons and tons of template name stuff in your compiled binary. i have one program that is over 100 mb and well over half of it seems to be template-related debugging stuff. it's unlikely that you could generate so many and such long symbols by hand if you weren't using templates. if you build without debugging symbols, or strip them, or separate them out, you may have different results, but i don't think that's the most common scenario for c++ users.you can also wind up with actual instruction bloat too: a seemingly "high performance" function written with recursive templates may wind up with dozens of kilobytes of machine code thrashing your i-cache while a perfectly good "old style" function would do the same job with a hundred bytes. disk may be cheap, but instruction cache is not. |
template metaprogramming with modern c++: templates in depth
| "by default, there is no exponential and mind blowing executable size increase."i'm sorry but that's not really true. if you compile with debugging information included (with or without optimization), gcc will give you tons and tons of template name stuff in your compiled binary. i have one program that is over 100 mb and well over half of it seems to be template-related debugging stuff. it's unlikely that you could generate so many and such long symbols by hand if you weren't using templates. if you build without debugging symbols, or strip them, or separate them out, you may have different results, but i don't think that's the most common scenario for c++ users.you can also wind up with actual instruction bloat too: a seemingly "high performance" function written with recursive templates may wind up with dozens of kilobytes of machine code thrashing your i-cache while a perfectly good "old style" function would do the same job with a hundred bytes. disk may be cheap, but instruction cache is not. | the article is good about explaining when and how code is generated, but i think that the fibonacci example does more harm then good because this is one of those fancy 'template hacks' which i wouldn't use for real-world code. a few really useful real-world use cases for templates are (imho):- they can make interfaces more simple by using template methods/functions (have a single method which is specialized by the compiler, instead of polluting the api with 20 slightly different methods which only differ by the argument type)- they can enable a coding style which 'looks and feels' almost dynamic without loosing the strict type checks and optimization opportunities that a static type system provides- they can help to keep related data close together in memory and minimize dynamic memory allocation (e.g. an array of structs instead of an array of pointers)- the compiler has more optimization opportunities because it has more type information (vs. a more dynamic system where types are only known at runtime)the tradeoff is of course that the compiler generates more (specialized) code, it breaks the simple rule that the amount of generated code grows linearly with the number of lines of code. on the other hand the compiler has a lot more type info to optimize the generated code. still the programmer has to know what's happening under the hood so he can weigh the advantages against the disadvantages.[edit: formatting] |
suicide, a crime of loneliness
| this is story of my friend, he calls himself "dood" as he doodles
"my mid life crises hit me hard. i was always loner by nature. never had many friends, few family members, mediocre career. not much money in the bank. in a year, i lost few of my elderly family members. it came as a shock.
i realized, after 20 years of career, i haven't achieved much. there are not many people in the world, who know about me, about my existence. whatever i was doing at my job, was not going to make any difference to the world or to anybody. if i die nothing matters. i lost interest in doing things. it was dead end for me. nothing made sense. i started getting suicidal thoughtswhatever i did, my brain told me, " why bother?" many people tried to advise me. but this is the first time, it didn't matter. in my life, first time i didn't care about others opinions.one day i doodled something on paper. i realized. i like to doodle. so i doodled more. i felt happy. i did my 9 to 5 job, but whenever i got time, i doodled. after few days, i put them for sell on different platforms. i wasn't expecting anybody to buy it. in fact, it was like i was craving for rejection, just so that i can feel that “i don't care" feeling.
i started wearing whatever i like. i started doing things which i liked. i realized i am the most important person in my life. it lifted lot of weight from my mind. i felt freealmost after one year, somebody bought one of my doodles as a company logo. not much money, but i felt good. i gave it to charity.
so, mostly things aren’t changed much in my life. but my attitude is changed. my biggest achievement in my life is, change of outlook from negative to positive. i started meeting many unfortunate people through my charity work. people, who don't have roof on their head, people with terminal illness. i realized how blessed i am, to have this kind of life. now i stopped taking things for granted. there is lot of life out there, more than promotion, bad boss, and dirty office politics. | how is suicide "unreasonable"? albert camus wrote in "le mythe de sysiphe":> il n'y a qu'un problème philosophique vraiment sérieux: c'est le suicide. juger que la vie vaut ou ne vaut pas la peine d'être vécue, c'est répondre à la question fondamentale de la philosophie.(there is only one really serious philosophical question, and that's suicide. deciding whether or not life is worth living is answering the fundamental question of all of philosophy.)if you arrive at the conclusion that there is no point to any of it, why not end your life on your own terms? we will all die eventually; it seems to me more courageous to decide of the moment.we regard suicide as the ultimate failure; but isn't it, rather, the ultimate choice? and isn't that the problem?suicide in a way is an insult to the living, that's what makes us hate it so much.of course, not all suicides are equal; teenage suicide is especially tragic, for the exact reasons given in the article (i had a cousin who killed himself at 24; for everybody who survived him, and esp. his brothers and sisters, and his parents, it's an incredible ordeal, a wound that will probably never heal).but we should respect the decision of a middle-aged man who had a wonderful and very successful career, and maybe came to the conclusion that he's done. we're not him, we'll never know how he felt anyway. |
suicide, a crime of loneliness
| how is suicide "unreasonable"? albert camus wrote in "le mythe de sysiphe":> il n'y a qu'un problème philosophique vraiment sérieux: c'est le suicide. juger que la vie vaut ou ne vaut pas la peine d'être vécue, c'est répondre à la question fondamentale de la philosophie.(there is only one really serious philosophical question, and that's suicide. deciding whether or not life is worth living is answering the fundamental question of all of philosophy.)if you arrive at the conclusion that there is no point to any of it, why not end your life on your own terms? we will all die eventually; it seems to me more courageous to decide of the moment.we regard suicide as the ultimate failure; but isn't it, rather, the ultimate choice? and isn't that the problem?suicide in a way is an insult to the living, that's what makes us hate it so much.of course, not all suicides are equal; teenage suicide is especially tragic, for the exact reasons given in the article (i had a cousin who killed himself at 24; for everybody who survived him, and esp. his brothers and sisters, and his parents, it's an incredible ordeal, a wound that will probably never heal).but we should respect the decision of a middle-aged man who had a wonderful and very successful career, and maybe came to the conclusion that he's done. we're not him, we'll never know how he felt anyway. | the article somewhat related to me.whenever i felt the urge, it was both instinctive and driven by the realization of utter pointlessness of any endeavor, ultimately of life itself. there were triggers, sure, which is where my instinct to give it all up came in, but the triggers themselves never drove it all the way. it was the chain of thought of how anything i do -- i used to do things primarily for my own satisfaction (read: happiness) -- is ultimately futile.i hated the fact that i am beholden to others -- my parents, my closest friends -- and thus cannot take my own life, but this thought was only a minor hurdle in the steep dive to suicide. only a minor hurdle because i saw them as just other people in this web of life, perhaps more closely tied to me, but my life is my own after all, and i am the only one in here. |
suicide, a crime of loneliness
| the article somewhat related to me.whenever i felt the urge, it was both instinctive and driven by the realization of utter pointlessness of any endeavor, ultimately of life itself. there were triggers, sure, which is where my instinct to give it all up came in, but the triggers themselves never drove it all the way. it was the chain of thought of how anything i do -- i used to do things primarily for my own satisfaction (read: happiness) -- is ultimately futile.i hated the fact that i am beholden to others -- my parents, my closest friends -- and thus cannot take my own life, but this thought was only a minor hurdle in the steep dive to suicide. only a minor hurdle because i saw them as just other people in this web of life, perhaps more closely tied to me, but my life is my own after all, and i am the only one in here. | suicides prevail at both ends of the spectrum of social interaction: too much or too little [1]. it's not just at the too little end. examples of too much social interaction leading to suicides: prison suicides, overworked stressed out students, suicides due to too much debt or career failure, individuals, usually women, left alone to take care of too many children alone without support, and altruistic suicides such as when elderly go into the wilderness to free up resources, or soldiers jumping on grenades. it's not just loneliness that kills. you have to plan ahead and manage your interaction such that you don't leave yourself without anyone, and have a support network and realistic expectations in life.[1] <link> |
suicide, a crime of loneliness
| suicides prevail at both ends of the spectrum of social interaction: too much or too little [1]. it's not just at the too little end. examples of too much social interaction leading to suicides: prison suicides, overworked stressed out students, suicides due to too much debt or career failure, individuals, usually women, left alone to take care of too many children alone without support, and altruistic suicides such as when elderly go into the wilderness to free up resources, or soldiers jumping on grenades. it's not just loneliness that kills. you have to plan ahead and manage your interaction such that you don't leave yourself without anyone, and have a support network and realistic expectations in life.[1] <link> | there's a biological phenomenon called "apoptosis," which may give us hints into the cause and behavior of suicides.apoptosis, simply put, is a cell-level suicide (or programmed cell death), which happens from multiple causes, but generally for the beneficial effects to the entire body, which happens to be a tragic outcome for the cell itself. this helps to increase the overall efficiency of the body or to prevent any possible damages.but, as you can presume, this 'suicide' sometimes happens to a perfectly healthy, normal cell -- when it's isolated, lacking interactions with other cells. of course, as with most living things, this is not a binary state, where a cell immediately performs the suicide on a trigger, but more of a gradual, transient process, which when pushed beyond a threshold or when the cell-death process wasn't halted for some reasons, may conclude in the death itself.this brings important insight into the behavior of human suicide as well. what role does interactions play part in making a healthy (or a depressed) human being to commit suicide, and what process can we learn from cells to prevent this from happening? life forms, no matter how complicated they seem, in general are fractal in nature with some degree of complexity layered by emergent behaviors, so there, we can learn something from our roots, or cells in this case.even more disturbing thought might be: are suicides sometimes beneficial to the society? i'd hate to ponder on this idea, but if we can assume a perspective of an alien scientist observing human colonies from far far away, this might an interesting area to explore. |
a discovery about prime numbers and what it means for the future of math (2013)
| this is a wonderful article, but the blog spam url should be changed to the original:
<link>;impact lab" has scraped the entire 5-month old article from it's original publication, and republished it verbatim with their own ads on it. while they link to original at the bottom of the full article (no mention on the teaser page), this is egregious copyright infringement. this appears to be their entire business model: <link> should ban them. slate (and the other infringed parties) should sue them out of existence. it should be an open-and-shut case. | from the article "the gaps between successive powers of 2 grow exponentially, and there are finitely many gaps of any given size; once you get past 16, for instance, you will never again see two powers of 2 separated by a gap of size 15 or less."unless i am mistaken, the gaps between powers of two never repeat. they keep getting bigger by a factor of two each time, right? |
a discovery about prime numbers and what it means for the future of math (2013)
| from the article "the gaps between successive powers of 2 grow exponentially, and there are finitely many gaps of any given size; once you get past 16, for instance, you will never again see two powers of 2 separated by a gap of size 15 or less."unless i am mistaken, the gaps between powers of two never repeat. they keep getting bigger by a factor of two each time, right? | so does this mean that the primes actually distribute based on some pseudo random pattern?certainly that is trivializing things but is this what the notion of the numbers acting random, but clearly not being random implies? |
a discovery about prime numbers and what it means for the future of math (2013)
| so does this mean that the primes actually distribute based on some pseudo random pattern?certainly that is trivializing things but is this what the notion of the numbers acting random, but clearly not being random implies? | hn discussion from 500 days ago - <link> has changed since then? |
a discovery about prime numbers and what it means for the future of math (2013)
| hn discussion from 500 days ago - <link> has changed since then? | another article which talks about this - <link> |
you call this thai food? the robotic taster will be the judge
| authenticity? i don't really care about that as so much as if the food tastes any good. | >the machine evaluates food by measuring its conductivity at different voltages.they should really have kept the functioning principle behind more smoke & mirrors, because this suddenly makes the whole thing seem very childish and ridiculous. conductivity may slightly cross over with the tongue's means of perception, but the main determinant of a food item’s flavor is the sense of smell, which is incredibly complex. we don’t even know how it works, but it seems to perform an in-depth analysis of every volatile molecule’s shape and features. |
you call this thai food? the robotic taster will be the judge
| >the machine evaluates food by measuring its conductivity at different voltages.they should really have kept the functioning principle behind more smoke & mirrors, because this suddenly makes the whole thing seem very childish and ridiculous. conductivity may slightly cross over with the tongue's means of perception, but the main determinant of a food item’s flavor is the sense of smell, which is incredibly complex. we don’t even know how it works, but it seems to perform an in-depth analysis of every volatile molecule’s shape and features. | you get what you optimize for. i can imagine food being served, if there's enough incentive to make this machine happy, that conducts electricity in all the right ways, but doesn't actually taste any better. |
you call this thai food? the robotic taster will be the judge
| you get what you optimize for. i can imagine food being served, if there's enough incentive to make this machine happy, that conducts electricity in all the right ways, but doesn't actually taste any better. | thai food in nj/ny is in a sad state. the best thai food in nyc doesn't hold a candle to an old lady making some gai gap tiam on the street of chiang mai. |
you call this thai food? the robotic taster will be the judge
| thai food in nj/ny is in a sad state. the best thai food in nyc doesn't hold a candle to an old lady making some gai gap tiam on the street of chiang mai. | i don't know if is this an ideal way to judge the authenticity of thai food, but i think it's refreshing as an applications of artificial senses beyond images and sound.i've been playing with the idea of doing some machine learning on artificial smell or taste. does anyone here have experiences with such things? in particular i'd love to learn something about what the options are for the sensors and peculiarities of the sampling process compared to light/sound. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.