diff --git a/matlab/fixtures/export_class_equivalence_fixtures.m b/matlab/fixtures/export_class_equivalence_fixtures.m new file mode 100644 index 00000000..35625557 --- /dev/null +++ b/matlab/fixtures/export_class_equivalence_fixtures.m @@ -0,0 +1,195 @@ +function export_class_equivalence_fixtures(nstatRoot, outRoot) +%EXPORT_CLASS_EQUIVALENCE_FIXTURES Create MATLAB-gold fixtures for class contracts. +% export_class_equivalence_fixtures(nstatRoot, outRoot) +% +% Inputs +% nstatRoot - path to MATLAB nSTAT source-of-truth repo +% outRoot - output root where class fixture .mat files are written +% +% Notes +% - This script is deterministic (rng fixed). +% - It writes compact fixtures used by Python class-contract tests. + +if nargin < 1 || isempty(nstatRoot) + envRoot = getenv('NSTAT_MATLAB_ROOT'); + if isempty(envRoot) + error(['nstatRoot not provided. Pass source root explicitly or set ', ... + 'NSTAT_MATLAB_ROOT environment variable.']); + end + nstatRoot = envRoot; +end + +if nargin < 2 || isempty(outRoot) + here = fileparts(mfilename('fullpath')); + outRoot = fullfile(here, '..', '..', 'tests', 'parity', 'fixtures', 'matlab_gold', 'classes'); +end + +if exist(nstatRoot, 'dir') ~= 7 + error('nstatRoot does not exist: %s', nstatRoot); +end + +addpath(nstatRoot); +rng(0, 'twister'); + +if exist(outRoot, 'dir') ~= 7 + mkdir(outRoot); +end + +write_confidence_interval_fixture(outRoot); +write_trialconfig_fixture(outRoot); +write_configcoll_fixture(outRoot); +write_cif_fixture(outRoot); +write_fitresult_and_summary_fixtures(outRoot); + +fprintf('Wrote class fixtures to %s\n', outRoot); +end + +function write_confidence_interval_fixture(outRoot) +classDir = fullfile(outRoot, 'ConfidenceInterval'); +if exist(classDir, 'dir') ~= 7 + mkdir(classDir); +end + +time = (0:0.25:1.0)'; +ci_data = [time, time + 0.5]; +ci = ConfidenceInterval(time, ci_data, 'CI', 'time', 's', 'a.u.', {'low', 'high'}); +ci.setColor('r'); +ci.setValue(0.90); + +width = ci_data(:, 2) - ci_data(:, 1); +ci_color = ci.color; +ci_value = ci.value; + +save(fullfile(classDir, 'basic.mat'), ... + 'time', 'ci_data', 'width', 'ci_color', 'ci_value', '-v7'); +end + +function write_trialconfig_fixture(outRoot) +classDir = fullfile(outRoot, 'TrialConfig'); +if exist(classDir, 'dir') ~= 7 + mkdir(classDir); +end + +tc = TrialConfig({'stim'}, 1000, [], [], [], 0, 'cfg'); +tc_struct = tc.toStructure; +tc_roundtrip = TrialConfig.fromStructure(tc_struct); + +tc_name = tc.getName; +tc_sample_rate = tc.sampleRate; +tc_cov_mask = tc.covMask; +tc_cov_lag = tc.covLag; +tc_roundtrip_name = tc_roundtrip.getName; +tc_roundtrip_sample_rate = tc_roundtrip.sampleRate; + +save(fullfile(classDir, 'basic.mat'), ... + 'tc_name', 'tc_sample_rate', 'tc_cov_mask', 'tc_cov_lag', ... + 'tc_roundtrip_name', 'tc_roundtrip_sample_rate', '-v7'); +end + +function write_configcoll_fixture(outRoot) +classDir = fullfile(outRoot, 'ConfigColl'); +if exist(classDir, 'dir') ~= 7 + mkdir(classDir); +end + +tc1 = TrialConfig({'stim'}, 1000, [], [], [], 0, 'cfg1'); +tc2 = TrialConfig({'stim2'}, 500, [], [], [], 0, 'cfg2'); +cc = ConfigColl({tc1, tc2}); +names = cc.getConfigNames; +subset = cc.getSubsetConfigs([1]); + +num_configs = cc.numConfigs; +subset_num_configs = subset.numConfigs; + +save(fullfile(classDir, 'basic.mat'), ... + 'num_configs', 'names', 'subset_num_configs', '-v7'); +end + +function write_cif_fixture(outRoot) +classDir = fullfile(outRoot, 'CIF'); +if exist(classDir, 'dir') ~= 7 + mkdir(classDir); +end + +dt = 0.001; +time = (0:dt:2.0)'; +lambda_values = max(12 + 4 * sin(2 * pi * 1 * time), 0.2); +lambda_cov = Covariate(time, lambda_values, 'Lambda', 'time', 's', 'sp/s', {'lambda'}); + +rng(0, 'twister'); +coll = CIF.simulateCIFByThinningFromLambda(lambda_cov, 3, dt); +spike_counts = zeros(3, 1); +first_five_spikes = cell(3, 1); +for i = 1:3 + st = coll.getNST(i); + spike_counts(i) = length(st.spikeTimes); + first_five_spikes{i} = st.spikeTimes(1:min(5, end)); +end + +save(fullfile(classDir, 'basic.mat'), ... + 'time', 'lambda_values', 'dt', 'spike_counts', 'first_five_spikes', '-v7'); +end + +function write_fitresult_and_summary_fixtures(outRoot) +fitDir = fullfile(outRoot, 'FitResult'); +if exist(fitDir, 'dir') ~= 7 + mkdir(fitDir); +end +sumDir = fullfile(outRoot, 'FitResSummary'); +if exist(sumDir, 'dir') ~= 7 + mkdir(sumDir); +end + +time = (0:0.1:1.0)'; +lambda_cov = Covariate(time, ones(size(time)), 'Lambda', 'time', 's', 'sp/s', {'lambda'}); +spike_obj = nspikeTrain([0.2 0.4 0.8]', '1', 0.001, 0, 1); + +tc = TrialConfig(); +tc.setName('cfg1'); +cc = ConfigColl(tc); + +cov_labels = {{'Baseline'}}; +num_hist = {0}; +hist_objects = {[]}; +ens_hist_obj = {[]}; +b = {[0.1]}; +dev = 1; +stats = {struct('se', 0.1, 'p', 0.5)}; +AIC = 2; +BIC = 3; +logLL = -1; + +fit_obj = FitResult( ... + spike_obj, cov_labels, num_hist, hist_objects, ens_hist_obj, lambda_cov, ... + b, dev, stats, AIC, BIC, logLL, cc, {}, {}, 'poisson'); + +Z = [0.1; 0.2; 0.3]; +U = [0.05; 0.1; 0.2]; +xAxis = [0.1; 0.2; 0.3]; +ksSorted = [0.11; 0.21; 0.29]; +ks_stat = 0.05; +fit_obj.setKSStats(Z, U, xAxis, ksSorted, ks_stat); + +fit_num_results = fit_obj.numResults; +fit_aic = fit_obj.AIC; +fit_bic = fit_obj.BIC; +fit_logll = fit_obj.logLL; +fit_neuron_number = fit_obj.neuronNumber; +fit_ks_stat = fit_obj.KSStats.ks_stat; +fit_p_value = fit_obj.KSStats.pValue; + +save(fullfile(fitDir, 'basic.mat'), ... + 'fit_num_results', 'fit_aic', 'fit_bic', 'fit_logll', ... + 'fit_neuron_number', 'fit_ks_stat', 'fit_p_value', '-v7'); + +frs = FitResSummary(fit_obj); +summary_num_neurons = frs.numNeurons; +summary_num_results = frs.numResults; +summary_aic = frs.AIC; +summary_bic = frs.BIC; +summary_fit_names = frs.fitNames; + +save(fullfile(sumDir, 'basic.mat'), ... + 'summary_num_neurons', 'summary_num_results', ... + 'summary_aic', 'summary_bic', 'summary_fit_names', '-v7'); +end diff --git a/parity/class_contracts.yml b/parity/class_contracts.yml new file mode 100644 index 00000000..9821e09a --- /dev/null +++ b/parity/class_contracts.yml @@ -0,0 +1,180 @@ +version: 1 +description: > + Class-level contract manifest tying MATLAB classes to Python counterparts, + MATLAB-gold fixtures, and critical method checkpoints. + +classes: + - matlab_class: SignalObj + python_class: nstat.signal.Signal + compat_class: nstat.compat.matlab.SignalObj + fixture_path: tests/parity/fixtures/matlab_gold/SignalObjExamples_gold.mat + key_methods: + - copy + - resample + - periodogram + - get_sub_signal + - merge + + - matlab_class: Covariate + python_class: nstat.signal.Covariate + compat_class: nstat.compat.matlab.Covariate + fixture_path: tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat + key_methods: + - get_sub_signal + - data_to_matrix + - compute_mean_plus_ci + - to_structure + - from_structure + + - matlab_class: ConfidenceInterval + python_class: nstat.confidence.ConfidenceInterval + compat_class: nstat.compat.matlab.ConfidenceInterval + fixture_path: tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat + key_methods: + - width + - contains + - set_color + - set_value + - from_structure + + - matlab_class: Events + python_class: nstat.events.Events + compat_class: nstat.compat.matlab.Events + fixture_path: tests/parity/fixtures/matlab_gold/EventsExamples_gold.mat + key_methods: + - subset + - merge + - shift + - to_structure + - from_structure + + - matlab_class: History + python_class: nstat.history.HistoryBasis + compat_class: nstat.compat.matlab.History + fixture_path: tests/parity/fixtures/matlab_gold/HistoryExamples_gold.mat + key_methods: + - design_matrix + - to_filter + - set_window + - to_structure + - from_structure + + - matlab_class: nspikeTrain + python_class: nstat.spikes.SpikeTrain + compat_class: nstat.compat.matlab.nspikeTrain + fixture_path: tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat + key_methods: + - firing_rate_hz + - bin_counts + - binarize + - shift_time + - copy + + - matlab_class: nstColl + python_class: nstat.spikes.SpikeTrainCollection + compat_class: nstat.compat.matlab.nstColl + fixture_path: tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat + key_methods: + - to_binned_matrix + - merge + - get_first_spike_time + - get_last_spike_time + - get_spike_times + + - matlab_class: CovColl + python_class: nstat.trial.CovariateCollection + compat_class: nstat.compat.matlab.CovColl + fixture_path: tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat + key_methods: + - design_matrix + - get_cov + - set_mask + - to_structure + - from_structure + + - matlab_class: TrialConfig + python_class: nstat.trial.TrialConfig + compat_class: nstat.compat.matlab.TrialConfig + fixture_path: tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat + key_methods: + - get_name + - set_name + - to_structure + - from_structure + + - matlab_class: ConfigColl + python_class: nstat.trial.ConfigCollection + compat_class: nstat.compat.matlab.ConfigColl + fixture_path: tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat + key_methods: + - get_config + - add_config + - get_config_names + - to_structure + - from_structure + + - matlab_class: Trial + python_class: nstat.trial.Trial + compat_class: nstat.compat.matlab.Trial + fixture_path: tests/parity/fixtures/matlab_gold/TrialExamples_gold.mat + key_methods: + - aligned_binned_observation + - get_design_matrix + - set_history + - set_trial_partition + - to_structure + + - matlab_class: CIF + python_class: nstat.cif.CIFModel + compat_class: nstat.compat.matlab.CIF + fixture_path: tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat + key_methods: + - evaluate + - linear_predictor + - log_likelihood + - simulate_by_thinning + - simulateCIFByThinningFromLambda + + - matlab_class: Analysis + python_class: nstat.analysis.Analysis + compat_class: nstat.compat.matlab.Analysis + fixture_path: tests/parity/fixtures/matlab_gold/AnalysisExamples_gold.mat + key_methods: + - fit_glm + - fit_trial + - run_analysis_for_neuron + - run_analysis_for_all_neurons + - compute_hist_lag + + - matlab_class: FitResult + python_class: nstat.fit.FitResult + compat_class: nstat.compat.matlab.FitResult + fixture_path: tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat + key_methods: + - predict + - aic + - bic + - as_cif_model + - to_structure + + - matlab_class: FitResSummary + python_class: nstat.fit.FitSummary + compat_class: nstat.compat.matlab.FitResSummary + fixture_path: tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat + key_methods: + - best_by_aic + - best_by_bic + - diff_aic + - diff_bic + - to_structure + + - matlab_class: DecodingAlgorithms + python_class: nstat.decoding.DecodingAlgorithms + compat_class: nstat.compat.matlab.DecodingAlgorithms + fixture_path: tests/parity/fixtures/matlab_gold/DecodingExample_gold.mat + key_methods: + - compute_spike_rate_cis + - compute_spike_rate_diff_cis + - decode_weighted_center + - decode_state_posterior + - computeSpikeRateCIs diff --git a/parity/class_equivalence_inventory.json b/parity/class_equivalence_inventory.json new file mode 100644 index 00000000..4adaafc6 --- /dev/null +++ b/parity/class_equivalence_inventory.json @@ -0,0 +1,13954 @@ +{ + "class_rows": [ + { + "class_contract": { + "compat_class": "nstat.compat.matlab.Analysis", + "fixture_path": "tests/parity/fixtures/matlab_gold/AnalysisExamples_gold.mat", + "key_methods": [ + "fit_glm", + "fit_trial", + "run_analysis_for_neuron", + "run_analysis_for_all_neurons", + "compute_hist_lag" + ], + "python_class": "nstat.analysis.Analysis" + }, + "compat": { + "constructor_signature": "(self, /, *args, **kwargs)", + "fields": [], + "methods": { + "GLMFit": "(X: 'np.ndarray', y: 'np.ndarray', fitType: 'str' = 'poisson', dt: 'float' = 1.0, l2Penalty: 'float' = 0.0) -> '_FitResult'", + "KSPlot": "(fit: 'Any', fitNum: 'int' = 1) -> 'Any'", + "RunAnalysisForAllNeurons": "(trial: '_Trial', config: '_TrialConfig') -> 'list[_FitResult]'", + "RunAnalysisForNeuron": "(trial: '_Trial', config: '_TrialConfig', unitIndex: 'int' = 0) -> '_FitResult'", + "bnlrCG": "(X: 'np.ndarray', y: 'np.ndarray', dt: 'float' = 1.0, l2Penalty: 'float' = 0.0) -> '_FitResult'", + "compHistEnsCoeff": "(y: 'np.ndarray', X: 'np.ndarray', dt: 'float' = 1.0) -> 'np.ndarray'", + "compHistEnsCoeffForAll": "(y_list: 'list[np.ndarray]', X_list: 'list[np.ndarray]', dt: 'float' = 1.0) -> 'list[np.ndarray]'", + "computeFitResidual": "(y: 'np.ndarray', X: 'np.ndarray', fit: '_FitResult', dt: 'float' = 1.0) -> 'np.ndarray'", + "computeGrangerCausalityMatrix": "(spikeMatrix: 'np.ndarray', maxLag: 'int' = 1) -> 'np.ndarray'", + "computeHistLag": "(signal: 'np.ndarray', maxLag: 'int' = 50) -> 'tuple[np.ndarray, np.ndarray]'", + "computeHistLagForAll": "(signals: 'np.ndarray', maxLag: 'int' = 50) -> 'tuple[np.ndarray, np.ndarray]'", + "computeInvGausTrans": "(y: 'np.ndarray', X: 'np.ndarray', fit: '_FitResult', dt: 'float' = 1.0) -> 'np.ndarray'", + "computeKSStats": "(transformed: 'np.ndarray') -> 'dict[str, float]'", + "computeNeighbors": "(positions: 'np.ndarray', k: 'int' = 1) -> 'np.ndarray'", + "fdr_bh": "(p_values: 'np.ndarray', alpha: 'float' = 0.05) -> 'np.ndarray'", + "fitGLM": "(X: 'np.ndarray', y: 'np.ndarray', fitType: 'str' = 'poisson', dt: 'float' = 1.0, l2Penalty: 'float' = 0.0) -> '_FitResult'", + "fitTrial": "(trial: '_Trial', config: '_TrialConfig', unitIndex: 'int' = 0) -> '_FitResult'", + "flatMaskCellToMat": "(flatMaskCell: 'list[np.ndarray]') -> 'np.ndarray'", + "ksdiscrete": "(sample: 'np.ndarray', reference: 'np.ndarray | None' = None) -> 'dict[str, float]'", + "plotCoeffs": "(fit: 'Any') -> 'Any'", + "plotFitResidual": "(y: 'np.ndarray', X: 'np.ndarray', fit: '_FitResult', dt: 'float' = 1.0) -> 'Any'", + "plotInvGausTrans": "(y: 'np.ndarray', X: 'np.ndarray', fit: '_FitResult', dt: 'float' = 1.0) -> 'Any'", + "plotSeqCorr": "(residual: 'np.ndarray') -> 'Any'", + "spikeTrigAvg": "(signal: 'np.ndarray', spikeTimes_s: 'np.ndarray', timeGrid_s: 'np.ndarray', window_s: 'tuple[float, float]' = (-0.05, 0.05)) -> 'tuple[np.ndarray, np.ndarray]'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/AnalysisExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "fitGLM": "fit_glm", + "fitTrial": "fit_trial" + }, + "compat_class": "nstat.compat.matlab.Analysis", + "python_class": "nstat.analysis.Analysis" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [], + "line": null, + "name": "Analysis", + "static": false + }, + "matlab_class": "Analysis", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Analysis.m", + "methods": [ + { + "access": "public", + "args": [ + "tObj", + "neuronNumber", + "configColl", + "makePlot", + "Algorithm", + "DTCorrection", + "batchMode" + ], + "line": 61, + "name": "RunAnalysisForNeuron", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "configs", + "makePlot", + "Algorithm", + "DTCorrection", + "batchMode" + ], + "line": 455, + "name": "RunAnalysisForAllNeurons", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNumber", + "lambdaIndex", + "Algorithm" + ], + "line": 510, + "name": "GLMFit", + "static": true + }, + { + "access": "public", + "args": [ + "fitResults", + "makePlot" + ], + "line": 667, + "name": "plotInvGausTrans", + "static": true + }, + { + "access": "public", + "args": [ + "fitResults", + "windowSize", + "makePlot" + ], + "line": 695, + "name": "plotFitResidual", + "static": true + }, + { + "access": "public", + "args": [ + "fitResults", + "DTCorrection", + "makePlot" + ], + "line": 720, + "name": "KSPlot", + "static": true + }, + { + "access": "public", + "args": [ + "fitResults" + ], + "line": 754, + "name": "plotSeqCorr", + "static": true + }, + { + "access": "public", + "args": [ + "fitResults" + ], + "line": 761, + "name": "plotCoeffs", + "static": true + }, + { + "access": "public", + "args": [ + "Z" + ], + "line": 770, + "name": "computeInvGausTrans", + "static": true + }, + { + "access": "public", + "args": [ + "nspikeObj", + "lambdaInput", + "DTCorrection" + ], + "line": 820, + "name": "computeKSStats", + "static": true + }, + { + "access": "public", + "args": [ + "nspikeObj", + "lambda", + "windowSize" + ], + "line": 943, + "name": "computeFitResidual", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "history", + "makePlot" + ], + "line": 997, + "name": "compHistEnsCoeffForAll", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "history", + "neuronNum", + "neighbors", + "ensembleCov", + "makePlot" + ], + "line": 1013, + "name": "compHistEnsCoeff", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "Algorithm", + "confidenceInterval", + "batchMode" + ], + "line": 1047, + "name": "computeGrangerCausalityMatrix", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum", + "windowTimes", + "CovLabels", + "Algorithm", + "batchMode", + "sampleRate", + "makePlot", + "histMinTimes", + "histMaxTimes" + ], + "line": 1111, + "name": "computeHistLag", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "windowTimes", + "CovLabels", + "Algorithm", + "batchMode", + "sampleRate", + "makePlot", + "histMinTimes", + "histMaxTimes" + ], + "line": 1169, + "name": "computeHistLagForAll", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum", + "sampleRate", + "windowTimes", + "makePlot" + ], + "line": 1207, + "name": "computeNeighbors", + "static": true + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum", + "windowSize" + ], + "line": 1237, + "name": "spikeTrigAvg", + "static": true + }, + { + "access": "public", + "args": [ + "flatMaskCell" + ], + "line": 1289, + "name": "flatMaskCellToMat", + "static": true + }, + { + "access": "public", + "args": [ + "X", + "yframe", + "rrflag" + ], + "line": 1301, + "name": "bnlrCG", + "static": true + }, + { + "access": "public", + "args": [ + "pk", + "st", + "spikeflag" + ], + "line": 1410, + "name": "ksdiscrete", + "static": true + }, + { + "access": "public", + "args": [ + "pvals", + "q", + "method", + "report" + ], + "line": 1714, + "name": "fdr_bh", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 57, + "name": "colors" + } + ], + "public_methods": [ + "GLMFit", + "KSPlot", + "RunAnalysisForAllNeurons", + "RunAnalysisForNeuron", + "bnlrCG", + "compHistEnsCoeff", + "compHistEnsCoeffForAll", + "computeFitResidual", + "computeGrangerCausalityMatrix", + "computeHistLag", + "computeHistLagForAll", + "computeInvGausTrans", + "computeKSStats", + "computeNeighbors", + "fdr_bh", + "flatMaskCellToMat", + "ksdiscrete", + "plotCoeffs", + "plotFitResidual", + "plotInvGausTrans", + "plotSeqCorr", + "spikeTrigAvg" + ], + "superclass": "" + }, + "matlab_class": "Analysis", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "GLMFit", + "mapped_via_alias": false, + "matlab_method": "GLMFit", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "KSPlot", + "mapped_via_alias": false, + "matlab_method": "KSPlot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "RunAnalysisForAllNeurons", + "mapped_via_alias": false, + "matlab_method": "RunAnalysisForAllNeurons", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "RunAnalysisForNeuron", + "mapped_via_alias": false, + "matlab_method": "RunAnalysisForNeuron", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "bnlrCG", + "mapped_via_alias": false, + "matlab_method": "bnlrCG", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "compHistEnsCoeff", + "mapped_via_alias": false, + "matlab_method": "compHistEnsCoeff", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "compHistEnsCoeffForAll", + "mapped_via_alias": false, + "matlab_method": "compHistEnsCoeffForAll", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeFitResidual", + "mapped_via_alias": false, + "matlab_method": "computeFitResidual", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeGrangerCausalityMatrix", + "mapped_via_alias": false, + "matlab_method": "computeGrangerCausalityMatrix", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeHistLag", + "mapped_via_alias": false, + "matlab_method": "computeHistLag", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeHistLagForAll", + "mapped_via_alias": false, + "matlab_method": "computeHistLagForAll", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeInvGausTrans", + "mapped_via_alias": false, + "matlab_method": "computeInvGausTrans", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeKSStats", + "mapped_via_alias": false, + "matlab_method": "computeKSStats", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeNeighbors", + "mapped_via_alias": false, + "matlab_method": "computeNeighbors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fdr_bh", + "mapped_via_alias": false, + "matlab_method": "fdr_bh", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "flatMaskCellToMat", + "mapped_via_alias": false, + "matlab_method": "flatMaskCellToMat", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ksdiscrete", + "mapped_via_alias": false, + "matlab_method": "ksdiscrete", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotCoeffs", + "mapped_via_alias": false, + "matlab_method": "plotCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotFitResidual", + "mapped_via_alias": false, + "matlab_method": "plotFitResidual", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotInvGausTrans", + "mapped_via_alias": false, + "matlab_method": "plotInvGausTrans", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotSeqCorr", + "mapped_via_alias": false, + "matlab_method": "plotSeqCorr", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "spikeTrigAvg", + "mapped_via_alias": false, + "matlab_method": "spikeTrigAvg", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, /, *args, **kwargs)", + "fields": [], + "methods": { + "compute_fit_residual": "(y: 'np.ndarray', X: 'np.ndarray', fit_result: 'FitResult', dt: 'float' = 1.0) -> 'np.ndarray'", + "compute_inv_gaus_trans": "(y: 'np.ndarray', X: 'np.ndarray', fit_result: 'FitResult', dt: 'float' = 1.0) -> 'np.ndarray'", + "compute_ks_stats": "(transformed_events: 'np.ndarray') -> 'dict[str, float]'", + "fdr_bh": "(p_values: 'np.ndarray', alpha: 'float' = 0.05) -> 'np.ndarray'", + "fit_glm": "(X: 'np.ndarray', y: 'np.ndarray', fit_type: 'str' = 'poisson', dt: 'float' = 1.0, l2_penalty: 'float' = 0.0) -> 'FitResult'", + "fit_trial": "(trial: 'Trial', config: 'TrialConfig', unit_index: 'int' = 0) -> 'FitResult'", + "glm_fit": "(X: 'np.ndarray', y: 'np.ndarray', fit_type: 'str' = 'poisson', dt: 'float' = 1.0, l2_penalty: 'float' = 0.0) -> 'FitResult'", + "run_analysis_for_all_neurons": "(trial: 'Trial', config: 'TrialConfig') -> 'list[FitResult]'", + "run_analysis_for_neuron": "(trial: 'Trial', config: 'TrialConfig', unit_index: 'int' = 0) -> 'FitResult'" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.CIF", + "fixture_path": "tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat", + "key_methods": [ + "evaluate", + "linear_predictor", + "log_likelihood", + "simulate_by_thinning", + "simulateCIFByThinningFromLambda" + ], + "python_class": "nstat.cif.CIFModel" + }, + "compat": { + "constructor_signature": "(self, coefficients: 'np.ndarray', intercept: 'float' = 0.0, link: 'str' = 'poisson') -> None", + "fields": [ + "coefficients", + "intercept", + "link" + ], + "methods": { + "CIF": "(*args: 'Any', **kwargs: 'Any') -> '_CIFModel'", + "CIFCopy": "(self) -> '_CIFModel'", + "computeLinearPredictor": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "computePlotParams": "(self, X: 'np.ndarray') -> 'dict[str, float]'", + "compute_plot_params": "(self, X: 'np.ndarray') -> 'dict[str, float]'", + "evalFunctionWithVectorArgs": "(self, X: 'np.ndarray', *_args: 'Any', **_kwargs: 'Any') -> 'np.ndarray'", + "evalGradient": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalGradientLDGamma": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalGradientLog": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalGradientLogLDGamma": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalJacobian": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalJacobianLDGamma": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalJacobianLog": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalJacobianLogLDGamma": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalLDGamma": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalLambda": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalLambdaDelta": "(self, X: 'np.ndarray', dt: 'float' = 1.0) -> 'np.ndarray'", + "evalLogLDGamma": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "eval_lambda_delta": "(self, X: 'np.ndarray', dt: 'float' = 1.0) -> 'np.ndarray'", + "evaluate": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "fromStructure": "(payload: 'dict[str, np.ndarray | float | str]') -> '_CIFModel'", + "from_structure": "(payload: 'dict[str, np.ndarray | float | str]') -> \"'CIFModel'\"", + "isSymBeta": "(self) -> 'bool'", + "linear_predictor": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "logLikelihood": "(self, y: 'np.ndarray', X: 'np.ndarray', dt: 'float' = 1.0) -> 'float'", + "log_likelihood": "(self, y: 'np.ndarray', X: 'np.ndarray', dt: 'float' = 1.0) -> 'float'", + "resolveSimulinkModelName": "(*_args: 'Any', **_kwargs: 'Any') -> 'str'", + "setHistory": "(self, history: 'Any') -> '_CIFModel'", + "setSpikeTrain": "(self, spike_train: 'Any') -> '_CIFModel'", + "simulateByThinning": "(self, time: 'np.ndarray', X: 'np.ndarray', rng: 'np.random.Generator | None' = None) -> 'np.ndarray'", + "simulateCIF": "(self, time: 'np.ndarray', X: 'np.ndarray', rng: 'np.random.Generator | None' = None) -> 'np.ndarray'", + "simulateCIFByThinning": "(self, time: 'np.ndarray', X: 'np.ndarray', rng: 'np.random.Generator | None' = None) -> 'np.ndarray'", + "simulateCIFByThinningFromLambda": "(lambda_signal: '_Covariate', numRealizations: 'int' = 1, maxTimeRes: 'float | None' = None) -> 'nstColl'", + "simulate_by_thinning": "(self, time: 'np.ndarray', X: 'np.ndarray', rng: 'np.random.Generator | None' = None) -> 'np.ndarray'", + "simulate_cif_by_thinning_from_lambda": "(time: 'np.ndarray', lambda_values: 'np.ndarray', num_realizations: 'int' = 1, rng: 'np.random.Generator | None' = None) -> 'list[np.ndarray]'", + "toStructure": "(self) -> 'dict[str, np.ndarray | float | str]'", + "to_structure": "(self) -> 'dict[str, np.ndarray | float | str]'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "class_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat" + }, + "mapping": { + "alias_methods": { + "computeLinearPredictor": "linear_predictor", + "evalLambda": "evaluate", + "logLikelihood": "log_likelihood", + "simulateByThinning": "simulate_by_thinning" + }, + "compat_class": "nstat.compat.matlab.CIF", + "python_class": "nstat.cif.CIFModel" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "beta", + "Xnames", + "stimNames", + "fitType", + "histCoeffs", + "historyObj", + "nst" + ], + "line": 96, + "name": "CIF", + "static": false + }, + "matlab_class": "CIF", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/CIF.m", + "methods": [ + { + "access": "public", + "args": [ + "beta", + "Xnames", + "stimNames", + "fitType", + "histCoeffs", + "historyObj", + "nst" + ], + "line": 96, + "name": "CIF", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj" + ], + "line": 377, + "name": "CIFCopy", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "spikeTrain" + ], + "line": 391, + "name": "setSpikeTrain", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "histObj" + ], + "line": 401, + "name": "setHistory", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst" + ], + "line": 419, + "name": "evalLambdaDelta", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst" + ], + "line": 449, + "name": "evalGradient", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst" + ], + "line": 483, + "name": "evalGradientLog", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst" + ], + "line": 518, + "name": "evalJacobian", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst" + ], + "line": 551, + "name": "evalJacobianLog", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst", + "gamma" + ], + "line": 588, + "name": "evalLDGamma", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst", + "gamma" + ], + "line": 620, + "name": "evalLogLDGamma", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst", + "gamma" + ], + "line": 653, + "name": "evalGradientLDGamma", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst", + "gamma" + ], + "line": 686, + "name": "evalGradientLogLDGamma", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst", + "gamma" + ], + "line": 723, + "name": "evalJacobianLogLDGamma", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj", + "stimVal", + "time_index", + "nst", + "gamma" + ], + "line": 755, + "name": "evalJacobianLDGamma", + "static": false + }, + { + "access": "public", + "args": [ + "cifObj" + ], + "line": 788, + "name": "isSymBeta", + "static": false + }, + { + "access": "public", + "args": [ + "lambda", + "numRealizations", + "maxTimeRes" + ], + "line": 799, + "name": "simulateCIFByThinningFromLambda", + "static": true + }, + { + "access": "public", + "args": [ + "mu", + "hist", + "stim", + "ens", + "inputStimSignal", + "inputEnsSignal", + "numRealizations", + "simType" + ], + "line": 879, + "name": "simulateCIFByThinning", + "static": true + }, + { + "access": "public", + "args": [ + "mu", + "hist", + "stim", + "ens", + "inputStimSignal", + "inputEnsSignal", + "numRealizations", + "simType" + ], + "line": 969, + "name": "simulateCIF", + "static": true + }, + { + "access": "private", + "args": [ + "funHandle", + "val" + ], + "line": 1051, + "name": "evalFunctionWithVectorArgs", + "static": true + }, + { + "access": "private", + "args": [ + "baseModelName" + ], + "line": 1059, + "name": "resolveSimulinkModelName", + "static": true + } + ], + "private_methods": [ + "evalFunctionWithVectorArgs", + "resolveSimulinkModelName" + ], + "properties": [ + { + "access": "public", + "line": 48, + "name": "b" + }, + { + "access": "public", + "line": 49, + "name": "varIn" + }, + { + "access": "public", + "line": 50, + "name": "stimVars" + }, + { + "access": "public", + "line": 51, + "name": "indepVars" + }, + { + "access": "public", + "line": 52, + "name": "stats" + }, + { + "access": "public", + "line": 53, + "name": "fitType" + }, + { + "access": "public", + "line": 54, + "name": "lambdaDelta" + }, + { + "access": "public", + "line": 55, + "name": "lambdaDeltaGamma" + }, + { + "access": "public", + "line": 56, + "name": "LogLambdaDeltaGamma" + }, + { + "access": "public", + "line": 57, + "name": "spikeTrain" + }, + { + "access": "public", + "line": 59, + "name": "gradientLambdaDelta" + }, + { + "access": "public", + "line": 60, + "name": "gradientLogLambdaDelta" + }, + { + "access": "public", + "line": 61, + "name": "gradientLambdaDeltaGamma" + }, + { + "access": "public", + "line": 62, + "name": "gradientLogLambdaDeltaGamma" + }, + { + "access": "public", + "line": 64, + "name": "jacobianLambdaDelta" + }, + { + "access": "public", + "line": 65, + "name": "jacobianLogLambdaDelta" + }, + { + "access": "public", + "line": 66, + "name": "jacobianLambdaDeltaGamma" + }, + { + "access": "public", + "line": 67, + "name": "jacobianLogLambdaDeltaGamma" + }, + { + "access": "public", + "line": 68, + "name": "history" + }, + { + "access": "public", + "line": 69, + "name": "histCoeffs" + }, + { + "access": "public", + "line": 70, + "name": "histCoeffVars" + }, + { + "access": "public", + "line": 71, + "name": "histVars" + }, + { + "access": "public", + "line": 72, + "name": "historyMat" + }, + { + "access": "public", + "line": 77, + "name": "lambdaDeltaFunction" + }, + { + "access": "public", + "line": 78, + "name": "lambdaDeltaGammaFunction" + }, + { + "access": "public", + "line": 79, + "name": "LogLambdaDeltaGammaFunction" + }, + { + "access": "public", + "line": 80, + "name": "gradientFunction" + }, + { + "access": "public", + "line": 81, + "name": "gradientLogFunction" + }, + { + "access": "public", + "line": 82, + "name": "gradientFunctionGamma" + }, + { + "access": "public", + "line": 83, + "name": "gradientLogFunctionGamma" + }, + { + "access": "public", + "line": 85, + "name": "jacobianFunction" + }, + { + "access": "public", + "line": 86, + "name": "jacobianLogFunction" + }, + { + "access": "public", + "line": 87, + "name": "jacobianFunctionGamma" + }, + { + "access": "public", + "line": 88, + "name": "jacobianLogFunctionGamma" + }, + { + "access": "public", + "line": 90, + "name": "argstr" + }, + { + "access": "public", + "line": 91, + "name": "argstrLDGamma" + } + ], + "public_methods": [ + "CIF", + "CIFCopy", + "evalGradient", + "evalGradientLDGamma", + "evalGradientLog", + "evalGradientLogLDGamma", + "evalJacobian", + "evalJacobianLDGamma", + "evalJacobianLog", + "evalJacobianLogLDGamma", + "evalLDGamma", + "evalLambdaDelta", + "evalLogLDGamma", + "isSymBeta", + "setHistory", + "setSpikeTrain", + "simulateCIF", + "simulateCIFByThinning", + "simulateCIFByThinningFromLambda" + ], + "superclass": "handle" + }, + "matlab_class": "CIF", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "CIF", + "mapped_via_alias": false, + "matlab_method": "CIF", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "CIFCopy", + "mapped_via_alias": false, + "matlab_method": "CIFCopy", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalGradient", + "mapped_via_alias": false, + "matlab_method": "evalGradient", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalGradientLDGamma", + "mapped_via_alias": false, + "matlab_method": "evalGradientLDGamma", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalGradientLog", + "mapped_via_alias": false, + "matlab_method": "evalGradientLog", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalGradientLogLDGamma", + "mapped_via_alias": false, + "matlab_method": "evalGradientLogLDGamma", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalJacobian", + "mapped_via_alias": false, + "matlab_method": "evalJacobian", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalJacobianLDGamma", + "mapped_via_alias": false, + "matlab_method": "evalJacobianLDGamma", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalJacobianLog", + "mapped_via_alias": false, + "matlab_method": "evalJacobianLog", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalJacobianLogLDGamma", + "mapped_via_alias": false, + "matlab_method": "evalJacobianLogLDGamma", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalLDGamma", + "mapped_via_alias": false, + "matlab_method": "evalLDGamma", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalLambdaDelta", + "mapped_via_alias": false, + "matlab_method": "evalLambdaDelta", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "evalLogLDGamma", + "mapped_via_alias": false, + "matlab_method": "evalLogLDGamma", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isSymBeta", + "mapped_via_alias": false, + "matlab_method": "isSymBeta", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setHistory", + "mapped_via_alias": false, + "matlab_method": "setHistory", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setSpikeTrain", + "mapped_via_alias": false, + "matlab_method": "setSpikeTrain", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "simulateCIF", + "mapped_via_alias": false, + "matlab_method": "simulateCIF", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "simulateCIFByThinning", + "mapped_via_alias": false, + "matlab_method": "simulateCIFByThinning", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "simulateCIFByThinningFromLambda", + "mapped_via_alias": false, + "matlab_method": "simulateCIFByThinningFromLambda", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, coefficients: 'np.ndarray', intercept: 'float' = 0.0, link: 'str' = 'poisson') -> None", + "fields": [ + "coefficients", + "intercept", + "link" + ], + "methods": { + "compute_plot_params": "(self, X: 'np.ndarray') -> 'dict[str, float]'", + "eval_lambda_delta": "(self, X: 'np.ndarray', dt: 'float' = 1.0) -> 'np.ndarray'", + "evaluate": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "from_structure": "(payload: 'dict[str, np.ndarray | float | str]') -> \"'CIFModel'\"", + "linear_predictor": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "log_likelihood": "(self, y: 'np.ndarray', X: 'np.ndarray', dt: 'float' = 1.0) -> 'float'", + "simulate_by_thinning": "(self, time: 'np.ndarray', X: 'np.ndarray', rng: 'np.random.Generator | None' = None) -> 'np.ndarray'", + "simulate_cif_by_thinning_from_lambda": "(time: 'np.ndarray', lambda_values: 'np.ndarray', num_realizations: 'int' = 1, rng: 'np.random.Generator | None' = None) -> 'list[np.ndarray]'", + "to_structure": "(self) -> 'dict[str, np.ndarray | float | str]'" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.ConfidenceInterval", + "fixture_path": "tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat", + "key_methods": [ + "width", + "contains", + "set_color", + "set_value", + "from_structure" + ], + "python_class": "nstat.confidence.ConfidenceInterval" + }, + "compat": { + "constructor_signature": "(self, time: 'np.ndarray', lower: 'np.ndarray', upper: 'np.ndarray', level: 'float' = 0.95) -> None", + "fields": [ + "level", + "lower", + "time", + "upper" + ], + "methods": { + "ConfidenceInterval": "(*args: 'Any', **kwargs: 'Any') -> '_ConfidenceInterval'", + "contains": "(self, values: 'np.ndarray') -> 'np.ndarray'", + "fromStructure": "(payload: 'dict[str, Any]') -> '_ConfidenceInterval'", + "getWidth": "(self) -> 'np.ndarray'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "setColor": "(self, color: 'str') -> '_ConfidenceInterval'", + "setValue": "(self, values: 'np.ndarray | float') -> '_ConfidenceInterval'", + "toStructure": "(self) -> 'dict[str, Any]'", + "width": "(self) -> 'np.ndarray'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "class_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat" + }, + "mapping": { + "alias_methods": { + "contains": "contains", + "getWidth": "width" + }, + "compat_class": "nstat.compat.matlab.ConfidenceInterval", + "python_class": "nstat.confidence.ConfidenceInterval" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "varargin" + ], + "line": 48, + "name": "ConfidenceInterval", + "static": false + }, + "matlab_class": "ConfidenceInterval", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/ConfidenceInterval.m", + "methods": [ + { + "access": "public", + "args": [ + "varargin" + ], + "line": 48, + "name": "ConfidenceInterval", + "static": false + }, + { + "access": "public", + "args": [ + "ciObj", + "color" + ], + "line": 53, + "name": "setColor", + "static": false + }, + { + "access": "public", + "args": [ + "ciObj", + "value" + ], + "line": 57, + "name": "setValue", + "static": false + }, + { + "access": "public", + "args": [ + "ciObj", + "color", + "alphaVal", + "drawPatches" + ], + "line": 61, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 101, + "name": "fromStructure", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 43, + "name": "color" + }, + { + "access": "public", + "line": 44, + "name": "value" + } + ], + "public_methods": [ + "ConfidenceInterval", + "fromStructure", + "plot", + "setColor", + "setValue" + ], + "superclass": "SignalObj" + }, + "matlab_class": "ConfidenceInterval", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ConfidenceInterval", + "mapped_via_alias": false, + "matlab_method": "ConfidenceInterval", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setColor", + "mapped_via_alias": false, + "matlab_method": "setColor", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setValue", + "mapped_via_alias": false, + "matlab_method": "setValue", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, time: 'np.ndarray', lower: 'np.ndarray', upper: 'np.ndarray', level: 'float' = 0.95) -> None", + "fields": [ + "level", + "lower", + "time", + "upper" + ], + "methods": { + "contains": "(self, values: 'np.ndarray') -> 'np.ndarray'", + "width": "(self) -> 'np.ndarray'" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.ConfigColl", + "fixture_path": "tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat", + "key_methods": [ + "get_config", + "add_config", + "get_config_names", + "to_structure", + "from_structure" + ], + "python_class": "nstat.trial.ConfigCollection" + }, + "compat": { + "constructor_signature": "(self, configs: 'list[TrialConfig]') -> None", + "fields": [ + "configs" + ], + "methods": { + "ConfigColl": "(*args: 'Any', **kwargs: 'Any') -> '_ConfigCollection'", + "addConfig": "(self, config: '_TrialConfig') -> '_ConfigCollection'", + "fromStructure": "(payload: 'dict[str, Any] | list[dict[str, Any]]') -> '_ConfigCollection'", + "getConfig": "(self, selector: 'int | str' = 1) -> '_TrialConfig'", + "getConfigNames": "(self) -> 'list[str]'", + "getConfigs": "(self) -> 'list[_TrialConfig]'", + "getSubsetConfigs": "(self, selectors: 'list[int] | np.ndarray') -> '_ConfigCollection'", + "setConfig": "(self, selector: 'int | str', config: '_TrialConfig') -> '_ConfigCollection'", + "setConfigNames": "(self, names: 'list[str]') -> '_ConfigCollection'", + "toStructure": "(self) -> 'dict[str, Any]'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "class_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat" + }, + "mapping": { + "alias_methods": { + "getConfigs": "configs" + }, + "compat_class": "nstat.compat.matlab.ConfigColl", + "python_class": "nstat.trial.ConfigCollection" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "tcObj" + ], + "line": 60, + "name": "ConfigColl", + "static": false + }, + "matlab_class": "ConfigColl", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/ConfigColl.m", + "methods": [ + { + "access": "public", + "args": [ + "tcObj" + ], + "line": 60, + "name": "ConfigColl", + "static": false + }, + { + "access": "public", + "args": [ + "tcColl", + "tcObj" + ], + "line": 72, + "name": "addConfig", + "static": false + }, + { + "access": "public", + "args": [ + "tcColl", + "index" + ], + "line": 104, + "name": "getConfig", + "static": false + }, + { + "access": "public", + "args": [ + "tcColl", + "trial", + "index" + ], + "line": 115, + "name": "setConfig", + "static": false + }, + { + "access": "public", + "args": [ + "tcColl", + "index" + ], + "line": 125, + "name": "getConfigNames", + "static": false + }, + { + "access": "public", + "args": [ + "tcColl", + "names", + "index" + ], + "line": 144, + "name": "setConfigNames", + "static": false + }, + { + "access": "public", + "args": [ + "tcColl", + "subset" + ], + "line": 172, + "name": "getSubsetConfigs", + "static": false + }, + { + "access": "public", + "args": [ + "tcColl" + ], + "line": 178, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 191, + "name": "fromStructure", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 51, + "name": "numConfigs" + }, + { + "access": "public", + "line": 52, + "name": "configNames" + }, + { + "access": "public", + "line": 56, + "name": "configArray" + } + ], + "public_methods": [ + "ConfigColl", + "addConfig", + "fromStructure", + "getConfig", + "getConfigNames", + "getSubsetConfigs", + "setConfig", + "setConfigNames", + "toStructure" + ], + "superclass": "handle" + }, + "matlab_class": "ConfigColl", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ConfigColl", + "mapped_via_alias": false, + "matlab_method": "ConfigColl", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "addConfig", + "mapped_via_alias": false, + "matlab_method": "addConfig", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getConfig", + "mapped_via_alias": false, + "matlab_method": "getConfig", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getConfigNames", + "mapped_via_alias": false, + "matlab_method": "getConfigNames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSubsetConfigs", + "mapped_via_alias": false, + "matlab_method": "getSubsetConfigs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setConfig", + "mapped_via_alias": false, + "matlab_method": "setConfig", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setConfigNames", + "mapped_via_alias": false, + "matlab_method": "setConfigNames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, configs: 'list[TrialConfig]') -> None", + "fields": [ + "configs" + ], + "methods": {}, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.CovColl", + "fixture_path": "tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat", + "key_methods": [ + "design_matrix", + "get_cov", + "set_mask", + "to_structure", + "from_structure" + ], + "python_class": "nstat.trial.CovariateCollection" + }, + "compat": { + "constructor_signature": "(self, covariates: 'list[Covariate]') -> None", + "fields": [ + "covariates" + ], + "methods": { + "addCovCellToColl": "(self, covariates: 'list[_Covariate]') -> \"'CovColl'\"", + "addCovCollection": "(self, other: '_CovariateCollection') -> \"'CovColl'\"", + "addSingleCovToColl": "(self, cov: '_Covariate') -> \"'CovColl'\"", + "addToColl": "(self, cov: '_Covariate') -> \"'CovColl'\"", + "add_to_coll": "(self, covariate: 'Covariate') -> \"'CovariateCollection'\"", + "containsChars": "(text: 'str', chars: 'str | list[str]') -> 'bool'", + "copy": "(self) -> \"'CovColl'\"", + "covIndFromSelector": "(self, selector: 'int | str | list[int] | list[str] | np.ndarray') -> 'list[int]'", + "dataToMatrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "dataToMatrixFromNames": "(self, names: 'list[str]') -> 'tuple[np.ndarray, list[str]]'", + "dataToMatrixFromSel": "(self, selectors: 'list[int]') -> 'tuple[np.ndarray, list[str]]'", + "dataToStructure": "(self) -> 'dict[str, Any]'", + "data_to_matrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "data_to_matrix_from_names": "(self, names: 'list[str]') -> 'tuple[np.ndarray, list[str]]'", + "data_to_matrix_from_sel": "(self, selectors: 'list[int]') -> 'tuple[np.ndarray, list[str]]'", + "design_matrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "enforceSampleRate": "(self, sampleRate: 'float') -> \"'CovColl'\"", + "findMaxTime": "(self) -> 'float'", + "findMinTime": "(self) -> 'float'", + "find_max_sample_rate": "(self) -> 'float'", + "find_max_time": "(self) -> 'float'", + "find_min_sample_rate": "(self) -> 'float'", + "find_min_time": "(self) -> 'float'", + "flattenCovMask": "(self, mask: 'list[int] | np.ndarray | list[list[int]]') -> 'list[int]'", + "fromStructure": "(payload: 'dict[str, Any]') -> \"'CovColl'\"", + "generateRemainingIndex": "(self, selector: 'int | str | list[int] | list[str] | np.ndarray') -> 'list[int]'", + "generateSelectorCell": "(self, mask: 'list[int] | np.ndarray') -> 'list[str]'", + "getAllCovLabels": "(self) -> 'list[str]'", + "getCov": "(self, selector: 'int | str') -> '_Covariate'", + "getCovDataMask": "(self) -> 'list[int]'", + "getCovDimension": "(self) -> 'int'", + "getCovIndFromName": "(self, name: 'str') -> 'int'", + "getCovIndicesFromNames": "(self, names: 'list[str]') -> 'list[int]'", + "getCovLabelsFromMask": "(self) -> 'list[str]'", + "getCovMaskFromSelector": "(self, selector: 'int | str | list[int] | list[str] | np.ndarray') -> 'list[int]'", + "getDesignMatrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "getSelectorFromMasks": "(self, mask: 'list[int] | np.ndarray') -> 'list[str]'", + "getTime": "(self) -> 'np.ndarray'", + "get_all_cov_labels": "(self) -> 'list[str]'", + "get_cov": "(self, selector: 'int | str') -> 'Covariate'", + "get_cov_dimension": "(self) -> 'int'", + "get_cov_ind_from_name": "(self, name: 'str') -> 'int'", + "get_cov_indices_from_names": "(self, names: 'list[str]') -> 'list[int]'", + "isCovMaskSet": "(self) -> 'bool'", + "isCovPresent": "(self, name: 'str') -> 'bool'", + "is_cov_present": "(self, name: 'str') -> 'bool'", + "isaSelectorCell": "(selector: 'Any') -> 'bool'", + "maskAwayAllExcept": "(self, selector: 'int | str | list[int] | list[str] | np.ndarray') -> \"'CovColl'\"", + "maskAwayCov": "(self, selector: 'int | str | list[int] | list[str] | np.ndarray') -> \"'CovColl'\"", + "maskAwayOnlyCov": "(self, selector: 'int | str | list[int] | list[str] | np.ndarray') -> \"'CovColl'\"", + "nActCovar": "(self) -> 'int'", + "n_act_covar": "(self) -> 'int'", + "numActCov": "(self) -> 'int'", + "num_act_cov": "(self) -> 'int'", + "parseDataSelectorArray": "(self, selector: 'Any') -> 'list[int]'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "removeCovariate": "(self, selector: 'int | str') -> \"'CovColl'\"", + "removeFromColl": "(self, selector: 'int | str') -> \"'CovColl'\"", + "removeFromCollByIndices": "(self, indices: 'list[int]') -> \"'CovColl'\"", + "resample": "(self, sampleRate: 'float') -> \"'CovColl'\"", + "resetCovShift": "(self) -> \"'CovColl'\"", + "resetMask": "(self) -> \"'CovColl'\"", + "restoreToOriginal": "(self) -> \"'CovColl'\"", + "restrictToTimeWindow": "(self, t_min: 'float', t_max: 'float') -> \"'CovColl'\"", + "setCovShift": "(self, shift_s: 'float') -> \"'CovColl'\"", + "setMask": "(self, selector: 'list[int] | list[str]') -> \"'CovColl'\"", + "setMasksFromSelector": "(self, selector: 'list[int] | list[str] | np.ndarray') -> \"'CovColl'\"", + "setMaxTime": "(self, t_max: 'float') -> \"'CovColl'\"", + "setMinTime": "(self, t_min: 'float') -> \"'CovColl'\"", + "setSampleRate": "(self, sampleRate: 'float') -> \"'CovColl'\"", + "sumDimensions": "(self) -> 'int'", + "sum_dimensions": "(self) -> 'int'", + "toStructure": "(self) -> 'dict[str, Any]'", + "updateTimes": "(self) -> \"'CovColl'\"" + }, + "properties": [ + "time" + ] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "CovColl": "copy", + "getDesignMatrix": "design_matrix", + "getTime": "time" + }, + "compat_class": "nstat.compat.matlab.CovColl", + "python_class": "nstat.trial.CovariateCollection" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "cov", + "varargin" + ], + "line": 78, + "name": "CovColl", + "static": false + }, + "matlab_class": "CovColl", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/CovColl.m", + "methods": [ + { + "access": "public", + "args": [ + "cov", + "varargin" + ], + "line": 78, + "name": "CovColl", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "minTime" + ], + "line": 105, + "name": "setMinTime", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "maxTime" + ], + "line": 121, + "name": "setMaxTime", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "sampleRate" + ], + "line": 138, + "name": "setSampleRate", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "cellInput" + ], + "line": 152, + "name": "setMask", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "identifier" + ], + "line": 163, + "name": "getCovDataMask", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 170, + "name": "isCovMaskSet", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 182, + "name": "nActCovar", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "identifier" + ], + "line": 192, + "name": "maskAwayCov", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 214, + "name": "copy", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "identifier" + ], + "line": 223, + "name": "maskAwayOnlyCov", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "identifier" + ], + "line": 231, + "name": "maskAwayAllExcept", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "identifier" + ], + "line": 253, + "name": "getCov", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "name" + ], + "line": 299, + "name": "getCovIndicesFromNames", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "identifier" + ], + "line": 319, + "name": "getCovDimension", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 329, + "name": "getAllCovLabels", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 343, + "name": "getCovLabelsFromMask", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 365, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 383, + "name": "findMinTime", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 392, + "name": "findMaxTime", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "cov" + ], + "line": 403, + "name": "addToColl", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "cov" + ], + "line": 421, + "name": "addCovCollection", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "cov" + ], + "line": 429, + "name": "isCovPresent", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "sampleRate" + ], + "line": 461, + "name": "resample", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 468, + "name": "restoreToOriginal", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "wMin", + "wMax" + ], + "line": 489, + "name": "restrictToTimeWindow", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "identifier" + ], + "line": 499, + "name": "removeCovariate", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 504, + "name": "resetMask", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 512, + "name": "enforceSampleRate", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "deltaT", + "identifier" + ], + "line": 525, + "name": "setCovShift", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 543, + "name": "resetCovShift", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj" + ], + "line": 549, + "name": "flattenCovMask", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "repType", + "dataSelector", + "varargin" + ], + "line": 566, + "name": "dataToMatrix", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "repType", + "dataSelector", + "varargin" + ], + "line": 584, + "name": "dataToMatrixFromNames", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "repType", + "selectorCell", + "varargin" + ], + "line": 588, + "name": "dataToMatrixFromSel", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "selectorCell", + "binwidth", + "minTime", + "maxTime" + ], + "line": 636, + "name": "dataToStructure", + "static": false + }, + { + "access": "public", + "args": [ + "ccObj", + "handle", + "repType", + "selectorCell" + ], + "line": 670, + "name": "plot", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "selectorCell" + ], + "line": 722, + "name": "setMasksFromSelector", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "selectorCell" + ], + "line": 727, + "name": "getCovMaskFromSelector", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "covMask" + ], + "line": 740, + "name": "getSelectorFromMasks", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "dataSelector" + ], + "line": 756, + "name": "isaSelectorCell", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "dataSelector" + ], + "line": 763, + "name": "generateSelectorCell", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "cov" + ], + "line": 801, + "name": "addCovCellToColl", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "cov" + ], + "line": 811, + "name": "addSingleCovToColl", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "cov" + ], + "line": 837, + "name": "updateTimes", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "name" + ], + "line": 848, + "name": "getCovIndFromName", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "identifier" + ], + "line": 857, + "name": "removeFromColl", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "ind" + ], + "line": 871, + "name": "removeFromCollByIndices", + "static": false + }, + { + "access": "private", + "args": [ + "ccObj", + "ind" + ], + "line": 897, + "name": "generateRemainingIndex", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 911, + "name": "fromStructure", + "static": true + }, + { + "access": "public", + "args": [ + "selectorCell" + ], + "line": 940, + "name": "covIndFromSelector", + "static": true + }, + { + "access": "public", + "args": [ + "selectorCell" + ], + "line": 950, + "name": "numActCov", + "static": true + }, + { + "access": "public", + "args": [ + "selectorCell", + "index" + ], + "line": 959, + "name": "sumDimensions", + "static": true + }, + { + "access": "public", + "args": [ + "entry" + ], + "line": 971, + "name": "parseDataSelectorArray", + "static": true + }, + { + "access": "public", + "args": [ + "x" + ], + "line": 978, + "name": "containsChars", + "static": true + } + ], + "private_methods": [ + "addCovCellToColl", + "addSingleCovToColl", + "generateRemainingIndex", + "generateSelectorCell", + "getCovIndFromName", + "getCovMaskFromSelector", + "getSelectorFromMasks", + "isaSelectorCell", + "removeFromColl", + "removeFromCollByIndices", + "setMasksFromSelector", + "updateTimes" + ], + "properties": [ + { + "access": "private", + "line": 59, + "name": "covArray" + }, + { + "access": "private", + "line": 60, + "name": "covDimensions" + }, + { + "access": "private", + "line": 61, + "name": "numCov" + }, + { + "access": "private", + "line": 62, + "name": "minTime" + }, + { + "access": "private", + "line": 63, + "name": "maxTime" + }, + { + "access": "private", + "line": 64, + "name": "covMask" + }, + { + "access": "private", + "line": 65, + "name": "covShift" + }, + { + "access": "private", + "line": 66, + "name": "sampleRate" + }, + { + "access": "public", + "line": 70, + "name": "originalSampleRate" + }, + { + "access": "public", + "line": 71, + "name": "originalMinTime" + }, + { + "access": "public", + "line": 72, + "name": "originalMaxTime" + } + ], + "public_methods": [ + "CovColl", + "addCovCollection", + "addToColl", + "containsChars", + "copy", + "covIndFromSelector", + "dataToMatrix", + "dataToMatrixFromNames", + "dataToMatrixFromSel", + "dataToStructure", + "enforceSampleRate", + "findMaxTime", + "findMinTime", + "flattenCovMask", + "fromStructure", + "getAllCovLabels", + "getCov", + "getCovDataMask", + "getCovDimension", + "getCovIndicesFromNames", + "getCovLabelsFromMask", + "isCovMaskSet", + "isCovPresent", + "maskAwayAllExcept", + "maskAwayCov", + "maskAwayOnlyCov", + "nActCovar", + "numActCov", + "parseDataSelectorArray", + "plot", + "removeCovariate", + "resample", + "resetCovShift", + "resetMask", + "restoreToOriginal", + "restrictToTimeWindow", + "setCovShift", + "setMask", + "setMaxTime", + "setMinTime", + "setSampleRate", + "sumDimensions", + "toStructure" + ], + "superclass": "handle" + }, + "matlab_class": "CovColl", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "copy", + "mapped_via_alias": true, + "matlab_method": "CovColl", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "addCovCollection", + "mapped_via_alias": false, + "matlab_method": "addCovCollection", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "addToColl", + "mapped_via_alias": false, + "matlab_method": "addToColl", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "containsChars", + "mapped_via_alias": false, + "matlab_method": "containsChars", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "copy", + "mapped_via_alias": false, + "matlab_method": "copy", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "covIndFromSelector", + "mapped_via_alias": false, + "matlab_method": "covIndFromSelector", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToMatrix", + "mapped_via_alias": false, + "matlab_method": "dataToMatrix", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToMatrixFromNames", + "mapped_via_alias": false, + "matlab_method": "dataToMatrixFromNames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToMatrixFromSel", + "mapped_via_alias": false, + "matlab_method": "dataToMatrixFromSel", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToStructure", + "mapped_via_alias": false, + "matlab_method": "dataToStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "enforceSampleRate", + "mapped_via_alias": false, + "matlab_method": "enforceSampleRate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findMaxTime", + "mapped_via_alias": false, + "matlab_method": "findMaxTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findMinTime", + "mapped_via_alias": false, + "matlab_method": "findMinTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "flattenCovMask", + "mapped_via_alias": false, + "matlab_method": "flattenCovMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getAllCovLabels", + "mapped_via_alias": false, + "matlab_method": "getAllCovLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCov", + "mapped_via_alias": false, + "matlab_method": "getCov", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCovDataMask", + "mapped_via_alias": false, + "matlab_method": "getCovDataMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCovDimension", + "mapped_via_alias": false, + "matlab_method": "getCovDimension", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCovIndicesFromNames", + "mapped_via_alias": false, + "matlab_method": "getCovIndicesFromNames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCovLabelsFromMask", + "mapped_via_alias": false, + "matlab_method": "getCovLabelsFromMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isCovMaskSet", + "mapped_via_alias": false, + "matlab_method": "isCovMaskSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isCovPresent", + "mapped_via_alias": false, + "matlab_method": "isCovPresent", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "maskAwayAllExcept", + "mapped_via_alias": false, + "matlab_method": "maskAwayAllExcept", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "maskAwayCov", + "mapped_via_alias": false, + "matlab_method": "maskAwayCov", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "maskAwayOnlyCov", + "mapped_via_alias": false, + "matlab_method": "maskAwayOnlyCov", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "nActCovar", + "mapped_via_alias": false, + "matlab_method": "nActCovar", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "numActCov", + "mapped_via_alias": false, + "matlab_method": "numActCov", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "parseDataSelectorArray", + "mapped_via_alias": false, + "matlab_method": "parseDataSelectorArray", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "removeCovariate", + "mapped_via_alias": false, + "matlab_method": "removeCovariate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resample", + "mapped_via_alias": false, + "matlab_method": "resample", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetCovShift", + "mapped_via_alias": false, + "matlab_method": "resetCovShift", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetMask", + "mapped_via_alias": false, + "matlab_method": "resetMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "restoreToOriginal", + "mapped_via_alias": false, + "matlab_method": "restoreToOriginal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "restrictToTimeWindow", + "mapped_via_alias": false, + "matlab_method": "restrictToTimeWindow", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setCovShift", + "mapped_via_alias": false, + "matlab_method": "setCovShift", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMask", + "mapped_via_alias": false, + "matlab_method": "setMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMaxTime", + "mapped_via_alias": false, + "matlab_method": "setMaxTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMinTime", + "mapped_via_alias": false, + "matlab_method": "setMinTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setSampleRate", + "mapped_via_alias": false, + "matlab_method": "setSampleRate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "sumDimensions", + "mapped_via_alias": false, + "matlab_method": "sumDimensions", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, covariates: 'list[Covariate]') -> None", + "fields": [ + "covariates" + ], + "methods": { + "add_to_coll": "(self, covariate: 'Covariate') -> \"'CovariateCollection'\"", + "copy": "(self) -> \"'CovariateCollection'\"", + "data_to_matrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "data_to_matrix_from_names": "(self, names: 'list[str]') -> 'tuple[np.ndarray, list[str]]'", + "data_to_matrix_from_sel": "(self, selectors: 'list[int]') -> 'tuple[np.ndarray, list[str]]'", + "design_matrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "find_max_sample_rate": "(self) -> 'float'", + "find_max_time": "(self) -> 'float'", + "find_min_sample_rate": "(self) -> 'float'", + "find_min_time": "(self) -> 'float'", + "get_all_cov_labels": "(self) -> 'list[str]'", + "get_cov": "(self, selector: 'int | str') -> 'Covariate'", + "get_cov_dimension": "(self) -> 'int'", + "get_cov_ind_from_name": "(self, name: 'str') -> 'int'", + "get_cov_indices_from_names": "(self, names: 'list[str]') -> 'list[int]'", + "is_cov_present": "(self, name: 'str') -> 'bool'", + "n_act_covar": "(self) -> 'int'", + "num_act_cov": "(self) -> 'int'", + "sum_dimensions": "(self) -> 'int'" + }, + "properties": [ + "time" + ] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.Covariate", + "fixture_path": "tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat", + "key_methods": [ + "get_sub_signal", + "data_to_matrix", + "compute_mean_plus_ci", + "to_structure", + "from_structure" + ], + "python_class": "nstat.signal.Covariate" + }, + "compat": { + "constructor_signature": "(self, time: 'ArrayLike', data: 'ArrayLike', name: 'str' = 'signal', units: 'str | None' = None, x_label: 'str | None' = None, y_label: 'str | None' = None, x_units: 'str | None' = None, y_units: 'str | None' = None, plot_props: 'dict[str, Any]' = , labels: 'list[str]' = , conf_interval: 'Any | None' = None) -> None", + "fields": [ + "conf_interval", + "data", + "labels", + "name", + "plot_props", + "time", + "units", + "x_label", + "x_units", + "y_label", + "y_units" + ], + "methods": { + "Covariate": "(payload: 'dict[str, Any]') -> '_Covariate'", + "align_time": "(self, new_zero_time: 'float' = 0.0) -> \"'Signal'\"", + "clear_plot_props": "(self) -> \"'Signal'\"", + "computeMeanPlusCI": "(self, axis: 'int' = 1, level: 'float' = 0.95) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "compute_mean_plus_ci": "(self, axis: 'int' = 1, level: 'float' = 0.95) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "copy": "(self) -> \"'Signal'\"", + "copySignal": "(self) -> '_Covariate'", + "copy_signal": "(self) -> \"'Signal'\"", + "dataToStructure": "(self) -> 'dict[str, Any]'", + "data_to_matrix": "(self) -> 'np.ndarray'", + "derivative": "(self) -> \"'Signal'\"", + "filtfilt": "(self, b: 'np.ndarray', a: 'np.ndarray') -> \"'Covariate'\"", + "fromStructure": "(payload: 'dict[str, Any]') -> '_Covariate'", + "from_structure": "(payload: 'dict[str, Any]') -> \"'Covariate'\"", + "getData": "(self) -> 'np.ndarray'", + "getLabels": "(self) -> 'list[str]'", + "getNumSignals": "(self) -> 'int'", + "getSampleRate": "(self) -> 'float'", + "getSigRep": "(self) -> 'np.ndarray'", + "getSubSignal": "(self, selector: 'int | str | list[int] | list[str]') -> '_Covariate'", + "getTime": "(self) -> 'np.ndarray'", + "get_labels": "(self) -> 'list[str]'", + "get_sub_signal": "(self, selector: 'Any') -> \"'Covariate'\"", + "integral": "(self) -> 'np.ndarray'", + "isConfIntervalSet": "(self) -> 'bool'", + "is_conf_interval_set": "(self) -> 'bool'", + "merge": "(self, other: \"'Signal'\") -> \"'Signal'\"", + "minus": "(self, other: 'float | np.ndarray | _Signal') -> '_Covariate'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "plus": "(self, other: 'float | np.ndarray | _Signal') -> '_Covariate'", + "resample": "(self, sample_rate_hz: 'float') -> \"'Signal'\"", + "restrict_to_time_window": "(self, min_time: 'float', max_time: 'float') -> \"'Signal'\"", + "setConfInterval": "(self, interval: 'Any') -> '_Covariate'", + "set_conf_interval": "(self, interval: 'Any') -> \"'Covariate'\"", + "set_max_time": "(self, max_time: 'float') -> \"'Signal'\"", + "set_min_time": "(self, min_time: 'float') -> \"'Signal'\"", + "set_name": "(self, name: 'str') -> \"'Signal'\"", + "set_plot_props": "(self, props: 'dict[str, Any]') -> \"'Signal'\"", + "set_units": "(self, units: 'str') -> \"'Signal'\"", + "set_x_units": "(self, units: 'str') -> \"'Signal'\"", + "set_xlabel": "(self, label: 'str') -> \"'Signal'\"", + "set_y_units": "(self, units: 'str') -> \"'Signal'\"", + "set_ylabel": "(self, label: 'str') -> \"'Signal'\"", + "shift_time": "(self, offset_s: 'float') -> \"'Signal'\"", + "toStructure": "(self) -> 'dict[str, Any]'", + "to_structure": "(self) -> 'dict[str, Any]'" + }, + "properties": [ + "duration_s", + "n_channels", + "n_samples", + "sample_rate_hz" + ] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "getData": "data", + "getLabels": "labels", + "getNumSignals": "n_channels", + "getSampleRate": "sample_rate_hz", + "getTime": "time" + }, + "compat_class": "nstat.compat.matlab.Covariate", + "python_class": "nstat.signal.Covariate" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "varargin" + ], + "line": 70, + "name": "Covariate", + "static": false + }, + "matlab_class": "Covariate", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Covariate.m", + "methods": [ + { + "access": "public", + "args": [ + "varargin" + ], + "line": 70, + "name": "Covariate", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "alphaVal" + ], + "line": 76, + "name": "computeMeanPlusCI", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "varargin" + ], + "line": 89, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "varargin" + ], + "line": 113, + "name": "getSubSignal", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "repType" + ], + "line": 123, + "name": "getSigRep", + "static": false + }, + { + "access": "public", + "args": [], + "line": 138, + "name": "get", + "static": false + }, + { + "access": "public", + "args": [], + "line": 141, + "name": "get", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "varargin" + ], + "line": 145, + "name": "filtfilt", + "static": false + }, + { + "access": "public", + "args": [ + "covObj" + ], + "line": 150, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "covObj" + ], + "line": 177, + "name": "isConfIntervalSet", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "ciObj" + ], + "line": 180, + "name": "setConfInterval", + "static": false + }, + { + "access": "public", + "args": [ + "covObj" + ], + "line": 187, + "name": "copySignal", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "covObj2" + ], + "line": 194, + "name": "plus", + "static": false + }, + { + "access": "public", + "args": [ + "covObj", + "covObj2" + ], + "line": 218, + "name": "minus", + "static": false + }, + { + "access": "public", + "args": [ + "covObj" + ], + "line": 243, + "name": "dataToStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 249, + "name": "fromStructure", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 61, + "name": "mu" + }, + { + "access": "public", + "line": 62, + "name": "sigma" + }, + { + "access": "public", + "line": 66, + "name": "ci" + } + ], + "public_methods": [ + "Covariate", + "computeMeanPlusCI", + "copySignal", + "dataToStructure", + "filtfilt", + "fromStructure", + "get", + "getSigRep", + "getSubSignal", + "isConfIntervalSet", + "minus", + "plot", + "plus", + "setConfInterval", + "toStructure" + ], + "superclass": "SignalObj" + }, + "matlab_class": "Covariate", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "Covariate", + "mapped_via_alias": false, + "matlab_method": "Covariate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeMeanPlusCI", + "mapped_via_alias": false, + "matlab_method": "computeMeanPlusCI", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "copySignal", + "mapped_via_alias": false, + "matlab_method": "copySignal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToStructure", + "mapped_via_alias": false, + "matlab_method": "dataToStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "filtfilt", + "mapped_via_alias": false, + "matlab_method": "filtfilt", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "get", + "mapped_via_alias": false, + "matlab_method": "get", + "present_in_compat_surface": false, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSigRep", + "mapped_via_alias": false, + "matlab_method": "getSigRep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSubSignal", + "mapped_via_alias": false, + "matlab_method": "getSubSignal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isConfIntervalSet", + "mapped_via_alias": false, + "matlab_method": "isConfIntervalSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "minus", + "mapped_via_alias": false, + "matlab_method": "minus", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plus", + "mapped_via_alias": false, + "matlab_method": "plus", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setConfInterval", + "mapped_via_alias": false, + "matlab_method": "setConfInterval", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, time: 'ArrayLike', data: 'ArrayLike', name: 'str' = 'signal', units: 'str | None' = None, x_label: 'str | None' = None, y_label: 'str | None' = None, x_units: 'str | None' = None, y_units: 'str | None' = None, plot_props: 'dict[str, Any]' = , labels: 'list[str]' = , conf_interval: 'Any | None' = None) -> None", + "fields": [ + "conf_interval", + "data", + "labels", + "name", + "plot_props", + "time", + "units", + "x_label", + "x_units", + "y_label", + "y_units" + ], + "methods": { + "align_time": "(self, new_zero_time: 'float' = 0.0) -> \"'Signal'\"", + "clear_plot_props": "(self) -> \"'Signal'\"", + "compute_mean_plus_ci": "(self, axis: 'int' = 1, level: 'float' = 0.95) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "copy": "(self) -> \"'Signal'\"", + "copy_signal": "(self) -> \"'Signal'\"", + "data_to_matrix": "(self) -> 'np.ndarray'", + "derivative": "(self) -> \"'Signal'\"", + "filtfilt": "(self, b: 'np.ndarray', a: 'np.ndarray') -> \"'Covariate'\"", + "from_structure": "(payload: 'dict[str, Any]') -> \"'Covariate'\"", + "get_labels": "(self) -> 'list[str]'", + "get_sub_signal": "(self, selector: 'Any') -> \"'Covariate'\"", + "integral": "(self) -> 'np.ndarray'", + "is_conf_interval_set": "(self) -> 'bool'", + "merge": "(self, other: \"'Signal'\") -> \"'Signal'\"", + "resample": "(self, sample_rate_hz: 'float') -> \"'Signal'\"", + "restrict_to_time_window": "(self, min_time: 'float', max_time: 'float') -> \"'Signal'\"", + "set_conf_interval": "(self, interval: 'Any') -> \"'Covariate'\"", + "set_max_time": "(self, max_time: 'float') -> \"'Signal'\"", + "set_min_time": "(self, min_time: 'float') -> \"'Signal'\"", + "set_name": "(self, name: 'str') -> \"'Signal'\"", + "set_plot_props": "(self, props: 'dict[str, Any]') -> \"'Signal'\"", + "set_units": "(self, units: 'str') -> \"'Signal'\"", + "set_x_units": "(self, units: 'str') -> \"'Signal'\"", + "set_xlabel": "(self, label: 'str') -> \"'Signal'\"", + "set_y_units": "(self, units: 'str') -> \"'Signal'\"", + "set_ylabel": "(self, label: 'str') -> \"'Signal'\"", + "shift_time": "(self, offset_s: 'float') -> \"'Signal'\"", + "to_structure": "(self) -> 'dict[str, Any]'" + }, + "properties": [ + "duration_s", + "n_channels", + "n_samples", + "sample_rate_hz" + ] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.DecodingAlgorithms", + "fixture_path": "tests/parity/fixtures/matlab_gold/DecodingExample_gold.mat", + "key_methods": [ + "compute_spike_rate_cis", + "compute_spike_rate_diff_cis", + "decode_weighted_center", + "decode_state_posterior", + "computeSpikeRateCIs" + ], + "python_class": "nstat.decoding.DecodingAlgorithms" + }, + "compat": { + "constructor_signature": "(self, /, *args, **kwargs)", + "fields": [], + "methods": { + "ComputeStimulusCIs": "(posterior: 'np.ndarray', state_values: 'np.ndarray', alpha: 'float' = 0.05) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "KF_ComputeParamStandardErrors": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "KF_EM": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "KF_EMCreateConstraints": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "KF_EStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "KF_MStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PPDecodeFilter": "(spike_counts: 'np.ndarray', tuning_rates: 'np.ndarray', transition: 'np.ndarray | None' = None, prior: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "PPDecodeFilterLinear": "(spike_counts: 'np.ndarray', tuning_rates: 'np.ndarray', transition: 'np.ndarray | None' = None, prior: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "PPDecode_predict": "(x_prev: 'np.ndarray', p_prev: 'np.ndarray', a: 'np.ndarray', q: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "PPDecode_update": "(x_pred: 'np.ndarray', p_pred: 'np.ndarray', y_t: 'np.ndarray', h: 'np.ndarray', r: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "PPDecode_updateLinear": "(x_pred: 'np.ndarray', p_pred: 'np.ndarray', y_t: 'np.ndarray', h: 'np.ndarray', r: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "PPHybridFilter": "(spike_counts: 'np.ndarray', tuning_rates: 'np.ndarray', transition: 'np.ndarray | None' = None, prior: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "PPHybridFilterLinear": "(spike_counts: 'np.ndarray', tuning_rates: 'np.ndarray', transition: 'np.ndarray | None' = None, prior: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "PPSS_EM": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PPSS_EMFB": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PPSS_EStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PPSS_MStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PP_ComputeParamStandardErrors": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PP_EM": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PP_EMCreateConstraints": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PP_EStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PP_MStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "PP_fixedIntervalSmoother": "(xf: 'np.ndarray', pf: 'np.ndarray', xp: 'np.ndarray', pp: 'np.ndarray', a: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "computeSpikeRateCIs": "(*args: 'Any', **kwargs: 'Any') -> 'tuple[Any, np.ndarray, np.ndarray]'", + "computeSpikeRateDiffCIs": "(spike_matrix_a: 'np.ndarray', spike_matrix_b: 'np.ndarray', alpha: 'float' = 0.05) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "decodeStatePosterior": "(spike_counts: 'np.ndarray', tuning_rates: 'np.ndarray', transition: 'np.ndarray | None' = None, prior: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "decodeWeightedCenter": "(spike_counts: 'np.ndarray', tuning_curves: 'np.ndarray') -> 'np.ndarray'", + "estimateInfoMat": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "getPoolSizeCompat": "() -> 'int'", + "kalman_filter": "(y: 'np.ndarray', a: 'np.ndarray', h: 'np.ndarray', q: 'np.ndarray', r: 'np.ndarray', x0: 'np.ndarray', p0: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray, np.ndarray, np.ndarray]'", + "kalman_fixedIntervalSmoother": "(xf: 'np.ndarray', pf: 'np.ndarray', xp: 'np.ndarray', pp: 'np.ndarray', a: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "kalman_predict": "(x_prev: 'np.ndarray', p_prev: 'np.ndarray', a: 'np.ndarray', q: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "kalman_smoother": "(xf: 'np.ndarray', pf: 'np.ndarray', xp: 'np.ndarray', pp: 'np.ndarray', a: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "kalman_smootherFromFiltered": "(y: 'np.ndarray', a: 'np.ndarray', h: 'np.ndarray', q: 'np.ndarray', r: 'np.ndarray', x0: 'np.ndarray', p0: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "kalman_update": "(x_pred: 'np.ndarray', p_pred: 'np.ndarray', y_t: 'np.ndarray', h: 'np.ndarray', r: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "mPPCODecodeLinear": "(spike_counts: 'np.ndarray', tuning_rates: 'np.ndarray', transition: 'np.ndarray | None' = None, prior: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "mPPCODecode_predict": "(x_prev: 'np.ndarray', p_prev: 'np.ndarray', a: 'np.ndarray', q: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "mPPCODecode_update": "(x_pred: 'np.ndarray', p_pred: 'np.ndarray', y_t: 'np.ndarray', h: 'np.ndarray', r: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "mPPCO_ComputeParamStandardErrors": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "mPPCO_EM": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "mPPCO_EMCreateConstraints": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "mPPCO_EStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "mPPCO_MStep": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "mPPCO_fixedIntervalSmoother": "(xf: 'np.ndarray', pf: 'np.ndarray', xp: 'np.ndarray', pp: 'np.ndarray', a: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "prepareEMResults": "(*_args: 'Any', **_kwargs: 'Any') -> 'None'", + "ukf": "(x_prev: 'np.ndarray', p_prev: 'np.ndarray', a: 'np.ndarray', q: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "ukf_sigmas": "(x: 'np.ndarray', p: 'np.ndarray', kappa: 'float' = 0.0) -> 'np.ndarray'", + "ukf_ut": "(sigmas: 'np.ndarray', wm: 'np.ndarray', wc: 'np.ndarray', noise: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/DecodingExample_gold.mat" + }, + "mapping": { + "alias_methods": { + "computeSpikeRateCIs": "compute_spike_rate_cis", + "decodeStatePosterior": "decode_state_posterior", + "decodeWeightedCenter": "decode_weighted_center" + }, + "compat_class": "nstat.compat.matlab.DecodingAlgorithms", + "python_class": "nstat.decoding.DecodingAlgorithms" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [], + "line": null, + "name": "DecodingAlgorithms", + "static": false + }, + "matlab_class": "DecodingAlgorithms", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/DecodingAlgorithms.m", + "methods": [ + { + "access": "public", + "args": [ + "A", + "Q", + "Px0", + "dN", + "lambdaCIFColl", + "binwidth", + "x0", + "Pi0", + "yT", + "PiT", + "estimateTarget", + "Wconv" + ], + "line": 62, + "name": "PPDecodeFilter", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "dN", + "mu", + "beta", + "fitType", + "delta", + "gamma", + "windowTimes", + "x0", + "Pi0", + "yT", + "PiT", + "estimateTarget", + "Wconv" + ], + "line": 291, + "name": "PPDecodeFilterLinear", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "dN", + "lags", + "mu", + "beta", + "fitType", + "delta", + "gamma", + "windowTimes", + "x0", + "Pi0" + ], + "line": 646, + "name": "PP_fixedIntervalSmoother", + "static": true + }, + { + "access": "public", + "args": [ + "x_u", + "W_u", + "A", + "Q", + "Wconv" + ], + "line": 756, + "name": "PPDecode_predict", + "static": true + }, + { + "access": "public", + "args": [ + "x_p", + "W_p", + "dN", + "lambdaIn", + "binwidth", + "time_index", + "WuConv" + ], + "line": 779, + "name": "PPDecode_update", + "static": true + }, + { + "access": "public", + "args": [ + "x_p", + "W_p", + "dN", + "mu", + "beta", + "fitType", + "gamma", + "HkAll", + "time_index", + "WuConv" + ], + "line": 844, + "name": "PPDecode_updateLinear", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "p_ij", + "Mu0", + "dN", + "mu", + "beta", + "fitType", + "binwidth", + "gamma", + "windowTimes", + "x0", + "Pi0", + "yT", + "PiT", + "estimateTarget", + "MinClassificationError" + ], + "line": 953, + "name": "PPHybridFilterLinear", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "p_ij", + "Mu0", + "dN", + "lambdaCIFColl", + "binwidth", + "x0", + "Pi0", + "yT", + "PiT", + "estimateTarget", + "MinClassificationError" + ], + "line": 1425, + "name": "PPHybridFilter", + "static": true + }, + { + "access": "public", + "args": [ + "fstate", + "x", + "P", + "hmeas", + "z", + "Q", + "R" + ], + "line": 1854, + "name": "ukf", + "static": true + }, + { + "access": "public", + "args": [ + "f", + "X", + "Wm", + "Wc", + "n", + "R" + ], + "line": 1929, + "name": "ukf_ut", + "static": true + }, + { + "access": "public", + "args": [ + "x", + "P", + "c" + ], + "line": 1954, + "name": "ukf_sigmas", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "C", + "Pv", + "Pw", + "Px0", + "x0", + "y", + "GnConv" + ], + "line": 1969, + "name": "kalman_filter", + "static": true + }, + { + "access": "public", + "args": [ + "x_p", + "Pe_p", + "C", + "Pw", + "y", + "GnConv" + ], + "line": 2019, + "name": "kalman_update", + "static": true + }, + { + "access": "public", + "args": [ + "x_u", + "Pe_u", + "A", + "Pv", + "GnConv" + ], + "line": 2034, + "name": "kalman_predict", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "C", + "Pv", + "Pw", + "Px0", + "x0", + "y", + "lags" + ], + "line": 2047, + "name": "kalman_fixedIntervalSmoother", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "x_p", + "Pe_p", + "x_u", + "Pe_u" + ], + "line": 2085, + "name": "kalman_smootherFromFiltered", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "C", + "Pv", + "Pw", + "Px0", + "x0", + "y" + ], + "line": 2118, + "name": "kalman_smoother", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q0", + "x0", + "dN", + "fitType", + "delta", + "gamma0", + "windowTimes", + "numBasis", + "neuronName" + ], + "line": 2157, + "name": "PPSS_EMFB", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q0", + "x0", + "dN", + "fitType", + "delta", + "gamma0", + "windowTimes", + "numBasis", + "Hk" + ], + "line": 2303, + "name": "PPSS_EM", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "x0", + "dN", + "HkAll", + "fitType", + "delta", + "gamma", + "numBasis" + ], + "line": 2432, + "name": "PPSS_EStep", + "static": true + }, + { + "access": "public", + "args": [ + "dN", + "HkAll", + "fitType", + "x_K", + "W_K", + "gamma", + "delta", + "sumXkTerms", + "windowTimes" + ], + "line": 2599, + "name": "PPSS_MStep", + "static": true + }, + { + "access": "public", + "args": [ + "fitType", + "neuronNumber", + "dN", + "HkAll", + "xK", + "WK", + "Q", + "gamma", + "windowTimes", + "delta", + "informationMatrix", + "logll" + ], + "line": 2727, + "name": "prepareEMResults", + "static": true + }, + { + "access": "public", + "args": [ + "fitType", + "xK", + "Wku", + "delta", + "Mc", + "alphaVal" + ], + "line": 2883, + "name": "ComputeStimulusCIs", + "static": true + }, + { + "access": "public", + "args": [ + "fitType", + "dN", + "HkAll", + "A", + "x0", + "xK", + "WK", + "Wku", + "Q", + "gamma", + "windowTimes", + "SumXkTerms", + "delta", + "Mc" + ], + "line": 2933, + "name": "estimateInfoMat", + "static": true + }, + { + "access": "public", + "args": [ + "xK", + "Wku", + "dN", + "t0", + "tf", + "fitType", + "delta", + "gamma", + "windowTimes", + "Mc", + "alphaVal" + ], + "line": 3108, + "name": "computeSpikeRateCIs", + "static": true + }, + { + "access": "public", + "args": [ + "xK", + "Wku", + "dN", + "time1", + "time2", + "fitType", + "delta", + "gamma", + "windowTimes", + "Mc", + "alphaVal" + ], + "line": 3210, + "name": "computeSpikeRateDiffCIs", + "static": true + }, + { + "access": "public", + "args": [ + "EstimateA", + "AhatDiag", + "QhatDiag", + "QhatIsotropic", + "RhatDiag", + "RhatIsotropic", + "Estimatex0", + "EstimatePx0", + "Px0Isotropic", + "mcIter", + "EnableIkeda" + ], + "line": 3316, + "name": "KF_EMCreateConstraints", + "static": true + }, + { + "access": "public", + "args": [ + "y", + "Ahat0", + "Qhat0", + "Chat0", + "Rhat0", + "alphahat0", + "x0", + "Px0", + "KFEM_Constraints" + ], + "line": 3377, + "name": "KF_EM", + "static": true + }, + { + "access": "public", + "args": [ + "y", + "xKFinal", + "WKFinal", + "Ahat", + "Qhat", + "Chat", + "Rhat", + "alphahat", + "x0hat", + "Px0hat", + "ExpectationSumsFinal", + "KFEM_Constraints" + ], + "line": 3681, + "name": "KF_ComputeParamStandardErrors", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "C", + "R", + "y", + "alpha", + "x0", + "Px0" + ], + "line": 4422, + "name": "KF_EStep", + "static": true + }, + { + "access": "public", + "args": [ + "y", + "x_K", + "x0", + "Px0", + "ExpectationSums", + "KFEM_Constraints" + ], + "line": 4520, + "name": "KF_MStep", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "C", + "R", + "y", + "alpha", + "dN", + "lags", + "mu", + "beta", + "fitType", + "delta", + "gamma", + "windowTimes", + "x0", + "Px0", + "HkAll" + ], + "line": 4608, + "name": "mPPCO_fixedIntervalSmoother", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "C", + "R", + "y", + "alpha", + "dN", + "mu", + "beta", + "fitType", + "delta", + "gamma", + "windowTimes", + "x0", + "Px0", + "HkAll" + ], + "line": 4710, + "name": "mPPCODecodeLinear", + "static": true + }, + { + "access": "public", + "args": [ + "x_u", + "W_u", + "A", + "Q" + ], + "line": 4867, + "name": "mPPCODecode_predict", + "static": true + }, + { + "access": "public", + "args": [ + "x_p", + "W_p", + "C", + "R", + "y", + "alpha", + "dN", + "mu", + "beta", + "fitType", + "gamma", + "HkAll", + "time_index", + "WuConv" + ], + "line": 4876, + "name": "mPPCODecode_update", + "static": true + }, + { + "access": "public", + "args": [ + "EstimateA", + "AhatDiag", + "QhatDiag", + "QhatIsotropic", + "RhatDiag", + "RhatIsotropic", + "Estimatex0", + "EstimatePx0", + "Px0Isotropic", + "mcIter", + "EnableIkeda" + ], + "line": 4966, + "name": "mPPCO_EMCreateConstraints", + "static": true + }, + { + "access": "public", + "args": [ + "y", + "dN", + "xKFinal", + "WKFinal", + "Ahat", + "Qhat", + "Chat", + "Rhat", + "alphahat", + "x0hat", + "Px0hat", + "ExpectationSumsFinal", + "fitType", + "muhat", + "betahat", + "gammahat", + "windowTimes", + "HkAll", + "mPPCOEM_Constraints" + ], + "line": 5027, + "name": "mPPCO_ComputeParamStandardErrors", + "static": true + }, + { + "access": "public", + "args": [ + "y", + "dN", + "Ahat0", + "Qhat0", + "Chat0", + "Rhat0", + "alphahat0", + "mu", + "beta", + "fitType", + "delta", + "gamma", + "windowTimes", + "x0", + "Px0", + "mPPCOEM_Constraints", + "MstepMethod" + ], + "line": 6160, + "name": "mPPCO_EM", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "C", + "R", + "y", + "alpha", + "dN", + "mu", + "beta", + "fitType", + "delta", + "gamma", + "HkAll", + "x0", + "Px0" + ], + "line": 6576, + "name": "mPPCO_EStep", + "static": true + }, + { + "access": "public", + "args": [ + "dN", + "y", + "x_K", + "W_K", + "x0", + "Px0", + "ExpectationSums", + "fitType", + "muhat", + "betahat", + "gammahat", + "windowTimes", + "HkAll", + "mPPCOEM_Constraints", + "MstepMethod" + ], + "line": 6794, + "name": "mPPCO_MStep", + "static": true + }, + { + "access": "public", + "args": [ + "EstimateA", + "AhatDiag", + "QhatDiag", + "QhatIsotropic", + "Estimatex0", + "EstimatePx0", + "Px0Isotropic", + "mcIter", + "EnableIkeda" + ], + "line": 7684, + "name": "PP_EMCreateConstraints", + "static": true + }, + { + "access": "public", + "args": [ + "dN", + "xKFinal", + "WKFinal", + "Ahat", + "Qhat", + "x0hat", + "Px0hat", + "ExpectationSumsFinal", + "fitType", + "muhat", + "betahat", + "gammahat", + "windowTimes", + "HkAll", + "PPEM_Constraints" + ], + "line": 7733, + "name": "PP_ComputeParamStandardErrors", + "static": true + }, + { + "access": "public", + "args": [ + "dN", + "Ahat0", + "Qhat0", + "mu", + "beta", + "fitType", + "delta", + "gamma", + "windowTimes", + "x0", + "Px0", + "PPEM_Constraints", + "MstepMethod" + ], + "line": 8614, + "name": "PP_EM", + "static": true + }, + { + "access": "public", + "args": [ + "A", + "Q", + "dN", + "mu", + "beta", + "fitType", + "gamma", + "HkAll", + "x0", + "Px0" + ], + "line": 9286, + "name": "PP_EStep", + "static": true + }, + { + "access": "public", + "args": [ + "dN", + "x_K", + "W_K", + "x0", + "Px0", + "ExpectationSums", + "fitType", + "muhat", + "betahat", + "gammahat", + "windowTimes", + "HkAll", + "PPEM_Constraints", + "MstepMethod" + ], + "line": 9678, + "name": "PP_MStep", + "static": true + }, + { + "access": "public", + "args": [], + "line": 10791, + "name": "getPoolSizeCompat", + "static": true + } + ], + "private_methods": [], + "properties": [], + "public_methods": [ + "ComputeStimulusCIs", + "KF_ComputeParamStandardErrors", + "KF_EM", + "KF_EMCreateConstraints", + "KF_EStep", + "KF_MStep", + "PPDecodeFilter", + "PPDecodeFilterLinear", + "PPDecode_predict", + "PPDecode_update", + "PPDecode_updateLinear", + "PPHybridFilter", + "PPHybridFilterLinear", + "PPSS_EM", + "PPSS_EMFB", + "PPSS_EStep", + "PPSS_MStep", + "PP_ComputeParamStandardErrors", + "PP_EM", + "PP_EMCreateConstraints", + "PP_EStep", + "PP_MStep", + "PP_fixedIntervalSmoother", + "computeSpikeRateCIs", + "computeSpikeRateDiffCIs", + "estimateInfoMat", + "getPoolSizeCompat", + "kalman_filter", + "kalman_fixedIntervalSmoother", + "kalman_predict", + "kalman_smoother", + "kalman_smootherFromFiltered", + "kalman_update", + "mPPCODecodeLinear", + "mPPCODecode_predict", + "mPPCODecode_update", + "mPPCO_ComputeParamStandardErrors", + "mPPCO_EM", + "mPPCO_EMCreateConstraints", + "mPPCO_EStep", + "mPPCO_MStep", + "mPPCO_fixedIntervalSmoother", + "prepareEMResults", + "ukf", + "ukf_sigmas", + "ukf_ut" + ], + "superclass": "" + }, + "matlab_class": "DecodingAlgorithms", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ComputeStimulusCIs", + "mapped_via_alias": false, + "matlab_method": "ComputeStimulusCIs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "KF_ComputeParamStandardErrors", + "mapped_via_alias": false, + "matlab_method": "KF_ComputeParamStandardErrors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "KF_EM", + "mapped_via_alias": false, + "matlab_method": "KF_EM", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "KF_EMCreateConstraints", + "mapped_via_alias": false, + "matlab_method": "KF_EMCreateConstraints", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "KF_EStep", + "mapped_via_alias": false, + "matlab_method": "KF_EStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "KF_MStep", + "mapped_via_alias": false, + "matlab_method": "KF_MStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PPDecodeFilter", + "mapped_via_alias": false, + "matlab_method": "PPDecodeFilter", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PPDecodeFilterLinear", + "mapped_via_alias": false, + "matlab_method": "PPDecodeFilterLinear", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PPDecode_predict", + "mapped_via_alias": false, + "matlab_method": "PPDecode_predict", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PPDecode_update", + "mapped_via_alias": false, + "matlab_method": "PPDecode_update", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PPDecode_updateLinear", + "mapped_via_alias": false, + "matlab_method": "PPDecode_updateLinear", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PPHybridFilter", + "mapped_via_alias": false, + "matlab_method": "PPHybridFilter", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PPHybridFilterLinear", + "mapped_via_alias": false, + "matlab_method": "PPHybridFilterLinear", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PPSS_EM", + "mapped_via_alias": false, + "matlab_method": "PPSS_EM", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PPSS_EMFB", + "mapped_via_alias": false, + "matlab_method": "PPSS_EMFB", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PPSS_EStep", + "mapped_via_alias": false, + "matlab_method": "PPSS_EStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PPSS_MStep", + "mapped_via_alias": false, + "matlab_method": "PPSS_MStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PP_ComputeParamStandardErrors", + "mapped_via_alias": false, + "matlab_method": "PP_ComputeParamStandardErrors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PP_EM", + "mapped_via_alias": false, + "matlab_method": "PP_EM", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PP_EMCreateConstraints", + "mapped_via_alias": false, + "matlab_method": "PP_EMCreateConstraints", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PP_EStep", + "mapped_via_alias": false, + "matlab_method": "PP_EStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "PP_MStep", + "mapped_via_alias": false, + "matlab_method": "PP_MStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "PP_fixedIntervalSmoother", + "mapped_via_alias": false, + "matlab_method": "PP_fixedIntervalSmoother", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "compute_spike_rate_cis", + "mapped_via_alias": true, + "matlab_method": "computeSpikeRateCIs", + "present_in_compat_surface": false, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeSpikeRateDiffCIs", + "mapped_via_alias": false, + "matlab_method": "computeSpikeRateDiffCIs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "estimateInfoMat", + "mapped_via_alias": false, + "matlab_method": "estimateInfoMat", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getPoolSizeCompat", + "mapped_via_alias": false, + "matlab_method": "getPoolSizeCompat", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "kalman_filter", + "mapped_via_alias": false, + "matlab_method": "kalman_filter", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "kalman_fixedIntervalSmoother", + "mapped_via_alias": false, + "matlab_method": "kalman_fixedIntervalSmoother", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "kalman_predict", + "mapped_via_alias": false, + "matlab_method": "kalman_predict", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "kalman_smoother", + "mapped_via_alias": false, + "matlab_method": "kalman_smoother", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "kalman_smootherFromFiltered", + "mapped_via_alias": false, + "matlab_method": "kalman_smootherFromFiltered", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "kalman_update", + "mapped_via_alias": false, + "matlab_method": "kalman_update", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mPPCODecodeLinear", + "mapped_via_alias": false, + "matlab_method": "mPPCODecodeLinear", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mPPCODecode_predict", + "mapped_via_alias": false, + "matlab_method": "mPPCODecode_predict", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mPPCODecode_update", + "mapped_via_alias": false, + "matlab_method": "mPPCODecode_update", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "mPPCO_ComputeParamStandardErrors", + "mapped_via_alias": false, + "matlab_method": "mPPCO_ComputeParamStandardErrors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "mPPCO_EM", + "mapped_via_alias": false, + "matlab_method": "mPPCO_EM", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "mPPCO_EMCreateConstraints", + "mapped_via_alias": false, + "matlab_method": "mPPCO_EMCreateConstraints", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "mPPCO_EStep", + "mapped_via_alias": false, + "matlab_method": "mPPCO_EStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "mPPCO_MStep", + "mapped_via_alias": false, + "matlab_method": "mPPCO_MStep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mPPCO_fixedIntervalSmoother", + "mapped_via_alias": false, + "matlab_method": "mPPCO_fixedIntervalSmoother", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "prepareEMResults", + "mapped_via_alias": false, + "matlab_method": "prepareEMResults", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ukf", + "mapped_via_alias": false, + "matlab_method": "ukf", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ukf_sigmas", + "mapped_via_alias": false, + "matlab_method": "ukf_sigmas", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ukf_ut", + "mapped_via_alias": false, + "matlab_method": "ukf_ut", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, /, *args, **kwargs)", + "fields": [], + "methods": { + "compute_spike_rate_cis": "(spike_matrix: 'np.ndarray', alpha: 'float' = 0.05) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "compute_spike_rate_diff_cis": "(spike_matrix_a: 'np.ndarray', spike_matrix_b: 'np.ndarray', alpha: 'float' = 0.05) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "compute_stimulus_cis": "(posterior: 'np.ndarray', state_values: 'np.ndarray', alpha: 'float' = 0.05) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "decode_state_posterior": "(spike_counts: 'np.ndarray', tuning_rates: 'np.ndarray', transition: 'np.ndarray | None' = None, prior: 'np.ndarray | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "decode_weighted_center": "(spike_counts: 'np.ndarray', tuning_curves: 'np.ndarray') -> 'np.ndarray'", + "kalman_filter": "(y: 'np.ndarray', a: 'np.ndarray', h: 'np.ndarray', q: 'np.ndarray', r: 'np.ndarray', x0: 'np.ndarray', p0: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray, np.ndarray, np.ndarray]'", + "kalman_fixed_interval_smoother": "(xf: 'np.ndarray', pf: 'np.ndarray', xp: 'np.ndarray', pp: 'np.ndarray', a: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "kalman_predict": "(x_prev: 'np.ndarray', p_prev: 'np.ndarray', a: 'np.ndarray', q: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'", + "kalman_update": "(x_pred: 'np.ndarray', p_pred: 'np.ndarray', y_t: 'np.ndarray', h: 'np.ndarray', r: 'np.ndarray') -> 'tuple[np.ndarray, np.ndarray]'" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.Events", + "fixture_path": "tests/parity/fixtures/matlab_gold/EventsExamples_gold.mat", + "key_methods": [ + "subset", + "merge", + "shift", + "to_structure", + "from_structure" + ], + "python_class": "nstat.events.Events" + }, + "compat": { + "constructor_signature": "(self, times: 'np.ndarray', labels: 'list[str]' = ) -> None", + "fields": [ + "labels", + "times" + ], + "methods": { + "Events": "(*args: 'Any', **kwargs: 'Any') -> '_Events'", + "dsxy2figxy": "(x: 'np.ndarray | float', y: 'np.ndarray | float') -> 'np.ndarray'", + "fromStructure": "(payload: 'dict[str, Any]') -> '_Events'", + "getTimes": "(self) -> 'np.ndarray'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "subset": "(self, start_s: 'float', end_s: 'float') -> \"'Events'\"", + "toStructure": "(self) -> 'dict[str, Any]'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/EventsExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "getTimes": "times", + "subset": "subset" + }, + "compat_class": "nstat.compat.matlab.Events", + "python_class": "nstat.events.Events" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "eventTimes", + "eventLabels", + "eventColor" + ], + "line": 68, + "name": "Events", + "static": false + }, + "matlab_class": "Events", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Events.m", + "methods": [ + { + "access": "public", + "args": [ + "eventTimes", + "eventLabels", + "eventColor" + ], + "line": 68, + "name": "Events", + "static": false + }, + { + "access": "public", + "args": [ + "EObj", + "handle", + "colorString" + ], + "line": 83, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "EObj" + ], + "line": 124, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 136, + "name": "fromStructure", + "static": true + }, + { + "access": "public", + "args": [ + "varargin" + ], + "line": 155, + "name": "dsxy2figxy", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 62, + "name": "eventTimes" + }, + { + "access": "public", + "line": 63, + "name": "eventLabels" + }, + { + "access": "public", + "line": 64, + "name": "eventColor" + } + ], + "public_methods": [ + "Events", + "dsxy2figxy", + "fromStructure", + "plot", + "toStructure" + ], + "superclass": "" + }, + "matlab_class": "Events", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "Events", + "mapped_via_alias": false, + "matlab_method": "Events", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dsxy2figxy", + "mapped_via_alias": false, + "matlab_method": "dsxy2figxy", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, times: 'np.ndarray', labels: 'list[str]' = ) -> None", + "fields": [ + "labels", + "times" + ], + "methods": { + "subset": "(self, start_s: 'float', end_s: 'float') -> \"'Events'\"" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.FitResSummary", + "fixture_path": "tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat", + "key_methods": [ + "best_by_aic", + "best_by_bic", + "diff_aic", + "diff_bic", + "to_structure" + ], + "python_class": "nstat.fit.FitSummary" + }, + "compat": { + "constructor_signature": "(self, results: 'list[FitResult]') -> None", + "fields": [ + "results" + ], + "methods": { + "FitResSummary": "(fitResultsCell: 'list[_FitResult] | _FitResult') -> '_FitSummary'", + "bestByAIC": "(self) -> '_FitResult'", + "bestByBIC": "(self) -> '_FitResult'", + "best_by_aic": "(self) -> 'FitResult'", + "best_by_bic": "(self) -> 'FitResult'", + "binCoeffs": "(self, minVal: 'float', maxVal: 'float', binSize: 'float' = 0.1) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "bin_coeffs": "(self, min_val: 'float', max_val: 'float', bin_size: 'float' = 0.1) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "boxPlot": "(self, X: 'np.ndarray | None' = None, diffIndex: 'int' = 1, h: 'Any' = None, dataLabels: 'list[str] | None' = None, *_args: 'Any', **_kwargs: 'Any') -> 'dict[str, np.ndarray]'", + "box_plot": "(self, X: 'np.ndarray | None' = None, diff_index: 'int' = 1) -> 'dict[str, np.ndarray]'", + "computeDiffMat": "(self, metric: 'str' = 'aic') -> 'np.ndarray'", + "compute_diff_mat": "(self, metric: 'str' = 'aic') -> 'np.ndarray'", + "fromStructure": "(structure: 'dict[str, Any]') -> '_FitSummary'", + "from_structure": "(payload: 'dict[str, Any]') -> \"'FitSummary'\"", + "getCoeffIndex": "(self, fitNum: 'int' = 1, sortByEpoch: 'bool' = False) -> 'tuple[np.ndarray, np.ndarray, int]'", + "getCoeffs": "(self, fitNum: 'int' = 1) -> 'tuple[np.ndarray, list[str], np.ndarray]'", + "getDiffAIC": "(self) -> 'np.ndarray'", + "getDiffBIC": "(self) -> 'np.ndarray'", + "getDifflogLL": "(self) -> 'np.ndarray'", + "getHistCoeffs": "(self, fitNum: 'int' = 1) -> 'tuple[np.ndarray, list[str], np.ndarray]'", + "getHistIndex": "(self, fitNum: 'int' = 1, sortByEpoch: 'bool' = False) -> 'tuple[np.ndarray, np.ndarray, int]'", + "getSigCoeffs": "(self, fitNum: 'int' = 1) -> 'tuple[np.ndarray, list[str], np.ndarray]'", + "getUniqueLabels": "(self) -> 'list[str]'", + "get_coeff_index": "(self, fit_num: 'int' = 1, sort_by_epoch: 'bool' = False) -> 'tuple[np.ndarray, np.ndarray, int]'", + "get_coeffs": "(self, fit_num: 'int' = 1) -> 'tuple[np.ndarray, list[str], np.ndarray]'", + "get_diff_aic": "(self) -> 'np.ndarray'", + "get_diff_bic": "(self) -> 'np.ndarray'", + "get_diff_log_likelihood": "(self) -> 'np.ndarray'", + "get_unique_labels": "(self) -> 'list[str]'", + "mapCovLabelsToUniqueLabels": "(self) -> 'list[str]'", + "plot2dCoeffSummary": "(self, fitNum: 'int' = 1) -> 'Any'", + "plot3dCoeffSummary": "(self, fitNum: 'int' = 1) -> 'Any'", + "plotAIC": "(self) -> 'Any'", + "plotAllCoeffs": "(self, fitNum: 'int' = 1) -> 'Any'", + "plotBIC": "(self) -> 'Any'", + "plotCoeffsWithoutHistory": "(self, fitNum: 'int' = 1) -> 'Any'", + "plotHistCoeffs": "(self, fitNum: 'int' = 1) -> 'Any'", + "plotIC": "(self, metric: 'str' = 'aic') -> 'Any'", + "plotKSSummary": "(self) -> 'Any'", + "plotResidualSummary": "(self) -> 'Any'", + "plotSummary": "(self, fitNum: 'int' = 1) -> 'Any'", + "plotlogLL": "(self) -> 'Any'", + "setCoeffRange": "(self, minVal: 'float', maxVal: 'float') -> '_FitSummary'", + "toStructure": "(self) -> 'dict[str, Any]'", + "to_structure": "(self) -> 'dict[str, Any]'", + "xticklabel_rotate": "(XTick: 'np.ndarray', rot: 'float', *args: 'Any', **kwargs: 'Any') -> 'Any'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "class_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat" + }, + "mapping": { + "alias_methods": { + "bestByAIC": "best_by_aic", + "bestByBIC": "best_by_bic" + }, + "compat_class": "nstat.compat.matlab.FitResSummary", + "python_class": "nstat.fit.FitSummary" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "fitResultsCell" + ], + "line": 75, + "name": "FitResSummary", + "static": false + }, + "matlab_class": "FitResSummary", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/FitResSummary.m", + "methods": [ + { + "access": "public", + "args": [ + "fitResultsCell" + ], + "line": 75, + "name": "FitResSummary", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj" + ], + "line": 161, + "name": "mapCovLabelsToUniqueLabels", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "diffIndex", + "makePlot", + "h" + ], + "line": 188, + "name": "getDiffAIC", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "diffIndex", + "makePlot", + "h" + ], + "line": 213, + "name": "getDiffBIC", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "diffIndex", + "makePlot", + "h" + ], + "line": 240, + "name": "getDifflogLL", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "minVal", + "maxVal", + "binSize" + ], + "line": 267, + "name": "binCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "minVal", + "maxVal" + ], + "line": 326, + "name": "setCoeffRange", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "fitNum" + ], + "line": 332, + "name": "getSigCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "h" + ], + "line": 349, + "name": "plotIC", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "h", + "fitNum", + "plotProps", + "plotSignificance", + "subIndex" + ], + "line": 365, + "name": "plotAllCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "h" + ], + "line": 427, + "name": "plot3dCoeffSummary", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "h" + ], + "line": 446, + "name": "plot2dCoeffSummary", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "neurons" + ], + "line": 473, + "name": "plotKSSummary", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj" + ], + "line": 524, + "name": "plotAIC", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj" + ], + "line": 549, + "name": "plotBIC", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj" + ], + "line": 573, + "name": "plotlogLL", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj" + ], + "line": 597, + "name": "plotResidualSummary", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj" + ], + "line": 626, + "name": "plotSummary", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "X", + "diffIndex", + "h", + "dataLabels", + "varargin" + ], + "line": 656, + "name": "boxPlot", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj" + ], + "line": 705, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "fitNum", + "sortByEpoch" + ], + "line": 721, + "name": "getCoeffIndex", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "fitNum", + "sortByEpoch", + "plotSignificance" + ], + "line": 798, + "name": "plotCoeffsWithoutHistory", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "fitNum", + "sortByEpoch" + ], + "line": 820, + "name": "getHistIndex", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "fitNum" + ], + "line": 887, + "name": "getCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "fitNum" + ], + "line": 1014, + "name": "getHistCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "frsObj", + "fitNum", + "sortByEpoch", + "plotSignificance" + ], + "line": 1094, + "name": "plotHistCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 1117, + "name": "fromStructure", + "static": true + }, + { + "access": "public", + "args": [ + "MAT", + "diffIndex" + ], + "line": 1127, + "name": "computeDiffMat", + "static": true + }, + { + "access": "public", + "args": [ + "covLabels" + ], + "line": 1134, + "name": "getUniqueLabels", + "static": true + }, + { + "access": "public", + "args": [ + "XTick", + "rot", + "varargin" + ], + "line": 1143, + "name": "xticklabel_rotate", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 48, + "name": "fitResCell" + }, + { + "access": "public", + "line": 49, + "name": "fitNames" + }, + { + "access": "public", + "line": 50, + "name": "numResults" + }, + { + "access": "public", + "line": 51, + "name": "maxNumIndex" + }, + { + "access": "public", + "line": 52, + "name": "dev" + }, + { + "access": "public", + "line": 53, + "name": "AIC" + }, + { + "access": "public", + "line": 54, + "name": "BIC" + }, + { + "access": "public", + "line": 55, + "name": "logLL" + }, + { + "access": "public", + "line": 56, + "name": "bAct" + }, + { + "access": "public", + "line": 57, + "name": "seAct" + }, + { + "access": "public", + "line": 58, + "name": "sigIndex" + }, + { + "access": "public", + "line": 59, + "name": "covLabels" + }, + { + "access": "public", + "line": 60, + "name": "uniqueCovLabels" + }, + { + "access": "public", + "line": 61, + "name": "indicesToUniqueLabels" + }, + { + "access": "public", + "line": 62, + "name": "flatMask" + }, + { + "access": "public", + "line": 63, + "name": "neuronNumbers" + }, + { + "access": "public", + "line": 64, + "name": "numNeurons" + }, + { + "access": "public", + "line": 65, + "name": "numCoeffs" + }, + { + "access": "public", + "line": 66, + "name": "numResultsCoeffPresent" + }, + { + "access": "public", + "line": 67, + "name": "KSStats" + }, + { + "access": "public", + "line": 68, + "name": "KSPvalues" + }, + { + "access": "public", + "line": 69, + "name": "withinConfInt" + }, + { + "access": "public", + "line": 70, + "name": "plotParams" + }, + { + "access": "public", + "line": 71, + "name": "coeffRange" + } + ], + "public_methods": [ + "FitResSummary", + "binCoeffs", + "boxPlot", + "computeDiffMat", + "fromStructure", + "getCoeffIndex", + "getCoeffs", + "getDiffAIC", + "getDiffBIC", + "getDifflogLL", + "getHistCoeffs", + "getHistIndex", + "getSigCoeffs", + "getUniqueLabels", + "mapCovLabelsToUniqueLabels", + "plot2dCoeffSummary", + "plot3dCoeffSummary", + "plotAIC", + "plotAllCoeffs", + "plotBIC", + "plotCoeffsWithoutHistory", + "plotHistCoeffs", + "plotIC", + "plotKSSummary", + "plotResidualSummary", + "plotSummary", + "plotlogLL", + "setCoeffRange", + "toStructure", + "xticklabel_rotate" + ], + "superclass": "handle" + }, + "matlab_class": "FitResSummary", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "FitResSummary", + "mapped_via_alias": false, + "matlab_method": "FitResSummary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "binCoeffs", + "mapped_via_alias": false, + "matlab_method": "binCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "boxPlot", + "mapped_via_alias": false, + "matlab_method": "boxPlot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeDiffMat", + "mapped_via_alias": false, + "matlab_method": "computeDiffMat", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCoeffIndex", + "mapped_via_alias": false, + "matlab_method": "getCoeffIndex", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCoeffs", + "mapped_via_alias": false, + "matlab_method": "getCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getDiffAIC", + "mapped_via_alias": false, + "matlab_method": "getDiffAIC", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getDiffBIC", + "mapped_via_alias": false, + "matlab_method": "getDiffBIC", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getDifflogLL", + "mapped_via_alias": false, + "matlab_method": "getDifflogLL", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getHistCoeffs", + "mapped_via_alias": false, + "matlab_method": "getHistCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getHistIndex", + "mapped_via_alias": false, + "matlab_method": "getHistIndex", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSigCoeffs", + "mapped_via_alias": false, + "matlab_method": "getSigCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getUniqueLabels", + "mapped_via_alias": false, + "matlab_method": "getUniqueLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mapCovLabelsToUniqueLabels", + "mapped_via_alias": false, + "matlab_method": "mapCovLabelsToUniqueLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot2dCoeffSummary", + "mapped_via_alias": false, + "matlab_method": "plot2dCoeffSummary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot3dCoeffSummary", + "mapped_via_alias": false, + "matlab_method": "plot3dCoeffSummary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotAIC", + "mapped_via_alias": false, + "matlab_method": "plotAIC", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotAllCoeffs", + "mapped_via_alias": false, + "matlab_method": "plotAllCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotBIC", + "mapped_via_alias": false, + "matlab_method": "plotBIC", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotCoeffsWithoutHistory", + "mapped_via_alias": false, + "matlab_method": "plotCoeffsWithoutHistory", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotHistCoeffs", + "mapped_via_alias": false, + "matlab_method": "plotHistCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotIC", + "mapped_via_alias": false, + "matlab_method": "plotIC", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotKSSummary", + "mapped_via_alias": false, + "matlab_method": "plotKSSummary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotResidualSummary", + "mapped_via_alias": false, + "matlab_method": "plotResidualSummary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotSummary", + "mapped_via_alias": false, + "matlab_method": "plotSummary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotlogLL", + "mapped_via_alias": false, + "matlab_method": "plotlogLL", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setCoeffRange", + "mapped_via_alias": false, + "matlab_method": "setCoeffRange", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "xticklabel_rotate", + "mapped_via_alias": false, + "matlab_method": "xticklabel_rotate", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, results: 'list[FitResult]') -> None", + "fields": [ + "results" + ], + "methods": { + "best_by_aic": "(self) -> 'FitResult'", + "best_by_bic": "(self) -> 'FitResult'", + "bin_coeffs": "(self, min_val: 'float', max_val: 'float', bin_size: 'float' = 0.1) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "box_plot": "(self, X: 'np.ndarray | None' = None, diff_index: 'int' = 1) -> 'dict[str, np.ndarray]'", + "compute_diff_mat": "(self, metric: 'str' = 'aic') -> 'np.ndarray'", + "from_structure": "(payload: 'dict[str, Any]') -> \"'FitSummary'\"", + "get_coeff_index": "(self, fit_num: 'int' = 1, sort_by_epoch: 'bool' = False) -> 'tuple[np.ndarray, np.ndarray, int]'", + "get_coeffs": "(self, fit_num: 'int' = 1) -> 'tuple[np.ndarray, list[str], np.ndarray]'", + "get_diff_aic": "(self) -> 'np.ndarray'", + "get_diff_bic": "(self) -> 'np.ndarray'", + "get_diff_log_likelihood": "(self) -> 'np.ndarray'", + "get_unique_labels": "(self) -> 'list[str]'", + "to_structure": "(self) -> 'dict[str, Any]'" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.FitResult", + "fixture_path": "tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat", + "key_methods": [ + "predict", + "aic", + "bic", + "as_cif_model", + "to_structure" + ], + "python_class": "nstat.fit.FitResult" + }, + "compat": { + "constructor_signature": "(self, coefficients: 'np.ndarray', intercept: 'float', fit_type: 'str', log_likelihood: 'float', n_samples: 'int', n_parameters: 'int', parameter_labels: 'list[str]' = , ks_stats: 'dict[str, np.ndarray | float]' = , fit_residual: 'np.ndarray | None' = None, inv_gaus_stats: 'dict[str, np.ndarray | float]' = , neuron_name: 'str' = '', plot_params: 'dict[str, Any]' = , xval_data: 'list[np.ndarray]' = , xval_time: 'list[np.ndarray]' = ) -> None", + "fields": [ + "coefficients", + "fit_residual", + "fit_type", + "intercept", + "inv_gaus_stats", + "ks_stats", + "log_likelihood", + "n_parameters", + "n_samples", + "neuron_name", + "parameter_labels", + "plot_params", + "xval_data", + "xval_time" + ], + "methods": { + "CellArrayToStructure": "(results: 'list[_FitResult]') -> 'list[dict[str, Any]]'", + "FitResult": "(structure: 'dict[str, Any]') -> '_FitResult'", + "KSPlot": "(self, fitNum: 'int' = 1) -> 'Any'", + "addParamsToFit": "(self, payload: 'dict[str, Any]') -> '_FitResult'", + "add_params_to_fit": "(self, payload: 'dict[str, Any]') -> 'None'", + "aic": "(self) -> 'float'", + "asCIFModel": "(self) -> '_CIFModel'", + "as_cif_model": "(self) -> 'CIFModel'", + "bic": "(self) -> 'float'", + "cell_array_to_structure": "(results: \"list['FitResult']\") -> 'list[dict[str, Any]]'", + "computePlotParams": "(self) -> 'dict[str, Any]'", + "computeValLambda": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "compute_plot_params": "(self) -> 'dict[str, Any]'", + "compute_val_lambda": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "evalLambda": "(self, X_or_modelIndex: 'Any', maybe_X: 'Any' = None) -> 'np.ndarray'", + "fromStructure": "(structure: 'dict[str, Any]') -> '_FitResult'", + "from_structure": "(payload: 'dict[str, Any]') -> \"'FitResult'\"", + "getAIC": "(self) -> 'float'", + "getBIC": "(self) -> 'float'", + "getCoeffIndex": "(self, label: 'str') -> 'int'", + "getCoeffs": "(self) -> 'np.ndarray'", + "getHistCoeffs": "(self, fitNum: 'int' = 1) -> 'tuple[np.ndarray, list[str], np.ndarray]'", + "getHistIndex": "(self, fitNum: 'int' = 1, sortByEpoch: 'bool' = False) -> 'tuple[np.ndarray, np.ndarray, int]'", + "getParam": "(self, key: 'str') -> 'float | np.ndarray | str | int'", + "getPlotParams": "(self) -> 'dict[str, Any]'", + "getSubsetFitResult": "(self, subfits: 'int | list[int] | np.ndarray') -> '_FitResult'", + "getUniqueLabels": "(self) -> 'list[str]'", + "get_coeff_index": "(self, label: 'str') -> 'int'", + "get_coeffs": "(self) -> 'np.ndarray'", + "get_param": "(self, key: 'str') -> 'float | np.ndarray | str | int'", + "get_plot_params": "(self) -> 'dict[str, Any]'", + "get_unique_labels": "(self) -> 'list[str]'", + "isValDataPresent": "(self) -> 'bool'", + "mapCovLabelsToUniqueLabels": "(self) -> 'list[str]'", + "map_cov_labels_to_unique_labels": "(self) -> 'list[str]'", + "mergeResults": "(self, newFitObj: 'Any') -> '_FitSummary'", + "plotCoeffs": "(self, handle: 'Any' = None, fitNum: 'int' = 1, plotProps: 'dict[str, Any] | None' = None, plotSignificance: 'bool' = True, subIndex: 'Any' = None) -> 'Any'", + "plotCoeffsWithoutHistory": "(self, fitNum: 'int' = 1, sortByEpoch: 'bool' = False, plotSignificance: 'bool' = True) -> 'Any'", + "plotHistCoeffs": "(self, fitNum: 'int' = 1, sortByEpoch: 'bool' = False, plotSignificance: 'bool' = True) -> 'Any'", + "plotInvGausTrans": "(self) -> 'Any'", + "plotResidual": "(self) -> 'Any'", + "plotResults": "(self) -> 'Any'", + "plotSeqCorr": "(self) -> 'Any'", + "plotValidation": "(self) -> 'Any'", + "predict": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "setFitResidual": "(self, fitResidual: 'np.ndarray') -> '_FitResult'", + "setInvGausStats": "(self, stats: 'dict[str, Any]') -> '_FitResult'", + "setKSStats": "(self, ksStat: 'np.ndarray | float | dict[str, Any]', pValue: 'np.ndarray | float | None' = None, withinConfInt: 'np.ndarray | float | None' = None) -> '_FitResult'", + "setNeuronName": "(self, neuronName: 'str') -> '_FitResult'", + "set_fit_residual": "(self, residual: 'np.ndarray') -> 'None'", + "set_inv_gaus_stats": "(self, payload: 'dict[str, Any]') -> 'None'", + "set_ks_stats": "(self, ks_stat: 'np.ndarray | float | dict[str, Any]', p_value: 'np.ndarray | float | None' = None, within_conf_int: 'np.ndarray | float | None' = None) -> 'None'", + "set_neuron_name": "(self, name: 'str') -> 'None'", + "toStructure": "(self) -> 'dict[str, Any]'", + "to_structure": "(self) -> 'dict[str, Any]'", + "xticklabel_rotate": "(XTick: 'np.ndarray', rot: 'float', *args: 'Any', **kwargs: 'Any') -> 'Any'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "class_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat" + }, + "mapping": { + "alias_methods": { + "asCIFModel": "as_cif_model", + "evalLambda": "predict", + "getAIC": "aic", + "getBIC": "bic" + }, + "compat_class": "nstat.compat.matlab.FitResult", + "python_class": "nstat.fit.FitResult" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "spikeObj", + "covLabels", + "numHist", + "histObjects", + "ensHistObj", + "lambda", + "b", + "dev", + "stats", + "AIC", + "BIC", + "logLL", + "configColl", + "XvalData", + "XvalTime", + "distribution" + ], + "line": 95, + "name": "FitResult", + "static": false + }, + "matlab_class": "FitResult", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/FitResult.m", + "methods": [ + { + "access": "public", + "args": [ + "spikeObj", + "covLabels", + "numHist", + "histObjects", + "ensHistObj", + "lambda", + "b", + "dev", + "stats", + "AIC", + "BIC", + "logLL", + "configColl", + "XvalData", + "XvalTime", + "distribution" + ], + "line": 95, + "name": "FitResult", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "name" + ], + "line": 190, + "name": "setNeuronName", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "newFitObj" + ], + "line": 193, + "name": "mergeResults", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "subfits" + ], + "line": 287, + "name": "getSubsetFitResult", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "neuronNum", + "lambda", + "b", + "dev", + "stats", + "AIC", + "BIC", + "logLL", + "configColl" + ], + "line": 324, + "name": "addParamsToFit", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 400, + "name": "computeValLambda", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 416, + "name": "mapCovLabelsToUniqueLabels", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 441, + "name": "getPlotParams", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 448, + "name": "plotValidation", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 460, + "name": "isValDataPresent", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "lambdaIndex", + "newData" + ], + "line": 480, + "name": "evalLambda", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum" + ], + "line": 592, + "name": "computePlotParams", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum", + "sortByEpoch" + ], + "line": 639, + "name": "getCoeffIndex", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum", + "sortByEpoch", + "plotSignificance" + ], + "line": 727, + "name": "plotCoeffsWithoutHistory", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum", + "sortByEpoch" + ], + "line": 749, + "name": "getHistIndex", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum" + ], + "line": 817, + "name": "getCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum" + ], + "line": 896, + "name": "getHistCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum", + "sortByEpoch", + "plotSignificance" + ], + "line": 1015, + "name": "plotHistCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "handle", + "fitNum", + "plotProps", + "plotSignificance", + "subIndex" + ], + "line": 1033, + "name": "plotCoeffs", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 1140, + "name": "plotResults", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "fitNum" + ], + "line": 1159, + "name": "KSPlot", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 1203, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 1252, + "name": "plotSeqCorr", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 1303, + "name": "plotInvGausTrans", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj" + ], + "line": 1357, + "name": "plotResidual", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "Z", + "U", + "xAxis", + "KSSorted", + "ks_stat" + ], + "line": 1379, + "name": "setKSStats", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "X", + "rhoSig", + "confBoundSig" + ], + "line": 1410, + "name": "setInvGausStats", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "M" + ], + "line": 1419, + "name": "setFitResidual", + "static": false + }, + { + "access": "public", + "args": [ + "fitObj", + "paramNames", + "fitNum" + ], + "line": 1425, + "name": "getParam", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 1464, + "name": "fromStructure", + "static": true + }, + { + "access": "public", + "args": [ + "fitResObjCell" + ], + "line": 1530, + "name": "CellArrayToStructure", + "static": true + }, + { + "access": "public", + "args": [ + "XTick", + "rot", + "varargin" + ], + "line": 1555, + "name": "xticklabel_rotate", + "static": true + }, + { + "access": "public", + "args": [ + "covLabels" + ], + "line": 1778, + "name": "getUniqueLabels", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 49, + "name": "numResults" + }, + { + "access": "public", + "line": 50, + "name": "lambda" + }, + { + "access": "public", + "line": 51, + "name": "numCoeffs" + }, + { + "access": "public", + "line": 52, + "name": "fitType" + }, + { + "access": "public", + "line": 54, + "name": "b" + }, + { + "access": "public", + "line": 56, + "name": "dev" + }, + { + "access": "public", + "line": 57, + "name": "AIC" + }, + { + "access": "public", + "line": 58, + "name": "BIC" + }, + { + "access": "public", + "line": 59, + "name": "logLL" + }, + { + "access": "public", + "line": 60, + "name": "stats" + }, + { + "access": "public", + "line": 61, + "name": "configs" + }, + { + "access": "public", + "line": 62, + "name": "configNames" + }, + { + "access": "public", + "line": 63, + "name": "neuronNumber" + }, + { + "access": "public", + "line": 64, + "name": "neuralSpikeTrain" + }, + { + "access": "public", + "line": 65, + "name": "covLabels" + }, + { + "access": "public", + "line": 66, + "name": "uniqueCovLabels" + }, + { + "access": "public", + "line": 67, + "name": "indicesToUniqueLabels" + }, + { + "access": "public", + "line": 68, + "name": "numHist" + }, + { + "access": "public", + "line": 69, + "name": "histObjects" + }, + { + "access": "public", + "line": 70, + "name": "ensHistObjects" + }, + { + "access": "public", + "line": 71, + "name": "flatMask" + }, + { + "access": "public", + "line": 72, + "name": "Z" + }, + { + "access": "public", + "line": 73, + "name": "U" + }, + { + "access": "public", + "line": 74, + "name": "X" + }, + { + "access": "public", + "line": 75, + "name": "Residual" + }, + { + "access": "public", + "line": 79, + "name": "invGausStats" + }, + { + "access": "public", + "line": 80, + "name": "KSStats" + }, + { + "access": "public", + "line": 81, + "name": "plotParams" + }, + { + "access": "public", + "line": 82, + "name": "XvalData" + }, + { + "access": "public", + "line": 83, + "name": "XvalTime" + }, + { + "access": "public", + "line": 84, + "name": "validation" + }, + { + "access": "public", + "line": 85, + "name": "minTime" + }, + { + "access": "public", + "line": 86, + "name": "maxTime" + }, + { + "access": "public", + "line": 89, + "name": "colors" + } + ], + "public_methods": [ + "CellArrayToStructure", + "FitResult", + "KSPlot", + "addParamsToFit", + "computePlotParams", + "computeValLambda", + "evalLambda", + "fromStructure", + "getCoeffIndex", + "getCoeffs", + "getHistCoeffs", + "getHistIndex", + "getParam", + "getPlotParams", + "getSubsetFitResult", + "getUniqueLabels", + "isValDataPresent", + "mapCovLabelsToUniqueLabels", + "mergeResults", + "plotCoeffs", + "plotCoeffsWithoutHistory", + "plotHistCoeffs", + "plotInvGausTrans", + "plotResidual", + "plotResults", + "plotSeqCorr", + "plotValidation", + "setFitResidual", + "setInvGausStats", + "setKSStats", + "setNeuronName", + "toStructure", + "xticklabel_rotate" + ], + "superclass": "handle" + }, + "matlab_class": "FitResult", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "CellArrayToStructure", + "mapped_via_alias": false, + "matlab_method": "CellArrayToStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "FitResult", + "mapped_via_alias": false, + "matlab_method": "FitResult", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "KSPlot", + "mapped_via_alias": false, + "matlab_method": "KSPlot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "addParamsToFit", + "mapped_via_alias": false, + "matlab_method": "addParamsToFit", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computePlotParams", + "mapped_via_alias": false, + "matlab_method": "computePlotParams", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeValLambda", + "mapped_via_alias": false, + "matlab_method": "computeValLambda", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "predict", + "mapped_via_alias": true, + "matlab_method": "evalLambda", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCoeffIndex", + "mapped_via_alias": false, + "matlab_method": "getCoeffIndex", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCoeffs", + "mapped_via_alias": false, + "matlab_method": "getCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getHistCoeffs", + "mapped_via_alias": false, + "matlab_method": "getHistCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getHistIndex", + "mapped_via_alias": false, + "matlab_method": "getHistIndex", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getParam", + "mapped_via_alias": false, + "matlab_method": "getParam", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getPlotParams", + "mapped_via_alias": false, + "matlab_method": "getPlotParams", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSubsetFitResult", + "mapped_via_alias": false, + "matlab_method": "getSubsetFitResult", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getUniqueLabels", + "mapped_via_alias": false, + "matlab_method": "getUniqueLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isValDataPresent", + "mapped_via_alias": false, + "matlab_method": "isValDataPresent", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mapCovLabelsToUniqueLabels", + "mapped_via_alias": false, + "matlab_method": "mapCovLabelsToUniqueLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mergeResults", + "mapped_via_alias": false, + "matlab_method": "mergeResults", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotCoeffs", + "mapped_via_alias": false, + "matlab_method": "plotCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotCoeffsWithoutHistory", + "mapped_via_alias": false, + "matlab_method": "plotCoeffsWithoutHistory", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotHistCoeffs", + "mapped_via_alias": false, + "matlab_method": "plotHistCoeffs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotInvGausTrans", + "mapped_via_alias": false, + "matlab_method": "plotInvGausTrans", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotResidual", + "mapped_via_alias": false, + "matlab_method": "plotResidual", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotResults", + "mapped_via_alias": false, + "matlab_method": "plotResults", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotSeqCorr", + "mapped_via_alias": false, + "matlab_method": "plotSeqCorr", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotValidation", + "mapped_via_alias": false, + "matlab_method": "plotValidation", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setFitResidual", + "mapped_via_alias": false, + "matlab_method": "setFitResidual", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setInvGausStats", + "mapped_via_alias": false, + "matlab_method": "setInvGausStats", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setKSStats", + "mapped_via_alias": false, + "matlab_method": "setKSStats", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setNeuronName", + "mapped_via_alias": false, + "matlab_method": "setNeuronName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "xticklabel_rotate", + "mapped_via_alias": false, + "matlab_method": "xticklabel_rotate", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, coefficients: 'np.ndarray', intercept: 'float', fit_type: 'str', log_likelihood: 'float', n_samples: 'int', n_parameters: 'int', parameter_labels: 'list[str]' = , ks_stats: 'dict[str, np.ndarray | float]' = , fit_residual: 'np.ndarray | None' = None, inv_gaus_stats: 'dict[str, np.ndarray | float]' = , neuron_name: 'str' = '', plot_params: 'dict[str, Any]' = , xval_data: 'list[np.ndarray]' = , xval_time: 'list[np.ndarray]' = ) -> None", + "fields": [ + "coefficients", + "fit_residual", + "fit_type", + "intercept", + "inv_gaus_stats", + "ks_stats", + "log_likelihood", + "n_parameters", + "n_samples", + "neuron_name", + "parameter_labels", + "plot_params", + "xval_data", + "xval_time" + ], + "methods": { + "add_params_to_fit": "(self, payload: 'dict[str, Any]') -> 'None'", + "aic": "(self) -> 'float'", + "as_cif_model": "(self) -> 'CIFModel'", + "bic": "(self) -> 'float'", + "cell_array_to_structure": "(results: \"list['FitResult']\") -> 'list[dict[str, Any]]'", + "compute_plot_params": "(self) -> 'dict[str, Any]'", + "compute_val_lambda": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "from_structure": "(payload: 'dict[str, Any]') -> \"'FitResult'\"", + "get_coeff_index": "(self, label: 'str') -> 'int'", + "get_coeffs": "(self) -> 'np.ndarray'", + "get_param": "(self, key: 'str') -> 'float | np.ndarray | str | int'", + "get_plot_params": "(self) -> 'dict[str, Any]'", + "get_unique_labels": "(self) -> 'list[str]'", + "map_cov_labels_to_unique_labels": "(self) -> 'list[str]'", + "predict": "(self, X: 'np.ndarray') -> 'np.ndarray'", + "set_fit_residual": "(self, residual: 'np.ndarray') -> 'None'", + "set_inv_gaus_stats": "(self, payload: 'dict[str, Any]') -> 'None'", + "set_ks_stats": "(self, ks_stat: 'np.ndarray | float | dict[str, Any]', p_value: 'np.ndarray | float | None' = None, within_conf_int: 'np.ndarray | float | None' = None) -> 'None'", + "set_neuron_name": "(self, name: 'str') -> 'None'", + "to_structure": "(self) -> 'dict[str, Any]'" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.History", + "fixture_path": "tests/parity/fixtures/matlab_gold/HistoryExamples_gold.mat", + "key_methods": [ + "design_matrix", + "to_filter", + "set_window", + "to_structure", + "from_structure" + ], + "python_class": "nstat.history.HistoryBasis" + }, + "compat": { + "constructor_signature": "(self, bin_edges_s: 'np.ndarray') -> None", + "fields": [ + "bin_edges_s" + ], + "methods": { + "History": "(*args: 'Any', **kwargs: 'Any') -> '_HistoryBasis'", + "computeHistory": "(self, spikeTimes_s: 'np.ndarray', timeGrid_s: 'np.ndarray') -> 'np.ndarray'", + "computeNSTHistoryWindow": "(self, spikeTrain: 'Any', timeGrid_s: 'np.ndarray') -> 'np.ndarray'", + "design_matrix": "(self, spike_times_s: 'np.ndarray', time_grid_s: 'np.ndarray') -> 'np.ndarray'", + "fromStructure": "(payload: 'dict[str, Any]') -> '_HistoryBasis'", + "getDesignMatrix": "(self, spike_times_s: 'np.ndarray', time_grid_s: 'np.ndarray') -> 'np.ndarray'", + "getNumBins": "(self) -> 'int'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "setWindow": "(self, *args: 'Any') -> '_HistoryBasis'", + "toFilter": "(self) -> 'np.ndarray'", + "toStructure": "(self) -> 'dict[str, Any]'" + }, + "properties": [ + "n_bins" + ] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/HistoryExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "getDesignMatrix": "design_matrix", + "getNumBins": "n_bins" + }, + "compat_class": "nstat.compat.matlab.History", + "python_class": "nstat.history.HistoryBasis" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "windowTimes", + "minTime", + "maxTime" + ], + "line": 59, + "name": "History", + "static": false + }, + "matlab_class": "History", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/History.m", + "methods": [ + { + "access": "public", + "args": [ + "windowTimes", + "minTime", + "maxTime" + ], + "line": 59, + "name": "History", + "static": false + }, + { + "access": "public", + "args": [ + "HistObj", + "nst", + "historyNum", + "tn" + ], + "line": 76, + "name": "computeHistory", + "static": false + }, + { + "access": "public", + "args": [ + "HistObj", + "windowTimes" + ], + "line": 137, + "name": "setWindow", + "static": false + }, + { + "access": "public", + "args": [ + "HistObj" + ], + "line": 144, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "HistObj", + "delta" + ], + "line": 164, + "name": "toFilter", + "static": false + }, + { + "access": "public", + "args": [ + "HistObj" + ], + "line": 193, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 203, + "name": "fromStructure", + "static": true + }, + { + "access": "private", + "args": [ + "HistObj", + "nst", + "historyNum", + "tn" + ], + "line": 216, + "name": "computeNSTHistoryWindow", + "static": false + } + ], + "private_methods": [ + "computeNSTHistoryWindow" + ], + "properties": [ + { + "access": "public", + "line": 53, + "name": "windowTimes" + }, + { + "access": "public", + "line": 54, + "name": "minTime" + }, + { + "access": "public", + "line": 55, + "name": "maxTime" + } + ], + "public_methods": [ + "History", + "computeHistory", + "fromStructure", + "plot", + "setWindow", + "toFilter", + "toStructure" + ], + "superclass": "handle" + }, + "matlab_class": "History", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "History", + "mapped_via_alias": false, + "matlab_method": "History", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeHistory", + "mapped_via_alias": false, + "matlab_method": "computeHistory", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setWindow", + "mapped_via_alias": false, + "matlab_method": "setWindow", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toFilter", + "mapped_via_alias": false, + "matlab_method": "toFilter", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, bin_edges_s: 'np.ndarray') -> None", + "fields": [ + "bin_edges_s" + ], + "methods": { + "design_matrix": "(self, spike_times_s: 'np.ndarray', time_grid_s: 'np.ndarray') -> 'np.ndarray'" + }, + "properties": [ + "n_bins" + ] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.SignalObj", + "fixture_path": "tests/parity/fixtures/matlab_gold/SignalObjExamples_gold.mat", + "key_methods": [ + "copy", + "resample", + "periodogram", + "get_sub_signal", + "merge" + ], + "python_class": "nstat.signal.Signal" + }, + "compat": { + "constructor_signature": "(self, time: 'ArrayLike', data: 'ArrayLike', name: 'str' = 'signal', units: 'str | None' = None, x_label: 'str | None' = None, y_label: 'str | None' = None, x_units: 'str | None' = None, y_units: 'str | None' = None, plot_props: 'dict[str, Any]' = ) -> None", + "fields": [ + "data", + "name", + "plot_props", + "time", + "units", + "x_label", + "x_units", + "y_label", + "y_units" + ], + "methods": { + "MTMspectrum": "(self) -> 'tuple[np.ndarray, np.ndarray]'", + "abs": "(self) -> \"'SignalObj'\"", + "alignTime": "(self, newZero: 'float' = 0.0) -> \"'SignalObj'\"", + "alignToMax": "(self, targetTime: 'float' = 0.0) -> \"'SignalObj'\"", + "align_time": "(self, new_zero_time: 'float' = 0.0) -> \"'Signal'\"", + "areDataLabelsEmpty": "(self) -> 'bool'", + "autocorrelation": "(self, maxLag: 'int | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "cell2str": "(cells: 'list[Any]', delimiter: 'str' = ',') -> 'str'", + "clearPlotProps": "(self) -> \"'SignalObj'\"", + "clear_plot_props": "(self) -> \"'Signal'\"", + "convertNamesToIndices": "(self, labels: 'list[str]') -> 'list[int]'", + "convertSigStructureToStructure": "(payload: 'dict[str, Any]') -> 'dict[str, Any]'", + "convertSimpleStructureToSigStructure": "(payload: 'dict[str, Any]') -> 'dict[str, Any]'", + "copy": "(self) -> \"'Signal'\"", + "copySignal": "(self) -> \"'SignalObj'\"", + "copy_signal": "(self) -> \"'Signal'\"", + "crosscorrelation": "(self, other: \"'SignalObj'\", maxLag: 'int | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "ctranspose": "(self) -> \"'SignalObj'\"", + "dataToMatrix": "(self) -> 'np.ndarray'", + "dataToStructure": "(self) -> 'dict[str, Any]'", + "data_to_matrix": "(self) -> 'np.ndarray'", + "derivative": "(self) -> \"'SignalObj'\"", + "derivativeAt": "(self, queryTime: 'float') -> 'np.ndarray'", + "filter": "(self, b: 'np.ndarray', a: 'np.ndarray') -> \"'SignalObj'\"", + "filtfilt": "(self, b: 'np.ndarray', a: 'np.ndarray') -> \"'SignalObj'\"", + "findGlobalPeak": "(self) -> 'tuple[float, float, int]'", + "findIndFromDataMask": "(self) -> 'list[int]'", + "findMaxima": "(self) -> 'tuple[np.ndarray, np.ndarray]'", + "findMinima": "(self) -> 'tuple[np.ndarray, np.ndarray]'", + "findNearestTimeIndex": "(self, queryTime: 'float') -> 'int'", + "findNearestTimeIndices": "(self, queryTimes: 'np.ndarray') -> 'np.ndarray'", + "findPeaks": "(self) -> 'tuple[np.ndarray, np.ndarray]'", + "getAvailableColor": "(index: 'int' = 0) -> 'str'", + "getData": "(self) -> 'np.ndarray'", + "getDuration": "(self) -> 'float'", + "getIndexFromLabel": "(self, label: 'str') -> 'int'", + "getIndicesFromLabels": "(self, labels: 'list[str]') -> 'list[int]'", + "getNumSamples": "(self) -> 'int'", + "getNumSignals": "(self) -> 'int'", + "getOrigDataSig": "(self) -> \"'SignalObj'\"", + "getOriginalData": "(self) -> 'np.ndarray'", + "getPlotProps": "(self) -> 'dict[str, Any]'", + "getSampleRate": "(self) -> 'float'", + "getSigInTimeWindow": "(self, t0: 'float', tf: 'float') -> \"'SignalObj'\"", + "getSubSignal": "(self, selector: 'int | list[int] | np.ndarray') -> \"'SignalObj'\"", + "getSubSignalFromInd": "(self, selector: 'int | list[int] | np.ndarray') -> \"'SignalObj'\"", + "getSubSignalFromNames": "(self, labels: 'list[str]') -> \"'SignalObj'\"", + "getSubSignalsWithinNStd": "(self, nStd: 'float' = 1.0) -> \"'SignalObj'\"", + "getTime": "(self) -> 'np.ndarray'", + "getValueAt": "(self, queryTime: 'float') -> 'np.ndarray'", + "get_sub_signal": "(self, selector: 'int | list[int] | np.ndarray') -> \"'Signal'\"", + "integral": "(self) -> 'np.ndarray'", + "isLabelPresent": "(self, label: 'str') -> 'bool'", + "isMaskSet": "(self) -> 'bool'", + "ldivide": "(self, other: \"float | np.ndarray | 'SignalObj'\") -> \"'SignalObj'\"", + "log": "(self) -> \"'SignalObj'\"", + "makeCompatible": "(self, other: '_Signal') -> \"tuple['SignalObj', 'SignalObj']\"", + "max": "(self) -> 'float'", + "mean": "(self) -> 'float'", + "median": "(self) -> 'float'", + "merge": "(self, other: '_Signal') -> \"'SignalObj'\"", + "min": "(self) -> 'float'", + "minus": "(self, other: \"float | np.ndarray | 'SignalObj'\") -> \"'SignalObj'\"", + "mode": "(self) -> 'float'", + "mtimes": "(self, other: \"float | np.ndarray | 'SignalObj'\") -> \"'SignalObj'\"", + "normWindowedSignal": "(self, windowSamples: 'int' = 11) -> \"'SignalObj'\"", + "periodogram": "(self) -> 'tuple[np.ndarray, np.ndarray]'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "plotAllVariability": "(self) -> 'Any'", + "plotPropsSet": "(self) -> 'bool'", + "plotVariability": "(self) -> 'Any'", + "plus": "(self, other: \"float | np.ndarray | 'SignalObj'\") -> \"'SignalObj'\"", + "power": "(self, exponent: 'float') -> \"'SignalObj'\"", + "rdivide": "(self, other: \"float | np.ndarray | 'SignalObj'\") -> \"'SignalObj'\"", + "resample": "(self, sampleRate: 'float') -> \"'SignalObj'\"", + "resampleMe": "(self, sampleRate: 'float') -> \"'SignalObj'\"", + "resetMask": "(self) -> \"'SignalObj'\"", + "restoreToOriginal": "(self) -> \"'SignalObj'\"", + "restrict_to_time_window": "(self, min_time: 'float', max_time: 'float') -> \"'Signal'\"", + "setDataLabels": "(self, labels: 'list[str]') -> \"'SignalObj'\"", + "setDataMask": "(self, mask: 'list[int] | np.ndarray') -> \"'SignalObj'\"", + "setMask": "(self, selector: 'list[int] | list[str] | np.ndarray') -> \"'SignalObj'\"", + "setMaskByInd": "(self, mask: 'list[int] | np.ndarray') -> \"'SignalObj'\"", + "setMaskByLabels": "(self, labels: 'list[str]') -> \"'SignalObj'\"", + "setMaxTime": "(self, maxTime: 'float') -> \"'SignalObj'\"", + "setMinTime": "(self, minTime: 'float') -> \"'SignalObj'\"", + "setName": "(self, name: 'str') -> \"'SignalObj'\"", + "setPlotProps": "(self, props: 'dict[str, Any]') -> \"'SignalObj'\"", + "setSampleRate": "(self, sampleRate: 'float') -> \"'SignalObj'\"", + "setUnits": "(self, units: 'str') -> \"'SignalObj'\"", + "setXUnits": "(self, units: 'str') -> \"'SignalObj'\"", + "setXlabel": "(self, label: 'str') -> \"'SignalObj'\"", + "setYLabel": "(self, label: 'str') -> \"'SignalObj'\"", + "setYUnits": "(self, units: 'str') -> \"'SignalObj'\"", + "set_max_time": "(self, max_time: 'float') -> \"'Signal'\"", + "set_min_time": "(self, min_time: 'float') -> \"'Signal'\"", + "set_name": "(self, name: 'str') -> \"'Signal'\"", + "set_plot_props": "(self, props: 'dict[str, Any]') -> \"'Signal'\"", + "set_units": "(self, units: 'str') -> \"'Signal'\"", + "set_x_units": "(self, units: 'str') -> \"'Signal'\"", + "set_xlabel": "(self, label: 'str') -> \"'Signal'\"", + "set_y_units": "(self, units: 'str') -> \"'Signal'\"", + "set_ylabel": "(self, label: 'str') -> \"'Signal'\"", + "setupPlots": "(self) -> \"'SignalObj'\"", + "shift": "(self, offset_s: 'float') -> \"'SignalObj'\"", + "shiftMe": "(self, offset_s: 'float') -> \"'SignalObj'\"", + "shiftTime": "(self, offset_s: 'float') -> \"'SignalObj'\"", + "shift_time": "(self, offset_s: 'float') -> \"'Signal'\"", + "signalFromStruct": "(payload: 'dict[str, Any]') -> \"'SignalObj'\"", + "spectrogram": "(self) -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "sqrt": "(self) -> \"'SignalObj'\"", + "std": "(self) -> 'float'", + "times": "(self, other: \"float | np.ndarray | 'SignalObj'\") -> \"'SignalObj'\"", + "transpose": "(self) -> \"'SignalObj'\"", + "uminus": "(self) -> \"'SignalObj'\"", + "uplus": "(self) -> \"'SignalObj'\"", + "windowedSignal": "(self, windowSamples: 'int' = 11) -> \"'SignalObj'\"", + "xcorr": "(self, other: \"'SignalObj | None'\" = None, maxLag: 'int | None' = None) -> 'tuple[np.ndarray, np.ndarray]'", + "xcov": "(self, other: \"'SignalObj | None'\" = None, maxLag: 'int | None' = None) -> 'tuple[np.ndarray, np.ndarray]'" + }, + "properties": [ + "duration_s", + "n_channels", + "n_samples", + "sample_rate_hz" + ] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/SignalObjExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "SignalObj": "copy", + "copy": "copy", + "getData": "data", + "getDuration": "duration_s", + "getName": "name", + "getNumSamples": "n_samples", + "getNumSignals": "n_channels", + "getSampleRate": "sample_rate_hz", + "getTime": "time" + }, + "compat_class": "nstat.compat.matlab.SignalObj", + "python_class": "nstat.signal.Signal" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "time", + "data", + "name", + "xlabelval", + "xunits", + "yunits", + "dataLabels", + "plotProps" + ], + "line": 121, + "name": "SignalObj", + "static": false + }, + "matlab_class": "SignalObj", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/SignalObj.m", + "methods": [ + { + "access": "public", + "args": [ + "time", + "data", + "name", + "xlabelval", + "xunits", + "yunits", + "dataLabels", + "plotProps" + ], + "line": 121, + "name": "SignalObj", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "name" + ], + "line": 196, + "name": "setName", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "name" + ], + "line": 205, + "name": "setXlabel", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "name" + ], + "line": 210, + "name": "setYLabel", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "xUnits", + "yUnits" + ], + "line": 216, + "name": "setUnits", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "units" + ], + "line": 234, + "name": "setXUnits", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "units" + ], + "line": 241, + "name": "setYUnits", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "sampleRate" + ], + "line": 248, + "name": "setSampleRate", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "dataLabels" + ], + "line": 262, + "name": "setDataLabels", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "minTime", + "holdVals" + ], + "line": 301, + "name": "setMinTime", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "maxTime", + "holdVals" + ], + "line": 341, + "name": "setMaxTime", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "plotProps", + "index" + ], + "line": 383, + "name": "setPlotProps", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "mask" + ], + "line": 435, + "name": "setMask", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 462, + "name": "getTime", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 467, + "name": "getData", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 475, + "name": "getOriginalData", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 484, + "name": "getOrigDataSig", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "x" + ], + "line": 499, + "name": "getValueAt", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "index" + ], + "line": 522, + "name": "getPlotProps", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "label" + ], + "line": 532, + "name": "getIndicesFromLabels", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2" + ], + "line": 573, + "name": "plus", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2" + ], + "line": 642, + "name": "minus", + "static": false + }, + { + "access": "public", + "args": [ + "s1" + ], + "line": 647, + "name": "uplus", + "static": false + }, + { + "access": "public", + "args": [ + "s1" + ], + "line": 652, + "name": "uminus", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "exponent" + ], + "line": 662, + "name": "power", + "static": false + }, + { + "access": "public", + "args": [ + "s1" + ], + "line": 671, + "name": "sqrt", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2" + ], + "line": 676, + "name": "times", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2" + ], + "line": 709, + "name": "mtimes", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2" + ], + "line": 728, + "name": "rdivide", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2" + ], + "line": 748, + "name": "ldivide", + "static": false + }, + { + "access": "public", + "args": [ + "s1" + ], + "line": 768, + "name": "ctranspose", + "static": false + }, + { + "access": "public", + "args": [ + "s1" + ], + "line": 774, + "name": "transpose", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 780, + "name": "derivative", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "x0" + ], + "line": 807, + "name": "derivativeAt", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "t0", + "tf" + ], + "line": 814, + "name": "integral", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "B", + "A" + ], + "line": 849, + "name": "filter", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "B", + "A" + ], + "line": 857, + "name": "filtfilt", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2", + "holdVals" + ], + "line": 865, + "name": "makeCompatible", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 907, + "name": "abs", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 926, + "name": "log", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "varargin" + ], + "line": 946, + "name": "median", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "varargin" + ], + "line": 984, + "name": "mode", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "varargin" + ], + "line": 1019, + "name": "mean", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "varargin" + ], + "line": 1052, + "name": "std", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "varargin" + ], + "line": 1087, + "name": "max", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "varargin" + ], + "line": 1095, + "name": "min", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1103, + "name": "autocorrelation", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "s2" + ], + "line": 1120, + "name": "crosscorrelation", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1130, + "name": "periodogram", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "NW", + "NFFT", + "Pval" + ], + "line": 1164, + "name": "MTMspectrum", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "freqVec", + "h" + ], + "line": 1205, + "name": "spectrogram", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2", + "varargin" + ], + "line": 1245, + "name": "xcorr", + "static": false + }, + { + "access": "public", + "args": [ + "s1", + "s2", + "varargin" + ], + "line": 1282, + "name": "xcov", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "varargin" + ], + "line": 1327, + "name": "merge", + "static": false + }, + { + "access": "public", + "args": [ + "sigIn" + ], + "line": 1366, + "name": "copySignal", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "newSampleRate" + ], + "line": 1386, + "name": "resample", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "newSampleRate" + ], + "line": 1398, + "name": "resampleMe", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "rMask" + ], + "line": 1423, + "name": "restoreToOriginal", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1444, + "name": "resetMask", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1450, + "name": "findIndFromDataMask", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "times" + ], + "line": 1458, + "name": "findNearestTimeIndices", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "time" + ], + "line": 1465, + "name": "findNearestTimeIndex", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "deltaT", + "updateLabels" + ], + "line": 1487, + "name": "shift", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "deltaT", + "updateLabels" + ], + "line": 1515, + "name": "shiftMe", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "timeMarker", + "newTime" + ], + "line": 1526, + "name": "alignTime", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1532, + "name": "plotPropsSet", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1544, + "name": "areDataLabelsEmpty", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "label" + ], + "line": 1555, + "name": "isLabelPresent", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1568, + "name": "isMaskSet", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "selectorArray" + ], + "line": 1573, + "name": "convertNamesToIndices", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1604, + "name": "alignToMax", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "type" + ], + "line": 1618, + "name": "findGlobalPeak", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "type", + "minDistance" + ], + "line": 1630, + "name": "findPeaks", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1654, + "name": "findMaxima", + "static": false + }, + { + "access": "public", + "args": [ + "sObj" + ], + "line": 1658, + "name": "findMinima", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "index" + ], + "line": 1662, + "name": "clearPlotProps", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "selectorArray" + ], + "line": 1705, + "name": "dataToStructure", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "selectorArray" + ], + "line": 1745, + "name": "dataToMatrix", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "identifier" + ], + "line": 1766, + "name": "getSubSignal", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "windowTimes", + "numPoints", + "lbound", + "ubound" + ], + "line": 1787, + "name": "normWindowedSignal", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "windowTimes" + ], + "line": 1847, + "name": "windowedSignal", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "wMin", + "wMax", + "holdVals" + ], + "line": 1861, + "name": "getSigInTimeWindow", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "nStd" + ], + "line": 1932, + "name": "getSubSignalsWithinNStd", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "selectorArray", + "plotPropsIn", + "handle" + ], + "line": 1948, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "handle", + "sArray" + ], + "line": 2067, + "name": "setupPlots", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "selectorArray" + ], + "line": 2133, + "name": "plotVariability", + "static": false + }, + { + "access": "public", + "args": [ + "sObj", + "faceColor", + "linewidth", + "ciUpper", + "ciLower" + ], + "line": 2168, + "name": "plotAllVariability", + "static": false + }, + { + "access": "private", + "args": [ + "sObj", + "label" + ], + "line": 2248, + "name": "getIndexFromLabel", + "static": false + }, + { + "access": "private", + "args": [ + "sObj", + "dataMask" + ], + "line": 2261, + "name": "setDataMask", + "static": false + }, + { + "access": "private", + "args": [ + "sObj", + "index" + ], + "line": 2273, + "name": "setMaskByInd", + "static": false + }, + { + "access": "private", + "args": [ + "sObj", + "labels" + ], + "line": 2287, + "name": "setMaskByLabels", + "static": false + }, + { + "access": "private", + "args": [ + "sObj", + "selectorArray" + ], + "line": 2298, + "name": "getSubSignalFromInd", + "static": false + }, + { + "access": "private", + "args": [ + "sObj", + "labels" + ], + "line": 2343, + "name": "getSubSignalFromNames", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 2360, + "name": "signalFromStruct", + "static": true + }, + { + "access": "public", + "args": [ + "sigStructure" + ], + "line": 2371, + "name": "convertSigStructureToStructure", + "static": true + }, + { + "access": "public", + "args": [ + "simpleStructure" + ], + "line": 2381, + "name": "convertSimpleStructureToSigStructure", + "static": true + }, + { + "access": "public", + "args": [ + "input" + ], + "line": 2398, + "name": "cell2str", + "static": true + }, + { + "access": "public", + "args": [ + "index" + ], + "line": 2409, + "name": "getAvailableColor", + "static": true + } + ], + "private_methods": [ + "getIndexFromLabel", + "getSubSignalFromInd", + "getSubSignalFromNames", + "setDataMask", + "setMaskByInd", + "setMaskByLabels" + ], + "properties": [ + { + "access": "private", + "line": 97, + "name": "name" + }, + { + "access": "private", + "line": 98, + "name": "time" + }, + { + "access": "private", + "line": 99, + "name": "data" + }, + { + "access": "private", + "line": 100, + "name": "dimension" + }, + { + "access": "private", + "line": 101, + "name": "minTime" + }, + { + "access": "private", + "line": 102, + "name": "maxTime" + }, + { + "access": "private", + "line": 103, + "name": "xlabelval" + }, + { + "access": "private", + "line": 104, + "name": "xunits" + }, + { + "access": "private", + "line": 105, + "name": "yunits" + }, + { + "access": "private", + "line": 106, + "name": "dataLabels" + }, + { + "access": "private", + "line": 107, + "name": "dataMask" + }, + { + "access": "private", + "line": 108, + "name": "sampleRate" + }, + { + "access": "private", + "line": 109, + "name": "plotProps" + }, + { + "access": "public", + "line": 112, + "name": "origSampleRate" + }, + { + "access": "public", + "line": 113, + "name": "originalTime" + }, + { + "access": "public", + "line": 114, + "name": "originalData" + } + ], + "public_methods": [ + "MTMspectrum", + "SignalObj", + "abs", + "alignTime", + "alignToMax", + "areDataLabelsEmpty", + "autocorrelation", + "cell2str", + "clearPlotProps", + "convertNamesToIndices", + "convertSigStructureToStructure", + "convertSimpleStructureToSigStructure", + "copySignal", + "crosscorrelation", + "ctranspose", + "dataToMatrix", + "dataToStructure", + "derivative", + "derivativeAt", + "filter", + "filtfilt", + "findGlobalPeak", + "findIndFromDataMask", + "findMaxima", + "findMinima", + "findNearestTimeIndex", + "findNearestTimeIndices", + "findPeaks", + "getAvailableColor", + "getData", + "getIndicesFromLabels", + "getOrigDataSig", + "getOriginalData", + "getPlotProps", + "getSigInTimeWindow", + "getSubSignal", + "getSubSignalsWithinNStd", + "getTime", + "getValueAt", + "integral", + "isLabelPresent", + "isMaskSet", + "ldivide", + "log", + "makeCompatible", + "max", + "mean", + "median", + "merge", + "min", + "minus", + "mode", + "mtimes", + "normWindowedSignal", + "periodogram", + "plot", + "plotAllVariability", + "plotPropsSet", + "plotVariability", + "plus", + "power", + "rdivide", + "resample", + "resampleMe", + "resetMask", + "restoreToOriginal", + "setDataLabels", + "setMask", + "setMaxTime", + "setMinTime", + "setName", + "setPlotProps", + "setSampleRate", + "setUnits", + "setXUnits", + "setXlabel", + "setYLabel", + "setYUnits", + "setupPlots", + "shift", + "shiftMe", + "signalFromStruct", + "spectrogram", + "sqrt", + "std", + "times", + "transpose", + "uminus", + "uplus", + "windowedSignal", + "xcorr", + "xcov" + ], + "superclass": "handle" + }, + "matlab_class": "SignalObj", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "MTMspectrum", + "mapped_via_alias": false, + "matlab_method": "MTMspectrum", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "copy", + "mapped_via_alias": true, + "matlab_method": "SignalObj", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "abs", + "mapped_via_alias": false, + "matlab_method": "abs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "alignTime", + "mapped_via_alias": false, + "matlab_method": "alignTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "alignToMax", + "mapped_via_alias": false, + "matlab_method": "alignToMax", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "areDataLabelsEmpty", + "mapped_via_alias": false, + "matlab_method": "areDataLabelsEmpty", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "autocorrelation", + "mapped_via_alias": false, + "matlab_method": "autocorrelation", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "cell2str", + "mapped_via_alias": false, + "matlab_method": "cell2str", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "clearPlotProps", + "mapped_via_alias": false, + "matlab_method": "clearPlotProps", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "convertNamesToIndices", + "mapped_via_alias": false, + "matlab_method": "convertNamesToIndices", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "convertSigStructureToStructure", + "mapped_via_alias": false, + "matlab_method": "convertSigStructureToStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "convertSimpleStructureToSigStructure", + "mapped_via_alias": false, + "matlab_method": "convertSimpleStructureToSigStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "copySignal", + "mapped_via_alias": false, + "matlab_method": "copySignal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "crosscorrelation", + "mapped_via_alias": false, + "matlab_method": "crosscorrelation", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ctranspose", + "mapped_via_alias": false, + "matlab_method": "ctranspose", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToMatrix", + "mapped_via_alias": false, + "matlab_method": "dataToMatrix", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToStructure", + "mapped_via_alias": false, + "matlab_method": "dataToStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "derivative", + "mapped_via_alias": false, + "matlab_method": "derivative", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "derivativeAt", + "mapped_via_alias": false, + "matlab_method": "derivativeAt", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "filter", + "mapped_via_alias": false, + "matlab_method": "filter", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "filtfilt", + "mapped_via_alias": false, + "matlab_method": "filtfilt", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findGlobalPeak", + "mapped_via_alias": false, + "matlab_method": "findGlobalPeak", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findIndFromDataMask", + "mapped_via_alias": false, + "matlab_method": "findIndFromDataMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findMaxima", + "mapped_via_alias": false, + "matlab_method": "findMaxima", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findMinima", + "mapped_via_alias": false, + "matlab_method": "findMinima", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findNearestTimeIndex", + "mapped_via_alias": false, + "matlab_method": "findNearestTimeIndex", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findNearestTimeIndices", + "mapped_via_alias": false, + "matlab_method": "findNearestTimeIndices", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findPeaks", + "mapped_via_alias": false, + "matlab_method": "findPeaks", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getAvailableColor", + "mapped_via_alias": false, + "matlab_method": "getAvailableColor", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "data", + "mapped_via_alias": true, + "matlab_method": "getData", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getIndicesFromLabels", + "mapped_via_alias": false, + "matlab_method": "getIndicesFromLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getOrigDataSig", + "mapped_via_alias": false, + "matlab_method": "getOrigDataSig", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getOriginalData", + "mapped_via_alias": false, + "matlab_method": "getOriginalData", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getPlotProps", + "mapped_via_alias": false, + "matlab_method": "getPlotProps", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSigInTimeWindow", + "mapped_via_alias": false, + "matlab_method": "getSigInTimeWindow", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSubSignal", + "mapped_via_alias": false, + "matlab_method": "getSubSignal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSubSignalsWithinNStd", + "mapped_via_alias": false, + "matlab_method": "getSubSignalsWithinNStd", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "time", + "mapped_via_alias": true, + "matlab_method": "getTime", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getValueAt", + "mapped_via_alias": false, + "matlab_method": "getValueAt", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "integral", + "mapped_via_alias": false, + "matlab_method": "integral", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isLabelPresent", + "mapped_via_alias": false, + "matlab_method": "isLabelPresent", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isMaskSet", + "mapped_via_alias": false, + "matlab_method": "isMaskSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ldivide", + "mapped_via_alias": false, + "matlab_method": "ldivide", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "log", + "mapped_via_alias": false, + "matlab_method": "log", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "makeCompatible", + "mapped_via_alias": false, + "matlab_method": "makeCompatible", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "max", + "mapped_via_alias": false, + "matlab_method": "max", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mean", + "mapped_via_alias": false, + "matlab_method": "mean", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "median", + "mapped_via_alias": false, + "matlab_method": "median", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "merge", + "mapped_via_alias": false, + "matlab_method": "merge", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "min", + "mapped_via_alias": false, + "matlab_method": "min", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "minus", + "mapped_via_alias": false, + "matlab_method": "minus", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mode", + "mapped_via_alias": false, + "matlab_method": "mode", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "mtimes", + "mapped_via_alias": false, + "matlab_method": "mtimes", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "normWindowedSignal", + "mapped_via_alias": false, + "matlab_method": "normWindowedSignal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "periodogram", + "mapped_via_alias": false, + "matlab_method": "periodogram", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotAllVariability", + "mapped_via_alias": false, + "matlab_method": "plotAllVariability", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotPropsSet", + "mapped_via_alias": false, + "matlab_method": "plotPropsSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotVariability", + "mapped_via_alias": false, + "matlab_method": "plotVariability", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plus", + "mapped_via_alias": false, + "matlab_method": "plus", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "power", + "mapped_via_alias": false, + "matlab_method": "power", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "rdivide", + "mapped_via_alias": false, + "matlab_method": "rdivide", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "resample", + "mapped_via_alias": false, + "matlab_method": "resample", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resampleMe", + "mapped_via_alias": false, + "matlab_method": "resampleMe", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetMask", + "mapped_via_alias": false, + "matlab_method": "resetMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "restoreToOriginal", + "mapped_via_alias": false, + "matlab_method": "restoreToOriginal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setDataLabels", + "mapped_via_alias": false, + "matlab_method": "setDataLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMask", + "mapped_via_alias": false, + "matlab_method": "setMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMaxTime", + "mapped_via_alias": false, + "matlab_method": "setMaxTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMinTime", + "mapped_via_alias": false, + "matlab_method": "setMinTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setName", + "mapped_via_alias": false, + "matlab_method": "setName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setPlotProps", + "mapped_via_alias": false, + "matlab_method": "setPlotProps", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setSampleRate", + "mapped_via_alias": false, + "matlab_method": "setSampleRate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setUnits", + "mapped_via_alias": false, + "matlab_method": "setUnits", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setXUnits", + "mapped_via_alias": false, + "matlab_method": "setXUnits", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setXlabel", + "mapped_via_alias": false, + "matlab_method": "setXlabel", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setYLabel", + "mapped_via_alias": false, + "matlab_method": "setYLabel", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setYUnits", + "mapped_via_alias": false, + "matlab_method": "setYUnits", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setupPlots", + "mapped_via_alias": false, + "matlab_method": "setupPlots", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "shift", + "mapped_via_alias": false, + "matlab_method": "shift", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "shiftMe", + "mapped_via_alias": false, + "matlab_method": "shiftMe", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "signalFromStruct", + "mapped_via_alias": false, + "matlab_method": "signalFromStruct", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "spectrogram", + "mapped_via_alias": false, + "matlab_method": "spectrogram", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "sqrt", + "mapped_via_alias": false, + "matlab_method": "sqrt", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "std", + "mapped_via_alias": false, + "matlab_method": "std", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "times", + "mapped_via_alias": false, + "matlab_method": "times", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "transpose", + "mapped_via_alias": false, + "matlab_method": "transpose", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "uminus", + "mapped_via_alias": false, + "matlab_method": "uminus", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "uplus", + "mapped_via_alias": false, + "matlab_method": "uplus", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "windowedSignal", + "mapped_via_alias": false, + "matlab_method": "windowedSignal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "xcorr", + "mapped_via_alias": false, + "matlab_method": "xcorr", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "xcov", + "mapped_via_alias": false, + "matlab_method": "xcov", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, time: 'ArrayLike', data: 'ArrayLike', name: 'str' = 'signal', units: 'str | None' = None, x_label: 'str | None' = None, y_label: 'str | None' = None, x_units: 'str | None' = None, y_units: 'str | None' = None, plot_props: 'dict[str, Any]' = ) -> None", + "fields": [ + "data", + "name", + "plot_props", + "time", + "units", + "x_label", + "x_units", + "y_label", + "y_units" + ], + "methods": { + "align_time": "(self, new_zero_time: 'float' = 0.0) -> \"'Signal'\"", + "clear_plot_props": "(self) -> \"'Signal'\"", + "copy": "(self) -> \"'Signal'\"", + "copy_signal": "(self) -> \"'Signal'\"", + "data_to_matrix": "(self) -> 'np.ndarray'", + "derivative": "(self) -> \"'Signal'\"", + "get_sub_signal": "(self, selector: 'int | list[int] | np.ndarray') -> \"'Signal'\"", + "integral": "(self) -> 'np.ndarray'", + "merge": "(self, other: \"'Signal'\") -> \"'Signal'\"", + "resample": "(self, sample_rate_hz: 'float') -> \"'Signal'\"", + "restrict_to_time_window": "(self, min_time: 'float', max_time: 'float') -> \"'Signal'\"", + "set_max_time": "(self, max_time: 'float') -> \"'Signal'\"", + "set_min_time": "(self, min_time: 'float') -> \"'Signal'\"", + "set_name": "(self, name: 'str') -> \"'Signal'\"", + "set_plot_props": "(self, props: 'dict[str, Any]') -> \"'Signal'\"", + "set_units": "(self, units: 'str') -> \"'Signal'\"", + "set_x_units": "(self, units: 'str') -> \"'Signal'\"", + "set_xlabel": "(self, label: 'str') -> \"'Signal'\"", + "set_y_units": "(self, units: 'str') -> \"'Signal'\"", + "set_ylabel": "(self, label: 'str') -> \"'Signal'\"", + "shift_time": "(self, offset_s: 'float') -> \"'Signal'\"" + }, + "properties": [ + "duration_s", + "n_channels", + "n_samples", + "sample_rate_hz" + ] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.Trial", + "fixture_path": "tests/parity/fixtures/matlab_gold/TrialExamples_gold.mat", + "key_methods": [ + "aligned_binned_observation", + "get_design_matrix", + "set_history", + "set_trial_partition", + "to_structure" + ], + "python_class": "nstat.trial.Trial" + }, + "compat": { + "constructor_signature": "(self, spikes: 'SpikeTrainCollection', covariates: 'CovariateCollection') -> None", + "fields": [ + "covariates", + "spikes" + ], + "methods": { + "addCov": "(self, cov: '_Covariate') -> \"'Trial'\"", + "aligned_binned_observation": "(self, bin_size_s: 'float', unit_index: 'int' = 0, mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "findMaxSampleRate": "(self) -> 'float'", + "findMaxTime": "(self) -> 'float'", + "findMinSampleRate": "(self) -> 'float'", + "findMinTime": "(self) -> 'float'", + "find_max_sample_rate": "(self) -> 'float'", + "find_max_time": "(self) -> 'float'", + "find_min_sample_rate": "(self) -> 'float'", + "find_min_time": "(self) -> 'float'", + "flattenCovMask": "(self, mask: 'list[int] | list[list[int]] | np.ndarray') -> 'list[int]'", + "flattenMask": "(self, mask: 'list[int] | list[list[int]] | np.ndarray') -> 'list[int]'", + "fromStructure": "(payload: 'dict[str, Any]') -> \"'Trial'\"", + "getAlignedBinnedObservation": "(self, binSize_s: 'float', unitIndex: 'int' = 0, mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "getAllCovLabels": "(self) -> 'list[str]'", + "getAllLabels": "(self, binSize_s: 'float' = 0.001) -> 'list[str]'", + "getCov": "(self, selector: 'int | str') -> '_Covariate'", + "getCovLabelsFromMask": "(self) -> 'list[str]'", + "getCovSelectorFromMask": "(self) -> 'list[str]'", + "getDesignMatrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "getEnsCovLabels": "(self, binSize_s: 'float' = 0.001) -> 'list[str]'", + "getEnsCovLabelsFromMask": "(self, binSize_s: 'float' = 0.001) -> 'list[str]'", + "getEnsCovMatrix": "(self, binSize_s: 'float' = 0.001, mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, list[str]]'", + "getEnsembleNeuronCovariates": "(self, binSize_s: 'float' = 0.001, mode: \"Literal['binary', 'count']\" = 'binary') -> 'CovColl'", + "getEvents": "(self) -> '_Events | None'", + "getHistForNeurons": "(self, neuronIndices: 'list[int] | np.ndarray', binSize_s: 'float' = 0.001) -> 'list[np.ndarray]'", + "getHistLabels": "(self) -> 'list[str]'", + "getHistMatrices": "(self, binSize_s: 'float' = 0.001) -> 'list[np.ndarray]'", + "getLabelsFromMask": "(self) -> 'list[str]'", + "getNeuron": "(self, unitInd: 'int' = 0) -> 'nstColl'", + "getNeuronIndFromMask": "(self) -> 'list[int]'", + "getNeuronIndFromName": "(self, name: 'str') -> 'list[int]'", + "getNeuronNames": "(self) -> 'list[str]'", + "getNeuronNeighbors": "(self) -> 'Any'", + "getNumHist": "(self) -> 'int'", + "getNumUniqueNeurons": "(self) -> 'int'", + "getSpikeVector": "(self, binSize_s: 'float', unitIndex: 'int' = 0, mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray]'", + "getTrialPartition": "(self) -> 'dict[str, tuple[float, float]]'", + "getUniqueNeuronNames": "(self) -> 'list[str]'", + "get_all_cov_labels": "(self) -> 'list[str]'", + "get_cov": "(self, selector: 'int | str') -> 'Covariate'", + "get_design_matrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "get_neuron": "(self, unit_index: 'int' = 0) -> 'SpikeTrainCollection'", + "get_spike_vector": "(self, bin_size_s: 'float', unit_index: 'int' = 0, mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray]'", + "isCovMaskSet": "(self) -> 'bool'", + "isEnsCovHistSet": "(self) -> 'bool'", + "isHistSet": "(self) -> 'bool'", + "isMaskSet": "(self) -> 'bool'", + "isNeuronMaskSet": "(self) -> 'bool'", + "isSampleRateConsistent": "(self) -> 'bool'", + "is_sample_rate_consistent": "(self, rtol: 'float' = 1e-06) -> 'bool'", + "makeConsistentSampleRate": "(self, sampleRate: 'float | None' = None) -> \"'Trial'\"", + "makeConsistentTime": "(self) -> \"'Trial'\"", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "plotCovariates": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "plotRaster": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "removeCov": "(self, selector: 'int | str') -> \"'Trial'\"", + "resample": "(self, sampleRate: 'float') -> \"'Trial'\"", + "resampleEnsColl": "(self, sampleRate: 'float') -> 'CovColl'", + "resetCovMask": "(self) -> \"'Trial'\"", + "resetEnsCovMask": "(self) -> \"'Trial'\"", + "resetHistory": "(self) -> \"'Trial'\"", + "resetNeuronMask": "(self) -> \"'Trial'\"", + "restoreToOriginal": "(self) -> \"'Trial'\"", + "setCovMask": "(self, selector: 'list[int] | list[str]') -> \"'Trial'\"", + "setEnsCovHist": "(self, ensCovHist: 'Any') -> \"'Trial'\"", + "setEnsCovMask": "(self, selector: 'list[int] | list[str] | np.ndarray') -> \"'Trial'\"", + "setHistory": "(self, history: 'Any') -> \"'Trial'\"", + "setMaxTime": "(self, t_max: 'float') -> \"'Trial'\"", + "setMinTime": "(self, t_min: 'float') -> \"'Trial'\"", + "setNeighbors": "(self, neighbors: 'Any') -> \"'Trial'\"", + "setNeuronMask": "(self, selector: 'list[int] | list[str] | np.ndarray') -> \"'Trial'\"", + "setSampleRate": "(self, sampleRate: 'float') -> \"'Trial'\"", + "setTrialEvents": "(self, events: '_Events') -> \"'Trial'\"", + "setTrialPartition": "(self, partition: 'dict[str, tuple[float, float]]') -> \"'Trial'\"", + "setTrialTimesFor": "(self, *args: 'Any') -> \"'Trial'\"", + "shiftCovariates": "(self, lag_s: 'float') -> \"'Trial'\"", + "toStructure": "(self) -> 'dict[str, Any]'", + "updateTimePartitions": "(self) -> \"'Trial'\"" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/TrialExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "Trial": "getDesignMatrix", + "getAlignedBinnedObservation": "aligned_binned_observation" + }, + "compat_class": "nstat.compat.matlab.Trial", + "python_class": "nstat.trial.Trial" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "nspikeColl", + "covarColl", + "event", + "hist", + "ensCovHist", + "ensCovMask" + ], + "line": 77, + "name": "Trial", + "static": false + }, + "matlab_class": "Trial", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Trial.m", + "methods": [ + { + "access": "public", + "args": [ + "nspikeColl", + "covarColl", + "event", + "hist", + "ensCovHist", + "ensCovMask" + ], + "line": 77, + "name": "Trial", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "event" + ], + "line": 147, + "name": "setTrialEvents", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "partitionTimes" + ], + "line": 172, + "name": "setTrialPartition", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 202, + "name": "getTrialPartition", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "partitionName" + ], + "line": 214, + "name": "setTrialTimesFor", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "minTime" + ], + "line": 241, + "name": "setMinTime", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "maxTime" + ], + "line": 256, + "name": "setMaxTime", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 270, + "name": "updateTimePartitions", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "sampleRate" + ], + "line": 287, + "name": "setSampleRate", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "mask" + ], + "line": 296, + "name": "setEnsCovMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "mask" + ], + "line": 306, + "name": "setCovMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "mask" + ], + "line": 320, + "name": "setNeuronMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "varargin" + ], + "line": 326, + "name": "setNeighbors", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "hist" + ], + "line": 329, + "name": "setHistory", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "hist" + ], + "line": 360, + "name": "setEnsCovHist", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 400, + "name": "isNeuronMaskSet", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 406, + "name": "isCovMaskSet", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 412, + "name": "isMaskSet", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 418, + "name": "isHistSet", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 438, + "name": "isEnsCovHistSet", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "cov" + ], + "line": 445, + "name": "addCov", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "identifier" + ], + "line": 453, + "name": "removeCov", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "varargin" + ], + "line": 464, + "name": "getSpikeVector", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum", + "varargin" + ], + "line": 471, + "name": "getDesignMatrix", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum", + "includedNeurons", + "varargin" + ], + "line": 508, + "name": "getEnsCovMatrix", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronIndex" + ], + "line": 529, + "name": "getHistForNeurons", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronIndex" + ], + "line": 568, + "name": "getHistMatrices", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "varargin" + ], + "line": 590, + "name": "getEnsembleNeuronCovariates", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 594, + "name": "getNeuronIndFromMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 599, + "name": "getNumUniqueNeurons", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 602, + "name": "getNeuronNames", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 605, + "name": "getUniqueNeuronNames", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronName" + ], + "line": 608, + "name": "getNeuronIndFromName", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum" + ], + "line": 623, + "name": "getNeuronNeighbors", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 630, + "name": "getCovSelectorFromMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "identifier" + ], + "line": 635, + "name": "getCov", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "identifier" + ], + "line": 640, + "name": "getNeuron", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 645, + "name": "getEvents", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 652, + "name": "getAllLabels", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 669, + "name": "getNumHist", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 685, + "name": "getAllCovLabels", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 688, + "name": "getCovLabelsFromMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 692, + "name": "getHistLabels", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 707, + "name": "getEnsCovLabels", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum" + ], + "line": 727, + "name": "getEnsCovLabelsFromMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "neuronNum" + ], + "line": 764, + "name": "getLabelsFromMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 792, + "name": "flattenCovMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 806, + "name": "flattenMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "varargin" + ], + "line": 827, + "name": "shiftCovariates", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 832, + "name": "resetEnsCovMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 836, + "name": "resetCovMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 841, + "name": "resetNeuronMask", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 846, + "name": "resetHistory", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "sampleRate" + ], + "line": 878, + "name": "resample", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 884, + "name": "resampleEnsColl", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 891, + "name": "restoreToOriginal", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 908, + "name": "makeConsistentSampleRate", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 911, + "name": "makeConsistentTime", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "handle" + ], + "line": 921, + "name": "plotRaster", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "handle" + ], + "line": 926, + "name": "plotCovariates", + "static": false + }, + { + "access": "public", + "args": [ + "tObj", + "handle" + ], + "line": 966, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "tObj" + ], + "line": 1015, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 1033, + "name": "fromStructure", + "static": true + }, + { + "access": "private", + "args": [ + "tObj" + ], + "line": 1054, + "name": "isSampleRateConsistent", + "static": false + }, + { + "access": "private", + "args": [ + "tObj" + ], + "line": 1057, + "name": "findMinTime", + "static": false + }, + { + "access": "private", + "args": [ + "tObj" + ], + "line": 1060, + "name": "findMaxTime", + "static": false + }, + { + "access": "private", + "args": [ + "tObj" + ], + "line": 1063, + "name": "findMinSampleRate", + "static": false + }, + { + "access": "private", + "args": [ + "tObj" + ], + "line": 1066, + "name": "findMaxSampleRate", + "static": false + } + ], + "private_methods": [ + "findMaxSampleRate", + "findMaxTime", + "findMinSampleRate", + "findMinTime", + "isSampleRateConsistent" + ], + "properties": [ + { + "access": "public", + "line": 56, + "name": "nspikeColl" + }, + { + "access": "public", + "line": 57, + "name": "covarColl" + }, + { + "access": "public", + "line": 58, + "name": "ensCovHist" + }, + { + "access": "public", + "line": 59, + "name": "ev" + }, + { + "access": "public", + "line": 60, + "name": "history" + }, + { + "access": "public", + "line": 61, + "name": "sampleRate" + }, + { + "access": "public", + "line": 62, + "name": "minTime" + }, + { + "access": "public", + "line": 63, + "name": "maxTime" + }, + { + "access": "public", + "line": 64, + "name": "covMask" + }, + { + "access": "public", + "line": 65, + "name": "ensCovMask" + }, + { + "access": "public", + "line": 66, + "name": "neuronMask" + }, + { + "access": "public", + "line": 67, + "name": "trainingWindow" + }, + { + "access": "public", + "line": 68, + "name": "validationWindow" + }, + { + "access": "public", + "line": 72, + "name": "ensCovColl" + } + ], + "public_methods": [ + "Trial", + "addCov", + "flattenCovMask", + "flattenMask", + "fromStructure", + "getAllCovLabels", + "getAllLabels", + "getCov", + "getCovLabelsFromMask", + "getCovSelectorFromMask", + "getDesignMatrix", + "getEnsCovLabels", + "getEnsCovLabelsFromMask", + "getEnsCovMatrix", + "getEnsembleNeuronCovariates", + "getEvents", + "getHistForNeurons", + "getHistLabels", + "getHistMatrices", + "getLabelsFromMask", + "getNeuron", + "getNeuronIndFromMask", + "getNeuronIndFromName", + "getNeuronNames", + "getNeuronNeighbors", + "getNumHist", + "getNumUniqueNeurons", + "getSpikeVector", + "getTrialPartition", + "getUniqueNeuronNames", + "isCovMaskSet", + "isEnsCovHistSet", + "isHistSet", + "isMaskSet", + "isNeuronMaskSet", + "makeConsistentSampleRate", + "makeConsistentTime", + "plot", + "plotCovariates", + "plotRaster", + "removeCov", + "resample", + "resampleEnsColl", + "resetCovMask", + "resetEnsCovMask", + "resetHistory", + "resetNeuronMask", + "restoreToOriginal", + "setCovMask", + "setEnsCovHist", + "setEnsCovMask", + "setHistory", + "setMaxTime", + "setMinTime", + "setNeighbors", + "setNeuronMask", + "setSampleRate", + "setTrialEvents", + "setTrialPartition", + "setTrialTimesFor", + "shiftCovariates", + "toStructure", + "updateTimePartitions" + ], + "superclass": "handle" + }, + "matlab_class": "Trial", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getDesignMatrix", + "mapped_via_alias": true, + "matlab_method": "Trial", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "addCov", + "mapped_via_alias": false, + "matlab_method": "addCov", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "flattenCovMask", + "mapped_via_alias": false, + "matlab_method": "flattenCovMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "flattenMask", + "mapped_via_alias": false, + "matlab_method": "flattenMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getAllCovLabels", + "mapped_via_alias": false, + "matlab_method": "getAllCovLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getAllLabels", + "mapped_via_alias": false, + "matlab_method": "getAllLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCov", + "mapped_via_alias": false, + "matlab_method": "getCov", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCovLabelsFromMask", + "mapped_via_alias": false, + "matlab_method": "getCovLabelsFromMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getCovSelectorFromMask", + "mapped_via_alias": false, + "matlab_method": "getCovSelectorFromMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getDesignMatrix", + "mapped_via_alias": false, + "matlab_method": "getDesignMatrix", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getEnsCovLabels", + "mapped_via_alias": false, + "matlab_method": "getEnsCovLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getEnsCovLabelsFromMask", + "mapped_via_alias": false, + "matlab_method": "getEnsCovLabelsFromMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getEnsCovMatrix", + "mapped_via_alias": false, + "matlab_method": "getEnsCovMatrix", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getEnsembleNeuronCovariates", + "mapped_via_alias": false, + "matlab_method": "getEnsembleNeuronCovariates", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getEvents", + "mapped_via_alias": false, + "matlab_method": "getEvents", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getHistForNeurons", + "mapped_via_alias": false, + "matlab_method": "getHistForNeurons", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getHistLabels", + "mapped_via_alias": false, + "matlab_method": "getHistLabels", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getHistMatrices", + "mapped_via_alias": false, + "matlab_method": "getHistMatrices", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getLabelsFromMask", + "mapped_via_alias": false, + "matlab_method": "getLabelsFromMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNeuron", + "mapped_via_alias": false, + "matlab_method": "getNeuron", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNeuronIndFromMask", + "mapped_via_alias": false, + "matlab_method": "getNeuronIndFromMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNeuronIndFromName", + "mapped_via_alias": false, + "matlab_method": "getNeuronIndFromName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNeuronNames", + "mapped_via_alias": false, + "matlab_method": "getNeuronNames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNeuronNeighbors", + "mapped_via_alias": false, + "matlab_method": "getNeuronNeighbors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNumHist", + "mapped_via_alias": false, + "matlab_method": "getNumHist", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNumUniqueNeurons", + "mapped_via_alias": false, + "matlab_method": "getNumUniqueNeurons", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSpikeVector", + "mapped_via_alias": false, + "matlab_method": "getSpikeVector", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getTrialPartition", + "mapped_via_alias": false, + "matlab_method": "getTrialPartition", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getUniqueNeuronNames", + "mapped_via_alias": false, + "matlab_method": "getUniqueNeuronNames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isCovMaskSet", + "mapped_via_alias": false, + "matlab_method": "isCovMaskSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isEnsCovHistSet", + "mapped_via_alias": false, + "matlab_method": "isEnsCovHistSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isHistSet", + "mapped_via_alias": false, + "matlab_method": "isHistSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isMaskSet", + "mapped_via_alias": false, + "matlab_method": "isMaskSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isNeuronMaskSet", + "mapped_via_alias": false, + "matlab_method": "isNeuronMaskSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "makeConsistentSampleRate", + "mapped_via_alias": false, + "matlab_method": "makeConsistentSampleRate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "makeConsistentTime", + "mapped_via_alias": false, + "matlab_method": "makeConsistentTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotCovariates", + "mapped_via_alias": false, + "matlab_method": "plotCovariates", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotRaster", + "mapped_via_alias": false, + "matlab_method": "plotRaster", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "removeCov", + "mapped_via_alias": false, + "matlab_method": "removeCov", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resample", + "mapped_via_alias": false, + "matlab_method": "resample", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resampleEnsColl", + "mapped_via_alias": false, + "matlab_method": "resampleEnsColl", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetCovMask", + "mapped_via_alias": false, + "matlab_method": "resetCovMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetEnsCovMask", + "mapped_via_alias": false, + "matlab_method": "resetEnsCovMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetHistory", + "mapped_via_alias": false, + "matlab_method": "resetHistory", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetNeuronMask", + "mapped_via_alias": false, + "matlab_method": "resetNeuronMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "restoreToOriginal", + "mapped_via_alias": false, + "matlab_method": "restoreToOriginal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setCovMask", + "mapped_via_alias": false, + "matlab_method": "setCovMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setEnsCovHist", + "mapped_via_alias": false, + "matlab_method": "setEnsCovHist", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setEnsCovMask", + "mapped_via_alias": false, + "matlab_method": "setEnsCovMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setHistory", + "mapped_via_alias": false, + "matlab_method": "setHistory", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMaxTime", + "mapped_via_alias": false, + "matlab_method": "setMaxTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMinTime", + "mapped_via_alias": false, + "matlab_method": "setMinTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setNeighbors", + "mapped_via_alias": false, + "matlab_method": "setNeighbors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setNeuronMask", + "mapped_via_alias": false, + "matlab_method": "setNeuronMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setSampleRate", + "mapped_via_alias": false, + "matlab_method": "setSampleRate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setTrialEvents", + "mapped_via_alias": false, + "matlab_method": "setTrialEvents", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setTrialPartition", + "mapped_via_alias": false, + "matlab_method": "setTrialPartition", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setTrialTimesFor", + "mapped_via_alias": false, + "matlab_method": "setTrialTimesFor", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "shiftCovariates", + "mapped_via_alias": false, + "matlab_method": "shiftCovariates", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "updateTimePartitions", + "mapped_via_alias": false, + "matlab_method": "updateTimePartitions", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, spikes: 'SpikeTrainCollection', covariates: 'CovariateCollection') -> None", + "fields": [ + "covariates", + "spikes" + ], + "methods": { + "aligned_binned_observation": "(self, bin_size_s: 'float', unit_index: 'int' = 0, mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray, np.ndarray]'", + "find_max_sample_rate": "(self) -> 'float'", + "find_max_time": "(self) -> 'float'", + "find_min_sample_rate": "(self) -> 'float'", + "find_min_time": "(self) -> 'float'", + "get_all_cov_labels": "(self) -> 'list[str]'", + "get_cov": "(self, selector: 'int | str') -> 'Covariate'", + "get_design_matrix": "(self) -> 'tuple[np.ndarray, list[str]]'", + "get_neuron": "(self, unit_index: 'int' = 0) -> 'SpikeTrainCollection'", + "get_spike_vector": "(self, bin_size_s: 'float', unit_index: 'int' = 0, mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray]'", + "is_sample_rate_consistent": "(self, rtol: 'float' = 1e-06) -> 'bool'" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.TrialConfig", + "fixture_path": "tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat", + "key_methods": [ + "get_name", + "set_name", + "to_structure", + "from_structure" + ], + "python_class": "nstat.trial.TrialConfig" + }, + "compat": { + "constructor_signature": "(self, covariateLabels: 'list[str] | None' = None, Fs: 'float' = 1000.0, fitType: 'str' = 'poisson', name: 'str' = 'config', **kwargs: 'Any') -> 'None'", + "fields": [ + "covariate_labels", + "fit_type", + "name", + "sample_rate_hz" + ], + "methods": { + "fromStructure": "(payload: 'dict[str, Any]') -> \"'TrialConfig'\"", + "getCovariateLabels": "(self) -> 'list[str]'", + "getFitType": "(self) -> 'str'", + "getName": "(self) -> 'str'", + "getSampleRate": "(self) -> 'float'", + "setConfig": "(self, trial: \"'Trial'\") -> \"'TrialConfig'\"", + "setName": "(self, name: 'str') -> \"'TrialConfig'\"", + "toStructure": "(self) -> 'dict[str, Any]'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "class_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat" + }, + "mapping": { + "alias_methods": { + "TrialConfig": "getName", + "getCovariateLabels": "covariate_labels", + "getFitType": "fit_type", + "getSampleRate": "sample_rate_hz" + }, + "compat_class": "nstat.compat.matlab.TrialConfig", + "python_class": "nstat.trial.TrialConfig" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "covMask", + "sampleRate", + "history", + "ensCovHist", + "ensCovMask", + "covLag", + "name" + ], + "line": 62, + "name": "TrialConfig", + "static": false + }, + "matlab_class": "TrialConfig", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/TrialConfig.m", + "methods": [ + { + "access": "public", + "args": [ + "covMask", + "sampleRate", + "history", + "ensCovHist", + "ensCovMask", + "covLag", + "name" + ], + "line": 62, + "name": "TrialConfig", + "static": false + }, + { + "access": "public", + "args": [ + "tcObj", + "trial" + ], + "line": 108, + "name": "setConfig", + "static": false + }, + { + "access": "public", + "args": [ + "tcObj" + ], + "line": 148, + "name": "getName", + "static": false + }, + { + "access": "public", + "args": [ + "tcObj", + "n" + ], + "line": 153, + "name": "setName", + "static": false + }, + { + "access": "public", + "args": [ + "tcObj" + ], + "line": 158, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 173, + "name": "fromStructure", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "public", + "line": 50, + "name": "covMask" + }, + { + "access": "public", + "line": 51, + "name": "covLag" + }, + { + "access": "public", + "line": 52, + "name": "sampleRate" + }, + { + "access": "public", + "line": 53, + "name": "history" + }, + { + "access": "public", + "line": 54, + "name": "ensCovHist" + }, + { + "access": "public", + "line": 55, + "name": "ensCovMask" + }, + { + "access": "public", + "line": 56, + "name": "name" + } + ], + "public_methods": [ + "TrialConfig", + "fromStructure", + "getName", + "setConfig", + "setName", + "toStructure" + ], + "superclass": "handle" + }, + "matlab_class": "TrialConfig", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getName", + "mapped_via_alias": true, + "matlab_method": "TrialConfig", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getName", + "mapped_via_alias": false, + "matlab_method": "getName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setConfig", + "mapped_via_alias": false, + "matlab_method": "setConfig", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setName", + "mapped_via_alias": false, + "matlab_method": "setName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, covariate_labels: 'list[str]' = , sample_rate_hz: 'float' = 1000.0, fit_type: 'str' = 'poisson', name: 'str' = 'config') -> None", + "fields": [ + "covariate_labels", + "fit_type", + "name", + "sample_rate_hz" + ], + "methods": {}, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.nspikeTrain", + "fixture_path": "tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat", + "key_methods": [ + "firing_rate_hz", + "bin_counts", + "binarize", + "shift_time", + "copy" + ], + "python_class": "nstat.spikes.SpikeTrain" + }, + "compat": { + "constructor_signature": "(self, spike_times: 'np.ndarray', t_start: 'float' = 0.0, t_end: 'float | None' = None, name: 'str' = 'unit') -> None", + "fields": [ + "name", + "spike_times", + "t_end", + "t_start" + ], + "methods": { + "bin_counts": "(self, bin_size_s: 'float') -> 'tuple[np.ndarray, np.ndarray]'", + "binarize": "(self, bin_size_s: 'float') -> 'tuple[np.ndarray, np.ndarray]'", + "clearSigRep": "(self) -> '_SpikeTrain'", + "computeRate": "(self) -> 'float'", + "computeStatistics": "(self) -> 'dict[str, float]'", + "copy": "(self) -> \"'SpikeTrain'\"", + "duration_s": "(self) -> 'float'", + "firing_rate_hz": "(self) -> 'float'", + "fromStructure": "(payload: 'dict[str, Any]') -> '_SpikeTrain'", + "getDuration": "(self) -> 'float'", + "getFieldVal": "(self, fieldName: 'str') -> 'Any'", + "getFiringRate": "(self) -> 'float'", + "getISIs": "(self) -> 'np.ndarray'", + "getLStatistic": "(self) -> 'float'", + "getMaxBinSizeBinary": "(self) -> 'float'", + "getMinISI": "(self) -> 'float'", + "getSigRep": "(self, binSize_s: 'float' = 0.001, mode: \"Literal['binary', 'count']\" = 'binary') -> 'np.ndarray'", + "getSpikeTimes": "(self) -> 'np.ndarray'", + "get_spike_times": "(self) -> 'np.ndarray'", + "isSigRepBinary": "(self, binSize_s: 'float' = 0.001) -> 'bool'", + "nspikeTrain": "(*args: 'Any', **kwargs: 'Any') -> '_SpikeTrain'", + "nstCopy": "(self) -> '_SpikeTrain'", + "partitionNST": "(self, partitionEdges_s: 'np.ndarray | list[float]') -> 'list[_SpikeTrain]'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "plotExponentialFit": "(self) -> 'Any'", + "plotISIHistogram": "(self, bins: 'int' = 20) -> 'Any'", + "plotISISpectrumFunction": "(self) -> 'Any'", + "plotJointISIHistogram": "(self, bins: 'int' = 20) -> 'Any'", + "plotProbPlot": "(self) -> 'Any'", + "resample": "(self, sampleRate: 'float') -> '_SpikeTrain'", + "restoreToOriginal": "(self) -> '_SpikeTrain'", + "setMER": "(self, mer: 'float') -> '_SpikeTrain'", + "setMaxTime": "(self, t_max: 'float') -> '_SpikeTrain'", + "setMinTime": "(self, t_min: 'float') -> '_SpikeTrain'", + "setName": "(self, name: 'str') -> '_SpikeTrain'", + "setSigRep": "(self, sigRep: 'np.ndarray') -> '_SpikeTrain'", + "set_max_time": "(self, t_max: 'float') -> \"'SpikeTrain'\"", + "set_min_time": "(self, t_min: 'float') -> \"'SpikeTrain'\"", + "shiftTime": "(self, offset_s: 'float') -> '_SpikeTrain'", + "shift_time": "(self, offset_s: 'float') -> \"'SpikeTrain'\"", + "toStructure": "(self) -> 'dict[str, Any]'" + }, + "properties": [] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "binCounts": "bin_counts", + "binarize": "binarize", + "getDuration": "duration_s", + "getFiringRate": "firing_rate_hz", + "getSpikeTimes": "spike_times" + }, + "compat_class": "nstat.compat.matlab.nspikeTrain", + "python_class": "nstat.spikes.SpikeTrain" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "spikeTimes", + "name", + "binwidth", + "minTime", + "maxTime", + "xlabelval", + "xunits", + "yunits", + "dataLabels", + "makePlots" + ], + "line": 103, + "name": "nspikeTrain", + "static": false + }, + "matlab_class": "nspikeTrain", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/nspikeTrain.m", + "methods": [ + { + "access": "public", + "args": [ + "spikeTimes", + "name", + "binwidth", + "minTime", + "maxTime", + "xlabelval", + "xunits", + "yunits", + "dataLabels", + "makePlots" + ], + "line": 103, + "name": "nspikeTrain", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 179, + "name": "getLStatistic", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "MERSig" + ], + "line": 213, + "name": "setMER", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "name" + ], + "line": 219, + "name": "setName", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "makePlots" + ], + "line": 228, + "name": "computeStatistics", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "binwidth", + "minTime", + "maxTime" + ], + "line": 335, + "name": "setSigRep", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "minTime" + ], + "line": 344, + "name": "setMinTime", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "maxTime" + ], + "line": 355, + "name": "setMaxTime", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 364, + "name": "clearSigRep", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "sampleRate" + ], + "line": 370, + "name": "resample", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "binwidth", + "minTime", + "maxTime" + ], + "line": 383, + "name": "getSigRep", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 559, + "name": "getMaxBinSizeBinary", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 569, + "name": "plotISISpectrumFunction", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "minTime", + "maxTime" + ], + "line": 585, + "name": "getSpikeTimes", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 595, + "name": "plotJointISIHistogram", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "fieldName" + ], + "line": 609, + "name": "getFieldVal", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "minTime", + "maxTime", + "numBins", + "handle" + ], + "line": 617, + "name": "plotISIHistogram", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "minTime", + "maxTime", + "numBins", + "handle" + ], + "line": 713, + "name": "plotExponentialFit", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "minTime", + "maxTime", + "handle" + ], + "line": 732, + "name": "plotProbPlot", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "minTime", + "maxTime" + ], + "line": 775, + "name": "getISIs", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "minTime", + "maxTime" + ], + "line": 787, + "name": "getMinISI", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "windowTimes", + "normalizeTime", + "lbound", + "ubound" + ], + "line": 796, + "name": "partitionNST", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 882, + "name": "isSigRepBinary", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 904, + "name": "computeRate", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 909, + "name": "restoreToOriginal", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 924, + "name": "nstCopy", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj", + "dHeight", + "yOffset", + "currentHandle" + ], + "line": 957, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "nstObj" + ], + "line": 1015, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 1032, + "name": "fromStructure", + "static": true + } + ], + "private_methods": [], + "properties": [ + { + "access": "private", + "line": 69, + "name": "name" + }, + { + "access": "private", + "line": 70, + "name": "spikeTimes" + }, + { + "access": "private", + "line": 72, + "name": "sigRep" + }, + { + "access": "private", + "line": 73, + "name": "sampleRate" + }, + { + "access": "private", + "line": 74, + "name": "maxTime" + }, + { + "access": "private", + "line": 75, + "name": "minTime" + }, + { + "access": "private", + "line": 79, + "name": "isSigRepBin" + }, + { + "access": "private", + "line": 80, + "name": "xlabelval" + }, + { + "access": "private", + "line": 81, + "name": "xunits" + }, + { + "access": "private", + "line": 82, + "name": "yunits" + }, + { + "access": "private", + "line": 83, + "name": "dataLabels" + }, + { + "access": "private", + "line": 84, + "name": "MER" + }, + { + "access": "private", + "line": 85, + "name": "avgFiringRate" + }, + { + "access": "private", + "line": 87, + "name": "B" + }, + { + "access": "private", + "line": 88, + "name": "An" + }, + { + "access": "private", + "line": 89, + "name": "burstTimes" + }, + { + "access": "private", + "line": 90, + "name": "burstRate" + }, + { + "access": "private", + "line": 91, + "name": "burstDuration" + }, + { + "access": "private", + "line": 92, + "name": "burstSig" + }, + { + "access": "private", + "line": 93, + "name": "burstIndex" + }, + { + "access": "private", + "line": 94, + "name": "numBursts" + }, + { + "access": "private", + "line": 95, + "name": "numSpikesPerBurst" + }, + { + "access": "private", + "line": 96, + "name": "avgSpikesPerBurst" + }, + { + "access": "private", + "line": 97, + "name": "stdSpikesPerBurst" + }, + { + "access": "private", + "line": 98, + "name": "Lstatistic" + } + ], + "public_methods": [ + "clearSigRep", + "computeRate", + "computeStatistics", + "fromStructure", + "getFieldVal", + "getISIs", + "getLStatistic", + "getMaxBinSizeBinary", + "getMinISI", + "getSigRep", + "getSpikeTimes", + "isSigRepBinary", + "nspikeTrain", + "nstCopy", + "partitionNST", + "plot", + "plotExponentialFit", + "plotISIHistogram", + "plotISISpectrumFunction", + "plotJointISIHistogram", + "plotProbPlot", + "resample", + "restoreToOriginal", + "setMER", + "setMaxTime", + "setMinTime", + "setName", + "setSigRep", + "toStructure" + ], + "superclass": "handle" + }, + "matlab_class": "nspikeTrain", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "clearSigRep", + "mapped_via_alias": false, + "matlab_method": "clearSigRep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeRate", + "mapped_via_alias": false, + "matlab_method": "computeRate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "computeStatistics", + "mapped_via_alias": false, + "matlab_method": "computeStatistics", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getFieldVal", + "mapped_via_alias": false, + "matlab_method": "getFieldVal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getISIs", + "mapped_via_alias": false, + "matlab_method": "getISIs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getLStatistic", + "mapped_via_alias": false, + "matlab_method": "getLStatistic", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getMaxBinSizeBinary", + "mapped_via_alias": false, + "matlab_method": "getMaxBinSizeBinary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getMinISI", + "mapped_via_alias": false, + "matlab_method": "getMinISI", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSigRep", + "mapped_via_alias": false, + "matlab_method": "getSigRep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "spike_times", + "mapped_via_alias": true, + "matlab_method": "getSpikeTimes", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isSigRepBinary", + "mapped_via_alias": false, + "matlab_method": "isSigRepBinary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "nspikeTrain", + "mapped_via_alias": false, + "matlab_method": "nspikeTrain", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "nstCopy", + "mapped_via_alias": false, + "matlab_method": "nstCopy", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "partitionNST", + "mapped_via_alias": false, + "matlab_method": "partitionNST", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotExponentialFit", + "mapped_via_alias": false, + "matlab_method": "plotExponentialFit", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotISIHistogram", + "mapped_via_alias": false, + "matlab_method": "plotISIHistogram", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotISISpectrumFunction", + "mapped_via_alias": false, + "matlab_method": "plotISISpectrumFunction", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotJointISIHistogram", + "mapped_via_alias": false, + "matlab_method": "plotJointISIHistogram", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotProbPlot", + "mapped_via_alias": false, + "matlab_method": "plotProbPlot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resample", + "mapped_via_alias": false, + "matlab_method": "resample", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "restoreToOriginal", + "mapped_via_alias": false, + "matlab_method": "restoreToOriginal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMER", + "mapped_via_alias": false, + "matlab_method": "setMER", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMaxTime", + "mapped_via_alias": false, + "matlab_method": "setMaxTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMinTime", + "mapped_via_alias": false, + "matlab_method": "setMinTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setName", + "mapped_via_alias": false, + "matlab_method": "setName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setSigRep", + "mapped_via_alias": false, + "matlab_method": "setSigRep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, spike_times: 'np.ndarray', t_start: 'float' = 0.0, t_end: 'float | None' = None, name: 'str' = 'unit') -> None", + "fields": [ + "name", + "spike_times", + "t_end", + "t_start" + ], + "methods": { + "bin_counts": "(self, bin_size_s: 'float') -> 'tuple[np.ndarray, np.ndarray]'", + "binarize": "(self, bin_size_s: 'float') -> 'tuple[np.ndarray, np.ndarray]'", + "copy": "(self) -> \"'SpikeTrain'\"", + "duration_s": "(self) -> 'float'", + "firing_rate_hz": "(self) -> 'float'", + "get_spike_times": "(self) -> 'np.ndarray'", + "set_max_time": "(self, t_max: 'float') -> \"'SpikeTrain'\"", + "set_min_time": "(self, t_min: 'float') -> \"'SpikeTrain'\"", + "shift_time": "(self, offset_s: 'float') -> \"'SpikeTrain'\"" + }, + "properties": [] + }, + "status": "verified" + }, + { + "class_contract": { + "compat_class": "nstat.compat.matlab.nstColl", + "fixture_path": "tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat", + "key_methods": [ + "to_binned_matrix", + "merge", + "get_first_spike_time", + "get_last_spike_time", + "get_spike_times" + ], + "python_class": "nstat.spikes.SpikeTrainCollection" + }, + "compat": { + "constructor_signature": "(self, trains: 'list[SpikeTrain]' = ) -> None", + "fields": [ + "trains" + ], + "methods": { + "BinarySigRep": "(self, binSize_s: 'float' = 0.001) -> 'np.ndarray'", + "addNeuronNamesToEnsCovColl": "(self, covColl: \"'CovColl'\") -> \"'CovColl'\"", + "addSingleSpikeToColl": "(self, unitInd: 'int', spikeTime: 'float') -> '_SpikeTrainCollection'", + "addToColl": "(self, train: '_SpikeTrain') -> '_SpikeTrainCollection'", + "add_single_spike_to_coll": "(self, unit_index: 'int', spike_time_s: 'float', sort_times: 'bool' = True) -> \"'SpikeTrainCollection'\"", + "add_to_coll": "(self, train: 'SpikeTrain') -> \"'SpikeTrainCollection'\"", + "areNeighborsSet": "(self) -> 'bool'", + "copy": "(self) -> \"'SpikeTrainCollection'\"", + "dataToMatrix": "(self, binSize_s: 'float', mode: \"Literal['binary', 'count']\" = 'binary') -> 'np.ndarray'", + "data_to_matrix": "(self, bin_size_s: 'float', mode: \"Literal['binary', 'count']\" = 'binary') -> 'np.ndarray'", + "enforceSampleRate": "(self, sampleRate: 'float') -> '_SpikeTrainCollection'", + "ensureConsistancy": "(self) -> 'bool'", + "estimateVarianceAcrossTrials": "(self, binSize_s: 'float' = 0.01) -> 'np.ndarray'", + "findMaxSampleRate": "(self) -> 'float'", + "fromStructure": "(payload: 'dict[str, Any]') -> '_SpikeTrainCollection'", + "generateUnitImpulseBasis": "(basisWidth_s: 'float', *args: 'Any', **kwargs: 'Any') -> '_Covariate'", + "getBinnedMatrix": "(self, binSize_s: 'float', mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray]'", + "getEnsembleNeuronCovariates": "(self, binSize_s: 'float' = 0.001, mode: \"Literal['binary', 'count']\" = 'binary') -> \"'CovColl'\"", + "getFieldVal": "(self, fieldName: 'str') -> 'list[Any]'", + "getFirstSpikeTime": "(self) -> 'float'", + "getISIs": "(self) -> 'list[np.ndarray]'", + "getIndFromMask": "(self) -> 'list[int]'", + "getIndFromMaskMinusOne": "(self) -> 'list[int]'", + "getLastSpikeTime": "(self) -> 'float'", + "getMaxBinSizeBinary": "(self) -> 'float'", + "getMinISIs": "(self) -> 'np.ndarray'", + "getNST": "(self, ind: 'int') -> 'nspikeTrain'", + "getNSTFromName": "(self, name: 'str') -> 'nspikeTrain'", + "getNSTIndicesFromName": "(self, name: 'str') -> 'list[int]'", + "getNSTnameFromInd": "(self, ind: 'int') -> 'str'", + "getNSTnames": "(self) -> 'list[str]'", + "getNeighbors": "(self) -> 'Any'", + "getNumUnits": "(self) -> 'int'", + "getSpikeTimes": "(self) -> 'list[np.ndarray]'", + "getUniqueNSTnames": "(self) -> 'list[str]'", + "get_first_spike_time": "(self) -> 'float'", + "get_last_spike_time": "(self) -> 'float'", + "get_nst": "(self, index: 'int') -> 'SpikeTrain'", + "get_nst_from_name": "(self, name: 'str', first_only: 'bool' = True) -> 'SpikeTrain | list[SpikeTrain]'", + "get_nst_indices_from_name": "(self, name: 'str') -> 'list[int]'", + "get_nst_name_from_ind": "(self, index: 'int') -> 'str'", + "get_nst_names": "(self) -> 'list[str]'", + "get_spike_times": "(self) -> 'list[np.ndarray]'", + "get_unique_nst_names": "(self) -> 'list[str]'", + "isNeuronMaskSet": "(self) -> 'bool'", + "isSigRepBinary": "(self, binSize_s: 'float' = 0.001) -> 'bool'", + "merge": "(self, other: '_SpikeTrainCollection') -> '_SpikeTrainCollection'", + "nstColl": "(*args: 'Any', **kwargs: 'Any') -> '_SpikeTrainCollection'", + "plot": "(self, *_args: 'Any', **_kwargs: 'Any') -> 'Any'", + "plotExponentialFit": "(self) -> 'Any'", + "plotISIHistogram": "(self, bins: 'int' = 20) -> 'Any'", + "psth": "(self, binSize_s: 'float' = 0.01) -> 'tuple[np.ndarray, np.ndarray]'", + "psthBars": "(self, binSize_s: 'float' = 0.01) -> 'tuple[np.ndarray, np.ndarray]'", + "psthGLM": "(self, binSize_s: 'float' = 0.01) -> 'tuple[np.ndarray, np.ndarray]'", + "resample": "(self, sampleRate: 'float') -> '_SpikeTrainCollection'", + "resetMask": "(self) -> '_SpikeTrainCollection'", + "restoreToOriginal": "(self) -> '_SpikeTrainCollection'", + "setMask": "(self, selector: 'list[int] | list[str]') -> '_SpikeTrainCollection'", + "setMaxTime": "(self, t_max: 'float') -> '_SpikeTrainCollection'", + "setMinTime": "(self, t_min: 'float') -> '_SpikeTrainCollection'", + "setNeighbors": "(self, neighbors: 'Any') -> '_SpikeTrainCollection'", + "setNeuronMask": "(self, selector: 'list[int] | list[str]') -> '_SpikeTrainCollection'", + "setNeuronMaskFromInd": "(self, indices: 'list[int] | np.ndarray') -> '_SpikeTrainCollection'", + "set_max_time": "(self, t_max: 'float') -> \"'SpikeTrainCollection'\"", + "set_min_time": "(self, t_min: 'float') -> \"'SpikeTrainCollection'\"", + "shiftTime": "(self, offset_s: 'float') -> '_SpikeTrainCollection'", + "shift_time": "(self, offset_s: 'float') -> \"'SpikeTrainCollection'\"", + "ssglm": "(self, binSize_s: 'float' = 0.01) -> 'tuple[np.ndarray, np.ndarray]'", + "toSpikeTrain": "(self, name: 'str' = 'merged') -> 'nspikeTrain'", + "toStructure": "(self) -> 'dict[str, Any]'", + "to_binned_matrix": "(self, bin_size_s: 'float', mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray]'", + "to_spike_train": "(self, name: 'str' = 'merged') -> 'SpikeTrain'", + "updateTimes": "(self) -> '_SpikeTrainCollection'" + }, + "properties": [ + "n_units" + ] + }, + "fixture": { + "exists": true, + "generator": "topic_gold_exporter", + "path": "tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat" + }, + "mapping": { + "alias_methods": { + "getBinnedMatrix": "to_binned_matrix", + "getNumUnits": "n_units", + "nstColl": "copy" + }, + "compat_class": "nstat.compat.matlab.nstColl", + "python_class": "nstat.spikes.SpikeTrainCollection" + }, + "matlab": { + "constructor": { + "access": "public", + "args": [ + "nst" + ], + "line": 62, + "name": "nstColl", + "static": false + }, + "matlab_class": "nstColl", + "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/nstColl.m", + "methods": [ + { + "access": "public", + "args": [ + "nst" + ], + "line": 62, + "name": "nstColl", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "nstColl2" + ], + "line": 84, + "name": "merge", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 91, + "name": "getFirstSpikeTime", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 97, + "name": "getLastSpikeTime", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 114, + "name": "getMaxBinSizeBinary", + "static": false + }, + { + "access": "public", + "args": [], + "line": 137, + "name": "get", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "neuronNum" + ], + "line": 142, + "name": "getNeighbors", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "fieldName" + ], + "line": 182, + "name": "getFieldVal", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "timeShift" + ], + "line": 196, + "name": "shiftTime", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "minTime" + ], + "line": 210, + "name": "setMinTime", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "maxTime" + ], + "line": 225, + "name": "setMaxTime", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "mask" + ], + "line": 239, + "name": "setMask", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "mask" + ], + "line": 251, + "name": "setNeuronMaskFromInd", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "mask" + ], + "line": 261, + "name": "setNeuronMask", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "neighborArray" + ], + "line": 269, + "name": "setNeighbors", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 286, + "name": "getIndFromMask", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "neuron" + ], + "line": 294, + "name": "getIndFromMaskMinusOne", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 298, + "name": "isNeuronMaskSet", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 308, + "name": "areNeighborsSet", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "rMask" + ], + "line": 316, + "name": "restoreToOriginal", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 340, + "name": "findMaxSampleRate", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 346, + "name": "resetMask", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "nst" + ], + "line": 352, + "name": "addToColl", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray" + ], + "line": 378, + "name": "getUniqueNSTnames", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray" + ], + "line": 384, + "name": "getNSTnames", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "neuronName" + ], + "line": 394, + "name": "getNSTIndicesFromName", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "ind" + ], + "line": 410, + "name": "getNSTnameFromInd", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "neuronName" + ], + "line": 418, + "name": "getNSTFromName", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "index" + ], + "line": 427, + "name": "getNST", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "sampleRate" + ], + "line": 455, + "name": "resample", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 474, + "name": "isSigRepBinary", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 478, + "name": "BinarySigRep", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "neuronNum", + "neighborIndex", + "windowTimes" + ], + "line": 493, + "name": "getEnsembleNeuronCovariates", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "ensembleCovariates" + ], + "line": 522, + "name": "addNeuronNamesToEnsCovColl", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray", + "binwidth", + "minTime", + "maxTime" + ], + "line": 551, + "name": "dataToMatrix", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray", + "minTime", + "maxTime", + "windowTimes" + ], + "line": 612, + "name": "toSpikeTrain", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "binwidth", + "selectorArray", + "minTime", + "maxTime" + ], + "line": 680, + "name": "psth", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "binwidth", + "selectorArray", + "minTime", + "maxTime" + ], + "line": 745, + "name": "psthBars", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "windowTimes", + "numBasis", + "numVarEstIter", + "fitType" + ], + "line": 809, + "name": "ssglm", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "basisWidth", + "history", + "fitType", + "selectorArray", + "minTime", + "maxTime", + "sampleRate" + ], + "line": 939, + "name": "psthGLM", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray", + "minTime", + "maxTime", + "handle", + "reverseOrderPlot" + ], + "line": 1175, + "name": "plot", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray", + "minTime", + "maxTime" + ], + "line": 1258, + "name": "getMinISIs", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray", + "minTime", + "maxTime" + ], + "line": 1285, + "name": "getISIs", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray", + "minTime", + "maxTime", + "handle" + ], + "line": 1310, + "name": "plotISIHistogram", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "selectorArray", + "minTime", + "maxTime", + "numBins", + "handle" + ], + "line": 1355, + "name": "plotExponentialFit", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "numBasis", + "windowTimes", + "numIter", + "fitType" + ], + "line": 1396, + "name": "estimateVarianceAcrossTrials", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj", + "minTime", + "maxTime" + ], + "line": 1465, + "name": "getSpikeTimes", + "static": false + }, + { + "access": "public", + "args": [ + "nstCollObj" + ], + "line": 1485, + "name": "toStructure", + "static": false + }, + { + "access": "public", + "args": [ + "structure" + ], + "line": 1503, + "name": "fromStructure", + "static": true + }, + { + "access": "public", + "args": [ + "basisWidth", + "minTime", + "maxTime", + "sampleRate" + ], + "line": 1513, + "name": "generateUnitImpulseBasis", + "static": true + }, + { + "access": "private", + "args": [ + "nstCollObj", + "nst" + ], + "line": 1559, + "name": "addSingleSpikeToColl", + "static": false + }, + { + "access": "private", + "args": [ + "nstCollObj" + ], + "line": 1576, + "name": "ensureConsistancy", + "static": false + }, + { + "access": "private", + "args": [ + "nstCollObj" + ], + "line": 1581, + "name": "enforceSampleRate", + "static": false + }, + { + "access": "private", + "args": [ + "nstCollObj", + "nst" + ], + "line": 1589, + "name": "updateTimes", + "static": false + } + ], + "private_methods": [ + "addSingleSpikeToColl", + "enforceSampleRate", + "ensureConsistancy", + "updateTimes" + ], + "properties": [ + { + "access": "private", + "line": 46, + "name": "nstrain" + }, + { + "access": "private", + "line": 47, + "name": "numSpikeTrains" + }, + { + "access": "private", + "line": 48, + "name": "minTime" + }, + { + "access": "private", + "line": 49, + "name": "maxTime" + }, + { + "access": "private", + "line": 50, + "name": "sampleRate" + }, + { + "access": "private", + "line": 51, + "name": "neuronMask" + }, + { + "access": "private", + "line": 52, + "name": "neuronNames" + }, + { + "access": "private", + "line": 54, + "name": "neighbors" + }, + { + "access": "public", + "line": 58, + "name": "uniqueNeuronNames" + } + ], + "public_methods": [ + "BinarySigRep", + "addNeuronNamesToEnsCovColl", + "addToColl", + "areNeighborsSet", + "dataToMatrix", + "estimateVarianceAcrossTrials", + "findMaxSampleRate", + "fromStructure", + "generateUnitImpulseBasis", + "get", + "getEnsembleNeuronCovariates", + "getFieldVal", + "getFirstSpikeTime", + "getISIs", + "getIndFromMask", + "getIndFromMaskMinusOne", + "getLastSpikeTime", + "getMaxBinSizeBinary", + "getMinISIs", + "getNST", + "getNSTFromName", + "getNSTIndicesFromName", + "getNSTnameFromInd", + "getNSTnames", + "getNeighbors", + "getSpikeTimes", + "getUniqueNSTnames", + "isNeuronMaskSet", + "isSigRepBinary", + "merge", + "nstColl", + "plot", + "plotExponentialFit", + "plotISIHistogram", + "psth", + "psthBars", + "psthGLM", + "resample", + "resetMask", + "restoreToOriginal", + "setMask", + "setMaxTime", + "setMinTime", + "setNeighbors", + "setNeuronMask", + "setNeuronMaskFromInd", + "shiftTime", + "ssglm", + "toSpikeTrain", + "toStructure" + ], + "superclass": "handle" + }, + "matlab_class": "nstColl", + "method_rows": [ + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "BinarySigRep", + "mapped_via_alias": false, + "matlab_method": "BinarySigRep", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "addNeuronNamesToEnsCovColl", + "mapped_via_alias": false, + "matlab_method": "addNeuronNamesToEnsCovColl", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "addToColl", + "mapped_via_alias": false, + "matlab_method": "addToColl", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "areNeighborsSet", + "mapped_via_alias": false, + "matlab_method": "areNeighborsSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "dataToMatrix", + "mapped_via_alias": false, + "matlab_method": "dataToMatrix", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "estimateVarianceAcrossTrials", + "mapped_via_alias": false, + "matlab_method": "estimateVarianceAcrossTrials", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "findMaxSampleRate", + "mapped_via_alias": false, + "matlab_method": "findMaxSampleRate", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "fromStructure", + "mapped_via_alias": false, + "matlab_method": "fromStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "generateUnitImpulseBasis", + "mapped_via_alias": false, + "matlab_method": "generateUnitImpulseBasis", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": false, + "covered_by_class_contract": false, + "excluded_method": true, + "mapped_member": "get", + "mapped_via_alias": false, + "matlab_method": "get", + "present_in_compat_surface": false, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getEnsembleNeuronCovariates", + "mapped_via_alias": false, + "matlab_method": "getEnsembleNeuronCovariates", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getFieldVal", + "mapped_via_alias": false, + "matlab_method": "getFieldVal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getFirstSpikeTime", + "mapped_via_alias": false, + "matlab_method": "getFirstSpikeTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getISIs", + "mapped_via_alias": false, + "matlab_method": "getISIs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getIndFromMask", + "mapped_via_alias": false, + "matlab_method": "getIndFromMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getIndFromMaskMinusOne", + "mapped_via_alias": false, + "matlab_method": "getIndFromMaskMinusOne", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getLastSpikeTime", + "mapped_via_alias": false, + "matlab_method": "getLastSpikeTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getMaxBinSizeBinary", + "mapped_via_alias": false, + "matlab_method": "getMaxBinSizeBinary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getMinISIs", + "mapped_via_alias": false, + "matlab_method": "getMinISIs", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNST", + "mapped_via_alias": false, + "matlab_method": "getNST", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNSTFromName", + "mapped_via_alias": false, + "matlab_method": "getNSTFromName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNSTIndicesFromName", + "mapped_via_alias": false, + "matlab_method": "getNSTIndicesFromName", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNSTnameFromInd", + "mapped_via_alias": false, + "matlab_method": "getNSTnameFromInd", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNSTnames", + "mapped_via_alias": false, + "matlab_method": "getNSTnames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getNeighbors", + "mapped_via_alias": false, + "matlab_method": "getNeighbors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getSpikeTimes", + "mapped_via_alias": false, + "matlab_method": "getSpikeTimes", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "getUniqueNSTnames", + "mapped_via_alias": false, + "matlab_method": "getUniqueNSTnames", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isNeuronMaskSet", + "mapped_via_alias": false, + "matlab_method": "isNeuronMaskSet", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "isSigRepBinary", + "mapped_via_alias": false, + "matlab_method": "isSigRepBinary", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": true, + "excluded_method": false, + "mapped_member": "merge", + "mapped_via_alias": false, + "matlab_method": "merge", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "copy", + "mapped_via_alias": true, + "matlab_method": "nstColl", + "present_in_compat_surface": true, + "present_in_python_surface": true + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plot", + "mapped_via_alias": false, + "matlab_method": "plot", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotExponentialFit", + "mapped_via_alias": false, + "matlab_method": "plotExponentialFit", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "plotISIHistogram", + "mapped_via_alias": false, + "matlab_method": "plotISIHistogram", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "psth", + "mapped_via_alias": false, + "matlab_method": "psth", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "psthBars", + "mapped_via_alias": false, + "matlab_method": "psthBars", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "psthGLM", + "mapped_via_alias": false, + "matlab_method": "psthGLM", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resample", + "mapped_via_alias": false, + "matlab_method": "resample", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "resetMask", + "mapped_via_alias": false, + "matlab_method": "resetMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "restoreToOriginal", + "mapped_via_alias": false, + "matlab_method": "restoreToOriginal", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMask", + "mapped_via_alias": false, + "matlab_method": "setMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMaxTime", + "mapped_via_alias": false, + "matlab_method": "setMaxTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setMinTime", + "mapped_via_alias": false, + "matlab_method": "setMinTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setNeighbors", + "mapped_via_alias": false, + "matlab_method": "setNeighbors", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setNeuronMask", + "mapped_via_alias": false, + "matlab_method": "setNeuronMask", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "setNeuronMaskFromInd", + "mapped_via_alias": false, + "matlab_method": "setNeuronMaskFromInd", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "shiftTime", + "mapped_via_alias": false, + "matlab_method": "shiftTime", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "ssglm", + "mapped_via_alias": false, + "matlab_method": "ssglm", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toSpikeTrain", + "mapped_via_alias": false, + "matlab_method": "toSpikeTrain", + "present_in_compat_surface": true, + "present_in_python_surface": false + }, + { + "covered_by_behavior_contract": true, + "covered_by_class_contract": false, + "excluded_method": false, + "mapped_member": "toStructure", + "mapped_via_alias": false, + "matlab_method": "toStructure", + "present_in_compat_surface": true, + "present_in_python_surface": false + } + ], + "python": { + "constructor_signature": "(self, trains: 'list[SpikeTrain]' = ) -> None", + "fields": [ + "trains" + ], + "methods": { + "add_single_spike_to_coll": "(self, unit_index: 'int', spike_time_s: 'float', sort_times: 'bool' = True) -> \"'SpikeTrainCollection'\"", + "add_to_coll": "(self, train: 'SpikeTrain') -> \"'SpikeTrainCollection'\"", + "copy": "(self) -> \"'SpikeTrainCollection'\"", + "data_to_matrix": "(self, bin_size_s: 'float', mode: \"Literal['binary', 'count']\" = 'binary') -> 'np.ndarray'", + "get_first_spike_time": "(self) -> 'float'", + "get_last_spike_time": "(self) -> 'float'", + "get_nst": "(self, index: 'int') -> 'SpikeTrain'", + "get_nst_from_name": "(self, name: 'str', first_only: 'bool' = True) -> 'SpikeTrain | list[SpikeTrain]'", + "get_nst_indices_from_name": "(self, name: 'str') -> 'list[int]'", + "get_nst_name_from_ind": "(self, index: 'int') -> 'str'", + "get_nst_names": "(self) -> 'list[str]'", + "get_spike_times": "(self) -> 'list[np.ndarray]'", + "get_unique_nst_names": "(self) -> 'list[str]'", + "merge": "(self, other: \"'SpikeTrainCollection'\") -> \"'SpikeTrainCollection'\"", + "set_max_time": "(self, t_max: 'float') -> \"'SpikeTrainCollection'\"", + "set_min_time": "(self, t_min: 'float') -> \"'SpikeTrainCollection'\"", + "shift_time": "(self, offset_s: 'float') -> \"'SpikeTrainCollection'\"", + "to_binned_matrix": "(self, bin_size_s: 'float', mode: \"Literal['binary', 'count']\" = 'binary') -> 'tuple[np.ndarray, np.ndarray]'", + "to_spike_train": "(self, name: 'str' = 'merged') -> 'SpikeTrain'" + }, + "properties": [ + "n_units" + ] + }, + "status": "verified" + } + ], + "generated_at_utc": "2026-03-04T13:56:22.456047+00:00", + "matlab_root": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local", + "python_root": "/private/tmp/nstat_python_exec_next", + "required_classes": [ + "SignalObj", + "Covariate", + "ConfidenceInterval", + "Events", + "History", + "nspikeTrain", + "nstColl", + "CovColl", + "TrialConfig", + "ConfigColl", + "Trial", + "CIF", + "Analysis", + "FitResult", + "FitResSummary", + "DecodingAlgorithms" + ], + "summary": { + "classes_missing_fixtures": [], + "classes_missing_mapping": [], + "classes_with_missing_method_symbols": [], + "required_classes_missing_from_matlab_scan": [], + "total_matlab_classes": 16 + } +} diff --git a/parity/class_equivalence_report.json b/parity/class_equivalence_report.json new file mode 100644 index 00000000..31499bb6 --- /dev/null +++ b/parity/class_equivalence_report.json @@ -0,0 +1,124 @@ +{ + "generated_at_utc": "2026-03-04T13:56:22.458597+00:00", + "remaining_issues": [], + "summary": { + "gap_classes": 0, + "partial_classes": 0, + "required_class_coverage_ok": true, + "total_classes": 16, + "verified_classes": 16 + }, + "top_critical_methods_tested": { + "Analysis": [ + "fit_glm", + "fit_trial", + "run_analysis_for_neuron", + "run_analysis_for_all_neurons", + "compute_hist_lag" + ], + "CIF": [ + "evaluate", + "linear_predictor", + "log_likelihood", + "simulate_by_thinning", + "simulateCIFByThinningFromLambda" + ], + "ConfidenceInterval": [ + "width", + "contains", + "set_color", + "set_value", + "from_structure" + ], + "ConfigColl": [ + "get_config", + "add_config", + "get_config_names", + "to_structure", + "from_structure" + ], + "CovColl": [ + "design_matrix", + "get_cov", + "set_mask", + "to_structure", + "from_structure" + ], + "Covariate": [ + "get_sub_signal", + "data_to_matrix", + "compute_mean_plus_ci", + "to_structure", + "from_structure" + ], + "DecodingAlgorithms": [ + "compute_spike_rate_cis", + "compute_spike_rate_diff_cis", + "decode_weighted_center", + "decode_state_posterior", + "computeSpikeRateCIs" + ], + "Events": [ + "subset", + "merge", + "shift", + "to_structure", + "from_structure" + ], + "FitResSummary": [ + "best_by_aic", + "best_by_bic", + "diff_aic", + "diff_bic", + "to_structure" + ], + "FitResult": [ + "predict", + "aic", + "bic", + "as_cif_model", + "to_structure" + ], + "History": [ + "design_matrix", + "to_filter", + "set_window", + "to_structure", + "from_structure" + ], + "SignalObj": [ + "copy", + "resample", + "periodogram", + "get_sub_signal", + "merge" + ], + "Trial": [ + "aligned_binned_observation", + "get_design_matrix", + "set_history", + "set_trial_partition", + "to_structure" + ], + "TrialConfig": [ + "get_name", + "set_name", + "to_structure", + "from_structure" + ], + "nspikeTrain": [ + "firing_rate_hz", + "bin_counts", + "binarize", + "shift_time", + "copy" + ], + "nstColl": [ + "to_binned_matrix", + "merge", + "get_first_spike_time", + "get_last_spike_time", + "get_spike_times" + ] + } +} diff --git a/parity/class_fixture_export_spec.yml b/parity/class_fixture_export_spec.yml new file mode 100644 index 00000000..e39e1ebf --- /dev/null +++ b/parity/class_fixture_export_spec.yml @@ -0,0 +1,69 @@ +version: 1 +description: > + Fixture export specification for per-class equivalence contracts. + This file is consumed by class-equivalence inventory/report tooling and + test harnesses; it is not referenced by the README. + +generators: + - name: topic_gold_exporter + script: tools/parity/export_matlab_gold_fixtures.py + command: >- + python tools/parity/export_matlab_gold_fixtures.py + --matlab-root + --out tests/parity/fixtures/matlab_gold + - name: class_gold_exporter + script: matlab/fixtures/export_class_equivalence_fixtures.m + command: >- + matlab -batch "addpath('matlab/fixtures'); + export_class_equivalence_fixtures('', + 'tests/parity/fixtures/matlab_gold/classes');" + +classes: + - matlab_class: SignalObj + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/SignalObjExamples_gold.mat + - matlab_class: Covariate + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat + - matlab_class: ConfidenceInterval + generator: class_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat + - matlab_class: Events + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/EventsExamples_gold.mat + - matlab_class: History + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/HistoryExamples_gold.mat + - matlab_class: nspikeTrain + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat + - matlab_class: nstColl + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat + - matlab_class: CovColl + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat + - matlab_class: TrialConfig + generator: class_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat + - matlab_class: ConfigColl + generator: class_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat + - matlab_class: Trial + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/TrialExamples_gold.mat + - matlab_class: CIF + generator: class_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat + - matlab_class: Analysis + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/AnalysisExamples_gold.mat + - matlab_class: FitResult + generator: class_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat + - matlab_class: FitResSummary + generator: class_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat + - matlab_class: DecodingAlgorithms + generator: topic_gold_exporter + fixture_path: tests/parity/fixtures/matlab_gold/DecodingExample_gold.mat diff --git a/parity/cycle_validation/cycle2.log b/parity/cycle_validation/cycle2.log new file mode 100644 index 00000000..d0292864 --- /dev/null +++ b/parity/cycle_validation/cycle2.log @@ -0,0 +1,333 @@ +=== Cycle 2 2026-03-04T13:57:40Z === +sssssss................................................................. [ 57%] +...................................................... [100%] +=============================== warnings summary =============================== +../../../opt/anaconda3/lib/python3.12/site-packages/jupyter_client/connect.py:22 + /opt/anaconda3/lib/python3.12/site-packages/jupyter_client/connect.py:22: DeprecationWarning: Jupyter is migrating its paths to use standard platformdirs + given by the platformdirs library. To remove this warning and + see the appropriate new directories, set the environment variable + `JUPYTER_PLATFORM_DIRS=1` and then run `jupyter --paths`. + The use of platformdirs will be the default in `jupyter_core` v6 + from jupyter_core.paths import jupyter_data_dir, jupyter_runtime_dir, secure_write + +tests/test_compat_behavior_contracts.py::test_compat_behavior_contracts_execute + /private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:582: UserWarning: nperseg = 256 is greater than input length = 5, using nperseg = 5 + f, t, s = spectrogram(mat[:, 0], fs=fs) + +tests/test_compat_behavior_contracts.py::test_compat_behavior_contracts_execute + /private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:3239: RuntimeWarning: Mean of empty slice + vals.append(float(np.nanmean(arr)) if arr.size else np.nan) + +-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html +Validation image baseline check passed. +Copied baseline images to tmp/pdfs/validation_report/notebook_images (49 png files). +Wrote MATLAB inventory to /private/tmp/nstat_python_exec_next/parity/matlab_api_inventory.json +Wrote Python inventory to /private/tmp/nstat_python_exec_next/parity/python_api_inventory.json +Wrote parity gap report to /private/tmp/nstat_python_exec_next/parity/parity_gap_report.json +Issue summary: high=0, medium=0, low=0 +/private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:582: UserWarning: nperseg = 256 is greater than input length = 11, using nperseg = 11 + f, t, s = spectrogram(mat[:, 0], fs=fs) +/private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:3239: RuntimeWarning: Mean of empty slice + vals.append(float(np.nanmean(arr)) if arr.size else np.nan) +/private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:3252: RuntimeWarning: Mean of empty slice + vals.append(float(np.nanmean(np.abs(arr))) if arr.size else np.nan) +Wrote method probe report to /private/tmp/nstat_python_exec_next/parity/method_probe_report.json +Method probe summary: total=502, attempted=402, successful=329 +Wrote equivalence audit report to /private/tmp/nstat_python_exec_next/parity/function_example_alignment_report.json +Method functional audit: total=502, excluded=21, verified=481, unverified=0, missing=0 +Example alignment audit: topics=30, pending_manual_review=0 +Strict line-port audit: verified=26, partial=0, gap=0 +Wrote numeric drift report: /private/tmp/nstat_python_exec_next/parity/numeric_drift_report.json +Topics: 31 +Failed topics: 0 +Failed metrics: 0 +Required topics coverage: 30/30 +Functional parity gate passed. +Example output spec check passed. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +Generated help pages, TOC, and mapping artifacts. +/private/tmp/nstat_python_exec_next/tools/reports/generate_validation_pdf.py:861: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). + "generated_at_utc": datetime.utcnow().isoformat(timespec="seconds") + "Z", +Generated PDF report: /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_085753.pdf +Machine-readable summary (JSON): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_085753.json +Machine-readable summary (CSV): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_085753.csv +MATLAB help root: /Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/helpfiles +Notebook results: total=30 executed=30 exec_failures=0 with_images=30 with_unique_images=30 duplicate_topics=0 +Parity results (gate mode): checked=30 failures=0 +Numeric drift topic results: checked=30 failures=0 +Command checks: total=0 failed=0 +Uniqueness stats: total_instances=37 total_unique=37 cross_topic_reused=0 cross_topic_reuse_ratio=0.000000 +Uniqueness violations: 0 +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +Generated help pages, TOC, and mapping artifacts. +/private/tmp/nstat_python_exec_next/tools/reports/generate_validation_pdf.py:861: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). + "generated_at_utc": datetime.utcnow().isoformat(timespec="seconds") + "Z", +Generated PDF report: /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_085939.pdf +Machine-readable summary (JSON): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_085939.json +Machine-readable summary (CSV): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_085939.csv +MATLAB help root: /Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/helpfiles +Notebook results: total=30 executed=30 exec_failures=0 with_images=30 with_unique_images=30 duplicate_topics=0 +Parity results (image mode): checked=0 failures=0 +Numeric drift topic results: checked=30 failures=0 +Command checks: total=0 failed=0 +Uniqueness stats: total_instances=37 total_unique=37 cross_topic_reused=0 cross_topic_reuse_ratio=0.000000 +Uniqueness violations: 0 +Wrote Python PDF: output/pdf/image_mode_parity/python_pages.pdf +Wrote MATLAB PDF: output/pdf/image_mode_parity/matlab_pages.pdf +Wrote pairs JSON: output/pdf/image_mode_parity/pairs.json +Wrote image-mode parity summary: /private/tmp/nstat_python_exec_next/output/pdf/image_mode_parity/summary.json +Compared pages: 30 (python=30 matlab=30) +Failed pages: 0 +Wrote Python performance JSON: output/performance/python_performance_report.json +Wrote Python performance CSV: output/performance/python_performance_report.csv +Benchmarked case-tier pairs: 7 +Skipping regression gating: benchmark environments are not comparable (current={'python': '3.12.4', 'platform': 'macOS-26.3-arm64-arm-64bit', 'numpy': '1.26.4', 'scipy': '1.13.1', 'matplotlib': '3.8.4', 'omp_num_threads': '', 'mkl_num_threads': '', 'openblas_num_threads': '', 'veclib_maximum_threads': ''}, previous={'python': '3.11.14', 'platform': 'Linux-6.14.0-1017-azure-x86_64-with-glibc2.39', 'numpy': '2.4.2', 'scipy': '1.17.1', 'matplotlib': '3.10.8', 'omp_num_threads': '1', 'mkl_num_threads': '1', 'openblas_num_threads': '1', 'veclib_maximum_threads': '1'}) +Wrote performance parity JSON: output/performance/performance_parity_report.json +Wrote performance parity CSV: output/performance/performance_parity_report.csv +Counts: total=7 missing_matlab=2 ratio_fail=0 regression_fail=0 diff --git a/parity/cycle_validation/cycle3.log b/parity/cycle_validation/cycle3.log new file mode 100644 index 00000000..9887b392 --- /dev/null +++ b/parity/cycle_validation/cycle3.log @@ -0,0 +1,333 @@ +=== Cycle 3 2026-03-04T14:02:15Z === +sssssss................................................................. [ 57%] +...................................................... [100%] +=============================== warnings summary =============================== +../../../opt/anaconda3/lib/python3.12/site-packages/jupyter_client/connect.py:22 + /opt/anaconda3/lib/python3.12/site-packages/jupyter_client/connect.py:22: DeprecationWarning: Jupyter is migrating its paths to use standard platformdirs + given by the platformdirs library. To remove this warning and + see the appropriate new directories, set the environment variable + `JUPYTER_PLATFORM_DIRS=1` and then run `jupyter --paths`. + The use of platformdirs will be the default in `jupyter_core` v6 + from jupyter_core.paths import jupyter_data_dir, jupyter_runtime_dir, secure_write + +tests/test_compat_behavior_contracts.py::test_compat_behavior_contracts_execute + /private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:582: UserWarning: nperseg = 256 is greater than input length = 5, using nperseg = 5 + f, t, s = spectrogram(mat[:, 0], fs=fs) + +tests/test_compat_behavior_contracts.py::test_compat_behavior_contracts_execute + /private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:3239: RuntimeWarning: Mean of empty slice + vals.append(float(np.nanmean(arr)) if arr.size else np.nan) + +-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html +Validation image baseline check passed. +Copied baseline images to tmp/pdfs/validation_report/notebook_images (49 png files). +Wrote MATLAB inventory to /private/tmp/nstat_python_exec_next/parity/matlab_api_inventory.json +Wrote Python inventory to /private/tmp/nstat_python_exec_next/parity/python_api_inventory.json +Wrote parity gap report to /private/tmp/nstat_python_exec_next/parity/parity_gap_report.json +Issue summary: high=0, medium=0, low=0 +/private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:582: UserWarning: nperseg = 256 is greater than input length = 11, using nperseg = 11 + f, t, s = spectrogram(mat[:, 0], fs=fs) +/private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:3239: RuntimeWarning: Mean of empty slice + vals.append(float(np.nanmean(arr)) if arr.size else np.nan) +/private/tmp/nstat_python_exec_next/src/nstat/compat/matlab/__init__.py:3252: RuntimeWarning: Mean of empty slice + vals.append(float(np.nanmean(np.abs(arr))) if arr.size else np.nan) +Wrote method probe report to /private/tmp/nstat_python_exec_next/parity/method_probe_report.json +Method probe summary: total=502, attempted=402, successful=329 +Wrote equivalence audit report to /private/tmp/nstat_python_exec_next/parity/function_example_alignment_report.json +Method functional audit: total=502, excluded=21, verified=481, unverified=0, missing=0 +Example alignment audit: topics=30, pending_manual_review=0 +Strict line-port audit: verified=26, partial=0, gap=0 +Wrote numeric drift report: /private/tmp/nstat_python_exec_next/parity/numeric_drift_report.json +Topics: 31 +Failed topics: 0 +Failed metrics: 0 +Required topics coverage: 30/30 +Functional parity gate passed. +Example output spec check passed. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +Generated help pages, TOC, and mapping artifacts. +/private/tmp/nstat_python_exec_next/tools/reports/generate_validation_pdf.py:861: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). + "generated_at_utc": datetime.utcnow().isoformat(timespec="seconds") + "Z", +Generated PDF report: /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_090228.pdf +Machine-readable summary (JSON): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_090228.json +Machine-readable summary (CSV): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_090228.csv +MATLAB help root: /Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/helpfiles +Notebook results: total=30 executed=30 exec_failures=0 with_images=30 with_unique_images=30 duplicate_topics=0 +Parity results (gate mode): checked=30 failures=0 +Numeric drift topic results: checked=30 failures=0 +Command checks: total=0 failed=0 +Uniqueness stats: total_instances=37 total_unique=37 cross_topic_reused=0 cross_topic_reuse_ratio=0.000000 +Uniqueness violations: 0 +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +0.00s - Debugger warning: It seems that frozen modules are being used, which may +0.00s - make the debugger miss breakpoints. Please pass -Xfrozen_modules=off +0.00s - to python to disable frozen modules. +0.00s - Note: Debugging will proceed. Set PYDEVD_DISABLE_FILE_VALIDATION=1 to disable this validation. +Generated help pages, TOC, and mapping artifacts. +/private/tmp/nstat_python_exec_next/tools/reports/generate_validation_pdf.py:861: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC). + "generated_at_utc": datetime.utcnow().isoformat(timespec="seconds") + "Z", +Generated PDF report: /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_090412.pdf +Machine-readable summary (JSON): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_090412.json +Machine-readable summary (CSV): /private/tmp/nstat_python_exec_next/output/pdf/nstat_python_validation_report_20260304_090412.csv +MATLAB help root: /Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/helpfiles +Notebook results: total=30 executed=30 exec_failures=0 with_images=30 with_unique_images=30 duplicate_topics=0 +Parity results (image mode): checked=0 failures=0 +Numeric drift topic results: checked=30 failures=0 +Command checks: total=0 failed=0 +Uniqueness stats: total_instances=37 total_unique=37 cross_topic_reused=0 cross_topic_reuse_ratio=0.000000 +Uniqueness violations: 0 +Wrote Python PDF: output/pdf/image_mode_parity/python_pages.pdf +Wrote MATLAB PDF: output/pdf/image_mode_parity/matlab_pages.pdf +Wrote pairs JSON: output/pdf/image_mode_parity/pairs.json +Wrote image-mode parity summary: /private/tmp/nstat_python_exec_next/output/pdf/image_mode_parity/summary.json +Compared pages: 30 (python=30 matlab=30) +Failed pages: 0 +Wrote Python performance JSON: output/performance/python_performance_report.json +Wrote Python performance CSV: output/performance/python_performance_report.csv +Benchmarked case-tier pairs: 7 +Skipping regression gating: benchmark environments are not comparable (current={'python': '3.12.4', 'platform': 'macOS-26.3-arm64-arm-64bit', 'numpy': '1.26.4', 'scipy': '1.13.1', 'matplotlib': '3.8.4', 'omp_num_threads': '', 'mkl_num_threads': '', 'openblas_num_threads': '', 'veclib_maximum_threads': ''}, previous={'python': '3.11.14', 'platform': 'Linux-6.14.0-1017-azure-x86_64-with-glibc2.39', 'numpy': '2.4.2', 'scipy': '1.17.1', 'matplotlib': '3.10.8', 'omp_num_threads': '1', 'mkl_num_threads': '1', 'openblas_num_threads': '1', 'veclib_maximum_threads': '1'}) +Wrote performance parity JSON: output/performance/performance_parity_report.json +Wrote performance parity CSV: output/performance/performance_parity_report.csv +Counts: total=7 missing_matlab=2 ratio_fail=0 regression_fail=0 diff --git a/parity/matlab_api_inventory.json b/parity/matlab_api_inventory.json index 5f96025f..c8c42d3f 100644 --- a/parity/matlab_api_inventory.json +++ b/parity/matlab_api_inventory.json @@ -2,7 +2,7 @@ "classes": [ { "matlab_class": "SignalObj", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/SignalObj.m", + "matlab_file": "/private/tmp/upstream-nstat/SignalObj.m", "method_count": 98, "methods": [ "SignalObj", @@ -107,7 +107,7 @@ }, { "matlab_class": "Covariate", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Covariate.m", + "matlab_file": "/private/tmp/upstream-nstat/Covariate.m", "method_count": 14, "methods": [ "Covariate", @@ -128,7 +128,7 @@ }, { "matlab_class": "ConfidenceInterval", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/ConfidenceInterval.m", + "matlab_file": "/private/tmp/upstream-nstat/ConfidenceInterval.m", "method_count": 5, "methods": [ "ConfidenceInterval", @@ -140,7 +140,7 @@ }, { "matlab_class": "Events", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Events.m", + "matlab_file": "/private/tmp/upstream-nstat/Events.m", "method_count": 5, "methods": [ "Events", @@ -152,7 +152,7 @@ }, { "matlab_class": "History", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/History.m", + "matlab_file": "/private/tmp/upstream-nstat/History.m", "method_count": 8, "methods": [ "History", @@ -167,7 +167,7 @@ }, { "matlab_class": "nspikeTrain", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/nspikeTrain.m", + "matlab_file": "/private/tmp/upstream-nstat/nspikeTrain.m", "method_count": 29, "methods": [ "nspikeTrain", @@ -203,7 +203,7 @@ }, { "matlab_class": "nstColl", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/nstColl.m", + "matlab_file": "/private/tmp/upstream-nstat/nstColl.m", "method_count": 53, "methods": [ "nstColl", @@ -263,7 +263,7 @@ }, { "matlab_class": "CovColl", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/CovColl.m", + "matlab_file": "/private/tmp/upstream-nstat/CovColl.m", "method_count": 55, "methods": [ "CovColl", @@ -325,7 +325,7 @@ }, { "matlab_class": "TrialConfig", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/TrialConfig.m", + "matlab_file": "/private/tmp/upstream-nstat/TrialConfig.m", "method_count": 6, "methods": [ "TrialConfig", @@ -338,7 +338,7 @@ }, { "matlab_class": "ConfigColl", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/ConfigColl.m", + "matlab_file": "/private/tmp/upstream-nstat/ConfigColl.m", "method_count": 9, "methods": [ "ConfigColl", @@ -354,7 +354,7 @@ }, { "matlab_class": "Trial", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Trial.m", + "matlab_file": "/private/tmp/upstream-nstat/Trial.m", "method_count": 68, "methods": [ "Trial", @@ -429,7 +429,7 @@ }, { "matlab_class": "CIF", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/CIF.m", + "matlab_file": "/private/tmp/upstream-nstat/CIF.m", "method_count": 21, "methods": [ "CIF", @@ -457,7 +457,7 @@ }, { "matlab_class": "Analysis", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/Analysis.m", + "matlab_file": "/private/tmp/upstream-nstat/Analysis.m", "method_count": 22, "methods": [ "RunAnalysisForNeuron", @@ -486,7 +486,7 @@ }, { "matlab_class": "FitResult", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/FitResult.m", + "matlab_file": "/private/tmp/upstream-nstat/FitResult.m", "method_count": 33, "methods": [ "FitResult", @@ -526,7 +526,7 @@ }, { "matlab_class": "FitResSummary", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/FitResSummary.m", + "matlab_file": "/private/tmp/upstream-nstat/FitResSummary.m", "method_count": 30, "methods": [ "FitResSummary", @@ -563,7 +563,7 @@ }, { "matlab_class": "DecodingAlgorithms", - "matlab_file": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local/DecodingAlgorithms.m", + "matlab_file": "/private/tmp/upstream-nstat/DecodingAlgorithms.m", "method_count": 45, "methods": [ "PPDecodeFilter", @@ -614,6 +614,6 @@ ] } ], - "generated_at_utc": "2026-03-02T18:50:19.335170+00:00", - "matlab_root": "/Users/iahncajigas/Library/CloudStorage/Dropbox/Research/Matlab/nSTAT_currentRelease_Local" + "generated_at_utc": "2026-03-04T14:50:53.506323+00:00", + "matlab_root": "/private/tmp/upstream-nstat" } diff --git a/parity/method_exclusions.yml b/parity/method_exclusions.yml index 03a522c4..c4c1502f 100644 --- a/parity/method_exclusions.yml +++ b/parity/method_exclusions.yml @@ -2,6 +2,14 @@ version: 1 policy_name: matlab_stub_exclusions classes: + - matlab_class: Covariate + rationale: "MATLAB legacy overloaded `get` accessor is represented by explicit property access in Python." + methods: + - get + - matlab_class: nstColl + rationale: "MATLAB legacy overloaded `get` accessor is represented by explicit property access in Python." + methods: + - get - matlab_class: DecodingAlgorithms rationale: "Documented as not yet ported in compat layer and intentionally raises NotImplementedError." methods: diff --git a/parity/method_probe_report.json b/parity/method_probe_report.json index 27294c37..6e197a96 100644 --- a/parity/method_probe_report.json +++ b/parity/method_probe_report.json @@ -1239,8 +1239,8 @@ "successful_method_count": 7 } ], - "generated_at_utc": "2026-03-02T18:50:23.986814+00:00", - "repo_root": "/private/tmp/nSTAT-python-cleanroom", + "generated_at_utc": "2026-03-04T14:50:57.511764+00:00", + "repo_root": "/private/tmp/nstat_python_exec_next", "summary": { "attempt_ratio": 0.8003992015968064, "attempted_methods": 401, diff --git a/parity/numeric_drift_report.json b/parity/numeric_drift_report.json index 5b7c9335..fd362418 100644 --- a/parity/numeric_drift_report.json +++ b/parity/numeric_drift_report.json @@ -1,6 +1,6 @@ { "schema_version": 1, - "generated_at_utc": "2026-03-04T04:20:54.562003+00:00", + "generated_at_utc": "2026-03-04T14:02:27.869956+00:00", "fixtures_manifest": "/private/tmp/nstat_python_exec_next/tests/parity/fixtures/matlab_gold/manifest.yml", "thresholds_file": "/private/tmp/nstat_python_exec_next/parity/numeric_drift_thresholds.yml", "summary": { diff --git a/parity/parity_gap_report.json b/parity/parity_gap_report.json index f21b4a7a..ed7b527b 100644 --- a/parity/parity_gap_report.json +++ b/parity/parity_gap_report.json @@ -266,7 +266,7 @@ } ], "fail_on": "medium", - "generated_at_utc": "2026-03-02T18:50:21.876733+00:00", + "generated_at_utc": "2026-03-04T14:50:55.758179+00:00", "issues": [], "summary": { "high": 0, diff --git a/parity/python_api_inventory.json b/parity/python_api_inventory.json index 5c3349cf..43536492 100644 --- a/parity/python_api_inventory.json +++ b/parity/python_api_inventory.json @@ -512,7 +512,7 @@ "fields": [ "trains" ], - "method_count": 72, + "method_count": 73, "methods": [ "BinarySigRep", "addNeuronNamesToEnsCovColl", @@ -561,6 +561,7 @@ "isNeuronMaskSet", "isSigRepBinary", "merge", + "nstColl", "plot", "plotExponentialFit", "plotISIHistogram", @@ -1262,7 +1263,7 @@ { "compat": { "fields": [], - "method_count": 47, + "method_count": 48, "methods": [ "ComputeStimulusCIs", "KF_ComputeParamStandardErrors", @@ -1292,6 +1293,7 @@ "decodeStatePosterior", "decodeWeightedCenter", "estimateInfoMat", + "getPoolSizeCompat", "kalman_filter", "kalman_fixedIntervalSmoother", "kalman_predict", @@ -1335,6 +1337,6 @@ "python_class": "nstat.decoding.DecodingAlgorithms" } ], - "generated_at_utc": "2026-03-02T18:50:20.498817+00:00", - "python_root": "/private/tmp/nSTAT-python-cleanroom" + "generated_at_utc": "2026-03-04T14:50:54.544346+00:00", + "python_root": "/private/tmp/nstat_python_exec_next" } diff --git a/src/nstat/compat/matlab/__init__.py b/src/nstat/compat/matlab/__init__.py index f30f5674..3d8fbe9e 100644 --- a/src/nstat/compat/matlab/__init__.py +++ b/src/nstat/compat/matlab/__init__.py @@ -3275,6 +3275,13 @@ def _em_not_implemented(name: str) -> None: f"{name} is not yet ported in nSTAT-python; use decodeStatePosterior/kalman_* APIs for now." ) + @staticmethod + def getPoolSizeCompat() -> int: + """Return active parallel pool size (MATLAB-compatible fallback).""" + # MATLAB returns 0 when no active parallel pool exists. nSTAT-python + # executes these workflows serially, so preserve the same default. + return 0 + @staticmethod def _chol_like_matlab(mat: np.ndarray) -> np.ndarray: arr = np.asarray(mat, dtype=float) diff --git a/tests/parity/compat_behavior_specs.yml b/tests/parity/compat_behavior_specs.yml index a48224fe..6272aae3 100644 --- a/tests/parity/compat_behavior_specs.yml +++ b/tests/parity/compat_behavior_specs.yml @@ -2489,6 +2489,10 @@ classes: python_class: nstat.compat.matlab.DecodingAlgorithms scenario: compat_decoding_basic contracts: + - member: getPoolSizeCompat + access: method + expect: + equals: 0 - member: computeSpikeRateDiffCIs access: method args_key: diff_args diff --git a/tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat b/tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat new file mode 100644 index 00000000..81e02193 Binary files /dev/null and b/tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat differ diff --git a/tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat b/tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat new file mode 100644 index 00000000..7fd7deba Binary files /dev/null and b/tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat differ diff --git a/tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat b/tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat new file mode 100644 index 00000000..2a38fb8c Binary files /dev/null and b/tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat differ diff --git a/tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat b/tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat new file mode 100644 index 00000000..3ba797be Binary files /dev/null and b/tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat differ diff --git a/tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat b/tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat new file mode 100644 index 00000000..5475e62c Binary files /dev/null and b/tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat differ diff --git a/tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat b/tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat new file mode 100644 index 00000000..24c0e876 Binary files /dev/null and b/tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat differ diff --git a/tests/test_class_contracts.py b/tests/test_class_contracts.py new file mode 100644 index 00000000..899ad6b2 --- /dev/null +++ b/tests/test_class_contracts.py @@ -0,0 +1,268 @@ +from __future__ import annotations + +from pathlib import Path +from typing import Any + +import numpy as np +import scipy.io +import yaml + +from nstat.compat import matlab as M +from tests.parity_utils import assert_allclose_scaled, assert_same_shape + + +CLASS_CONTRACTS = Path("parity/class_contracts.yml") +FIXTURE_SPEC = Path("parity/class_fixture_export_spec.yml") + + +def _load_yaml(path: Path) -> dict[str, Any]: + return yaml.safe_load(path.read_text(encoding="utf-8")) + + +def _load_mat(path: Path) -> dict[str, Any]: + return scipy.io.loadmat(path) + + +def _vec(m: dict[str, Any], key: str) -> np.ndarray: + return np.asarray(m[key], dtype=float).reshape(-1) + + +def _str_list(mat_cell: Any) -> list[str]: + arr = np.asarray(mat_cell, dtype=object).reshape(-1) + out: list[str] = [] + for item in arr: + if isinstance(item, np.ndarray): + if item.size == 1: + out.append(str(item.reshape(-1)[0])) + else: + out.append(str(item.squeeze().tolist())) + else: + out.append(str(item)) + return out + + +def test_class_contract_manifest_covers_all_classes_and_fixtures_exist() -> None: + contracts = _load_yaml(CLASS_CONTRACTS) + fixture_spec = _load_yaml(FIXTURE_SPEC) + + contract_classes = {str(row["matlab_class"]) for row in contracts.get("classes", [])} + fixture_classes = {str(row["matlab_class"]) for row in fixture_spec.get("classes", [])} + expected = { + "SignalObj", + "Covariate", + "ConfidenceInterval", + "Events", + "History", + "nspikeTrain", + "nstColl", + "CovColl", + "TrialConfig", + "ConfigColl", + "Trial", + "CIF", + "Analysis", + "FitResult", + "FitResSummary", + "DecodingAlgorithms", + } + + assert contract_classes == expected + assert fixture_classes == expected + + for row in contracts.get("classes", []): + fixture_path = Path(str(row["fixture_path"])) + assert fixture_path.exists(), f"missing fixture for {row['matlab_class']}: {fixture_path}" + assert row.get("key_methods"), f"missing key_methods for {row['matlab_class']}" + + +def test_signalobj_contract_against_matlab_fixture() -> None: + m = _load_mat(Path("tests/parity/fixtures/matlab_gold/SignalObjExamples_gold.mat")) + t = _vec(m, "time_sig") + v1 = _vec(m, "v1_sig") + v2 = _vec(m, "v2_sig") + fs = float(_vec(m, "sampleRate_sig")[0]) + rs = float(_vec(m, "resample_hz_sig")[0]) + window_t0 = float(_vec(m, "window_t0_sig")[0]) + window_t1 = float(_vec(m, "window_t1_sig")[0]) + expected_peak = int(round(float(_vec(m, "periodogram_peak_idx_sig")[0]))) + + s = M.SignalObj(time=t, data=np.column_stack([v1, v2]), name="sig") + assert s.getNumSamples() == int(round(float(_vec(m, "n_samples_sig")[0]))) + assert np.isclose(s.getSampleRate(), fs, atol=1e-10) + + rs_obj = s.resample(rs) + assert rs_obj.getNumSamples() == int(round(float(_vec(m, "resampled_n_samples_sig")[0]))) + win = s.getSigInTimeWindow(window_t0, window_t1) + assert win.getNumSamples() == int(round(float(_vec(m, "window_n_samples_sig")[0]))) + + _f, p = s.periodogram() + assert int(np.argmax(np.asarray(p).reshape(-1))) == expected_peak + + +def test_covariate_contract_against_matlab_fixture() -> None: + m = _load_mat(Path("tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat")) + time = _vec(m, "time_cov") + stim = _vec(m, "cov_stim") + ctx = np.asarray(m["cov_ctx"], dtype=float) + expected_design = np.asarray(m["expected_design_cov"], dtype=float) + + cov = M.Covariate( + time=time, + data=np.column_stack([stim, ctx]), + name="cov", + labels=["stim", "ctx1", "ctx2"], + ) + cov_mat = np.asarray(cov.getSigRep(), dtype=float) + assert_same_shape(cov_mat, expected_design) + assert_allclose_scaled(cov_mat, expected_design, rtol=0.0, atol=1e-12) + + sub = cov.getSubSignal(["stim"]) + assert_same_shape(np.asarray(sub.getSigRep(), dtype=float), stim.reshape(-1, 1)) + + +def test_confidence_interval_contract_against_matlab_fixture() -> None: + m = _load_mat(Path("tests/parity/fixtures/matlab_gold/classes/ConfidenceInterval/basic.mat")) + time = _vec(m, "time") + ci_data = np.asarray(m["ci_data"], dtype=float) + expected_width = _vec(m, "width") + expected_value = float(_vec(m, "ci_value")[0]) + + ci = M.ConfidenceInterval(time=time, lower=ci_data[:, 0], upper=ci_data[:, 1], level=expected_value) + ci.setColor("r") + ci.setValue(expected_value) + + got_width = np.asarray(ci.getWidth(), dtype=float).reshape(-1) + assert_same_shape(got_width, expected_width) + assert_allclose_scaled(got_width, expected_width, rtol=0.0, atol=1e-12) + assert np.isclose(ci.level, expected_value) + + +def test_events_history_nspiketrain_nstcoll_contracts_against_matlab_fixtures() -> None: + m_events = _load_mat(Path("tests/parity/fixtures/matlab_gold/EventsExamples_gold.mat")) + event_times = _vec(m_events, "event_times") + subset_start = float(_vec(m_events, "subset_start")[0]) + subset_end = float(_vec(m_events, "subset_end")[0]) + expected_subset = _vec(m_events, "expected_subset_times") + + ev = M.Events(times=event_times) + ev_subset = ev.subset(subset_start, subset_end) + assert_allclose_scaled(np.asarray(ev_subset.times, dtype=float), expected_subset, rtol=0.0, atol=1e-12) + + m_hist = _load_mat(Path("tests/parity/fixtures/matlab_gold/HistoryExamples_gold.mat")) + hist = M.History(_vec(m_hist, "bin_edges_hist")) + h = np.asarray( + hist.computeHistory(_vec(m_hist, "spike_times_hist"), _vec(m_hist, "time_grid_hist")), + dtype=float, + ) + expected_h = np.asarray(m_hist["H_expected_hist"], dtype=float) + assert_same_shape(h, expected_h) + assert_allclose_scaled(h, expected_h, rtol=0.0, atol=1e-12) + + m_coll = _load_mat(Path("tests/parity/fixtures/matlab_gold/nstCollExamples_gold.mat")) + t_start = float(_vec(m_coll, "t_start_coll")[0]) + t_end = float(_vec(m_coll, "t_end_coll")[0]) + bin_size = float(_vec(m_coll, "bin_size_coll")[0]) + st1 = M.nspikeTrain(spike_times=_vec(m_coll, "spike_times_1"), t_start=t_start, t_end=t_end, name="u1") + st2 = M.nspikeTrain(spike_times=_vec(m_coll, "spike_times_2"), t_start=t_start, t_end=t_end, name="u2") + coll = M.nstColl([st1, st2]) + _t, count_mat = coll.getBinnedMatrix(bin_size, "count") + expected_count = np.asarray(m_coll["expected_count_matrix"], dtype=float) + assert_same_shape(count_mat, expected_count) + assert_allclose_scaled(count_mat, expected_count, rtol=0.0, atol=1e-12) + assert np.isclose(coll.getFirstSpikeTime(), float(_vec(m_coll, "expected_first_spike")[0])) + assert np.isclose(coll.getLastSpikeTime(), float(_vec(m_coll, "expected_last_spike")[0])) + + +def test_covcoll_trial_trialconfig_configcoll_contracts_against_matlab_fixtures() -> None: + m_cov = _load_mat(Path("tests/parity/fixtures/matlab_gold/CovCollExamples_gold.mat")) + time = _vec(m_cov, "time_cov") + stim = _vec(m_cov, "cov_stim") + ctx = np.asarray(m_cov["cov_ctx"], dtype=float) + + cov1 = M.Covariate(time=time, data=stim, name="stim", labels=["stim"]) + cov2 = M.Covariate(time=time, data=ctx, name="ctx", labels=["ctx1", "ctx2"]) + cov_coll = M.CovColl([cov1, cov2]) + design, labels = cov_coll.getDesignMatrix() + assert_same_shape(design, np.asarray(m_cov["expected_design_cov"], dtype=float)) + assert labels == ["stim", "ctx1", "ctx2"] + + m_trial = _load_mat(Path("tests/parity/fixtures/matlab_gold/TrialExamples_gold.mat")) + st = M.nspikeTrain( + spike_times=_vec(m_trial, "spike_times_trial"), + t_start=0.0, + t_end=1.0, + name="u1", + ) + trial = M.Trial(M.nstColl([st]), cov_coll) + _t_obs, y_obs, _x_obs = trial.getAlignedBinnedObservation( + binSize_s=float(_vec(m_trial, "bin_size_trial")[0]), + unitIndex=0, + mode="count", + ) + y_expected = _vec(m_trial, "expected_y_trial") + y_obs_vec = np.asarray(y_obs, dtype=float).reshape(-1) + assert_same_shape(y_obs_vec, y_expected) + assert_allclose_scaled(y_obs_vec, y_expected, rtol=0.0, atol=1e-12) + + m_tc = _load_mat(Path("tests/parity/fixtures/matlab_gold/classes/TrialConfig/basic.mat")) + tc = M.TrialConfig(covariateLabels=["stim"], Fs=float(_vec(m_tc, "tc_sample_rate")[0]), name=str(_str_list(m_tc["tc_name"])[0])) + assert np.isclose(tc.getSampleRate(), float(_vec(m_tc, "tc_sample_rate")[0])) + + m_cc = _load_mat(Path("tests/parity/fixtures/matlab_gold/classes/ConfigColl/basic.mat")) + cc = M.ConfigColl([tc, M.TrialConfig(covariateLabels=["ctx"], Fs=500.0, name="cfg2")]) + assert len(cc.getConfigs()) == int(round(float(_vec(m_cc, "num_configs")[0]))) + + +def test_cif_analysis_decoding_fitresult_fitsummary_contracts_against_matlab_fixtures() -> None: + m_cif = _load_mat(Path("tests/parity/fixtures/matlab_gold/classes/CIF/basic.mat")) + time = _vec(m_cif, "time") + lam = _vec(m_cif, "lambda_values") + dt = float(_vec(m_cif, "dt")[0]) + expected_counts = _vec(m_cif, "spike_counts") + + lambda_cov = M.Covariate(time=time, data=lam, name="Lambda", labels=["lambda"]) + np.random.seed(0) + coll = M.CIF.simulateCIFByThinningFromLambda(lambda_cov, int(expected_counts.size), dt) + counts = np.asarray([len(coll.getNST(i).spike_times) for i in range(int(expected_counts.size))], dtype=float) + # Stochastic realizations are deterministic under seed=0; allow a tiny tolerance. + assert_allclose_scaled(counts, expected_counts, rtol=0.0, atol=3.0) + + m_analysis = _load_mat(Path("tests/parity/fixtures/matlab_gold/AnalysisExamples_gold.mat")) + fit = M.Analysis.fitGLM( + X=np.asarray(m_analysis["X_analysis"], dtype=float), + y=_vec(m_analysis, "counts_analysis"), + fitType="poisson", + dt=float(_vec(m_analysis, "dt_analysis")[0]), + ) + expected_b = _vec(m_analysis, "b_analysis") + got_b = np.concatenate(([fit.intercept], np.asarray(fit.coefficients, dtype=float).reshape(-1))) + assert_allclose_scaled(got_b, expected_b, rtol=0.0, atol=0.5) + + m_dec = _load_mat(Path("tests/parity/fixtures/matlab_gold/DecodingExample_gold.mat")) + decoded, posterior = M.DecodingAlgorithms.decodeStatePosterior( + spike_counts=np.asarray(m_dec["spike_counts_dec"], dtype=float), + tuning_rates=np.asarray(m_dec["tuning_dec"], dtype=float), + transition=np.asarray(m_dec["transition_dec"], dtype=float), + ) + assert np.array_equal(decoded, np.asarray(m_dec["expected_decoded_dec"], dtype=int).reshape(-1)) + assert_same_shape(posterior, np.asarray(m_dec["expected_posterior_dec"], dtype=float)) + + m_fr = _load_mat(Path("tests/parity/fixtures/matlab_gold/classes/FitResult/basic.mat")) + fr = M.FitResult( + coefficients=np.array([0.1], dtype=float), + intercept=0.0, + fit_type="poisson", + log_likelihood=float(_vec(m_fr, "fit_logll")[0]), + n_samples=3, + n_parameters=1, + parameter_labels=["Baseline"], + ) + fr.setKSStats(np.asarray(_vec(m_fr, "fit_ks_stat"), dtype=float)) + fr.setNeuronName(str(int(round(float(_vec(m_fr, "fit_neuron_number")[0]))))) + assert np.isfinite(fr.getAIC()) + assert np.isfinite(fr.getBIC()) + + m_fs = _load_mat(Path("tests/parity/fixtures/matlab_gold/classes/FitResSummary/basic.mat")) + fs = M.FitResSummary([fr]) + assert len(fs.results) == int(round(float(_vec(m_fs, "summary_num_neurons")[0]))) + assert fs.bestByAIC() is fr diff --git a/tests/test_class_equivalence_artifacts.py b/tests/test_class_equivalence_artifacts.py new file mode 100644 index 00000000..e196cea7 --- /dev/null +++ b/tests/test_class_equivalence_artifacts.py @@ -0,0 +1,57 @@ +from __future__ import annotations + +import json +from pathlib import Path + + +def test_class_equivalence_inventory_exists_and_has_full_class_coverage() -> None: + inventory_path = Path("parity/class_equivalence_inventory.json") + assert inventory_path.exists(), "Missing parity/class_equivalence_inventory.json" + + payload = json.loads(inventory_path.read_text(encoding="utf-8")) + rows = payload.get("class_rows", []) + assert len(rows) >= 16 + + statuses = {str(row.get("status", "")) for row in rows} + assert "gap_missing_mapping" not in statuses + + required = { + "SignalObj", + "Covariate", + "ConfidenceInterval", + "Events", + "History", + "nspikeTrain", + "nstColl", + "CovColl", + "TrialConfig", + "ConfigColl", + "Trial", + "CIF", + "Analysis", + "FitResult", + "FitResSummary", + "DecodingAlgorithms", + } + covered = {str(row["matlab_class"]) for row in rows} + assert required.issubset(covered) + + summary = payload.get("summary", {}) + assert summary.get("required_classes_missing_from_matlab_scan", []) == [] + assert summary.get("classes_missing_mapping", []) == [] + + +def test_class_equivalence_report_exists_and_is_clean() -> None: + report_path = Path("parity/class_equivalence_report.json") + assert report_path.exists(), "Missing parity/class_equivalence_report.json" + + payload = json.loads(report_path.read_text(encoding="utf-8")) + summary = payload.get("summary", {}) + assert int(summary.get("total_classes", 0)) >= 16 + assert int(summary.get("gap_classes", 1)) == 0 + assert bool(summary.get("required_class_coverage_ok", False)) + + top_methods = payload.get("top_critical_methods_tested", {}) + assert len(top_methods) >= 16 + for cls, methods in top_methods.items(): + assert methods, f"missing critical methods for {cls}" diff --git a/tools/parity/generate_class_equivalence_inventory.py b/tools/parity/generate_class_equivalence_inventory.py new file mode 100644 index 00000000..bc6002de --- /dev/null +++ b/tools/parity/generate_class_equivalence_inventory.py @@ -0,0 +1,492 @@ +#!/usr/bin/env python3 +"""Generate class-level MATLAB/Python equivalence inventory and summary report.""" + +from __future__ import annotations + +import argparse +import importlib +import inspect +import json +import re +import sys +from collections import defaultdict +from datetime import datetime, timezone +from pathlib import Path +from typing import Any + +import yaml + + +CLASSDEF_RE = re.compile(r"^\s*classdef\s+([A-Za-z]\w*)(?:\s*<\s*([^\n%]+))?", flags=re.IGNORECASE) +METHODS_BLOCK_RE = re.compile(r"^\s*methods(?:\s*\(([^)]*)\))?\s*$", flags=re.IGNORECASE) +PROPERTIES_BLOCK_RE = re.compile(r"^\s*properties(?:\s*\(([^)]*)\))?\s*$", flags=re.IGNORECASE) +FUNCTION_RE = re.compile( + r"^\s*function\b(?:\s+\[[^\]]*\]\s*=|\s+[^=\n\r]+\s*=)?\s*([A-Za-z]\w*)\s*(?:\(([^)]*)\))?", + flags=re.IGNORECASE, +) +PROPERTY_RE = re.compile(r"^\s*([A-Za-z]\w*)") +ACCESS_RE = re.compile(r"access\s*=\s*([A-Za-z]+)", flags=re.IGNORECASE) + + +REQUIRED_CLASSES = [ + "SignalObj", + "Covariate", + "ConfidenceInterval", + "Events", + "History", + "nspikeTrain", + "nstColl", + "CovColl", + "TrialConfig", + "ConfigColl", + "Trial", + "CIF", + "Analysis", + "FitResult", + "FitResSummary", + "DecodingAlgorithms", +] + + +def parse_args() -> argparse.Namespace: + parser = argparse.ArgumentParser(description=__doc__) + parser.add_argument("--repo-root", type=Path, default=Path(__file__).resolve().parents[2]) + parser.add_argument("--matlab-root", type=Path, required=True) + parser.add_argument("--method-mapping", type=Path, default=Path("parity/method_mapping.yaml")) + parser.add_argument("--method-exclusions", type=Path, default=Path("parity/method_exclusions.yml")) + parser.add_argument("--class-contracts", type=Path, default=Path("parity/class_contracts.yml")) + parser.add_argument("--fixture-spec", type=Path, default=Path("parity/class_fixture_export_spec.yml")) + parser.add_argument( + "--behavior-contracts", + type=Path, + action="append", + default=[Path("tests/parity/class_behavior_specs.yml"), Path("tests/parity/compat_behavior_specs.yml")], + ) + parser.add_argument("--out-inventory", type=Path, default=Path("parity/class_equivalence_inventory.json")) + parser.add_argument("--out-report", type=Path, default=Path("parity/class_equivalence_report.json")) + return parser.parse_args() + + +def _load_yaml(path: Path) -> dict[str, Any]: + return yaml.safe_load(path.read_text(encoding="utf-8")) + + +def _signature_text(callable_obj: Any) -> str: + try: + return str(inspect.signature(callable_obj)) + except (TypeError, ValueError): + return "(unavailable)" + + +def _public_python_surface(obj: Any) -> dict[str, Any]: + methods: dict[str, str] = {} + properties: list[str] = [] + fields: list[str] = [] + + for name, member in inspect.getmembers(obj): + if name.startswith("_"): + continue + raw = inspect.getattr_static(obj, name) + if isinstance(raw, property): + properties.append(name) + continue + if inspect.isroutine(member): + methods[name] = _signature_text(member) + + dataclass_fields = getattr(obj, "__dataclass_fields__", {}) + for name in sorted(dataclass_fields): + if not name.startswith("_"): + fields.append(name) + + init_sig = "(unavailable)" + if hasattr(obj, "__init__"): + init_sig = _signature_text(obj.__init__) + + return { + "constructor_signature": init_sig, + "methods": dict(sorted(methods.items())), + "properties": sorted(set(properties)), + "fields": sorted(set(fields)), + } + + +def _parse_attrs(attrs: str | None) -> tuple[str, bool]: + if not attrs: + return "public", False + access_match = ACCESS_RE.search(attrs) + access = access_match.group(1).lower() if access_match else "public" + is_static = "static" in attrs.lower() + return access, is_static + + +def _parse_matlab_class(path: Path) -> dict[str, Any]: + text = path.read_text(encoding="utf-8", errors="ignore") + lines = text.splitlines() + + class_name = path.stem + superclass = "" + class_match = None + for line in lines: + class_match = CLASSDEF_RE.match(line) + if class_match: + class_name = class_match.group(1) + superclass = (class_match.group(2) or "").strip() + break + + properties: list[dict[str, Any]] = [] + methods: list[dict[str, Any]] = [] + + in_properties = False + current_prop_access = "public" + current_methods_access = "public" + current_methods_static = False + in_methods = False + + for idx, raw in enumerate(lines, start=1): + line = raw.rstrip() + stripped = line.strip() + if not stripped or stripped.startswith("%"): + continue + + pm = PROPERTIES_BLOCK_RE.match(line) + if pm: + in_properties = True + in_methods = False + current_prop_access, _ = _parse_attrs(pm.group(1)) + continue + + mm = METHODS_BLOCK_RE.match(line) + if mm: + in_methods = True + in_properties = False + current_methods_access, current_methods_static = _parse_attrs(mm.group(1)) + continue + + if stripped == "end": + if in_properties: + in_properties = False + # Keep method block mode sticky across nested function `end`. + continue + + if in_properties: + prop_match = PROPERTY_RE.match(line) + if prop_match: + prop_name = prop_match.group(1) + if prop_name.lower() not in {"properties", "methods", "classdef", "end"}: + properties.append( + { + "name": prop_name, + "access": current_prop_access, + "line": idx, + } + ) + continue + + func_match = FUNCTION_RE.match(line) + if func_match and in_methods: + name = func_match.group(1) + args_raw = (func_match.group(2) or "").strip() + args = [a.strip() for a in args_raw.split(",") if a.strip()] if args_raw else [] + methods.append( + { + "name": name, + "args": args, + "line": idx, + "access": current_methods_access, + "static": current_methods_static, + } + ) + + constructor = next((m for m in methods if m["name"] == class_name), None) + public_methods = [m["name"] for m in methods if m["access"] not in {"private"}] + private_methods = [m["name"] for m in methods if m["access"] == "private"] + + return { + "matlab_class": class_name, + "matlab_file": str(path), + "superclass": superclass, + "constructor": constructor or {"name": class_name, "args": [], "line": None, "access": "public", "static": False}, + "properties": properties, + "methods": methods, + "public_methods": sorted(dict.fromkeys(public_methods)), + "private_methods": sorted(dict.fromkeys(private_methods)), + } + + +def _contract_members(paths: list[Path]) -> dict[str, set[str]]: + out: dict[str, set[str]] = defaultdict(set) + for path in paths: + if not path.exists(): + continue + payload = _load_yaml(path) + for cls in payload.get("classes", []): + name = str(cls["matlab_class"]) + for contract in cls.get("contracts", []): + out[name].add(str(contract["member"])) + return out + + +def _fixture_lookup(fixture_spec: dict[str, Any]) -> dict[str, dict[str, str]]: + out: dict[str, dict[str, str]] = {} + for row in fixture_spec.get("classes", []): + out[str(row["matlab_class"])] = { + "fixture_path": str(row["fixture_path"]), + "generator": str(row["generator"]), + } + return out + + +def _excluded_methods(path: Path) -> dict[str, set[str]]: + if not path.exists(): + return {} + payload = _load_yaml(path) + out: dict[str, set[str]] = {} + for row in payload.get("classes", []): + cls = str(row.get("matlab_class", "")) + if not cls: + continue + out[cls] = {str(method) for method in row.get("methods", [])} + return out + + +def _load_python_class(path: str) -> Any: + module, attr = path.rsplit(".", 1) + return getattr(importlib.import_module(module), attr) + + +def build_inventory(args: argparse.Namespace) -> tuple[dict[str, Any], dict[str, Any]]: + repo_root = args.repo_root.resolve() + matlab_root = args.matlab_root.resolve() + mapping = _load_yaml((repo_root / args.method_mapping).resolve()) + class_contracts = _load_yaml((repo_root / args.class_contracts).resolve()) + fixture_spec = _load_yaml((repo_root / args.fixture_spec).resolve()) + exclusions = _excluded_methods((repo_root / args.method_exclusions).resolve()) + behavior_contracts = _contract_members([(repo_root / p).resolve() for p in args.behavior_contracts]) + + src_root = repo_root / "src" + if str(src_root) not in sys.path: + sys.path.insert(0, str(src_root)) + + matlab_files = sorted(matlab_root.glob("*.m")) + matlab_classes = {} + for f in matlab_files: + text = f.read_text(encoding="utf-8", errors="ignore") + if CLASSDEF_RE.search(text): + entry = _parse_matlab_class(f) + matlab_classes[entry["matlab_class"]] = entry + + mapping_rows = {str(row["matlab_class"]): row for row in mapping.get("classes", [])} + contract_rows = {str(row["matlab_class"]): row for row in class_contracts.get("classes", [])} + fixture_rows = _fixture_lookup(fixture_spec) + + class_rows: list[dict[str, Any]] = [] + missing_classes: list[str] = [] + missing_mappings: list[str] = [] + missing_fixtures: list[str] = [] + missing_method_symbols: dict[str, list[str]] = {} + + for matlab_class in sorted(matlab_classes): + matlab_meta = matlab_classes[matlab_class] + map_row = mapping_rows.get(matlab_class) + contract_row = contract_rows.get(matlab_class) + fixture_row = fixture_rows.get(matlab_class) + + if map_row is None: + missing_mappings.append(matlab_class) + class_rows.append( + { + "matlab_class": matlab_class, + "status": "gap_missing_mapping", + "matlab": matlab_meta, + } + ) + continue + + python_class_path = str(map_row["python_class"]) + compat_class_path = str(map_row["compat_class"]) + alias_methods = {str(k): str(v) for k, v in map_row.get("alias_methods", {}).items()} + + py_cls = _load_python_class(python_class_path) + compat_cls = _load_python_class(compat_class_path) + py_surface = _public_python_surface(py_cls) + compat_surface = _public_python_surface(compat_cls) + + py_members = set(py_surface["methods"]).union(py_surface["properties"]).union(py_surface["fields"]) + compat_members = set(compat_surface["methods"]).union(compat_surface["properties"]).union(compat_surface["fields"]) + + method_rows: list[dict[str, Any]] = [] + missing_for_class: list[str] = [] + for matlab_method in matlab_meta["public_methods"]: + mapped = alias_methods.get(matlab_method, matlab_method) + in_python = mapped in py_members + in_compat = mapped in compat_members + symbol_ok = in_python or in_compat + is_excluded = matlab_method in exclusions.get(matlab_class, set()) + if (not symbol_ok) and (not is_excluded): + missing_for_class.append(matlab_method) + method_rows.append( + { + "matlab_method": matlab_method, + "mapped_member": mapped, + "mapped_via_alias": matlab_method in alias_methods, + "present_in_python_surface": in_python, + "present_in_compat_surface": in_compat, + "excluded_method": is_excluded, + "covered_by_behavior_contract": mapped in behavior_contracts.get(matlab_class, set()), + "covered_by_class_contract": mapped in set(contract_row.get("key_methods", [])) if contract_row else False, + } + ) + + if missing_for_class: + missing_method_symbols[matlab_class] = missing_for_class + + fixture_path = "" + fixture_exists = False + fixture_generator = "" + if fixture_row: + fixture_path = fixture_row["fixture_path"] + fixture_generator = fixture_row["generator"] + fixture_exists = (repo_root / fixture_path).exists() + if not fixture_exists: + missing_fixtures.append(matlab_class) + else: + missing_fixtures.append(matlab_class) + + constructor_contract = {} + if contract_row is not None: + constructor_contract = { + "python_class": str(contract_row.get("python_class", "")), + "compat_class": str(contract_row.get("compat_class", "")), + "fixture_path": str(contract_row.get("fixture_path", "")), + "key_methods": list(contract_row.get("key_methods", [])), + } + + status = "verified" + if missing_for_class: + status = "partial_missing_method_symbols" + if not fixture_exists: + status = "partial_missing_fixture" + + class_rows.append( + { + "matlab_class": matlab_class, + "status": status, + "matlab": matlab_meta, + "mapping": { + "python_class": python_class_path, + "compat_class": compat_class_path, + "alias_methods": alias_methods, + }, + "python": py_surface, + "compat": compat_surface, + "fixture": { + "path": fixture_path, + "exists": fixture_exists, + "generator": fixture_generator, + }, + "class_contract": constructor_contract, + "method_rows": method_rows, + } + ) + + for required in REQUIRED_CLASSES: + if required not in matlab_classes: + missing_classes.append(required) + + inventory = { + "generated_at_utc": datetime.now(timezone.utc).isoformat(), + "matlab_root": str(matlab_root), + "python_root": str(repo_root), + "required_classes": REQUIRED_CLASSES, + "class_rows": class_rows, + "summary": { + "total_matlab_classes": len(matlab_classes), + "required_classes_missing_from_matlab_scan": sorted(missing_classes), + "classes_missing_mapping": sorted(missing_mappings), + "classes_missing_fixtures": sorted(missing_fixtures), + "classes_with_missing_method_symbols": sorted(missing_method_symbols.keys()), + }, + } + + verified = [row for row in class_rows if row["status"] == "verified"] + partial = [row for row in class_rows if row["status"].startswith("partial_")] + gaps = [row for row in class_rows if row["status"].startswith("gap_")] + + top_methods = {} + for row in class_rows: + cls = row["matlab_class"] + key_methods = row.get("class_contract", {}).get("key_methods", []) or [] + if key_methods: + top_methods[cls] = key_methods[:10] + else: + top_methods[cls] = [m["matlab_method"] for m in row["method_rows"][:10]] + + remaining_issues: list[dict[str, Any]] = [] + for cls in sorted(missing_method_symbols): + remaining_issues.append( + { + "matlab_class": cls, + "issue": "missing_method_symbol", + "missing_methods": sorted(missing_method_symbols[cls]), + } + ) + for cls in sorted(missing_fixtures): + remaining_issues.append( + { + "matlab_class": cls, + "issue": "missing_fixture", + "repro": f"python tools/parity/export_matlab_gold_fixtures.py --matlab-root {matlab_root}", + } + ) + for cls in sorted(missing_mappings): + remaining_issues.append( + { + "matlab_class": cls, + "issue": "missing_mapping", + "repro": "Update parity/method_mapping.yaml with python_class/compat_class mapping.", + } + ) + + report = { + "generated_at_utc": datetime.now(timezone.utc).isoformat(), + "summary": { + "verified_classes": len(verified), + "partial_classes": len(partial), + "gap_classes": len(gaps), + "total_classes": len(class_rows), + "required_class_coverage_ok": len(missing_classes) == 0, + }, + "top_critical_methods_tested": top_methods, + "remaining_issues": remaining_issues, + } + return inventory, report + + +def _write_json(path: Path, payload: dict[str, Any]) -> None: + path.parent.mkdir(parents=True, exist_ok=True) + path.write_text(json.dumps(payload, indent=2, sort_keys=True) + "\n", encoding="utf-8") + + +def main() -> int: + args = parse_args() + inventory, report = build_inventory(args) + + repo_root = args.repo_root.resolve() + out_inventory = (repo_root / args.out_inventory).resolve() + out_report = (repo_root / args.out_report).resolve() + _write_json(out_inventory, inventory) + _write_json(out_report, report) + + print(f"Wrote class inventory: {out_inventory}") + print(f"Wrote class report: {out_report}") + print( + "Summary: " + f"{report['summary']['verified_classes']} verified, " + f"{report['summary']['partial_classes']} partial, " + f"{report['summary']['gap_classes']} gaps" + ) + return 0 + + +if __name__ == "__main__": + raise SystemExit(main())