[Insight-developers] FEM framework and Testing/Data (was: Modular ITK Git Question)

Magnotta, Vincent A vincent-magnotta at uiowa.edu
Wed Apr 6 20:32:09 EDT 2011


Brad,

Thanks for the git help I will give this a try tomorrow to see how it goes.

Just a follow up on your comments.

1) I was unable to get the SetupForDevelopment.sh script to work on my machine. I mentioned this problem at the second ITKv4 meeting and was not able to resolve this problem. To make progress I abandoned trying to make this work. It would be great if there was a web interface like github that we could resolve some of these issues that required e-mail correspondence to change ssh keys, etc. Most of my problems were trying to resolve ssh key problems. At least when I l;ast tried, if the script errored before completion, several aliases were not defined correctly. This made working with git very confusing when trying to following the ITK cheat sheet.

2) I would agree that FEM would seem to fit better in Numerics, its original home. However, SpatialObjects are in Core and the addition of a new SpatialObject to support the FE model required this change. It could be moved back, but substantial changes would be required to SpatialObjects to support this.

3) I know the issue with the MetaIO, but I wanted a monolithic checkout for our changes to simplify testing across the platforms and feedback from anyone interested.

Vince

--
Associate Professor
Department of Radiology
0453-D JCP
200 Hawkins Drive
Iowa City, IA 52242
E-mail: vincent-magnotta at uiowa.edu
Phone: 319-356-8255 Fax: 319-353-6275
Website: http://www.healthcare.uiowa.edu/Radiology


________________________________________
From: Brad King [brad.king at kitware.com]
Sent: Wednesday, April 06, 2011 3:01 PM
To: Magnotta, Vincent A
Cc: Insight Developers
Subject: Re: FEM framework and Testing/Data (was: Modular ITK Git Question)

On 04/06/2011 02:24 PM, Magnotta, Vincent A wrote:
> I am working on integrating our FEM changes into modular ITK. This is
> currently housed on github (git at github.com:vmagnotta/ITKFEM-Modular.git).

For reference, one may browse your repositories here:

  https://github.com/vmagnotta/ITKFEM-Modular
  https://github.com/vmagnotta/ITKV4FEM-ModularData

Thanks for working on this.  Here are a few general comments:

- The "UPD: " prefix in your commit messages does not follow our rules.
  Please follow the instructions at http://www.itk.org/Wiki/ITK/Git/Develop
  to get started with development.  The SetupForDevelopment.sh installs
  a local hook which would have caught this and given you a message
  describing the possible prefixes.

- Why this commit: Moved FEM from Numerics to Core
  https://github.com/vmagnotta/ITKFEM-Modular/commit/5b8675e5 ?
  Finite elements seem pretty numerical to me.  The directory structure
  and grouping is for human reference.  It is independent of module
  dependencies.

- The modifications to Modules/ThirdParty/MetaIO/src/MetaIO cannot be
  committed upstream through Git.  That directory is replayed from a
  Subversion repository by a robot.  We can deal with that when you
  submit the series for review though.  It will be easier if you keep
  commits to this directory separate from the others.

- The Testing/Data update commit
  https://github.com/vmagnotta/ITKFEM-Modular/commit/753cbf26
  updates the submodule reference to f93daefd but I do not see
  that commit in your data repository.  Perhaps that is the purpose
  of your posted question though ;)

> I have all of the FEM
> framework changes made for an initial integration and have added a
> number of files for regression testing. This brings me to my question.

I've been so busy with the modularization transition that I have not had
time to get back to fixing up the way we reference testing data to avoid
submodules but still not put it in the source tree.

> I would now like to link the Testing/Data to this new Data repository
> instead of the default ITK testing data. Would any one have a suggestion
> on how to do this?

The Testing/Data link only names a commit hash from another repository:

 $ git ls-tree -r HEAD -- Testing/Data
 160000 commit 9e3b3ef32e5fcae1dc54d80534c8dab24248a9d6  Testing/Data

This does not give Git enough information to actually fetch the commit.
Instead, one must configure the repository from which to fetch the data.
This starts with the ".gitmodules" file at the top of the tree:

 $ git show HEAD:.gitmodules
 [submodule "Testing/Data"]
         path = Testing/Data
         url = git://itk.org/ITKData.git

However, the url in there is not used directly.  The "git submodule init"
command copies it into the local repository's configuration:

 $ git config submodule.Testing/Data.url
 git://itk.org/ITKData.git

It is this URL from which Git fetches during "git submodule update".
You can change it in a local clone:

 $ git config submodule.Testing/Data.url git://github.com/...

However, that doesn't actually matter for this use case.

What you need to do is ensure that Testing/Data in your branch of ITK
points at the right commit in your branch of ITKData:

 $ cd Testing/Data
 $ git checkout $commit_you_want
 $ cd ..
 $ git add Testing/Data
 $ git commit

Then make sure both branch heads are published in your github forks.
During review you can push only the ITK part to Gerrit.  Then add a
note to the review page that mentions the URL of your data repository.
Then a reviewer may do this to get it:

 $ cd ITK
 $ git fetch gerrit $your_change && git checkout FETCH_HEAD
 $ cd Testing/Data
 $ git fetch $your_data_url
 $ cd ../..
 $ git submodule update

-Brad


________________________________
Notice: This UI Health Care e-mail (including attachments) is covered by the Electronic Communications Privacy Act, 18 U.S.C. 2510-2521, is confidential and may be legally privileged.  If you are not the intended recipient, you are hereby notified that any retention, dissemination, distribution, or copying of this communication is strictly prohibited.  Please reply to the sender that you have received the message in error, then delete it.  Thank you.
________________________________


More information about the Insight-developers mailing list