2015-10-31

FME 2016 Help has been retired?

FME 2016 ヘルプがなくなった?

FME 2016 beta build 16118

The Help window as a part of Workbench has been retired in build 16115+. However, don't worry, the new Help system has been introduced instead. It's an independent application (one of utilities), but still keeps the functionality to synchronize with user operations in Workbench interface. e.g. if you select a transformer on the Canvas or the Transformer Gallery, the Help will show the corresponding page as same as before.
ビルド16115以降で、ワークベンチの一部としてのヘルプウィンドウは廃止されました。しかし、ご安心ください。その代わりに新しいヘルプシステムが導入されました。これは独立したアプリケーション (ひとつのユーティリティ) ですが、ワークベンチのインターフェースにおけるユーザー操作と同期する機能は維持されています。例えば、キャンバスやトランスフォーマーギャラリーでトランスフォーマーを選択すると、以前と同様にヘルプは対応するページを表示します。




































You can put the Help window on the top-most of windows by pushing the "Pin to top" button at the right-top of the window.
You can scroll or move the help page freely, even when you are editing parameters with a dialog box. e.g. transformer parameters, feature type properties.
You can minimize the window when you don't need to see the help, and also show it again anytime if needed.
ウィンドウ右上の "Pin to top" ボタンを押すと、ヘルプウィンドウを最上位のウィンドウにすることができます。
ダイアログボックスでパラメーター (例えばトランスフォーマーパラメーターやフィーチャータイププロパティ) を編集している間でも、自由にヘルプのページをスクロールしたり移動したりすることができます。
ヘルプを参照する必要がなければウィンドウを最小化することができるし、必要になればいつでも再表示することができます。

I believe that the usability will be fairly better than before.
以前よりも使い勝手がかなり良くなると思います。

2015-10-25

FME 2016 Dataset Fanout Setting

FME 2016 データセットファンアウトの設定

FME 2016 beta build 16110

There is an improvement regarding the Dataset Fanout setting.
データセットファンアウト (データセットレベルの出力先振り分け) の設定に関する改良があります。
=====
2015-11-18
The Dataset Fanout in FME 2016 is still undergoing development, the user interface and behavior may be changed further more.
FME 2016 のデータセットファンアウトはまだ開発中で、ユーザーインターフェースや動作はさらに変わることもあります。

FME 2015 1.2.1 build 15539












FME 2016 beta build 16110













Note: In Windows Japanese edition, a backslash (0x5C) is displayed with a  symbol.

In FME 2016, you can set an expression to the fanout dataset name, so it will be unnecessary to create a special feature attribute ("_code_and_name" in the above example) in the data flow for that. Great!
FME 2016 ではファンアウトデータセット名に式が設定できるので、データフローでそのための特別なフィーチャー属性 (上の例では "_code_and_name") を作成する必要はなくなります。すばらしい!

=====
2015-11-24 FME 2016.0 beta build 16133
One more great enhancement has been done. You can now create multiple zip files through the Dataset Fanout. See here.
もうひとつの大きな機能強化が行われました。データセットファンアウトで複数の zip ファイルが作成できます。ここを参照してください。

2015-10-24

FME 2016 FeatureWriter Use Case - Automate File Upload

FME 2016 FeatureWriter 使用例 - ファイルアップロードの自動化

FME 2016 beta build 16110

From this Q&A.
この Q&A から。
FME Community Answers > upload files to a FTP-Server

I agree with David. It'll be surely easier by introducing the FeatureWriter transformer in FME 2016. I think that "automate creating and uploading files to a server with a single workspace" would be one of effective use cases of the transformer.
デビッドさんと同感です。FME 2016 で FeatureWriter トランスフォーマーが導入されることによって、それは間違いなく簡単になるでしょう。「ファイルの作成とサーバーへのアップロードをひとつのワークスペースで自動化すること」は、このトランスフォーマーの効果的な使い方のひとつになると思います。

A demo workspace
デモワークスペース



















In this example, the FeatureWriter has just one writer feature type, but you can also define multiple feature types if necessary. That is, you can add input ports to the transformer, each port will correspond to each feature type.
この例では、FeatureWriter はひとつだけライターフィーチャータイプを持っていますが、必要であれば、複数のフィーチャータイプを定義することもできます。つまり、このトランスフォーマーには入力ポートを追加することができ、各ポートが各フィーチャータイプに対応することになります。























In the FTPCaller parameter settings, there is nothing special.
FTPCaller のパラメーター設定では、特別なことは何もありません。





















The FeatureWriter writes all the input features into a zip file with compressing, and then the FTPCaller uploads the zip file to the specified FTP server. You don't need to upload the file manually after translation or create another workspace containing the WorkspaceRunner, any longer.
FeatureWrite は全ての入力フィーチャーを圧縮してzipファイルに書き込み、FTPCaller はそのzipファイルを指定されたFTPサーバーにアップロードします。もはや、変換後にファイルを手作業でアップロードしたり、WorkspaceRunner を持つ別のワークスペースを作成したりする必要はありません。

Although the FeatureWriter parameters dialog doesn't have the "Zip output" button yet, it worked fine to write the features into a zip file, if I set a zip file path (i.e. ending with ".zip") to the "Dataset" parameter. Wish the button if possible.
FeatureWriter のパラメーター設定画面に "Zip ouput" ボタンがまだありませんが、"Dataset" パラメーターに zip ファイルパス (つまり ".zip" で終わる) を設定すれば、フィーチャーをzipファイルに書き込むことができました。できればボタンがほしいです。



