A small roller coaster ride as I submitted my first preprint

Standard

 

(I originally wrote this on June 29, 2022 but never posted it)

Roughly 2 years into my PhD program, I finally finished and submitted my first paper manuscript. If you are interested, the preprint is available here on arXiv. As I picked this blog post up again in December 2023, the paper is finally accepted by Ultramicroscopy and is available here as well: https://doi.org/10.1016/j.ultramic.2023.113902.

Rather than talking much about what the paper is about, which you can read yourself, here I would actually prefer to talk about all the events leading to this paper. I looked back and realized yesterday that the thoughts leading to the idea presented in this paper could really have been left in a corner of my desk last November and never be touched again.

(1)

Back in August 2022. The detector I used has the functionality of filtering incoming electrons (or any high-energy particles) based on their energy by applying a threshold. However, I noted that when I set the threshold higher than the primary electron energy of the microscope, the detector still register events, lots of them. I thought the energy calibration is off (turns our this is simply because of pile-up, so many electrons are registered as a single event but with sum of their energies).

The manufacturer of the detector told me to do an energy spectra collection, which requires another data readout mode optimized for sparse events, and typical STEM-in-SEM beam currents are too high to give the desierd “sparsity”. So this readout mode does not work. Had it work, we could do spectra imaging with electrons and evelate our experiments. Though at that time I am not aware of this limitation, and thus I had some discussions with the manufacturer of the detector. 

To show them my confusion, I collected the patterns using both the conventional readout and the new readout, the former gives the diffraction pattern and the latter doesn’t. I also captured the patterns at different exposure times (this eventually becomes FIgure 3(a) and (b) in the paper), and tried to compare total event counts for the two modes. Eventually, another detector expert was able to answer my questions.

(1)

In late November, when I had pretty much gave up on the spectra imaging prospect, my supervisor had a look at the slides I made for the manufacturer again, and mentioned something vaguely about the prospect of combining these patterns for a better one. The sentence started from “I am sure there is something you could do re……”.

Now that the paper is finalized, I could not quite remember how lost I was hearing these instructions. But I knew I had no idea how to make it happen. So roughly a week later, I showed up in my supervisor’s office with no prior notice, and asked him to explain his idea. Eventually, he made 3 sketches on paper.

Still, at that time my focus was on detector characterization, so if anything this is a secondary objective. However, our SEM broke down on December 7th and repair schedule is unknown, probably after the Christmas break.

So, I had to find things to do, and dug out the 3 pieces of paper my supervisor made sketches on, and started programming in MATLAB. It took me a while to get everything going and at its very beginning stage, the code is quite primitive, no loops, no indices, and I keep forgetting it’s “~=” rather than “!=” in MATLAB. After a few days, a final pattern was produced according to our initial plans.

Feedback? “That’s beautiful”. This makes me realize that we might be onto something. After the turn of the year, I decided to talk about this routine on our research group meeting, which is the first time I present my own results since I joined (if not counting the 2 exam rehersals in March and August 2021).

Since my diffraction experiments usually requires a long SEM session, I work a lot on Saturdays. One of these Saturdays when I tried to collect some data with software masking of the detector (masked pixels are turned off during data collection) using an aluminum sample, I collected an interesting dataset and processed it with the code I wrote, indexed the resulting pattern and showed to my supervisor again.

Feedback? “Woah – that is super pretty!!!!!!” (all 6 exclamation marks reproduced here). So we decided to write the first draft paper you see today. The “super pretty” pattern is now the demonstration pattern in Figures 4-6. The first draft was ready as early as in March and my supervisor said “it reads”. But this is still not the full story.

(2)

At this stage, we thought that the theoretical framework of pattern processing and the demonstrative aluminum pattern alone might not be enough for a full-length paper, so it would be better to see if the same method works on other materials, because it should. With this in mind, I borrowed some samples from a colleague who deemed the samples no longer useful to her. The sample is interesting, and we know the candidate phas but also different. A lot of time was spent on phase identification on what seems to be an unknown structure.

In addition, I started to prioritize “other project”. Until a few weeks ago, when I received an alert on a new paper, which basically did the “other project” I have been doing. This is only a few days after one of the milestones of my detector characterization experiments. I panicked a lot and panic-wrote my own version of the detector paper.

While I panicked, my supervisor was preparing for a workshop talk and asked me to provide a few diffraction patterns. Afterwards, according to him, one of the attendees, who seems to be a tough audience, was impressed with my processing method and the final result.

It was in that instant that I asked if we can submit the paper without the extra work on the borrowed samples, or any other sample. I reopened that Word document which I haven’t opened in 3 months, and started editing. Since this is a panic reaction and also important thing for my PhD program, I also work on the file on Saturdays and tried to put together everything needed for the submission.

My supervisor, on the other hand, wants to add a bit more to the paper now that the planned content on the extra samples are gone. He wanted to work on something different with my pattern, something hasn’t been done in a while by him. This code alone took more than a week for him to complete, while he was attending another conference and trying to promote my work to a number of microscopists. For this I am quite thankful as we both realize that the paper will be even better with these extra work. This piece of “extra work” becomes the reprojection and fully experimental stereogram, i.e. Figure 7 and 8.

(3)

At this point, most of our discussions and collaborations are about the manuscript and figures. An very important aspect of the work, my code, was not touched or checked by my supervisor yet. As he tried to merge my code into the AstroEBSD repository, he “function-ized” a lot of the routines in my code and had frequently asked me to see if the new version works. Indeed, the new version is concise and, agree to disagree, probably more elegant.

As he travelled to Europe yet again, so in order to catch up as quickly as possible thanks to the time difference, I check my messages and emails immediately after I wake up, and make edits accordingly. Everything went according to the plan, and we plan to submit to a journal and arXiv on Friday, June 23th.

Friday morning when I woke up, this message shows up:

Need you to check / verify something // I have updated the matlab code for the paper release

I thought it would just be testing, so despite it was 6 AM, I started debugging in my bed. But the edited code had a multiplicity of errors when I ran them. When I managed to make the program run, what could finish in 7 seconds now finishes in 7 minutes, and I had no clue about what I could do. The issue was related to generating FIgure 3(e). The anxiety quickly climbed to a level where I was almost blinded by rage.

I replied at least twice “I don’t know how to fix it” and even thought about not being able to submit the paper on my bus ride to the university. Luckily, it was in June, so the bus ride was  otherwise pleasant…

6 hours later, sitting in my office, I realized that there is an alternative way, and after some crunching the code works again at the intended speed and produces the result I wanted. Of course, due to time zone issues, it is already a bit late to submit the paper on Friday.

The wait did not last too long, as I got confirmation from him Sunday at 1:21AM that everything is submitted. I saw the messages and emails after I woke up and made a long, long exhale.

(4)

So yes, the paper started from a dataset not originally collected for this purpose. I had two panic attacks and lots of rage and frustration. However, if things did not unfold in this way, the sketch papers with my supervisor’s idea would still sat on my bookshelves, collect dust and might never be picked up by me ever.