Skip to content

Commit

Permalink
Merge pull request #21 from VisLab/main
Browse files Browse the repository at this point in the history
Added hedtools to the docs build requirements
  • Loading branch information
VisLab authored Jun 21, 2024
2 parents 4c75fed + 3aef248 commit 11f0edd
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 11 deletions.
3 changes: 2 additions & 1 deletion docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Sphinx>=5.2.2
myst-parser>=0.18.1
sphinx-rtd-theme>=1.0.0
sphinxcontrib-matlabdomain
sphinxcontrib-matlabdomain
hedtools>=8.3.0
8 changes: 3 additions & 5 deletions hedmat/hedtools/HedToolsPython.m
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@
check_for_warnings=checkWarnings);
if ~isempty(sidecar) && ~isequal(sidecar, py.None)
sidecar = HedTools.formatSidecar(sidecar);
sidecarObj = py.hed.tools.analysis.annotation_util.strs_to_sidecar(sidecar);
sidecarObj = py.hed.tools.strs_to_sidecar(sidecar);
issues = sidecarObj.validate(obj.HedSchema, error_handler=ehandler);
hasErrors = py.hed.errors.error_reporter.check_for_any_errors(issues);
issues = char(py.hed.get_printable_issue_string(issues));
Expand Down Expand Up @@ -256,16 +256,14 @@
% Note this is used as the basis for HED queries or for assembled HED.
% To manipulate directly in MATLAB -- convert to a cell array of char
% using string(cell(hedObjs))

hmod = py.importlib.import_module('hed');

eventManager = hmod.EventManager(tabular, schema);
eventManager = py.hed.tools.EventManager(tabular, schema);
if removeTypesOn
removeTypes = {'Condition-variable', 'Task'};
else
removeTypes = {};
end
tagManager = hmod.HedTagManager(eventManager, ...
tagManager = py.hed.tools.HedTagManager(eventManager, ...
py.list(removeTypes));
hedStringObjs = ...
tagManager.get_hed_objs(includeContext, replaceDefs);
Expand Down
5 changes: 3 additions & 2 deletions hedmat/web_services_demos/runAllDemos.m
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
%host = 'https://hedtools.org/hed';
host = 'https://hedtools.org/hed';
%host = 'https://hedtools.org/hed_dev';
host = 'http://127.0.0.1:5000';
%host = 'http://127.0.0.1:5000';


errorMap = containers.Map('KeyType', 'char', 'ValueType', 'any');
errorMap('demoGetServices') = demoGetServices(host);
Expand Down
2 changes: 1 addition & 1 deletion tests/test_hed_tools/TestHedToolsPython.m
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
methods (TestClassSetup)
function setUp(testCase)
testCase.hmod = py.importlib.import_module('hed');
testCase.hed = HedToolsPython('8.2.0');
testCase.hed = HedToolsPython('8.3.0');
[curDir, ~, ~] = fileparts(mfilename("fullpath"));
dataPath = fullfile(curDir, filesep, '..', filesep, '..', ...
filesep, 'data', filesep);
Expand Down
7 changes: 5 additions & 2 deletions tests/test_hed_tools/TestHedToolsService.m
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,11 @@
methods (TestClassSetup)
function setUp(testCase)
testCase.hed = ...
HedToolsService('8.2.0', 'https://hedtools.org/hed_dev');
% HedToolsService('8.2.0', 'http://127.0.0.1:5000');
HedToolsService('8.2.0', 'https://hedtools.org/hed');
% testCase.hed = ...
% HedToolsService('8.2.0', 'https://hedtools.org/hed_dev');
% testCase.hed = ...
% HedToolsService('8.2.0', 'http://127.0.0.1:5000');
[curDir, ~, ~] = fileparts(mfilename("fullpath"));
dataPath = fullfile(curDir, filesep, '..', filesep, '..', ...
filesep, 'data', filesep);
Expand Down

0 comments on commit 11f0edd

Please sign in to comment.