=====
Oops, the "Zip output" button image has also been changed in FME 2016.
おっと、"Zip output" ボタンのイメージも FME 2016 で変更されていました。



=====
updated... build 16115. Yup, this shows a zipper clearly :)
更新... build 16115。うん。これは明らかにジッパーだ (^^)

2015-10-15

FME 2016 Workbench Run Modes

FME 2016 Workbench の実行モード

FME 2015.1.2.1 build 15539
Run Workspace | Prompt and Run | Run with Full Inspection | Run with Breakpoints




FME 2016 beta build 16104
Run Workspace | With Prompt | With Full Inspection | With Breakpoints




=====
The button image for "With Breakpoints" (the bug) may be changed in the near future. See also Dale's comment.
"With Breakpoints" ボタンのイメージ (虫) は近いうちに変更されるかも知れません。Dale さんのコメントも参照してください。
=====

The change has been done not only on the button images, but also on their behavior.
変更はボタンのイメージだけでなく、動作についても行われています。

In FME 2015, as you know, each command runs the workspace with its own mode.
FME 2015 では、ご存じのように各コマンドはそれぞれのモードでワークスペースを実行します。

In FME 2016, however, only "Run Workspace" runs the workspace, others indicate run modes which can be switched on/off independently. That is, you can also select two or three modes simultaneously if necessary. Primarily this may be considered as an enhancement of the functionality for debugging. e.g. you can run with Prompt and Full Inspection.
FME 2016 では "Run Workspace" だけがワークスペースを実行し、他は、個別にオン/オフが切り替えられる実行モードを示します。つまり、必要に応じて2つまたは3つのモードも同時に選択できるということです。これは、主にデバッグ機能の向上と考えることができます。例えば、Prompt および Full Inspection モードで実行できます。

Run Workspace with Prompt and Full Inspection




The new button images are simpler and more intuitive. Just would like to know why scarab (?) for "Run With Breakpoints" :)
新しいボタンのイメージは、よりシンプルで直感的です。ただ、"Run With Breakpoints" がなぜスカラベ (?) なのか知りたいのですが (^^)

2015-10-13

FME 2016 AttributeManager Transformer

FME 2016 AttributeManager トランスフォーマー

FME 2016 beta build 16104.

OK. I have investigated what we can do with the AttributeManager. In my understanding, the transformer performs one of the following actions for each attribute of the input feature.
OK. AttributeManager で何ができるかを調べました。私が理解したところでは、このトランスフォーマーは、入力フィーチャーの属性ごとに、下記のアクションのうちひとつを行います。

Set Value (値の設定):
Set the specified value to the attribute, or create a new attribute with the specified value. It's equivalent to the AttributeCreator or the AttributeCopier.
その属性に指定された値を設定するか、または、指定された値を持つ新しい属性を作成する。これは AttributeCreator または AttributeCopier と同等。

Do Nothing (何もしない):
Do nothing against the attribute. Why not say "No Action"?
その属性に対しては何もしない。"No Action" と言ってはどう?

Rename (属性名の変更):
Rename the attribute. It's equivalent to the AttributeRenamer or the ListRenamer.
その属性の名前を変更する。これは AttributeRenamer または ListRenamer と同等。

Remove (属性の削除):
Remove the attribute. It's equivalent to the AttributeRemover.
その属性を削除する。これは AttributeRemover と同等。

Set Default Value (デフォルト値の設定):
Basically it's the same as "Rename" on a non-list attribute, but set the specified value if the input attribute was missing. It's equivalent to the AttributeRenamer with Default Value setting (Rename with Default Value).
基本的には非リスト属性についての "Rename" と同じ。ただし、もし入力側の属性が存在していなければ、指定された値を設定する。これはデフォルト値が設定された AttributeRenamer と同等。

























Conclusion. The AttributeManager can be considered as an advanced AttributeRenamer involving the functionalities of AttributeCreator, AttributeCopier, AttributeRemover, and ListRenamer. A data flow containing those transformers can be replaced with just one AttributeManager. Additionally, it allows us to reorder the attribute names which are displayed in the Workbench interface.
結論。AttributeMerger は、AttributeCreator, AttributeCopier, AttributeRemover および ListRenamer の機能を含む高度な AttributeRenamer であると考えることができます。それらのトランスフォーマーを含むデータフローは、ひとつの AttributeManager に置き換えられます。さらに、Workbench のインターフェースに表示されている属性名の順番を変更することも可能にします。

















Really powerful.
本当にパワフルです。

If the transformer could "expose" and "hide" attribute names, would be perfect...
もしこのトランスフォーマーが、属性名を公開したり隠したりできれば完璧なんですが。

=====
2015-10-15:
Flashed a way to expose attributes with the AttributeManager. This is it.
AttributeManager で属性名を公開する方法が閃きました。これです。

















Not sure whether it's an assumed use...
想定されている使用法かどうかは分かりません。

=====
2015-11-04: build 16118
The parameters dialog has been updated.
パラメーター設定画面が更新されています。

FME 2016 New Feature - Upgrade Transformer

FME 2016 の新機能 - Upgrade Transformer (トランスフォーマーのアップグレード)

FME 2016 beta build 16104.

Open a workspace which was created with an older version of FME Workbench. If a transformer has been upgraded, the menu command "Upgrade Transformer" will be displayed when right-click on the transformer. Click the command if you want to upgrade it.
古いバージョンの FME Workbench で作成されたワークスペースを開いてください。トランスフォーマーがアップグレードされている場合は、それを右クリックしたときに "Upgrade Transformer" (トランスフォーマーのアップグレード) というメニューコマンドが表示されます。アップグレードしたいときは、そのコマンドをクリックしてください。


























