Skip to main content
Solved

Python FME API Documentation: Code example for raster creation could be wrong


takashi
Influencer

I'm afraid that this code in the "Getting Started  Working with rasters" section  is wrong.

        # creating the new FMERaster
        rasterProperties = fmeobjects.FMERasterProperties(numRows, numCols,
                                                          xCellOrigin, yCellOrigin,
                                                          xSpacing, ySpacing,
                                                          xOrigin, yOrigin,
                                                          xRotation, yRotation)

According to the API reference, the order of parameters should be:

        # creating the new FMERaster
        rasterProperties = fmeobjects.FMERasterProperties(numRows, numCols,
                                                          xSpacing, ySpacing,
                                                          xCellOrigin, yCellOrigin,
                                                          xOrigin, yOrigin,
                                                          xRotation, yRotation)

Best answer by fmelizard

Hi @takashi. I've passed this onto Development, I'll update when I receive a response. Thank you.

View original
Did this help you find an answer to your question?

7 replies

fmelizard
Safer
Forum|alt.badge.img+18
  • Safer
  • Best Answer
  • May 29, 2018

Hi @takashi. I've passed this onto Development, I'll update when I receive a response. Thank you.


fmelizard
Safer
Forum|alt.badge.img+18
  • Safer
  • May 29, 2018
fmelizard wrote:

Hi @takashi. I've passed this onto Development, I'll update when I receive a response. Thank you.

Hi @takashi. Yes you are correct, that's a good find. Development will correct the section to match the proper usage according to the API documentation.

 


takashi
Influencer
  • Author
  • May 29, 2018
fmelizard wrote:

Hi @takashi. I've passed this onto Development, I'll update when I receive a response. Thank you.

Thanks for your quick response :-)

 

 


carsonlam
Safer
Forum|alt.badge.img
  • Safer
  • May 29, 2018
takashi wrote:
Thanks for your quick response :-)

 

 

We've fixed the documentation. Thanks!

takashi
Influencer
  • Author
  • May 30, 2018
carsonlam wrote:
We've fixed the documentation. Thanks!
I cannot see any update yet, here.

 

http://docs.safe.com/fme/html/fmepython/getting_started.html#working-with-rasters

 

 


carsonlam
Safer
Forum|alt.badge.img
  • Safer
  • May 30, 2018
takashi wrote:
Hmm, looks like it's still cached over there. May take some time to show up...

 

 


carsonlam
Safer
Forum|alt.badge.img
  • Safer
  • May 30, 2018
takashi wrote:
Okay, it's up to date now. :)

Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings