• Big Sur and Migration Assistant

    I had a problem with Migration Assistant and searched for a solution on the internet and found nothing. I suspected a solution, but the Apple Geniuses could not confirm if I was correct. Since I now have a solution, I thought I would document it for the next person.

    I have a hardware issue on a 2020 Intel MacBook Air. It passed the Genius hardware test so they recommended a clean install of the software. I had a Time Machine backup, so I told them to wipe it and reinstall the operating system. They did not reinstall the operating system but rather upgraded me to Big Sur.

    Here is the problem: Big Sur Migration Assistant, in the setup process, could not see my Catalina created Time Machine backup.

    For completeness here are some other observations:

    • Big Sur Migration Assistant can see a Big Sur created Time Machine backup from a secondary computer.
    • Finder on another computer can see both backup directories.
    • Internet recovery on the MacBook Air could see all the Time Machine backups.
    • The OS version of the Catalina backups were “unknown.”

    My hypothesis: Big Sur Migration Assistant is not backward compatible with Catalina-created Time Machine backups. And Apple did not document this change, nor inform their Geniuses.

    The solution: A new clean install, but this time installing Catalina. Catalina’s version of Migration Assistant can see both my Catalina and the Big Sur created backups. Accept the hypothesis and start looking for a new backup routine that documents breaking changes.

  • The Rain

    Rain, coffee, and jazz.

    No, not jazz — K-pop. Not K-pop, something else. It should be soft but loud, fun but also relaxing. It should be joyous and melancholy.

    On a rainy day, while drinking coffee, one should listen to … the rain.

  • I Felt the Need to Write

    This time, I mostly wanted to write because I got a new keyboard today. Beyond that though, I find writing gives me the space to think.

    I am an external processor, I think best while speaking. As such, my wife has become an expert at ignoring me. Without that skill, she would be subjected to every single one of my inner thoughts. However, when my brain is overwhelmed, and my thoughts are racing, I can’t speak fast enough to keep up. This is where writing finds its power.

    Writing is slow and allows for repeated refining, but is still an external process. It allows me to understand my thoughts, but also acts like meditation and slows me down to a manageable pace. And so, tonight I write.

  • On Writing

    Work can take interesting turns.

    In my previous post I discussed my plan to write more. It was well meaning, but not practical. It was born out of my frustration with not budgeting enough time to edit my dissertation. Since then I have learned two things: write more and putting words on the page is not the same as writing.

    For the last half year or so, I have been focusing on putting in an ever increasing amount of hours writing. As a scientist, I am judged by how I communicate my ideas. This is predominately done via journal article. During this journey, I have learned that writing has three major phases: idea creation & outlining, drafting, and editing.

    This new framework has worked! Scientists usually write about one article per year. Since my last blog post less than two years ago, I have not written just one or two journal article but three. On top of that, I have one more in the editing stage, and two in the drafting stage. That will be six total articles before the end of the year.

    All told, my previous post was an interesting idea that did not work. However, I was since been able to figure out a framework that does work. Now I am writing more and more and seeing the value from each of the three major writing phases.

  • Needing to Write

    It takes a wide range of skills to be a scientist. Besides my mathematical, coding, and statistical skills, I need to be a good writer and communicator. Like everything, I need to practice my writing and editing skills. So, I will publish a new idea every week. It may be a blog post, code documentation, a couple paragraphs of an upcoming paper, or something else. With this repetition, I hope to build both my writing skills and a great editing workflow.

  • TypeError from numpy, pandas, and linear algebra

    I was working with some data. I put it into a pandas DataFrame like many data scientists. I built the DataFrame up row by row because sometimes data is not packaged nicely.

    I then tried to plot the resulting data with seaborn’s regplot1 and got an nasty TypeError:

    TypeError: No loop matching the specified signature and casting was found for ufunc svd_n_s
    

    In the trace back this is coming from some deep level in numpy’s linear algebra modules. I tried both the default and robust=True so the issue was not the specific numpy routine since statsmodels also had an issue.

    Finally after many attempts at searching for a solution I found this stackoverflow question with a helpful comment2. It looks like numpy’s linear algebra fails like this if they type is not a float and it prefers a float64.

    I knew my DataFrame only contained numbers but I looked at it more closely. I initialed it like this:

    >>> pd.DataFrame(columns=['hr', 'age'])
    

    And after it was filled I looked at one column and noticed that it defaulted to an generic object type.

    >>> plot['age']
    0      11.2113
    1      4.35541
    ...
    119    3.59919
    Name: age, Length: 120, dtype: object
    

    The issue was found!

    All I needed to do was change my initiation to

    >>> pd.DataFrame(columns=['hr', 'age'], dtype=np.float64)
    

    and everything worked as expected.

    1. Note that other plots did work, just nothing with a fit. 

    2. I am not sure why this is not an answer. But whatever. 

  • Jupiter's Great Red Spot [Link]

    NASA’s Juno spacecraft has a camera called JunoCam. It’s main purpose it to take pictures of Jupiter up-close and personal for the whole world to see. It recently [took images] of the Great Red Spot.

    enhanced-color image of Jupiter’s Great Red Spot

    The Great Red Spot has inspired and perplexed people ever since we first saw it. Juno, with its eight science instruments, is now providing us with the most information we have ever had on this phenomenon. Hopefully soon we will hear what scientist have newly discovered about this strange extraterrestrial storm.

    If this excites you, Juno invites the public to participate in the Juno mission. You can find out more on their website.

subscribe via RSS