Read the message, then click Yes if you surely want to upgrade.
メッセージを読み、本当にアップグレードしたいなら Yes をクリックします。













Confirm (modify if necessary) the parameter settings, then click OK.
パラメーターの設定を確認 (必要に応じて修正) してから OK をクリックします。












If you click the "Show Changes" button in the dialog above, you can also see the contents which have been changed by the upgrade. It's great.
上のダイアログボックスで "Show Changes" ボタンをクリックすると、アップグレードによって変更された内容を見ることもできます。これは素晴らしい。













Done!
完了!


FME 2016 New Transformers

FME 2016 の新トランスフォーマー

So far, I found these new transformers in FME 2016 beta build 16104.
これまでのところ、FME 2016 ベータ版 build 16104 で次の新しいトランスフォーマーを見つけました。

AttributeManager
AttributeValidator
CenterPointExtractor
ClosedCurveFilter
DMSCoordinateExtractor
FeatureWriter
LogMessageStreamer
MapboxStyler
OrientationReverser * see the additional post. 2015-12-15
PointPropertyExtractor
PointPropertySetter

The FeatureWriter allows us to implement "inline writing" in a workspace.
I expect this innovates workflow design concepts :)
FeatureWriter は、ワークスペースに「インライン出力」を実装することを可能にします。
これはワークフローのデザインコンセプトに革新をもたらすと思います。

Looks like
- AttributeClassifier has been upgraded to the new AttributeValidator;
- InsidePointExtractor has been upgraded to the new CenterPointExtractor, which can extract (x, y, z) of either center, center of gravity or inside point according to user's selection;
- Orientor (Orientation Type: REVERSE) and SurfaceReverser have been integrated into the new OrientationReverser, but couldn't find out where the Orientor (RIGHT/LEFT-HAND-RULE) has gone.
その他、以下のように見えます。
- AttributeClassifier は AttributeValidator にアップグレードされました。
- InsidePointExtractor は CenterPointExtractor にアップグレードされました。これは、選択に応じて中心、重心、または内点のいずれかの (x, y, z) を抽出します。
- Orientor (Orientation Type: REVERSE) と SurfaceReverser は、OrientationReverser に統合されましたが、Orientor (RIGHT/LEFT-HAND-RULE) はどこに行ったか見つけられませんでした。

=====
Don't worry. The GeometryValidator (Issue: Invalid Area Orientation, FME 2015.1+) can be used instead of the Orientor (RIGHT/LEFT-HAND-RULE). See also Dale's comment.
心配無用。GeometryValidator (Issues: Invalid Area Orientation, FME 2015.1+) が Orientor (RIGHT/LEFT-HAND-RULE) の代わりに使用できます。 Dale さんのコメントも参照してください。

=====
2015-12-15 FME 2016.0 beta build 16147
I noticed the OrientationReverser has been renamed again. It is now called "Orientor". The previous name and functionality has revived, and also the SurfaceReverser has been integrated into it.
OrientationReverser が再び改名されていることに気がつきました。今は "Orientor" と呼ばれています。以前の名前と機能が復活するとともに、SurfaceReverser がこれに統合されています。

2015-05-17

Recently Published FME Store Transformers

最近FMEストアで公開したトランスフォーマー


AttributeSwapper

Swaps the values of specified two attributes (A and B) unconditionally by default.
Optionally, you can choose one of these conditional swapping modes.
"A < B": Swap the values only when A is less than B.
"A > B": Swap the values only when A is greater than B.
The internal storage data types of the attributes will also be swapped. And also <null> and <missing> will be swapped, but they will be treated as the empty string when comparing values in conditional swapping mode.
The main process has been implemented with a Tcl script.

指定した二つの属性(A及びB)の値を、デフォルトでは無条件で交換します。
必要に応じて、次のうちひとつの条件付きスワップモードを選べます。
"A < B": AがBより小さいときだけ交換する。
"A > B": AがBより大きいときだけ交換する。
属性の内部データ型も交換されます。また、<null>及び<missing>も交換されますが、条件付きスワップモードで値を比較するとき、それらは空文字列として扱われます。
主処理はTclスクリプトで実装されています。


FeatureAlternator

Outputs the features entered from the two input ports (A and B) alternatively. i.e. A, B, A, B, ...
If the number of features entered from one input port is greater than another, the remainder features will be output from RemnantA or RemnantB port after all alternated features have been output.
The main process has been implemented with a Python script.

二つの入力ポート(A及びB)から入力されたフィーチャーを交互に出力します。つまり、A, B, A, B, ...のように。一方のポートから入力されたフィーチャーの数が他方よりも多かった場合、交互のフィーチャーが出力された後、残りのフィーチャーはRemnantAまたはRemnantBポートから出力されます。
主処理はPythonスクリプトで実装されています。


PathSegmentJoiner

Transforms a path into a line by connecting its path segments. By default, the transformer transforms the input path only if it is a linear path that doesn't contain arc-segments.
If you set "Yes" to the "Transform Non-Linear Path after Stroking Arc Segments" parameter, the transformer also transforms non-linear paths into lines after stroking their arc-segments.
The resulting lines will be output from the Touched port; untouched features will be output from the Untouched port.
The main process has been implemented with a Python script.

