Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
BIDS Handler
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Toumji Abdallah
BIDS Handler
Commits
9a85c4b8
Commit
9a85c4b8
authored
1 year ago
by
Toumji Abdallah
Browse files
Options
Downloads
Plain Diff
Merge remote-tracking branch 'origin/master'
parents
54092b75
e9b5dc37
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
BIDSHandler/CreationTool/Application.py
+6
-1
6 additions, 1 deletion
BIDSHandler/CreationTool/Application.py
BIDSHandler/Tools.py
+9
-2
9 additions, 2 deletions
BIDSHandler/Tools.py
main.py
+6
-1
6 additions, 1 deletion
main.py
with
21 additions
and
4 deletions
BIDSHandler/CreationTool/Application.py
+
6
−
1
View file @
9a85c4b8
...
...
@@ -2,6 +2,7 @@ import json
import
os
import
shutil
import
tkinter
as
tk
import
platform
from
pathlib
import
Path
from
tkinter
import
ttk
,
messagebox
...
...
@@ -554,8 +555,12 @@ class Application(tk.Frame):
command
=
self
.
actual_project_state
)
self
.
show_project_button
.
pack
()
if
platform
.
system
()
==
'
Windows
'
:
open_project_button
=
tk
.
Button
(
self
.
integrate_sidecar_frame
,
text
=
'
Open project
'
,
command
=
lambda
:
os
.
startfile
(
self
.
project_directory
))
else
:
open_project_button
=
tk
.
Button
(
self
.
integrate_sidecar_frame
,
text
=
'
Open project
'
,
command
=
lambda
:
os
.
system
(
'
xdg-open
'
+
self
.
project_directory
))
open_project_button
.
pack
()
self
.
previous_directory
=
None
...
...
This diff is collapsed.
Click to expand it.
BIDSHandler/Tools.py
+
9
−
2
View file @
9a85c4b8
...
...
@@ -14,6 +14,7 @@ Functions:
import
json
import
os
from
re
import
search
import
platform
def
get_entities
(
experiments_files
,
project_directory
):
...
...
@@ -386,7 +387,10 @@ class Tools:
The metadata of the file in json format
"""
if
platform
.
system
()
==
'
Windows
'
:
layout_path
=
path
.
replace
(
'
/
'
,
'
\\
'
)
else
:
layout_path
=
path
metadata
=
self
.
layout
.
get
()[
self
.
layout
.
get
(
return_type
=
'
filename
'
).
index
(
layout_path
)].
get_metadata
()
metadata
=
json
.
dumps
(
metadata
,
skipkeys
=
True
,
...
...
@@ -405,7 +409,10 @@ class Tools:
The pybids bids file
"""
if
platform
.
system
()
==
'
Windows
'
:
layout_path
=
path
.
replace
(
'
/
'
,
'
\\
'
)
else
:
layout_path
=
path
return
self
.
layout
.
get
()[
self
.
layout
.
get
(
return_type
=
'
filename
'
).
index
(
layout_path
)]
This diff is collapsed.
Click to expand it.
main.py
+
6
−
1
View file @
9a85c4b8
...
...
@@ -9,6 +9,7 @@ Methods:
"""
import
tkinter
as
tk
import
platform
from
BIDSHandler.MainApplication
import
Application
as
MainApplication
...
...
@@ -32,7 +33,11 @@ class BIDSViewer:
"""
The constructor of the class, it instantiates the main window of the application.
"""
root
=
tk
.
Tk
()
if
platform
.
system
()
==
'
Windows
'
:
root
.
state
(
'
zoomed
'
)
else
:
root
.
attributes
(
'
-zoomed
'
,
True
)
root
.
title
(
'
BIDS Handler
'
)
self
.
app
=
MainApplication
(
root
)
def
show
(
self
):
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment