Thursday, June 21, 2012

Solving picture puzzles algorithmically

A different course today: algorithmically solving puzzles. The reading is here: http://chenlab.ece.cornell.edu/people/Andy/publications/Andy_files/Gallagher_cvpr2012_puzzleAssembly.pdf

Some of the proposed applications include piecing together shredded evidence or archeological artifacts. I'm not sure those applications are of particular interest to me, but the fundamental problem is still interesting.

The proposed solutions here are to determine a gradient across the edges of pieces, rather than the absolute color as former solutions had. It presents a greedy solution, which means that it optimizes the local areas rather than optimizing the whole puzzle, in the interest of processing power.

The conclusion I have reached from this paper is that: I need to learn a heck of a lot more about this. Check back in a few days; I'll be going through some of the references and trying to determine what the models actually are. It's an interesting read anyway even if you don't know all the nitty-gritty details of how they solve these things, and I do recommend it.

My first thought (with admittedly very little knowledge of how these things actually get solved) is: is there a way to organize the puzzle first so that you don't have to locally optimize as much, and would that be worth the extra processing power? I expect that with a large enough puzzle it could eventually be. What I'm thinking is assign a gradient value based on the pixels, inserted into a binary tree, or something of that nature. Not sure. I'll follow up here when I've got a clearer mental idea.

Sunday, June 17, 2012

Russia (Martin Sixsmith) The final.

This morning I finished the history of Russia. Definitely an engrossing read, especially for someone who has really only ever had Russia mentioned in history class in relation to US history. It was published in 2012 and deals with events right up to present day. It was a fun read. The author mixes events, commentary, and anecdotes well, and gives a good coloring of culture and technology in addition to the political aspects. It paints a portrait of a culture that is constructing itself as a blend of eastern and western cultures, with its own uniquely Russian base. It is able to paint a vivid enough picture as to convince me to travel there if possible.

The book is a history of Russia, but it is a history constructed to answer the question "Can/should Russia transform itself into a western-style democracy?" From the beginning the book is peppered with comments indicating that such-and-such an event was another missed chance for western-style democracy. In the end he arrives at the conclusion that 'It is a beguiling thought [that incorporating into the modern international trade system would force Russia to westernize], but it is not supported by the facts." Furthermore, "International trade links seemed not to have persuaded russia to act like a European country, but to have convinced her that she can act as she likes." The book successfully argues this case, and I do not have enough background from other sources to judge whether that is off base or not.



I was listening to Tchaikovsky's 5th and 6th symphonies as I finished this; it felt appropriate. There is one part in the 5th symphony that sounds as though it was the inspiration for part of the rhapsody in August Rush. I'll go back and try to figure out the exact point.




Friday, June 15, 2012

Russia (Martin Sixsmith) Continued some more. Yes, it's a long book.

Reading a history while the rain is pouring outside, sipping a cup of tea. I feel almost civilized. Then I go to the computer to write down my reflections and remember that that is not the case.

One of the things I like about this book is that it does not just spend time on politics and wars, but also science, technology, and arts.


Having made it through the horrifyingly depressing catalogue of crimes committed by Stalin, it is easy to see how parts of Russian history brought about the worst in people. It is a necessary reminder to see how it can bring out the best also. This conversation occurred between the noted cosmonaut Vladimir Komarov and a KGB official shortly before a lift-off:

As [Komarov] was seeing us off, he said straight out, 'I'm not going to make it back from this flight.' I asked him, 'If you're convinced you're going to die, why don't you refuse the mission?' He answered, 'Because if I don't make the flight, they'll send Yura [Gagarin], and he'll die instead of me. We've got to take care of him.'

Komarov did die in the flight; the systems failed shortly into the flight and the mission was aborted. The team was unable to regain control. The deputy premier and Komarov's wife spoke to him on video call; they had about two hours before the ship smashed into the ground at 400 miles per hour.



