Miracle-dz/UniFAR-FTUs huggingface dataset:
CodeEditor: Learning to Edit Source Code with Pre-trained Models

Developers often perform repetitive code editing activities (up to 70%) for various reasons (e.g., code refactoring) during software development. Many deep learning (DL) models have been proposed to automate code editing by learning from the code editing history. Among DL-based models, pre-trained code editing models have achieved the state-of-the-art (SOTA) results. Pre-trained models are first pre-trained with pre-training tasks and fine-tuned with the code editing task. Existing pre-training tasks mainly are code infilling tasks (e.g., masked language modeling), which are derived from the natural language processing field and are not designed for automatic code editing. In this article, we propose a novel pre-training task specialized in code editing and present an effective pre-trained code editing model named CodeEditor. Compared to previous code infilling tasks, our pre-training task further improves the performance and generalization ability of code editing models. Specifically, we collect lots of real-world code snippets as the ground truth and use a powerful generator to rewrite them into mutated versions. Then, we pre-train our CodeEditor to edit mutated versions into the corresponding ground truth, to learn edit patterns. We conduct experiments on four code editing datasets and evaluate the pre-trained CodeEditor in three settings (i.e., fine-tuning, few-shot, and zero-shot). (1) In the fine-tuning setting, we train the pre-trained CodeEditor with four datasets and evaluate it on the test data. CodeEditor outperforms the SOTA baselines by 15%, 25.5%, 9.4%, and 26.6% on four datasets. (2) In the few-shot setting, we train the pre-trained CodeEditor with limited data and evaluate it on the test data. CodeEditor substantially performs better than all baselines, even outperforming baselines that are fine-tuned with all data. (3) In the zero-shot setting, we evaluate the pre-trained CodeEditor on the test data without training. CodeEditor correctly edits 1,113 programs, while the SOTA baselines cannot work. The results show that the superiority of our pre-training task and the pre-trained CodeEditor is more effective in automatic code editing.
Fully discrete A‐ϕ finite element method for Maxwell's equations with nonlinear conductivity

This article is devoted to the study of a fully discrete A‐ ϕ finite element method to solve nonlinear Maxwell's equations based on backward Euler discretization in time and nodal finite elements in space. The nonlinearity is owing to a field‐dependent conductivity with the power‐law form | E | α − 1 , 0 < α < 1 . We design a nonlinear time‐discrete scheme for approximation in suitable function spaces. We show the well‐posedness of the problem, prove the convergence of the semidiscrete scheme based on the boundedness of the second derivative in the dual space and derive its error estimate. The Minty–Browder technique is introduced to obtain the convergence of the nonlinear term. Finally, we discuss the error estimate for the fully discretized problem and support the theoretical result by two numerical experiments. © 2014 Wiley Periodicals, Inc. Numer Methods Partial Differential Eq 30: 2083–2108, 2014
The dependence of protostar formation on the geometry and strength of the initial magnetic field

BTL acknowledges support from an STFC Studentship and Long Term Attachment grant. This work was also supported by the European Research Council under the European Community's Seventh Framework Programme (FP7/2007-2013 Grant Agreement No. 339248). MRB's visit to Monash was funded by an International Collaboration Award from the Australian Research Council (ARC) under the Discovery Project scheme grant DP130102078. This work used the DiRAC Complexity system, operated by the University of Leicester IT Services, which forms part of the STFC DiRAC HPC Facility (www.dirac.ac.uk). This equipment is funded by BIS National E-Infrastructure capital grant ST/K000373/1 and STFC DiRAC Operations grant ST/K0003259/1. DiRAC is part of the National E-Infrastructure. Calculations were also performed on the University of Exeter Supercomputer, a DiRAC Facility jointly funded by STFC, the Large Facilities Capital Fund of BIS and the University of Exeter. This work also made use of the NumPy (van der Welt, Colbert & Varoquax 2011) and Matplotlib (Hunter 2007) Python modules. Rendered plots were produced using the splash (Price 2007) visualization program.
Questioning the Validity of Summarization Datasets and Improving Their Factual Consistency

