Comments (11)
Hi,
Thank you for reporting the issue. I have fixed it on the following fork:
https://github.com/jerome-colin/Start-MAJA
I'd be curious to get your feedback before merging it with the main project since I can't reproduce the issue on my computer.
Thanks,
Jerome
from maja.
from maja.
Hi Jerome, Olivier,
Thanks for the fix, I'm going to test it as soon as possible, but it seems to be good according to the code.
Nicolas
from maja.
Hello,
You can merge with the main project, it works fine on my side.
Thanks
from maja.
Hi Olivier and Jerome,
Given that I needed this fix in my work, I added this one in my fork, so my pull request includes the code from Jerome.
Thanks again.
Nicolas
from maja.
Great, thanks ! It may be wise to have both python 2 and 3 versions living alongside for a while, I'll check with Olivier and come back to you later.
Jerome
from maja.
Yes I understand about Python version...
I made a little fix in your code, actually I fully tested the function and it was necessary to add an increment at row 216 :
Sorry about that, it works fine now.
Nicolas
from maja.
Hi Nicolas,
I'm a bit doubtful about this indent. As far as I see it, if you move the assert in the if clause, you're sure the assertion is True since it's the if condition too. Whenever you have time, I'd be curious to see what error you get before indenting this line (or even remove the try... except statement for testing). Besides, I must admit that I'm not a big fan of assertion (I just kept it since this code is using aplenty). I would preferably catch and manage any other (more explicit) exceptions.
Anyway thanks for your help !
Jerome
from maja.
Hi Jerome,
I understand your point of view, I'm not used to employing assert function.
Actually, here the aim is to get the Tile ID, that means the if condition has to be True too. If you don't put the indent, the assert function is always interpreted, that returns a False because the first for loop iteration (tileFilenameItems[s] with s = 0) is not the Tile ID.
That provokes the except statement at the first loop and finally the "sys.exit(1)".
I hope I was clear...
Thanks again.
Nicolas
from maja.
Ok, I see : this assertion should be out of the for loop, my mistake. It should act as a final check on the tile name pattern once each element of the list passed through the loop. Unindent the assert statement twice will do the job.
Thanks !
from maja.
I agree with you, Jérome and Nicolas, it is way time to switch to python 3.
Olivier
from maja.
Related Issues (20)
- How to install MAJA 4 in Ubuntu 20.04 and Docker HOT 3
- [best practices] Processing by orbit HOT 11
- Using StartMaja with MAJA v3.2.2 HOT 1
- Solution for the error happening in case you try to use CAMS (if "NbNonInterpolate" in self._beforeFile.keys(): 'NoneType' object has no attribute 'keys') HOT 3
- Testing MAJA - Where to get "MAJA-DATA" and "MAJA-Validation"? HOT 1
- Github vs gitlab - which MAJA code should I use? HOT 3
- What are the differences between StartMaja scripts on different repositories? HOT 1
- License confusion HOT 2
- Access denied HOT 11
- Xml encoding in xml_tools.py HOT 2
- SRTM download link doesn't respond HOT 5
- Optimal parameters to get the best results (advice needed) HOT 10
- Inputs do not occupy the same physical space HOT 5
- CMake error for EXPAT when compiling MAJA HOT 11
- [best practices] Optimal parameters for rain forest region HOT 4
- Cmake error for GDAL while compiling MAJA
- SameFileError when processing with StartMaja HOT 1
- Repository no more active, please use MAJA's Forum for issues
- Directory of input files as symbolic links
- Maja creates L2A level data with empty cloud masks & 0 instead of -10000 for each band HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from maja.