構成するセグメントを連結することにより、パスをラインに変換します。デフォルトではアーク(弧)セグメントを含まない線形のパスのみを変換します。
"Transform Non-Linear Path after Stroking Arc Segments"パラメーターを"Yes"に設定した場合は、非線形のパスについても、アークセグメントを近似するラインに置き換えてから変換します。
変換後のラインはTouchedポートから出力され、変換されなかったフィーチャーはUntouchedポートから出力されます。
主処理はPythonスクリプトで実装されています。

=====
2015-05-25

ZipArchiver

Compresses a file and appends it into the specified zip file.
The archive name will become the same as the target file name. If a file having the same name as the target file has been archived in the zip file already, the target file will not be archived.
The transformer creates a new zip file when receiving the first file that should be archived into it, if the specified zip file doesn't exist.
-----
Note: Currently this transformer DOES NOT SUPPORT file path strings containing Non-ASCII characters. Unexpected result may occur if the target file path and/or zip file path contain Non-ASCII characters.

ファイルを圧縮し、指定したzipファイルに追加します。
アーカイブ名は対象のファイル名と同じになります。対象とするファイルと同じ名前のファイルがすでにzipファイルにアーカイブされていた場合、その対象ファイルはアーカイブされません。
指定したzipファイルが存在しない場合、このトランスフォーマーはそれにアーカイブすべき最初のファイルを受け取ったときに新しいzipファイルを作成します。
-----
注:現在このトランスフォーマーは、非ASCII文字(半角の英数字・記号以外の文字)を含むファイルパス文字列をサポートしていません。 対象ファイルパスおよび/またはzipファイルパスに非ASCII文字が含まれている場合、予期しない結果が生じることがあります。
=====

FME 2015.1.0.1 build 15480

2015-05-16

NeighborFinder - Collect All Candidates for Each Base

NeighborFinder - 各ベースに対して全ての候補フィーチャーを集める

The traditional way is to set an enough large value to the "Maximum Distance" parameter and specify a Close Candidate List Name.
伝統的は方法は、"Maximum Distance"(最大距離)パラメーターに十分大きな値を設定し、Close Candidate List Name(近い候補を格納するリスト名)を指定することです。

"To get the distance from a given Base to all Candidate features, use a very large number for this parameter and specify a Close Candidate List Name."
-- Help on the NeighborFinder
「ベースフィーチャーから全ての候補フィーチャーまでの距離を取得するには、このパラメーターに非常に大きな値を設定するとともに、Close Candidate List Nameを指定してください。」
(NeighborFinderのヘルプより)

Now, the "Number of Neighbors to Find" parameter has been added to the transformer in FME 2015. You have to specify at least one of this parameter and the "Maximum Distance".
さて、FME 2015では、"Number of Neighbors to Find"パラメーターが追加されました。このパラメーターと"Maximum Distance"の少なくともどちらか一方は指定する必要があります




















You now have these three choices about the method of finding neighbors.
これで、近傍フィーチャーの探し方に関して次の三つの選択肢を持つことになりました。

1. Number of Neighbors to Find: <not set>, Maximum Distance: D
Find neighbors in candidates within D. It's equivalent to the previous version.
距離D以内にある候補の中で近傍を探す。これは以前のバージョンと同じ。

2. Number of Neighbors to Find: N ( > 0), Maximum Distance: <not set>
Find neighbors in closer N candidates. If you want to find the closest neighbor regardless of the distance, you can use this option with setting 1 as N. Probably it's the most frequent use case.
近い方からN個の候補の中で近傍を探す。距離に関係なく最も近い近傍を見つけたいときは、Nに1を設定してこのオプションが使えます。おそらくそれが最も多い使用法でしょう。

3. Number of Neighbors to Find: N ( > 0),  Maximum Distance: D
Find neighbors in closer maximum N candidates within D.
距離D以内で近い方から最大N個の候補の中で近傍を探す。

In fact, the traditional way mentioned above is not something special, just is an application of the 1st method. If the maximum distance between base and candidate in the data is known when creating the workspace, there is no problem with the way. Just set a value greater than the maximum D to the "Maximum Distance" parameter. That's it.
実のところ、前述の伝統的な方法は特別なものではなく、第一の方法の応用に過ぎません。ワークスペースの作成時にデータにおけるベースと候補の間の最大距離が既知であれば、この方法には何も問題はありません。単にその最大距離より大きい値を"Maximum Distance"に設定するだけです。

But if it's difficult to determine the maximum distance, how to?
しかし、その最大距離を決めるのが難しいときは、どうします?

In FME 2014 or earlier, it was necessary to estimate the maximum distance anyhow.
In FME 2015, I noticed that the transformer collects all candidates for each base with this setting.
FME 2014以前では、何とかしてその最大距離を推定する必要がありました。
FME 2015では、次の設定によって各ベースに対して全ての候補が集められることに気がつきました。

Number of Neighbors to Find: 0, Maximum Distance: <not set>

Interesting, but it's not documented anywhere. I'm not sure whether it is a correct behavior intended by the developer.
面白いけど、この方法はどこにも記載されていません。開発者が意図した正しい動作であるかどうかは分かりません。

FME 2015.1.0.1 build 15480

2015-05-07

FME stores all attributes as character strings (?): Part 3

FMEは全ての属性を文字列として格納する (?): パート3

Previously I quoted this description from the Workbench help, twice.
以前2回、ワークベンチのヘルプから次の説明を引用したことがあります。

