dataesr/scientific-paragraphs-categorization huggingface dataset:
In the following, we chose the Resnet50 network  (He et al. , 2016)  as the CNN encoder, which we found to outperform the Inception model for this task. We trained the model on ~1,400 manually segmented brightfield images using three output classes (i. e. 'background,' 'mother cell,' 'other cell') in order to discriminate the mother cell of interest from the surrounding cellular objects. We used a separate test dataset containing ~500 labeled images to evaluate the performance of the classifier (see Methods for details about the generation of the groundtruth data sets). Our results revealed that mother cell contours could be determined accurately with a trained classifier (Figure  5A -C and Figure  5 -figure  supplement 2A-D ). In addition, we used a cross-validation procedure based on random partitioning of training and test datasets that highlighted the robustness of the classification (Figure  5 -figure  supplement 2E ).
Microfabrication The designs were created on AutoCAD to produce chrome photomasks (jd-photodata, UK). The microfluidic master molds were then made by standard photolithography processes. The designs were created on AutoCAD (see https://github. com/TAspert/DetecDiv_Data; Aspert, 2021 to download the design) to produce chrome photomasks (jd-photodata, UK). Then, the microfluidic master molds were made using two rounds of classical photolithography steps. The array of 2000 traps was created from a 5. 25 µm deposit by spinning (WS650 spin coater, Laurell, France) 3 mL of SU8-2005 negative photoresist at 2500 rpm for 30 s on a 3" wafer (Neyco, FRANCE). Then, a soft bake of 3 min at 95 °C on heating plates (VWR) was performed, followed by exposure to 365 nm UVs at 120 mJ/cm² with a mask aligner (UV-KUB3, Kloé, FRANCE).
Sample holder and temperature control We designed a custom 3D-printed sample holder (by extruding PLA material with a MK3S+printer, Prusa Research, Czech republic) for the microfluidic device to ensure the mechanical stability of the microfluidic device (design available on github: https://github. com/TAspert/ITO_heating_device;  Aspert, 2022). In addition, we developed a custom temperature control system to maintain a constant temperature (30 °C) and guarantee optimal cell growth throughout the experiment. Briefly, we used an Indium Tin Oxide (ITO) Coated glass, an electrically conductive and transparent material, in direct contact with the PDMS chip. Therefore, applying a voltage to the ITO glass heat the glass and the adjacent PDMS chip by Joule effect (Figure  1 -figure supplement 1A).
To achieve a temperature control loop, we used an infrared sensor attached to the objective and facing towards the bottom glass coverslip in contact with the cells. The sensor allowed in situ temperature measurement and was used in an Arduino-based PID control loop to regulate the heating power to maintain the setpoint temperature (the circuit diagram is available on github: https://github. com/TAspert/ITO_heating_device; Aspert, 2022). About 0. 3 W was sufficient to maintain a 30 °C temperature at room temperature. Notably, the temperature profile obtained with this method was homogenous and constant throughout the experiment. Furthermore, the glass is fully transparent to visible light. In addition, it does not interfere with fluorescent light when using an inverted microscope since it is located at the end of the optical path, after the sample.
Software and time-lapse acquisition parameters Micromanager v2. 0. was used to drive the camera, the light source, the XYZ controller, and the LED light source for fluorescence epi-illumination. We developed a specific program in order to drive the temperature controller from the Arduino (The source code is available on github: https://github. com/ TAspert/ITO_heating_device;  Aspert, 2022). Unless specified otherwise, the interval between two brightfield frames for all the experiments was 5 min, and images were recorded over 1000 frames (i. e. ~3 days). We used three z-stack for brightfield imaging (spaced by 1. 35 µm) to ease the detection of small buds during the image classification process for cell state determination. Fluorescent images were acquired with a 10 min interval using 470 nm illumination for 50ms.
Autofocusing To keep a stable focus through the whole experiment, we developed a custom software-based autofocus routine that finds the sharpest image on the first field of view and then applies the focus correction to the rest of the positions (https://github. com/TAspert/DetecDiv_Data;  Aspert, 2021). This method provides faster scanning of all fields of view in a reasonable time. Nevertheless, it is almost as efficient as performing autofocusing on each position since the primary source of defocusing in our setup is the thermal drift, which applies identically to all the positions.
Additional datasets for the comparative study of division detection Time-lapse image datasets of individual mother cells trapped in microfluidic devices were obtained from the Murat Acar and Peter Swain lab. The datasets were used to compare the performance of our cell division tracking pipeline, as described in the main text. Data from the Acar lab were generated on a Nikon Ti Eclipse using ×40 brightfield imaging with a 10min-interval and a single z-stack, as previously described  (Liu et al. , 2015). Data from the Swain lab were obtained using a Nikon Ti Eclipse microscope using ×60 brightfield imaging, a 2. 5min-interval  (Crane et al. , 2014; Granados et al. , 2018) , and 5 z-stacks combined into a single RGB image and used as input to the classifier. We also used a separate trap design from our own lab that is similar to a previously reported design  (Jo et al.
Image processing DetecDiv software We developed Matlab software with a graphical user interface, DetecDiv, which provides different classification models: image classification, image sequence classification, time series classification, and pixel classification (semantic segmentation), see Supplementary file 2 for details. DetecDiv was developed using Matlab, and additional toolboxes (TB), such as the Computer Vision TB, the Deeplearning TB, and the Image Processing TB. A graphical user interface (GUI) was designed to facilitate the generation of the training sets. The DetecDiv software is available for download on GitHub: https://github. com/gcharvin/DetecDiv  (Aspert, 2021)   DetecDiv can be used with an arbitrarily large number of classes, image channels, types, and sizes. Indeed, several classification models can be defined to process the images: (1) Image classification using a convolutional network (CNN, see Figure  2 -figure supplement 1); (2) a combined CNN+LSTM classifier (Figure  2A ); (3) an LSTM network to perform sequence-to-sequence (as in Figure  4A ) or sequence-to-one classification; (4) An encoder/decoder classifier to perform pixel classification (semantic segmentation) based on the DeeplabV3 + architecture  (Chen et al.
DetecDiv training and validation procedures are run either at the command line, which allows using remote computing resources, such as a CPU/GPU cluster, or using a Matlab GUI application. All the relevant training parameters can be easily defined by the user. Moreover, we designed generic routines to benchmark the trained classifiers that allow an in-depth evaluation of the classifiers' performances  (Laine et al. , 2021). Trained classifiers can be exported to user-defined repositories and classified data can be further processed using custom Matlab scripts, and images sequences can be exported as. mat or. avi video files. Last, DetecDiv provides additional post-processing routines to extract cell-cycle, lifespan and pixel-related (volume, signal intensity, etc) data for further analysis, as performed in the present study.
, 2015)  to classify images according to these six classes using a training set of 200,000 representative manually annotated brightfield images (i. e. 200 ROIs monitored during 1000 frames). Of note, the number of images used for training results from a trade-off between the desired accuracy of the model and the time required to build the training set. The training of the classifier was achieved using Adaptive Moment estimation (Adam) optimizer  (Kingma and Ba, 2015). Specific parameters used can be found in the Figure  2 -source data 1. After the training procedure, we tested the classifier using a dataset composed of 50 independent ROIs (i. e. ~50,000 images) that were manually annotated and used for benchmarking (Figure  2 figure supplement 2).
Image sequence classification using combined CNN and a long short-term memory network (LSTM) To provide a more accurate classification of the image according to the cellular state, we added a bidirectional long short-term memory (LSTM) network with 150 hidden units to the CNN network  (Hochreiter and Schmidhuber, 1997). The LSTM network takes the whole sequence of images as input (instead of independent images in the case of the CNN). 200 ROIs (with 1000 frames each) were used to train the LSTM network independently of the CNN network (see training parameters in Figure  2 -source data 1 and benchmarks on Figure  2 -figure supplement 2B-D). The CNN and the LSTM network were then assembled as described in Figure  2A  in order to output a sequence of labels for each sequence of images. The assembled network was then benchmarked using a set of 50 independent annotated ROIs, as described above.
Assessment of cell-cycle slowdown using an LSTM network We designed a time series classification method to identify when the cell cycle starts to slow down (Senescence Entry Point, or SEP, see Results section). For this, we trained a bidirectional LSTM network with 150 hidden units to classify all the frames in each lifespan, into two classes, 'pre-SEP and 'post-SEP', using a manually annotated dataset containing 200 ROIs. To achieve these annotations, we designed a custom annotation GUI allowing us to monitor the successive states of a mother cell of interest over time, as output by the CNN+LSTM network above. This tool was convenient to detect the cell cycle slow down occurring upon entry into senescence. Then, the LSTM network was trained using class probabilities from the previously described CNN+LSTM (unbudded, small, large, dead), see.
Brightfield and fluorescence images semantic segmentation using DeepLabV3+ Cells and nuclei contours were determined based on brightfield and fluorescence images, respectively, using the deep learning-based semantic segmentation architecture DeepLabV3+  (Chen et al. , 2018). To generate the groundtruth data required to feed both the training and test datasets, we developed a graphical user-interfaced routine to 'paint' the input images, a process which took about.
Acknowledgements We thank  Audrey Matifas  for constant technical support throughout this work,  Sophie Quintin  and  Nacho Molina  for carefully reading the manuscript. We are very grateful to  Murat Acar  and  David Moreno Fortuño , as well as  Peter Swain  and  Julian Pietsch  for providing the additional time-lapse datasets analyzed in this study. We thank  Olivier Tassy  for their insightful discussions. We thank  Denis Fumagalli  at the  IGBMC Mediaprep facility  for media preparation. We are grateful to the IT service for efficient support and providing the computing resources. We thank the  Charvin lab  members,  Bertrand Vernay ,  Jerome Mutterer ,  Serge Taubert , and the  IGBMC imaging facility  for discussions and technical support. This work was supported by the  Agence Nationale pour la Recherche  (T.
Code The custom MATLAB software DetecDiv, used to analyze imaging data with deep-learning algorithms, is available on https://github. com/gcharvin/DetecDiv. This software distribution features a tutorial on how to use the graphical user interface: https:// github. com/gcharvin/DetecDiv/blob/master/Tutorial/GUI_tutorial. md. It also provides the main commands to use the DetecDiv pipeline in custom user-defined scripts: https://github. com/gcharvin/DetecDiv/blob/master/Tutorial/commandline_tutorial. md. A demo project that contains all the necessary files to learn how to use DetecDiv can be downloaded from zenodo: https://doi. org/10. 5281/zenodo. 5771536.
15-30 s per image depending on the number of cells in a 60×60 pixel-large field of view. We trained the network using a training set containing 1400 and 3000 images for brightfield and fluorescence images, respectively (see Figure5-figure supplement 2 and Figure5-figure supplement 3 for benchmarking results). Specific parameters used can be found in the Figure5-source data 1 (cell segmentation) and Figure5-source data 2 (nucleus segmentation). In addition, we have implemented a cross-validation routine to test the sensitivity of the classifier used for cell segmentation to the training and test datasets. For this purpose, we have performed 30 successive random draws of 200 annotated ROIs to be used as a training set and 50 annotated ROIs for testing the classifier (the total number of manually annotated ROIs is 250).
Lifespan analyses: ○ Training and test datasets: doi. org/10. 5281/zenodo. 6078462 ○ Trained Network (CNN+LSTM): doi. org/10. 5281/zenodo. 5553862 • Brightfield image segmentation: ○ Training and test datasets: doi. org/10. 5281/zenodo. 6077125 ○ Trained Network (Encoder-Decoder DeeplabV3+): doi. org/10. 5281/zenodo. 5553851 • Cell-cycle slowdown (Senescence Entry Point) detection: •.
However, these experiments are carried out on isolated films, and the extrapolation of these observations to the evolution of the 3D structures such as liquid foams where other effects impact the drainage is far from trivial. 0] [41] [42] [43] [44] [45] [46] [47] [48]  SANS data also provide information on the internal structure of the foam solution over a large length scale. The relatively large diameter of the beam (a few tens of millimetres) allows the probing of several hundred bubbles and films. This method, therefore, provides acceptable statistics on data collected during time scales of a few minutes, a sufficient temporal resolution if the foam does not collapse too quickly. The first cell was manufactured in the early 2000 s and consisted of a Plexiglas cell with a quartz window allowing the study of foam at a single given height.
49 Since then, interest in this technique has continued to grow with new cells recently developed. 50 The technique has been employed to investigate stimuli responsive foams,  42, 43  foams stabilized by polymeric surfactants,  44  proteins,  45  or, more recently, nano-ions. 47 hile SANS enables us to determine with precision the thickness of films in real foams, it is essential to characterize the foam in its entirety and on all its scales simultaneously: from the bubble to the film, in order to optimize the different parameters involved in the aging of the foam. To address this challenge, we have developed a new device that enables to simultaneously collect microscopic information on the foam via SANS experiments and macroscopic information, with the acquisition of 2D images using an optical camera, as well as conductivity data measured through the foam.
Materials The non-ionic surfactant polyoxyethylene (10) oleyl ether surfactant BrijO10 (C 18:1 E 10 ) and the ionic surfactant sodium dodecyl sulfate (SDS, NaC 12 H 25 SO 4 , Z99. 0%) were purchased from Sigma Aldrich and were used without further purification. The data presented in this article were conducted with a foam stabilized with 0. 5 mM BrijO10 which is well above the critical micelle concentration of 40 mM molar  51  and upon addition of 0. 2 mM SDS. Samples were prepared in Millipore water for Foam-analyser experiments and in D 2 O purchased from Eurisotop (99. 9% isotopic purity) for small-angle neutron scattering (SANS) experiments.
55 The empty cell signal was subtracted for each scattering curve. The absolute scale was obtained by normalizing the neutron beam flux. The experiments described in this article were performed at the height of the second prism, at 8 cm above the level of the solution at rest. SANS experiments were also conducted on foaming solutions in a quartz cuvette of 2 mm thick on the D22 diffractometer to obtain structural information of micellar solution. In this configuration, neutron wavelength was also set at 6 Å and with two detector distances at 1. 4 and 17. 6 m and with a 17. 6 m collimation, resulting in a q-vector range from 0. 003 to 0. 64 Å À1. The SANS data analysis was performed in absolute units, considering the scattering length densities and molecular volumes given in Table  S1  in the ESI.
Data collection The foam is generated in the quartz cell from the foaming solution containing the nonionic surfactant Polyoxyethylene (10) oleyl ether (Brij O10) at 0. 5 mM doped with 0. 2 mM sodium dodecyl sulfate. The molar ratio of anionic to nonionic surfactant is 1/2. 5. The gas flow is stopped once the column is filled, defining the starting point t = 0 of the time-resolved experiments. The structure of the foam is then investigated as a function of time at the level of prism 2 for this study, at approx. 8 cm above the liquid surface, as shown in Fig. 2c. The measurement of the conductance was performed simultaneously through the foaming solution and the foam at three different heights. Fig. 3  presents a typical set of kinetics data recorded simultaneously during the free drainage of a foam: 2D SANS scattering data (Fig.
Image processing The collected optical images were binarised to extract the relevant information: bubble size, liquid volume fraction, specific surface area of the foam, and radius of the Plateau borders. This binarisation process was automated using the ''Adaptive Threshold'' command from OpenCV package,  56  for which the binarisation threshold value varies for each pixel depending on the gray level of its neighborhood. Once the image is binarised, ''findContours'' and ''drawContours'' commands from OpenCV package  56  are applied to remove artefacts from impurities within the bubbles. The source code used for the image treatment is provided in Section S2 of the ESI. † An updated version of the software is freely available at https:// github. com/leonardo-chiappisi/pyFoam_analysis. From the binarised images, the surface area of each bubble in contact with the wall of the column S bubble was measured as well as their surface radius expressed as r ¼ ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi ffi S bubble =p p.
Conductance data The liquid fraction f is also determined using electrical conductance values. This measurements is possible for the investigated system thanks to the presence of a charged surfactant. The following empirical relation is valid for both wet and dry foams: 59 f ¼ 3s r ð1 þ 11s r Þ 1 þ 25s r þ 10s r 2 (4) with s r = s foam /s liquid the ratio between the measured conductivity through the foam and the liquid. The ratio of conductivities s r can be approximated by the ratio of conductances G r = G foam /G liquid = ks foam /ks liquid = s r since the constant cell k is similar at all heights of the cell. For the BrijO10 + SDS solution, the conductance measured at the bottom of the cell is equal to G liquid = 10. 5 mS. As can be seen in Fig. 3e , since the electrodes are located below and above the prism, the conductivities are averaged to provide the value of f at the height of the neutron beam.
Liquid fraction. To obtain information about drainage, the time evolution of the liquid fraction f was determined. As mentioned previously, four independent techniques were used: conductance measurements, image analysis, neutron beam transmission, and SANS data analysis. The data from the four techniques are given in Fig. 8a. The SANS data give an overestimated value of f compared to the other techniques which will be discussed in the Section 4. 2. For the three other methods, although slight differences are visible, they are consistent and provide a clear trend for the evolution of the liquid volume fraction in the foam as a function of time. These three methods have different strengths and weaknesses to estimate the liquid volume fraction within the foam at a given height: electrical conductivity is a reliable and robust method when the system is rich in charge, but it can be applied to conductive solutions only; f obtained from the image analysis suffers from the choice of the threshold during the binarisation procedure and is limited by the camera resolution.
However, it can be applied to any foam, even non-ionic ones. Neutron transmission suffers from a low signal-to-noise ratio and although the measurements are taken primarily to obtain absolute units of the SANS data they are also used in this context to corroborate the correctness of the solution volume fraction at a given height in the foam and as a function of time. In our experiments, and in particular at high times (after 20 min), the measured conductance is low and close to the sensitivity limit of the conductivity meter (see Fig. 3e ) which explains the large uncertainty of the liquid fraction. Despite different strengths and weaknesses, all three methods give similar results and make it possible to determine the time evolution type of the foam quality: wet foam (f 4 10%), dry foam (f o 5%) or very dry foam (f o 1%).
Accordingly, the data between 10 and 20 min were fitted assuming a ''thick'' film of 60 nm. This dimension has, however, no real physical meaning. While the thickness of the foam films cannot be determined, this approach allows us to calculate the specific surface of the films from the intensity of the reflected signal below the total reflection angle q around 0. 15 Å À1. From 20 min onward, all structural parameters -the liquid fraction f, the inter-bubble film thickness h, the specific surface areas from the Plateau borders S/V| PB and from the films S/V| film -can be obtained from the fit of the SANS data, and are shown in Fig. 9. The liquid fraction obtained from the SANS analysis varies from 4 down to 2% in this time range. It appears to be overestimated compared to the values determined using conductance, neutron transmission, and image analysis.
Their sum agrees very well with the results from the image analysis, at least in the last 30 minutes, supporting the use of the absolute scale in the scattering experiment. In particular, the analysis of the SANS data allows us to discern directly between the two specific surface areas, S/V| PB and S/V| film. While the surface area of the foam film decreases only moderately with time, the Plateau border area decreases significantly within the investigated time range, from 100 to less than 10 cm À1. The Plateau borders specific surface area decreases with a bi-exponential law (see Fig. S8  in the ESI †), with characteristic times of (7 AE 1) and (42 AE 2) minutes. In contrast, the specific surface area of the films decreases slowly, mostly linearly in time. Thus, the sum is dominated by the Plateau borders contribution at the beginning of drainage and then by the foam film when the foam is aged and dried.
Conclusion In summary, the analysis of foam stability requires the collection of a wide range of information from the nano-to the centimetre scale that has to be correlated for a better understanding of the underlying processes. While such a multi-scale analysis is mostly performed using different techniques separately in the literature,  34, 77  herein the evolution of foam has been followed simultaneously using macro-photography, electrical conductivity, and small-angle neutron scattering. The combination of these three techniques allows us to perform this multi-scale analysis in real-time on a given sample. In particular, the analysis in absolute scale of the SANS data allows quantifying of the specific surface areas from Plateau borders and from inter-bubble thin films as well for which time their evolution can be correlated to the film thickness variation, while the analysis of the SANS data in arbitrary units only provided reliable values for the foam film thickness.