GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Fix lack of abs() in scale_down parameter in psscale by PaulWessel · Pull Request #7816 · GenericMappingTools/gmt

Conversation

@PaulWessel

@PaulWessel PaulWessel commented Sep 14, 2023

Copy link
Copy Markdown
Contributor

Somehow I forgot that a color bar can be given with negative length to reverse the positive direction. The new scale_down variable that adjusts annotation font size and other bar parameters involves taking sqrt of the ratio of two dimensions. One of them was in the form of MAX (a, b) and a was negative, so it picked the bar width b and we got tiny fonts.

This PR does the fabs() and revises the wrong PostScript original GMT_App_M_2.ps.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
PaulWessel and others added 12 commits September 14, 2023 14:09
@PaulWessel
Expland triangulate -S with modifier +z so we can write -Zvalue in he…
c661eb5
…aders

The value can be determined via the optional argument to +z:
a mean of triplet [Default]
l Lower value of triplet
m Median value of triplet
p Modal value of triplet
Upper value of triplet
@PaulWessel
improve usage messages
d7d88db
@PaulWessel
Merge branch 'master' into tri-patches
9d7dd13
@PaulWessel
Update triangulate.c
d5daea5
@PaulWessel
Update triangulate.rst
a429415
@PaulWessel
Add test script
19c4b57
@PaulWessel
Update triangulate.dvc
b43b567
@PaulWessel
Update triangulate.c
b67e2f4
@PaulWessel
Update triangulate.c
f4d6e52
@joa-quim
Fix indentations.
086d78b
@PaulWessel
Fix lack of abs() in scale_down parameter
c6baa07
Somehow forgot that a color bar can be given with negative length to reverse the positive direction.  THe scale_dowm variable which involves sqrt of two dimensions , one of them was MAX (a, b) and a was negative, so it picked the bar width and we got tiny fonts.

This PR does teh fabs() and revises the wrong PostScript original.
@PaulWessel
Merge branch 'master' into tri-patches
6e797cf
@PaulWessel PaulWessel added the bug Something isn't working label Sep 14, 2023
@PaulWessel PaulWessel added this to the 6.5.0 milestone Sep 14, 2023
@PaulWessel
PaulWessel requested review from Esteban82 and joa-quim September 14, 2023 17:00
@PaulWessel PaulWessel self-assigned this Sep 14, 2023
joa-quim
joa-quim approved these changes Sep 14, 2023
View reviewed changes
@PaulWessel
PaulWessel merged commit 6fc01cb into master Sep 14, 2023
@PaulWessel
PaulWessel deleted the tri-patches branch September 14, 2023 20:00
@PaulWessel PaulWessel mentioned this pull request Sep 14, 2023
Tiny annotations on GMT_App_M_2.png #7814
Closed
@seisman

seisman commented Sep 21, 2023

Copy link
Copy Markdown
Member

@PaulWessel Did you forget to run dvc push when working on this PR?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

It is possible, what do you see?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@seisman

seisman commented Sep 21, 2023

Copy link
Copy Markdown
Member

The CI fails with errors like:

A       test/baseline/nearneighbor/
A       test/baseline/grdvolume/
A       test/baseline/psmask/
A       test/baseline/psevents/
A       test/baseline/grdpaste/
A       doc/examples/images/
93 files added and 979 files fetched
ERROR: failed to pull data from the cloud - Checkout failed for following targets:
doc/scripts/images
Is your cache up to date?
<https://error.dvc.org/missing-files>

I think it means the new baseline images in the doc/scripts/images directory were not pushed to the remote.

Could you please run dvc push on your computer?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Done, said 2 files pushed.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

I will run all tests now.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

MacOS gives 64 failures, in different categories:

  1. Most are grdimage/contour of earth_relief that have changed over time.
  2. Bunch of colorers are now different
  3. LOng-standing bugs yielding failures.

horsclpanel_diff

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@seisman

seisman commented Sep 21, 2023

Copy link
Copy Markdown
Member

Done, said 2 files pushed.

The CI now can get the baseline images correctly.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

I also have a few font(?) issues. Do you get this for GMT_Defaults_1c?

GMT_Defaults_1c_diff

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@seisman

seisman commented Sep 21, 2023

Copy link
Copy Markdown
Member

Yes, I have the same failure on Linux with gs 10.02.0

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

I have updated 9 PS files and now down to 55 failures

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

I don't understand nothing of our failing tests. I', down to 21 but for example equalarea fails because
image

or contours because
image

This has to be due to un-updated PSs

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Those changed in the last few hours. Please do dvc pull to get the latest.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Note there are still some (including the equlization) who fails due to the grid differences.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Also refresh master as well

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

All six of these fail because of similar issues with the colorbar bar. None because of a different grid

        354 - test/grd2cpt/equalarea.sh (Failed)
        373 - test/grdcontour/contours.sh (Failed)
        424 - test/grdfilter/openmp.sh (Failed)
        426 - test/grdfilter/threads.sh (Failed)
        445 - test/grdimage/grdcyclic.sh (Failed)
        448 - test/grdimage/grdread.sh (Failed)
        527 - test/grdvector/met_uv.sh (Failed)

and the met_uv.sh fails although it has a # GMT_KNOWN_FAILURE_WINDOWS

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

This is even more obvious.
image

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Well, when I run those scripts I get grid image mismatches that dominates the failure. This must either be

  1. M1 round off, using the -no-fast-math compiler switched helped but I think there is more here
  2. You are running different @earth_relief files. Can you do a ls -l on one of them and see what you get?
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Looks like your dvc files are not up to date. Here is my full cyclic diff:

grdcyclic_diff

I can of course update the PS since mine looks great, but then I think you will get the grdimage failure

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

I just did a dvc pull before running the tests. Different chips can not explain the differences. There are IEEE rules for floating point calculation and chips have to produce de same result. Also, fast-math should never be a default.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Could you send me the grid resulting from

gmt grdcut -R0/10/0/10 @earth_relief_05m_p -Gafr_topo.grd

and I will compare. Something is odd here.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

This fails because of the symbols transparency is different from when the orig was created. No grids involved
events_diff

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

That one was updated < 30 minutes ago and now passes?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

gmt grdcut -R0/10/0/10 @earth_relief_05m_p -Gafr_topo.grd

afr_topo.grd.zip

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Same with the other prevents test.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

Well, it says is very feshy

C:\progs_cygw\GMTdev\gmt5\master>dvc pull
Everything is up to date.
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

Your file differs a lot from mine. What does

ls -l ~/.gmt/server/earth/earth_relief/earth_relief_05m_p
total 23432
-rw-------  1 pwessel  staff  5939369 Aug 20 16:43 S90E000.earth_relief_05m_p.nc
-rw-------  1 pwessel  staff  6052681 Aug 20 16:43 S90W180.earth_relief_05m_p.nc

say

afr_topo.grd: v_min: -4992 v_max: 2769.5 name: z
afr_topo_jl.grd: v_min: -5087 v_max: 2769.5 name: z
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Maybe my issue with different grids having been written to .gmt. After deleting the 05m_p dir and rerun I get you grid. So I will delete earth_relief and rerun tests.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member
$ ls -l ~/.gmt/server/earth/earth_relief/earth_relief_05m_p
total 11732
-rw-r--r-- 1 j 197121 5952748 Aug 17 14:11 S90E000.earth_relief_05m_p.nc
-rw-r--r-- 1 j 197121 6057780 Aug 17 14:09 S90W180.earth_relief_05m_p.nc

An important question is is "What is this test testing"? If it's only the cyclic cpt it shouldn't involve any grid.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Yes, for this case sure, but do you feel like editing hundreds of scripts to make it so?

First, we need to get the tests to run from the static.generic-mapping-tools.org service with the idea that those files should not change. Working on it.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

I just though. If we invent a synthetic Earth we could cut it pieces to use in tests and no need for the static thing.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

@Esteban82, the oceania server has a gmt_data_server.txt file that lists the new planets. Did you or I update it by mistake? Says updated Sept 20 (yesterday). Oh, I see the cronjob copies information/gmt_data_server.txt into oceania etc. But that cron script is outdated; we do not store that in git anymore. There are no planet data on oceania, only candidate, yet the text file lists all of them. I will work on that.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

I just though. If we invent a synthetic Earth we could cut it pieces to use in tests and no need for the static thing.

If we create GMT_world_topo_15s.nc and tile it we will need to update hundreds of PostScript plots and scripts. I'm not ready for that for sure.
I do not understand why my grdcyclic test fails now that we both use the same grid. So your full image looks OK and just the color bars?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

Yes, colorbars are the source of almost all failures I see. That and the events transparency.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Esteban82

Esteban82 commented Sep 21, 2023

Copy link
Copy Markdown
Member

@Esteban82, the oceania server has a gmt_data_server.txt file that lists the new planets. Did you or I update it by mistake? Says updated Sept 20 (yesterday). Oh, I see the cronjob copies information/gmt_data_server.txt into oceania etc. But that cron script is outdated; we do not store that in git anymore. There are no planet data on oceania, only candidate, yet the text file lists all of them. I will work on that.

No, I didn't touch that file. It must have been the cronjob.

PaulWessel reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Could you try this for me: copy your

-rw-r--r-- 1 j 197121 5952748 Aug 17 14:11 S90E000.earth_relief_05m_p.nc
-rw-r--r-- 1 j 197121 6057780 Aug 17 14:09 S90W180.earth_relief_05m_p.nc

somewhere to safe, then delete those two files from your .gmt dir, then cd to your build dir and try test -R grdcyclic. Still passes after downloading the grids (are they coming from oceania or Europe?)

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Esteban82

Esteban82 commented Sep 21, 2023

Copy link
Copy Markdown
Member

Could you try this for me: copy your

Are you asking me or joaquim?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

Could you try this for me: copy your

Are you asking me or joaquim?

Sorry, that was for Joaquim. And I was a bit hasty declaring the files are the same:

gmt grdmath afr_topo_jl.grd afr_topo.grd SUB = d.grd
d.grd: v_min: -176.5 v_max: 132 name: z

Because here are the updated min/max after I wiped my earth_relief and got fresh from oceania:

afr_topo_jl.grd: v_min: -5087 v_max: 2769.5 name: z
afr_topo.grd: v_min: -5071 v_max: 2769.5 name: z

So we use different data and hence mine (more recent) differ and the test fails miserably. oceania has the same as candidate [Idid both]

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@PaulWessel

PaulWessel commented Sep 21, 2023

Copy link
Copy Markdown
Contributor Author

And of course it makes sense that the differences only involve the oceans (new SRTM15s data).

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@joa-quim

joa-quim commented Sep 21, 2023

Copy link
Copy Markdown
Member

Doing that now the tests fails just like yours (grid's is !=)

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@joa-quim joa-quim joa-quim approved these changes
@Esteban82 Esteban82 Awaiting requested review from Esteban82

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@PaulWessel PaulWessel

Labels

bug Something isn't working

Projects

None yet

Milestone

6.5.0

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

4 participants

@PaulWessel @seisman @joa-quim @Esteban82
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.