It is true that winners re-write the history. The author and I come at this story from a very western point of view, and at first it seems like a barefaced tragedy that Stalin could so successfully brainwash generations that they would still have trouble throwing off his yoke years after he was dead. In thinking about it further, however, are not the western powers are having that exact problem now with the idea of perfect free markets? It is a symmetry offset by several generations, but a symmetry nonetheless. In confronting our political-economic crisis of a government owned by the largest players of capitalism, it is as difficult for us to take a step back and see the solutions as it is/was for Russia. We also have the people who will defend the system of pure capitalism to their death, despite the fact that much of the stability we enjoy can be attributed to a government with some social programs.

This isn't to say that if we had remained an industry-baron nation we would not have been strong enough to defend our borders or created a cultural renaissance. In fact, one of the things that jumps out is that the industry fortunes made life better entire cities. I visited Pittsburgh and Delaware recently, and the impact of Andrew Carnegie and Alfred DuPont is probably incalculable . Libraries, museums, schools, hospitals, infrastructure. However, the tendency of capitalism as it has been practiced is for those with wealth to accumulate more wealth more quickly, and with that wealth a concentration of power. The thing keeping capitalists in check is a government interested in enough socialism to keep society from falling over and rebuilding from scratch. If the mass of people working got sufficiently fed up, it is not unthinkable that the federal government could go the way of the Tsars.  Pity the fool so quick to judge others that they fail to judge themselves?


I thought the rain was pouring before. I was wrong. It is torrentially pouring now.

Thursday, June 14, 2012

Russia (Martin Sixsmith) continued a third

Moving on to Stalinism:

Timeline:
1927 Dec: Announce the collectivization and move on to the next grand stage of Communism
1929: Two million ton shortfall in grain.

Guys! It's not working because we haven't gone far enough! On to greater glory! Collectivize it all!
 (cough Fed printing money cough austerity measures cough tax breaks cough). I know its said that those who fail to learn history are doomed to repeat it, but given the average knowledge of history in the USA and the fact that we're not obviously doubling down on things that haven't worked yet because we haven't taken them far enough, that saying is a blatant lie. Blatant.




I just stumbled across this quote, which is utterly wonderful. Made my night. It pertains to Nikolai Yezhov, the head of the secret police (and officially responsible for the Russian Terror) and his successor, Lavrenty Beria. It is particularly relevant here that the Russian word 'yezh' can be translated to 'hedgehog'. A year after he resigned from his post, Yezhov was arrested for crimes against the regime and killed. Regarding the official reaction to his death,

"As had happened with the Old Bolsheviks [party leaders who had been part of the revolution and therefore could make some claim to being Lenin's successor], his image was removed from official photographs, and the pages of his entry in The Great Soviet Encylopaedia, which had celebrated him as the protector of the revolution, were ripped out. To fill the gap, a very long article was inserted on the subject of hedghogs.*

*The same thing would happen in 1953 when Yezhov's successor as head of the secret police, Lavrenty Beria, fell from grace. In his case, readers of The Great Soviet Encylopaedia would find themselves very well informed about the Bering Strait."

Wednesday, June 13, 2012

Russia (Martin Sixsmith), continued

Several observations on the Russian revolution:
 - If you can incite a man to kill another due to perceived agreements, then someone else can too. You then know what kind of man you are dealing with.
 - When you are dealing with someone who deliberately attempts to suppress his emotions and cultivate more sociopathic tendencies than he was inherently born with, you probably shouldn't run the other way. That tends to leave your back as a nice target for rifle fire.
 - Terror only works to the point where everyone knows that they're going to be mercilessly tortured for no better reason than that they need to be to keep the rest of the masses terrified. At that point, they have nothing left to lose, and will rise.
 - The enemy of those with plans are those people who come to believe whole-heartedly in those plans. When the people who have the plans change something, in response to crises or needs, the people who whole-heartedly believe in those original plans won't switch. You have to get people-worship for that. (Taken from the discussion of the New Economic Policy (NEP), and it seems to apply reasonably well to the US Tea Party origins vs current construction).


 I would like to point out an observation of the author. He is discussing the similarities between the NEP and Gorbachev's perestroika reforms. The passage in the footnote on page 245 reads, "I believe that Gorbachev, like Lenin, saw economic liberalization as a means to preserve and strengthen socialism, but - unlike Lenin - he failed to impose the political tightening that would stop change spiraling out of control and ultimately destroying the system is was designed to save." I don't have enough background on the perestroika reforms to see if this is an accurate comparison, and I'm sure from the bias of the author that the way it is presented here will portray it as an accurate comparison, but the entirety of the footnote give an interesting idea on how political parties can maintain power. More interesting is trying to figure out at what point the reforms have progressed so far that the reforms themselves start getting pushback. I'm a product of a capitalist society and I have trouble seeing that such reforms on this society would go too far, but then I look at the push for more bank regulation and realize that that is exactly what we're seeing. I wonder where the balance point is and how the initial outlook of the reforming society affects the balance point.

"...the Russian people's worst misfortune was Lenin's birth; their next worst, his death.' -Winston Churchill. How do different generations of Russians view/react to this statement?


The final and only true conclusion I can arrive at from reading these passages: 
I sincerely pray to whatever may be listening that I never forget that people are, in fact, people. 

Tuesday, June 12, 2012

Russia: A 1000 Year Chronicle of the Wild East (Martin Sixsmith)

This is a book I have been reading for a while, and with my impending move out of Miami, am obliged to finally finish and return to the library. It is a history of Russia. My motive in choosing it was that, while I had a lot of US history, a fair amount of European history, a bit of Chinese and Japanese (especially as they pertained to the west), and a few other bits here and there, I did not truly have any idea of Russian history. On seeing this book on the new-books shelf, I figured it would be an interesting choice.

A caveat: I am 182 pages in out of 530; the death of Rasputin, about to start the roller-coaster ride of the revolution. The beginning opens explaining a bit about the author - he is not Russian, but a European with a love of Russia and a significant research background into it. The style of the book is a mixture of historical facts, cultural examinations, and personal anecdotes of exploring the areas where key events occurred.

The first overriding theme that struck me was this: the author had incorrectly subtitled the work. Rather than "A 1000 year chronicle of the Wild East," it would better have been named "All the times Russia missed its chance for a constitutional monarchy, from a European point of view." The author is quick to point out every time Russia could have become a more western style democracy but didn't. There is not really any discussion about whether/how this would have worked for Russia. He does discuss how the overriding cultural feelings of the time were summed up in the belief that centralized autocratic power was the only way to protect Russia's borders, and how this feeling came about from several centuries of invasions followed by several centuries of occupation by the golden horde. Frankly, based on the descriptions of the book, I'm amazed the distinct culture that is now Russia didn't get more absorbed by the Huns than it did. Perhaps that's me as a citizen of these United States, in which the usurpation of power by the federal government has been so slow and gradual, and a function of the power which we permitted to the government (rather than hostile takeover, for the most part), that the correct word to use now is 'The' instead of 'These'. It is interesting to note how the different paths seem to be leading us to similar places. I digress.

I'm not sure if its a good thing or a bad thing that the author refrains from discussing the implications of creating a constitutional monarchy. On the one hand, the pace of the book is good and portraying the events without boring by analysis is a wonderful quality in the book. On the other hand,  I'm definitely intrigued as to why he feels that it is the correct solution. You can either say that its development is similar to Europe's, in little states bonding together for protection or being overrun and absorbed, or you can say that it is the opposite, in that once a centralized power gained an advantage over neighboring states it was mostly outward conquest. If you approach it from the former point of view it lends itself to the possibility of a constitutional monarchy. The latter point of view requires more centralized power and the ability to make quick decisions for tactical purposes.


More later.

Sunday, June 10, 2012

The Will of the Empress - Tamora Pierce

I probably should have stated earlier, but I will state it now: I will reference plot details, possibly spoilers, quotes, and other things in the course of the discussion.The first paragraph will usually be safe to read as they will typically contain background information to orient the reader in both the background of the story and my particular background that may be relevant. The last paragraph should also be safe; I will make an effort to make sure it only includes a synopsis of what I think of the work. In other areas, I'll try to give little enough context that you won't understand precisely what I mean unless you've read the book, but it may give you some premonitions about what's going to happen, and I do reserve the right to do a full plot synopsis.

 The Will of the Empress: Tamora Pierce