The topic of summarization evaluation has recently attracted a surge of attention due to the rapid development of abstractive summarization systems. However, the formulation of the task is rather ambiguous, neither the linguistic nor the natural language processing communities have succeeded in giving a mutually agreed-upon definition. Due to this lack of well-defined formulation, a large number of popular abstractive summarization datasets are constructed in a manner that neither guarantees validity nor meets one of the most essential criteria of summarization: factual consistency. In this paper, we address this issue by combining state-of-the-art factual consistency models to identify the problematic instances present in popular summarization datasets. We release SummFC, a filtered summarization dataset with improved factual consistency, and demonstrate that models trained on this dataset achieve improved performance in nearly all quality aspects. We argue that our dataset should become a valid benchmark for developing and evaluating summarization systems.
Origin of cosmic chemical abundances

Cosmological N-body hydrodynamic computations following atomic and molecular chemistry (e$^-$, H, H$^+$, H$^-$, He, He$^+$, He$^{++}$, D, D$^+$, H$_2$, H$_2^+$, HD, HeH$^+$), gas cooling, star formation and production of heavy elements (C, N, O, Ne, Mg, Si, S, Ca, Fe, etc.) from stars covering a range of mass and metallicity are used to explore the origin of several chemical abundance patterns and to study both the metal and molecular content during simulated galaxy assembly. The resulting trends show a remarkable similarity to up-to-date observations of the most metal-poor damped Lyman-$\alpha$ absorbers at redshift $z\gtrsim 2$. These exhibit a transient nature and represent collapsing gaseous structures captured while cooling is becoming effective in lowering the temperature below $\sim 10^4\,\rm K$, before they are disrupted by episodes of star formation or tidal effects. Our theoretical results agree with the available data for typical elemental ratios, such as [C/O], [Si/Fe], [O/Fe], [Si/O], [Fe/H], [O/H] at redshifts $z\sim 2-7$. Correlations between HI and H$_2$ abundances show temporal and local variations and large spreads as a result of the increasing cosmic star formation activity from $z\sim 6$ to $z\sim 3$. The scatter we find in the abundance ratios is compatible with the observational data and is explained by simultaneous enrichment by sources from different stellar phases or belonging to different stellar populations. Simulated synthetic spectra support the existence of metal-poor cold clumps with large optical depth at $z\sim 6$ that could be potential population~III sites at low or intermediate redshift. The expected dust content is in line with recent determinations.
Ergodicity of explicit logarithmic cocycles over IETs

We prove ergodicity in a class of skew-product extensions of interval exchange transformations given by cocycles with logarithmic singularities. This, in particular, gives explicit examples of ergodic $\mathbb{R}$-extensions of minimal locally Hamiltonian flows with non-degenerate saddles in genus two. More generally, given any symmetric irreducible permutation, we show that for almost every choice of lengths vector, the skew-product built over the IET with the given permutation and lengths vector given by a cocycle, with symmetric, logarithmic singularities, which is \emph{odd} when restricted to each continuity subinterval is ergodic.
Medical Codes Prediction from Clinical Notes: From Human Coders to Machines

Prediction of medical codes from clinical notes is a practical and essential need for every healthcare delivery organization within current medical systems. Automating annotation will save significant time and excessive effort that human coders spend today. However, the biggest challenge is directly identifying appropriate medical codes from several thousands of high-dimensional codes from unstructured free-text clinical notes. This complex medical codes prediction problem from clinical notes has received substantial interest in the NLP community, and several recent studies have shown the state-of-the-art code prediction results of full-fledged deep learning-based methods. This progress raises the fundamental question of how far automated machine learning systems are from human coders' working performance, as well as the important question of how well current explainability methods apply to advanced neural network models such as transformers. This is to predict correct codes and present references in clinical notes that support code prediction, as this level of explainability and accuracy of the prediction outcomes is critical to gaining trust from professional medical coders.
Studying inductive biases in image classification task

