dataesr/scientific-paragraphs-categorization huggingface dataset:
Segmentation of spots in diffraction images is critical for accurate grain mapping in 3D. When the grain mapping is done by the recently established lab-based X-ray diffraction contrast tomography (LabDCT), diffraction spots suffering from low signal-to-noise ratios impose a severe challenge in precise identification of the spots using conventional image filters, thereby hindering the detection of small grains and limiting the spatial resolution. To overcome this challenge, we have applied an automatic instance segmentation deep learning network based on Mask R-CNN (two-stage region-based convolutional neural network) for finding spots in LabDCT images. The training data for the neural network was synthesized by combining virtual noise-free images (obtained from a forward simulation model) and noise-only images (obtained by filtering out diffraction spots in experimental images).
Based on the diffraction spots deducted by the forward simulation model, data labelling and annotation was thus performed in an unsupervised manner without the need for tedious human labelling. By applying the network in a PyTorch framework called Detectron2, we show that the trained model performed significantly better than the conventional method in spot segmentation, resulting in a better grain reconstruction, subsequently. The work illustrates the potential of deep learning for improving LabDCT and other grain mapping techniques in a broader sense.
A resulting poor spot segmentation may lead to wrong indexing (including un-indexed and falsely indexed grain orientations) and unsatisfactory grain shape reconstruction. Conventionally, a rolling median background correction combined with various filtering processes, such as the Laplacian of Gaussian filter, are applied for spot segmentation. This method generally works well for spots with good signal-to-noise ratios, whereas it can lead to over or under segmentation of spots with low signal-to-noise ratios. The latter hinders improvement in spatial resolution and sets a grain size detection limit (small grains cannot be resolved). An additional complication is that this conventional routine requires extensive trial and error testing to find an optimal set of processing parameters  [14]. Recently, there has been significant progress in using deep learning methods for image analysis, driven by an increase in compute power and academic competitions using public dataset.
With the aim to explore the potential of Mask R-CNN for i) improving the accuracy and ii) automatizing the process of segmenting diffraction spots, we established Mask R-CNN particularly for LabDCT, but also with a flexibility to be applicable for diffraction images acquired from similar techniques, such as synchrotron DCT. We first trained a Mask R-CNN model using synthetic image data containing realistic noise, and then applied it for real LabDCT images. Similar to our previously developed deep learning framework for removing background noise  [15] , the synthetic images were generated by a forward simulation model combined with a generic approach to extract a realistic experimental background noise. The diffraction spots of the synthesized training images were tuned to capture the common range of signal-to-noise ratios for experimental images.
Generation of synthetic data Synthetic image data was created to train and test the deep learning Mask R-CNN model for segmentation of the diffraction spots in LabDCT images. We first used a forward simulation tool to generate noise-free LabDCT images (I simu ), where only diffraction spots are present, and they are labeled. Three virtual cylindrical Al samples, with random grain orientations and different grain size distributions, were synthesized as input for simulating LabDCT diffraction images at sample rotation angles from -180 • to 180 • with a step size of 2 • , resulting in 181 projection images for each sample. Each projection image contains all the possible diffraction spots from the first 4 {hkl} families of all grains in each sample, excluding the central region where a virtual beam-stop shield all the signals (including both the direct beam and any diffraction spots expected in this region).
The simulated diffraction image has a size of 2032 × 2032 pixels with an effective pixel size of 3. 36 μm in a 16-bit format assuming a dynamic range covering the pixel value from 0 to 65,535. The simulations were performed in a Laue focusing geometry, i. e. with the sample-to-source distance (L ss ) being the same as sample-todetector distance (L sd ), each being 11 mm. An X-ray spectrum from a tungsten anode X-ray tube, operating at 140 kV, was used. The maximum pixel value of the simulated image did not saturate the synthetic detector, but some pixel values were larger than 50,000. More details about the forward simulation model can be found in  [21]  and the code is freely accessible (https://github. com/haixingfang/LabDCT-fo rward-simu-model). To maximize variations in the projections, concerning the number of spots, spot sizes and intensities, we carefully tuned the number of grains and the grain size distribution in each of the three virtual samples, with the intention of capturing features of small spots as precisely as possible.
Typically, we set τ = 1 and I 0 = 110, which is a common background pixel value for experimental LabDCT diffraction images  [22]. We tuned these two parameters to enhance the variations in the signal-to-noise ratios for the generated diffraction images. This method has shown to be able to capture well the features of the real experimental LabDCT diffraction images. An example of I simu and x is shown Fig. 1a-b. Labeled image data serves as the target for training the deep learning network. Accurately labeled spots is essential for obtaining successful training. Although there is no background noise affecting the spot segmentation for I simu , spot overlap affects the accuracy of the spot labelling. As reported in our previous work  [14] , a better separated segmentation of the overlapped spots results in a better grain indexing, even though the grain reconstruction algorithm can tolerate a small degree of spot overlap.
Data labeling and augmentation The labeled images were transformed into a COCO dataset format  [25]  where each spot was labeled as one individual instance with a mask and a bounding box (see Fig. 2a ). To increase the amount of training data, image augmentation, including random flipping, random brightness, random contrast and cropping, was applied. Fig. 2b  shows an example of an augmented image. The settings of image augmentation are given in Table  S1  in Supplementary Materials. To reduce the demand Table  1  Characteristics of three virtual input Al samples. Mean values and standard deviations are given for grain size (equivalent spherical diameter) and number of spots per projection. Note that the later corresponds to the total number of isolated spot regions, which is smaller than the total number of unique hkl reflections as spot overlap occurs in the three samples.
3 ). To train the Mask R-CNN model, the synthetic images for both input image x and labeled content image y c (ground truth) were split into a training dataset (95% = 1031 images) and a validation dataset (5% = 55 images). Similar to  [20] , at each iterative loop of training, a total loss (loss_total), measuring the difference between an output image (ŷ) and a content image (y c ), is calculated for both the training and validation datasets. This total loss is a sum of five different losses, as expressed by: loss total = loss rpn cls + loss rpn loc + loss cls + loss box reg + loss mask,  (3)  where the first two losses (loss_rpn_cls and loss_rpn_loc, corresponding to the classification loss and localization loss, respectively, in the regional proposal network) measure the performance of the first-stage region proposal network (RPN), loss_cls and loss_box_reg are losses in the ROI Head and loss_mask is the loss in the Mask Head (output masks from an input of detected bounding boxes).
Implementation The Mask R-CNN model was, in the present work, implemented based on a PyTorch framework with a Detectron2 model (https://github. com/facebookresearch/detectron2). The training was performed using the above mentioned 1086 synthetic images, where 95% (= 1031 images) were randomly grouped into the training dataset and 5% (= 55 images) into the validation dataset. A standalone computer equipped with a 16-GB GPU (NVIDIA Quadro P5000) was used to train the model. Fig. 4a  shows different contributions of the five different losses to the total training loss. It shows that the four losses, loss_rpn_loc, loss_rpn_cls, loss_box_reg and loss_cls, decay fast to be stable with relative small values, whilst loss_mask requires more iterations to become flat and this loss function plays a major role for the total loss.
This is to test the robustness of the trained model. The trained Mask R-CNN model was applied to the LabDCT projection images for predicting instance masks, i. e. for spot segmentation. The obtained binary images were directly used as input for grain reconstruction with a voxel size of 2. 5 μm applying the commercial software (GrainMapper3D version 3. 1) developed by Xnovo Technology ApS. A standard LabDCT spot segmentation routine was also applied using a rolling median background noise correction and then a Laplacian of Gaussian (LoG) based filtering method to obtain binary images for grain reconstruction. Reconstruction parameters were set as standard (the same as in  [14] ) and held fixed for both reconstructions. Grains were identified from neighboring regions with a maximum misorientation of 0.
Two aspects of the LabDCT grain maps are compared to SR-DCT: how well the grain indexing is and how accurate the grain boundary position is for the commonly indexed grains. The former was done by pairing grains based on their orientations and positions between the two LabDCT grain maps and the SR-DCT. The latter was assessed by calculating the average grain boundary deviation (δ GB ): δ GB = 1 N voxel,GB ∑ ε GB , (5) where ε GB is the Euclidean distance between a grain boundary voxel in the SR-DCT dataset and the nearest voxel on the boundary of the paired grain in the LabDCT dataset (either Lab-Routine or Lab-Mask-RCNN); N voxel, GB is the total number of grain boundary voxels in the SR-DCT dataset. More details on the method for the comparison can be found in  [14]. Table  S2  in Supplementary Materials).
Comparison of grain reconstructions Fig. 8  shows grain maps reconstructed from the synchrotron measurement (SR-DCT) and those from the LabDCT images segmented by the two different methods. Although both Lab-Routine and Lab-Mask-RCNN are largely consistent with SR-DCT, significant differences in details of some grains can be observed by closer examinations on the 3D volumes and the 2D slices: Some grains are present in the slice of SR-DCT but are not in any of the two LabDCT slices (e. g. the ones indicated by the red arrows in Fig. 8a ). Except for the small grains #673 and #693 at the sample surface, other missing grains can be found in other sections of both LabDCT datasets, indicating a spatial shift for reconstructions of these grains (note that this is caused by the imaging technique rather than the physical structural change of the sample between different measurements).
Using the same method for comparing grain indexing as reported previously  [15, 14] , all grains in the datasets can be classified into four categories: one-to-one indexed, one-to-multi indexed (one grain in SR-DCT is indexed by more than one grain in the LabDCT dataset), falsenegatively indexed (a grain that is not indexed in LabDCT dataset but actually exists in SR-DCT) and false-positively indexed (a grain that is indexed in LabDCT dataset but actually does not exist in SR-DCT). The first two categories are true-positively indexed. The latter two categories can be further classified according to the locations of the grains: at sample surface or in sample interior. A summary is given in Table  2. It is found that 22 more grains are correctly indexed (mostly grain size <40 μm, including 1 one-to-multi indexed grain), resulting in 22 fewer falsenegatively indexed grains (8 in the sample interior and 14 at the sample surface) in Lab-Mask-RCNN than Lab-Routine.
Hence, the F 1 score is calculated as F 1 = 2 * P * S/(P + S), a higher score thus corresponds to more accurate indexing. Based on the results in Table  2 , we derived F 1 = 0. 815 for the Lab-Routine and F 1 = 0. 830 for the Lab-Mask-RCNN. It is noteworthy that the current Lab-Routine obtained by the reconstruction with a more recent version of GrainMapper3D software (version 3. 1) has better performance than an older reconstruction with version 2. 3 (F 1 = 0. 802 as reported in  [14]  for the present iron sample), using the same reconstruction settings. A recent summary of the advances on GrainMapper3D software is reported in  [34]. There are 397 commonly indexed grains between the two LabDCT datasets and SR-DCT. For these grains, we can assess the performance of grain shape reconstructions by comparing the deviation of each grain boundary voxel (ε GB ) and average grain boundary deviation (δ GB , see Eq.
Mask R-CNN is also advantageous to use for the spot segmentation compared to the standard routine. Once the model is trained, it can be directly applied to experimental images, even for somewhat different samples and experimental set-ups. For the standard routine, on the other hand, a set of parameters needs to be tuned for each LabDCT dataset and rely on experience in order to generate high quality spot segmentation. Compared to our previously proposed deep learning method used for removing background noise (referred to as DL-BG,  [15] ), the mask-RCNN model has two advantages. First, it outputs instance masks directly and does not require a second step for binarization as the DL-BG does. Second, the Mask R-CNN model does not require a resizing of the input image for making prediction output, whereas DL-BG usually requires a down sampling of the input image for making predictions using the same computing resources.
Conclusions We have applied Mask R-CNN for instance segmentation of LabDCT images with the state of the art library (open source software package Detectron2) implemented in the python deep learning framework PyTorch. We used synthetic data for training the model to perform segmentation of diffraction spots from the LabDCT images. This is the first time that deep learning instance segmentation is used for this image type and the results are superior compared to the standard way of segmentation as well as to our previous deep learning approach, especially in terms of finding small spots and individually segmenting the spot shapes accurately. The Mask R-CNN model enables a better grain mapping compared to the standard routine. As demonstrated for a recrystallized iron sample with many spots in every LabDCT projecton image, 22 additional grains were correctly indexed (out of a total of 458 grains) and the spatial resolution, characterized by the grain boundary deviation, was improved by 30% on average.
The toroidal variation of refraction is negligible according to TORBEAM  [8]. For details of the analysis of the thermo-couple data see  [7]. For higher expected absorption a longer pre-blip was applied in order to reach steady conditions during the phase of mirror. AUG #39747, I p : 800 kA, B t : -1. 6 T. To ensure plasma initiation and to avoid locked-modes in the ramp-up phase the plasma was started with B t : -1. 7 T. The field was changed between 1. 4-2. 6 s. Otherwise identical control parameters as figure 3, except that beam 6 had to be used with 140 GHz since beam 7 was not available. The 105 GHz heating uses up to 5 beams (4 in fig. 3 ). As can be seen from box A, there was a mistake in programming the fifth sweep of launcher 8 in this specific discharge. Consequently, there is no rise of the TC on the respective reflector in box D.
movement. Also shown in box B are the traces for the 105 GHz beams. For the first 3 sweeps the power was constant (4 beams), then it decreased successively (3, 2, 1, 0 beams). Boxes C,D show the reaction of some strayradiation-diodes and the thermo-couple (TC) data. The stray radiation increases significantly towards the end of the discharge, whereas the correlated rise of the TC-data seems to saturate. Box E shows that the variation of the 105 GHz power led to the expected variation of T e , while n e (Box F) was kept at the envisaged low values. The T e data are determined from Thomson-Scattering (TS), since the stray radiation may damage the ECE. After determining the stray radiation levels, the sweeps with higher absorption were repeated with ECE, while those with lower absorption were repeated without the 140 GHz blips, but with ECE.
Except for the cases with non-thermal electrons as discussed in section 2. 2, ECE and TS agreed sufficiently well. Box G shows hard X-ray (HXR) data related to such relativistic electrons, and in figure  3  those are only found as a very small run-away population in the first sec. of the discharge. Also shown in box F is a trace of the recy-cling flux in the main chamber measured with an ionization gauge. It is strikingly in phase with the latter sweeps and the amplitude of the sniffer signals. The increase of the recycling flux must be related to a particle source driven by a sufficiently high level of stray radiation. This is also obvious from the reaction of the line-integrated density signals on these fluxes. As indicated in figure 2 the nonabsorbed power crosses the X2 resonance in the scrape-off layer on the HFS.
We note from figure  5  that the cold X2 resonance for the 140 GHz blips is for beam 6 still just in front of the reflector. For beam 8 (z heat shield ≈ 0. 5 m as in fig. 2 , beam not shown in fig. 5 ), it is in the tile, respectively in the gap. Apparently also a resonance in a gap can lead to a significant particle source. Maybe the solid surface next to the resonance leads to an efficient fueling (production of secondary electrons) for the arc. n e and T e profiles for AUG #39748 closest to 3. 3s, no time averaging. T e data from Thomson scattering (TS) and ECE-emission (T e,rad ). The integrated data analysis (IDA) used the low field side (LFS) ECE data for T e and the interferometry and Lithium-beam data for n e  [9].
Comparison with linear theory The non-thermal effects as described in the previous section are not expected to be relevant in ITER. The larger the machine, the better is the assumption, that an electron leaving an EC beam will thermalize before it re-enters another EC-beam. For the absorption calculation this allows to always assume a Maxwellian velocity-distribution. The absorption profile scales under those circumstances linearly with the input power, since no distortion builds up which would introduce a non-linearity by its dependence on input power. It is this kind of linear theory which was used in the calculations for fig. 1  and for which ITER is interested to test the validity. While in  [3]  the code GRAY was used, on AUG the code TORBEAM  [8]  is used. Both codes differ in the description of the Gaussian beam, but have been successfully bench marked for ITER  [11].
Acknowledgment The views and opinions expressed herein do not necessarily reflect those of the  ITER Organization. This work has been carried out within the framework of the  EUROfusion Consortium , funded by the  European Union  via the  Euratom Research and Training Programme  (Grant Agreement No  101052200 -EUROfusion ). Views and opinions expressed are however those of the author(s) only and do not necessarily reflect those of the European Union or the European Commission. Neither the  European Union  nor the  European Commission  can be held responsible for them. S. S. Denk  acknowledges support of his work by  US DOE  under  DE-SC0016154.
a b s t r a c t Agri-environmental and climate schemes are an important policy instrument in the Common Agricultural Policy of the European Union to maintain biodiversity and safeguard ecosystem services provision for human wellbeing. In the presented dataset, we analyzed 19 innovative contracts for agri-environmental and climate schemes from six European countries, representing examples of four different contract types: result-based, collective, land tenure, and value chain contracts. Our analytical approach comprised three steps: In the first step, we used a method mix combining literature review, web search, and expert consultation to identify potential case examples for the innovative contracts. In the second step, we employed a survey, which was structured in accordance with Ostrom's institutional analysis and development framework to collect detailed information on each contract.
The survey was either filled in by us authors, based on information retrieved from websites and other data sources, or by experts directly involved in the different contracts. Based on the collected data, in the third step, an in-depth analysis was conducted on the public, private, and civil actors involved from different governance levels (local, regional, national, or international) and the roles these actors perform in contract governance. The dataset generated through these three steps contains 84 data files, which includes tables, figures, maps, and a text file. The dataset can be re-used by all interested in result-based, collective, land tenure, and value chain contracts for agri-environmental and climate schemes. Each contract is characterized in great detail by 34 variables making the dataset suitable for further institutional and governance analysis.
Value of the Data • The small-n-dataset ( n = 19) contains examples of innovative contracts exemplifying resultbased, collective, land tenure, and value chain contracts for agri-environmental and climate schemes currently tested with, based on the assumption that they can improve schemes' environmental effectiveness, cost efficiency, and participation options for all relevant stakeholders at the landscape level. • It presents a very detailed account of each contract, using 34 variables per case, which can be grouped based on the five aspects of Elinor Ostrom's institutional analysis and development (IAD) framework: action situation, context conditions, interactions, outcomes, and evaluation criteria (cf. [3]  ) • The dataset is useful for all analytical purposes related to institutional and governance analysis, with a particular focus on the analysis of involved governance actors from different societal spheres (public, private, and civil), who can be engaged from different governance levels (local, regional, national, and international) • The dataset is deemed informative and beneficial for every party (e.
g. researchers, practitioners such as farmers or non-governmental organizations, or policy makers) interested in exploring novel solutions for agri-environmental and climate schemes, which deviate in their characteristics from the currently prevailing individual and action-based contracts that only involve farmers and government agencies as contractual parties. • The dataset is applicable for all methods suited to the analysis of small-n-samples, such as qualitative comparative analysis (e. g. [5]  ) or other qualitative methods. • When further enlarged, possibly narrowing down the number of variables considered per contract, the dataset might also become suitable for quantitative methods and statistical analysis.