This book is a re-read, albeit one that I haven't reread in a while. It is a fantasy novel; effectively the third installment in the Circle of Magic series. The other two installments came out in four books each, one book for each of the four types of magic wielded by the main characters. The first set deals with how they became the circle of magic in the first place; the second set deals with each individual mage while they are off traveling without the others, and this book fittingly brings them all back together again.

While this is better constructed than some of her other middling works, it sometimes feels as though the author is self-conscious. "I am an author and I have to figure out something to write." I feel like there were times that the author struggled with how her characters should act given the way she created the rules of the universe - if it was as well-known as was implied that the palace was a safe-haven for kidnap attempts, then Fin was absolutely insane to do it there. If it was common knowledge, "Everyone knows...", then when he eventually had to reveal himself as the perpetrator a year down the line or so, the Empress would be forced to act against him even if she wanted to keep Sandry in Namorn, so that the other parents would be willing to keep their daughters at courts. They try to explain this away as a lapse in judgement on Fin's part, but you shouldn't be relying on a lapse in judgement by someone who is extremely savvy to power shifts at court as a means of driving your plot forward. Particularly when you really accomplished nothing exceptional by having this attempted at court. Primarily, it seemed to be a plot device calculated to infuriate Sandry enough to make her leave Namorn.This could have been done with any almost-successful kidnapping attempt at any place, and didn't have to flout the social rules to happen in the palace.

There are other things that just looked a little bit shoddy. Spelling errors are never forgiveable. The word is 'now', not 'know', get it write! One of the characters from prior novels developed a sudden preference for women over men, which looked like it was dropped in the middle possibly as a political/social statement. It reminded me of the Inheritance trilogy however-many-books-they've-got, where the main character suddenly develops a need to be vegetarian. Fine, I can deal with it, just don't drop in the "I'm an author making social commentary and this makes sense" comments. They really just annoy me, like little gnats. If you want to throw something in there like that, at least throw it in on the character that hasn't shown any sexual interest towards anyone yet. You spent the entire last book implying there was an attraction between this character and one of the other [guy] main characters. Sure it never went anywhere due to minor issues like people being insane, but whatever!

I like most of what Tamora Pierce writes, but if I had to recommend something, I'd recommend some of her earlier work. It is more innocent, more written for the sake of being a story than for the sake of having written something. I'll have to go back through some of the first/second set of books in this to see if I'm picking up stuff that I missed the first time around, but I don't expect it. It's a fine book to read if you're looking for something that is a children's book and doesn't try to go too seriously into character development. The magic is an interesting concept, but you got more of that from the first two sets of books. This book was more about the characters.

Sunday, June 3, 2012

More than Human (Ramez Naam): Part 3

Finished the book. It is well worth reading, as a "This is where technology is right now and here are some ideas of where it could go, as our knowledge of how things work and precision increases." As most of this knowledge is going to arrive owing to solving diseases, it is a very small step from there to applying it to enhancements. If the state of drugs are any indication, once a thing is possible, it will happen even if it must happen at first by illicit means and it is better to accept that and prepare for it than to deny it. The author does not address moral questions in this book beyond that point. At some point, some of the authors of books decrying enhancements' moral depravity will stop focusing on why we shouldn't move forward and start focusing on ways we can mitigate negative effects/magnify positive effects. In the meantime, science is slowly chugging along.

As a parting comment, a rather odd video by one of the researchers who is cited in the book on the technology and its implications:
http://www.youtube.com/watch?v=Pgmoz4f8LA4

More Than Human (Ramez Naam) - continued

Interjecting this at the top so it doesn't get lost: The author puts forward the best argument I have ever heard regarding morality of reproductive cloning in theory: Identical twins are reproductive clones of one another. They are regarded as distinct people with distinct souls in most cultures. A clone of you would simply have the same set of genes, and be far more different than any identical twin, due to the difference in cultures of when you both grew up.




More on the subject of looking back at the author looking forward:

Regarding the technology of sequencing the human genome, the author references two companies - US Genome and Affymetrix. US Genome's most recent patent is 2005, although they claim to still be developing methods. While the author focuses on its potential applications to sequencing the human genome quickly and efficiently particularly in regards to embryonic modifications, it appears to have branched into more currently profitable pursuits such as pathogenesis analysis. On the other hand, Affymetrix has improved its human genome detection kits from 100,000 sequence points to 629,000 base pair points (prices not available online, so I can't compare those, but probably similar or cheaper than in 2005). 

To date, we are not really any farther along in embryonic testing. We can test for more genetic diseases as we find the associated genes, but the technology itself has not changed significantly. The Recombinant Advisory Commission (RAC) ruled in 1999 that in-utero gene therapy could affect reproductive cells and be passed on to subsequent generations. I was astonished that the author did not point out that in the future, this could be one of the advantages of the gene therapy [note: he does imply something similar later]. He does state that amniocentesis testing can help screen for down syndrome and other genetic factors, but stops short of suggesting that we could use gene therapy to eliminate unwanted genes from the gene pool while still carrying the child. As an example, a non-color-blind girl (gen2) born to a color-blind father (gen1) will necessarily carry a recessive gene for color-blindness. As it is, any male descendants (gen3) of the girl will carry a 50-50 chance of being color-blind. We could use gene therapy to correct the recessive color-blind gene at generation 2 and remove those genes from the pool. Any color-blindness that results after that is the result of spontaneous mutations, not inherited factors.

As a side note to the chapter above, the RAC stated in 1999 that the technology was not specific enough to consider in-utero genetic therapy as safe. They have not yet changed their stance, but they indicated at that time that given advancements in technology, such therapy could be reconsidered.
Link: http://oba.od.nih.gov/oba/rac/racinutero.pdf
General link to RAC documents: http://oba.od.nih.gov/rdna/rdna_resources.html
Welcome to life!

The goal here is to keep track of various and sundry new things, including but not limited to new media (reading, movies, recipes, etc... Anything and everything).


To start - My current reading list. I will also be adding discussions on books that I've read in the past, as I feel like re-reading or discussing them.

 - More than Human (Ramez Naam)
 - Russia: A 1000-Year Chronicle of the Wild East (Martin Sixsmith)
 - The Unbearable Lightness of Being (Milan Kundera)
 - Ender's Game (Orson Scott Card)



More Than Human has an interesting perspective. It's an explanation of how human enhancements (genetic, lifestyle, medication-based, whichever) could work and improve our lives, not just cure diseases. It is a pro-enhancement stance, meant to offset some of the more negative works out there. As such, it focuses on the positives. It does typically mention the negatives in passing, but effectively assumes that at some point in the future, technology will overcome those problems.

One of the interesting aspects of this book is the fact that it was published in 2005, and cites many contemporary research projects in enhancements. As such, we are now able to go back and look at how some of research that was on-going or about to start turned out.  Of the two studies looking at IGF1 and its ability to treat ALS (Lou Gehrig's disease), one showed positive results and the other showed no significant data. IGF has to date not been approved for use in treating the disease. As regards studies on 2-deoxy-D-glucose (2DG) uses for anti-aging, we are effectively at the same place as when the book was written - it is toxic to humans in medium doses, has shown promise in low doses in mice, and we haven't been able to move forward with it in other ways yet. Other mimetics on the market have not been proven to help with anything, and your best bet still remains a glass of red wine. It is, however, just a bet still. (That said, moderate alcohol intake has been shown repeatedly to improve your cardiovascular outlook far more effectively than a lot of the blood-pressure-lowering-liver-or-kidney-killing medications out there, so why not?) 

As an interesting side note, at one point in the book the author talks about Caloric Restriction diets. That amuses me greatly, because a CR diet is one in which the person eats significantly fewer calories, 'on the point of starvation', with the goal of living a longer life. Although he doesn't get into numbers, a little bit of research into these diets show people going at about 1500 calories per day, carefully calculated to have a balance of nutrients. Interestingly, that's about how much I consume in a normal day when I'm cooking for myself. I wouldn't consider that anywhere near starvation, and I wouldn't consider it something where you need to be especially careful to get all your nutrients, as long as you're eating well and paying attention to what your body wants you to eat.

I'm about halfway through the book, so I will post more thoughts as I go through it.