Recently, self-attention (SA) structures became popular in computer vision ﬁelds. They have locally independent ﬁlters and can use large kernels, which contradicts the previously popular convolutional neural networks (CNNs). CNNs success was attributed to the hard-coded inductive biases of locality and spatial invariance. However, recent studies have shown that inductive biases in CNNs are too restrictive. On the other hand, the relative position encodings, similar to depthwise (DW) convolution, are necessary for the local SA networks, which indicates that the SA structures are not entirely spatially variant. Hence, we would like to determine which part of inductive biases contributes to the success of the local SA structures. To do so, we introduced context-aware decomposed attention (CADA), which decomposes attention maps into multiple trainable base kernels and accumulates them using context-aware (CA) parameters. This way, we could identify the link between the CNNs and SA networks. We conducted ablation studies using the ResNet50 applied to the ImageNet classiﬁcation task. DW convolution could have a large locality without increasing computational costs compared to CNNs, but the accuracy saturates with larger kernels. CADA follows this characteristic of locality. We showed that context awareness was the crucial property; however, large local information was not necessary to construct CA parameters. Even though no spatial invariance makes training difﬁcult, more relaxed spatial invariance gave better accuracy than strict spatial invariance. Also, additional strong spatial invariance through relative position encoding was preferable. We extended these experiments to ﬁlters for downsampling and showed that locality bias is more critical for downsampling but can remove the strong locality bias using relaxed spatial invariance.
A robust, discrete-gradient descent procedure for optimisation with time-dependent PDE and norm constraints

Many physical questions in fluid dynamics can be recast in terms of norm constrained optimisation problems; which in-turn, can be further recast as unconstrained problems on spherical manifolds. Due to the nonlinearities of the governing PDEs, and the computational cost of performing optimal control on such systems, improving the numerical convergence of the optimisation procedure is crucial. Borrowing tools from the optimisation on manifolds community we outline a numerically consistent, discrete formulation of the direct-adjoint looping method accompanied by gradient descent and line-search algorithms with global convergence guarantees. We numerically demonstrate the robustness of this formulation on three example problems of relevance in fluid dynamics and provide an accompanying library SphereManOpt
THE RED AND FEATURELESS OUTER DISKS OF NEARBY SPIRAL GALAXIES

We present results from deep, wide-field surface photometry of three nearby (D = 4–7 Mpc) spiral galaxies: M94 (NGC 4736), M64 (NGC 4826), and M106 (NGC 4258). Our imaging reaches a limiting surface brightness of ∼ 28–30 mag arcsec−2 and probes colors down to ∼ 27.5 mag arcsec−2. We compare our broadband optical data to available ultraviolet and high column density H i data to better constrain the star-forming history and stellar populations of the outermost parts of each galaxy’s disk. Each galaxy has a well-defined radius beyond which little star formation occurs and the disk light appears both azimuthally smooth and red in color, suggestive of old, well-mixed stellar populations. Given the lack of ongoing star formation or blue stellar populations in these galaxies’ outer disks, the most likely mechanisms for their formation are dynamical processes such as disk heating or radial migration, rather than inside-out growth of the disks. This is also implied by the similarity in outer disk properties despite each galaxy showing distinct levels of environmental influence, from a purely isolated galaxy (M94) to one experiencing weak tidal perturbations from its satellite galaxies (M106) to a galaxy recovering from a recent merger (M64), suggesting that a variety of evolutionary histories can yield similar outer disk structure. While this suggests a common secular mechanism for outer disk formation, the large extent of these smooth, red stellar populations—which reach several disk scale lengths beyond the galaxies’ spiral structure—may challenge models of radial migration given the lack of any nonaxisymmetric forcing at such large radii.
The Role of Gravity in Producing Power-law Mass Functions