"Feature attributes are usually a primitive type: integers, floats, characters. Internally, FME stores all attributes as character strings and automatically converts between a string representation and a numeric representation as needed."
-- FME Workbench (2015.0 or earlier) > FME Architecture (Reference) > Attribute

2013-05-19 FME stores all attributes as character strings
2013-09-30 FME stores all attributes as character strings: Part 2

Today, I noticed that the "FME Architecture" section has disappeared in FME 2015.1.
今日、FME 2015.1では"FME Architecture"の章が消えていることに気がつきました。

Probably old FME stores all attributes as character strings, but it seems not to be true in the current FME. Actually I frequently see "64 bit integer", "64 bit real" etc.
おそらく古いFMEは全ての属性を文字列として格納するのでしょうが、現在のFMEではそうではないようです。実際、"64 bit integer"、"64 bit real"などをよく見かけます。

I guess a big change about internal attribute data handling has been done for FME 2015, but I'm unclear what the current rule on the data types is.
If the section would be restored with update, it could become clear.
FME 2015では、内部での属性データの取り扱いについて大きな変更があったと推測しますが、データ型についての現在のルールは不明です。
もしその章が更新されて復活したならば明確になるのかも知れませんが。

2015-05-04

Destination Feature Type Name Setting in FME 2015.1

FME 2015.1における出力先フィーチャータイプ名の設定

In FME 2015.1, the "Fanout By Attribute" doesn't appear in writer feature type properties dialog. The Feature Type Fanout has been retired?
FME 2015.1では、ライターフィーチャータイププロパティ設定画面で"Fanout By Attribute"が表示されません。フィーチャータイプ・ファンアウトは廃止された?

FME 2015.0 build 15253
















FME 2015.1 build 15479
















The answer is also "Yes", and can also be "No".
答えは「はい」でもあり、「いいえ」でもあり得ます。

Yes, the term "Feature Type Fanout" will be deprecated in the context of setting a writer feature type properties. But the functionality itself has not been deprecated.
You can use the functionality through setting an attribute to the feature type name field.
はい。「フィーチャータイプ・ファンアウト」という用語は、ライターフィーチャータイププロパティ設定の文脈では使用されなくなります。しかし、その機能自体は廃止されていません。
その機能は、フィーチャータイプ名フィールドに属性を設定することによって使うことができます。

In FME 2015.1, you can set destination feature type name by one of these ways.
(1) Enter a string (static feature type name) to the field directly.
(2) Select an attribute (equivalent to the old "Fanout By Attribute").
(3) Enter a string with the Text Editor.
(4) Select a user parameter (equivalent to entering "$(parameter name)" to the field directly).
FME 2015.1では、これらの方法のどれかひとつによって出力先フィーチャータイプ名を設定できます。
(1) フィールドに直接文字列(静的なフィーチャータイプ名)を入力する。
(2) 属性を選択する(以前の"Fanout By Attribute"と同等)。
(3) テキストエディタを使って文字列を入力する。
(4) ユーザーパラメータを選択する(フィールドに"$(パラメーター名)"を直接入力するのと同等)。












(1), (2), (4) have been also available in the previous version, but (3) is new and interesting. You can perform a string operation here and use the result as the destination feature type name.
(1), (2), (4)は以前のバージョンでも可能でしたが、(3)は新しく、興味深い。ここでなんらかの文字列操作を実行し、その結果を出力先フィーチャータイプ名として使うことができます。

Example:







See also this article.
この記事も参照してください。
The Safe Software Blog > The Feature Types They Are a-Changin’

FME 2015.1 build 15479

2015-05-02

AttributeCreator Advanced Attribute Value Handling

AttributeCreatorの高度な属性値処理

The "Multiple Feature Attribute Support" of the AttributeCreator was introduced in FME 2013 SP2, we have been receiving big benefit from that.
The functionality had been called the same name until 2014, maybe the only change during the period would be that the "null support" was added in FME 2014.
AttributeCreatorの"Multiple Feature Attribute Support"(複数フィーチャーの属性サポート)はFME 2013 SP2で導入され、私たちは大きな恩恵を受けてきました。
この機能は2014年までは同じ名前で呼ばれており、おそらく、その間の唯一の変更は、FME 2014で「ナル値のサポート」が追加されたことでしょう。














In FME 2015.0, the functionality itself was not changed basically, although the parameters group name has been changed to "Advanced: Prior/Subsequent Feature Attribute Retrieval".
FME 2015.0では、パラメーターグループ名が"Advanced: Prior/Subsequent Feature Attribute Retrieval"に変わりましたが、基本的には機能そのものに変化はありませんでした。












But there have been a big change in FME 2015.1.
しかし、FME 2015.1で大きな変化がありました。

That is, the "Substitute Missing, Null and Empty by" parameter (called "If Attribute is Missing, Null, or Empty" in the previous version) is now independent from the functionality for accessing prior/subsequent feature attributes.
それは、"Substitue Missing, Null and Empty by"パラメーター(以前は"If Attribute is Missing, Null, or Empty"と呼ばれていた)が、前後のフィーチャー属性にアクセスする機能から独立したことです。













What we can do with that?
これで何ができます?

Maybe a typical use case would be to replace an null, missing or empty attribute with a specific value (Default Value). For example, this setting is effective when you need to treat null or missing as 0 in a math expression.
おそらく典型的なユースケースは、ナル、欠落、空文字列属性をある特定の値(Default Value)に置き換えることでしょう。例えばこの設定は、数式においてナルや欠落を0とみなす必要があるときに効果的です。




















It doesn't stand out, but is a wouderful improvement.
目立たないけれども素晴らしい改良です。

FME 2015.1 build 15479

Read Schema Features with FeatureReader

FeatureReaderでスキーマフィーチャーを読み込む

FME 2015.1 has been released a few days ago.
FME 2015.1が数日前にリリースされました。

In FME 2015.1, a new output port named <Schema> has been added to the FeatureReader transformer. From this port, schema features will be output for each feature type, each feature contains the following attributes as a schema information of a feature type.
FME 2015.1では、FeatureReaderトランスフォーマーに <Schema> という名前の出力ポートが追加されました。このポートからは、フィーチャータイプごとのスキーマフィーチャーが出力され、各フィーチャーはフィーチャータイプのスキーマ情報として次のような属性を持ちます。

attribute{}.name
attribute{}.fme_data_type
attribute{}.native_data_type
fme_feature_type_name
etc.

Since the structure is same as the schema feature read by the Schema (Any Format) reader, it can be used to configure dynamic schema applying the method described in this article.
この構造は Schema (Any Format) リーダーで読み込まれるスキーマフィーチャーと同じなので、次の記事で説明されている方法を応用してダイナミックスキーマを構成するのに使用できます。

Think of a case like this.
- There are many Shape files which are saved in a certain folder.
- Their schemas are unknown when creating the workspace.
- You have to create a new File Geodatabase (*.gdb) and export all Shape features to the gdb.
- The destination schemas should be same as the source schemas.
次のような場合について考えます。
- あるフォルダにたくさんのShapeファイルが保存されている。
- ワークスペースの作成時点でそれらのスキーマは不明。
- 新しいファイルジオデータベース (*.gdb) を作成し、全てのShapeフィーチャーをそのgdbにエクスポートしなければならない。
- 出力先のスキーマはソーススキーマと同じでなければならない。

=====
2015-05-23: oops! It was not essential to merge the schema to data features. Since the Schema feature will be outputted first from the FeatureReader, you can send it directly to the Dynamic writer. Then, the writer can configure the destination schema based on it.
Revised the following.
おっと、データフィーチャーにスキーマをマージすることは必須ではありませんでした。スキーマフィーチャーはFeatureReaderから最初に出力されるので、それを直接ダイナミックライターに送ることができます。ライターはそれに基づいて出力先のスキーマを構成できます。
下記修正。
=====

With the FeatureReader in FME 2015.1, this approach is available.
(1) Get all Shape file paths (*.shp) with a Directory and File Pathnames reader.
(2) Send them to a FeatureReader, select "path_windows" or "path_unix" attribute for the "Dataset" parameter.
(3) Merge schema feature to data features with a FeatureMerger.
Requestor (data feature)  fme_feature_type
Supplier (schema feature)  fme_feature_type_name
(4) (3) Send both the Schema feature and the Data features to a FILEGDB writer with Dyanmic Schema mode. Set "Schema from first feature" to the "Schema Sources" parameter.
FME 2015.1のFeatureReaderでは、次のアプローチが可能です。
(1) Directory and File Pathnames リーダーで全てのShapeファイルパス(*.shp)を取得する。
(2) それらをFeatureReaderに送り、"Dataset"パラメータで"path_windows"または"path_unix"属性を選択する。
(3) FeatureMergerでスキーマフィーチャーをデータフィーチャーに結合する。
Requestor (データフィーチャー)  fme_feature_type
Supplier (スキーマフィーチャー)  fme_feature_type_name
(4) (3) スキーマフィーチャーとデータフィーチャーを両方ともダイナミックスキーマモードのFILEGDBライターに送る。"Schema Sources"パラメーターは"Schema from first feature"(フィーチャータイプごとに最初のフィーチャーのスキーマを使用する)に設定してください。


2015-05-23
Deprecated the left image.
左の図は廃止しました。






There are some changes regarding Feature Types in FME 2015.1. See also this article.
FME 2015.1ではフィーチャータイプに関していくつかの変更があります。次の記事も参照してください。

FME 2015.1 build 15479

2015-04-14

Change of ListExploder Default Behavior

ListExploderのデフォルトの動作の変更

In FME 2015, the "Attribute Accumulation" parameters group has been introduced into several transformers such as FeatureMerger, PointOnAreaOverlayer, ListExploder and so on.
FME 2015では、FeatureMerger、PointOnAreaOverlayer、ListExploderなどいくつかのトランスフォーマーに"Attribute Accumulation"パラメーターグループが導入されました。






















In almost all the transformers having "Attribute Accumulation" group, the behavior with default parameter settings is same as the default behavior of the previous version. They are following the general principle that the backward compatibility should be kept.
"Attribute Accumulation"グループを持つほぼ全てのトランスフォーマーでは、デフォルトのパラメーター設定での動作は以前のバージョンのデフォルトの動作と同じです。これらは後方互換性を保つべきであるという一般原則に従っています。

However, I noticed the ListExploder is not following the principle.
しかし、ListExploderはその原則に従っていないことに気がつきました。

The new ListExploder has these four options depending on the Attribute Accumulation settings.
新しいListExploderには、Attribute Accumulationの設定に応じてこれらの4つのオプションがあります。
Accumulation ModeConflict Resolution
1Merge Incoming ListUse Original(default)
2Merge Incoming ListUse Incoming List
3Prefix Incoming List
4Only Use Incoming List

The 1st option is set by default, but the default behavior of the previous version is equivalent to the 2nd option.
1番目のオプションがデフォルトで設定されていますが、以前のバージョンのデフォルトの動作は2番目のオプションに相当します。

