<commit_before>package cn.edu.nju.software.jksc.symys.algorithm;

import cn.edu.nju.software.jksc.symys.common.exception.ParameterInvalidException;

/**
 * Created by 缪晓伟 on 2015/6/18.
 */
public class MapGenerator
{
	private static GeneratingAlgorithm[][] algorithmMatrix;

	static
	{
		algorithmMatrix=new GeneratingAlgorithm[7][5];
		algorithmMatrix[3][1]=new Algorithm3x3_1();
		algorithmMatrix[3][2]=new Algorithm3x3_2();
		algorithmMatrix[3][4]=new Algorithm3x3_4();
		algorithmMatrix[4][1]=new Algorithm4x4_1();
		algorithmMatrix[4][2]=new Algorithm4x4_2();
		algorithmMatrix[4][4]=new Algorithm4x4_4();
		algorithmMatrix[5][1]=new Algorithm5x5_1();
		algorithmMatrix[5][2]=new Algorithm5x5_2();
		algorithmMatrix[5][4]=new Algorithm5x5_4();
		algorithmMatrix[6][1]=new Algorithm6x6_1();
		algorithmMatrix[6][2]=new Algorithm6x6_2();
		algorithmMatrix[6][4]=new Algorithm6x6_4();
	}

	public static int[][] generate(int gridSize,int numOfAxis,int numOfMix,int step) throws ParameterInvalidException
	{
		if(gridSize<3||gridSize>6||numOfAxis<1||numOfAxis>4)
			throw new ParameterInvalidException("grid size: "+gridSize+", number of axis: "+numOfAxis);

		if(numOfAxis==3)
			numOfAxis=4;

		int[][] ret=algorithmMatrix[gridSize][numOfAxis].generate(numOfMix);

		//For redundancy
		ret=algorithmMatrix[gridSize][numOfAxis].swap(ret,(int)(step*1.5));

		return null;
	}
}<commit_msg>小C是我错了<commit_after>package cn.edu.nju.software.jksc.symys.algorithm;

import cn.edu.nju.software.jksc.symys.common.exception.ParameterInvalidException;

/**
 * Created by 缪晓伟 on 2015/6/18.
 */
public class MapGenerator
{
	private static GeneratingAlgorithm[][] algorithmMatrix;

	static
	{
		algorithmMatrix=new GeneratingAlgorithm[7][5];
		algorithmMatrix[3][1]=new Algorithm3x3_1();
		algorithmMatrix[3][2]=new Algorithm3x3_2();
		algorithmMatrix[3][4]=new Algorithm3x3_4();
		algorithmMatrix[4][1]=new Algorithm4x4_1();
		algorithmMatrix[4][2]=new Algorithm4x4_2();
		algorithmMatrix[4][4]=new Algorithm4x4_4();
		algorithmMatrix[5][1]=new Algorithm5x5_1();
		algorithmMatrix[5][2]=new Algorithm5x5_2();
		algorithmMatrix[5][4]=new Algorithm5x5_4();
		algorithmMatrix[6][1]=new Algorithm6x6_1();
		algorithmMatrix[6][2]=new Algorithm6x6_2();
		algorithmMatrix[6][4]=new Algorithm6x6_4();
	}

	public static int[][] generate(int gridSize,int numOfAxis,int numOfMix,int step) throws ParameterInvalidException
	{
		if(gridSize<3||gridSize>6||numOfAxis<1||numOfAxis>4)
			throw new ParameterInvalidException("grid size: "+gridSize+", number of axis: "+numOfAxis);

		if(numOfAxis==3)
			numOfAxis=4;

		int[][] ret=algorithmMatrix[gridSize][numOfAxis].generate(numOfMix);

		//For redundancy
		ret=algorithmMatrix[gridSize][numOfAxis].swap(ret,(int)(step*1.5));

		return ret;
	}
}
{'fraction_non_alphanumeric': 0.15379061371841155, 'fraction_numerical': 0.0555956678700361, 'mean_word_length': 7.371601208459214, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '987574', 'n_tokens_mistral': 1090, 'n_tokens_neox': 987, 'n_words': 144}