gustavoasoares / refazer Goto Github PK
View Code? Open in Web Editor NEWRefazer: Learning Program Transformations from Examples
Refazer: Learning Program Transformations from Examples
Free certificate: https://letsencrypt.org/
When running the test cases, we need to add the Prose and Code Analysis libraries to the test project, otherwise Prose throws an exception. These libraries should not be required since they are already important in the Refazer project.
After trying to update my packages, I got the following error:
Could not install package 'Microsoft.CodeAnalysis.Common 2.2.0'. You are trying to install this package into a project that targets '.NETFramework,Version=v4.5.2', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.
@gustavoasoares, what .NETFramework version do you have?
Currently, the grammar is manually copied to Content/transformation.grammar so that we can run it online. We need to automatically update this file every time it is changed in the Refazer project.
hi,
i am going to use refazer on linux. And when i loaded refazer.sln with Rider, i have seen errors as following.
10/19/17
11:14 AM Project 'Refazer' load finished with warnings: The reference assemblies for framework ".NETFramework,Version=v4.5.2" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend. at (1122:5)
11:14 AM .NET Framework is not found: MsBuild can not find TargetFramework assemblies, specify a Mono MSBuild in settings. You can download the latest stable Mono release. Also install msbuild package.
11:14 AM Project 'Refazer.WebAPI' load failed: The imported project "/usr/share/dotnet/sdk/2.0.0/Microsoft/VisualStudio/v15.0/WebApplications/Microsoft.WebApplication.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk. /usr/info/code/csharp/refazer-0.1/Refazer.WebAPI/Refazer.WebAPI.csproj at (553:3)
11:14 AM MSBuild targets were not found: Make sure that all SDKs required for projects in this solution are installed, or specify a different MSBuild version in settings.
11:14 AM Project 'Refazer.Test' load finished with warnings: The reference assemblies for framework ".NETFramework,Version=v4.5.2" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend. at (1122:5)
11:15 AM Project 'Refazer' load finished with warnings: The reference assemblies for framework ".NETFramework,Version=v4.5.2" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend. at (1122:5)
11:15 AM .NET Framework is not found: MsBuild can not find TargetFramework assemblies, specify a Mono MSBuild in settings. You can download the latest stable Mono release. Also install msbuild package.
11:15 AM Project 'Refazer.Test' load finished with warnings: The reference assemblies for framework ".NETFramework,Version=v4.5.2" were not found. To resolve this, install the SDK or Targeting Pack for this framework version or retarget your application to a version of the framework for which you have the SDK or Targeting Pack installed. Note that assemblies will be resolved from the Global Assembly Cache (GAC) and will be used in place of reference assemblies. Therefore your assembly may not be correctly targeted for the framework you intend. at (1122:5)
It seems to be related with .NETFramework, Version...
Any one here can offer me some suggestion about how to fix this problem...
https://github.com/gustavoasoares/refazer/blob/features/extraction/Refazer.Test/TestUtils.cs#L17-L20
Error preventing successful build:
Severity Code Description Project File Line Suppression State
Error CS7036 There is no argument given that corresponds to the required formal parameter 'id' of 'TestUtils.AssertCorrectExtraction(string, int)' Refazer.Test C:\Users\eglassman\Source\SecondCopyRepos\refazer\Refazer.Test\TestUtils.cs 19 Active
refazer/Tutor/Refazer4Python.cs
Line 109 in 046f831
I'm not sure I need it anymore when creating specs out of pairs of PythonNodes.
Requires learning how to make that part of a test.
Currently, we are sequentially testing all incorrect submissions. The time to test about 300 submissions against one transformation is ranging from a couple of seconds to minutes, depending on the transformation.
One problem is when the transformation leads to an infinite loop or recursion, which stops after the timeout. If there are many timeouts, it will slow down the process.
Try to add parallelism to improve the performance.
hello,
I am doing some research on Programming language correction and i found this project of yours which i think is very interesting.
However, i am not quite familiar with C# and i didnt get to see the results of the project. Can you give me a quick tutorial on how to use it. I tried to build the project in Vscode it gives me some errors when building the refazerweb , and also when trying to execute the Readme tutorial it tells me there is some problems with nuget packages or that it does not recognize the IsNullorEmpty fonction. Also, the test does not succeed only 5 or 6 of them, so i am a bit confused as i would really love to test this project.
If you have some explanation or help it would be wonderful.
Thank you very much
(see interface for text extraction in PROSE repo)
Will try stepping through the call to LearnExtractions.
I'd like to use Refazer on Python programs much like I use PROSE playground (prose-playground.cloudapp.net) on text. :D
Here's the method to adapt:
[TestMethod]
public void TestLearnMultipleExamples1()
{
var examples = new List<Tuple<string, string>>();
var before = @"i = 0";
var after = @"i = 1";
examples.Add(Tuple.Create(before, after));
before = @"i, j = 0, 1";
after = @"i, j = 1, 1";
examples.Add(Tuple.Create(before, after));
TestUtils.AssertCorrectTransformation(examples);
}
I'm trying to create PythonExtraction.cs and it's not working because of this difference. :/
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.