Opened 12 years ago

Closed 6 years ago

#1836 closed defect (wontfix)

r.reclass.eq reports r.reclass rules file missing

Reported by: cwren Owned by: grass-dev@…
Priority: normal Milestone: 7.0.7
Component: Default Version: svn-trunk
Keywords: Cc:
CPU: x86-64 Platform: MSWindows 7

Description

r.reclass.eq gives an error referring to a missing rules file and fails to produce an output. Using osgeo4w's grass70dev 7.0.svn-r54261-436

r.rescale.eq --overwrite input=test@PERMANENT output=testout to=1,100 Reading test@PERMANENT ... Description:

Reclassify raster map based on category values. Creates a new raster map whose category values are based

upon a reclassification of the categories in an existing raster map. Keywords:

raster, reclassification

Usage:

r.reclass input=name output=name rules=name [title=string]

[--overwrite] [--verbose] [--quiet]

Flags:

--o Allow output files to overwrite existing files --v Verbose module output --q Quiet module output

Parameters:

input Name of raster map to be reclassified

output Name for output raster map

rules File containing reclass rules

"-" to read from stdin

title Title for the resulting raster map

ERROR: Required parameter <rules> not set:

(File containing reclass rules)

Rescale test@PERMANENT[-5644,5207] to testout[1,100]

Change History (7)

comment:1 by neteler, 12 years ago

grep G_popen_write */*.c
r.mode/main.c:    reclass = G_popen_write(&reclass_child, "r.reclass", args);
r.rescale.eq/main.c:    fp = G_popen_write(&child, "r.reclass", args);
r.rescale/main.c:    fp = G_popen_write(&child, "r.reclass", args);
r.statistics/run_cmd.c:    fp = G_popen_write(child, argv[0], argv);

The usage of argv and args of G_popen_write() is not the same, desired?

in reply to:  description ; comment:2 by glynn, 12 years ago

Replying to cwren:

r.reclass.eq gives an error referring to a missing rules file and fails to produce an output.

It's actually r.rescale.eq, not r.reclass.eq.

It hasn't been updated since r.reclass' rules= option became mandatory. r.rescale was fixed with r45358; r.rescale.eq needs the same treatment.

BTW, there's no need to sprintf() the string into a buffer; using a string literal will work.

in reply to:  2 comment:3 by neteler, 12 years ago

Replying to glynn:

It hasn't been updated since r.reclass' rules= option became mandatory. r.rescale was fixed with r45358; r.rescale.eq needs the same treatment.

Done in r54322. The tomorrow's binary snapshot will contain the fix.

BTW, there's no need to sprintf() the string into a buffer; using a string literal will work.

Still open.

comment:4 by martinl, 9 years ago

Milestone: 7.0.07.0.5

comment:5 by neteler, 8 years ago

Milestone: 7.0.57.0.6

comment:6 by neteler, 7 years ago

Milestone: 7.0.67.0.7

comment:7 by martinl, 6 years ago

Resolution: wontfix
Status: newclosed

No activity.

Note: See TracTickets for help on using tickets.