I had discussed about this change with Safe support team.
Safe acknowledges that the default behavior of new ListExploder is different from the previous version. And, according to their explanation, the change has been done intentionally to unify the default behavior of the transformers which have "Attribute Accumulation" parameters group.
この変更についてSafe社のサポートチームと話し合いました。
Safe社も新しいListExploderのデフォルトの動作が以前のバージョンと異なることは認めています。そして、彼らの説明によれば、この変更は、"Attribute Accumulation"パラメーターグループを持つトランスフォーマーのデフォルトの動作を統一するために意図的に行われたということです。

I understand that the change is reasonable, but it might cause a confusion to some users who are familiar with the default behavior of the previous ListExploder.
この変更が合理的であることは理解しますが、以前のListExploderのデフォルトの動作に親しんでいるユーザーに混乱をもたらすかも知れません。

Check the parameters always when you use the ListExploder in FME 2015.
FME 2015でListExploderを使うときは、これらのパラメーターをいつも確認してください。

=====
So, I still think it's better that the Attribute Accumulation group will be shown by default, at least in the ListExploder...
なので、Attribute Accumulationグループはデフォルトで表示された方が良いとまだ思っています。少なくともListExploderでは。。。

2015-04-13

Use Time Positions on Time Line

タイムライン上の時間位置の利用

Summary of this thread.
このスレッドのまとめ。
FME Community Answers > Merge features based on time

Assuming you have two datasets:
- one contains rasters having a datetime attribute,
- another contains GPS points also having a datetime attribute.
The goal is to give each raster the geographic coordinate of a point having smallest time difference from the raster.
二つのデータセットがあるものとします。
- ひとつは日付時刻属性を持つラスターから成り、
- もう一つはやはり日付時刻属性を持つGPSポイントから成る。
目標は、各ラスターに、そのラスターからの時間差が最も小さいポイントの地理座標を与えることです。

Seemingly the solution would be complicated, but you can solve it easily with the NeighborFinder if you replace every geometry with a time position on a time line - i.e. a coordinate (time, 0) on the X axis.
一見、解決策は複雑になりそうですが、ジオメトリをタイムラインにおける時間位置 - つまりX軸上の座標 (時間, 0) に置き換えれば、NeighborFinerを使って簡単に解決できます。

(1) Convert the datetime value to the count of seconds since the epoch, using a DateFormatter (Destination Date Format: %s).
DateFormatter (Destination Date Format: %s) によって日付時刻値をエポックからの秒数に変換します。

(2) Extract the raster data as an attribute by a RasterExtractor, and replace the geometry with a point (X=seconds, Y=0) by a VertexCreator.
RasterExtractorによってラスターデータを属性として抽出し、VertexCreatorによってジオメトリをポイント (X=秒数, Y=0) に置き換えます。

(3) Extract geographic coordinate (x, y) of the GPS points by a CoordinateExtractor, and replace the geometry with a point (X=seconds, Y=0) by a VertexCreator, as well.
CoordinateExtractorによってGPSポイントの地理座標 (x, y) を抽出し、同様にVertexCreratorによってジオメトリをポイント (X=秒数, Y=0) に置き換えます。

Here, the point (X=second, Y=0) represents the time position of a feature on a time line (X-axis).
ここで、ポイント (X=秒数, Y=0) がタイムライン(X軸)上のフィーチャーの時間位置を表します。

(4) Add a NeighborFinder; send the (2) features to the Base port; send the (3) features to the Candidate port. Then, each Matched feature will have the geographic coordinate (x, y) of a GPS point which has smallest time difference.
NeighborFinderを追加し、(2)のフィーチャーをBaseポートに、(3)のフィーチャーをCandidateポートに送ります。すると、Matchedフィーチャー は、時間差が最小のGPSポイントの地理座標 (x, y)を持つことになります。

(5) Finally, restore the original raster of each Matched feature by a RasterReplacer.
最後にRasterReplacerによってMatchedフィーチャーを元のラスターに復元します。

I think you have ever learned about "Number Line" in school. In fact, the time line is not any one other than the Number Line.
Elementary mathematics is also very helpful in some cases.
学校で「数直線」について習ったことがあると思います。実のところ、タイムラインは数直線に他なりません。
初等数学も時にはとても役に立ちます。

2015-04-12

Change Multiple Data Types Simultaneously

複数のデータ型を同時に変更する

FME 2015.1 is coming soon.
FME 2015.1は間もなくリリースされます。

Found a wonderful enhancement of writer feature type in FME 2015.1 beta.
You can change data types of multiple attributes simultaneously.
FME 2015.1ベータでライターフィーチャータイプの素晴らしい機能強化を見つけました。
複数の属性のデータ型を同時に変更することができます。

Select multiple rows with Ctrl+Click.
Ctrlキーを押しながらクリックして複数行を選択。















Change data type of a row in the selection. e.g. char -> number
選択行内のどれかの行でデータ型を変更。例: char -> number















Change width and precision if necessary.
必要に応じて幅と精度も変更。















Quick and intuitive. I have waited for this for long time :)
迅速かつ直感的。長い間これを待っていました(^^)

FME 2015.1 Beta build 15468

2015-03-01

Create Schema Features with Python Script

Pythoスクリプトによるスキーマフィーチャーの作成

From this thread.
このスレッドから。
Community Answers > Oracle Spatial to SHAPE

