Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions targetFunctions/common/resampleLayers/adaptive.m
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@
%nPoints = 20;
%minAngle = 0.8*pi;
minSignal = 0.2; % units normalized to data range
minLength = 0; % units normalized to data range
minLength = 0.005; % units normalized to data range
maxLength = Inf; % units normalized to data range
maxArea = 5e-4; % units normalized to data range

Expand Down Expand Up @@ -204,7 +204,7 @@
% n = n+2;
% case 'minlength'
% minLength = varargin{n+1};
% thresholdingLength = true;
thresholdingLength = true;
% n = n+2;
% case 'minsignal'
% minSignal = varargin{n+1};
Expand Down Expand Up @@ -286,14 +286,14 @@
% triangle side is a segment, which can be split or not depending on the
% refinement parameters.
segmentsToSplit = [trianglesToRefine; false] | [false; trianglesToRefine];
% if thresholdingLength
% dataSegments = diff(dataPoints(:,1:2));
% normalizedSegments = bsxfun(@rdivide, dataSegments, dataBoxSize);
% segmentsLengthNormalized = hypot(normalizedSegments(:,1), normalizedSegments(:,2));
% tooLongSegments = segmentsLengthNormalized > maxLength;
% longEnoughSegments = segmentsLengthNormalized > minLength;
% segmentsToSplit = (segmentsToSplit | tooLongSegments) & longEnoughSegments;
% end
if thresholdingLength
dataSegments = diff(dataPoints(:,1:2));
normalizedSegments = bsxfun(@rdivide, dataSegments, dataBoxSize);
segmentsLengthNormalized = hypot(normalizedSegments(:,1), normalizedSegments(:,2));
tooLongSegments = segmentsLengthNormalized > maxLength;
longEnoughSegments = segmentsLengthNormalized > minLength;
segmentsToSplit = (segmentsToSplit | tooLongSegments) & longEnoughSegments;
end
% if thresholdingSignal
% segmentsCenters = (dataPoints(1:end-1,2)+dataPoints(2:end,2))/2;
% centerAboveThreshold = segmentsCenters > minSignal * max(abs(dataPoints(:,2)));
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified tests/domainsTFReflectivityCalculation/domainsCustomXYInputs.mat
Binary file not shown.
Binary file not shown.
Binary file modified tests/domainsTFReflectivityCalculation/domainsCustomXYTFParams.mat
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/absorptionInputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/absorptionOutputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/absorptionTFParams.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/customLayersInputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/customLayersOutputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/customLayersTFParams.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/customXYInputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/customXYOutputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/customXYTFParams.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/standardLayersInputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/standardLayersOutputs.mat
Binary file not shown.
Binary file modified tests/normalTFReflectivityCalculation/standardLayersTFParams.mat
Binary file not shown.
Binary file modified tests/testCommonFunctions/adaptiveOutputs.mat
Binary file not shown.
Binary file modified tests/testCommonFunctions/resampleLayersOutputs.mat
Binary file not shown.
Binary file modified tests/testProjectConversion/DSPCBilayerProjectClass.mat
Binary file not shown.
Binary file modified tests/testProjectConversion/monolayerVolumeModelProjectClass.mat
Binary file not shown.
Loading