plateform stringclasses 1
value | repo_name stringlengths 13 113 | name stringlengths 3 74 | ext stringclasses 1
value | path stringlengths 12 229 | size int64 23 843k | source_encoding stringclasses 9
values | md5 stringlengths 32 32 | text stringlengths 23 843k |
|---|---|---|---|---|---|---|---|---|
github | hymanc/MRSLAM-master | viewLsr.m | .m | MRSLAM-master/Code/featureSLAM/vicpark/viewLsr.m | 1,720 | utf_8 | a33ae9fa578279c02de98c06364d5299 | function ViewLsr
%function ViewLsr(FileName,figu,dttt)
% Jose. ACFR. 1999.
FileName = 'aa3_lsr2.mat' ;
dttt = 0.2 ;
figu = 1 ;
global AAr;
AAr = [0:360]*pi/360 ;
load(FileName) ;
L = size(LASER) ; L=L(1) ;
Time = double(TLsr) ; clear TLsr;
CAAA = cos(AAr) ;
SAAA = sin(AAr) ;
global pCircles ;
nc = 9 ; aaa = [0:nc... |
github | hymanc/MRSLAM-master | runvp.m | .m | MRSLAM-master/Code/featureSLAM/vicpark/runvp.m | 5,258 | utf_8 | 1de95f136aa4926c9282ca4ecc693b82 | function runvp(nSteps,pauseLen,makeVideo)
global Param;
global State;
global Data;
if ~exist('nSteps','var') || isempty(nSteps)
nSteps = inf;
end
if ~exist('pauseLen','var')
pauseLen = 0; % seconds
end
% Attempt to open video file
%if makeVideo
% try
% votype = 'VideoWriter';
% vo = VideoWr... |
github | hymanc/MRSLAM-master | scanAndFill95percent.m | .m | MRSLAM-master/CustomMapAndModel/scanAndFill95percent.m | 5,242 | utf_8 | 0196369dd389c1182e73c852af859a11 | function scanAndFill95percent()
close all;
%[x,y,theta]=MYpath();
OdometryModel='OdometryMotion';
THEIMAGE='Test5.png';
[MAP,PIXDIM]=getTheMAP(THEIMAGE);
SENSOR.RADIUS=50; %Limit of the sensor
SENSOR.AOS=[-90 90]*pi/180; %Sensor angle of sensitivity
SENSOR.AOSDIV=180; ... |
github | hymanc/MRSLAM-master | scanAndFill.m | .m | MRSLAM-master/CustomMapAndModel/scanAndFill.m | 6,572 | utf_8 | b183afb54f5ac583a084d9ef14aeb94b | function scanAndFill()
close all;
%[x,y,theta]=MYpath();
OdometryModel='OdometryMotion';
THEIMAGE='Test5.png';
[MAP,PIXDIM]=getTheMAP(THEIMAGE);
SENSOR.RADIUS=75; %Limit of the sensor
SENSOR.AOS=[-90 90]*pi/180; %Sensor angle of sensitivity
SENSOR.AOSDIV=180; %Di... |
github | hymanc/MRSLAM-master | measurement_model_prob.m | .m | MRSLAM-master/Clean/Tools/measurement_model_prob.m | 2,404 | utf_8 | 92ec9c512d72efca522be7dccd62c9b7 | function w=measurement_model_prob(scan,pose,MAP,SENSOR,Q,R,gridSize,offset)
logica=MAP>prob_to_log_odds(0.5);
r=rayTrace(pose(1)-offset(1),pose(2)-offset(2),pose(3),logica,SENSOR);
%r=rayTrace(pose(1),pose(2),pose(3),logica,SENSOR);
smap=size(MAP);
robTrans = v2t(pose);
robPoseMapFra... |
github | hymanc/MRSLAM-master | bresenham.m | .m | MRSLAM-master/Clean/COTs/bresenham.m | 1,372 | utf_8 | 43617a124d44fcb42dde3c64c6ae1708 | function [X,Y] = bresenham(mycoords)
% BRESENHAM: Generate a line profile of a 2d image
% using Bresenham's algorithm
% [X,Y] = bresenham(mycoords)
%
% - For a demo purpose, try >> bresenham();
%
% - mycoords is coordinate of the form: [x1, y1; x2, y2]
% which can be obtained from ginput function
... |
github | hymanc/MRSLAM-master | readAlbertB.m | .m | MRSLAM-master/Data/readAlbertB.m | 2,221 | utf_8 | c0de595fd7189e5b7f808462619f26a0 | function [rad,pose,odom,t]=readAlbertB()
filename='../Data/albertB.img.sm.log';
fff=fopen(filename,'r');
ODOM='ODOM';
nODOM=numel(ODOM);
FLASER='FLASER';
nFLASER=numel(FLASER);
str=[];
rad=[];
pose=[];
odom=[];
t=[];
odomodom=[];
inputsodom=[];
todom=[]... |
github | hymanc/MRSLAM-master | viewLsr.m | .m | MRSLAM-master/Data/vicpark/viewLsr.m | 1,665 | utf_8 | 225732358882556faf2ae446fc248530 | function ViewLsr
%function ViewLsr(FileName,figu,dttt)
% Jose. ACFR. 1999.
FileName = 'aa3_lsr2.mat' ;
dttt = 0.2 ;
figu = 1 ;
global AAr;
AAr = [0:360]*pi/360 ;
load(FileName) ;
L = size(LASER) ; L=L(1) ;
Time = double(TLsr) ; clear TLsr;
CAAA = cos(AAr) ;
SAAA = sin(AAr) ;
global pCircles ;
nc = 9 ; aaa = [0:nc... |
github | robotology/icub-tests-master | encoderConsistencyPlotAll.m | .m | icub-tests-master/suites/contexts/scripts/encoderConsistencyPlotAll.m | 1,672 | utf_8 | 8fb9b5d537c3619e0d80c5509f7a6d54 | % iCub Robot Unit Tests (Robot Testing Framework)
%
% Copyright (C) 2015-2019 Istituto Italiano di Tecnologia (IIT)
%
% This library is free software; you can redistribute it and/or
% modify it under the terms of the GNU Lesser General Public
% License as published by the Free Software Foundation; either
% version 2.1 ... |
github | robotology/icub-tests-master | oneFile_plot.m | .m | icub-tests-master/suites/contexts/scripts/oneFile_plot.m | 1,189 | utf_8 | 3189bf1aa889ecae01d35380e7d4230a | % iCub Robot Unit Tests (Robot Testing Framework)
%
% Copyright (C) 2015-2019 Istituto Italiano di Tecnologia (IIT)
%
% This library is free software; you can redistribute it and/or
% modify it under the terms of the GNU Lesser General Public
% License as published by the Free Software Foundation; either
% version 2.1 ... |
github | robotology/icub-tests-master | torqueStiffDamp_plotAll.m | .m | icub-tests-master/suites/contexts/scripts/torqueStiffDamp_plotAll.m | 1,950 | utf_8 | 4eb77ee305d34c0297b535275c7bec1b | % iCub Robot Unit Tests (Robot Testing Framework)
%
% Copyright (C) 2015-2019 Istituto Italiano di Tecnologia (IIT)
%
% This library is free software; you can redistribute it and/or
% modify it under the terms of the GNU Lesser General Public
% License as published by the Free Software Foundation; either
% version 2.1 ... |
github | robotology/icub-tests-master | torqueStiffDamp_plot.m | .m | icub-tests-master/suites/contexts/scripts/torqueStiffDamp_plot.m | 1,141 | utf_8 | c21ddde5c7c989033d769d673fbf76d3 | % iCub Robot Unit Tests (Robot Testing Framework)
%
% Copyright (C) 2015-2019 Istituto Italiano di Tecnologia (IIT)
%
% This library is free software; you can redistribute it and/or
% modify it under the terms of the GNU Lesser General Public
% License as published by the Free Software Foundation; either
% version 2.1 ... |
github | gsmafra/lee-2009-audio-master | get_spectrogram_orig.m | .m | lee-2009-audio-master/code/get_spectrogram_orig.m | 953 | utf_8 | e1e47ad68735cb56ffd1477190ba3035 | % octave
function [P padding] = get_spectrogram_orig(Y, padding, fs)
if ~exist('fs', 'var')
warning('sample rate was not specified: using the rate for TIMIT instead.. If the audio file is not from TIMIT corpus, you should set this value correctly!!');
fs = get_constant('TimitSampleRate');
end
wintime = get_cons... |
github | gsmafra/lee-2009-audio-master | concatenate_speech_data.m | .m | lee-2009-audio-master/code/concatenate_speech_data.m | 427 | utf_8 | ed227ad77e782a5fd0e75d00df44ce90 | % octave.
function [Pconc startframe_list] = concatenate_speech_data(Pall, idx)
count = 0;
for i=1:length(idx)
count = count + size(Pall{idx(i)},2);
end
numfeat = size(Pall{1},1);
Pconc = zeros(numfeat, count);
startframe_list = [];
count = 0;
for i=1:length(idx)
startframe_list(i) = count+1;
Pconc(:, ... |
github | gsmafra/lee-2009-audio-master | vec.m | .m | lee-2009-audio-master/code/vec.m | 47 | utf_8 | a52140cd30e943a42bc6532771e114cf | % octave
function y = vec(x)
y = x(:);
return
|
github | gsmafra/lee-2009-audio-master | subvec.m | .m | lee-2009-audio-master/code/subvec.m | 58 | utf_8 | 12fb38108b4a2cbde70745c10bce0c46 | % octave
function y = subvec(x, idx)
y = x(idx);
return
|
github | brain-life/encode-master | demo_virtual_lesion.m | .m | encode-master/scripts/demos/demo_virtual_lesion.m | 12,328 | utf_8 | 490e5344bd1bf7e3410cf47ff96c6967 | function [fh, fe] = demo_virtual_lesion()
% Example of Virtual Lesion computation using the multidimensional encoding
% model and the LiFE method.
%
% This demo function illustrates how to perfomr a virtual lesion by using
% the multidimensional connectome encoding framework.
%
% The demo reproduces some of the result... |
github | brain-life/encode-master | demo_connectome_data_comparison.m | .m | encode-master/scripts/demos/demo_connectome_data_comparison.m | 17,247 | utf_8 | f0491e706b233191f580ae54f001da2e | function [fh, fe] = demo_connectome_data_comparison()
% This demo characterizes connectomes obtained with different data sets and
% tracking methods.
%
% It compares two fundamental properties of a connectome density and error
% in predicting the diffusion signal. It shows how these conenctome
% properties depend fro... |
github | brain-life/encode-master | demo_LiFE.m | .m | encode-master/scripts/demos/demo_LiFE.m | 17,310 | utf_8 | bd51cad0ea995a42703fdc7408e8ea07 | function [fh, fe] = demo_LiFE()
% Example of initialization and fitting of the LiFE model
%
% This demo function illustrates how to:
% - A - Set up a LiFE structure, identified as 'fe' (fascicle evaluation) in
% the code below. This model contains a prediction of the diffusion
% measurements in each white-matter vox... |
github | brain-life/encode-master | demo_connectome_encoding.m | .m | encode-master/scripts/demos/demo_connectome_encoding.m | 9,303 | utf_8 | 31a1abd21958f8925a39590825b110e9 | function [fh, fe] = demo_connectome_encoding()
%% Encode a connectome in multidimensional array (also called tensor).
%
% This demo illustrates how to take a tractography file (a full-set of
% streamlines, also called 'fascicles') and associated diffusion-weighted
% imaging data (a NIFTI file plus BVEC/BVAL files used ... |
github | brain-life/encode-master | feConnectomeEncoding.m | .m | encode-master/life/fe/feConnectomeEncoding.m | 6,863 | utf_8 | b895d2a43300b033e52902dc1df53638 | function fe = feConnectomeEncoding(fe)
% Compute multiway decompositon model to predict directional diffusion in each voxel from fibers
%
% fe = feConnectomeBuildModel(fe)
%
% INPUTS: fe - An fe structure, see feCreate.m
%
% See also: feFitModel.m, feComputePredictedSignal.m
%
% Copyright (2020), Indiana U... |
github | brain-life/encode-master | feConnectomeStatistics.m | .m | encode-master/life/fe/feConnectomeStatistics.m | 5,970 | utf_8 | 4b7d6deea423a74019cca0bc39eab51b | function fe = feConnectomeStatistics(fe)
% Compute Curvature and Torsion of fibers
%
% Copyright (2015), Franco Pestilli (Indiana Univ.) - Cesar F. Caiafa (CONICET)
% email: pestillifranco@gmail.com and ccaiafa@gmail.com
%
if notDefined('fe'), error('LiFE (fe = feCreate) struct needed'); end
if ~isfield(fe,... |
github | brain-life/encode-master | FitFullModelSampleAllTractsGPU.m | .m | encode-master/life/compute/FitFullModelSampleAllTractsGPU.m | 10,210 | utf_8 | 41142c752702e6e404835771f5d2ee00 | function [fe, results] = FitFullModelSampleAllTracts(dwiFile, fgFileName, feFileName, L, p, n, alpha_v, alpha_f, lambda_1, lambda_2, fg_classification)
% INPUT
% dwFile: diffusion measurements
% fgFileName: Tractography file
% L: discretization parameter in ENCODE
% p: ... |
github | brain-life/encode-master | FitFullModelSampleVoxels_and_Fibers.m | .m | encode-master/life/compute/FitFullModelSampleVoxels_and_Fibers.m | 11,919 | utf_8 | 47d71e2facf0c8091b320f028f02c08a | function [fe, results] = FitFullModelSampleVoxels_and_Fibers(dwiFile, fgFileName, feFileName, L, p, n, m, alpha_v, alpha_f, lambda_1, lambda_2, fg_classification)
% INPUT
% dwFile: diffusion measurements
% fgFileName: Tractography file
% L: discretization parameter in ENCODE
%... |
github | brain-life/encode-master | FitFullModelSampleAllTracts.m | .m | encode-master/life/compute/FitFullModelSampleAllTracts.m | 11,418 | utf_8 | 349be223507e64cc17e129068afe3b66 | function [fe, results] = FitFullModelSampleAllTracts(dwiFile, fgFileName, feFileName, L, p, n, alpha_v, alpha_f, lambda_1, lambda_2, fg_classification)
% INPUT
% dwFile: diffusion measurements
% fgFileName: Tractography file
% L: discretization parameter in ENCODE
% p: ... |
github | brain-life/encode-master | FitFullModelSample.m | .m | encode-master/life/compute/FitFullModelSample.m | 7,946 | utf_8 | a6b42c53c067461aafbb08367ef75aa7 | function [fe, results] = FitFullModelSample(dwiFile, fgFileName, feFileName, L, p, n, alpha_v, alpha_f, lambda_a, lambda_r)
% INPUT
% dwFile: diffusion measurements
% fgFileName: Tractography file
% L: discretization parameter in ENCODE
% p: Training set rat... |
github | brain-life/encode-master | feGetAtoms.m | .m | encode-master/life/compute/feGetAtoms.m | 629 | utf_8 | bc4030cb4394f69eef62403a5d20f507 | % This function return the indices to the atoms having a particular spatial orientation determined by a main_orient +- offest
% Copyright (2015), Franco Pestilli (Indiana Univ.) - Cesar F. Caiafa (CONICET)
% email: pestillifranco@gmail.com and ccaiafa@gmail.com
function [ ind] = feGetAtoms(fe, main_orient, offset)
% ... |
github | brain-life/encode-master | feComputeVirtualLesion_norm.m | .m | encode-master/life/compute/feComputeVirtualLesion_norm.m | 2,876 | utf_8 | e7d34f172c6df813232d5e087544403f | % This function compute the rmse in a path neighborhood voxels with and
% without Virtual Lesion
function [ rmse_wVL, rmse_woVL, nFib_tract, nFib_PN, nVoxels] = feComputeVirtualLesion_norm(fe, ind_tract)
% INPUTS:
% fe: fe structure
% ind1: indices to fibers in the tract to be virtually lesioned
% ind_nnz = find(fe.li... |
github | brain-life/encode-master | feFindCrossingVoxCoord.m | .m | encode-master/life/compute/feFindCrossingVoxCoord.m | 531 | utf_8 | b2900adcb735b56d84c26c290e9883a1 |
function [cross_vox_ind, cross_vox_coord] = feFindCrossingVoxCoord(fe, ind1, ind2)
[Na] = size(fe.life.M.Phi,1); % # of atoms
[Nv] = size(fe.life.M.Phi,2); % # of voxels
[Nf] = size(fe.life.M.Phi,3); % # of fascicles
Phi_tract1 = fe.life.M.Phi(:,:,ind1);
[subs, vals] = find(Phi_tract1);
vox_ind_1 = unique(subs(:,2))... |
github | brain-life/encode-master | feComputeVirtualLesion_norm_FULL.m | .m | encode-master/life/compute/feComputeVirtualLesion_norm_FULL.m | 2,677 | utf_8 | c051e1cec40451d856bc9a50b5928ed3 | % This function compute the rmse in a path neighborhood voxels with and
% without Virtual Lesion
function [ rmse_wVL, rmse_woVL, nFib_tract, nFib_PN, nVoxels] = feComputeVirtualLesion_norm_FULL(fe, ind_tract)
% INPUTS:
% fe: fe structure
% ind1: indices to fibers in the tract to be virtually lesioned
% ind_nnz = find(... |
github | brain-life/encode-master | feGetVoxels.m | .m | encode-master/life/compute/feGetVoxels.m | 600 | utf_8 | 07991f507aa443938053b0630118a136 | % This function return the indices to the atoms having a particular spatial orientation determined by a main_orient +- offest
% Copyright (2015), Franco Pestilli (Indiana Univ.) - Cesar F. Caiafa (CONICET)
% email: pestillifranco@gmail.com and ccaiafa@gmail.com
function [ ind] = feGetVoxels(fe, v0, dv)
% INPUTS:
% fe... |
github | brain-life/encode-master | FitFullModel.m | .m | encode-master/life/compute/FitFullModel.m | 7,778 | utf_8 | fa4f53ae8046a2ea2d43ecf72f9b3d3b | function [fe, results] = FitFullModel(dwiFile, fgFileName, feFileName, L, p, alpha_v, alpha_f, lambda_a, lambda_r)
% INPUT
% dwFile: diffusion measurements
% fgFileName: Tractography file
% L: discretization parameter in ENCODE
% p: Training set ratio, (1-p)... |
github | brain-life/encode-master | FitFullModel_old.m | .m | encode-master/life/compute/FitFullModel_old.m | 7,113 | utf_8 | dd733d2691c8afbd4143eedf65a984a2 | function [fe, results] = FitFullModel(dwiFile, fgFileName, feFileName, L, p, alpha_v, alpha_f, lambda_a, lambda_r)
% INPUT
% dwFile: diffusion measurements
% fgFileName: Tractography file
% L: discretization parameter in ENCODE
% p: Training set ratio, (1-p)... |
github | brain-life/encode-master | feComputeAnglesTracts.m | .m | encode-master/life/compute/feComputeAnglesTracts.m | 2,479 | utf_8 | dc101e7c0942757c24a80452bf9cb55d | % This function compute the angles between two tracts. The indices ind1 and
% ind2 indicate the fascicles (3rmode indices) in those tracts,
% respectively
% Copyright (2015), Franco Pestilli (Indiana Univ.) - Cesar F. Caiafa (CONICET)
% email: pestillifranco@gmail.com and ccaiafa@gmail.com
function [ Angles] = feComp... |
github | brain-life/encode-master | bbnnls_orig.m | .m | encode-master/external/bbnnls_orig.m | 6,613 | utf_8 | 1d4693ff6d27b42c1b225c56768b1053 | function out = bbnnls_orig(A, b, x0, opt)
% BBNNLS -- Solve NNLS problems via SBB
%
% WARNING Use at own risk!
% NOTE --- guaranteed convergence phase: *REMOVED* for speedup!!
% NOTE --- To speed up code further, *REMOVE* debugging part
%
%
% function out = bbnnls(A, b, x0, opt)
% Solve a bound-constrained least squ... |
github | brain-life/encode-master | ByteSize.m | .m | encode-master/external/ByteSize.m | 1,008 | utf_8 | 0de6743694fc04d04efbb426fd338f29 | function str = ByteSize(in, fid)
% BYTESIZE writes the memory usage of the provide variable to the given file
% identifier. Output is written to screen if fid is 1, empty or not provided.
if nargin == 1 || isempty(fid)
fid = 1;
end
s = whos('in');
str = Bytes2str(s.bytes);
%fprintf(fid,[Bytes2str(s.bytes) '\n']);... |
github | brain-life/encode-master | bbnnls_orig_gpu.m | .m | encode-master/external/bbnnls_orig_gpu.m | 6,890 | utf_8 | 6bff4df0680b3826c7be599552433b1b | function out = bbnnls_orig_gpu(A, b, x0, opt)
% BBNNLS -- Solve NNLS problems via SBB
%
% WARNING Use at own risk!
% NOTE --- guaranteed convergence phase: *REMOVED* for speedup!!
% NOTE --- To speed up code further, *REMOVE* debugging part
%
%
% function out = bbnnls(A, b, x0, opt)
% Solve a bound-constrained least... |
github | brain-life/encode-master | bbnnls.m | .m | encode-master/external/bbnnls.m | 8,314 | utf_8 | 6d29c91af95ba7f58318b8e80c29726b | function out = bbnnls(M, b, x0, opt)
% function out = bbnnls_New(A, b, x0, opt)
%
% This is a modified version of BBNNLS code originally written by Suvrit Sra, Dongmin Kim
% This version accept as parameter a factorization of matrix A which is a
% structure M containing:
% 1) The Dictionary M.DictSig;
% 2)... |
github | brain-life/encode-master | checkMexCompiled.m | .m | encode-master/external/checkMexCompiled.m | 2,935 | utf_8 | d4a2d0a9d37be463424684b0a5eadec5 | function checkMexCompiled(varargin)
%CHECKMEXCOMPILED Check if mex file is compiled for system
%
% IOSR.GENERAL.CHECKMEXCOMPILED(SOURCE_FILE) checks whether a mex source
% file SOURCE_FILE is compiled for the current operating system OR
% whether the source file has been modified since it was compiled. It is
% ... |
github | brain-life/encode-master | cp_apr.m | .m | encode-master/external/tensor_toolbox_2.5/cp_apr.m | 7,920 | utf_8 | 5e7833d58cab0d616e25f7d89a374e1d | function [M,Minit,output] = cp_apr(X, R, varargin)
%CP_APR Compute nonnegative CP with alternating Poisson regression.
%
% M = CP_APR(X, R) computes an estimate of the best rank-R
% CP model of a tensor X using an alternating Poisson regression.
% The input X can be a tensor, sptensor, ktensor, or ttensor. The
% ... |
github | brain-life/encode-master | export_data.m | .m | encode-master/external/tensor_toolbox_2.5/export_data.m | 2,370 | utf_8 | 1e8dfa282d0e4b69ff77560a6f844bd7 | function export_data(A, fname)
%EXPORT_DATA Export tensor-related data to a file.
%
% EXPORT(A,FNAME) exports object A to the file named FNAME in plain ASCII
% text. Export currently supports exporting the following data types:
%
% - tensor
% - matrix
%
% In the case of a tensor, the first t... |
github | brain-life/encode-master | cp_nmu.m | .m | encode-master/external/tensor_toolbox_2.5/cp_nmu.m | 4,976 | utf_8 | 633d7166c5a07d5533e57ba3ccb25162 | function [P,Uinit] = cp_nmu(X,R,opts)
%CP_NMU Compute nonnegative CP with multiplicative updates.
%
% P = CP_NMU(X,R) computes an estimate of the best rank-R PARAFAC
% model of a tensor X with nonnegative constraints on the factors.
% This version uses the Lee & Seung multiplicative updates from
% their NMF alg... |
github | brain-life/encode-master | tt_combinator.m | .m | encode-master/external/tensor_toolbox_2.5/tt_combinator.m | 12,716 | utf_8 | c75d4873d79dfc2d82fa4aa65a273093 | function [A] = tt_combinator(N,K,s1,s2)
%TT_COMBINATOR Perform basic permutation and combination samplings.
% COMBINATOR will return one of 4 different samplings on the set 1:N,
% taken K at a time. These samplings are given as follows:
%
% PERMUTATIONS WITH REPETITION/REPLACEMENT
% COMBINATOR(N,K,'p','... |
github | brain-life/encode-master | import_data.m | .m | encode-master/external/tensor_toolbox_2.5/import_data.m | 1,807 | utf_8 | 8b7c322f2ba9cde0561398578ec0ce13 | function A = import_data(fname)
%IMPORT_DATA Import tensor-related data to a file.
%
% A = IMPORT_DATA(FNAME) imports an object A from the file named FNAME.
% The supported data types and formatting of the file are explained in
% EXPORT_DATA.
%
% See also TENSOR, EXPORT_DATA
%
%MATLAB Tensor Toolbox.
... |
github | brain-life/encode-master | create_problem.m | .m | encode-master/external/tensor_toolbox_2.5/create_problem.m | 12,899 | utf_8 | 7d998940893bb78a66078143cfa43ae5 | function [info,params] = create_problem(varargin)
%CREATE_PROBLEM Create test problems for tensor factorizations.
%
% INFO = CREATE_PROBLEM('Param',value,...) creates a tensor factorization
% test problem. It generates a solution corresponding to a ktensor or a
% ttensor, and then it generates an example dat... |
github | brain-life/encode-master | renumber.m | .m | encode-master/external/tensor_toolbox_2.5/@sptensor/private/renumber.m | 1,606 | utf_8 | b0e7ca64b6641a9f0ac50bef3e9ae5ef | function [newsubs, newsz] = renumber(subs, sz, range)
%RENUMBER indices for sptensor subsref
%
% [NEWSUBS,NEWSZ] = RENUMBER(SUBS,SZ,RANGE) takes a set of
% original subscripts SUBS with entries from a tensor of size
% SZ. All the entries in SUBS are assumed to be within the
% specified RANGE. These subscripts are t... |
github | brain-life/encode-master | tucker_me.m | .m | encode-master/external/tensor_toolbox_2.5/met/tucker_me.m | 4,560 | utf_8 | 3216bec3b59aecd3b4a11c8e4c559039 | function [T, max_mem, Uinit] = tucker_me(X, R, esz, opts)
%TUCKER_ME Memory-efficient Tucker higher-order orthogonal iteration.
%
% T = TUCKER_ME(X,R,ESZ) computes the best rank(R1,R2,..,Rn)
% approximation of tensor X, according to the specified dimensions
% in vector R. ESZ specifies the number of dimensions th... |
github | brain-life/encode-master | tucker_me_test.m | .m | encode-master/external/tensor_toolbox_2.5/met/tucker_me_test.m | 3,079 | utf_8 | 7cd5d5bf56ea1d8a82ef189d3c71d564 | function tucker_me_test
%TUCKER_ME_TEST Very simple tests of tucker_me.
% Code by Tamara Kolda and Jimeng Sun, 2008.
%
% Based on the paper:
% T. G. Kolda and J. Sun. Scalable Tensor Decompositions for Multi-aspect
% Data Mining. In: ICDM 2008: Proceedings of the 8th IEEE International
% Conference on Data M... |
github | brain-life/encode-master | ttm_me.m | .m | encode-master/external/tensor_toolbox_2.5/met/ttm_me.m | 4,085 | utf_8 | 241d426fee6a1d228fd2ca6c01db66b1 | function Y = ttm_me(X, U, edims, sdims, tflag)
%TTM_ME Memory-efficient sptensor times matrix.
%
% Y = TTM_ME(X, U, EDIMS, SDIMS, TFLAG) handles some dimensions
% elementwise and others in the standard way. Here, X is a sparse tensor
% (sptensor), U is a cell array of matrices of length ndims(X),
% EDIMS speci... |
github | brain-life/encode-master | fixsigns.m | .m | encode-master/external/tensor_toolbox_2.5/@ktensor/fixsigns.m | 3,162 | utf_8 | 8a24ae047737b6b7c2b6e62347dcd2d0 | function K = fixsigns(K,K0)
%FIXSIGNS Fix sign ambiguity of a ktensor.
%
% K = FIXSIGNS(K) makes it so that the largest magnitude entries for
% each vector in each factor of K are positive, provided that the
% sign on *pairs* of vectors in a rank-1 component can be flipped.
%
% K = FIXSIGNS(K,K0) returns a vers... |
github | brain-life/encode-master | datadisp.m | .m | encode-master/external/tensor_toolbox_2.5/@ktensor/datadisp.m | 3,162 | utf_8 | 0b9d29cbfc884a9dbb6eec3a8729b7b1 | function datadisp(T, dimlabels, opts)
%DATADISP Special display of a ktensor.
%
% DATADISP(T,LABELS) displays the largest positive entries of each rank-1
% factor of T using the corresponding labels. LABELS is a cell array of
% size ndims(T) such that LABELS{n} is a string cell array of length
% size(T,n).
%
%... |
github | gokererdogan/ML_ReadingGroup-master | hamiltonian_mcmc_sample.m | .m | ML_ReadingGroup-master/mcmc/hamiltonian_mcmc_sample.m | 1,560 | utf_8 | b976682acca8dcfcc585fdd4f37fda2a | % Hamiltonian MCMC
% See Neal, R. M. (2011). MCMC Using Hamiltonian Dynamics.
% In Brooks, S., Gelman, A., Jones, G., and Meng, X., editors,
% Handbook of Markov Chain Monte Carlo, chapter 5, pages 113?162.
% Chapman and Hall / CRC Press
% for a very nice introduction to Hamiltonian MCMC
%
% Goker Erdogan
% 4 ... |
github | GiovanniPaoloGibilisco/spark-log-processor-master | EstimationAnalysis.m | .m | spark-log-processor-master/performance-estimator/src/main/resources/EstimationAnalysis.m | 3,073 | utf_8 | a4bef6a44681d3efd95b4ffb8cd68d12 |
function EstimationAnalysis(x,y,y_estimate,training_size)
%commonly used percentiles for the gaussian
%68,3% = P{ ? - 1,00 ? < X < ? + 1,00 ? }
%95,0% = P{ ? - 1,96 ? < X < ? + 1,96 ? }
%95,5% = P{ ? - 2,00 ? < X < ? + 2,00 ? }
%99,0% = P{ ? - 2,58 ? < X < ? + 2,58 ? }
%99,7% = P{ ? - 3,00 ? < X < ? + 3,00 ? ... |
github | coenvl/mSAM-master | analyzeResults.m | .m | mSAM-master/functions/analyzeResults.m | 1,784 | utf_8 | 49276c0fcba190f58c82b8fff6afcdad | %% ANALYZERESULTS
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: January 15, 2016
%
%% See also:
%
%% Function Definition
function varargout = analyzeResults(results)
% algos = sort(fieldnames(result... |
github | coenvl/mSAM-master | createResultGraph.m | .m | mSAM-master/functions/createResultGraph.m | 8,626 | utf_8 | d3be88d0d55699996633ba247686a43f | %% CREATERESULTGRAPH
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2015 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: July 30, 2015
%
%% See also:
%
%% Function Definition
function [varargout] = createResultGraph(results, x_field, y_field, plotOptions)
%% Get what... |
github | coenvl/mSAM-master | createResultTable.m | .m | mSAM-master/functions/createResultTable.m | 2,085 | utf_8 | fb00f3bcf34b06040df2553054b1497f | %% CREATERESULTTABLE
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: January 30, 2016
%
%% See also:
%
%% Function Definition
function varargout = createResultTable(exp, options)
if numel(exp) == 1
... |
github | coenvl/mSAM-master | getExperimentSolvers.m | .m | mSAM-master/functions/getExperimentSolvers.m | 6,483 | utf_8 | 1951424607e4aaaa278389f5a3c3a3cf | %% GETEXPERIMENTSOLVERS
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: September 15, 2016
%
%% See also:
%
%% Function Definition
function solvers = getExperimentSolvers(series)
%%
if nargin > 0 &&... |
github | coenvl/mSAM-master | generateWPTScenario.m | .m | mSAM-master/functions/generateWPTScenario.m | 3,255 | utf_8 | 5dcd748c16e5595cbdc66ef798dca820 | %% GENERATEWPTSCENARIO
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2017 - TNO*
% * *Author*: leeuwencjv
% * *Since*: March 24, 2017
%
%% See also:
%
%% Function Definition
function [agentPos, receiverPos, sensorPos, edges, transmitter_to_receiver, transmitter_to_senso... |
github | coenvl/mSAM-master | getFixedAlgoStyles.m | .m | mSAM-master/functions/getFixedAlgoStyles.m | 1,653 | utf_8 | 899b5d50824ac96021acea00cdd8b599 | %% GETFIXEDALGOSTYLES
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2017 - TNO*
% * *Author*: leeuwencjv
% * *Since*: January 06, 2017
%
%% See also:
%
%% Function Definition
function fixedStyles = getFixedAlgoStyles()
colors = cubehelix(8, .5, -1.5, 3, 1);
fixedStyles... |
github | coenvl/mSAM-master | getGraphOptions.m | .m | mSAM-master/functions/getGraphOptions.m | 1,948 | utf_8 | dce35726f78e4236bf298a471b7e3a79 | %% GETGRAPHOPTIONS
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2015 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: July 30, 2015
%
%% See also:
%
%% Function Definition
function options = getGraphOptions()
scale_factor = 2;
font_scale_factor = 2;
% Figure option... |
github | coenvl/mSAM-master | prepareResults.m | .m | mSAM-master/functions/prepareResults.m | 1,557 | utf_8 | 516b6b54435b5db0eece5f320bb0715c | %% PREPARERESULTS
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: January 16, 2016
%
%% See also:
%
%% Function Definition
function matresults = prepareResults(cellresults, fixedrange)
algos = sort(f... |
github | coenvl/mSAM-master | visualizeProgress.m | .m | mSAM-master/functions/visualizeProgress.m | 1,568 | utf_8 | 6be6043b3f37894516f2331a3806f636 | %% visualizeProgress
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: April 22, 2016
%
%% See also:
%
%% Function Definition
function visualizeProgress(exp, solvername)
persistent handles;
persistent... |
github | coenvl/mSAM-master | pdftops.m | .m | mSAM-master/functions/export_fig/pdftops.m | 5,994 | utf_8 | 24eb803667c83c8a28424c979311652b | function varargout = pdftops(cmd)
%PDFTOPS Calls a local pdftops executable with the input command
%
% Example:
% [status result] = pdftops(cmd)
%
% Attempts to locate a pdftops executable, finally asking the user to
% specify the directory pdftops was installed into. The resulting path is
% stored for future refere... |
github | coenvl/mSAM-master | crop_borders.m | .m | mSAM-master/functions/export_fig/crop_borders.m | 4,976 | utf_8 | c814ff486afb188464069b51e4b5ed8a | function [A, vA, vB, bb_rel] = crop_borders(A, bcol, padding, crop_amounts)
%CROP_BORDERS Crop the borders of an image or stack of images
%
% [B, vA, vB, bb_rel] = crop_borders(A, bcol, [padding])
%
%IN:
% A - HxWxCxN stack of images.
% bcol - Cx1 background colour vector.
% padding - scalar indicating how much... |
github | coenvl/mSAM-master | isolate_axes.m | .m | mSAM-master/functions/export_fig/isolate_axes.m | 4,721 | utf_8 | 253cd7b7d8fc7cb00d0cc55926f32de5 | function fh = isolate_axes(ah, vis)
%ISOLATE_AXES Isolate the specified axes in a figure on their own
%
% Examples:
% fh = isolate_axes(ah)
% fh = isolate_axes(ah, vis)
%
% This function will create a new figure containing the axes/uipanels
% specified, and also their associated legends and colorbars. The objects
%... |
github | coenvl/mSAM-master | im2gif.m | .m | mSAM-master/functions/export_fig/im2gif.m | 6,048 | utf_8 | 5a7437140f8d013158a195de1e372737 | %IM2GIF Convert a multiframe image to an animated GIF file
%
% Examples:
% im2gif infile
% im2gif infile outfile
% im2gif(A, outfile)
% im2gif(..., '-nocrop')
% im2gif(..., '-nodither')
% im2gif(..., '-ncolors', n)
% im2gif(..., '-loops', n)
% im2gif(..., '-delay', n)
%
% This function converts a mu... |
github | coenvl/mSAM-master | read_write_entire_textfile.m | .m | mSAM-master/functions/export_fig/read_write_entire_textfile.m | 924 | utf_8 | 779e56972f5d9778c40dee98ddbd677e | %READ_WRITE_ENTIRE_TEXTFILE Read or write a whole text file to/from memory
%
% Read or write an entire text file to/from memory, without leaving the
% file open if an error occurs.
%
% Reading:
% fstrm = read_write_entire_textfile(fname)
% Writing:
% read_write_entire_textfile(fname, fstrm)
%
%IN:
% fname - Pathn... |
github | coenvl/mSAM-master | pdf2eps.m | .m | mSAM-master/functions/export_fig/pdf2eps.m | 1,471 | utf_8 | a1f41f0c7713c73886a2323e53ed982b | %PDF2EPS Convert a pdf file to eps format using pdftops
%
% Examples:
% pdf2eps source dest
%
% This function converts a pdf file to eps format.
%
% This function requires that you have pdftops, from the Xpdf suite of
% functions, installed on your system. This can be downloaded from:
% http://www.foolabs.com/xpdf ... |
github | coenvl/mSAM-master | print2array.m | .m | mSAM-master/functions/export_fig/print2array.m | 10,117 | utf_8 | 826905ad12ce0de461386980b4aae89b | function [A, bcol] = print2array(fig, res, renderer, gs_options)
%PRINT2ARRAY Exports a figure to an image array
%
% Examples:
% A = print2array
% A = print2array(figure_handle)
% A = print2array(figure_handle, resolution)
% A = print2array(figure_handle, resolution, renderer)
% A = print2array(figure_handle... |
github | coenvl/mSAM-master | append_pdfs.m | .m | mSAM-master/functions/export_fig/append_pdfs.m | 2,678 | utf_8 | 949c7c4ec3f5af6ff23099f17b1dfd79 | %APPEND_PDFS Appends/concatenates multiple PDF files
%
% Example:
% append_pdfs(output, input1, input2, ...)
% append_pdfs(output, input_list{:})
% append_pdfs test.pdf temp1.pdf temp2.pdf
%
% This function appends multiple PDF files to an existing PDF file, or
% concatenates them into a PDF file if the output fi... |
github | coenvl/mSAM-master | using_hg2.m | .m | mSAM-master/functions/export_fig/using_hg2.m | 1,064 | utf_8 | a1883d15c4304cd0ac406c117e3047ea | %USING_HG2 Determine if the HG2 graphics engine is used
%
% tf = using_hg2(fig)
%
%IN:
% fig - handle to the figure in question.
%
%OUT:
% tf - boolean indicating whether the HG2 graphics engine is being used
% (true) or not (false).
% 19/06/2015 - Suppress warning in R2015b; cache result for improved per... |
github | coenvl/mSAM-master | eps2pdf.m | .m | mSAM-master/functions/export_fig/eps2pdf.m | 8,435 | utf_8 | 95432e4216ee24df69e7e5720c6c4039 | function eps2pdf(source, dest, crop, append, gray, quality, gs_options)
%EPS2PDF Convert an eps file to pdf format using ghostscript
%
% Examples:
% eps2pdf source dest
% eps2pdf(source, dest, crop)
% eps2pdf(source, dest, crop, append)
% eps2pdf(source, dest, crop, append, gray)
% eps2pdf(source, dest, crop... |
github | coenvl/mSAM-master | ghostscript.m | .m | mSAM-master/functions/export_fig/ghostscript.m | 7,706 | utf_8 | 92dbafb8d4fb243cae8716c6ecb0bbe5 | function varargout = ghostscript(cmd)
%GHOSTSCRIPT Calls a local GhostScript executable with the input command
%
% Example:
% [status result] = ghostscript(cmd)
%
% Attempts to locate a ghostscript executable, finally asking the user to
% specify the directory ghostcript was installed into. The resulting path
% is s... |
github | coenvl/mSAM-master | fix_lines.m | .m | mSAM-master/functions/export_fig/fix_lines.m | 6,290 | utf_8 | 8437006b104957762090e3d875688cb6 | %FIX_LINES Improves the line style of eps files generated by print
%
% Examples:
% fix_lines fname
% fix_lines fname fname2
% fstrm_out = fixlines(fstrm_in)
%
% This function improves the style of lines in eps files generated by
% MATLAB's print function, making them more similar to those seen on
% screen. Grid ... |
github | coenvl/mSAM-master | graphDensity.m | .m | mSAM-master/functions/graph/graphDensity.m | 522 | utf_8 | 8097f6eb54f6ca507edc061b7fc165bc | %% GRAPHDENSITY
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2015 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: July 09, 2015
%
%% See also:
%
%% Function Definition
function density = graphDensity( edges )
if iscell(edges)
density = nan;
return
end
% Ge... |
github | coenvl/mSAM-master | isGraph.m | .m | mSAM-master/functions/graph/isGraph.m | 357 | utf_8 | 9f82b73c12847ca5ea51dde691ced842 | %% ISGRAPH
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: August 12, 2016
%
%% See also:
%
%% Function Definition
function valid = isGraph(edges)
if iscell(edges)
edges = vertcat(edges{:});
en... |
github | coenvl/mSAM-master | graphSize.m | .m | mSAM-master/functions/graph/graphSize.m | 412 | utf_8 | 02749951748a81b3b6889aac0b73e5ce | %% GRAPHSIZE
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2015 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: July 10, 2015
%
%% See also:
%
%% Function Definition
function [ size ] = graphSize( edges )
if isempty(edges)
size = 0;
return;
end
if iscell(ed... |
github | coenvl/mSAM-master | higherOrderGraphIsConnected.m | .m | mSAM-master/functions/graph/higherOrderGraphIsConnected.m | 1,235 | utf_8 | e13c6ab3fe48d1f1e409bf3cd75239cd | %% GRAPHISCONNECTED
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: July 29, 2016
%
%% See also:
%
%% Function Definition
function [ isConnected, missing ] = higherOrderGraphIsConnected(edges, knownGraphSize)
% Firs... |
github | coenvl/mSAM-master | printGraph.m | .m | mSAM-master/functions/graph/printGraph.m | 1,495 | utf_8 | ec2bddcf2afe8ca6dbb2200ef7c22a0a | %% PRINTGRAPH
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2015 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: July 03, 2015
%
%% See also:
%
%% Function Definition
function filename = printGraph(edges, filename)
if nargin < 2
filename = uiputfile('*.png', 'Se... |
github | coenvl/mSAM-master | graphIsConnected.m | .m | mSAM-master/functions/graph/graphIsConnected.m | 1,253 | utf_8 | 653eb979dc0ca89dcd8844a8803fffa9 | %% GRAPHISCONNECTED
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: July 29, 2016
%
%% See also:
%
%% Function Definition
function [ isConnected, missing ] = graphIsConnected( edges )
if iscell(edges... |
github | coenvl/mSAM-master | path_loss_factor.m | .m | mSAM-master/functions/util/path_loss_factor.m | 308 | utf_8 | a1f3a78b57480e8e7814927a3baa04e6 | %--------------------------------------------------------
% returns power levels according to the simple path loss
%--------------------------------------------------------
function power_factor = path_loss_factor(distances)
alpha = 100;
beta = 100;
power_factor = alpha./(distances+beta).^2;
end |
github | coenvl/mSAM-master | LP_solution.m | .m | mSAM-master/functions/util/LP_solution.m | 902 | utf_8 | 9d9a55dd5bdf626c91d3e9cf56f828dd | %--------------------------------------------------------
% Centralized linear programming solution
%--------------------------------------------------------
function [x,fval] = LP_solution(transmitter_to_receiver_distances,transmitter_to_sensor_distances,...
EMR_Threshold,MAX_POWER, MIN_POWER)
[Num_Transmitte... |
github | coenvl/mSAM-master | poissonSample.m | .m | mSAM-master/functions/util/poissonSample.m | 1,944 | utf_8 | 48ba8fd16c60231cfe8912f472eece44 | %% POISSONSAMPLE
% *Select 2D points according to a poisson point process*
%
% Select a set of 2D points according to a poisson point process. In doing
% so, the average density in any subregion of the space is constant. More
% info see: http://en.wikipedia.org/wiki/Poisson_point_process.
%
% Iteratively selects prev... |
github | coenvl/mSAM-master | poissonSample3.m | .m | mSAM-master/functions/util/poissonSample3.m | 2,210 | utf_8 | c391f2e96188caf434aa8b4be239d765 | %% POISSONSAMPLE
% *Select 3D points according to a poisson point process*
%
% Select a set of 3D points according to a poisson point process. In doing
% so, the average density in any subregion of the space is constant. More
% info see: http://en.wikipedia.org/wiki/Poisson_point_process.
%
% Iteratively selects prev... |
github | coenvl/mSAM-master | getSubOption.m | .m | mSAM-master/functions/util/getSubOption.m | 2,746 | utf_8 | b4d57a5a7f63b551eefdc29e6401273f | %% GETSUBOPTION
% *Get an option from a nested options struct*
%
% Get an option from a nested struct of multiple options. This function
% will check if the option exists, and if not will return the default value
% (if provided).
%
%% Usage:
% value = getSubOption(default, options, fieldname)
% Check the options stru... |
github | coenvl/mSAM-master | getSolverCounterPart.m | .m | mSAM-master/experiment/private/getSolverCounterPart.m | 777 | utf_8 | 8ab9fb8c1ec381b192d1067269d92758 | %% GETSOLVERCOUNTERPART
% *Summary of this function goes here*
%
% Detailed explanation goes here
%
%% Copyright
% * *2016 - TNO*
% * *Author*: Coen van Leeuwen
% * *Since*: August 12, 2016
%
%% See also:
%
%% Function Definition
function type = getSolverCounterPart(solverType)
dummyVariable = nl.coen... |
github | harleigh/SnoptProjects-master | brachFrictionUserFun.m | .m | SnoptProjects-master/brachistochrone/noSparsityNoJacobian/brachFrictionUserFun.m | 2,816 | utf_8 | ffbf4609bfd70c02da5f6cf0add5e214 | %{
The UserFun for the Brach Problem. This function is called by SNOPT to
converge to an optimal solution. In this function
1) We pack the nonlinear constraints into F.
2) We calculate the Jacobian of the constraints with respect to the
decision variables (variable G).
In this fu... |
github | harleigh/SnoptProjects-master | buildInitialGuess.m | .m | SnoptProjects-master/brachistochrone/noSparsityNoJacobian/buildInitialGuess.m | 1,792 | utf_8 | ebdc96451667ff1fe2c825da0c1c3485 | %{
Name: buildInitialGuess
This function returns an initial guess (of a straight line) that starts
at (x0,y0) and ends at (xf,yf) and has constant velocity, and a final time
guess of 1.
Inputs:
* x0, y0, v0, xf, yf Initial and final point constraints for the Brach
Curve
*... |
github | harleigh/SnoptProjects-master | brachFrictionUserFun.m | .m | SnoptProjects-master/brachistochrone/sparsityAndJacobian/brachFrictionUserFun.m | 7,083 | utf_8 | 7de98a1899cf22f50be81d2d2a0018b5 | %{
The UserFun for the Brach Problem. This function is called by SNOPT to
converge to an optimal solution. In this function
1) We pack the nonlinear constraints into F.
2) We calculate the Jacobian of the constraints with respect to the
decision variables (variable G).
In this fu... |
github | harleigh/SnoptProjects-master | findSparsityPattern.m | .m | SnoptProjects-master/brachistochrone/sparsityAndJacobian/findSparsityPattern.m | 2,814 | utf_8 | 923575aa4cb52e90bd35101b0d8e1049 | %{
The sparsity pattern of G: The Jacobian of the constraints (packed into F)
with respect to the Decesion Variables (packed into xInit) tells Snopt which
sections of the jacobian that are nonZero, and hence need to be computed
(either by me, or by Snopt; in this version of the code I explicitly compute... |
github | harleigh/SnoptProjects-master | buildInitialGuess.m | .m | SnoptProjects-master/brachistochrone/sparsityAndJacobian/buildInitialGuess.m | 1,792 | utf_8 | ebdc96451667ff1fe2c825da0c1c3485 | %{
Name: buildInitialGuess
This function returns an initial guess (of a straight line) that starts
at (x0,y0) and ends at (xf,yf) and has constant velocity, and a final time
guess of 1.
Inputs:
* x0, y0, v0, xf, yf Initial and final point constraints for the Brach
Curve
*... |
github | SNEEManchester/qosa-snee-master | md5.m | .m | qosa-snee-master/src/matlab/wheresched/md5.m | 5,614 | utf_8 | 8e05a9bcad3bd63d1e3e5d5a43f80480 | % md5 Compute MD5 hash function for files
%
% d = md5(FileName)
%
% md5() computes the MD5 hash function of
% the file specified in the string FileName
% and returns it as a 64-character array d.
% The MD5 message-digest algorithm is specified
% in RFC 1321.
% The code below is for instructional and i... |
github | SNEEManchester/qosa-snee-master | nomadm.m | .m | qosa-snee-master/src/matlab/wheresched/nomadm.m | 212,095 | utf_8 | 5a5ad1f8b3da4f5c54698581128fded7 | function nomadm
%NOMADM Execute the NOMADm graphic user interface (GUI).
%
% Syntax:
% nomadm
%
% Description:
% NOMADM launches the NOMADm GUI, which controls the setup of an
% optimization problem, setting of various algorithm parameters and
% options, running of the MADS algorithm ... |
github | SNEEManchester/qosa-snee-master | daf_moveOpInst.m | .m | qosa-snee-master/src/matlab/wheresched/daf_moveOpInst.m | 3,659 | utf_8 | 41bba6fdc035650b52aa2f23e7836850 | function N = daf_moveOpInst(N, candNum, opInstIndex, opInstId, currentSite, newSite)
global operatorinstances;
global locationConstraints;
global rt;
global opInstDeepestConfSite;
global opInstChildren;
global opInstanceIndex;
global parentOpInst;
global numNeighbours
global sites;
%Assign the operator i... |
github | SNEEManchester/qosa-snee-master | wheresched.m | .m | qosa-snee-master/src/matlab/wheresched/wheresched.m | 7,718 | utf_8 | 1bb6d60951b950a7f912ea5386be5895 | function f = wheresched(x, p)
global rt;
global operatorinstances;
global parentOpInst;
global outputSize;
global opInstanceIndex;
global min_f;
global sites;
global opInstOperator;
global card;
global siteTuplesToSend;
global operators;
global tuplesPerMessage;
global txEnergy;
global siteChildren;
gl... |
github | SNEEManchester/qosa-snee-master | wheresched_Omega.m | .m | qosa-snee-master/src/matlab/wheresched/wheresched_Omega.m | 973 | utf_8 | 499db10cb1a85d6aa26bdd0d288137e2 | %*********************************************************************
% experiment_Omega: User-supplied function for defining Omega, based on p.
% --------------------------------------------------------------------
% Variables:
% A = Coefficient matrix for bound and linear constraints
% l = Lo... |
github | SNEEManchester/qosa-snee-master | mads.m | .m | qosa-snee-master/src/matlab/wheresched/mads.m | 248,979 | utf_8 | 0ca31f8e9b216c0555190f3c7e2690db | function [BestF,BestI,RunData,varargout] = mads(Problem,iterate0,varargin)
%MADS Solver for nonlinear and mixed variable constrained optimization
%
% Syntax:
% [BESTF,BESTI,RUNDATA] = mads(PROBLEM,ITERATE0)
% [BESTF,BESTI,RUNDATA] = mads(PROBLEM,ITERATE0,OPTIONS)
% [BESTF,BESTI,RUNDA... |
github | SNEEManchester/qosa-snee-master | wheresched_x0.m | .m | qosa-snee-master/src/matlab/wheresched/wheresched_x0.m | 2,357 | utf_8 | 0a6067bc8571b35355c538399f4e97ad | function iterate = wheresched_x0;
global assignment;
global outputSize;
global opInstChildren;
global opInstDeepestConfSite;
global operatorinstances;
global locationConstraints;
global initVal;
global heuristic_init_point;
disp('*** Starting Initial Points Function***')
%This one is guaranteed to be fe... |
github | SNEEManchester/qosa-snee-master | wheresched_X.m | .m | qosa-snee-master/src/matlab/wheresched/wheresched_X.m | 2,348 | utf_8 | b8b24f4c09ce14d0e5206ac3626cc5b3 | function isFeasible = wheresched_X(x,p)
global operatorinstances;
global locationConstraints;
global memoryAvailable;
global memoryCost;
global sites;
global parentOpInst;
global opInstanceIndex;
disp('*** Starting Feasibility Function ***')
isFeasible = 1;
%Location-sensitive operators
for i=1:1:len... |
github | SNEEManchester/qosa-snee-master | wheresched_N.m | .m | qosa-snee-master/src/matlab/wheresched/wheresched_N.m | 4,883 | utf_8 | e336d3dbe6f81f33ce0d642895e9fcb5 | %*********************************************************************
% experiment_N: User-supplied function defining set of neighbors for a
% a given vector of categorical variables p.
% --------------------------------------------------------------------
% Variables:
% iterate = iterate for w... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.