Numerical simulations of star formation have found that a power-law mass function can develop at high masses. In a previous paper, we employed isothermal simulations that created large numbers of sinks over a large range in masses to show that the power-law exponent of the mass function, , asymptotically and accurately approaches Γ = −1. Simple analytic models show that such a power law can develop if the mass accretion rate , as in Bondi–Hoyle accretion; however, the sink mass accretion rates in the simulations show significant departures from this relation. In this paper, we show that the expected accretion rate dependence is more closely realized provided the gravitating mass is taken to be the sum of the sink mass and the mass in the near environment. This reconciles the observed mass functions with the accretion rate dependencies, and demonstrates that power-law upper mass functions are essentially the result of gravitational focusing, a mechanism present in, for example, the competitive accretion model.
Charge ordering and correlation effects in the extended Hubbard model

We study the half filled extended Hubbard model on a two-dimensional square lattice using cluster dynamical mean field theory on clusters of size 8-20. We show that the model exhibits metallic, Mott insulating, and charge ordered phases, and determine the location of the charge ordering phase transition line and the properties of the ordered and disordered phase as a function of temperature, local interaction, and nearest neighbor interaction. We find strong non-local correlations in the uniform phase and a pronounced screening effect in the vicinity of the phase transition, where non-local interactions push the system towards metallic behavior. In contrast, correlations in the ordered phase are mostly local to the unit cell. Extrapolation to the thermodynamic limit and control of all sources of errors allow us to assess the regime of applicability of simpler approximation schemes for systems with non-local interactions. We also demonstrate how strong non-local electron-electron interactions can increase electron mobility by turning a charge ordered insulator into a metal.
The long-period massive binary HD 54662 revisited

Context. HD 54662 is an O-type binary star belonging to the CMa OB1 association. Because of its long-period orbit, this system is an interesting target to test the adiabatic wind shock model. Aims. The goal of this study is to improve our knowledge of the orbital and stellar parameters of HD 54662 and to analyze its X-ray emission to test the theoretical scaling of X-ray emission with orbital separation for adiabatic wind shocks. Methods. We applied a spectral disentangling code to a set of optical spectra to determine the radial velocities and the individual spectra of the primary and secondary stars. The orbital solution of the system was established and the reconstructed individual spectra were analyzed by means of the CMFGEN model atmosphere code. We fitted two X-ray spectra using a Markov chain Monte Carlo algorithm and compared these spectra to the emission expected from adiabatic shocks. Results. We determine an orbital period of 2103.4 days, a surprisingly low orbital eccentricity of 0.11, and a mass ratio m2/m1 of 0.84. Combined with the orbital inclination inferred in a previous astrometric study, we obtain surprisingly low masses of 9.7 and 8.2 M⊙. From the disentangled primary and secondary spectra, we infer O6.5 spectral types for both stars, of which the primary is about two times brighter than the secondary. The softness of the X-ray spectra for the two observations, the very small variation of best-fitting spectral parameters, and the comparison of the X-ray-to-bolometric luminosity ratio with the canonical value for O-type stars allow us to conclude that X-ray emission from the wind interaction region is quite low and that the observed emission is rather dominated by the intrinsic emission from the stars. We cannot confirm the runaway status previously attributed to HD 54662 by computing the peculiar radial and tangential velocities. We find no X-ray emission associated with the bow shock detected in the infrared. Conclusions. The lack of hard X-ray emission from the wind-shock region suggests that the mass-loss rates are lower than expected and/or that the pre-shock wind velocities are much lower than the terminal wind velocities. The bow shock associated with HD 54662 possibly corresponds to a wind-blown arc created by the interaction of the stellar winds with the ionized gas of the CMa OB1 association rather than by a large differential velocity between the binary and the surrounding interstellar medium.
Towards quantitative precision in the chiral crossover: Masses and fluctuation scales

We investigate the relation between the physical pion pole and screening masses and the mesonic fluctuation scale in low-energy QCD, which relates to the curvature of the mesonic effective potential. This relation is important for the correct relative weight of quantum, thermal and density fluctuations. Hence, it governs the location of phase boundaries as well as the phase structure of QCD. The identification of the correct physics scales is also primarily important for the correct adjustment of the parameters of effective models for low-energy QCD. It is shown that subject to an appropriate definition of the latter, all these scales agree at vanishing temperature, while they deviate from each other at finite temperature.
Maxwell’s (D, H) excitation fields: lessons from permanent magnets

Macroscopic Maxwellian electrodynamics consists of four field quantities along with electric charges and electric currents. The fields occur in pairs, the primary ones being the electric and magnetic fields ( E , B ) , and the other the excitation fields ( D , H ) . The link between the two pairs of field is provided by constitutive relations, which specify ( D , H ) in terms of ( E , B ) ; this last connection enabling Maxwell’s (differential) equations to be combined in a way that supports waves. In this paper we examine the role played by the excitation fields ( D , H ) , showing that they can be regarded as not having a physical existence, and are merely playing a mathematically convenient role. This point of view is made particularly relevant when we consider competing constitutive models of permanent magnets, which although having the same measurable magnetic properties, have startlingly different behaviours for the magnetic excitation field H .
Principles of kinematics and dynamics

PART I: INTRODUCTION 1. What is Synoptic Meteorology? 2. Units and Variables 3. Coordinate Systems PART II: SCALAR FIELDS AND THEIR KINEMATICS 1. The Pressure Field 2. The Temperature and Moisture Fields 3. The Measurement of Scalar Fields PART III: KINEMATICS OF THE WIND FIELD 1. Properties of the Wind Field 2. Computation of Divergence, Vorticity, and Deformation 3. Properties of the Three Dimensional Wind Field 4. Measuring the Wind Field PART IV: ELEMENTARY ATMOSPHERIC DYNAMICS AND THERMODYNAMICS 1. The Law of Motion 2. The Equation of Continuity 3. The Thermodynamics Equation 4. Friction 5. The Vorticity Equation 6. Energetics 7. Thermodynamic Retrieval PART V: QUASI-GEOSTROPHIC THEORY 1. Introduction 2. Estimating the terms in the Vorticity and Thermodynamics Equation 3. Estimating Vertical Motion from the Observed Wind and Mass Fields 4. Estimating Local Height Tendencies from the Observed Wind and Mass Fields 5. The Quasi-Geostrophic Vorticity and Thermodnamic Equations 6. Derivation of the Quasi-Geostrophic w and Height Tendency Equations 7. Interpretation of the Quasi-Geostrophic w-Equation 8. The Quasi-Geostrophic Potential Vorticity Form of the Height-Tendency Equation 9. Static Stability Effects on Vertical Motion 10. Interpretation of the Quasi-Geostrophic Height-Tendency Equation 11. The Effects of Vertical Variations in Static Stability on the Geopotential-Height Tendency
Models of Uranus' interior and magnetic field

Our understanding of Uranus' interior structure comes from the results of theoretical models. In this chapter, we review the methods for computing such models. We discuss the various physical assumptions employed, and assess their strengths and weaknesses. The accretion theory of the formation of the planets is summarized and the implications for the structure and composition of Uranus are presented. We then discuss the results of the most recent modeling efforts. All of these essentially agree as to the form of the interior density profile, but disagree as to the composition of the material which gives rise to that profile. This is due to the fact that the composition of a mixture is not uniquely determined by its density. This point is elaborated on, in the light of constraints from atmospheric observations, and studies of the chemistry of the deep interior. The implications of these model results are examined for their bearing on three important questions. First, the anomalously low internal heat source of the planet compared to its insolation is discussed. Several characteristic heatflows are evaluated, and it is suggested that convection in stably stratified layers may be the most reasonable interpretation of Uranus' low heat flow. Second, the strongly tilted dipole of the magnetic field is discussed, and a possible explanation is presented. Finally, the chemistry of Uranus' atmosphere and deep interior is reviewed in the context of these models, and the implications of these models for theories of the formation of Uranus are discussed.