dataesr/scientific-paragraphs-categorization huggingface dataset:
Conclusions In this paper, we presented our interpretability approach and researches that apply to WSI classification architectures. We proposed a unified design that gather a vast majority of WSI classification methods relying on MIL learning. We motivated and applied a gradient-based attribution method to identify features that have been learned to be relevant in intermediate (tile and slide) descriptors. Then we showed the relevance of these features by visualization (with dataset patches and max activation) and validation by pathologists. These discussions made us consider measuring interpretability by computing explanability heat-maps over whole slides taking into account only identified features. Allying patchbased and slide-based visualization took interpretability to a next level for pathologists to understand histological meanings of features used by trained models.
Discussions With this, we also open a lot of additional questions that could be of critical interest for the development of efficient CAD tools and to guide medical discoveries. We could start by adapting and/or validating the approach to a dataset with more than two classes and also trying fancier explanation methods such as SmoothGrad or Integrated Gradient. Measuring the interpretability could be performed by more pathologists to have quantitative evaluation of tile-level features. It would be also interesting to study the impact of stain normalization pre-processing on identified features and on the quality of featurebased heat-maps. We also want to discuss the fact that it seems that using and mixing together few numbers of features from ImageNet is good enough to describe tissues that can be found on histopathology slides, which may explain the choice of a specific feature extraction model, as long as it is only transfer from pre-training on ImageNet, is not a critical hyperparameter since most popular CNN architectures are able to learn complex features.
The switch rail typically rests directly on a baseplate attached to the sleeper, while the stock rail is connected to the baseplate via a resilient layer, as shown in Figure  1. However, commercial Multibody Dynamics (MBS) software does not readily offer such a track model and the most obvious solution to separate the switch and stock rail is to use the capability they have to model additional wheel contact with a guide or stock rail. This usually allows the user to define another set of possible contact with a fourth and fifth rail body in the track (one on either side potentially). It is to be noted that the separation of the two rails has recently received some interest from the scientific community  [12]  accounting only for the vertical interaction and not taking into account the vehicle or track dynamics, while a dynamic study was presented in  [3].
The purpose of this paper is twofold: • The first part concerns the separation of rails in the lateral direction in the wheel/rail (W/R) contact. The goal is to evaluate the necessity at the contact level to take into account the relative lateral dof of the switch rail with respect to the stock rail, which was not considered in  [3]. • The second objective is to elaborate more detailed track models of the switch panel including the baseplate, to assess their influence on W/R forces, and also on forces between the components of the switch panel. The GB 56 kg rail diverging switch case [45] (Run #2 of the S&C benchmark  [6] ) is considered as the case study in the present paper. Implementations are done in Multibody Systems (MBS) software VI-Rail and VOCO. The base model for the track is the so-called 'co-running' track model as defined in the S&C benchmark.
Case study Run #2 of the benchmark (GB 56 diverging switch case) is chosen as a case study. The reader may refer to a thorough description of the settings in the benchmark statement  [6]. The only modification in the VOCO settings concerns the output sampling frequency, which has been increased to 10 kHz instead of 2 kHz initially. This is due to the introduction of a small mass (baseplate) and high stiffness (contact) in some of the configurations. MBS software VI-Rail and VOCO are used to address the case study. Simple non-Hertzian contact models are implemented in both software packages. VI-Rail uses the Kik-Piotrowski method  [7]  for normal contact and FASTSIM  [8]  for tangential contact. The STRIPES method  [9]  is considered in VOCO in order to handle the normal and tangential contact.
In this study linear stiffness (500 kN/mm) and damping (20 N•s/mm) are introduced in VOCO at the W/R contact level. A Hertzian stiffness with standard steel properties is considered in VI-Rail with a Hertzian damping ratio of 0. 001  [10]. The reader may refer to the summary of the method statements  [11] , to the individual online method statements of each MBS package  [12] , and finally to the paper dedicated to W/R contact written in the frame of this special issue  [13] , for a thorough description of the W/R contact methods used by each software.
In both VOCO  and VI-Rail simulations, this coupling is replaced by a spring with a high stiffness of 15 MN/mm and damping 10 Ns/mm. Next, a series of track models (Figure  4 ) is studied where a baseplate is introduced in the software VOCO. The baseplate is modelled as a mass, linked to the track through a baseplate pad. The switch rail rests on the baseplate with steel on steel contact. Model (a) is the simplest one where the baseplate is connected to the switch rail through stiff springs accounting for the steel on steel contact. In model (b), a unilateral contact is added at the undercut plane of angle φ between the switch rail and the stock rail. No initial gap is considered between the rails. In model (c), the lateral spring is removed at the interface between the baseplate and the switch rail, and is replaced by dry friction with a Coulomb's limit.
Acknowledgements The input from  Xinggao Shu  at  TTCI  is gratefully acknowledged for the several exchanges in conducting two complimentary papers on this topic. The support from the  UK EPSRC project Track to the Future  (grant agreement no. EP/M025276/1 ) and  EU   H2020  project  In2Track2  (grant agreement No:  826255 ) is gratefully acknowledged by co-author Bezin.
The Orbitrap mass spectrometer has recently been proved to be a powerful instrument to accurately measure gas-phase and particle-phase organic compounds with a greater mass resolving power than other widely used online mass spectrometers in atmospheric sciences. We develop an open-source software tool (Orbitool, https://orbitrap. catalyse. cnrs. fr, last access: 4 February 2021) to facilitate the analysis of long-term online Orbitrap data. Orbitool can average long-term data while improving the mass accuracy by re-calibrating each mass spectrum, assign molecular formulae of compounds and their isotopes to measured signals, and export time series and mass defect plots. The noise reduction procedure in Orbitool can separate signal peaks from noise and reduce the computational and storage expenses.
Chemical ionization Orbitrap data from laboratory experiments on ozonolysis of monoterpenes and ambient measurements in urban Shanghai were used to test Orbitool. For the test dataset, the average mass accuracy was improved from < 2 to < 0. 5 ppm by mass calibrating each spectrum. The denoising procedure removed 97 % of the noise peaks from a spectrum averaged for 30 min while maintaining the signal peaks, substantially helping the automatic assignment of unknown species. To illustrate the capabilities of Orbitool, we used the most challenging and complex dataset we have collected so far, which consists of ambient gas-phase measurements in urban Shanghai. These tests showed that Orbitool was able to automatically assign hundreds of molecular formulae as well as their isotopes with high accuracy.
However, the quantitative evaluation of the impact of aerosols on climate is as yet inadequately constrained Published by Copernicus Publications on behalf of the European Geosciences Union. R. Cai et al. :  Orbitool: a new software tool for Orbitrap due to many factors, including an incomplete understanding of how VOC oxidation processes contribute to new particle and secondary organic aerosol formation  (Glasius and Goldstein, 2016). Indeed, the gas-phase oxidation of one single VOC can yield thousands of oxidized products  (Glasius and Goldstein, 2016; Goldstein and Galbally, 2007; Li et al. , 2020; Riva et al. , 2019b). As a result, the chemical variety of OVOCs poses a major challenge in detecting, quantifying, and characterizing such a large number and wide variety of organic compounds.
The demand for a new software tool for analyzing Orbitrap data comes along with applying an Orbitrap in long-term continuous online measurements. The commercial software, Xcalibur™, which was used in our initial studies  (Lee et al. , 2020; Riva et al. , 2019a Riva et al. , , 2020)) , provides an interface for basic data analysis, e. g. , reading single or averaged scans and exporting the time evolution of selected signal peaks. However, more complicated data analysis is usually needed for investigating the complexity and chemical processes occurring within the atmosphere. Hence, some customized software tools, e. g. , RawQuant  (Kovalchik et al. , 2018) , RawTools  (Kovalchik et al. , 2019) , and DIMSpy  (Weber and Zhou, 2019)  have been developed to meet different demands. In atmospheric sciences, the concentrations of some key chemical species (e.
g. , peroxy radicals) in a typical atmospheric environment are extremely low (< 1 ppt). The measured spectra must be averaged over a long period to decrease the noise level so that these low signals can be unambiguously identified among noise. This step implies averaging spectra across files while maintaining mass accuracy. Although facilitated by the high mass resolution of the Orbitrap, a minor proportion of the detected signal peaks still inevitably overlap with each other. Therefore, peak fitting is needed to separate the overlapped signal peaks. In addition, using a list (i. e. , "peak list") of possible species obtained in similar atmospheric environments reduces the expense of data analysis. The aforementioned features have already been realized in existing software tools for analyzing data acquired with CIMS or proton-transfer-reaction (PTR) TOF MS, e.
g. , TofTools  (Junninen et al. , 2010) , Tofware, and other software developed to analyze PTR TOF MS datasets  (Holzinger, 2015; Müller et al. , 2013). It would seem straightforward to convert the Orbitrap raw data into certain formats and then conduct data analysis using these existing software tools. However, due to the high mass resolution of the Orbitrap compared to TOF mass analyzers, the computational expense will be high if analyzing Orbitrap data using, for example, TofTools. This is because the TOF mass spectra are stored on equally spaced grids (with respect to TOF), with data points on the order of 10 4 -10 5. For comparison, approximately 10 8 data points are needed to characterize a single Orbitrap spectrum using this grid-based data structure. Instead, saving only the signals with their adjacent zeros will reduce the computational and storing expenses by orders of magnitude, and the Orbitrap raw data are saved using this data structure.
In addition, TofTools determines the noise level using the equally spaced data within a certain mass defect range, whereas such information is not recorded in the Orbitrap data. As a result, a new software tool for analyzing Orbitrap data is needed to facilitate its application in atmospheric research. In this study, we develop a new software tool, named Orbitool, for analyzing online Orbitrap mass spectrometry data. The working principles and features of Orbitool are introduced. Several test examples using both laboratory and atmospheric data are presented to illustrate and validate its features.
Orbitool Orbitool is a software tool with a graphical user interface (GUI) for analyzing online Orbitrap mass spectrometry data. It is optimized for long-term field or laboratory campaigns and laboratory studies. Flexible input and output interfaces facilitate the coupling between Orbitool and other software. Orbitool's basic working principle is shown in Fig. 1 , which includes data reading and averaging, noise determination and reduction, peak shape determination, mass calibration, signal abundance determination via peak fitting, molecular formula assignment, and data output. The details of these features will be elaborated in the following sections. Orbitool is mainly coded in Python with support from several third-party libraries  (Pedregosa et al. , 2011; Goloborodko et al. , 2013; Levitsky et al.
, 2018). To enhance computational speed, the mass spectra are processed using the Numba package  (Lam et al. , 2015)  and chemical composition and signal abundance are determined using the Cython package  (Behnel et al. , 2011). RawFileReader from Thermo Fisher Scientific is used to read the raw data reported by Orbitrap. Orbitool was tested in Python 3. 6 on the Microsoft Windows operating system. An executable version of Orbitool and its open-source codes are publicly available (see "Code availability").
Data averaging The data collected by the Orbitrap are stored in a RAW file, containing segmented peak intensities and their corresponding masses of each scan, scan filters, event logs, instrumental information, etc. The RAW file records only the spectra of all the detected peaks rather than a dense grid-based spectrum. Most tuning parameters of Orbitrap, e. g. , injection time of each microscan and the number of microscans for every single scan, do not affect the analysis with Orbitool. However, it should be specially clarified that Orbitool is compatible with the profile mode but not the centroid mode of Orbitrap, because attributing chemical formulae to measured signal peaks is based on fitting peaks to the profile data. The first step to analyze raw mass spectrometry data with Orbitool is reading and averaging the spectra.
Since the abundances of most detected species can be extremely low, especially under typical ambient concentrations, averaging is needed for identifying these signal peaks against noise. The raw data can be imported into Orbitool as single files or using a file folder. The user can choose to average all the imported files or a subset of them. The average spectra are calculated based on either scan number or time. For the time-based data averaging, time intervals are determined by the beginning time, the end time, and the duration of each time interval. Orbitool calculates the average spectrum for each time interval. The beginning and end times can be specified by the user, while they are by default obtained from the time range of the input data files. The data recorded in the same file are averaged using an averaging function in the Thermo RawFil-eReader library, and the average is calculated with respect to scan number.
Then, a calibration curve is fitted using a polynomial function and shown on the GUI. The users can set the degree of the polynomial and adjust the calibration curve by using different calibration species. The spectra saved in the same raw data file share the same calibration parameters. The difference between the measured mass and the calibration mass inferred from the chemical formula is shown on the GUI. If the analyzed dataset contains more than one raw file, the trends in these differences for all the calibration species are displayed (Fig. 2b ). The calibration information can also be exported for further analysis. Using lock mass(es) during Orbitrap measurements can improve mass accuracy, but it requires a constantly existing compound in the measured spectra. When charging compounds by chemical ionization, the reagent ion and its dimer are usually in high abundance.
The user may add all the molecular formulae into the mass list or select only a proportion of them. The unidentified chemical species are R. Cai et al. :  Orbitool: a new software tool for Orbitrap shown with empty strings. The mass list can be exported and saved into a CSV file. Alternatively, an existing mass list with a certain format can be imported into Orbitool. The new mass list imported from a file or retrieved from a new mass spectrum can either substitute the existing list or merge with it. Orbitool supports fitting the signal peaks using a mass list instead of fitting all the signal peaks, which reduces the user's workload when analyzing the chemical species in a known system. For instance, when measuring ambient air, the user can average data over a whole day to obtain a mass list.
5, 0. 8] Da. They can also be identified by eye in the mass range from 600 to 750 Da, where only a few signal peaks were detected and noise peaks are at approximately the same height. The noise level in Fig. 4b  is lower than that in Fig. 4a  because it was averaged for a longer period. Of the measured peaks in the Shanghai dataset after the 30 min averaging, 97 % were identified as noise and hence removed. Since no significant mass dependencies on noise and discriminator levels were observed, Orbitool uses size-independent noise and discriminator levels. It should be clarified that some signal peaks with low abundances may be mistaken as noise peaks during noise reduction. Even after averaging for a longer period, some detected compounds with extremely low abundances may still be below the discriminator level.
Summary We developed a software tool named Orbitool for analyzing long-term online Orbitrap mass spectrometry data in atmospheric research. Orbitool is capable of averaging raw data across files while improving the mass accuracy, distinguishing signal peaks against noise peaks, assigning chemical compounds and their isotopes via peak fitting, and exporting time series and mass defect plots. Compared to similar software tools for atmospheric science studies such as TofTools, Orbitool redesigned the storage method for the measured signals so that it reduces the computational and storage expenses. The data measured in a laboratory study on ozonolysis of monoterpenes and in the ambient air of Shanghai were used to test Orbitool. The mass axis uncertainty after calibration using Orbitool was < 0.
5 ppm in this test, which is lower than the average uncertainty of 2 ppm calibrated during mea-surements. The noise reduction was demonstrated to be able to separate signal peaks from noise and reduce the number of saved data. For instance, the total number of peaks of a test spectrum averaged over 30 min was reduced by 97 %. The mass defect plot retrieved using Orbitool indicates that most of the chemical species in urban Shanghai measured by a CI-Orbitrap were organic compounds and reveals the presence of gaseous compounds with unique compositions (i. e. , CHONS, CHOS). Orbitool is open-source and freely available for download (see "Code availability" below). We hope that it will evolve in the future with added features, optimally as a community effort as Orbitrap mass spectrometers become increasingly utilized as tools for online studies within, and possibly outside, atmospheric sciences.
Acknowledgements. We gratefully acknowledge  Jianmin Chen  and  Hui Chen  ( Fudan University ) for their support during the field campaign. We would like to thank  Bin-Yu Kuang  ( Zhejiang University ) for useful discussions. Matthieu Riva  wishes to thank the  French national program LEFE (Les Enveloppes Fluides et l'Environnement ) for their financial support. Financial support. This research has been supported by the  European Research Council (ERC-StG MAARvEL  (grant no. 852161 ) and  ERC-StG CHAPAs  (grant no. 850614 )), the  National Key R&D Program of China  (grant nos. 2016YFC0200104  and  2018YFC0213800 ), the  Academy of Finland  (grant no. 332547 ),.
Programming language identification (PLI) is a common need in automatic program comprehension as well as a prerequisite for deeper forms of code understanding. Image-based approaches to PLI have recently emerged and are appealing due to their applicability to code screenshots and programming video tutorials. However, they remain limited to the recognition of a small amount of programming languages (up to 10 languages in the literature). We show that it is possible to perform image-based PLI on a large number of programming languages (up to 149 in our experiments) with high (92%) precision and recall, using convolutional neural networks (CNNs) and transfer learning, starting from readily-available pretrained CNNs. Results were obtained on a large real-world dataset of 300,000 code snippets extracted from popular GitHub repositories.
Paper contributions We propose an image-based approach for programming language identification that relies on convolutional neural networks (CNNs) which have been pretrained on generic images and subsequently adapted to PLI using transfer learning. We validate the approach on a realworld dataset of 20 million source code files retrieved from popular GitHub repositories, from which we extract a balanced dataset of 300,000 code snippet images encompassing 149 programming languages. We test the approach using three classifiers, each based on a different pretrained CNN for image recognition: a residual network(ResNet)  (He et al. , 2016 ), MobileNetv2 (Howard et al. , 2017) , and AlexNet  (Krizhevsky, Sutskever & Hinton, 2017). We positively answer RQ1, by achieving both precision and recall of 92-93% with the ResNet-and MobileNet-based classifiers.
RELATED WORK Image-based PLI  Kiyak et al. (2020)  compared several image-and text-based approaches to Programming Language Identification (PLI). At a glance, Table  1  in their work reports that the maximum diversity supported by image-based PLI among surveyed works was 8 languages, reached by the same authors in  Kiyak et al. (2020)  with an accuracy of 93. 5% on a dataset of 40 K files. We achieve comparable performances (92% precision and recall) with much higher language diversity (149 languages) and on a larger dataset (300 K snippets). Both approaches use Convolutional Neural Networks (CNNs), the main difference being our usage of transfer learning to adapt pretrained image CNNs. In light of the obtained performances, the saving in training effort enabled by transfer learning appears to validate our choice.
Image-based PLI has been attempted by others too. Ott et al. have  shown how to use CNNs to identify video frames that contain Java code within video programming tutorials  (Ott et al. , 2018a)  (versus frames not showing code at all) and to distinguish frames containing Java from frames containing Python  (Ott et al. , 2018b). In the present work we consider a much larger set of languages. They use real images from screencasts and labelling performed manually by students, whereas we use synthetic images and rely on Linguist  (GitHub, Inc. , 2011)  as source of truth. Hong, Mizuno & Kondo (2019)  (not considered in  Kiyak et al. (2020) ) performed imagebased PLI over 10 languages with 90% accuracy, using snippets from StackOverflow and GitHub, rendering them to bitmaps like we do, but using GuessLang (SOMDA, 2017) as source of truth.
Other visual artifacts Visual development artifacts have also been analyzed for uses cases other than PLI. CodeTube  (Ponzanelli et al. , 2016)  uses Optical Character Recognition (OCR) techniques to index the parts of video programming tutorials that contain code fragments and allows to query them as text. Yadid & Yahav (2016)  used similar techniques to extract code from video tutorials, joining together snippets that spawn multiple frames with OCR error correction. Zhao et al. (2019)  used CNNs to automatically identify common development workflow actions in programming screencasts. The images in our dataset are not from screencasts, but given the high-quality of screencast frames we expect the proposed classifiers to be applicable in that context as well.