Skip to content

Commit

Permalink
respect the ghost keyword if it has been explicit
Browse files Browse the repository at this point in the history
  • Loading branch information
aoterodelaroza committed Dec 13, 2024
1 parent 7e96612 commit 97badce
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.2.359
1.2.360
1 change: 1 addition & 0 deletions src/fieldseedmod.f90
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ module fieldseedmod
character(len=mlen) :: fid = "" !< field ID
logical :: nou = .false. !< wannier option nou
integer :: molden_type = molden_type_unknown !< type of molden file
logical :: ghost_explicit = .false. !< whether there has been a explicit for ghost
! pwc
integer :: pwcspin = 0 !< read which spin (0=all,1=up,2=dn)
integer, allocatable :: pwcikpt(:) !< read which kpts
Expand Down
2 changes: 2 additions & 0 deletions src/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ module subroutine fieldseed_end(f)
f%expr = ""
f%elseopt = ""
f%testrmt = .true.
f%ghost_explicit = .false.
f%readvirtual = .false.
f%vaspblk = 1
f%fid = ""
Expand Down Expand Up @@ -443,6 +444,7 @@ module subroutine fieldseed_parse(f,line,withoptions,lp0)
f%ids = word
elseif (equal(lword,"ghost")) then
f%iff = ifformat_as_ghost
f%ghost_explicit = .true.
else
call backtrack()
ok = eval_next(f%n(1),line,lp)
Expand Down
2 changes: 1 addition & 1 deletion src/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ module subroutine load_field_string(s,line,verbose,id,errmsg,ti)

! Maybe we can load it as a grid if all the fields are grids
! and they are the same size
if (seed%iff == ifformat_as_ghost) then
if (seed%iff == ifformat_as_ghost.and..not.seed%ghost_explicit) then
syl => s
call fields_in_eval(seed%expr,errmsg,nn,idlist,c_loc(syl))
if (len_trim(errmsg) > 0) return
Expand Down

0 comments on commit 97badce

Please sign in to comment.