In many cases, you can use the Schema (Any Format) reader to read schemas of source feature types from any format dataset. Schema features contains "attriubte{}" list, it can be used to configure dynamic schema with this method.
"Destination Schema is Derived from List Attributes"
多くの場合には、Schema (Any Format)リーダーを使って、どんなフォーマットでも、そのデータセットからソースフィーチャータイプのスキーマを読むことができます。スキーマフィーチャーは "attribute{}" リストを持っており、次の方法によってダイナミックスキーマを設定するのに使えます。
"Destination Schema is Derived from List Attributes"

However, in the case where the feature type (table) names will be determined at each run-time (i.e. they are unknown when creating the workspace), you cannot use the Schema reader since the feature types cannot be set to the reader beforehand.
しかし、フィーチャータイプ(テーブル)名が実行時に決定されるような場合(つまり、ワークスペース作成時にはそれらが未知である場合)には、フィーチャータイプをあらかじめ設定することができないため、Schemaリーダーを使うことができません。

In such a case, I think a Python script is an effective solution. fmeobjects.FMEUniversalReader class provides the functionality equivalent to the Reader in Workbench.
そのような場合には、Pythonスクリプトが効果的だと思います。fmeobjects.FMEUniversalReaderクラスが、ワークベンチのリーダーに相当する機能を提供します。
=====
Note: Safe is planning to do enhancement regarding schema reading functionality in the near future. This Python approach could be unnecessary after the enhancement has been done.
See also Dale's comment.
注: Safe社は近い将来におけるスキーマ読込に関する機能強化を計画しています。それが実現すると、このPythonによるアプローチは不要になるかも知れません。
デールさんのコメントも参照してください。
=====

For example, if the source feature type (e.g. Oracle Non-spatial database table) names will be given by an input feature which contains an attribute (e.g. "table_list") storing them in comma-delimited format, a PythonCaller with this script creates schema features for each table.
例えば、ソースフィーチャータイプ(例: Oracle Non-spatial データベーステーブル)名が、それらをカンマ区切り形式の属性(例: "table_list")として持つ入力フィーチャーによって与えられる場合には、次のスクリプトを設定したPythonCallerが各テーブルに対応するスキーマフィーチャーを作成します。
-----
class SchemaReader(object):
    def input(self, feature):
        # Create SCHEMA reader.
        # Set comma-delimited feature type (table) names to "IDLIST" directive.
        directives = ['IDLIST', feature.getAttribute('table_list')]
        reader = fmeobjects.FMEUniversalReader('SCHEMA', False, directives)
     
        # Open dataset.
        # The parameter setting is an example for ORACLE_NONSPATIAL format.
        # Required parameters other than "REAL_FORMAT" are different
        # depending on the real format.
        # See "Mapping File Directives" section in the help documentation
        # on the real format to learn more about the format specific parameters.
        dataset = <service name>
        parameters = [
            'REAL_FORMAT', 'ORACLE_NONSPATIAL',
            'USER_NAME', <user name>,
            'PASSWORD', <password>,
        ]
        reader.open(dataset, parameters)
     
        # Read and output schema features.
        while True:
            schema = reader.read()
            if schema == None:
                break
            self.pyoutput(schema)
         
        # Close the dataset.
        reader.close()

-----

It's simple and efficient, but I noticed that FME will write all the parameter values including password into the log file. For higher security, it might be better to create a format specific reader, rather than the Schema reader.
In this case, you will have to create the "attribute{}" with the script.
これは簡単で効率的ですが、FMEは、パスワードを含む全てのパラメーターの値をログファイルに書き込むことに気がつきました。より高いセキュリティのためには、Schemaリーダーではなく、フォーマット固有のリーダーを作成する方が良いかも知れません。
その場合、"attribute{}"はスクリプトで作成する必要があります。
-----
class SchemaReader(object):      
    def input(self, feature):
        # Create ORACLE_NONSPATIAL reader.
        # Set comma-delimited feature type (table) names to "IDLIST" directive.
        directives = ['IDLIST', feature.getAttribute('table_list')]
        reader = fmeobjects.FMEUniversalReader('ORACLE_NONSPATIAL', False, directives)
     
        # Open dataset.
        # The parameter setting is an example for ORACLE_NONSPATIAL format.
        # Required parameters are different depending on the format.
        # See "Mapping File Directives" section in the help documentation
        # on the real format to learn more about the format specific parameters.
        dataset = <service name>
        parameters = [
            'USER_NAME', <user name>,
            'PASSWORD', <password>,
        ]
        reader.open(dataset, parameters)
     
        # Read and output schema features.
        while True:
            schema = reader.readSchema()
            if schema == None:
                break
         
            # Set Feature Type Name.
            schema.setAttribute('fme_feature_type_name', schema.getFeatureType())
         
            # Create "attribute{}".
            for i, name in enumerate(schema.getSequencedAttributeNames()):
                type = schema.getAttribute(name)
                schema.setAttribute('attribute{%d}.name' % i, name)
                schema.setAttribute('attribute{%d}.fme_data_type' % i, type)
             
            # Ouput Schema Feature.
            self.pyoutput(schema)
         
        # Close the dataset.
        reader.close()
-----

See here to learn more about the FMEUniversalReader class and its methods.
FMEUniversalReaderクラスとそのメソッドの詳細についてはここを参照してください。
Python FME Objects API Reference

Although the example above is for the ORACLE_NONSPATIAL format, I think the same mechanism can also be applied to any other formats.
上の例はORACLE_NONSPATIALフォーマット用ですが、同じ仕組みは他のすべてのフォーマットにも適用できると思います。

FME 2015.0 build 15253